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 ENABLE_HEADLESS_ONLY 930 DEFAULT_MAKE_TARGET 931 OS_VERSION_MICRO 932 OS_VERSION_MINOR 933 OS_VERSION_MAJOR 934 PKG_CONFIG 935 BASH_ARGS 936 SETFILE 937 CODESIGN 938 XATTR 939 DSYMUTIL 940 IS_GNU_TIME 941 PATCH 942 DTRACE 943 TIME 944 STAT 945 HG 946 READELF 947 OTOOL 948 LDD 949 ZIP 950 UNZIP 951 TAR_SUPPORTS_TRANSFORM 952 TAR_INCLUDE_PARAM 953 TAR_CREATE_EXTRA_PARAM 954 TAR_TYPE 955 FIND_DELETE 956 OUTPUT_SYNC 957 OUTPUT_SYNC_SUPPORTED 958 CHECK_TOOLSDIR_MAKE 959 CHECK_TOOLSDIR_GMAKE 960 CHECK_MAKE 961 CHECK_GMAKE 962 MAKE 963 PKGHANDLER 964 CONFIGURESUPPORT_OUTPUTDIR 965 OUTPUT_ROOT 966 CONF_NAME 967 SPEC 968 SDKROOT 969 XCODEBUILD 970 VALID_JVM_VARIANTS 971 JVM_VARIANTS 972 DEBUG_LEVEL 973 HOTSPOT_DEBUG_LEVEL 974 JDK_VARIANT 975 USERNAME 976 CANONICAL_TOPDIR 977 ORIGINAL_TOPDIR 978 TOPDIR 979 PATH_SEP 980 ZERO_ARCHDEF 981 HOTSPOT_BUILD_CPU_DEFINE 982 HOTSPOT_BUILD_CPU_ARCH 983 HOTSPOT_BUILD_CPU 984 HOTSPOT_BUILD_OS_TYPE 985 HOTSPOT_BUILD_OS 986 OPENJDK_BUILD_BUNDLE_PLATFORM 987 OPENJDK_BUILD_CPU_BUNDLE 988 OPENJDK_BUILD_OS_BUNDLE 989 OPENJDK_BUILD_OS_EXPORT_DIR 990 OPENJDK_BUILD_CPU_JLI_CFLAGS 991 OPENJDK_BUILD_CPU_OSARCH 992 OPENJDK_BUILD_CPU_ISADIR 993 OPENJDK_BUILD_CPU_LIBDIR 994 OPENJDK_BUILD_CPU_LEGACY_LIB 995 OPENJDK_BUILD_CPU_LEGACY 996 HOTSPOT_TARGET_CPU_DEFINE 997 HOTSPOT_TARGET_CPU_ARCH 998 HOTSPOT_TARGET_CPU 999 HOTSPOT_TARGET_OS_TYPE 1000 HOTSPOT_TARGET_OS 1001 DEFINE_CROSS_COMPILE_ARCH 1002 LP64 1003 OPENJDK_TARGET_BUNDLE_PLATFORM 1004 OPENJDK_TARGET_CPU_BUNDLE 1005 OPENJDK_TARGET_OS_BUNDLE 1006 OPENJDK_TARGET_OS_EXPORT_DIR 1007 OPENJDK_TARGET_CPU_JLI_CFLAGS 1008 OPENJDK_TARGET_CPU_OSARCH 1009 OPENJDK_TARGET_CPU_ISADIR 1010 OPENJDK_TARGET_CPU_LIBDIR 1011 OPENJDK_TARGET_CPU_LEGACY_LIB 1012 OPENJDK_TARGET_CPU_LEGACY 1013 REQUIRED_OS_VERSION 1014 REQUIRED_OS_NAME 1015 COMPILE_TYPE 1016 OPENJDK_TARGET_CPU_ENDIAN 1017 OPENJDK_TARGET_CPU_BITS 1018 OPENJDK_TARGET_CPU_ARCH 1019 OPENJDK_TARGET_CPU 1020 OPENJDK_TARGET_OS_ENV 1021 OPENJDK_TARGET_OS_TYPE 1022 OPENJDK_TARGET_OS 1023 OPENJDK_BUILD_CPU_ENDIAN 1024 OPENJDK_BUILD_CPU_BITS 1025 OPENJDK_BUILD_CPU_ARCH 1026 OPENJDK_BUILD_CPU 1027 OPENJDK_BUILD_OS_ENV 1028 OPENJDK_BUILD_OS_TYPE 1029 OPENJDK_BUILD_OS 1030 OPENJDK_BUILD_AUTOCONF_NAME 1031 OPENJDK_TARGET_AUTOCONF_NAME 1032 target_os 1033 target_vendor 1034 target_cpu 1035 target 1036 host_os 1037 host_vendor 1038 host_cpu 1039 host 1040 build_os 1041 build_vendor 1042 build_cpu 1043 build 1044 NICE 1045 CPIO 1046 DF 1047 READLINK 1048 CYGPATH 1049 SED 1050 FGREP 1051 EGREP 1052 GREP 1053 AWK 1054 XARGS 1055 WHICH 1056 WC 1057 UNIQ 1058 UNAME 1059 TR 1060 TOUCH 1061 TEE 1062 TAR 1063 TAIL 1064 SORT 1065 SH 1066 RMDIR 1067 RM 1068 PRINTF 1069 NAWK 1070 MV 1071 MKTEMP 1072 MKDIR 1073 LS 1074 LN 1075 GZIP 1076 GUNZIP 1077 HEAD 1078 FIND 1079 FILE 1080 EXPR 1081 ECHO 1082 DIRNAME 1083 DIFF 1084 DATE 1085 CUT 1086 CP 1087 COMM 1088 CMP 1089 CHMOD 1090 CAT 1091 BASH 1092 BASENAME 1093 DATE_WHEN_CONFIGURED 1094 ORIGINAL_PATH 1095 CONFIGURE_COMMAND_LINE 1096 target_alias 1097 host_alias 1098 build_alias 1099 LIBS 1100 ECHO_T 1101 ECHO_N 1102 ECHO_C 1103 DEFS 1104 mandir 1105 localedir 1106 libdir 1107 psdir 1108 pdfdir 1109 dvidir 1110 htmldir 1111 infodir 1112 docdir 1113 oldincludedir 1114 includedir 1115 localstatedir 1116 sharedstatedir 1117 sysconfdir 1118 datadir 1119 datarootdir 1120 libexecdir 1121 sbindir 1122 bindir 1123 program_transform_name 1124 prefix 1125 exec_prefix 1126 PACKAGE_URL 1127 PACKAGE_BUGREPORT 1128 PACKAGE_STRING 1129 PACKAGE_VERSION 1130 PACKAGE_TARNAME 1131 PACKAGE_NAME 1132 PATH_SEPARATOR 1133 SHELL' 1134 ac_subst_files='' 1135 ac_user_opts=' 1136 enable_option_checking 1137 with_target_bits 1138 enable_openjdk_only 1139 with_custom_make_dir 1140 with_jdk_variant 1141 enable_debug 1142 with_debug_level 1143 with_jvm_variants 1144 with_devkit 1145 with_sys_root 1146 with_sysroot 1147 with_tools_dir 1148 with_toolchain_path 1149 with_extra_path 1150 with_sdk_name 1151 with_conf_name 1152 with_output_sync 1153 with_default_make_target 1154 enable_headless_only 1155 with_cacerts_file 1156 enable_unlimited_crypto 1157 with_copyright_year 1158 enable_keep_packaged_modules 1159 with_milestone 1160 with_update_version 1161 with_user_release_suffix 1162 with_build_number 1163 with_version_string 1164 with_version_pre 1165 with_version_opt 1166 with_version_build 1167 with_version_major 1168 with_version_minor 1169 with_version_security 1170 with_version_patch 1171 with_boot_jdk 1172 with_build_jdk 1173 with_add_source_root 1174 with_override_source_root 1175 with_adds_and_overrides 1176 with_override_langtools 1177 with_override_corba 1178 with_override_jaxp 1179 with_override_jaxws 1180 with_override_hotspot 1181 with_override_nashorn 1182 with_override_jdk 1183 with_import_hotspot 1184 with_import_modules 1185 enable_static_build 1186 with_toolchain_type 1187 with_extra_cflags 1188 with_extra_cxxflags 1189 with_extra_ldflags 1190 with_toolchain_version 1191 with_build_devkit 1192 with_jtreg 1193 enable_warnings_as_errors 1194 with_native_debug_symbols 1195 enable_debug_symbols 1196 enable_zip_debug_info 1197 enable_native_coverage 1198 enable_dtrace 1199 with_jvm_features 1200 with_jvm_interpreter 1201 enable_hotspot_gtest 1202 with_stdc__lib 1203 with_msvcr_dll 1204 with_msvcp_dll 1205 with_x 1206 with_cups 1207 with_cups_include 1208 with_freetype 1209 with_freetype_include 1210 with_freetype_lib 1211 with_freetype_src 1212 enable_freetype_bundling 1213 with_alsa 1214 with_alsa_include 1215 with_alsa_lib 1216 with_libffi 1217 with_libffi_include 1218 with_libffi_lib 1219 with_libjpeg 1220 with_giflib 1221 with_libpng 1222 with_zlib 1223 with_lcms 1224 with_dxsdk 1225 with_dxsdk_lib 1226 with_dxsdk_include 1227 enable_jtreg_failure_handler 1228 enable_generate_classlist 1229 with_num_cores 1230 with_memory_size 1231 with_jobs 1232 with_test_jobs 1233 with_boot_jdk_jvmargs 1234 with_sjavac_server_java 1235 enable_sjavac 1236 enable_javac_server 1237 enable_icecc 1238 enable_precompiled_headers 1239 enable_ccache 1240 with_ccache_dir 1241 ' 1242 ac_precious_vars='build_alias 1243 host_alias 1244 target_alias 1245 BASENAME 1246 BASH 1247 CAT 1248 CHMOD 1249 CMP 1250 COMM 1251 CP 1252 CUT 1253 DATE 1254 DIFF 1255 DIRNAME 1256 ECHO 1257 EXPR 1258 FILE 1259 FIND 1260 HEAD 1261 GUNZIP 1262 GZIP 1263 LN 1264 LS 1265 MKDIR 1266 MKTEMP 1267 MV 1268 NAWK 1269 PRINTF 1270 RM 1271 RMDIR 1272 SH 1273 SORT 1274 TAIL 1275 TAR 1276 TEE 1277 TOUCH 1278 TR 1279 UNAME 1280 UNIQ 1281 WC 1282 WHICH 1283 XARGS 1284 AWK 1285 GREP 1286 EGREP 1287 FGREP 1288 SED 1289 CYGPATH 1290 READLINK 1291 DF 1292 CPIO 1293 NICE 1294 MAKE 1295 UNZIP 1296 ZIP 1297 LDD 1298 OTOOL 1299 READELF 1300 HG 1301 STAT 1302 TIME 1303 DTRACE 1304 PATCH 1305 DSYMUTIL 1306 XATTR 1307 CODESIGN 1308 SETFILE 1309 PKG_CONFIG 1310 JAVA 1311 JAVAC 1312 JAVAH 1313 JAR 1314 JARSIGNER 1315 CC 1316 CFLAGS 1317 LDFLAGS 1318 LIBS 1319 CPPFLAGS 1320 CXX 1321 CXXFLAGS 1322 CCC 1323 CPP 1324 CXXCPP 1325 AS 1326 AR 1327 LIPO 1328 STRIP 1329 NM 1330 GNM 1331 OBJCOPY 1332 OBJDUMP 1333 BUILD_CC 1334 BUILD_CXX 1335 BUILD_NM 1336 BUILD_AR 1337 BUILD_OBJCOPY 1338 BUILD_STRIP 1339 JTREGEXE 1340 XMKMF 1341 FREETYPE_CFLAGS 1342 FREETYPE_LIBS 1343 ALSA_CFLAGS 1344 ALSA_LIBS 1345 LIBFFI_CFLAGS 1346 LIBFFI_LIBS 1347 PNG_CFLAGS 1348 PNG_LIBS 1349 LCMS_CFLAGS 1350 LCMS_LIBS 1351 ICECC_CMD 1352 ICECC_CREATE_ENV 1353 ICECC_WRAPPER 1354 CCACHE' 1355 1356 1357 # Initialize some variables set by options. 1358 ac_init_help= 1359 ac_init_version=false 1360 ac_unrecognized_opts= 1361 ac_unrecognized_sep= 1362 # The variables have the same names as the options, with 1363 # dashes changed to underlines. 1364 cache_file=/dev/null 1365 exec_prefix=NONE 1366 no_create= 1367 no_recursion= 1368 prefix=NONE 1369 program_prefix=NONE 1370 program_suffix=NONE 1371 program_transform_name=s,x,x, 1372 silent= 1373 site= 1374 srcdir= 1375 verbose= 1376 x_includes=NONE 1377 x_libraries=NONE 1378 1379 # Installation directory options. 1380 # These are left unexpanded so users can "make install exec_prefix=/foo" 1381 # and all the variables that are supposed to be based on exec_prefix 1382 # by default will actually change. 1383 # Use braces instead of parens because sh, perl, etc. also accept them. 1384 # (The list follows the same order as the GNU Coding Standards.) 1385 bindir='${exec_prefix}/bin' 1386 sbindir='${exec_prefix}/sbin' 1387 libexecdir='${exec_prefix}/libexec' 1388 datarootdir='${prefix}/share' 1389 datadir='${datarootdir}' 1390 sysconfdir='${prefix}/etc' 1391 sharedstatedir='${prefix}/com' 1392 localstatedir='${prefix}/var' 1393 includedir='${prefix}/include' 1394 oldincludedir='/usr/include' 1395 docdir='${datarootdir}/doc/${PACKAGE_TARNAME}' 1396 infodir='${datarootdir}/info' 1397 htmldir='${docdir}' 1398 dvidir='${docdir}' 1399 pdfdir='${docdir}' 1400 psdir='${docdir}' 1401 libdir='${exec_prefix}/lib' 1402 localedir='${datarootdir}/locale' 1403 mandir='${datarootdir}/man' 1404 1405 ac_prev= 1406 ac_dashdash= 1407 for ac_option 1408 do 1409 # If the previous option needs an argument, assign it. 1410 if test -n "$ac_prev"; then 1411 eval $ac_prev=\$ac_option 1412 ac_prev= 1413 continue 1414 fi 1415 1416 case $ac_option in 1417 *=?*) ac_optarg=`expr "X$ac_option" : '[^=]*=\(.*\)'` ;; 1418 *=) ac_optarg= ;; 1419 *) ac_optarg=yes ;; 1420 esac 1421 1422 # Accept the important Cygnus configure options, so we can diagnose typos. 1423 1424 case $ac_dashdash$ac_option in 1425 --) 1426 ac_dashdash=yes ;; 1427 1428 -bindir | --bindir | --bindi | --bind | --bin | --bi) 1429 ac_prev=bindir ;; 1430 -bindir=* | --bindir=* | --bindi=* | --bind=* | --bin=* | --bi=*) 1431 bindir=$ac_optarg ;; 1432 1433 -build | --build | --buil | --bui | --bu) 1434 ac_prev=build_alias ;; 1435 -build=* | --build=* | --buil=* | --bui=* | --bu=*) 1436 build_alias=$ac_optarg ;; 1437 1438 -cache-file | --cache-file | --cache-fil | --cache-fi \ 1439 | --cache-f | --cache- | --cache | --cach | --cac | --ca | --c) 1440 ac_prev=cache_file ;; 1441 -cache-file=* | --cache-file=* | --cache-fil=* | --cache-fi=* \ 1442 | --cache-f=* | --cache-=* | --cache=* | --cach=* | --cac=* | --ca=* | --c=*) 1443 cache_file=$ac_optarg ;; 1444 1445 --config-cache | -C) 1446 cache_file=config.cache ;; 1447 1448 -datadir | --datadir | --datadi | --datad) 1449 ac_prev=datadir ;; 1450 -datadir=* | --datadir=* | --datadi=* | --datad=*) 1451 datadir=$ac_optarg ;; 1452 1453 -datarootdir | --datarootdir | --datarootdi | --datarootd | --dataroot \ 1454 | --dataroo | --dataro | --datar) 1455 ac_prev=datarootdir ;; 1456 -datarootdir=* | --datarootdir=* | --datarootdi=* | --datarootd=* \ 1457 | --dataroot=* | --dataroo=* | --dataro=* | --datar=*) 1458 datarootdir=$ac_optarg ;; 1459 1460 -disable-* | --disable-*) 1461 ac_useropt=`expr "x$ac_option" : 'x-*disable-\(.*\)'` 1462 # Reject names that are not valid shell variable names. 1463 expr "x$ac_useropt" : ".*[^-+._$as_cr_alnum]" >/dev/null && 1464 as_fn_error $? "invalid feature name: $ac_useropt" 1465 ac_useropt_orig=$ac_useropt 1466 ac_useropt=`$as_echo "$ac_useropt" | sed 's/[-+.]/_/g'` 1467 case $ac_user_opts in 1468 *" 1469 "enable_$ac_useropt" 1470 "*) ;; 1471 *) ac_unrecognized_opts="$ac_unrecognized_opts$ac_unrecognized_sep--disable-$ac_useropt_orig" 1472 ac_unrecognized_sep=', ';; 1473 esac 1474 eval enable_$ac_useropt=no ;; 1475 1476 -docdir | --docdir | --docdi | --doc | --do) 1477 ac_prev=docdir ;; 1478 -docdir=* | --docdir=* | --docdi=* | --doc=* | --do=*) 1479 docdir=$ac_optarg ;; 1480 1481 -dvidir | --dvidir | --dvidi | --dvid | --dvi | --dv) 1482 ac_prev=dvidir ;; 1483 -dvidir=* | --dvidir=* | --dvidi=* | --dvid=* | --dvi=* | --dv=*) 1484 dvidir=$ac_optarg ;; 1485 1486 -enable-* | --enable-*) 1487 ac_useropt=`expr "x$ac_option" : 'x-*enable-\([^=]*\)'` 1488 # Reject names that are not valid shell variable names. 1489 expr "x$ac_useropt" : ".*[^-+._$as_cr_alnum]" >/dev/null && 1490 as_fn_error $? "invalid feature name: $ac_useropt" 1491 ac_useropt_orig=$ac_useropt 1492 ac_useropt=`$as_echo "$ac_useropt" | sed 's/[-+.]/_/g'` 1493 case $ac_user_opts in 1494 *" 1495 "enable_$ac_useropt" 1496 "*) ;; 1497 *) ac_unrecognized_opts="$ac_unrecognized_opts$ac_unrecognized_sep--enable-$ac_useropt_orig" 1498 ac_unrecognized_sep=', ';; 1499 esac 1500 eval enable_$ac_useropt=\$ac_optarg ;; 1501 1502 -exec-prefix | --exec_prefix | --exec-prefix | --exec-prefi \ 1503 | --exec-pref | --exec-pre | --exec-pr | --exec-p | --exec- \ 1504 | --exec | --exe | --ex) 1505 ac_prev=exec_prefix ;; 1506 -exec-prefix=* | --exec_prefix=* | --exec-prefix=* | --exec-prefi=* \ 1507 | --exec-pref=* | --exec-pre=* | --exec-pr=* | --exec-p=* | --exec-=* \ 1508 | --exec=* | --exe=* | --ex=*) 1509 exec_prefix=$ac_optarg ;; 1510 1511 -gas | --gas | --ga | --g) 1512 # Obsolete; use --with-gas. 1513 with_gas=yes ;; 1514 1515 -help | --help | --hel | --he | -h) 1516 ac_init_help=long ;; 1517 -help=r* | --help=r* | --hel=r* | --he=r* | -hr*) 1518 ac_init_help=recursive ;; 1519 -help=s* | --help=s* | --hel=s* | --he=s* | -hs*) 1520 ac_init_help=short ;; 1521 1522 -host | --host | --hos | --ho) 1523 ac_prev=host_alias ;; 1524 -host=* | --host=* | --hos=* | --ho=*) 1525 host_alias=$ac_optarg ;; 1526 1527 -htmldir | --htmldir | --htmldi | --htmld | --html | --htm | --ht) 1528 ac_prev=htmldir ;; 1529 -htmldir=* | --htmldir=* | --htmldi=* | --htmld=* | --html=* | --htm=* \ 1530 | --ht=*) 1531 htmldir=$ac_optarg ;; 1532 1533 -includedir | --includedir | --includedi | --included | --include \ 1534 | --includ | --inclu | --incl | --inc) 1535 ac_prev=includedir ;; 1536 -includedir=* | --includedir=* | --includedi=* | --included=* | --include=* \ 1537 | --includ=* | --inclu=* | --incl=* | --inc=*) 1538 includedir=$ac_optarg ;; 1539 1540 -infodir | --infodir | --infodi | --infod | --info | --inf) 1541 ac_prev=infodir ;; 1542 -infodir=* | --infodir=* | --infodi=* | --infod=* | --info=* | --inf=*) 1543 infodir=$ac_optarg ;; 1544 1545 -libdir | --libdir | --libdi | --libd) 1546 ac_prev=libdir ;; 1547 -libdir=* | --libdir=* | --libdi=* | --libd=*) 1548 libdir=$ac_optarg ;; 1549 1550 -libexecdir | --libexecdir | --libexecdi | --libexecd | --libexec \ 1551 | --libexe | --libex | --libe) 1552 ac_prev=libexecdir ;; 1553 -libexecdir=* | --libexecdir=* | --libexecdi=* | --libexecd=* | --libexec=* \ 1554 | --libexe=* | --libex=* | --libe=*) 1555 libexecdir=$ac_optarg ;; 1556 1557 -localedir | --localedir | --localedi | --localed | --locale) 1558 ac_prev=localedir ;; 1559 -localedir=* | --localedir=* | --localedi=* | --localed=* | --locale=*) 1560 localedir=$ac_optarg ;; 1561 1562 -localstatedir | --localstatedir | --localstatedi | --localstated \ 1563 | --localstate | --localstat | --localsta | --localst | --locals) 1564 ac_prev=localstatedir ;; 1565 -localstatedir=* | --localstatedir=* | --localstatedi=* | --localstated=* \ 1566 | --localstate=* | --localstat=* | --localsta=* | --localst=* | --locals=*) 1567 localstatedir=$ac_optarg ;; 1568 1569 -mandir | --mandir | --mandi | --mand | --man | --ma | --m) 1570 ac_prev=mandir ;; 1571 -mandir=* | --mandir=* | --mandi=* | --mand=* | --man=* | --ma=* | --m=*) 1572 mandir=$ac_optarg ;; 1573 1574 -nfp | --nfp | --nf) 1575 # Obsolete; use --without-fp. 1576 with_fp=no ;; 1577 1578 -no-create | --no-create | --no-creat | --no-crea | --no-cre \ 1579 | --no-cr | --no-c | -n) 1580 no_create=yes ;; 1581 1582 -no-recursion | --no-recursion | --no-recursio | --no-recursi \ 1583 | --no-recurs | --no-recur | --no-recu | --no-rec | --no-re | --no-r) 1584 no_recursion=yes ;; 1585 1586 -oldincludedir | --oldincludedir | --oldincludedi | --oldincluded \ 1587 | --oldinclude | --oldinclud | --oldinclu | --oldincl | --oldinc \ 1588 | --oldin | --oldi | --old | --ol | --o) 1589 ac_prev=oldincludedir ;; 1590 -oldincludedir=* | --oldincludedir=* | --oldincludedi=* | --oldincluded=* \ 1591 | --oldinclude=* | --oldinclud=* | --oldinclu=* | --oldincl=* | --oldinc=* \ 1592 | --oldin=* | --oldi=* | --old=* | --ol=* | --o=*) 1593 oldincludedir=$ac_optarg ;; 1594 1595 -prefix | --prefix | --prefi | --pref | --pre | --pr | --p) 1596 ac_prev=prefix ;; 1597 -prefix=* | --prefix=* | --prefi=* | --pref=* | --pre=* | --pr=* | --p=*) 1598 prefix=$ac_optarg ;; 1599 1600 -program-prefix | --program-prefix | --program-prefi | --program-pref \ 1601 | --program-pre | --program-pr | --program-p) 1602 ac_prev=program_prefix ;; 1603 -program-prefix=* | --program-prefix=* | --program-prefi=* \ 1604 | --program-pref=* | --program-pre=* | --program-pr=* | --program-p=*) 1605 program_prefix=$ac_optarg ;; 1606 1607 -program-suffix | --program-suffix | --program-suffi | --program-suff \ 1608 | --program-suf | --program-su | --program-s) 1609 ac_prev=program_suffix ;; 1610 -program-suffix=* | --program-suffix=* | --program-suffi=* \ 1611 | --program-suff=* | --program-suf=* | --program-su=* | --program-s=*) 1612 program_suffix=$ac_optarg ;; 1613 1614 -program-transform-name | --program-transform-name \ 1615 | --program-transform-nam | --program-transform-na \ 1616 | --program-transform-n | --program-transform- \ 1617 | --program-transform | --program-transfor \ 1618 | --program-transfo | --program-transf \ 1619 | --program-trans | --program-tran \ 1620 | --progr-tra | --program-tr | --program-t) 1621 ac_prev=program_transform_name ;; 1622 -program-transform-name=* | --program-transform-name=* \ 1623 | --program-transform-nam=* | --program-transform-na=* \ 1624 | --program-transform-n=* | --program-transform-=* \ 1625 | --program-transform=* | --program-transfor=* \ 1626 | --program-transfo=* | --program-transf=* \ 1627 | --program-trans=* | --program-tran=* \ 1628 | --progr-tra=* | --program-tr=* | --program-t=*) 1629 program_transform_name=$ac_optarg ;; 1630 1631 -pdfdir | --pdfdir | --pdfdi | --pdfd | --pdf | --pd) 1632 ac_prev=pdfdir ;; 1633 -pdfdir=* | --pdfdir=* | --pdfdi=* | --pdfd=* | --pdf=* | --pd=*) 1634 pdfdir=$ac_optarg ;; 1635 1636 -psdir | --psdir | --psdi | --psd | --ps) 1637 ac_prev=psdir ;; 1638 -psdir=* | --psdir=* | --psdi=* | --psd=* | --ps=*) 1639 psdir=$ac_optarg ;; 1640 1641 -q | -quiet | --quiet | --quie | --qui | --qu | --q \ 1642 | -silent | --silent | --silen | --sile | --sil) 1643 silent=yes ;; 1644 1645 -sbindir | --sbindir | --sbindi | --sbind | --sbin | --sbi | --sb) 1646 ac_prev=sbindir ;; 1647 -sbindir=* | --sbindir=* | --sbindi=* | --sbind=* | --sbin=* \ 1648 | --sbi=* | --sb=*) 1649 sbindir=$ac_optarg ;; 1650 1651 -sharedstatedir | --sharedstatedir | --sharedstatedi \ 1652 | --sharedstated | --sharedstate | --sharedstat | --sharedsta \ 1653 | --sharedst | --shareds | --shared | --share | --shar \ 1654 | --sha | --sh) 1655 ac_prev=sharedstatedir ;; 1656 -sharedstatedir=* | --sharedstatedir=* | --sharedstatedi=* \ 1657 | --sharedstated=* | --sharedstate=* | --sharedstat=* | --sharedsta=* \ 1658 | --sharedst=* | --shareds=* | --shared=* | --share=* | --shar=* \ 1659 | --sha=* | --sh=*) 1660 sharedstatedir=$ac_optarg ;; 1661 1662 -site | --site | --sit) 1663 ac_prev=site ;; 1664 -site=* | --site=* | --sit=*) 1665 site=$ac_optarg ;; 1666 1667 -srcdir | --srcdir | --srcdi | --srcd | --src | --sr) 1668 ac_prev=srcdir ;; 1669 -srcdir=* | --srcdir=* | --srcdi=* | --srcd=* | --src=* | --sr=*) 1670 srcdir=$ac_optarg ;; 1671 1672 -sysconfdir | --sysconfdir | --sysconfdi | --sysconfd | --sysconf \ 1673 | --syscon | --sysco | --sysc | --sys | --sy) 1674 ac_prev=sysconfdir ;; 1675 -sysconfdir=* | --sysconfdir=* | --sysconfdi=* | --sysconfd=* | --sysconf=* \ 1676 | --syscon=* | --sysco=* | --sysc=* | --sys=* | --sy=*) 1677 sysconfdir=$ac_optarg ;; 1678 1679 -target | --target | --targe | --targ | --tar | --ta | --t) 1680 ac_prev=target_alias ;; 1681 -target=* | --target=* | --targe=* | --targ=* | --tar=* | --ta=* | --t=*) 1682 target_alias=$ac_optarg ;; 1683 1684 -v | -verbose | --verbose | --verbos | --verbo | --verb) 1685 verbose=yes ;; 1686 1687 -version | --version | --versio | --versi | --vers | -V) 1688 ac_init_version=: ;; 1689 1690 -with-* | --with-*) 1691 ac_useropt=`expr "x$ac_option" : 'x-*with-\([^=]*\)'` 1692 # Reject names that are not valid shell variable names. 1693 expr "x$ac_useropt" : ".*[^-+._$as_cr_alnum]" >/dev/null && 1694 as_fn_error $? "invalid package name: $ac_useropt" 1695 ac_useropt_orig=$ac_useropt 1696 ac_useropt=`$as_echo "$ac_useropt" | sed 's/[-+.]/_/g'` 1697 case $ac_user_opts in 1698 *" 1699 "with_$ac_useropt" 1700 "*) ;; 1701 *) ac_unrecognized_opts="$ac_unrecognized_opts$ac_unrecognized_sep--with-$ac_useropt_orig" 1702 ac_unrecognized_sep=', ';; 1703 esac 1704 eval with_$ac_useropt=\$ac_optarg ;; 1705 1706 -without-* | --without-*) 1707 ac_useropt=`expr "x$ac_option" : 'x-*without-\(.*\)'` 1708 # Reject names that are not valid shell variable names. 1709 expr "x$ac_useropt" : ".*[^-+._$as_cr_alnum]" >/dev/null && 1710 as_fn_error $? "invalid package name: $ac_useropt" 1711 ac_useropt_orig=$ac_useropt 1712 ac_useropt=`$as_echo "$ac_useropt" | sed 's/[-+.]/_/g'` 1713 case $ac_user_opts in 1714 *" 1715 "with_$ac_useropt" 1716 "*) ;; 1717 *) ac_unrecognized_opts="$ac_unrecognized_opts$ac_unrecognized_sep--without-$ac_useropt_orig" 1718 ac_unrecognized_sep=', ';; 1719 esac 1720 eval with_$ac_useropt=no ;; 1721 1722 --x) 1723 # Obsolete; use --with-x. 1724 with_x=yes ;; 1725 1726 -x-includes | --x-includes | --x-include | --x-includ | --x-inclu \ 1727 | --x-incl | --x-inc | --x-in | --x-i) 1728 ac_prev=x_includes ;; 1729 -x-includes=* | --x-includes=* | --x-include=* | --x-includ=* | --x-inclu=* \ 1730 | --x-incl=* | --x-inc=* | --x-in=* | --x-i=*) 1731 x_includes=$ac_optarg ;; 1732 1733 -x-libraries | --x-libraries | --x-librarie | --x-librari \ 1734 | --x-librar | --x-libra | --x-libr | --x-lib | --x-li | --x-l) 1735 ac_prev=x_libraries ;; 1736 -x-libraries=* | --x-libraries=* | --x-librarie=* | --x-librari=* \ 1737 | --x-librar=* | --x-libra=* | --x-libr=* | --x-lib=* | --x-li=* | --x-l=*) 1738 x_libraries=$ac_optarg ;; 1739 1740 -*) as_fn_error $? "unrecognized option: \`$ac_option' 1741 Try \`$0 --help' for more information" 1742 ;; 1743 1744 *=*) 1745 ac_envvar=`expr "x$ac_option" : 'x\([^=]*\)='` 1746 # Reject names that are not valid shell variable names. 1747 case $ac_envvar in #( 1748 '' | [0-9]* | *[!_$as_cr_alnum]* ) 1749 as_fn_error $? "invalid variable name: \`$ac_envvar'" ;; 1750 esac 1751 eval $ac_envvar=\$ac_optarg 1752 export $ac_envvar ;; 1753 1754 *) 1755 # FIXME: should be removed in autoconf 3.0. 1756 $as_echo "$as_me: WARNING: you should use --build, --host, --target" >&2 1757 expr "x$ac_option" : ".*[^-._$as_cr_alnum]" >/dev/null && 1758 $as_echo "$as_me: WARNING: invalid host type: $ac_option" >&2 1759 : "${build_alias=$ac_option} ${host_alias=$ac_option} ${target_alias=$ac_option}" 1760 ;; 1761 1762 esac 1763 done 1764 1765 if test -n "$ac_prev"; then 1766 ac_option=--`echo $ac_prev | sed 's/_/-/g'` 1767 as_fn_error $? "missing argument to $ac_option" 1768 fi 1769 1770 if test -n "$ac_unrecognized_opts"; then 1771 case $enable_option_checking in 1772 no) ;; 1773 fatal) as_fn_error $? "unrecognized options: $ac_unrecognized_opts" ;; 1774 *) $as_echo "$as_me: WARNING: unrecognized options: $ac_unrecognized_opts" >&2 ;; 1775 esac 1776 fi 1777 1778 # Check all directory arguments for consistency. 1779 for ac_var in exec_prefix prefix bindir sbindir libexecdir datarootdir \ 1780 datadir sysconfdir sharedstatedir localstatedir includedir \ 1781 oldincludedir docdir infodir htmldir dvidir pdfdir psdir \ 1782 libdir localedir mandir 1783 do 1784 eval ac_val=\$$ac_var 1785 # Remove trailing slashes. 1786 case $ac_val in 1787 */ ) 1788 ac_val=`expr "X$ac_val" : 'X\(.*[^/]\)' \| "X$ac_val" : 'X\(.*\)'` 1789 eval $ac_var=\$ac_val;; 1790 esac 1791 # Be sure to have absolute directory names. 1792 case $ac_val in 1793 [\\/$]* | ?:[\\/]* ) continue;; 1794 NONE | '' ) case $ac_var in *prefix ) continue;; esac;; 1795 esac 1796 as_fn_error $? "expected an absolute directory name for --$ac_var: $ac_val" 1797 done 1798 1799 # There might be people who depend on the old broken behavior: `$host' 1800 # used to hold the argument of --host etc. 1801 # FIXME: To remove some day. 1802 build=$build_alias 1803 host=$host_alias 1804 target=$target_alias 1805 1806 # FIXME: To remove some day. 1807 if test "x$host_alias" != x; then 1808 if test "x$build_alias" = x; then 1809 cross_compiling=maybe 1810 elif test "x$build_alias" != "x$host_alias"; then 1811 cross_compiling=yes 1812 fi 1813 fi 1814 1815 ac_tool_prefix= 1816 test -n "$host_alias" && ac_tool_prefix=$host_alias- 1817 1818 test "$silent" = yes && exec 6>/dev/null 1819 1820 1821 ac_pwd=`pwd` && test -n "$ac_pwd" && 1822 ac_ls_di=`ls -di .` && 1823 ac_pwd_ls_di=`cd "$ac_pwd" && ls -di .` || 1824 as_fn_error $? "working directory cannot be determined" 1825 test "X$ac_ls_di" = "X$ac_pwd_ls_di" || 1826 as_fn_error $? "pwd does not report name of working directory" 1827 1828 1829 # Find the source files, if location was not specified. 1830 if test -z "$srcdir"; then 1831 ac_srcdir_defaulted=yes 1832 # Try the directory containing this script, then the parent directory. 1833 ac_confdir=`$as_dirname -- "$as_myself" || 1834 $as_expr X"$as_myself" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \ 1835 X"$as_myself" : 'X\(//\)[^/]' \| \ 1836 X"$as_myself" : 'X\(//\)$' \| \ 1837 X"$as_myself" : 'X\(/\)' \| . 2>/dev/null || 1838 $as_echo X"$as_myself" | 1839 sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{ 1840 s//\1/ 1841 q 1842 } 1843 /^X\(\/\/\)[^/].*/{ 1844 s//\1/ 1845 q 1846 } 1847 /^X\(\/\/\)$/{ 1848 s//\1/ 1849 q 1850 } 1851 /^X\(\/\).*/{ 1852 s//\1/ 1853 q 1854 } 1855 s/.*/./; q'` 1856 srcdir=$ac_confdir 1857 if test ! -r "$srcdir/$ac_unique_file"; then 1858 srcdir=.. 1859 fi 1860 else 1861 ac_srcdir_defaulted=no 1862 fi 1863 if test ! -r "$srcdir/$ac_unique_file"; then 1864 test "$ac_srcdir_defaulted" = yes && srcdir="$ac_confdir or .." 1865 as_fn_error $? "cannot find sources ($ac_unique_file) in $srcdir" 1866 fi 1867 ac_msg="sources are in $srcdir, but \`cd $srcdir' does not work" 1868 ac_abs_confdir=`( 1869 cd "$srcdir" && test -r "./$ac_unique_file" || as_fn_error $? "$ac_msg" 1870 pwd)` 1871 # When building in place, set srcdir=. 1872 if test "$ac_abs_confdir" = "$ac_pwd"; then 1873 srcdir=. 1874 fi 1875 # Remove unnecessary trailing slashes from srcdir. 1876 # Double slashes in file names in object file debugging info 1877 # mess up M-x gdb in Emacs. 1878 case $srcdir in 1879 */) srcdir=`expr "X$srcdir" : 'X\(.*[^/]\)' \| "X$srcdir" : 'X\(.*\)'`;; 1880 esac 1881 for ac_var in $ac_precious_vars; do 1882 eval ac_env_${ac_var}_set=\${${ac_var}+set} 1883 eval ac_env_${ac_var}_value=\$${ac_var} 1884 eval ac_cv_env_${ac_var}_set=\${${ac_var}+set} 1885 eval ac_cv_env_${ac_var}_value=\$${ac_var} 1886 done 1887 1888 # 1889 # Report the --help message. 1890 # 1891 if test "$ac_init_help" = "long"; then 1892 # Omit some internal or obsolete options to make the list less imposing. 1893 # This message is too long to be a string in the A/UX 3.1 sh. 1894 cat <<_ACEOF 1895 \`configure' configures OpenJDK jdk9 to adapt to many kinds of systems. 1896 1897 Usage: $0 [OPTION]... [VAR=VALUE]... 1898 1899 To assign environment variables (e.g., CC, CFLAGS...), specify them as 1900 VAR=VALUE. See below for descriptions of some of the useful variables. 1901 1902 Defaults for the options are specified in brackets. 1903 1904 Configuration: 1905 -h, --help display this help and exit 1906 --help=short display options specific to this package 1907 --help=recursive display the short help of all the included packages 1908 -V, --version display version information and exit 1909 -q, --quiet, --silent do not print \`checking ...' messages 1910 --cache-file=FILE cache test results in FILE [disabled] 1911 -C, --config-cache alias for \`--cache-file=config.cache' 1912 -n, --no-create do not create output files 1913 --srcdir=DIR find the sources in DIR [configure dir or \`..'] 1914 1915 Installation directories: 1916 --prefix=PREFIX install architecture-independent files in PREFIX 1917 [$ac_default_prefix] 1918 --exec-prefix=EPREFIX install architecture-dependent files in EPREFIX 1919 [PREFIX] 1920 1921 By default, \`make install' will install all the files in 1922 \`$ac_default_prefix/bin', \`$ac_default_prefix/lib' etc. You can specify 1923 an installation prefix other than \`$ac_default_prefix' using \`--prefix', 1924 for instance \`--prefix=\$HOME'. 1925 1926 For better control, use the options below. 1927 1928 Fine tuning of the installation directories: 1929 --bindir=DIR user executables [EPREFIX/bin] 1930 --sbindir=DIR system admin executables [EPREFIX/sbin] 1931 --libexecdir=DIR program executables [EPREFIX/libexec] 1932 --sysconfdir=DIR read-only single-machine data [PREFIX/etc] 1933 --sharedstatedir=DIR modifiable architecture-independent data [PREFIX/com] 1934 --localstatedir=DIR modifiable single-machine data [PREFIX/var] 1935 --libdir=DIR object code libraries [EPREFIX/lib] 1936 --includedir=DIR C header files [PREFIX/include] 1937 --oldincludedir=DIR C header files for non-gcc [/usr/include] 1938 --datarootdir=DIR read-only arch.-independent data root [PREFIX/share] 1939 --datadir=DIR read-only architecture-independent data [DATAROOTDIR] 1940 --infodir=DIR info documentation [DATAROOTDIR/info] 1941 --localedir=DIR locale-dependent data [DATAROOTDIR/locale] 1942 --mandir=DIR man documentation [DATAROOTDIR/man] 1943 --docdir=DIR documentation root [DATAROOTDIR/doc/openjdk] 1944 --htmldir=DIR html documentation [DOCDIR] 1945 --dvidir=DIR dvi documentation [DOCDIR] 1946 --pdfdir=DIR pdf documentation [DOCDIR] 1947 --psdir=DIR ps documentation [DOCDIR] 1948 _ACEOF 1949 1950 cat <<\_ACEOF 1951 1952 X features: 1953 --x-includes=DIR X include files are in DIR 1954 --x-libraries=DIR X library files are in DIR 1955 1956 System types: 1957 --build=BUILD configure for building on BUILD [guessed] 1958 --host=HOST cross-compile to build programs to run on HOST [BUILD] 1959 --target=TARGET configure for building compilers for TARGET [HOST] 1960 _ACEOF 1961 fi 1962 1963 if test -n "$ac_init_help"; then 1964 case $ac_init_help in 1965 short | recursive ) echo "Configuration of OpenJDK jdk9:";; 1966 esac 1967 cat <<\_ACEOF 1968 1969 Optional Features: 1970 --disable-option-checking ignore unrecognized --enable/--with options 1971 --disable-FEATURE do not include FEATURE (same as --enable-FEATURE=no) 1972 --enable-FEATURE[=ARG] include FEATURE [ARG=yes] 1973 --enable-openjdk-only suppress building custom source even if present 1974 [disabled] 1975 --enable-debug set the debug level to fastdebug (shorthand for 1976 --with-debug-level=fastdebug) [disabled] 1977 --enable-headless-only only build headless (no GUI) support [disabled] 1978 --enable-unlimited-crypto 1979 Enable unlimited crypto policy [disabled] 1980 --disable-keep-packaged-modules 1981 Do not keep packaged modules in jdk image [enable] 1982 --enable-static-build enable static library build [disabled] 1983 --disable-warnings-as-errors 1984 do not consider native warnings to be an error 1985 [enabled] 1986 --enable-debug-symbols Deprecated. Option is kept for backwards 1987 compatibility and is ignored 1988 --enable-zip-debug-info Deprecated. Option is kept for backwards 1989 compatibility and is ignored 1990 --enable-native-coverage 1991 enable native compilation with code coverage 1992 data[disabled] 1993 --enable-dtrace[=yes/no/auto] 1994 enable dtrace. Default is auto, where dtrace is 1995 enabled if all dependencies are present. 1996 --disable-hotspot-gtest Disables building of the Hotspot unit tests 1997 --disable-freetype-bundling 1998 disable bundling of the freetype library with the 1999 build result [enabled on Windows or when using 2000 --with-freetype, disabled otherwise] 2001 --enable-jtreg-failure-handler 2002 forces build of the jtreg failure handler to be 2003 enabled, missing dependencies become fatal errors. 2004 Default is auto, where the failure handler is built 2005 if all dependencies are present and otherwise just 2006 disabled. 2007 --disable-generate-classlist 2008 forces enabling or disabling of the generation of a 2009 CDS classlist at build time. Default is to generate 2010 it when either the server or client JVMs are built. 2011 --enable-sjavac use sjavac to do fast incremental compiles 2012 [disabled] 2013 --disable-javac-server disable javac server [enabled] 2014 --enable-icecc enable distribted compilation of native code using 2015 icecc/icecream [disabled] 2016 --disable-precompiled-headers 2017 disable using precompiled headers when compiling C++ 2018 [enabled] 2019 --enable-ccache enable using ccache to speed up recompilations 2020 [disabled] 2021 2022 Optional Packages: 2023 --with-PACKAGE[=ARG] use PACKAGE [ARG=yes] 2024 --without-PACKAGE do not use PACKAGE (same as --with-PACKAGE=no) 2025 --with-target-bits build 32-bit or 64-bit binaries (for platforms that 2026 support it), e.g. --with-target-bits=32 [guessed] 2027 --with-custom-make-dir Deprecated. Option is kept for backwards 2028 compatibility and is ignored 2029 --with-jdk-variant JDK variant to build (normal) [normal] 2030 --with-debug-level set the debug level (release, fastdebug, slowdebug, 2031 optimized) [release] 2032 --with-jvm-variants JVM variants (separated by commas) to build 2033 (server,client,minimal,core,zero,zeroshark,custom) 2034 [server] 2035 --with-devkit use this devkit for compilers, tools and resources 2036 --with-sys-root alias for --with-sysroot for backwards compatability 2037 --with-sysroot use this directory as sysroot 2038 --with-tools-dir alias for --with-toolchain-path for backwards 2039 compatibility 2040 --with-toolchain-path prepend these directories when searching for 2041 toolchain binaries (compilers etc) 2042 --with-extra-path prepend these directories to the default path 2043 --with-sdk-name use the platform SDK of the given name. [macosx] 2044 --with-conf-name use this as the name of the configuration [generated 2045 from important configuration options] 2046 --with-output-sync set make output sync type if supported by make. 2047 [recurse] 2048 --with-default-make-target 2049 set the default make target [exploded-image] 2050 --with-cacerts-file specify alternative cacerts file 2051 --with-copyright-year Set copyright year value for build [current year] 2052 --with-milestone Deprecated. Option is kept for backwards 2053 compatibility and is ignored 2054 --with-update-version Deprecated. Option is kept for backwards 2055 compatibility and is ignored 2056 --with-user-release-suffix 2057 Deprecated. Option is kept for backwards 2058 compatibility and is ignored 2059 --with-build-number Deprecated. Option is kept for backwards 2060 compatibility and is ignored 2061 --with-version-string Set version string [calculated] 2062 --with-version-pre Set the base part of the version 'PRE' field 2063 (pre-release identifier) ['internal'] 2064 --with-version-opt Set version 'OPT' field (build metadata) 2065 [<timestamp>.<user>.<dirname>] 2066 --with-version-build Set version 'BUILD' field (build number) [not 2067 specified] 2068 --with-version-major Set version 'MAJOR' field (first number) [current 2069 source value] 2070 --with-version-minor Set version 'MINOR' field (second number) [current 2071 source value] 2072 --with-version-security Set version 'SECURITY' field (third number) [current 2073 source value] 2074 --with-version-patch Set version 'PATCH' field (fourth number) [not 2075 specified] 2076 --with-boot-jdk path to Boot JDK (used to bootstrap build) [probed] 2077 --with-build-jdk path to JDK of same version as is being built[the 2078 newly built JDK] 2079 --with-add-source-root Deprecated. Option is kept for backwards 2080 compatibility and is ignored 2081 --with-override-source-root 2082 Deprecated. Option is kept for backwards 2083 compatibility and is ignored 2084 --with-adds-and-overrides 2085 Deprecated. Option is kept for backwards 2086 compatibility and is ignored 2087 --with-override-langtools 2088 Deprecated. Option is kept for backwards 2089 compatibility and is ignored 2090 --with-override-corba Deprecated. Option is kept for backwards 2091 compatibility and is ignored 2092 --with-override-jaxp Deprecated. Option is kept for backwards 2093 compatibility and is ignored 2094 --with-override-jaxws Deprecated. Option is kept for backwards 2095 compatibility and is ignored 2096 --with-override-hotspot Deprecated. Option is kept for backwards 2097 compatibility and is ignored 2098 --with-override-nashorn Deprecated. Option is kept for backwards 2099 compatibility and is ignored 2100 --with-override-jdk Deprecated. Option is kept for backwards 2101 compatibility and is ignored 2102 --with-import-hotspot import hotspot binaries from this jdk image or 2103 hotspot build dist dir instead of building from 2104 source 2105 --with-import-modules import a set of prebuilt modules either as a zip 2106 file or an exploded directory 2107 --with-toolchain-type the toolchain type (or family) to use, use '--help' 2108 to show possible values [platform dependent] 2109 --with-extra-cflags extra flags to be used when compiling jdk c-files 2110 --with-extra-cxxflags extra flags to be used when compiling jdk c++-files 2111 --with-extra-ldflags extra flags to be used when linking jdk 2112 --with-toolchain-version 2113 the version of the toolchain to look for, use 2114 '--help' to show possible values [platform 2115 dependent] 2116 --with-build-devkit Devkit to use for the build platform toolchain 2117 --with-jtreg Regression Test Harness [probed] 2118 --with-native-debug-symbols 2119 set the native debug symbol configuration (none, 2120 internal, external, zipped) [varying] 2121 --with-jvm-features additional JVM features to enable (separated by 2122 comma), use '--help' to show possible values [none] 2123 --with-jvm-interpreter Deprecated. Option is kept for backwards 2124 compatibility and is ignored 2125 --with-stdc++lib=<static>,<dynamic>,<default> 2126 force linking of the C++ runtime on Linux to either 2127 static or dynamic, default is static with dynamic as 2128 fallback 2129 --with-msvcr-dll path to microsoft C runtime dll (msvcr*.dll) 2130 (Windows only) [probed] 2131 --with-msvcp-dll path to microsoft C++ runtime dll (msvcp*.dll) 2132 (Windows only) [probed] 2133 --with-x use the X Window System 2134 --with-cups specify prefix directory for the cups package 2135 (expecting the headers under PATH/include) 2136 --with-cups-include specify directory for the cups include files 2137 --with-freetype specify prefix directory for the freetype package 2138 (expecting the libraries under PATH/lib and the 2139 headers under PATH/include) 2140 --with-freetype-include specify directory for the freetype include files 2141 --with-freetype-lib specify directory for the freetype library 2142 --with-freetype-src specify directory with freetype sources to 2143 automatically build the library (experimental, 2144 Windows-only) 2145 --with-alsa specify prefix directory for the alsa package 2146 (expecting the libraries under PATH/lib and the 2147 headers under PATH/include) 2148 --with-alsa-include specify directory for the alsa include files 2149 --with-alsa-lib specify directory for the alsa library 2150 --with-libffi specify prefix directory for the libffi package 2151 (expecting the libraries under PATH/lib and the 2152 headers under PATH/include) 2153 --with-libffi-include specify directory for the libffi include files 2154 --with-libffi-lib specify directory for the libffi library 2155 --with-libjpeg use libjpeg from build system or OpenJDK source 2156 (system, bundled) [bundled] 2157 --with-giflib use giflib from build system or OpenJDK source 2158 (system, bundled) [bundled] 2159 --with-libpng use libpng from build system or OpenJDK source 2160 (system, bundled) [bundled] 2161 --with-zlib use zlib from build system or OpenJDK source 2162 (system, bundled) [bundled] 2163 --with-lcms use lcms2 from build system or OpenJDK source 2164 (system, bundled) [bundled] 2165 --with-dxsdk Deprecated. Option is kept for backwards 2166 compatibility and is ignored 2167 --with-dxsdk-lib Deprecated. Option is kept for backwards 2168 compatibility and is ignored 2169 --with-dxsdk-include Deprecated. Option is kept for backwards 2170 compatibility and is ignored 2171 --with-num-cores number of cores in the build system, e.g. 2172 --with-num-cores=8 [probed] 2173 --with-memory-size memory (in MB) available in the build system, e.g. 2174 --with-memory-size=1024 [probed] 2175 --with-jobs number of parallel jobs to let make run [calculated 2176 based on cores and memory] 2177 --with-test-jobs number of parallel tests jobs to run [based on build 2178 jobs] 2179 --with-boot-jdk-jvmargs specify JVM arguments to be passed to all java 2180 invocations of boot JDK, overriding the default 2181 values, e.g --with-boot-jdk-jvmargs="-Xmx8G 2182 -enableassertions" 2183 --with-sjavac-server-java 2184 use this java binary for running the sjavac 2185 background server [Boot JDK java] 2186 --with-ccache-dir where to store ccache files [~/.ccache] 2187 2188 Some influential environment variables: 2189 BASENAME Override default value for BASENAME 2190 BASH Override default value for BASH 2191 CAT Override default value for CAT 2192 CHMOD Override default value for CHMOD 2193 CMP Override default value for CMP 2194 COMM Override default value for COMM 2195 CP Override default value for CP 2196 CUT Override default value for CUT 2197 DATE Override default value for DATE 2198 DIFF Override default value for DIFF 2199 DIRNAME Override default value for DIRNAME 2200 ECHO Override default value for ECHO 2201 EXPR Override default value for EXPR 2202 FILE Override default value for FILE 2203 FIND Override default value for FIND 2204 HEAD Override default value for HEAD 2205 GUNZIP Override default value for GUNZIP 2206 GZIP Override default value for GZIP 2207 LN Override default value for LN 2208 LS Override default value for LS 2209 MKDIR Override default value for MKDIR 2210 MKTEMP Override default value for MKTEMP 2211 MV Override default value for MV 2212 NAWK Override default value for NAWK 2213 PRINTF Override default value for PRINTF 2214 RM Override default value for RM 2215 RMDIR Override default value for RMDIR 2216 SH Override default value for SH 2217 SORT Override default value for SORT 2218 TAIL Override default value for TAIL 2219 TAR Override default value for TAR 2220 TEE Override default value for TEE 2221 TOUCH Override default value for TOUCH 2222 TR Override default value for TR 2223 UNAME Override default value for UNAME 2224 UNIQ Override default value for UNIQ 2225 WC Override default value for WC 2226 WHICH Override default value for WHICH 2227 XARGS Override default value for XARGS 2228 AWK Override default value for AWK 2229 GREP Override default value for GREP 2230 EGREP Override default value for EGREP 2231 FGREP Override default value for FGREP 2232 SED Override default value for SED 2233 CYGPATH Override default value for CYGPATH 2234 READLINK Override default value for READLINK 2235 DF Override default value for DF 2236 CPIO Override default value for CPIO 2237 NICE Override default value for NICE 2238 MAKE Override default value for MAKE 2239 UNZIP Override default value for UNZIP 2240 ZIP Override default value for ZIP 2241 LDD Override default value for LDD 2242 OTOOL Override default value for OTOOL 2243 READELF Override default value for READELF 2244 HG Override default value for HG 2245 STAT Override default value for STAT 2246 TIME Override default value for TIME 2247 DTRACE Override default value for DTRACE 2248 PATCH Override default value for PATCH 2249 DSYMUTIL Override default value for DSYMUTIL 2250 XATTR Override default value for XATTR 2251 CODESIGN Override default value for CODESIGN 2252 SETFILE Override default value for SETFILE 2253 PKG_CONFIG path to pkg-config utility 2254 JAVA Override default value for JAVA 2255 JAVAC Override default value for JAVAC 2256 JAVAH Override default value for JAVAH 2257 JAR Override default value for JAR 2258 JARSIGNER Override default value for JARSIGNER 2259 CC C compiler command 2260 CFLAGS C compiler flags 2261 LDFLAGS linker flags, e.g. -L<lib dir> if you have libraries in a 2262 nonstandard directory <lib dir> 2263 LIBS libraries to pass to the linker, e.g. -l<library> 2264 CPPFLAGS (Objective) C/C++ preprocessor flags, e.g. -I<include dir> if 2265 you have headers in a nonstandard directory <include dir> 2266 CXX C++ compiler command 2267 CXXFLAGS C++ compiler flags 2268 CPP C preprocessor 2269 CXXCPP C++ preprocessor 2270 AS Override default value for AS 2271 AR Override default value for AR 2272 LIPO Override default value for LIPO 2273 STRIP Override default value for STRIP 2274 NM Override default value for NM 2275 GNM Override default value for GNM 2276 OBJCOPY Override default value for OBJCOPY 2277 OBJDUMP Override default value for OBJDUMP 2278 BUILD_CC Override default value for BUILD_CC 2279 BUILD_CXX Override default value for BUILD_CXX 2280 BUILD_NM Override default value for BUILD_NM 2281 BUILD_AR Override default value for BUILD_AR 2282 BUILD_OBJCOPY 2283 Override default value for BUILD_OBJCOPY 2284 BUILD_STRIP Override default value for BUILD_STRIP 2285 JTREGEXE Override default value for JTREGEXE 2286 XMKMF Path to xmkmf, Makefile generator for X Window System 2287 FREETYPE_CFLAGS 2288 C compiler flags for FREETYPE, overriding pkg-config 2289 FREETYPE_LIBS 2290 linker flags for FREETYPE, overriding pkg-config 2291 ALSA_CFLAGS C compiler flags for ALSA, overriding pkg-config 2292 ALSA_LIBS linker flags for ALSA, overriding pkg-config 2293 LIBFFI_CFLAGS 2294 C compiler flags for LIBFFI, overriding pkg-config 2295 LIBFFI_LIBS linker flags for LIBFFI, overriding pkg-config 2296 PNG_CFLAGS C compiler flags for PNG, overriding pkg-config 2297 PNG_LIBS linker flags for PNG, overriding pkg-config 2298 LCMS_CFLAGS C compiler flags for LCMS, overriding pkg-config 2299 LCMS_LIBS linker flags for LCMS, overriding pkg-config 2300 ICECC_CMD Override default value for ICECC_CMD 2301 ICECC_CREATE_ENV 2302 Override default value for ICECC_CREATE_ENV 2303 ICECC_WRAPPER 2304 Override default value for ICECC_WRAPPER 2305 CCACHE Override default value for CCACHE 2306 2307 Use these variables to override the choices made by `configure' or to help 2308 it to find libraries and programs with nonstandard names/locations. 2309 2310 Report bugs to <build-dev@openjdk.java.net>. 2311 OpenJDK home page: <http://openjdk.java.net>. 2312 _ACEOF 2313 ac_status=$? 2314 fi 2315 2316 if test "$ac_init_help" = "recursive"; then 2317 # If there are subdirs, report their specific --help. 2318 for ac_dir in : $ac_subdirs_all; do test "x$ac_dir" = x: && continue 2319 test -d "$ac_dir" || 2320 { cd "$srcdir" && ac_pwd=`pwd` && srcdir=. && test -d "$ac_dir"; } || 2321 continue 2322 ac_builddir=. 2323 2324 case "$ac_dir" in 2325 .) ac_dir_suffix= ac_top_builddir_sub=. ac_top_build_prefix= ;; 2326 *) 2327 ac_dir_suffix=/`$as_echo "$ac_dir" | sed 's|^\.[\\/]||'` 2328 # A ".." for each directory in $ac_dir_suffix. 2329 ac_top_builddir_sub=`$as_echo "$ac_dir_suffix" | sed 's|/[^\\/]*|/..|g;s|/||'` 2330 case $ac_top_builddir_sub in 2331 "") ac_top_builddir_sub=. ac_top_build_prefix= ;; 2332 *) ac_top_build_prefix=$ac_top_builddir_sub/ ;; 2333 esac ;; 2334 esac 2335 ac_abs_top_builddir=$ac_pwd 2336 ac_abs_builddir=$ac_pwd$ac_dir_suffix 2337 # for backward compatibility: 2338 ac_top_builddir=$ac_top_build_prefix 2339 2340 case $srcdir in 2341 .) # We are building in place. 2342 ac_srcdir=. 2343 ac_top_srcdir=$ac_top_builddir_sub 2344 ac_abs_top_srcdir=$ac_pwd ;; 2345 [\\/]* | ?:[\\/]* ) # Absolute name. 2346 ac_srcdir=$srcdir$ac_dir_suffix; 2347 ac_top_srcdir=$srcdir 2348 ac_abs_top_srcdir=$srcdir ;; 2349 *) # Relative name. 2350 ac_srcdir=$ac_top_build_prefix$srcdir$ac_dir_suffix 2351 ac_top_srcdir=$ac_top_build_prefix$srcdir 2352 ac_abs_top_srcdir=$ac_pwd/$srcdir ;; 2353 esac 2354 ac_abs_srcdir=$ac_abs_top_srcdir$ac_dir_suffix 2355 2356 cd "$ac_dir" || { ac_status=$?; continue; } 2357 # Check for guested configure. 2358 if test -f "$ac_srcdir/configure.gnu"; then 2359 echo && 2360 $SHELL "$ac_srcdir/configure.gnu" --help=recursive 2361 elif test -f "$ac_srcdir/configure"; then 2362 echo && 2363 $SHELL "$ac_srcdir/configure" --help=recursive 2364 else 2365 $as_echo "$as_me: WARNING: no configuration information is in $ac_dir" >&2 2366 fi || ac_status=$? 2367 cd "$ac_pwd" || { ac_status=$?; break; } 2368 done 2369 fi 2370 2371 test -n "$ac_init_help" && exit $ac_status 2372 if $ac_init_version; then 2373 cat <<\_ACEOF 2374 OpenJDK configure jdk9 2375 generated by GNU Autoconf 2.69 2376 2377 Copyright (C) 2012 Free Software Foundation, Inc. 2378 This configure script is free software; the Free Software Foundation 2379 gives unlimited permission to copy, distribute and modify it. 2380 _ACEOF 2381 exit 2382 fi 2383 2384 ## ------------------------ ## 2385 ## Autoconf initialization. ## 2386 ## ------------------------ ## 2387 2388 # ac_fn_c_try_compile LINENO 2389 # -------------------------- 2390 # Try to compile conftest.$ac_ext, and return whether this succeeded. 2391 ac_fn_c_try_compile () 2392 { 2393 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack 2394 rm -f conftest.$ac_objext 2395 if { { ac_try="$ac_compile" 2396 case "(($ac_try" in 2397 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; 2398 *) ac_try_echo=$ac_try;; 2399 esac 2400 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\"" 2401 $as_echo "$ac_try_echo"; } >&5 2402 (eval "$ac_compile") 2>conftest.err 2403 ac_status=$? 2404 if test -s conftest.err; then 2405 grep -v '^ *+' conftest.err >conftest.er1 2406 cat conftest.er1 >&5 2407 mv -f conftest.er1 conftest.err 2408 fi 2409 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 2410 test $ac_status = 0; } && { 2411 test -z "$ac_c_werror_flag" || 2412 test ! -s conftest.err 2413 } && test -s conftest.$ac_objext; then : 2414 ac_retval=0 2415 else 2416 $as_echo "$as_me: failed program was:" >&5 2417 sed 's/^/| /' conftest.$ac_ext >&5 2418 2419 ac_retval=1 2420 fi 2421 eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno 2422 as_fn_set_status $ac_retval 2423 2424 } # ac_fn_c_try_compile 2425 2426 # ac_fn_cxx_try_compile LINENO 2427 # ---------------------------- 2428 # Try to compile conftest.$ac_ext, and return whether this succeeded. 2429 ac_fn_cxx_try_compile () 2430 { 2431 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack 2432 rm -f conftest.$ac_objext 2433 if { { ac_try="$ac_compile" 2434 case "(($ac_try" in 2435 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; 2436 *) ac_try_echo=$ac_try;; 2437 esac 2438 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\"" 2439 $as_echo "$ac_try_echo"; } >&5 2440 (eval "$ac_compile") 2>conftest.err 2441 ac_status=$? 2442 if test -s conftest.err; then 2443 grep -v '^ *+' conftest.err >conftest.er1 2444 cat conftest.er1 >&5 2445 mv -f conftest.er1 conftest.err 2446 fi 2447 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 2448 test $ac_status = 0; } && { 2449 test -z "$ac_cxx_werror_flag" || 2450 test ! -s conftest.err 2451 } && test -s conftest.$ac_objext; then : 2452 ac_retval=0 2453 else 2454 $as_echo "$as_me: failed program was:" >&5 2455 sed 's/^/| /' conftest.$ac_ext >&5 2456 2457 ac_retval=1 2458 fi 2459 eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno 2460 as_fn_set_status $ac_retval 2461 2462 } # ac_fn_cxx_try_compile 2463 2464 # ac_fn_c_try_cpp LINENO 2465 # ---------------------- 2466 # Try to preprocess conftest.$ac_ext, and return whether this succeeded. 2467 ac_fn_c_try_cpp () 2468 { 2469 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack 2470 if { { ac_try="$ac_cpp conftest.$ac_ext" 2471 case "(($ac_try" in 2472 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; 2473 *) ac_try_echo=$ac_try;; 2474 esac 2475 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\"" 2476 $as_echo "$ac_try_echo"; } >&5 2477 (eval "$ac_cpp conftest.$ac_ext") 2>conftest.err 2478 ac_status=$? 2479 if test -s conftest.err; then 2480 grep -v '^ *+' conftest.err >conftest.er1 2481 cat conftest.er1 >&5 2482 mv -f conftest.er1 conftest.err 2483 fi 2484 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 2485 test $ac_status = 0; } > conftest.i && { 2486 test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" || 2487 test ! -s conftest.err 2488 }; then : 2489 ac_retval=0 2490 else 2491 $as_echo "$as_me: failed program was:" >&5 2492 sed 's/^/| /' conftest.$ac_ext >&5 2493 2494 ac_retval=1 2495 fi 2496 eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno 2497 as_fn_set_status $ac_retval 2498 2499 } # ac_fn_c_try_cpp 2500 2501 # ac_fn_cxx_try_cpp LINENO 2502 # ------------------------ 2503 # Try to preprocess conftest.$ac_ext, and return whether this succeeded. 2504 ac_fn_cxx_try_cpp () 2505 { 2506 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack 2507 if { { ac_try="$ac_cpp conftest.$ac_ext" 2508 case "(($ac_try" in 2509 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; 2510 *) ac_try_echo=$ac_try;; 2511 esac 2512 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\"" 2513 $as_echo "$ac_try_echo"; } >&5 2514 (eval "$ac_cpp conftest.$ac_ext") 2>conftest.err 2515 ac_status=$? 2516 if test -s conftest.err; then 2517 grep -v '^ *+' conftest.err >conftest.er1 2518 cat conftest.er1 >&5 2519 mv -f conftest.er1 conftest.err 2520 fi 2521 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 2522 test $ac_status = 0; } > conftest.i && { 2523 test -z "$ac_cxx_preproc_warn_flag$ac_cxx_werror_flag" || 2524 test ! -s conftest.err 2525 }; then : 2526 ac_retval=0 2527 else 2528 $as_echo "$as_me: failed program was:" >&5 2529 sed 's/^/| /' conftest.$ac_ext >&5 2530 2531 ac_retval=1 2532 fi 2533 eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno 2534 as_fn_set_status $ac_retval 2535 2536 } # ac_fn_cxx_try_cpp 2537 2538 # ac_fn_c_try_link LINENO 2539 # ----------------------- 2540 # Try to link conftest.$ac_ext, and return whether this succeeded. 2541 ac_fn_c_try_link () 2542 { 2543 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack 2544 rm -f conftest.$ac_objext conftest$ac_exeext 2545 if { { ac_try="$ac_link" 2546 case "(($ac_try" in 2547 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; 2548 *) ac_try_echo=$ac_try;; 2549 esac 2550 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\"" 2551 $as_echo "$ac_try_echo"; } >&5 2552 (eval "$ac_link") 2>conftest.err 2553 ac_status=$? 2554 if test -s conftest.err; then 2555 grep -v '^ *+' conftest.err >conftest.er1 2556 cat conftest.er1 >&5 2557 mv -f conftest.er1 conftest.err 2558 fi 2559 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 2560 test $ac_status = 0; } && { 2561 test -z "$ac_c_werror_flag" || 2562 test ! -s conftest.err 2563 } && test -s conftest$ac_exeext && { 2564 test "$cross_compiling" = yes || 2565 test -x conftest$ac_exeext 2566 }; then : 2567 ac_retval=0 2568 else 2569 $as_echo "$as_me: failed program was:" >&5 2570 sed 's/^/| /' conftest.$ac_ext >&5 2571 2572 ac_retval=1 2573 fi 2574 # Delete the IPA/IPO (Inter Procedural Analysis/Optimization) information 2575 # created by the PGI compiler (conftest_ipa8_conftest.oo), as it would 2576 # interfere with the next link command; also delete a directory that is 2577 # left behind by Apple's compiler. We do this before executing the actions. 2578 rm -rf conftest.dSYM conftest_ipa8_conftest.oo 2579 eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno 2580 as_fn_set_status $ac_retval 2581 2582 } # ac_fn_c_try_link 2583 2584 # ac_fn_cxx_check_header_mongrel LINENO HEADER VAR INCLUDES 2585 # --------------------------------------------------------- 2586 # Tests whether HEADER exists, giving a warning if it cannot be compiled using 2587 # the include files in INCLUDES and setting the cache variable VAR 2588 # accordingly. 2589 ac_fn_cxx_check_header_mongrel () 2590 { 2591 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack 2592 if eval \${$3+:} false; then : 2593 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5 2594 $as_echo_n "checking for $2... " >&6; } 2595 if eval \${$3+:} false; then : 2596 $as_echo_n "(cached) " >&6 2597 fi 2598 eval ac_res=\$$3 2599 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5 2600 $as_echo "$ac_res" >&6; } 2601 else 2602 # Is the header compilable? 2603 { $as_echo "$as_me:${as_lineno-$LINENO}: checking $2 usability" >&5 2604 $as_echo_n "checking $2 usability... " >&6; } 2605 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 2606 /* end confdefs.h. */ 2607 $4 2608 #include <$2> 2609 _ACEOF 2610 if ac_fn_cxx_try_compile "$LINENO"; then : 2611 ac_header_compiler=yes 2612 else 2613 ac_header_compiler=no 2614 fi 2615 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext 2616 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_header_compiler" >&5 2617 $as_echo "$ac_header_compiler" >&6; } 2618 2619 # Is the header present? 2620 { $as_echo "$as_me:${as_lineno-$LINENO}: checking $2 presence" >&5 2621 $as_echo_n "checking $2 presence... " >&6; } 2622 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 2623 /* end confdefs.h. */ 2624 #include <$2> 2625 _ACEOF 2626 if ac_fn_cxx_try_cpp "$LINENO"; then : 2627 ac_header_preproc=yes 2628 else 2629 ac_header_preproc=no 2630 fi 2631 rm -f conftest.err conftest.i conftest.$ac_ext 2632 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_header_preproc" >&5 2633 $as_echo "$ac_header_preproc" >&6; } 2634 2635 # So? What about this header? 2636 case $ac_header_compiler:$ac_header_preproc:$ac_cxx_preproc_warn_flag in #(( 2637 yes:no: ) 2638 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: accepted by the compiler, rejected by the preprocessor!" >&5 2639 $as_echo "$as_me: WARNING: $2: accepted by the compiler, rejected by the preprocessor!" >&2;} 2640 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: proceeding with the compiler's result" >&5 2641 $as_echo "$as_me: WARNING: $2: proceeding with the compiler's result" >&2;} 2642 ;; 2643 no:yes:* ) 2644 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: present but cannot be compiled" >&5 2645 $as_echo "$as_me: WARNING: $2: present but cannot be compiled" >&2;} 2646 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: check for missing prerequisite headers?" >&5 2647 $as_echo "$as_me: WARNING: $2: check for missing prerequisite headers?" >&2;} 2648 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: see the Autoconf documentation" >&5 2649 $as_echo "$as_me: WARNING: $2: see the Autoconf documentation" >&2;} 2650 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: section \"Present But Cannot Be Compiled\"" >&5 2651 $as_echo "$as_me: WARNING: $2: section \"Present But Cannot Be Compiled\"" >&2;} 2652 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: proceeding with the compiler's result" >&5 2653 $as_echo "$as_me: WARNING: $2: proceeding with the compiler's result" >&2;} 2654 ( $as_echo "## ----------------------------------------- ## 2655 ## Report this to build-dev@openjdk.java.net ## 2656 ## ----------------------------------------- ##" 2657 ) | sed "s/^/$as_me: WARNING: /" >&2 2658 ;; 2659 esac 2660 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5 2661 $as_echo_n "checking for $2... " >&6; } 2662 if eval \${$3+:} false; then : 2663 $as_echo_n "(cached) " >&6 2664 else 2665 eval "$3=\$ac_header_compiler" 2666 fi 2667 eval ac_res=\$$3 2668 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5 2669 $as_echo "$ac_res" >&6; } 2670 fi 2671 eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno 2672 2673 } # ac_fn_cxx_check_header_mongrel 2674 2675 # ac_fn_cxx_try_run LINENO 2676 # ------------------------ 2677 # Try to link conftest.$ac_ext, and return whether this succeeded. Assumes 2678 # that executables *can* be run. 2679 ac_fn_cxx_try_run () 2680 { 2681 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack 2682 if { { ac_try="$ac_link" 2683 case "(($ac_try" in 2684 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; 2685 *) ac_try_echo=$ac_try;; 2686 esac 2687 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\"" 2688 $as_echo "$ac_try_echo"; } >&5 2689 (eval "$ac_link") 2>&5 2690 ac_status=$? 2691 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 2692 test $ac_status = 0; } && { ac_try='./conftest$ac_exeext' 2693 { { case "(($ac_try" in 2694 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; 2695 *) ac_try_echo=$ac_try;; 2696 esac 2697 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\"" 2698 $as_echo "$ac_try_echo"; } >&5 2699 (eval "$ac_try") 2>&5 2700 ac_status=$? 2701 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 2702 test $ac_status = 0; }; }; then : 2703 ac_retval=0 2704 else 2705 $as_echo "$as_me: program exited with status $ac_status" >&5 2706 $as_echo "$as_me: failed program was:" >&5 2707 sed 's/^/| /' conftest.$ac_ext >&5 2708 2709 ac_retval=$ac_status 2710 fi 2711 rm -rf conftest.dSYM conftest_ipa8_conftest.oo 2712 eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno 2713 as_fn_set_status $ac_retval 2714 2715 } # ac_fn_cxx_try_run 2716 2717 # ac_fn_cxx_check_header_compile LINENO HEADER VAR INCLUDES 2718 # --------------------------------------------------------- 2719 # Tests whether HEADER exists and can be compiled using the include files in 2720 # INCLUDES, setting the cache variable VAR accordingly. 2721 ac_fn_cxx_check_header_compile () 2722 { 2723 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack 2724 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5 2725 $as_echo_n "checking for $2... " >&6; } 2726 if eval \${$3+:} false; then : 2727 $as_echo_n "(cached) " >&6 2728 else 2729 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 2730 /* end confdefs.h. */ 2731 $4 2732 #include <$2> 2733 _ACEOF 2734 if ac_fn_cxx_try_compile "$LINENO"; then : 2735 eval "$3=yes" 2736 else 2737 eval "$3=no" 2738 fi 2739 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext 2740 fi 2741 eval ac_res=\$$3 2742 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5 2743 $as_echo "$ac_res" >&6; } 2744 eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno 2745 2746 } # ac_fn_cxx_check_header_compile 2747 2748 # ac_fn_cxx_compute_int LINENO EXPR VAR INCLUDES 2749 # ---------------------------------------------- 2750 # Tries to find the compile-time value of EXPR in a program that includes 2751 # INCLUDES, setting VAR accordingly. Returns whether the value could be 2752 # computed 2753 ac_fn_cxx_compute_int () 2754 { 2755 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack 2756 if test "$cross_compiling" = yes; then 2757 # Depending upon the size, compute the lo and hi bounds. 2758 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 2759 /* end confdefs.h. */ 2760 $4 2761 int 2762 main () 2763 { 2764 static int test_array [1 - 2 * !(($2) >= 0)]; 2765 test_array [0] = 0; 2766 return test_array [0]; 2767 2768 ; 2769 return 0; 2770 } 2771 _ACEOF 2772 if ac_fn_cxx_try_compile "$LINENO"; then : 2773 ac_lo=0 ac_mid=0 2774 while :; do 2775 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 2776 /* end confdefs.h. */ 2777 $4 2778 int 2779 main () 2780 { 2781 static int test_array [1 - 2 * !(($2) <= $ac_mid)]; 2782 test_array [0] = 0; 2783 return test_array [0]; 2784 2785 ; 2786 return 0; 2787 } 2788 _ACEOF 2789 if ac_fn_cxx_try_compile "$LINENO"; then : 2790 ac_hi=$ac_mid; break 2791 else 2792 as_fn_arith $ac_mid + 1 && ac_lo=$as_val 2793 if test $ac_lo -le $ac_mid; then 2794 ac_lo= ac_hi= 2795 break 2796 fi 2797 as_fn_arith 2 '*' $ac_mid + 1 && ac_mid=$as_val 2798 fi 2799 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext 2800 done 2801 else 2802 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 2803 /* end confdefs.h. */ 2804 $4 2805 int 2806 main () 2807 { 2808 static int test_array [1 - 2 * !(($2) < 0)]; 2809 test_array [0] = 0; 2810 return test_array [0]; 2811 2812 ; 2813 return 0; 2814 } 2815 _ACEOF 2816 if ac_fn_cxx_try_compile "$LINENO"; then : 2817 ac_hi=-1 ac_mid=-1 2818 while :; do 2819 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 2820 /* end confdefs.h. */ 2821 $4 2822 int 2823 main () 2824 { 2825 static int test_array [1 - 2 * !(($2) >= $ac_mid)]; 2826 test_array [0] = 0; 2827 return test_array [0]; 2828 2829 ; 2830 return 0; 2831 } 2832 _ACEOF 2833 if ac_fn_cxx_try_compile "$LINENO"; then : 2834 ac_lo=$ac_mid; break 2835 else 2836 as_fn_arith '(' $ac_mid ')' - 1 && ac_hi=$as_val 2837 if test $ac_mid -le $ac_hi; then 2838 ac_lo= ac_hi= 2839 break 2840 fi 2841 as_fn_arith 2 '*' $ac_mid && ac_mid=$as_val 2842 fi 2843 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext 2844 done 2845 else 2846 ac_lo= ac_hi= 2847 fi 2848 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext 2849 fi 2850 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext 2851 # Binary search between lo and hi bounds. 2852 while test "x$ac_lo" != "x$ac_hi"; do 2853 as_fn_arith '(' $ac_hi - $ac_lo ')' / 2 + $ac_lo && ac_mid=$as_val 2854 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 2855 /* end confdefs.h. */ 2856 $4 2857 int 2858 main () 2859 { 2860 static int test_array [1 - 2 * !(($2) <= $ac_mid)]; 2861 test_array [0] = 0; 2862 return test_array [0]; 2863 2864 ; 2865 return 0; 2866 } 2867 _ACEOF 2868 if ac_fn_cxx_try_compile "$LINENO"; then : 2869 ac_hi=$ac_mid 2870 else 2871 as_fn_arith '(' $ac_mid ')' + 1 && ac_lo=$as_val 2872 fi 2873 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext 2874 done 2875 case $ac_lo in #(( 2876 ?*) eval "$3=\$ac_lo"; ac_retval=0 ;; 2877 '') ac_retval=1 ;; 2878 esac 2879 else 2880 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 2881 /* end confdefs.h. */ 2882 $4 2883 static long int longval () { return $2; } 2884 static unsigned long int ulongval () { return $2; } 2885 #include <stdio.h> 2886 #include <stdlib.h> 2887 int 2888 main () 2889 { 2890 2891 FILE *f = fopen ("conftest.val", "w"); 2892 if (! f) 2893 return 1; 2894 if (($2) < 0) 2895 { 2896 long int i = longval (); 2897 if (i != ($2)) 2898 return 1; 2899 fprintf (f, "%ld", i); 2900 } 2901 else 2902 { 2903 unsigned long int i = ulongval (); 2904 if (i != ($2)) 2905 return 1; 2906 fprintf (f, "%lu", i); 2907 } 2908 /* Do not output a trailing newline, as this causes \r\n confusion 2909 on some platforms. */ 2910 return ferror (f) || fclose (f) != 0; 2911 2912 ; 2913 return 0; 2914 } 2915 _ACEOF 2916 if ac_fn_cxx_try_run "$LINENO"; then : 2917 echo >>conftest.val; read $3 <conftest.val; ac_retval=0 2918 else 2919 ac_retval=1 2920 fi 2921 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \ 2922 conftest.$ac_objext conftest.beam conftest.$ac_ext 2923 rm -f conftest.val 2924 2925 fi 2926 eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno 2927 as_fn_set_status $ac_retval 2928 2929 } # ac_fn_cxx_compute_int 2930 2931 # ac_fn_cxx_try_link LINENO 2932 # ------------------------- 2933 # Try to link conftest.$ac_ext, and return whether this succeeded. 2934 ac_fn_cxx_try_link () 2935 { 2936 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack 2937 rm -f conftest.$ac_objext conftest$ac_exeext 2938 if { { ac_try="$ac_link" 2939 case "(($ac_try" in 2940 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; 2941 *) ac_try_echo=$ac_try;; 2942 esac 2943 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\"" 2944 $as_echo "$ac_try_echo"; } >&5 2945 (eval "$ac_link") 2>conftest.err 2946 ac_status=$? 2947 if test -s conftest.err; then 2948 grep -v '^ *+' conftest.err >conftest.er1 2949 cat conftest.er1 >&5 2950 mv -f conftest.er1 conftest.err 2951 fi 2952 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 2953 test $ac_status = 0; } && { 2954 test -z "$ac_cxx_werror_flag" || 2955 test ! -s conftest.err 2956 } && test -s conftest$ac_exeext && { 2957 test "$cross_compiling" = yes || 2958 test -x conftest$ac_exeext 2959 }; then : 2960 ac_retval=0 2961 else 2962 $as_echo "$as_me: failed program was:" >&5 2963 sed 's/^/| /' conftest.$ac_ext >&5 2964 2965 ac_retval=1 2966 fi 2967 # Delete the IPA/IPO (Inter Procedural Analysis/Optimization) information 2968 # created by the PGI compiler (conftest_ipa8_conftest.oo), as it would 2969 # interfere with the next link command; also delete a directory that is 2970 # left behind by Apple's compiler. We do this before executing the actions. 2971 rm -rf conftest.dSYM conftest_ipa8_conftest.oo 2972 eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno 2973 as_fn_set_status $ac_retval 2974 2975 } # ac_fn_cxx_try_link 2976 2977 # ac_fn_cxx_check_func LINENO FUNC VAR 2978 # ------------------------------------ 2979 # Tests whether FUNC exists, setting the cache variable VAR accordingly 2980 ac_fn_cxx_check_func () 2981 { 2982 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack 2983 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5 2984 $as_echo_n "checking for $2... " >&6; } 2985 if eval \${$3+:} false; then : 2986 $as_echo_n "(cached) " >&6 2987 else 2988 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 2989 /* end confdefs.h. */ 2990 /* Define $2 to an innocuous variant, in case <limits.h> declares $2. 2991 For example, HP-UX 11i <limits.h> declares gettimeofday. */ 2992 #define $2 innocuous_$2 2993 2994 /* System header to define __stub macros and hopefully few prototypes, 2995 which can conflict with char $2 (); below. 2996 Prefer <limits.h> to <assert.h> if __STDC__ is defined, since 2997 <limits.h> exists even on freestanding compilers. */ 2998 2999 #ifdef __STDC__ 3000 # include <limits.h> 3001 #else 3002 # include <assert.h> 3003 #endif 3004 3005 #undef $2 3006 3007 /* Override any GCC internal prototype to avoid an error. 3008 Use char because int might match the return type of a GCC 3009 builtin and then its argument prototype would still apply. */ 3010 #ifdef __cplusplus 3011 extern "C" 3012 #endif 3013 char $2 (); 3014 /* The GNU C library defines this for functions which it implements 3015 to always fail with ENOSYS. Some functions are actually named 3016 something starting with __ and the normal name is an alias. */ 3017 #if defined __stub_$2 || defined __stub___$2 3018 choke me 3019 #endif 3020 3021 int 3022 main () 3023 { 3024 return $2 (); 3025 ; 3026 return 0; 3027 } 3028 _ACEOF 3029 if ac_fn_cxx_try_link "$LINENO"; then : 3030 eval "$3=yes" 3031 else 3032 eval "$3=no" 3033 fi 3034 rm -f core conftest.err conftest.$ac_objext \ 3035 conftest$ac_exeext conftest.$ac_ext 3036 fi 3037 eval ac_res=\$$3 3038 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5 3039 $as_echo "$ac_res" >&6; } 3040 eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno 3041 3042 } # ac_fn_cxx_check_func 3043 3044 # ac_fn_c_check_header_compile LINENO HEADER VAR INCLUDES 3045 # ------------------------------------------------------- 3046 # Tests whether HEADER exists and can be compiled using the include files in 3047 # INCLUDES, setting the cache variable VAR accordingly. 3048 ac_fn_c_check_header_compile () 3049 { 3050 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack 3051 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5 3052 $as_echo_n "checking for $2... " >&6; } 3053 if eval \${$3+:} false; then : 3054 $as_echo_n "(cached) " >&6 3055 else 3056 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 3057 /* end confdefs.h. */ 3058 $4 3059 #include <$2> 3060 _ACEOF 3061 if ac_fn_c_try_compile "$LINENO"; then : 3062 eval "$3=yes" 3063 else 3064 eval "$3=no" 3065 fi 3066 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext 3067 fi 3068 eval ac_res=\$$3 3069 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5 3070 $as_echo "$ac_res" >&6; } 3071 eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno 3072 3073 } # ac_fn_c_check_header_compile 3074 cat >config.log <<_ACEOF 3075 This file contains any messages produced by compilers while 3076 running configure, to aid debugging if configure makes a mistake. 3077 3078 It was created by OpenJDK $as_me jdk9, which was 3079 generated by GNU Autoconf 2.69. Invocation command line was 3080 3081 $ $0 $@ 3082 3083 _ACEOF 3084 exec 5>>config.log 3085 { 3086 cat <<_ASUNAME 3087 ## --------- ## 3088 ## Platform. ## 3089 ## --------- ## 3090 3091 hostname = `(hostname || uname -n) 2>/dev/null | sed 1q` 3092 uname -m = `(uname -m) 2>/dev/null || echo unknown` 3093 uname -r = `(uname -r) 2>/dev/null || echo unknown` 3094 uname -s = `(uname -s) 2>/dev/null || echo unknown` 3095 uname -v = `(uname -v) 2>/dev/null || echo unknown` 3096 3097 /usr/bin/uname -p = `(/usr/bin/uname -p) 2>/dev/null || echo unknown` 3098 /bin/uname -X = `(/bin/uname -X) 2>/dev/null || echo unknown` 3099 3100 /bin/arch = `(/bin/arch) 2>/dev/null || echo unknown` 3101 /usr/bin/arch -k = `(/usr/bin/arch -k) 2>/dev/null || echo unknown` 3102 /usr/convex/getsysinfo = `(/usr/convex/getsysinfo) 2>/dev/null || echo unknown` 3103 /usr/bin/hostinfo = `(/usr/bin/hostinfo) 2>/dev/null || echo unknown` 3104 /bin/machine = `(/bin/machine) 2>/dev/null || echo unknown` 3105 /usr/bin/oslevel = `(/usr/bin/oslevel) 2>/dev/null || echo unknown` 3106 /bin/universe = `(/bin/universe) 2>/dev/null || echo unknown` 3107 3108 _ASUNAME 3109 3110 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 3111 for as_dir in $PATH 3112 do 3113 IFS=$as_save_IFS 3114 test -z "$as_dir" && as_dir=. 3115 $as_echo "PATH: $as_dir" 3116 done 3117 IFS=$as_save_IFS 3118 3119 } >&5 3120 3121 cat >&5 <<_ACEOF 3122 3123 3124 ## ----------- ## 3125 ## Core tests. ## 3126 ## ----------- ## 3127 3128 _ACEOF 3129 3130 3131 # Keep a trace of the command line. 3132 # Strip out --no-create and --no-recursion so they do not pile up. 3133 # Strip out --silent because we don't want to record it for future runs. 3134 # Also quote any args containing shell meta-characters. 3135 # Make two passes to allow for proper duplicate-argument suppression. 3136 ac_configure_args= 3137 ac_configure_args0= 3138 ac_configure_args1= 3139 ac_must_keep_next=false 3140 for ac_pass in 1 2 3141 do 3142 for ac_arg 3143 do 3144 case $ac_arg in 3145 -no-create | --no-c* | -n | -no-recursion | --no-r*) continue ;; 3146 -q | -quiet | --quiet | --quie | --qui | --qu | --q \ 3147 | -silent | --silent | --silen | --sile | --sil) 3148 continue ;; 3149 *\'*) 3150 ac_arg=`$as_echo "$ac_arg" | sed "s/'/'\\\\\\\\''/g"` ;; 3151 esac 3152 case $ac_pass in 3153 1) as_fn_append ac_configure_args0 " '$ac_arg'" ;; 3154 2) 3155 as_fn_append ac_configure_args1 " '$ac_arg'" 3156 if test $ac_must_keep_next = true; then 3157 ac_must_keep_next=false # Got value, back to normal. 3158 else 3159 case $ac_arg in 3160 *=* | --config-cache | -C | -disable-* | --disable-* \ 3161 | -enable-* | --enable-* | -gas | --g* | -nfp | --nf* \ 3162 | -q | -quiet | --q* | -silent | --sil* | -v | -verb* \ 3163 | -with-* | --with-* | -without-* | --without-* | --x) 3164 case "$ac_configure_args0 " in 3165 "$ac_configure_args1"*" '$ac_arg' "* ) continue ;; 3166 esac 3167 ;; 3168 -* ) ac_must_keep_next=true ;; 3169 esac 3170 fi 3171 as_fn_append ac_configure_args " '$ac_arg'" 3172 ;; 3173 esac 3174 done 3175 done 3176 { ac_configure_args0=; unset ac_configure_args0;} 3177 { ac_configure_args1=; unset ac_configure_args1;} 3178 3179 # When interrupted or exit'd, cleanup temporary files, and complete 3180 # config.log. We remove comments because anyway the quotes in there 3181 # would cause problems or look ugly. 3182 # WARNING: Use '\'' to represent an apostrophe within the trap. 3183 # WARNING: Do not start the trap code with a newline, due to a FreeBSD 4.0 bug. 3184 trap 'exit_status=$? 3185 # Save into config.log some information that might help in debugging. 3186 { 3187 echo 3188 3189 $as_echo "## ---------------- ## 3190 ## Cache variables. ## 3191 ## ---------------- ##" 3192 echo 3193 # The following way of writing the cache mishandles newlines in values, 3194 ( 3195 for ac_var in `(set) 2>&1 | sed -n '\''s/^\([a-zA-Z_][a-zA-Z0-9_]*\)=.*/\1/p'\''`; do 3196 eval ac_val=\$$ac_var 3197 case $ac_val in #( 3198 *${as_nl}*) 3199 case $ac_var in #( 3200 *_cv_*) { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: cache variable $ac_var contains a newline" >&5 3201 $as_echo "$as_me: WARNING: cache variable $ac_var contains a newline" >&2;} ;; 3202 esac 3203 case $ac_var in #( 3204 _ | IFS | as_nl) ;; #( 3205 BASH_ARGV | BASH_SOURCE) eval $ac_var= ;; #( 3206 *) { eval $ac_var=; unset $ac_var;} ;; 3207 esac ;; 3208 esac 3209 done 3210 (set) 2>&1 | 3211 case $as_nl`(ac_space='\'' '\''; set) 2>&1` in #( 3212 *${as_nl}ac_space=\ *) 3213 sed -n \ 3214 "s/'\''/'\''\\\\'\'''\''/g; 3215 s/^\\([_$as_cr_alnum]*_cv_[_$as_cr_alnum]*\\)=\\(.*\\)/\\1='\''\\2'\''/p" 3216 ;; #( 3217 *) 3218 sed -n "/^[_$as_cr_alnum]*_cv_[_$as_cr_alnum]*=/p" 3219 ;; 3220 esac | 3221 sort 3222 ) 3223 echo 3224 3225 $as_echo "## ----------------- ## 3226 ## Output variables. ## 3227 ## ----------------- ##" 3228 echo 3229 for ac_var in $ac_subst_vars 3230 do 3231 eval ac_val=\$$ac_var 3232 case $ac_val in 3233 *\'\''*) ac_val=`$as_echo "$ac_val" | sed "s/'\''/'\''\\\\\\\\'\'''\''/g"`;; 3234 esac 3235 $as_echo "$ac_var='\''$ac_val'\''" 3236 done | sort 3237 echo 3238 3239 if test -n "$ac_subst_files"; then 3240 $as_echo "## ------------------- ## 3241 ## File substitutions. ## 3242 ## ------------------- ##" 3243 echo 3244 for ac_var in $ac_subst_files 3245 do 3246 eval ac_val=\$$ac_var 3247 case $ac_val in 3248 *\'\''*) ac_val=`$as_echo "$ac_val" | sed "s/'\''/'\''\\\\\\\\'\'''\''/g"`;; 3249 esac 3250 $as_echo "$ac_var='\''$ac_val'\''" 3251 done | sort 3252 echo 3253 fi 3254 3255 if test -s confdefs.h; then 3256 $as_echo "## ----------- ## 3257 ## confdefs.h. ## 3258 ## ----------- ##" 3259 echo 3260 cat confdefs.h 3261 echo 3262 fi 3263 test "$ac_signal" != 0 && 3264 $as_echo "$as_me: caught signal $ac_signal" 3265 $as_echo "$as_me: exit $exit_status" 3266 } >&5 3267 rm -f core *.core core.conftest.* && 3268 rm -f -r conftest* confdefs* conf$$* $ac_clean_files && 3269 exit $exit_status 3270 ' 0 3271 for ac_signal in 1 2 13 15; do 3272 trap 'ac_signal='$ac_signal'; as_fn_exit 1' $ac_signal 3273 done 3274 ac_signal=0 3275 3276 # confdefs.h avoids OS command line length limits that DEFS can exceed. 3277 rm -f -r conftest* confdefs.h 3278 3279 $as_echo "/* confdefs.h */" > confdefs.h 3280 3281 # Predefined preprocessor variables. 3282 3283 cat >>confdefs.h <<_ACEOF 3284 #define PACKAGE_NAME "$PACKAGE_NAME" 3285 _ACEOF 3286 3287 cat >>confdefs.h <<_ACEOF 3288 #define PACKAGE_TARNAME "$PACKAGE_TARNAME" 3289 _ACEOF 3290 3291 cat >>confdefs.h <<_ACEOF 3292 #define PACKAGE_VERSION "$PACKAGE_VERSION" 3293 _ACEOF 3294 3295 cat >>confdefs.h <<_ACEOF 3296 #define PACKAGE_STRING "$PACKAGE_STRING" 3297 _ACEOF 3298 3299 cat >>confdefs.h <<_ACEOF 3300 #define PACKAGE_BUGREPORT "$PACKAGE_BUGREPORT" 3301 _ACEOF 3302 3303 cat >>confdefs.h <<_ACEOF 3304 #define PACKAGE_URL "$PACKAGE_URL" 3305 _ACEOF 3306 3307 3308 # Let the site file select an alternate cache file if it wants to. 3309 # Prefer an explicitly selected file to automatically selected ones. 3310 ac_site_file1=NONE 3311 ac_site_file2=NONE 3312 if test -n "$CONFIG_SITE"; then 3313 # We do not want a PATH search for config.site. 3314 case $CONFIG_SITE in #(( 3315 -*) ac_site_file1=./$CONFIG_SITE;; 3316 */*) ac_site_file1=$CONFIG_SITE;; 3317 *) ac_site_file1=./$CONFIG_SITE;; 3318 esac 3319 elif test "x$prefix" != xNONE; then 3320 ac_site_file1=$prefix/share/config.site 3321 ac_site_file2=$prefix/etc/config.site 3322 else 3323 ac_site_file1=$ac_default_prefix/share/config.site 3324 ac_site_file2=$ac_default_prefix/etc/config.site 3325 fi 3326 for ac_site_file in "$ac_site_file1" "$ac_site_file2" 3327 do 3328 test "x$ac_site_file" = xNONE && continue 3329 if test /dev/null != "$ac_site_file" && test -r "$ac_site_file"; then 3330 { $as_echo "$as_me:${as_lineno-$LINENO}: loading site script $ac_site_file" >&5 3331 $as_echo "$as_me: loading site script $ac_site_file" >&6;} 3332 sed 's/^/| /' "$ac_site_file" >&5 3333 . "$ac_site_file" \ 3334 || { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 3335 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;} 3336 as_fn_error $? "failed to load site script $ac_site_file 3337 See \`config.log' for more details" "$LINENO" 5; } 3338 fi 3339 done 3340 3341 if test -r "$cache_file"; then 3342 # Some versions of bash will fail to source /dev/null (special files 3343 # actually), so we avoid doing that. DJGPP emulates it as a regular file. 3344 if test /dev/null != "$cache_file" && test -f "$cache_file"; then 3345 { $as_echo "$as_me:${as_lineno-$LINENO}: loading cache $cache_file" >&5 3346 $as_echo "$as_me: loading cache $cache_file" >&6;} 3347 case $cache_file in 3348 [\\/]* | ?:[\\/]* ) . "$cache_file";; 3349 *) . "./$cache_file";; 3350 esac 3351 fi 3352 else 3353 { $as_echo "$as_me:${as_lineno-$LINENO}: creating cache $cache_file" >&5 3354 $as_echo "$as_me: creating cache $cache_file" >&6;} 3355 >$cache_file 3356 fi 3357 3358 # Check that the precious variables saved in the cache have kept the same 3359 # value. 3360 ac_cache_corrupted=false 3361 for ac_var in $ac_precious_vars; do 3362 eval ac_old_set=\$ac_cv_env_${ac_var}_set 3363 eval ac_new_set=\$ac_env_${ac_var}_set 3364 eval ac_old_val=\$ac_cv_env_${ac_var}_value 3365 eval ac_new_val=\$ac_env_${ac_var}_value 3366 case $ac_old_set,$ac_new_set in 3367 set,) 3368 { $as_echo "$as_me:${as_lineno-$LINENO}: error: \`$ac_var' was set to \`$ac_old_val' in the previous run" >&5 3369 $as_echo "$as_me: error: \`$ac_var' was set to \`$ac_old_val' in the previous run" >&2;} 3370 ac_cache_corrupted=: ;; 3371 ,set) 3372 { $as_echo "$as_me:${as_lineno-$LINENO}: error: \`$ac_var' was not set in the previous run" >&5 3373 $as_echo "$as_me: error: \`$ac_var' was not set in the previous run" >&2;} 3374 ac_cache_corrupted=: ;; 3375 ,);; 3376 *) 3377 if test "x$ac_old_val" != "x$ac_new_val"; then 3378 # differences in whitespace do not lead to failure. 3379 ac_old_val_w=`echo x $ac_old_val` 3380 ac_new_val_w=`echo x $ac_new_val` 3381 if test "$ac_old_val_w" != "$ac_new_val_w"; then 3382 { $as_echo "$as_me:${as_lineno-$LINENO}: error: \`$ac_var' has changed since the previous run:" >&5 3383 $as_echo "$as_me: error: \`$ac_var' has changed since the previous run:" >&2;} 3384 ac_cache_corrupted=: 3385 else 3386 { $as_echo "$as_me:${as_lineno-$LINENO}: warning: ignoring whitespace changes in \`$ac_var' since the previous run:" >&5 3387 $as_echo "$as_me: warning: ignoring whitespace changes in \`$ac_var' since the previous run:" >&2;} 3388 eval $ac_var=\$ac_old_val 3389 fi 3390 { $as_echo "$as_me:${as_lineno-$LINENO}: former value: \`$ac_old_val'" >&5 3391 $as_echo "$as_me: former value: \`$ac_old_val'" >&2;} 3392 { $as_echo "$as_me:${as_lineno-$LINENO}: current value: \`$ac_new_val'" >&5 3393 $as_echo "$as_me: current value: \`$ac_new_val'" >&2;} 3394 fi;; 3395 esac 3396 # Pass precious variables to config.status. 3397 if test "$ac_new_set" = set; then 3398 case $ac_new_val in 3399 *\'*) ac_arg=$ac_var=`$as_echo "$ac_new_val" | sed "s/'/'\\\\\\\\''/g"` ;; 3400 *) ac_arg=$ac_var=$ac_new_val ;; 3401 esac 3402 case " $ac_configure_args " in 3403 *" '$ac_arg' "*) ;; # Avoid dups. Use of quotes ensures accuracy. 3404 *) as_fn_append ac_configure_args " '$ac_arg'" ;; 3405 esac 3406 fi 3407 done 3408 if $ac_cache_corrupted; then 3409 { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 3410 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;} 3411 { $as_echo "$as_me:${as_lineno-$LINENO}: error: changes in the environment can compromise the build" >&5 3412 $as_echo "$as_me: error: changes in the environment can compromise the build" >&2;} 3413 as_fn_error $? "run \`make distclean' and/or \`rm $cache_file' and start over" "$LINENO" 5 3414 fi 3415 ## -------------------- ## 3416 ## Main body of script. ## 3417 ## -------------------- ## 3418 3419 ac_ext=c 3420 ac_cpp='$CPP $CPPFLAGS' 3421 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5' 3422 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' 3423 ac_compiler_gnu=$ac_cv_c_compiler_gnu 3424 3425 3426 3427 ac_aux_dir= 3428 for ac_dir in $TOPDIR/common/autoconf/build-aux "$srcdir"/$TOPDIR/common/autoconf/build-aux; do 3429 if test -f "$ac_dir/install-sh"; then 3430 ac_aux_dir=$ac_dir 3431 ac_install_sh="$ac_aux_dir/install-sh -c" 3432 break 3433 elif test -f "$ac_dir/install.sh"; then 3434 ac_aux_dir=$ac_dir 3435 ac_install_sh="$ac_aux_dir/install.sh -c" 3436 break 3437 elif test -f "$ac_dir/shtool"; then 3438 ac_aux_dir=$ac_dir 3439 ac_install_sh="$ac_aux_dir/shtool install -c" 3440 break 3441 fi 3442 done 3443 if test -z "$ac_aux_dir"; then 3444 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 3445 fi 3446 3447 # These three variables are undocumented and unsupported, 3448 # and are intended to be withdrawn in a future Autoconf release. 3449 # They can cause serious problems if a builder's source tree is in a directory 3450 # whose full name contains unusual characters. 3451 ac_config_guess="$SHELL $ac_aux_dir/config.guess" # Please don't use this var. 3452 ac_config_sub="$SHELL $ac_aux_dir/config.sub" # Please don't use this var. 3453 ac_configure="$SHELL $ac_aux_dir/configure" # Please don't use this var. 3454 3455 3456 # pkg.m4 - Macros to locate and utilise pkg-config. -*- Autoconf -*- 3457 3458 # 3459 # Copyright (c) 2012, 2013, Oracle and/or its affiliates. All rights reserved. 3460 # DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. 3461 # 3462 # This code is free software; you can redistribute it and/or modify it 3463 # under the terms of the GNU General Public License version 2 only, as 3464 # published by the Free Software Foundation. Oracle designates this 3465 # particular file as subject to the "Classpath" exception as provided 3466 # by Oracle in the LICENSE file that accompanied this code. 3467 # 3468 # This code is distributed in the hope that it will be useful, but WITHOUT 3469 # ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or 3470 # FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License 3471 # version 2 for more details (a copy is included in the LICENSE file that 3472 # accompanied this code). 3473 # 3474 # You should have received a copy of the GNU General Public License version 3475 # 2 along with this work; if not, write to the Free Software Foundation, 3476 # Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. 3477 # 3478 # Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA 3479 # or visit www.oracle.com if you need additional information or have any 3480 # questions. 3481 # 3482 3483 # 3484 # Copyright © 2004 Scott James Remnant <scott@netsplit.com>. 3485 # 3486 # This program is free software; you can redistribute it and/or modify 3487 # it under the terms of the GNU General Public License as published by 3488 # the Free Software Foundation; either version 2 of the License, or 3489 # (at your option) any later version. 3490 # 3491 # This program is distributed in the hope that it will be useful, but 3492 # WITHOUT ANY WARRANTY; without even the implied warranty of 3493 # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU 3494 # General Public License for more details. 3495 # 3496 # You should have received a copy of the GNU General Public License 3497 # along with this program; if not, write to the Free Software 3498 # Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. 3499 # 3500 # As a special exception to the GNU General Public License, if you 3501 # distribute this file as part of a program that contains a 3502 # configuration script generated by Autoconf, you may include it under 3503 # the same distribution terms that you use for the rest of that program. 3504 3505 # PKG_PROG_PKG_CONFIG([MIN-VERSION]) 3506 # ---------------------------------- 3507 # PKG_PROG_PKG_CONFIG 3508 3509 # PKG_CHECK_EXISTS(MODULES, [ACTION-IF-FOUND], [ACTION-IF-NOT-FOUND]) 3510 # 3511 # Check to see whether a particular set of modules exists. Similar 3512 # to PKG_CHECK_MODULES(), but does not set variables or print errors. 3513 # 3514 # 3515 # Similar to PKG_CHECK_MODULES, make sure that the first instance of 3516 # this or PKG_CHECK_MODULES is called, or make sure to call 3517 # PKG_CHECK_EXISTS manually 3518 # -------------------------------------------------------------- 3519 3520 3521 3522 # _PKG_CONFIG([VARIABLE], [COMMAND], [MODULES]) 3523 # --------------------------------------------- 3524 # _PKG_CONFIG 3525 3526 # _PKG_SHORT_ERRORS_SUPPORTED 3527 # ----------------------------- 3528 # _PKG_SHORT_ERRORS_SUPPORTED 3529 3530 3531 # PKG_CHECK_MODULES(VARIABLE-PREFIX, MODULES, [ACTION-IF-FOUND], 3532 # [ACTION-IF-NOT-FOUND]) 3533 # 3534 # 3535 # Note that if there is a possibility the first call to 3536 # PKG_CHECK_MODULES might not happen, you should be sure to include an 3537 # explicit call to PKG_PROG_PKG_CONFIG in your configure.ac 3538 # 3539 # 3540 # -------------------------------------------------------------- 3541 # PKG_CHECK_MODULES 3542 3543 3544 # Include these first... 3545 # 3546 # Copyright (c) 2011, 2016, Oracle and/or its affiliates. All rights reserved. 3547 # DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. 3548 # 3549 # This code is free software; you can redistribute it and/or modify it 3550 # under the terms of the GNU General Public License version 2 only, as 3551 # published by the Free Software Foundation. Oracle designates this 3552 # particular file as subject to the "Classpath" exception as provided 3553 # by Oracle in the LICENSE file that accompanied this code. 3554 # 3555 # This code is distributed in the hope that it will be useful, but WITHOUT 3556 # ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or 3557 # FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License 3558 # version 2 for more details (a copy is included in the LICENSE file that 3559 # accompanied this code). 3560 # 3561 # You should have received a copy of the GNU General Public License version 3562 # 2 along with this work; if not, write to the Free Software Foundation, 3563 # Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. 3564 # 3565 # Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA 3566 # or visit www.oracle.com if you need additional information or have any 3567 # questions. 3568 # 3569 3570 # Create a function/macro that takes a series of named arguments. The call is 3571 # similar to AC_DEFUN, but the setup of the function looks like this: 3572 # BASIC_DEFUN_NAMED([MYFUNC], [FOO *BAR], [$@], [ 3573 # ... do something 3574 # AC_MSG_NOTICE([Value of BAR is ARG_BAR]) 3575 # ]) 3576 # A star (*) in front of a named argument means that it is required and it's 3577 # presence will be verified. To pass e.g. the first value as a normal indexed 3578 # argument, use [m4_shift($@)] as the third argument instead of [$@]. These 3579 # arguments are referenced in the function by their name prefixed by ARG_, e.g. 3580 # "ARG_FOO". 3581 # 3582 # The generated function can be called like this: 3583 # MYFUNC(FOO: [foo-val], 3584 # BAR: [ 3585 # $ECHO hello world 3586 # ]) 3587 # Note that the argument value must start on the same line as the argument name. 3588 # 3589 # Argument 1: Name of the function to define 3590 # Argument 2: List of legal named arguments, with a * prefix for required arguments 3591 # Argument 3: Argument array to treat as named, typically $@ 3592 # Argument 4: The main function body 3593 3594 3595 # Test if $1 is a valid argument to $3 (often is $JAVA passed as $3) 3596 # If so, then append $1 to $2 \ 3597 # Also set JVM_ARG_OK to true/false depending on outcome. 3598 3599 3600 # Appends a string to a path variable, only adding the : when needed. 3601 3602 3603 # Prepends a string to a path variable, only adding the : when needed. 3604 3605 3606 # This will make sure the given variable points to a full and proper 3607 # path. This means: 3608 # 1) There will be no spaces in the path. On unix platforms, 3609 # spaces in the path will result in an error. On Windows, 3610 # the path will be rewritten using short-style to be space-free. 3611 # 2) The path will be absolute, and it will be in unix-style (on 3612 # cygwin). 3613 # $1: The name of the variable to fix 3614 3615 3616 # This will make sure the given variable points to a executable 3617 # with a full and proper path. This means: 3618 # 1) There will be no spaces in the path. On unix platforms, 3619 # spaces in the path will result in an error. On Windows, 3620 # the path will be rewritten using short-style to be space-free. 3621 # 2) The path will be absolute, and it will be in unix-style (on 3622 # cygwin). 3623 # Any arguments given to the executable is preserved. 3624 # If the input variable does not have a directory specification, then 3625 # it need to be in the PATH. 3626 # $1: The name of the variable to fix 3627 3628 3629 3630 3631 # Register a --with argument but mark it as deprecated 3632 # $1: The name of the with argument to deprecate, not including --with- 3633 3634 3635 # Register a --enable argument but mark it as deprecated 3636 # $1: The name of the with argument to deprecate, not including --enable- 3637 # $2: The name of the argument to deprecate, in shell variable style (i.e. with _ instead of -) 3638 # $3: Messages to user. 3639 3640 3641 3642 3643 # Test that variable $1 denoting a program is not empty. If empty, exit with an error. 3644 # $1: variable to check 3645 3646 3647 # Check that there are no unprocessed overridden variables left. 3648 # If so, they are an incorrect argument and we will exit with an error. 3649 3650 3651 # Setup a tool for the given variable. If correctly specified by the user, 3652 # use that value, otherwise search for the tool using the supplied code snippet. 3653 # $1: variable to set 3654 # $2: code snippet to call to look for the tool 3655 # $3: code snippet to call if variable was used to find tool 3656 3657 3658 # Call BASIC_SETUP_TOOL with AC_PATH_PROGS to locate the tool 3659 # $1: variable to set 3660 # $2: executable name (or list of names) to look for 3661 3662 3663 # Call BASIC_SETUP_TOOL with AC_CHECK_TOOLS to locate the tool 3664 # $1: variable to set 3665 # $2: executable name (or list of names) to look for 3666 3667 3668 # Like BASIC_PATH_PROGS but fails if no tool was found. 3669 # $1: variable to set 3670 # $2: executable name (or list of names) to look for 3671 3672 3673 # Like BASIC_SETUP_TOOL but fails if no tool was found. 3674 # $1: variable to set 3675 # $2: autoconf macro to call to look for the special tool 3676 3677 3678 # Setup the most fundamental tools that relies on not much else to set up, 3679 # but is used by much of the early bootstrap code. 3680 3681 3682 # Setup basic configuration paths, and platform-specific stuff related to PATHs. 3683 3684 3685 # Evaluates platform specific overrides for devkit variables. 3686 # $1: Name of variable 3687 3688 3689 3690 3691 3692 3693 #%%% Simple tools %%% 3694 3695 # Check if we have found a usable version of make 3696 # $1: the path to a potential make binary (or empty) 3697 # $2: the description on how we found this 3698 3699 3700 3701 3702 # Goes looking for a usable version of GNU make. 3703 3704 3705 3706 3707 3708 3709 3710 3711 # Check if build directory is on local disk. If not possible to determine, 3712 # we prefer to claim it's local. 3713 # Argument 1: directory to test 3714 # Argument 2: what to do if it is on local disk 3715 # Argument 3: what to do otherwise (remote disk or failure) 3716 3717 3718 # Check that source files have basic read permissions set. This might 3719 # not be the case in cygwin in certain conditions. 3720 3721 3722 3723 3724 # Check for support for specific options in bash 3725 3726 3727 ################################################################################ 3728 # 3729 # Default make target 3730 # 3731 3732 3733 # Code to run after AC_OUTPUT 3734 3735 3736 # 3737 # Copyright (c) 2011, 2012, Oracle and/or its affiliates. All rights reserved. 3738 # DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. 3739 # 3740 # This code is free software; you can redistribute it and/or modify it 3741 # under the terms of the GNU General Public License version 2 only, as 3742 # published by the Free Software Foundation. Oracle designates this 3743 # particular file as subject to the "Classpath" exception as provided 3744 # by Oracle in the LICENSE file that accompanied this code. 3745 # 3746 # This code is distributed in the hope that it will be useful, but WITHOUT 3747 # ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or 3748 # FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License 3749 # version 2 for more details (a copy is included in the LICENSE file that 3750 # accompanied this code). 3751 # 3752 # You should have received a copy of the GNU General Public License version 3753 # 2 along with this work; if not, write to the Free Software Foundation, 3754 # Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. 3755 # 3756 # Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA 3757 # or visit www.oracle.com if you need additional information or have any 3758 # questions. 3759 # 3760 3761 3762 3763 3764 3765 # Helper function which possibly converts a path using DOS-style short mode. 3766 # If so, the updated path is stored in $new_path. 3767 # $1: The path to check 3768 3769 3770 # Helper function which possibly converts a path using DOS-style short mode. 3771 # If so, the updated path is stored in $new_path. 3772 # $1: The path to check 3773 3774 3775 # FIXME: The BASIC_FIXUP_*_CYGWIN/MSYS is most likely too convoluted 3776 # and could probably be heavily simplified. However, all changes in this 3777 # area tend to need lot of testing in different scenarios, and in lack of 3778 # proper unit testing, cleaning this up has not been deemed worth the effort 3779 # at the moment. 3780 3781 3782 3783 3784 3785 3786 3787 3788 3789 # Setup basic configuration paths, and platform-specific stuff related to PATHs. 3790 3791 3792 3793 3794 # ... then the rest 3795 # 3796 # Copyright (c) 2011, 2015, Oracle and/or its affiliates. All rights reserved. 3797 # DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. 3798 # 3799 # This code is free software; you can redistribute it and/or modify it 3800 # under the terms of the GNU General Public License version 2 only, as 3801 # published by the Free Software Foundation. Oracle designates this 3802 # particular file as subject to the "Classpath" exception as provided 3803 # by Oracle in the LICENSE file that accompanied this code. 3804 # 3805 # This code is distributed in the hope that it will be useful, but WITHOUT 3806 # ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or 3807 # FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License 3808 # version 2 for more details (a copy is included in the LICENSE file that 3809 # accompanied this code). 3810 # 3811 # You should have received a copy of the GNU General Public License version 3812 # 2 along with this work; if not, write to the Free Software Foundation, 3813 # Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. 3814 # 3815 # Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA 3816 # or visit www.oracle.com if you need additional information or have any 3817 # questions. 3818 # 3819 3820 ######################################################################## 3821 # This file handles detection of the Boot JDK. The Boot JDK detection 3822 # process has been developed as a response to solve a complex real-world 3823 # problem. Initially, it was simple, but it has grown as platform after 3824 # platform, idiosyncracy after idiosyncracy has been supported. 3825 # 3826 # The basic idea is this: 3827 # 1) You need an acceptable *) JDK to use as a Boot JDK 3828 # 2) There are several ways to locate a JDK, that are mostly platform 3829 # dependent **) 3830 # 3) You can have multiple JDKs installed 3831 # 4) If possible, configure should try to dig out an acceptable JDK 3832 # automatically, without having to resort to command-line options 3833 # 3834 # *) acceptable means e.g. JDK7 for building JDK8, a complete JDK (with 3835 # javac) and not a JRE, etc. 3836 # 3837 # **) On Windows we typically use a well-known path. 3838 # On MacOSX we typically use the tool java_home. 3839 # On Linux we typically find javac in the $PATH, and then follow a 3840 # chain of symlinks that often ends up in a real JDK. 3841 # 3842 # This leads to the code where we check in different ways to locate a 3843 # JDK, and if one is found, check if it is acceptable. If not, we print 3844 # our reasons for rejecting it (useful when debugging non-working 3845 # configure situations) and continue checking the next one. 3846 ######################################################################## 3847 3848 # Execute the check given as argument, and verify the result 3849 # If the Boot JDK was previously found, do nothing 3850 # $1 A command line (typically autoconf macro) to execute 3851 3852 3853 # Test: Is bootjdk explicitely set by command line arguments? 3854 3855 3856 # Test: Is $JAVA_HOME set? 3857 3858 3859 # Test: Is there a java or javac in the PATH, which is a symlink to the JDK? 3860 3861 3862 # Test: Is there a /usr/libexec/java_home? (Typically on MacOSX) 3863 # $1: Argument to the java_home binary (optional) 3864 3865 3866 # Test: On MacOS X, can we find a boot jdk using /usr/libexec/java_home? 3867 3868 3869 # Look for a jdk in the given path. If there are multiple, try to select the newest. 3870 # If found, set BOOT_JDK and BOOT_JDK_FOUND. 3871 # $1 = Path to directory containing jdk installations. 3872 # $2 = String to append to the found JDK directory to get the proper JDK home 3873 3874 3875 # Call BOOTJDK_FIND_BEST_JDK_IN_DIRECTORY, but use the given 3876 # environmental variable as base for where to look. 3877 # $1 Name of an environmal variable, assumed to point to the Program Files directory. 3878 3879 3880 # Test: Is there a JDK installed in default, well-known locations? 3881 3882 3883 # Check that a command-line tool in the Boot JDK is correct 3884 # $1 = name of variable to assign 3885 # $2 = name of binary 3886 3887 3888 ############################################################################### 3889 # 3890 # We need a Boot JDK to bootstrap the build. 3891 # 3892 3893 3894 3895 3896 3897 # BUILD_JDK: the location of the latest JDK that can run 3898 # on the host system and supports the target class file version 3899 # generated in this JDK build. This variable should only be 3900 # used after the launchers are built. 3901 # 3902 3903 # Execute the check given as argument, and verify the result. 3904 # If the JDK was previously found, do nothing. 3905 # $1 A command line (typically autoconf macro) to execute 3906 3907 3908 # By default the BUILD_JDK is the JDK_OUTPUTDIR. If the target architecture 3909 # is different than the host system doing the build (e.g. cross-compilation), 3910 # a special BUILD_JDK is built as part of the build process. An external 3911 # prebuilt BUILD_JDK can also be supplied. 3912 3913 3914 # 3915 # Copyright (c) 2011, 2016, Oracle and/or its affiliates. All rights reserved. 3916 # DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. 3917 # 3918 # This code is free software; you can redistribute it and/or modify it 3919 # under the terms of the GNU General Public License version 2 only, as 3920 # published by the Free Software Foundation. Oracle designates this 3921 # particular file as subject to the "Classpath" exception as provided 3922 # by Oracle in the LICENSE file that accompanied this code. 3923 # 3924 # This code is distributed in the hope that it will be useful, but WITHOUT 3925 # ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or 3926 # FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License 3927 # version 2 for more details (a copy is included in the LICENSE file that 3928 # accompanied this code). 3929 # 3930 # You should have received a copy of the GNU General Public License version 3931 # 2 along with this work; if not, write to the Free Software Foundation, 3932 # Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. 3933 # 3934 # Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA 3935 # or visit www.oracle.com if you need additional information or have any 3936 # questions. 3937 # 3938 3939 3940 3941 3942 3943 3944 3945 3946 3947 3948 3949 3950 3951 3952 3953 3954 3955 ################################################################################ 3956 # 3957 # Runs icecc-create-env once and prints the error if it fails 3958 # 3959 # $1: arguments to icecc-create-env 3960 # $2: log file 3961 # 3962 3963 3964 ################################################################################ 3965 # 3966 # Optionally enable distributed compilation of native code using icecc/icecream 3967 # 3968 3969 3970 3971 3972 3973 3974 3975 # 3976 # Copyright (c) 2011, 2016, Oracle and/or its affiliates. All rights reserved. 3977 # DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. 3978 # 3979 # This code is free software; you can redistribute it and/or modify it 3980 # under the terms of the GNU General Public License version 2 only, as 3981 # published by the Free Software Foundation. Oracle designates this 3982 # particular file as subject to the "Classpath" exception as provided 3983 # by Oracle in the LICENSE file that accompanied this code. 3984 # 3985 # This code is distributed in the hope that it will be useful, but WITHOUT 3986 # ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or 3987 # FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License 3988 # version 2 for more details (a copy is included in the LICENSE file that 3989 # accompanied this code). 3990 # 3991 # You should have received a copy of the GNU General Public License version 3992 # 2 along with this work; if not, write to the Free Software Foundation, 3993 # Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. 3994 # 3995 # Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA 3996 # or visit www.oracle.com if you need additional information or have any 3997 # questions. 3998 # 3999 4000 # Reset the global CFLAGS/LDFLAGS variables and initialize them with the 4001 # corresponding configure arguments instead 4002 4003 4004 # Setup the sysroot flags and add them to global CFLAGS and LDFLAGS so 4005 # that configure can use them while detecting compilers. 4006 # TOOLCHAIN_TYPE is available here. 4007 # Param 1 - Optional prefix to all variables. (e.g BUILD_) 4008 4009 4010 4011 4012 4013 4014 # Documentation on common flags used for solstudio in HIGHEST. 4015 # 4016 # WARNING: Use of OPTIMIZATION_LEVEL=HIGHEST in your Makefile needs to be 4017 # done with care, there are some assumptions below that need to 4018 # be understood about the use of pointers, and IEEE behavior. 4019 # 4020 # -fns: Use non-standard floating point mode (not IEEE 754) 4021 # -fsimple: Do some simplification of floating point arithmetic (not IEEE 754) 4022 # -fsingle: Use single precision floating point with 'float' 4023 # -xalias_level=basic: Assume memory references via basic pointer types do not alias 4024 # (Source with excessing pointer casting and data access with mixed 4025 # pointer types are not recommended) 4026 # -xbuiltin=%all: Use intrinsic or inline versions for math/std functions 4027 # (If you expect perfect errno behavior, do not use this) 4028 # -xdepend: Loop data dependency optimizations (need -xO3 or higher) 4029 # -xrestrict: Pointer parameters to functions do not overlap 4030 # (Similar to -xalias_level=basic usage, but less obvious sometimes. 4031 # If you pass in multiple pointers to the same data, do not use this) 4032 # -xlibmil: Inline some library routines 4033 # (If you expect perfect errno behavior, do not use this) 4034 # -xlibmopt: Use optimized math routines (CURRENTLY DISABLED) 4035 # (If you expect perfect errno behavior, do not use this) 4036 # Can cause undefined external on Solaris 8 X86 on __sincos, removing for now 4037 4038 # FIXME: this will never happen since sparc != sparcv9, ie 32 bit, which we don't build anymore. 4039 # Bug? 4040 #if test "x$OPENJDK_TARGET_CPU" = xsparc; then 4041 # CFLAGS_JDK="${CFLAGS_JDK} -xmemalign=4s" 4042 # CXXFLAGS_JDK="${CXXFLAGS_JDK} -xmemalign=4s" 4043 #fi 4044 4045 4046 4047 4048 4049 4050 ################################################################################ 4051 # $1 - Either BUILD or TARGET to pick the correct OS/CPU variables to check 4052 # conditionals against. 4053 # $2 - Optional prefix for each variable defined. 4054 4055 4056 # FLAGS_C_COMPILER_CHECK_ARGUMENTS(ARGUMENT: [ARGUMENT], IF_TRUE: [RUN-IF-TRUE], 4057 # IF_FALSE: [RUN-IF-FALSE]) 4058 # ------------------------------------------------------------ 4059 # Check that the C compiler supports an argument 4060 4061 4062 4063 4064 # FLAGS_CXX_COMPILER_CHECK_ARGUMENTS(ARGUMENT: [ARGUMENT], IF_TRUE: [RUN-IF-TRUE], 4065 # IF_FALSE: [RUN-IF-FALSE]) 4066 # ------------------------------------------------------------ 4067 # Check that the C++ compiler supports an argument 4068 4069 4070 4071 4072 # FLAGS_COMPILER_CHECK_ARGUMENTS(ARGUMENT: [ARGUMENT], IF_TRUE: [RUN-IF-TRUE], 4073 # IF_FALSE: [RUN-IF-FALSE]) 4074 # ------------------------------------------------------------ 4075 # Check that the C and C++ compilers support an argument 4076 4077 4078 4079 4080 # FLAGS_LINKER_CHECK_ARGUMENTS(ARGUMENT: [ARGUMENT], IF_TRUE: [RUN-IF-TRUE], 4081 # IF_FALSE: [RUN-IF-FALSE]) 4082 # ------------------------------------------------------------ 4083 # Check that the linker support an argument 4084 4085 4086 4087 4088 4089 4090 # FLAGS_SETUP_GCC6_COMPILER_FLAGS([PREFIX]) 4091 # Arguments: 4092 # $1 - Optional prefix for each variable defined. 4093 4094 4095 # 4096 # Copyright (c) 2011, 2016, Oracle and/or its affiliates. All rights reserved. 4097 # DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. 4098 # 4099 # This code is free software; you can redistribute it and/or modify it 4100 # under the terms of the GNU General Public License version 2 only, as 4101 # published by the Free Software Foundation. Oracle designates this 4102 # particular file as subject to the "Classpath" exception as provided 4103 # by Oracle in the LICENSE file that accompanied this code. 4104 # 4105 # This code is distributed in the hope that it will be useful, but WITHOUT 4106 # ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or 4107 # FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License 4108 # version 2 for more details (a copy is included in the LICENSE file that 4109 # accompanied this code). 4110 # 4111 # You should have received a copy of the GNU General Public License version 4112 # 2 along with this work; if not, write to the Free Software Foundation, 4113 # Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. 4114 # 4115 # Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA 4116 # or visit www.oracle.com if you need additional information or have any 4117 # questions. 4118 # 4119 4120 4121 4122 4123 4124 cygwin_help() { 4125 case $1 in 4126 unzip) 4127 PKGHANDLER_COMMAND="( cd <location of cygwin setup.exe> && cmd /c setup -q -P unzip )" 4128 HELP_MSG="You might be able to fix this by running '$PKGHANDLER_COMMAND'." 4129 ;; 4130 zip) 4131 PKGHANDLER_COMMAND="( cd <location of cygwin setup.exe> && cmd /c setup -q -P zip )" 4132 HELP_MSG="You might be able to fix this by running '$PKGHANDLER_COMMAND'." 4133 ;; 4134 make) 4135 PKGHANDLER_COMMAND="( cd <location of cygwin setup.exe> && cmd /c setup -q -P make )" 4136 HELP_MSG="You might be able to fix this by running '$PKGHANDLER_COMMAND'." 4137 ;; 4138 freetype) 4139 HELP_MSG=" 4140 The freetype library can now be build during the configure process. 4141 Download the freetype sources and unpack them into an arbitrary directory: 4142 4143 wget http://download.savannah.gnu.org/releases/freetype/freetype-2.5.3.tar.gz 4144 tar -xzf freetype-2.5.3.tar.gz 4145 4146 Then run configure with '--with-freetype-src=<freetype_src>'. This will 4147 automatically build the freetype library into '<freetype_src>/lib64' for 64-bit 4148 builds or into '<freetype_src>/lib32' for 32-bit builds. 4149 Afterwards you can always use '--with-freetype-include=<freetype_src>/include' 4150 and '--with-freetype-lib=<freetype_src>/lib32|64' for other builds. 4151 4152 Alternatively you can unpack the sources like this to use the default directory: 4153 4154 tar --one-top-level=$HOME/freetype --strip-components=1 -xzf freetype-2.5.3.tar.gz" 4155 ;; 4156 esac 4157 } 4158 4159 msys_help() { 4160 PKGHANDLER_COMMAND="" 4161 } 4162 4163 apt_help() { 4164 case $1 in 4165 reduced) 4166 PKGHANDLER_COMMAND="sudo apt-get install gcc-multilib g++-multilib" ;; 4167 devkit) 4168 PKGHANDLER_COMMAND="sudo apt-get install build-essential" ;; 4169 openjdk) 4170 PKGHANDLER_COMMAND="sudo apt-get install openjdk-8-jdk" ;; 4171 alsa) 4172 PKGHANDLER_COMMAND="sudo apt-get install libasound2-dev" ;; 4173 cups) 4174 PKGHANDLER_COMMAND="sudo apt-get install libcups2-dev" ;; 4175 freetype) 4176 PKGHANDLER_COMMAND="sudo apt-get install libfreetype6-dev" ;; 4177 ffi) 4178 PKGHANDLER_COMMAND="sudo apt-get install libffi-dev" ;; 4179 x11) 4180 PKGHANDLER_COMMAND="sudo apt-get install libX11-dev libxext-dev libxrender-dev libxtst-dev libxt-dev" ;; 4181 ccache) 4182 PKGHANDLER_COMMAND="sudo apt-get install ccache" ;; 4183 dtrace) 4184 PKGHANDLER_COMMAND="sudo apt-get install systemtap-sdt-dev" ;; 4185 esac 4186 } 4187 4188 yum_help() { 4189 case $1 in 4190 devkit) 4191 PKGHANDLER_COMMAND="sudo yum groupinstall \"Development Tools\"" ;; 4192 openjdk) 4193 PKGHANDLER_COMMAND="sudo yum install java-1.8.0-openjdk-devel" ;; 4194 alsa) 4195 PKGHANDLER_COMMAND="sudo yum install alsa-lib-devel" ;; 4196 cups) 4197 PKGHANDLER_COMMAND="sudo yum install cups-devel" ;; 4198 freetype) 4199 PKGHANDLER_COMMAND="sudo yum install freetype-devel" ;; 4200 x11) 4201 PKGHANDLER_COMMAND="sudo yum install libXtst-devel libXt-devel libXrender-devel libXi-devel" ;; 4202 ccache) 4203 PKGHANDLER_COMMAND="sudo yum install ccache" ;; 4204 esac 4205 } 4206 4207 port_help() { 4208 PKGHANDLER_COMMAND="" 4209 } 4210 4211 pkgutil_help() { 4212 PKGHANDLER_COMMAND="" 4213 } 4214 4215 pkgadd_help() { 4216 PKGHANDLER_COMMAND="" 4217 } 4218 4219 # This function will check if we're called from the "configure" wrapper while 4220 # printing --help. If so, we will print out additional information that can 4221 # only be extracted within the autoconf script, and then exit. This must be 4222 # called at the very beginning in configure.ac. 4223 4224 4225 4226 4227 4228 4229 # 4230 # Copyright (c) 2011, 2016, Oracle and/or its affiliates. All rights reserved. 4231 # DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. 4232 # 4233 # This code is free software; you can redistribute it and/or modify it 4234 # under the terms of the GNU General Public License version 2 only, as 4235 # published by the Free Software Foundation. Oracle designates this 4236 # particular file as subject to the "Classpath" exception as provided 4237 # by Oracle in the LICENSE file that accompanied this code. 4238 # 4239 # This code is distributed in the hope that it will be useful, but WITHOUT 4240 # ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or 4241 # FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License 4242 # version 2 for more details (a copy is included in the LICENSE file that 4243 # accompanied this code). 4244 # 4245 # You should have received a copy of the GNU General Public License version 4246 # 2 along with this work; if not, write to the Free Software Foundation, 4247 # Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. 4248 # 4249 # Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA 4250 # or visit www.oracle.com if you need additional information or have any 4251 # questions. 4252 # 4253 4254 # All valid JVM features, regardless of platform 4255 VALID_JVM_FEATURES="compiler1 compiler2 zero shark minimal dtrace jvmti jvmci \ 4256 fprof vm-structs jni-check services management all-gcs nmt cds static-build" 4257 4258 # All valid JVM variants 4259 VALID_JVM_VARIANTS="server client minimal core zero zeroshark custom" 4260 4261 ############################################################################### 4262 # Check if the specified JVM variant should be built. To be used in shell if 4263 # constructs, like this: 4264 # if HOTSPOT_CHECK_JVM_VARIANT(server); then 4265 # 4266 # Only valid to use after HOTSPOT_SETUP_JVM_VARIANTS has setup variants. 4267 4268 # Definition kept in one line to allow inlining in if statements. 4269 # Additional [] needed to keep m4 from mangling shell constructs. 4270 4271 4272 ############################################################################### 4273 # Check if the specified JVM features are explicitly enabled. To be used in 4274 # shell if constructs, like this: 4275 # if HOTSPOT_CHECK_JVM_FEATURE(jvmti); then 4276 # 4277 # Only valid to use after HOTSPOT_SETUP_JVM_FEATURES has setup features. 4278 4279 # Definition kept in one line to allow inlining in if statements. 4280 # Additional [] needed to keep m4 from mangling shell constructs. 4281 4282 4283 ############################################################################### 4284 # Check which variants of the JVM that we want to build. Available variants are: 4285 # server: normal interpreter, and a tiered C1/C2 compiler 4286 # client: normal interpreter, and C1 (no C2 compiler) 4287 # minimal: reduced form of client with optional features stripped out 4288 # core: normal interpreter only, no compiler 4289 # zero: C++ based interpreter only, no compiler 4290 # zeroshark: C++ based interpreter, and a llvm-based compiler 4291 # custom: baseline JVM with no default features 4292 # 4293 4294 4295 ############################################################################### 4296 # Check if dtrace should be enabled and has all prerequisites present. 4297 # 4298 4299 4300 ############################################################################### 4301 # Set up all JVM features for each JVM variant. 4302 # 4303 4304 4305 ############################################################################### 4306 # Validate JVM features once all setup is complete, including custom setup. 4307 # 4308 4309 4310 ################################################################################ 4311 # Check if gtest should be built 4312 # 4313 4314 4315 # 4316 # Copyright (c) 2011, 2016, Oracle and/or its affiliates. All rights reserved. 4317 # DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. 4318 # 4319 # This code is free software; you can redistribute it and/or modify it 4320 # under the terms of the GNU General Public License version 2 only, as 4321 # published by the Free Software Foundation. Oracle designates this 4322 # particular file as subject to the "Classpath" exception as provided 4323 # by Oracle in the LICENSE file that accompanied this code. 4324 # 4325 # This code is distributed in the hope that it will be useful, but WITHOUT 4326 # ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or 4327 # FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License 4328 # version 2 for more details (a copy is included in the LICENSE file that 4329 # accompanied this code). 4330 # 4331 # You should have received a copy of the GNU General Public License version 4332 # 2 along with this work; if not, write to the Free Software Foundation, 4333 # Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. 4334 # 4335 # Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA 4336 # or visit www.oracle.com if you need additional information or have any 4337 # questions. 4338 # 4339 4340 ############################################################################### 4341 # Check which variant of the JDK that we want to build. 4342 # Currently we have: 4343 # normal: standard edition 4344 # but the custom make system may add other variants 4345 # 4346 # Effectively the JDK variant gives a name to a specific set of 4347 # modules to compile into the JDK. 4348 4349 4350 ############################################################################### 4351 # Set the debug level 4352 # release: no debug information, all optimizations, no asserts. 4353 # optimized: no debug information, all optimizations, no asserts, HotSpot target is 'optimized'. 4354 # fastdebug: debug information (-g), all optimizations, all asserts 4355 # slowdebug: debug information (-g), no optimizations, all asserts 4356 4357 4358 ############################################################################### 4359 # 4360 # Should we build only OpenJDK even if closed sources are present? 4361 # 4362 4363 4364 4365 4366 ############################################################################### 4367 # 4368 # Enable or disable the elliptic curve crypto implementation 4369 # 4370 4371 4372 4373 4374 ################################################################################ 4375 # 4376 # Gcov coverage data for hotspot 4377 # 4378 4379 4380 ################################################################################ 4381 # 4382 # Static build support. When enabled will generate static 4383 # libraries instead of shared libraries for all JDK libs. 4384 # 4385 4386 4387 ################################################################################ 4388 # 4389 # jlink options. 4390 # We always keep packaged modules in JDK image. 4391 # 4392 4393 4394 ################################################################################ 4395 # 4396 # Check if building of the jtreg failure handler should be enabled. 4397 # 4398 4399 4400 ################################################################################ 4401 # 4402 # Enable or disable generation of the classlist at build time 4403 # 4404 4405 4406 # 4407 # Copyright (c) 2015, Oracle and/or its affiliates. All rights reserved. 4408 # DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. 4409 # 4410 # This code is free software; you can redistribute it and/or modify it 4411 # under the terms of the GNU General Public License version 2 only, as 4412 # published by the Free Software Foundation. Oracle designates this 4413 # particular file as subject to the "Classpath" exception as provided 4414 # by Oracle in the LICENSE file that accompanied this code. 4415 # 4416 # This code is distributed in the hope that it will be useful, but WITHOUT 4417 # ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or 4418 # FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License 4419 # version 2 for more details (a copy is included in the LICENSE file that 4420 # accompanied this code). 4421 # 4422 # You should have received a copy of the GNU General Public License version 4423 # 2 along with this work; if not, write to the Free Software Foundation, 4424 # Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. 4425 # 4426 # Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA 4427 # or visit www.oracle.com if you need additional information or have any 4428 # questions. 4429 # 4430 4431 ############################################################################### 4432 # 4433 # Setup version numbers 4434 # 4435 4436 # Verify that a given string represents a valid version number, and assign it 4437 # to a variable. 4438 4439 # Argument 1: the variable to assign to 4440 # Argument 2: the value given by the user 4441 4442 4443 4444 4445 # 4446 # Copyright (c) 2011, 2016, Oracle and/or its affiliates. All rights reserved. 4447 # DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. 4448 # 4449 # This code is free software; you can redistribute it and/or modify it 4450 # under the terms of the GNU General Public License version 2 only, as 4451 # published by the Free Software Foundation. Oracle designates this 4452 # particular file as subject to the "Classpath" exception as provided 4453 # by Oracle in the LICENSE file that accompanied this code. 4454 # 4455 # This code is distributed in the hope that it will be useful, but WITHOUT 4456 # ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or 4457 # FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License 4458 # version 2 for more details (a copy is included in the LICENSE file that 4459 # accompanied this code). 4460 # 4461 # You should have received a copy of the GNU General Public License version 4462 # 2 along with this work; if not, write to the Free Software Foundation, 4463 # Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. 4464 # 4465 # Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA 4466 # or visit www.oracle.com if you need additional information or have any 4467 # questions. 4468 # 4469 4470 # Major library component reside in separate files. 4471 # 4472 # Copyright (c) 2011, 2015, Oracle and/or its affiliates. All rights reserved. 4473 # DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. 4474 # 4475 # This code is free software; you can redistribute it and/or modify it 4476 # under the terms of the GNU General Public License version 2 only, as 4477 # published by the Free Software Foundation. Oracle designates this 4478 # particular file as subject to the "Classpath" exception as provided 4479 # by Oracle in the LICENSE file that accompanied this code. 4480 # 4481 # This code is distributed in the hope that it will be useful, but WITHOUT 4482 # ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or 4483 # FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License 4484 # version 2 for more details (a copy is included in the LICENSE file that 4485 # accompanied this code). 4486 # 4487 # You should have received a copy of the GNU General Public License version 4488 # 2 along with this work; if not, write to the Free Software Foundation, 4489 # Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. 4490 # 4491 # Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA 4492 # or visit www.oracle.com if you need additional information or have any 4493 # questions. 4494 # 4495 4496 ################################################################################ 4497 # Setup alsa (Advanced Linux Sound Architecture) 4498 ################################################################################ 4499 4500 4501 # 4502 # Copyright (c) 2011, 2015, Oracle and/or its affiliates. All rights reserved. 4503 # DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. 4504 # 4505 # This code is free software; you can redistribute it and/or modify it 4506 # under the terms of the GNU General Public License version 2 only, as 4507 # published by the Free Software Foundation. Oracle designates this 4508 # particular file as subject to the "Classpath" exception as provided 4509 # by Oracle in the LICENSE file that accompanied this code. 4510 # 4511 # This code is distributed in the hope that it will be useful, but WITHOUT 4512 # ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or 4513 # FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License 4514 # version 2 for more details (a copy is included in the LICENSE file that 4515 # accompanied this code). 4516 # 4517 # You should have received a copy of the GNU General Public License version 4518 # 2 along with this work; if not, write to the Free Software Foundation, 4519 # Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. 4520 # 4521 # Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA 4522 # or visit www.oracle.com if you need additional information or have any 4523 # questions. 4524 # 4525 4526 ################################################################################ 4527 # Setup bundled libraries. 4528 # 4529 # For libjpeg, giflib, libpng, lcms2 and zlib, the source is present in the 4530 # OpenJDK repository. Default is to use these libraries as bundled, but they 4531 # might be replaced by en external version by the user. 4532 ################################################################################ 4533 4534 4535 ################################################################################ 4536 # Setup libjpeg 4537 ################################################################################ 4538 4539 4540 ################################################################################ 4541 # Setup giflib 4542 ################################################################################ 4543 4544 4545 ################################################################################ 4546 # Setup libpng 4547 ################################################################################ 4548 4549 4550 ################################################################################ 4551 # Setup zlib 4552 ################################################################################ 4553 4554 4555 ################################################################################ 4556 # Setup lcms (Little CMS) 4557 ################################################################################ 4558 4559 4560 # 4561 # Copyright (c) 2011, 2016, Oracle and/or its affiliates. All rights reserved. 4562 # DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. 4563 # 4564 # This code is free software; you can redistribute it and/or modify it 4565 # under the terms of the GNU General Public License version 2 only, as 4566 # published by the Free Software Foundation. Oracle designates this 4567 # particular file as subject to the "Classpath" exception as provided 4568 # by Oracle in the LICENSE file that accompanied this code. 4569 # 4570 # This code is distributed in the hope that it will be useful, but WITHOUT 4571 # ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or 4572 # FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License 4573 # version 2 for more details (a copy is included in the LICENSE file that 4574 # accompanied this code). 4575 # 4576 # You should have received a copy of the GNU General Public License version 4577 # 2 along with this work; if not, write to the Free Software Foundation, 4578 # Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. 4579 # 4580 # Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA 4581 # or visit www.oracle.com if you need additional information or have any 4582 # questions. 4583 # 4584 4585 ################################################################################ 4586 # Setup cups (Common Unix Printing System) 4587 ################################################################################ 4588 4589 4590 # 4591 # Copyright (c) 2015, Oracle and/or its affiliates. All rights reserved. 4592 # DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. 4593 # 4594 # This code is free software; you can redistribute it and/or modify it 4595 # under the terms of the GNU General Public License version 2 only, as 4596 # published by the Free Software Foundation. Oracle designates this 4597 # particular file as subject to the "Classpath" exception as provided 4598 # by Oracle in the LICENSE file that accompanied this code. 4599 # 4600 # This code is distributed in the hope that it will be useful, but WITHOUT 4601 # ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or 4602 # FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License 4603 # version 2 for more details (a copy is included in the LICENSE file that 4604 # accompanied this code). 4605 # 4606 # You should have received a copy of the GNU General Public License version 4607 # 2 along with this work; if not, write to the Free Software Foundation, 4608 # Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. 4609 # 4610 # Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA 4611 # or visit www.oracle.com if you need additional information or have any 4612 # questions. 4613 # 4614 4615 ################################################################################ 4616 # Setup libffi (Foreign Function Interface) 4617 ################################################################################ 4618 4619 4620 # 4621 # Copyright (c) 2011, 2015, Oracle and/or its affiliates. All rights reserved. 4622 # DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. 4623 # 4624 # This code is free software; you can redistribute it and/or modify it 4625 # under the terms of the GNU General Public License version 2 only, as 4626 # published by the Free Software Foundation. Oracle designates this 4627 # particular file as subject to the "Classpath" exception as provided 4628 # by Oracle in the LICENSE file that accompanied this code. 4629 # 4630 # This code is distributed in the hope that it will be useful, but WITHOUT 4631 # ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or 4632 # FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License 4633 # version 2 for more details (a copy is included in the LICENSE file that 4634 # accompanied this code). 4635 # 4636 # You should have received a copy of the GNU General Public License version 4637 # 2 along with this work; if not, write to the Free Software Foundation, 4638 # Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. 4639 # 4640 # Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA 4641 # or visit www.oracle.com if you need additional information or have any 4642 # questions. 4643 # 4644 4645 ################################################################################ 4646 # Build the freetype lib from source 4647 ################################################################################ 4648 4649 4650 ################################################################################ 4651 # Check if a potential freeype library match is correct and usable 4652 ################################################################################ 4653 4654 4655 ################################################################################ 4656 # Setup freetype (The FreeType2 font rendering library) 4657 ################################################################################ 4658 4659 4660 # 4661 # Copyright (c) 2011, 2016, Oracle and/or its affiliates. All rights reserved. 4662 # DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. 4663 # 4664 # This code is free software; you can redistribute it and/or modify it 4665 # under the terms of the GNU General Public License version 2 only, as 4666 # published by the Free Software Foundation. Oracle designates this 4667 # particular file as subject to the "Classpath" exception as provided 4668 # by Oracle in the LICENSE file that accompanied this code. 4669 # 4670 # This code is distributed in the hope that it will be useful, but WITHOUT 4671 # ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or 4672 # FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License 4673 # version 2 for more details (a copy is included in the LICENSE file that 4674 # accompanied this code). 4675 # 4676 # You should have received a copy of the GNU General Public License version 4677 # 2 along with this work; if not, write to the Free Software Foundation, 4678 # Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. 4679 # 4680 # Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA 4681 # or visit www.oracle.com if you need additional information or have any 4682 # questions. 4683 # 4684 4685 ################################################################################ 4686 # Setup the standard C/C++ runtime libraries. 4687 # 4688 # Most importantly, determine if stdc++ should be linked statically or 4689 # dynamically. 4690 ################################################################################ 4691 4692 4693 # 4694 # Copyright (c) 2011, 2015, Oracle and/or its affiliates. All rights reserved. 4695 # DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. 4696 # 4697 # This code is free software; you can redistribute it and/or modify it 4698 # under the terms of the GNU General Public License version 2 only, as 4699 # published by the Free Software Foundation. Oracle designates this 4700 # particular file as subject to the "Classpath" exception as provided 4701 # by Oracle in the LICENSE file that accompanied this code. 4702 # 4703 # This code is distributed in the hope that it will be useful, but WITHOUT 4704 # ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or 4705 # FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License 4706 # version 2 for more details (a copy is included in the LICENSE file that 4707 # accompanied this code). 4708 # 4709 # You should have received a copy of the GNU General Public License version 4710 # 2 along with this work; if not, write to the Free Software Foundation, 4711 # Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. 4712 # 4713 # Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA 4714 # or visit www.oracle.com if you need additional information or have any 4715 # questions. 4716 # 4717 4718 ################################################################################ 4719 # Setup X11 Windows system 4720 ################################################################################ 4721 4722 4723 4724 ################################################################################ 4725 # Determine which libraries are needed for this configuration 4726 ################################################################################ 4727 4728 4729 ################################################################################ 4730 # Parse library options, and setup needed libraries 4731 ################################################################################ 4732 4733 4734 ################################################################################ 4735 # Setup llvm (Low-Level VM) 4736 ################################################################################ 4737 4738 4739 ################################################################################ 4740 # Setup various libraries, typically small system libraries 4741 ################################################################################ 4742 4743 4744 ################################################################################ 4745 # libstlport.so.1 is needed for running gtest on Solaris. Find it to 4746 # redistribute it in the test image. 4747 ################################################################################ 4748 4749 4750 4751 # 4752 # Copyright (c) 2011, 2016, Oracle and/or its affiliates. All rights reserved. 4753 # DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. 4754 # 4755 # This code is free software; you can redistribute it and/or modify it 4756 # under the terms of the GNU General Public License version 2 only, as 4757 # published by the Free Software Foundation. Oracle designates this 4758 # particular file as subject to the "Classpath" exception as provided 4759 # by Oracle in the LICENSE file that accompanied this code. 4760 # 4761 # This code is distributed in the hope that it will be useful, but WITHOUT 4762 # ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or 4763 # FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License 4764 # version 2 for more details (a copy is included in the LICENSE file that 4765 # accompanied this code). 4766 # 4767 # You should have received a copy of the GNU General Public License version 4768 # 2 along with this work; if not, write to the Free Software Foundation, 4769 # Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. 4770 # 4771 # Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA 4772 # or visit www.oracle.com if you need additional information or have any 4773 # questions. 4774 # 4775 4776 # Support macro for PLATFORM_EXTRACT_TARGET_AND_BUILD. 4777 # Converts autoconf style CPU name to OpenJDK style, into 4778 # VAR_CPU, VAR_CPU_ARCH, VAR_CPU_BITS and VAR_CPU_ENDIAN. 4779 4780 4781 # Support macro for PLATFORM_EXTRACT_TARGET_AND_BUILD. 4782 # Converts autoconf style OS name to OpenJDK style, into 4783 # VAR_OS, VAR_OS_TYPE and VAR_OS_ENV. 4784 4785 4786 # Expects $host_os $host_cpu $build_os and $build_cpu 4787 # and $with_target_bits to have been setup! 4788 # 4789 # Translate the standard triplet(quadruplet) definition 4790 # of the target/build system into OPENJDK_TARGET_OS, OPENJDK_TARGET_CPU, 4791 # OPENJDK_BUILD_OS, etc. 4792 4793 4794 # Check if a reduced build (32-bit on 64-bit platforms) is requested, and modify behaviour 4795 # accordingly. Must be done after setting up build and target system, but before 4796 # doing anything else with these values. 4797 4798 4799 # Setup the legacy variables, for controlling the old makefiles. 4800 # 4801 4802 4803 # $1 - Either TARGET or BUILD to setup the variables for. 4804 4805 4806 4807 4808 #%%% Build and target systems %%% 4809 4810 4811 4812 4813 # Support macro for PLATFORM_SETUP_OPENJDK_TARGET_BITS. 4814 # Add -mX to various FLAGS variables. 4815 4816 4817 4818 4819 4820 4821 # 4822 # Copyright (c) 2011, 2015, Oracle and/or its affiliates. All rights reserved. 4823 # DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. 4824 # 4825 # This code is free software; you can redistribute it and/or modify it 4826 # under the terms of the GNU General Public License version 2 only, as 4827 # published by the Free Software Foundation. Oracle designates this 4828 # particular file as subject to the "Classpath" exception as provided 4829 # by Oracle in the LICENSE file that accompanied this code. 4830 # 4831 # This code is distributed in the hope that it will be useful, but WITHOUT 4832 # ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or 4833 # FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License 4834 # version 2 for more details (a copy is included in the LICENSE file that 4835 # accompanied this code). 4836 # 4837 # You should have received a copy of the GNU General Public License version 4838 # 2 along with this work; if not, write to the Free Software Foundation, 4839 # Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. 4840 # 4841 # Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA 4842 # or visit www.oracle.com if you need additional information or have any 4843 # questions. 4844 # 4845 4846 4847 4848 4849 4850 4851 4852 ################################################################################ 4853 # Define a mechanism for importing extra prebuilt modules 4854 # 4855 4856 4857 4858 # 4859 # Copyright (c) 2011, 2016, Oracle and/or its affiliates. All rights reserved. 4860 # DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. 4861 # 4862 # This code is free software; you can redistribute it and/or modify it 4863 # under the terms of the GNU General Public License version 2 only, as 4864 # published by the Free Software Foundation. Oracle designates this 4865 # particular file as subject to the "Classpath" exception as provided 4866 # by Oracle in the LICENSE file that accompanied this code. 4867 # 4868 # This code is distributed in the hope that it will be useful, but WITHOUT 4869 # ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or 4870 # FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License 4871 # version 2 for more details (a copy is included in the LICENSE file that 4872 # accompanied this code). 4873 # 4874 # You should have received a copy of the GNU General Public License version 4875 # 2 along with this work; if not, write to the Free Software Foundation, 4876 # Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. 4877 # 4878 # Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA 4879 # or visit www.oracle.com if you need additional information or have any 4880 # questions. 4881 # 4882 4883 ######################################################################## 4884 # This file is responsible for detecting, verifying and setting up the 4885 # toolchain, i.e. the compiler, linker and related utilities. It will setup 4886 # proper paths to the binaries, but it will not setup any flags. 4887 # 4888 # The binaries used is determined by the toolchain type, which is the family of 4889 # compilers and related tools that are used. 4890 ######################################################################## 4891 4892 4893 # All valid toolchains, regardless of platform (used by help.m4) 4894 VALID_TOOLCHAINS_all="gcc clang solstudio xlc microsoft" 4895 4896 # These toolchains are valid on different platforms 4897 VALID_TOOLCHAINS_linux="gcc clang" 4898 VALID_TOOLCHAINS_solaris="solstudio" 4899 VALID_TOOLCHAINS_macosx="gcc clang" 4900 VALID_TOOLCHAINS_aix="xlc" 4901 VALID_TOOLCHAINS_windows="microsoft" 4902 4903 # Toolchain descriptions 4904 TOOLCHAIN_DESCRIPTION_clang="clang/LLVM" 4905 TOOLCHAIN_DESCRIPTION_gcc="GNU Compiler Collection" 4906 TOOLCHAIN_DESCRIPTION_microsoft="Microsoft Visual Studio" 4907 TOOLCHAIN_DESCRIPTION_solstudio="Oracle Solaris Studio" 4908 TOOLCHAIN_DESCRIPTION_xlc="IBM XL C/C++" 4909 4910 # Minimum supported versions, empty means unspecified 4911 TOOLCHAIN_MINIMUM_VERSION_clang="3.2" 4912 TOOLCHAIN_MINIMUM_VERSION_gcc="4.3" 4913 TOOLCHAIN_MINIMUM_VERSION_microsoft="" 4914 TOOLCHAIN_MINIMUM_VERSION_solstudio="5.13" 4915 TOOLCHAIN_MINIMUM_VERSION_xlc="" 4916 4917 # Prepare the system so that TOOLCHAIN_CHECK_COMPILER_VERSION can be called. 4918 # Must have CC_VERSION_NUMBER and CXX_VERSION_NUMBER. 4919 # $1 - optional variable prefix for compiler and version variables (BUILD_) 4920 # $2 - optional variable prefix for comparable variable (OPENJDK_BUILD_) 4921 4922 4923 # Check if the configured compiler (C and C++) is of a specific version or 4924 # newer. TOOLCHAIN_PREPARE_FOR_VERSION_COMPARISONS must have been called before. 4925 # 4926 # Arguments: 4927 # VERSION: The version string to check against the found version 4928 # IF_AT_LEAST: block to run if the compiler is at least this version (>=) 4929 # IF_OLDER_THAN: block to run if the compiler is older than this version (<) 4930 # PREFIX: Optional variable prefix for compiler to compare version for (OPENJDK_BUILD_) 4931 4932 4933 4934 4935 # Setup a number of variables describing how native output files are 4936 # named on this platform/toolchain. 4937 4938 4939 # Determine which toolchain type to use, and make sure it is valid for this 4940 # platform. Setup various information about the selected toolchain. 4941 4942 4943 # Before we start detecting the toolchain executables, we might need some 4944 # special setup, e.g. additional paths etc. 4945 4946 4947 # Restore path, etc 4948 4949 4950 # Check if a compiler is of the toolchain type we expect, and save the version 4951 # information from it. If the compiler does not match the expected type, 4952 # this function will abort using AC_MSG_ERROR. If it matches, the version will 4953 # be stored in CC_VERSION_NUMBER/CXX_VERSION_NUMBER (as a dotted number), and 4954 # the full version string in CC_VERSION_STRING/CXX_VERSION_STRING. 4955 # 4956 # $1 = compiler to test (CC or CXX) 4957 # $2 = human readable name of compiler (C or C++) 4958 4959 4960 # Try to locate the given C or C++ compiler in the path, or otherwise. 4961 # 4962 # $1 = compiler to test (CC or CXX) 4963 # $2 = human readable name of compiler (C or C++) 4964 # $3 = list of compiler names to search for 4965 4966 4967 # Detect the core components of the toolchain, i.e. the compilers (CC and CXX), 4968 # preprocessor (CPP and CXXCPP), the linker (LD), the assembler (AS) and the 4969 # archiver (AR). Verify that the compilers are correct according to the 4970 # toolchain type. 4971 4972 4973 # Setup additional tools that is considered a part of the toolchain, but not the 4974 # core part. Many of these are highly platform-specific and do not exist, 4975 # and/or are not needed on all platforms. 4976 4977 4978 # Setup the build tools (i.e, the compiler and linker used to build programs 4979 # that should be run on the build platform, not the target platform, as a build 4980 # helper). Since the non-cross-compile case uses the normal, target compilers 4981 # for this, we can only do this after these have been setup. 4982 4983 4984 # Setup legacy variables that are still needed as alternative ways to refer to 4985 # parts of the toolchain. 4986 4987 4988 # Do some additional checks on the detected tools. 4989 4990 4991 # Setup the JTReg Regression Test Harness. 4992 4993 4994 # 4995 # Copyright (c) 2011, 2012, Oracle and/or its affiliates. All rights reserved. 4996 # DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. 4997 # 4998 # This code is free software; you can redistribute it and/or modify it 4999 # under the terms of the GNU General Public License version 2 only, as 5000 # published by the Free Software Foundation. Oracle designates this 5001 # particular file as subject to the "Classpath" exception as provided 5002 # by Oracle in the LICENSE file that accompanied this code. 5003 # 5004 # This code is distributed in the hope that it will be useful, but WITHOUT 5005 # ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or 5006 # FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License 5007 # version 2 for more details (a copy is included in the LICENSE file that 5008 # accompanied this code). 5009 # 5010 # You should have received a copy of the GNU General Public License version 5011 # 2 along with this work; if not, write to the Free Software Foundation, 5012 # Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. 5013 # 5014 # Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA 5015 # or visit www.oracle.com if you need additional information or have any 5016 # questions. 5017 # 5018 5019 ################################################################################ 5020 # The order of these defines the priority by which we try to find them. 5021 VALID_VS_VERSIONS="2013 2012 2010" 5022 5023 VS_DESCRIPTION_2010="Microsoft Visual Studio 2010" 5024 VS_VERSION_INTERNAL_2010=100 5025 VS_MSVCR_2010=msvcr100.dll 5026 # We don't use msvcp on Visual Studio 2010 5027 #VS_MSVCP_2010=msvcp100.dll 5028 VS_ENVVAR_2010="VS100COMNTOOLS" 5029 VS_VS_INSTALLDIR_2010="Microsoft Visual Studio 10.0" 5030 VS_SDK_INSTALLDIR_2010="Microsoft SDKs/Windows/v7.1" 5031 VS_VS_PLATFORM_NAME_2010="v100" 5032 VS_SDK_PLATFORM_NAME_2010="Windows7.1SDK" 5033 5034 VS_DESCRIPTION_2012="Microsoft Visual Studio 2012" 5035 VS_VERSION_INTERNAL_2012=110 5036 VS_MSVCR_2012=msvcr110.dll 5037 VS_MSVCP_2012=msvcp110.dll 5038 VS_ENVVAR_2012="VS110COMNTOOLS" 5039 VS_VS_INSTALLDIR_2012="Microsoft Visual Studio 11.0" 5040 VS_SDK_INSTALLDIR_2012= 5041 VS_VS_PLATFORM_NAME_2012="v110" 5042 VS_SDK_PLATFORM_NAME_2012= 5043 5044 VS_DESCRIPTION_2013="Microsoft Visual Studio 2013" 5045 VS_VERSION_INTERNAL_2013=120 5046 VS_MSVCR_2013=msvcr120.dll 5047 VS_MSVCP_2013=msvcp120.dll 5048 VS_ENVVAR_2013="VS120COMNTOOLS" 5049 VS_VS_INSTALLDIR_2013="Microsoft Visual Studio 12.0" 5050 VS_SDK_INSTALLDIR_2013= 5051 VS_VS_PLATFORM_NAME_2013="v120" 5052 VS_SDK_PLATFORM_NAME_2013= 5053 5054 ################################################################################ 5055 5056 5057 5058 ################################################################################ 5059 5060 5061 5062 ################################################################################ 5063 # Finds the bat or cmd file in Visual Studio or the SDK that sets up a proper 5064 # build environment and assigns it to VS_ENV_CMD 5065 5066 5067 ################################################################################ 5068 5069 5070 5071 ################################################################################ 5072 # Check if the VS env variables were setup prior to running configure. 5073 # If not, then find vcvarsall.bat and run it automatically, and integrate 5074 # the set env variables into the spec file. 5075 5076 5077 5078 5079 5080 5081 5082 5083 5084 5085 5086 5087 5088 5089 # This line needs to be here, verbatim, after all includes and the dummy hook 5090 # definitions. It is replaced with custom functionality when building 5091 # custom sources. 5092 #CUSTOM_AUTOCONF_INCLUDE 5093 5094 # Do not change or remove the following line, it is needed for consistency checks: 5095 DATE_WHEN_GENERATED=1474894604 5096 5097 ############################################################################### 5098 # 5099 # Initialization / Boot-strapping 5100 # 5101 # The bootstrapping process needs to solve the "chicken or the egg" problem, 5102 # thus it jumps back and forth, each time gaining something needed later on. 5103 # 5104 ############################################################################### 5105 5106 # If we are requested to print additional help, do that and then exit. 5107 # This must be the very first call. 5108 5109 if test "x$CONFIGURE_PRINT_ADDITIONAL_HELP" != x; then 5110 5111 # Print available toolchains 5112 $PRINTF "The following toolchains are available as arguments to --with-toolchain-type.\n" 5113 $PRINTF "Which are valid to use depends on the build platform.\n" 5114 for toolchain in $VALID_TOOLCHAINS_all; do 5115 # Use indirect variable referencing 5116 toolchain_var_name=TOOLCHAIN_DESCRIPTION_$toolchain 5117 TOOLCHAIN_DESCRIPTION=${!toolchain_var_name} 5118 $PRINTF " %-10s %s\n" $toolchain "$TOOLCHAIN_DESCRIPTION" 5119 done 5120 $PRINTF "\n" 5121 5122 # Print available jvm features 5123 $PRINTF "The following JVM features are available as arguments to --with-jvm-features.\n" 5124 $PRINTF "Which are valid to use depends on the target platform.\n " 5125 $PRINTF "%s " $VALID_JVM_FEATURES 5126 $PRINTF "\n" 5127 5128 # And now exit directly 5129 exit 0 5130 fi 5131 5132 5133 # Basic initialization that must happen first of all in the normal process. 5134 5135 # Save the original command line. This is passed to us by the wrapper configure script. 5136 5137 # Save the path variable before it gets changed 5138 ORIGINAL_PATH="$PATH" 5139 5140 DATE_WHEN_CONFIGURED=`LANG=C date` 5141 5142 { $as_echo "$as_me:${as_lineno-$LINENO}: Configuration created at $DATE_WHEN_CONFIGURED." >&5 5143 $as_echo "$as_me: Configuration created at $DATE_WHEN_CONFIGURED." >&6;} 5144 { $as_echo "$as_me:${as_lineno-$LINENO}: configure script generated at timestamp $DATE_WHEN_GENERATED." >&5 5145 $as_echo "$as_me: configure script generated at timestamp $DATE_WHEN_GENERATED." >&6;} 5146 5147 5148 # Start with tools that do not need have cross compilation support 5149 # and can be expected to be found in the default PATH. These tools are 5150 # used by configure. 5151 5152 # First are all the simple required tools. 5153 5154 5155 5156 # Publish this variable in the help. 5157 5158 5159 if [ -z "${BASENAME+x}" ]; then 5160 # The variable is not set by user, try to locate tool using the code snippet 5161 for ac_prog in basename 5162 do 5163 # Extract the first word of "$ac_prog", so it can be a program name with args. 5164 set dummy $ac_prog; ac_word=$2 5165 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 5166 $as_echo_n "checking for $ac_word... " >&6; } 5167 if ${ac_cv_path_BASENAME+:} false; then : 5168 $as_echo_n "(cached) " >&6 5169 else 5170 case $BASENAME in 5171 [\\/]* | ?:[\\/]*) 5172 ac_cv_path_BASENAME="$BASENAME" # Let the user override the test with a path. 5173 ;; 5174 *) 5175 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 5176 for as_dir in $PATH 5177 do 5178 IFS=$as_save_IFS 5179 test -z "$as_dir" && as_dir=. 5180 for ac_exec_ext in '' $ac_executable_extensions; do 5181 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 5182 ac_cv_path_BASENAME="$as_dir/$ac_word$ac_exec_ext" 5183 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 5184 break 2 5185 fi 5186 done 5187 done 5188 IFS=$as_save_IFS 5189 5190 ;; 5191 esac 5192 fi 5193 BASENAME=$ac_cv_path_BASENAME 5194 if test -n "$BASENAME"; then 5195 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BASENAME" >&5 5196 $as_echo "$BASENAME" >&6; } 5197 else 5198 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 5199 $as_echo "no" >&6; } 5200 fi 5201 5202 5203 test -n "$BASENAME" && break 5204 done 5205 5206 else 5207 # The variable is set, but is it from the command line or the environment? 5208 5209 # Try to remove the string !BASENAME! from our list. 5210 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!BASENAME!/} 5211 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 5212 # If it failed, the variable was not from the command line. Ignore it, 5213 # but warn the user (except for BASH, which is always set by the calling BASH). 5214 if test "xBASENAME" != xBASH; then 5215 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of BASENAME from the environment. Use command line variables instead." >&5 5216 $as_echo "$as_me: WARNING: Ignoring value of BASENAME from the environment. Use command line variables instead." >&2;} 5217 fi 5218 # Try to locate tool using the code snippet 5219 for ac_prog in basename 5220 do 5221 # Extract the first word of "$ac_prog", so it can be a program name with args. 5222 set dummy $ac_prog; ac_word=$2 5223 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 5224 $as_echo_n "checking for $ac_word... " >&6; } 5225 if ${ac_cv_path_BASENAME+:} false; then : 5226 $as_echo_n "(cached) " >&6 5227 else 5228 case $BASENAME in 5229 [\\/]* | ?:[\\/]*) 5230 ac_cv_path_BASENAME="$BASENAME" # Let the user override the test with a path. 5231 ;; 5232 *) 5233 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 5234 for as_dir in $PATH 5235 do 5236 IFS=$as_save_IFS 5237 test -z "$as_dir" && as_dir=. 5238 for ac_exec_ext in '' $ac_executable_extensions; do 5239 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 5240 ac_cv_path_BASENAME="$as_dir/$ac_word$ac_exec_ext" 5241 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 5242 break 2 5243 fi 5244 done 5245 done 5246 IFS=$as_save_IFS 5247 5248 ;; 5249 esac 5250 fi 5251 BASENAME=$ac_cv_path_BASENAME 5252 if test -n "$BASENAME"; then 5253 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BASENAME" >&5 5254 $as_echo "$BASENAME" >&6; } 5255 else 5256 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 5257 $as_echo "no" >&6; } 5258 fi 5259 5260 5261 test -n "$BASENAME" && break 5262 done 5263 5264 else 5265 # If it succeeded, then it was overridden by the user. We will use it 5266 # for the tool. 5267 5268 # First remove it from the list of overridden variables, so we can test 5269 # for unknown variables in the end. 5270 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 5271 5272 # Check if we try to supply an empty value 5273 if test "x$BASENAME" = x; then 5274 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool BASENAME= (no value)" >&5 5275 $as_echo "$as_me: Setting user supplied tool BASENAME= (no value)" >&6;} 5276 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for BASENAME" >&5 5277 $as_echo_n "checking for BASENAME... " >&6; } 5278 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 5279 $as_echo "disabled" >&6; } 5280 else 5281 # Check if the provided tool contains a complete path. 5282 tool_specified="$BASENAME" 5283 tool_basename="${tool_specified##*/}" 5284 if test "x$tool_basename" = "x$tool_specified"; then 5285 # A command without a complete path is provided, search $PATH. 5286 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool BASENAME=$tool_basename" >&5 5287 $as_echo "$as_me: Will search for user supplied tool BASENAME=$tool_basename" >&6;} 5288 # Extract the first word of "$tool_basename", so it can be a program name with args. 5289 set dummy $tool_basename; ac_word=$2 5290 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 5291 $as_echo_n "checking for $ac_word... " >&6; } 5292 if ${ac_cv_path_BASENAME+:} false; then : 5293 $as_echo_n "(cached) " >&6 5294 else 5295 case $BASENAME in 5296 [\\/]* | ?:[\\/]*) 5297 ac_cv_path_BASENAME="$BASENAME" # Let the user override the test with a path. 5298 ;; 5299 *) 5300 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 5301 for as_dir in $PATH 5302 do 5303 IFS=$as_save_IFS 5304 test -z "$as_dir" && as_dir=. 5305 for ac_exec_ext in '' $ac_executable_extensions; do 5306 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 5307 ac_cv_path_BASENAME="$as_dir/$ac_word$ac_exec_ext" 5308 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 5309 break 2 5310 fi 5311 done 5312 done 5313 IFS=$as_save_IFS 5314 5315 ;; 5316 esac 5317 fi 5318 BASENAME=$ac_cv_path_BASENAME 5319 if test -n "$BASENAME"; then 5320 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BASENAME" >&5 5321 $as_echo "$BASENAME" >&6; } 5322 else 5323 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 5324 $as_echo "no" >&6; } 5325 fi 5326 5327 5328 if test "x$BASENAME" = x; then 5329 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 5330 fi 5331 else 5332 # Otherwise we believe it is a complete path. Use it as it is. 5333 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool BASENAME=$tool_specified" >&5 5334 $as_echo "$as_me: Will use user supplied tool BASENAME=$tool_specified" >&6;} 5335 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for BASENAME" >&5 5336 $as_echo_n "checking for BASENAME... " >&6; } 5337 if test ! -x "$tool_specified"; then 5338 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 5339 $as_echo "not found" >&6; } 5340 as_fn_error $? "User supplied tool BASENAME=$tool_specified does not exist or is not executable" "$LINENO" 5 5341 fi 5342 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 5343 $as_echo "$tool_specified" >&6; } 5344 fi 5345 fi 5346 fi 5347 5348 fi 5349 5350 5351 5352 if test "x$BASENAME" = x; then 5353 as_fn_error $? "Could not find required tool for BASENAME" "$LINENO" 5 5354 fi 5355 5356 5357 5358 5359 5360 # Publish this variable in the help. 5361 5362 5363 if [ -z "${BASH+x}" ]; then 5364 # The variable is not set by user, try to locate tool using the code snippet 5365 for ac_prog in bash 5366 do 5367 # Extract the first word of "$ac_prog", so it can be a program name with args. 5368 set dummy $ac_prog; ac_word=$2 5369 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 5370 $as_echo_n "checking for $ac_word... " >&6; } 5371 if ${ac_cv_path_BASH+:} false; then : 5372 $as_echo_n "(cached) " >&6 5373 else 5374 case $BASH in 5375 [\\/]* | ?:[\\/]*) 5376 ac_cv_path_BASH="$BASH" # Let the user override the test with a path. 5377 ;; 5378 *) 5379 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 5380 for as_dir in $PATH 5381 do 5382 IFS=$as_save_IFS 5383 test -z "$as_dir" && as_dir=. 5384 for ac_exec_ext in '' $ac_executable_extensions; do 5385 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 5386 ac_cv_path_BASH="$as_dir/$ac_word$ac_exec_ext" 5387 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 5388 break 2 5389 fi 5390 done 5391 done 5392 IFS=$as_save_IFS 5393 5394 ;; 5395 esac 5396 fi 5397 BASH=$ac_cv_path_BASH 5398 if test -n "$BASH"; then 5399 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BASH" >&5 5400 $as_echo "$BASH" >&6; } 5401 else 5402 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 5403 $as_echo "no" >&6; } 5404 fi 5405 5406 5407 test -n "$BASH" && break 5408 done 5409 5410 else 5411 # The variable is set, but is it from the command line or the environment? 5412 5413 # Try to remove the string !BASH! from our list. 5414 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!BASH!/} 5415 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 5416 # If it failed, the variable was not from the command line. Ignore it, 5417 # but warn the user (except for BASH, which is always set by the calling BASH). 5418 if test "xBASH" != xBASH; then 5419 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of BASH from the environment. Use command line variables instead." >&5 5420 $as_echo "$as_me: WARNING: Ignoring value of BASH from the environment. Use command line variables instead." >&2;} 5421 fi 5422 # Try to locate tool using the code snippet 5423 for ac_prog in bash 5424 do 5425 # Extract the first word of "$ac_prog", so it can be a program name with args. 5426 set dummy $ac_prog; ac_word=$2 5427 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 5428 $as_echo_n "checking for $ac_word... " >&6; } 5429 if ${ac_cv_path_BASH+:} false; then : 5430 $as_echo_n "(cached) " >&6 5431 else 5432 case $BASH in 5433 [\\/]* | ?:[\\/]*) 5434 ac_cv_path_BASH="$BASH" # Let the user override the test with a path. 5435 ;; 5436 *) 5437 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 5438 for as_dir in $PATH 5439 do 5440 IFS=$as_save_IFS 5441 test -z "$as_dir" && as_dir=. 5442 for ac_exec_ext in '' $ac_executable_extensions; do 5443 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 5444 ac_cv_path_BASH="$as_dir/$ac_word$ac_exec_ext" 5445 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 5446 break 2 5447 fi 5448 done 5449 done 5450 IFS=$as_save_IFS 5451 5452 ;; 5453 esac 5454 fi 5455 BASH=$ac_cv_path_BASH 5456 if test -n "$BASH"; then 5457 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BASH" >&5 5458 $as_echo "$BASH" >&6; } 5459 else 5460 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 5461 $as_echo "no" >&6; } 5462 fi 5463 5464 5465 test -n "$BASH" && break 5466 done 5467 5468 else 5469 # If it succeeded, then it was overridden by the user. We will use it 5470 # for the tool. 5471 5472 # First remove it from the list of overridden variables, so we can test 5473 # for unknown variables in the end. 5474 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 5475 5476 # Check if we try to supply an empty value 5477 if test "x$BASH" = x; then 5478 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool BASH= (no value)" >&5 5479 $as_echo "$as_me: Setting user supplied tool BASH= (no value)" >&6;} 5480 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for BASH" >&5 5481 $as_echo_n "checking for BASH... " >&6; } 5482 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 5483 $as_echo "disabled" >&6; } 5484 else 5485 # Check if the provided tool contains a complete path. 5486 tool_specified="$BASH" 5487 tool_basename="${tool_specified##*/}" 5488 if test "x$tool_basename" = "x$tool_specified"; then 5489 # A command without a complete path is provided, search $PATH. 5490 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool BASH=$tool_basename" >&5 5491 $as_echo "$as_me: Will search for user supplied tool BASH=$tool_basename" >&6;} 5492 # Extract the first word of "$tool_basename", so it can be a program name with args. 5493 set dummy $tool_basename; ac_word=$2 5494 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 5495 $as_echo_n "checking for $ac_word... " >&6; } 5496 if ${ac_cv_path_BASH+:} false; then : 5497 $as_echo_n "(cached) " >&6 5498 else 5499 case $BASH in 5500 [\\/]* | ?:[\\/]*) 5501 ac_cv_path_BASH="$BASH" # Let the user override the test with a path. 5502 ;; 5503 *) 5504 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 5505 for as_dir in $PATH 5506 do 5507 IFS=$as_save_IFS 5508 test -z "$as_dir" && as_dir=. 5509 for ac_exec_ext in '' $ac_executable_extensions; do 5510 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 5511 ac_cv_path_BASH="$as_dir/$ac_word$ac_exec_ext" 5512 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 5513 break 2 5514 fi 5515 done 5516 done 5517 IFS=$as_save_IFS 5518 5519 ;; 5520 esac 5521 fi 5522 BASH=$ac_cv_path_BASH 5523 if test -n "$BASH"; then 5524 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BASH" >&5 5525 $as_echo "$BASH" >&6; } 5526 else 5527 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 5528 $as_echo "no" >&6; } 5529 fi 5530 5531 5532 if test "x$BASH" = x; then 5533 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 5534 fi 5535 else 5536 # Otherwise we believe it is a complete path. Use it as it is. 5537 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool BASH=$tool_specified" >&5 5538 $as_echo "$as_me: Will use user supplied tool BASH=$tool_specified" >&6;} 5539 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for BASH" >&5 5540 $as_echo_n "checking for BASH... " >&6; } 5541 if test ! -x "$tool_specified"; then 5542 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 5543 $as_echo "not found" >&6; } 5544 as_fn_error $? "User supplied tool BASH=$tool_specified does not exist or is not executable" "$LINENO" 5 5545 fi 5546 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 5547 $as_echo "$tool_specified" >&6; } 5548 fi 5549 fi 5550 fi 5551 5552 fi 5553 5554 5555 5556 if test "x$BASH" = x; then 5557 as_fn_error $? "Could not find required tool for BASH" "$LINENO" 5 5558 fi 5559 5560 5561 5562 5563 5564 # Publish this variable in the help. 5565 5566 5567 if [ -z "${CAT+x}" ]; then 5568 # The variable is not set by user, try to locate tool using the code snippet 5569 for ac_prog in cat 5570 do 5571 # Extract the first word of "$ac_prog", so it can be a program name with args. 5572 set dummy $ac_prog; ac_word=$2 5573 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 5574 $as_echo_n "checking for $ac_word... " >&6; } 5575 if ${ac_cv_path_CAT+:} false; then : 5576 $as_echo_n "(cached) " >&6 5577 else 5578 case $CAT in 5579 [\\/]* | ?:[\\/]*) 5580 ac_cv_path_CAT="$CAT" # Let the user override the test with a path. 5581 ;; 5582 *) 5583 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 5584 for as_dir in $PATH 5585 do 5586 IFS=$as_save_IFS 5587 test -z "$as_dir" && as_dir=. 5588 for ac_exec_ext in '' $ac_executable_extensions; do 5589 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 5590 ac_cv_path_CAT="$as_dir/$ac_word$ac_exec_ext" 5591 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 5592 break 2 5593 fi 5594 done 5595 done 5596 IFS=$as_save_IFS 5597 5598 ;; 5599 esac 5600 fi 5601 CAT=$ac_cv_path_CAT 5602 if test -n "$CAT"; then 5603 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CAT" >&5 5604 $as_echo "$CAT" >&6; } 5605 else 5606 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 5607 $as_echo "no" >&6; } 5608 fi 5609 5610 5611 test -n "$CAT" && break 5612 done 5613 5614 else 5615 # The variable is set, but is it from the command line or the environment? 5616 5617 # Try to remove the string !CAT! from our list. 5618 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!CAT!/} 5619 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 5620 # If it failed, the variable was not from the command line. Ignore it, 5621 # but warn the user (except for BASH, which is always set by the calling BASH). 5622 if test "xCAT" != xBASH; then 5623 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of CAT from the environment. Use command line variables instead." >&5 5624 $as_echo "$as_me: WARNING: Ignoring value of CAT from the environment. Use command line variables instead." >&2;} 5625 fi 5626 # Try to locate tool using the code snippet 5627 for ac_prog in cat 5628 do 5629 # Extract the first word of "$ac_prog", so it can be a program name with args. 5630 set dummy $ac_prog; ac_word=$2 5631 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 5632 $as_echo_n "checking for $ac_word... " >&6; } 5633 if ${ac_cv_path_CAT+:} false; then : 5634 $as_echo_n "(cached) " >&6 5635 else 5636 case $CAT in 5637 [\\/]* | ?:[\\/]*) 5638 ac_cv_path_CAT="$CAT" # Let the user override the test with a path. 5639 ;; 5640 *) 5641 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 5642 for as_dir in $PATH 5643 do 5644 IFS=$as_save_IFS 5645 test -z "$as_dir" && as_dir=. 5646 for ac_exec_ext in '' $ac_executable_extensions; do 5647 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 5648 ac_cv_path_CAT="$as_dir/$ac_word$ac_exec_ext" 5649 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 5650 break 2 5651 fi 5652 done 5653 done 5654 IFS=$as_save_IFS 5655 5656 ;; 5657 esac 5658 fi 5659 CAT=$ac_cv_path_CAT 5660 if test -n "$CAT"; then 5661 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CAT" >&5 5662 $as_echo "$CAT" >&6; } 5663 else 5664 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 5665 $as_echo "no" >&6; } 5666 fi 5667 5668 5669 test -n "$CAT" && break 5670 done 5671 5672 else 5673 # If it succeeded, then it was overridden by the user. We will use it 5674 # for the tool. 5675 5676 # First remove it from the list of overridden variables, so we can test 5677 # for unknown variables in the end. 5678 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 5679 5680 # Check if we try to supply an empty value 5681 if test "x$CAT" = x; then 5682 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool CAT= (no value)" >&5 5683 $as_echo "$as_me: Setting user supplied tool CAT= (no value)" >&6;} 5684 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for CAT" >&5 5685 $as_echo_n "checking for CAT... " >&6; } 5686 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 5687 $as_echo "disabled" >&6; } 5688 else 5689 # Check if the provided tool contains a complete path. 5690 tool_specified="$CAT" 5691 tool_basename="${tool_specified##*/}" 5692 if test "x$tool_basename" = "x$tool_specified"; then 5693 # A command without a complete path is provided, search $PATH. 5694 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool CAT=$tool_basename" >&5 5695 $as_echo "$as_me: Will search for user supplied tool CAT=$tool_basename" >&6;} 5696 # Extract the first word of "$tool_basename", so it can be a program name with args. 5697 set dummy $tool_basename; ac_word=$2 5698 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 5699 $as_echo_n "checking for $ac_word... " >&6; } 5700 if ${ac_cv_path_CAT+:} false; then : 5701 $as_echo_n "(cached) " >&6 5702 else 5703 case $CAT in 5704 [\\/]* | ?:[\\/]*) 5705 ac_cv_path_CAT="$CAT" # Let the user override the test with a path. 5706 ;; 5707 *) 5708 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 5709 for as_dir in $PATH 5710 do 5711 IFS=$as_save_IFS 5712 test -z "$as_dir" && as_dir=. 5713 for ac_exec_ext in '' $ac_executable_extensions; do 5714 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 5715 ac_cv_path_CAT="$as_dir/$ac_word$ac_exec_ext" 5716 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 5717 break 2 5718 fi 5719 done 5720 done 5721 IFS=$as_save_IFS 5722 5723 ;; 5724 esac 5725 fi 5726 CAT=$ac_cv_path_CAT 5727 if test -n "$CAT"; then 5728 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CAT" >&5 5729 $as_echo "$CAT" >&6; } 5730 else 5731 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 5732 $as_echo "no" >&6; } 5733 fi 5734 5735 5736 if test "x$CAT" = x; then 5737 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 5738 fi 5739 else 5740 # Otherwise we believe it is a complete path. Use it as it is. 5741 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool CAT=$tool_specified" >&5 5742 $as_echo "$as_me: Will use user supplied tool CAT=$tool_specified" >&6;} 5743 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for CAT" >&5 5744 $as_echo_n "checking for CAT... " >&6; } 5745 if test ! -x "$tool_specified"; then 5746 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 5747 $as_echo "not found" >&6; } 5748 as_fn_error $? "User supplied tool CAT=$tool_specified does not exist or is not executable" "$LINENO" 5 5749 fi 5750 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 5751 $as_echo "$tool_specified" >&6; } 5752 fi 5753 fi 5754 fi 5755 5756 fi 5757 5758 5759 5760 if test "x$CAT" = x; then 5761 as_fn_error $? "Could not find required tool for CAT" "$LINENO" 5 5762 fi 5763 5764 5765 5766 5767 5768 # Publish this variable in the help. 5769 5770 5771 if [ -z "${CHMOD+x}" ]; then 5772 # The variable is not set by user, try to locate tool using the code snippet 5773 for ac_prog in chmod 5774 do 5775 # Extract the first word of "$ac_prog", so it can be a program name with args. 5776 set dummy $ac_prog; ac_word=$2 5777 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 5778 $as_echo_n "checking for $ac_word... " >&6; } 5779 if ${ac_cv_path_CHMOD+:} false; then : 5780 $as_echo_n "(cached) " >&6 5781 else 5782 case $CHMOD in 5783 [\\/]* | ?:[\\/]*) 5784 ac_cv_path_CHMOD="$CHMOD" # Let the user override the test with a path. 5785 ;; 5786 *) 5787 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 5788 for as_dir in $PATH 5789 do 5790 IFS=$as_save_IFS 5791 test -z "$as_dir" && as_dir=. 5792 for ac_exec_ext in '' $ac_executable_extensions; do 5793 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 5794 ac_cv_path_CHMOD="$as_dir/$ac_word$ac_exec_ext" 5795 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 5796 break 2 5797 fi 5798 done 5799 done 5800 IFS=$as_save_IFS 5801 5802 ;; 5803 esac 5804 fi 5805 CHMOD=$ac_cv_path_CHMOD 5806 if test -n "$CHMOD"; then 5807 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CHMOD" >&5 5808 $as_echo "$CHMOD" >&6; } 5809 else 5810 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 5811 $as_echo "no" >&6; } 5812 fi 5813 5814 5815 test -n "$CHMOD" && break 5816 done 5817 5818 else 5819 # The variable is set, but is it from the command line or the environment? 5820 5821 # Try to remove the string !CHMOD! from our list. 5822 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!CHMOD!/} 5823 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 5824 # If it failed, the variable was not from the command line. Ignore it, 5825 # but warn the user (except for BASH, which is always set by the calling BASH). 5826 if test "xCHMOD" != xBASH; then 5827 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of CHMOD from the environment. Use command line variables instead." >&5 5828 $as_echo "$as_me: WARNING: Ignoring value of CHMOD from the environment. Use command line variables instead." >&2;} 5829 fi 5830 # Try to locate tool using the code snippet 5831 for ac_prog in chmod 5832 do 5833 # Extract the first word of "$ac_prog", so it can be a program name with args. 5834 set dummy $ac_prog; ac_word=$2 5835 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 5836 $as_echo_n "checking for $ac_word... " >&6; } 5837 if ${ac_cv_path_CHMOD+:} false; then : 5838 $as_echo_n "(cached) " >&6 5839 else 5840 case $CHMOD in 5841 [\\/]* | ?:[\\/]*) 5842 ac_cv_path_CHMOD="$CHMOD" # Let the user override the test with a path. 5843 ;; 5844 *) 5845 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 5846 for as_dir in $PATH 5847 do 5848 IFS=$as_save_IFS 5849 test -z "$as_dir" && as_dir=. 5850 for ac_exec_ext in '' $ac_executable_extensions; do 5851 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 5852 ac_cv_path_CHMOD="$as_dir/$ac_word$ac_exec_ext" 5853 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 5854 break 2 5855 fi 5856 done 5857 done 5858 IFS=$as_save_IFS 5859 5860 ;; 5861 esac 5862 fi 5863 CHMOD=$ac_cv_path_CHMOD 5864 if test -n "$CHMOD"; then 5865 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CHMOD" >&5 5866 $as_echo "$CHMOD" >&6; } 5867 else 5868 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 5869 $as_echo "no" >&6; } 5870 fi 5871 5872 5873 test -n "$CHMOD" && break 5874 done 5875 5876 else 5877 # If it succeeded, then it was overridden by the user. We will use it 5878 # for the tool. 5879 5880 # First remove it from the list of overridden variables, so we can test 5881 # for unknown variables in the end. 5882 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 5883 5884 # Check if we try to supply an empty value 5885 if test "x$CHMOD" = x; then 5886 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool CHMOD= (no value)" >&5 5887 $as_echo "$as_me: Setting user supplied tool CHMOD= (no value)" >&6;} 5888 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for CHMOD" >&5 5889 $as_echo_n "checking for CHMOD... " >&6; } 5890 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 5891 $as_echo "disabled" >&6; } 5892 else 5893 # Check if the provided tool contains a complete path. 5894 tool_specified="$CHMOD" 5895 tool_basename="${tool_specified##*/}" 5896 if test "x$tool_basename" = "x$tool_specified"; then 5897 # A command without a complete path is provided, search $PATH. 5898 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool CHMOD=$tool_basename" >&5 5899 $as_echo "$as_me: Will search for user supplied tool CHMOD=$tool_basename" >&6;} 5900 # Extract the first word of "$tool_basename", so it can be a program name with args. 5901 set dummy $tool_basename; ac_word=$2 5902 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 5903 $as_echo_n "checking for $ac_word... " >&6; } 5904 if ${ac_cv_path_CHMOD+:} false; then : 5905 $as_echo_n "(cached) " >&6 5906 else 5907 case $CHMOD in 5908 [\\/]* | ?:[\\/]*) 5909 ac_cv_path_CHMOD="$CHMOD" # Let the user override the test with a path. 5910 ;; 5911 *) 5912 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 5913 for as_dir in $PATH 5914 do 5915 IFS=$as_save_IFS 5916 test -z "$as_dir" && as_dir=. 5917 for ac_exec_ext in '' $ac_executable_extensions; do 5918 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 5919 ac_cv_path_CHMOD="$as_dir/$ac_word$ac_exec_ext" 5920 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 5921 break 2 5922 fi 5923 done 5924 done 5925 IFS=$as_save_IFS 5926 5927 ;; 5928 esac 5929 fi 5930 CHMOD=$ac_cv_path_CHMOD 5931 if test -n "$CHMOD"; then 5932 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CHMOD" >&5 5933 $as_echo "$CHMOD" >&6; } 5934 else 5935 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 5936 $as_echo "no" >&6; } 5937 fi 5938 5939 5940 if test "x$CHMOD" = x; then 5941 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 5942 fi 5943 else 5944 # Otherwise we believe it is a complete path. Use it as it is. 5945 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool CHMOD=$tool_specified" >&5 5946 $as_echo "$as_me: Will use user supplied tool CHMOD=$tool_specified" >&6;} 5947 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for CHMOD" >&5 5948 $as_echo_n "checking for CHMOD... " >&6; } 5949 if test ! -x "$tool_specified"; then 5950 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 5951 $as_echo "not found" >&6; } 5952 as_fn_error $? "User supplied tool CHMOD=$tool_specified does not exist or is not executable" "$LINENO" 5 5953 fi 5954 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 5955 $as_echo "$tool_specified" >&6; } 5956 fi 5957 fi 5958 fi 5959 5960 fi 5961 5962 5963 5964 if test "x$CHMOD" = x; then 5965 as_fn_error $? "Could not find required tool for CHMOD" "$LINENO" 5 5966 fi 5967 5968 5969 5970 5971 5972 # Publish this variable in the help. 5973 5974 5975 if [ -z "${CMP+x}" ]; then 5976 # The variable is not set by user, try to locate tool using the code snippet 5977 for ac_prog in cmp 5978 do 5979 # Extract the first word of "$ac_prog", so it can be a program name with args. 5980 set dummy $ac_prog; ac_word=$2 5981 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 5982 $as_echo_n "checking for $ac_word... " >&6; } 5983 if ${ac_cv_path_CMP+:} false; then : 5984 $as_echo_n "(cached) " >&6 5985 else 5986 case $CMP in 5987 [\\/]* | ?:[\\/]*) 5988 ac_cv_path_CMP="$CMP" # Let the user override the test with a path. 5989 ;; 5990 *) 5991 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 5992 for as_dir in $PATH 5993 do 5994 IFS=$as_save_IFS 5995 test -z "$as_dir" && as_dir=. 5996 for ac_exec_ext in '' $ac_executable_extensions; do 5997 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 5998 ac_cv_path_CMP="$as_dir/$ac_word$ac_exec_ext" 5999 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 6000 break 2 6001 fi 6002 done 6003 done 6004 IFS=$as_save_IFS 6005 6006 ;; 6007 esac 6008 fi 6009 CMP=$ac_cv_path_CMP 6010 if test -n "$CMP"; then 6011 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CMP" >&5 6012 $as_echo "$CMP" >&6; } 6013 else 6014 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 6015 $as_echo "no" >&6; } 6016 fi 6017 6018 6019 test -n "$CMP" && break 6020 done 6021 6022 else 6023 # The variable is set, but is it from the command line or the environment? 6024 6025 # Try to remove the string !CMP! from our list. 6026 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!CMP!/} 6027 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 6028 # If it failed, the variable was not from the command line. Ignore it, 6029 # but warn the user (except for BASH, which is always set by the calling BASH). 6030 if test "xCMP" != xBASH; then 6031 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of CMP from the environment. Use command line variables instead." >&5 6032 $as_echo "$as_me: WARNING: Ignoring value of CMP from the environment. Use command line variables instead." >&2;} 6033 fi 6034 # Try to locate tool using the code snippet 6035 for ac_prog in cmp 6036 do 6037 # Extract the first word of "$ac_prog", so it can be a program name with args. 6038 set dummy $ac_prog; ac_word=$2 6039 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 6040 $as_echo_n "checking for $ac_word... " >&6; } 6041 if ${ac_cv_path_CMP+:} false; then : 6042 $as_echo_n "(cached) " >&6 6043 else 6044 case $CMP in 6045 [\\/]* | ?:[\\/]*) 6046 ac_cv_path_CMP="$CMP" # Let the user override the test with a path. 6047 ;; 6048 *) 6049 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 6050 for as_dir in $PATH 6051 do 6052 IFS=$as_save_IFS 6053 test -z "$as_dir" && as_dir=. 6054 for ac_exec_ext in '' $ac_executable_extensions; do 6055 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 6056 ac_cv_path_CMP="$as_dir/$ac_word$ac_exec_ext" 6057 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 6058 break 2 6059 fi 6060 done 6061 done 6062 IFS=$as_save_IFS 6063 6064 ;; 6065 esac 6066 fi 6067 CMP=$ac_cv_path_CMP 6068 if test -n "$CMP"; then 6069 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CMP" >&5 6070 $as_echo "$CMP" >&6; } 6071 else 6072 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 6073 $as_echo "no" >&6; } 6074 fi 6075 6076 6077 test -n "$CMP" && break 6078 done 6079 6080 else 6081 # If it succeeded, then it was overridden by the user. We will use it 6082 # for the tool. 6083 6084 # First remove it from the list of overridden variables, so we can test 6085 # for unknown variables in the end. 6086 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 6087 6088 # Check if we try to supply an empty value 6089 if test "x$CMP" = x; then 6090 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool CMP= (no value)" >&5 6091 $as_echo "$as_me: Setting user supplied tool CMP= (no value)" >&6;} 6092 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for CMP" >&5 6093 $as_echo_n "checking for CMP... " >&6; } 6094 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 6095 $as_echo "disabled" >&6; } 6096 else 6097 # Check if the provided tool contains a complete path. 6098 tool_specified="$CMP" 6099 tool_basename="${tool_specified##*/}" 6100 if test "x$tool_basename" = "x$tool_specified"; then 6101 # A command without a complete path is provided, search $PATH. 6102 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool CMP=$tool_basename" >&5 6103 $as_echo "$as_me: Will search for user supplied tool CMP=$tool_basename" >&6;} 6104 # Extract the first word of "$tool_basename", so it can be a program name with args. 6105 set dummy $tool_basename; ac_word=$2 6106 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 6107 $as_echo_n "checking for $ac_word... " >&6; } 6108 if ${ac_cv_path_CMP+:} false; then : 6109 $as_echo_n "(cached) " >&6 6110 else 6111 case $CMP in 6112 [\\/]* | ?:[\\/]*) 6113 ac_cv_path_CMP="$CMP" # Let the user override the test with a path. 6114 ;; 6115 *) 6116 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 6117 for as_dir in $PATH 6118 do 6119 IFS=$as_save_IFS 6120 test -z "$as_dir" && as_dir=. 6121 for ac_exec_ext in '' $ac_executable_extensions; do 6122 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 6123 ac_cv_path_CMP="$as_dir/$ac_word$ac_exec_ext" 6124 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 6125 break 2 6126 fi 6127 done 6128 done 6129 IFS=$as_save_IFS 6130 6131 ;; 6132 esac 6133 fi 6134 CMP=$ac_cv_path_CMP 6135 if test -n "$CMP"; then 6136 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CMP" >&5 6137 $as_echo "$CMP" >&6; } 6138 else 6139 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 6140 $as_echo "no" >&6; } 6141 fi 6142 6143 6144 if test "x$CMP" = x; then 6145 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 6146 fi 6147 else 6148 # Otherwise we believe it is a complete path. Use it as it is. 6149 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool CMP=$tool_specified" >&5 6150 $as_echo "$as_me: Will use user supplied tool CMP=$tool_specified" >&6;} 6151 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for CMP" >&5 6152 $as_echo_n "checking for CMP... " >&6; } 6153 if test ! -x "$tool_specified"; then 6154 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 6155 $as_echo "not found" >&6; } 6156 as_fn_error $? "User supplied tool CMP=$tool_specified does not exist or is not executable" "$LINENO" 5 6157 fi 6158 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 6159 $as_echo "$tool_specified" >&6; } 6160 fi 6161 fi 6162 fi 6163 6164 fi 6165 6166 6167 6168 if test "x$CMP" = x; then 6169 as_fn_error $? "Could not find required tool for CMP" "$LINENO" 5 6170 fi 6171 6172 6173 6174 6175 6176 # Publish this variable in the help. 6177 6178 6179 if [ -z "${COMM+x}" ]; then 6180 # The variable is not set by user, try to locate tool using the code snippet 6181 for ac_prog in comm 6182 do 6183 # Extract the first word of "$ac_prog", so it can be a program name with args. 6184 set dummy $ac_prog; ac_word=$2 6185 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 6186 $as_echo_n "checking for $ac_word... " >&6; } 6187 if ${ac_cv_path_COMM+:} false; then : 6188 $as_echo_n "(cached) " >&6 6189 else 6190 case $COMM in 6191 [\\/]* | ?:[\\/]*) 6192 ac_cv_path_COMM="$COMM" # Let the user override the test with a path. 6193 ;; 6194 *) 6195 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 6196 for as_dir in $PATH 6197 do 6198 IFS=$as_save_IFS 6199 test -z "$as_dir" && as_dir=. 6200 for ac_exec_ext in '' $ac_executable_extensions; do 6201 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 6202 ac_cv_path_COMM="$as_dir/$ac_word$ac_exec_ext" 6203 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 6204 break 2 6205 fi 6206 done 6207 done 6208 IFS=$as_save_IFS 6209 6210 ;; 6211 esac 6212 fi 6213 COMM=$ac_cv_path_COMM 6214 if test -n "$COMM"; then 6215 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $COMM" >&5 6216 $as_echo "$COMM" >&6; } 6217 else 6218 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 6219 $as_echo "no" >&6; } 6220 fi 6221 6222 6223 test -n "$COMM" && break 6224 done 6225 6226 else 6227 # The variable is set, but is it from the command line or the environment? 6228 6229 # Try to remove the string !COMM! from our list. 6230 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!COMM!/} 6231 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 6232 # If it failed, the variable was not from the command line. Ignore it, 6233 # but warn the user (except for BASH, which is always set by the calling BASH). 6234 if test "xCOMM" != xBASH; then 6235 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of COMM from the environment. Use command line variables instead." >&5 6236 $as_echo "$as_me: WARNING: Ignoring value of COMM from the environment. Use command line variables instead." >&2;} 6237 fi 6238 # Try to locate tool using the code snippet 6239 for ac_prog in comm 6240 do 6241 # Extract the first word of "$ac_prog", so it can be a program name with args. 6242 set dummy $ac_prog; ac_word=$2 6243 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 6244 $as_echo_n "checking for $ac_word... " >&6; } 6245 if ${ac_cv_path_COMM+:} false; then : 6246 $as_echo_n "(cached) " >&6 6247 else 6248 case $COMM in 6249 [\\/]* | ?:[\\/]*) 6250 ac_cv_path_COMM="$COMM" # Let the user override the test with a path. 6251 ;; 6252 *) 6253 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 6254 for as_dir in $PATH 6255 do 6256 IFS=$as_save_IFS 6257 test -z "$as_dir" && as_dir=. 6258 for ac_exec_ext in '' $ac_executable_extensions; do 6259 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 6260 ac_cv_path_COMM="$as_dir/$ac_word$ac_exec_ext" 6261 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 6262 break 2 6263 fi 6264 done 6265 done 6266 IFS=$as_save_IFS 6267 6268 ;; 6269 esac 6270 fi 6271 COMM=$ac_cv_path_COMM 6272 if test -n "$COMM"; then 6273 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $COMM" >&5 6274 $as_echo "$COMM" >&6; } 6275 else 6276 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 6277 $as_echo "no" >&6; } 6278 fi 6279 6280 6281 test -n "$COMM" && break 6282 done 6283 6284 else 6285 # If it succeeded, then it was overridden by the user. We will use it 6286 # for the tool. 6287 6288 # First remove it from the list of overridden variables, so we can test 6289 # for unknown variables in the end. 6290 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 6291 6292 # Check if we try to supply an empty value 6293 if test "x$COMM" = x; then 6294 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool COMM= (no value)" >&5 6295 $as_echo "$as_me: Setting user supplied tool COMM= (no value)" >&6;} 6296 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for COMM" >&5 6297 $as_echo_n "checking for COMM... " >&6; } 6298 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 6299 $as_echo "disabled" >&6; } 6300 else 6301 # Check if the provided tool contains a complete path. 6302 tool_specified="$COMM" 6303 tool_basename="${tool_specified##*/}" 6304 if test "x$tool_basename" = "x$tool_specified"; then 6305 # A command without a complete path is provided, search $PATH. 6306 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool COMM=$tool_basename" >&5 6307 $as_echo "$as_me: Will search for user supplied tool COMM=$tool_basename" >&6;} 6308 # Extract the first word of "$tool_basename", so it can be a program name with args. 6309 set dummy $tool_basename; ac_word=$2 6310 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 6311 $as_echo_n "checking for $ac_word... " >&6; } 6312 if ${ac_cv_path_COMM+:} false; then : 6313 $as_echo_n "(cached) " >&6 6314 else 6315 case $COMM in 6316 [\\/]* | ?:[\\/]*) 6317 ac_cv_path_COMM="$COMM" # Let the user override the test with a path. 6318 ;; 6319 *) 6320 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 6321 for as_dir in $PATH 6322 do 6323 IFS=$as_save_IFS 6324 test -z "$as_dir" && as_dir=. 6325 for ac_exec_ext in '' $ac_executable_extensions; do 6326 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 6327 ac_cv_path_COMM="$as_dir/$ac_word$ac_exec_ext" 6328 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 6329 break 2 6330 fi 6331 done 6332 done 6333 IFS=$as_save_IFS 6334 6335 ;; 6336 esac 6337 fi 6338 COMM=$ac_cv_path_COMM 6339 if test -n "$COMM"; then 6340 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $COMM" >&5 6341 $as_echo "$COMM" >&6; } 6342 else 6343 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 6344 $as_echo "no" >&6; } 6345 fi 6346 6347 6348 if test "x$COMM" = x; then 6349 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 6350 fi 6351 else 6352 # Otherwise we believe it is a complete path. Use it as it is. 6353 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool COMM=$tool_specified" >&5 6354 $as_echo "$as_me: Will use user supplied tool COMM=$tool_specified" >&6;} 6355 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for COMM" >&5 6356 $as_echo_n "checking for COMM... " >&6; } 6357 if test ! -x "$tool_specified"; then 6358 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 6359 $as_echo "not found" >&6; } 6360 as_fn_error $? "User supplied tool COMM=$tool_specified does not exist or is not executable" "$LINENO" 5 6361 fi 6362 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 6363 $as_echo "$tool_specified" >&6; } 6364 fi 6365 fi 6366 fi 6367 6368 fi 6369 6370 6371 6372 if test "x$COMM" = x; then 6373 as_fn_error $? "Could not find required tool for COMM" "$LINENO" 5 6374 fi 6375 6376 6377 6378 6379 6380 # Publish this variable in the help. 6381 6382 6383 if [ -z "${CP+x}" ]; then 6384 # The variable is not set by user, try to locate tool using the code snippet 6385 for ac_prog in cp 6386 do 6387 # Extract the first word of "$ac_prog", so it can be a program name with args. 6388 set dummy $ac_prog; ac_word=$2 6389 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 6390 $as_echo_n "checking for $ac_word... " >&6; } 6391 if ${ac_cv_path_CP+:} false; then : 6392 $as_echo_n "(cached) " >&6 6393 else 6394 case $CP in 6395 [\\/]* | ?:[\\/]*) 6396 ac_cv_path_CP="$CP" # Let the user override the test with a path. 6397 ;; 6398 *) 6399 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 6400 for as_dir in $PATH 6401 do 6402 IFS=$as_save_IFS 6403 test -z "$as_dir" && as_dir=. 6404 for ac_exec_ext in '' $ac_executable_extensions; do 6405 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 6406 ac_cv_path_CP="$as_dir/$ac_word$ac_exec_ext" 6407 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 6408 break 2 6409 fi 6410 done 6411 done 6412 IFS=$as_save_IFS 6413 6414 ;; 6415 esac 6416 fi 6417 CP=$ac_cv_path_CP 6418 if test -n "$CP"; then 6419 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CP" >&5 6420 $as_echo "$CP" >&6; } 6421 else 6422 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 6423 $as_echo "no" >&6; } 6424 fi 6425 6426 6427 test -n "$CP" && break 6428 done 6429 6430 else 6431 # The variable is set, but is it from the command line or the environment? 6432 6433 # Try to remove the string !CP! from our list. 6434 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!CP!/} 6435 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 6436 # If it failed, the variable was not from the command line. Ignore it, 6437 # but warn the user (except for BASH, which is always set by the calling BASH). 6438 if test "xCP" != xBASH; then 6439 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of CP from the environment. Use command line variables instead." >&5 6440 $as_echo "$as_me: WARNING: Ignoring value of CP from the environment. Use command line variables instead." >&2;} 6441 fi 6442 # Try to locate tool using the code snippet 6443 for ac_prog in cp 6444 do 6445 # Extract the first word of "$ac_prog", so it can be a program name with args. 6446 set dummy $ac_prog; ac_word=$2 6447 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 6448 $as_echo_n "checking for $ac_word... " >&6; } 6449 if ${ac_cv_path_CP+:} false; then : 6450 $as_echo_n "(cached) " >&6 6451 else 6452 case $CP in 6453 [\\/]* | ?:[\\/]*) 6454 ac_cv_path_CP="$CP" # Let the user override the test with a path. 6455 ;; 6456 *) 6457 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 6458 for as_dir in $PATH 6459 do 6460 IFS=$as_save_IFS 6461 test -z "$as_dir" && as_dir=. 6462 for ac_exec_ext in '' $ac_executable_extensions; do 6463 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 6464 ac_cv_path_CP="$as_dir/$ac_word$ac_exec_ext" 6465 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 6466 break 2 6467 fi 6468 done 6469 done 6470 IFS=$as_save_IFS 6471 6472 ;; 6473 esac 6474 fi 6475 CP=$ac_cv_path_CP 6476 if test -n "$CP"; then 6477 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CP" >&5 6478 $as_echo "$CP" >&6; } 6479 else 6480 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 6481 $as_echo "no" >&6; } 6482 fi 6483 6484 6485 test -n "$CP" && break 6486 done 6487 6488 else 6489 # If it succeeded, then it was overridden by the user. We will use it 6490 # for the tool. 6491 6492 # First remove it from the list of overridden variables, so we can test 6493 # for unknown variables in the end. 6494 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 6495 6496 # Check if we try to supply an empty value 6497 if test "x$CP" = x; then 6498 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool CP= (no value)" >&5 6499 $as_echo "$as_me: Setting user supplied tool CP= (no value)" >&6;} 6500 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for CP" >&5 6501 $as_echo_n "checking for CP... " >&6; } 6502 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 6503 $as_echo "disabled" >&6; } 6504 else 6505 # Check if the provided tool contains a complete path. 6506 tool_specified="$CP" 6507 tool_basename="${tool_specified##*/}" 6508 if test "x$tool_basename" = "x$tool_specified"; then 6509 # A command without a complete path is provided, search $PATH. 6510 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool CP=$tool_basename" >&5 6511 $as_echo "$as_me: Will search for user supplied tool CP=$tool_basename" >&6;} 6512 # Extract the first word of "$tool_basename", so it can be a program name with args. 6513 set dummy $tool_basename; ac_word=$2 6514 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 6515 $as_echo_n "checking for $ac_word... " >&6; } 6516 if ${ac_cv_path_CP+:} false; then : 6517 $as_echo_n "(cached) " >&6 6518 else 6519 case $CP in 6520 [\\/]* | ?:[\\/]*) 6521 ac_cv_path_CP="$CP" # Let the user override the test with a path. 6522 ;; 6523 *) 6524 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 6525 for as_dir in $PATH 6526 do 6527 IFS=$as_save_IFS 6528 test -z "$as_dir" && as_dir=. 6529 for ac_exec_ext in '' $ac_executable_extensions; do 6530 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 6531 ac_cv_path_CP="$as_dir/$ac_word$ac_exec_ext" 6532 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 6533 break 2 6534 fi 6535 done 6536 done 6537 IFS=$as_save_IFS 6538 6539 ;; 6540 esac 6541 fi 6542 CP=$ac_cv_path_CP 6543 if test -n "$CP"; then 6544 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CP" >&5 6545 $as_echo "$CP" >&6; } 6546 else 6547 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 6548 $as_echo "no" >&6; } 6549 fi 6550 6551 6552 if test "x$CP" = x; then 6553 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 6554 fi 6555 else 6556 # Otherwise we believe it is a complete path. Use it as it is. 6557 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool CP=$tool_specified" >&5 6558 $as_echo "$as_me: Will use user supplied tool CP=$tool_specified" >&6;} 6559 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for CP" >&5 6560 $as_echo_n "checking for CP... " >&6; } 6561 if test ! -x "$tool_specified"; then 6562 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 6563 $as_echo "not found" >&6; } 6564 as_fn_error $? "User supplied tool CP=$tool_specified does not exist or is not executable" "$LINENO" 5 6565 fi 6566 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 6567 $as_echo "$tool_specified" >&6; } 6568 fi 6569 fi 6570 fi 6571 6572 fi 6573 6574 6575 6576 if test "x$CP" = x; then 6577 as_fn_error $? "Could not find required tool for CP" "$LINENO" 5 6578 fi 6579 6580 6581 6582 6583 6584 # Publish this variable in the help. 6585 6586 6587 if [ -z "${CUT+x}" ]; then 6588 # The variable is not set by user, try to locate tool using the code snippet 6589 for ac_prog in cut 6590 do 6591 # Extract the first word of "$ac_prog", so it can be a program name with args. 6592 set dummy $ac_prog; ac_word=$2 6593 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 6594 $as_echo_n "checking for $ac_word... " >&6; } 6595 if ${ac_cv_path_CUT+:} false; then : 6596 $as_echo_n "(cached) " >&6 6597 else 6598 case $CUT in 6599 [\\/]* | ?:[\\/]*) 6600 ac_cv_path_CUT="$CUT" # Let the user override the test with a path. 6601 ;; 6602 *) 6603 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 6604 for as_dir in $PATH 6605 do 6606 IFS=$as_save_IFS 6607 test -z "$as_dir" && as_dir=. 6608 for ac_exec_ext in '' $ac_executable_extensions; do 6609 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 6610 ac_cv_path_CUT="$as_dir/$ac_word$ac_exec_ext" 6611 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 6612 break 2 6613 fi 6614 done 6615 done 6616 IFS=$as_save_IFS 6617 6618 ;; 6619 esac 6620 fi 6621 CUT=$ac_cv_path_CUT 6622 if test -n "$CUT"; then 6623 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CUT" >&5 6624 $as_echo "$CUT" >&6; } 6625 else 6626 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 6627 $as_echo "no" >&6; } 6628 fi 6629 6630 6631 test -n "$CUT" && break 6632 done 6633 6634 else 6635 # The variable is set, but is it from the command line or the environment? 6636 6637 # Try to remove the string !CUT! from our list. 6638 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!CUT!/} 6639 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 6640 # If it failed, the variable was not from the command line. Ignore it, 6641 # but warn the user (except for BASH, which is always set by the calling BASH). 6642 if test "xCUT" != xBASH; then 6643 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of CUT from the environment. Use command line variables instead." >&5 6644 $as_echo "$as_me: WARNING: Ignoring value of CUT from the environment. Use command line variables instead." >&2;} 6645 fi 6646 # Try to locate tool using the code snippet 6647 for ac_prog in cut 6648 do 6649 # Extract the first word of "$ac_prog", so it can be a program name with args. 6650 set dummy $ac_prog; ac_word=$2 6651 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 6652 $as_echo_n "checking for $ac_word... " >&6; } 6653 if ${ac_cv_path_CUT+:} false; then : 6654 $as_echo_n "(cached) " >&6 6655 else 6656 case $CUT in 6657 [\\/]* | ?:[\\/]*) 6658 ac_cv_path_CUT="$CUT" # Let the user override the test with a path. 6659 ;; 6660 *) 6661 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 6662 for as_dir in $PATH 6663 do 6664 IFS=$as_save_IFS 6665 test -z "$as_dir" && as_dir=. 6666 for ac_exec_ext in '' $ac_executable_extensions; do 6667 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 6668 ac_cv_path_CUT="$as_dir/$ac_word$ac_exec_ext" 6669 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 6670 break 2 6671 fi 6672 done 6673 done 6674 IFS=$as_save_IFS 6675 6676 ;; 6677 esac 6678 fi 6679 CUT=$ac_cv_path_CUT 6680 if test -n "$CUT"; then 6681 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CUT" >&5 6682 $as_echo "$CUT" >&6; } 6683 else 6684 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 6685 $as_echo "no" >&6; } 6686 fi 6687 6688 6689 test -n "$CUT" && break 6690 done 6691 6692 else 6693 # If it succeeded, then it was overridden by the user. We will use it 6694 # for the tool. 6695 6696 # First remove it from the list of overridden variables, so we can test 6697 # for unknown variables in the end. 6698 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 6699 6700 # Check if we try to supply an empty value 6701 if test "x$CUT" = x; then 6702 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool CUT= (no value)" >&5 6703 $as_echo "$as_me: Setting user supplied tool CUT= (no value)" >&6;} 6704 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for CUT" >&5 6705 $as_echo_n "checking for CUT... " >&6; } 6706 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 6707 $as_echo "disabled" >&6; } 6708 else 6709 # Check if the provided tool contains a complete path. 6710 tool_specified="$CUT" 6711 tool_basename="${tool_specified##*/}" 6712 if test "x$tool_basename" = "x$tool_specified"; then 6713 # A command without a complete path is provided, search $PATH. 6714 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool CUT=$tool_basename" >&5 6715 $as_echo "$as_me: Will search for user supplied tool CUT=$tool_basename" >&6;} 6716 # Extract the first word of "$tool_basename", so it can be a program name with args. 6717 set dummy $tool_basename; ac_word=$2 6718 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 6719 $as_echo_n "checking for $ac_word... " >&6; } 6720 if ${ac_cv_path_CUT+:} false; then : 6721 $as_echo_n "(cached) " >&6 6722 else 6723 case $CUT in 6724 [\\/]* | ?:[\\/]*) 6725 ac_cv_path_CUT="$CUT" # Let the user override the test with a path. 6726 ;; 6727 *) 6728 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 6729 for as_dir in $PATH 6730 do 6731 IFS=$as_save_IFS 6732 test -z "$as_dir" && as_dir=. 6733 for ac_exec_ext in '' $ac_executable_extensions; do 6734 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 6735 ac_cv_path_CUT="$as_dir/$ac_word$ac_exec_ext" 6736 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 6737 break 2 6738 fi 6739 done 6740 done 6741 IFS=$as_save_IFS 6742 6743 ;; 6744 esac 6745 fi 6746 CUT=$ac_cv_path_CUT 6747 if test -n "$CUT"; then 6748 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CUT" >&5 6749 $as_echo "$CUT" >&6; } 6750 else 6751 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 6752 $as_echo "no" >&6; } 6753 fi 6754 6755 6756 if test "x$CUT" = x; then 6757 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 6758 fi 6759 else 6760 # Otherwise we believe it is a complete path. Use it as it is. 6761 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool CUT=$tool_specified" >&5 6762 $as_echo "$as_me: Will use user supplied tool CUT=$tool_specified" >&6;} 6763 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for CUT" >&5 6764 $as_echo_n "checking for CUT... " >&6; } 6765 if test ! -x "$tool_specified"; then 6766 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 6767 $as_echo "not found" >&6; } 6768 as_fn_error $? "User supplied tool CUT=$tool_specified does not exist or is not executable" "$LINENO" 5 6769 fi 6770 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 6771 $as_echo "$tool_specified" >&6; } 6772 fi 6773 fi 6774 fi 6775 6776 fi 6777 6778 6779 6780 if test "x$CUT" = x; then 6781 as_fn_error $? "Could not find required tool for CUT" "$LINENO" 5 6782 fi 6783 6784 6785 6786 6787 6788 # Publish this variable in the help. 6789 6790 6791 if [ -z "${DATE+x}" ]; then 6792 # The variable is not set by user, try to locate tool using the code snippet 6793 for ac_prog in date 6794 do 6795 # Extract the first word of "$ac_prog", so it can be a program name with args. 6796 set dummy $ac_prog; ac_word=$2 6797 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 6798 $as_echo_n "checking for $ac_word... " >&6; } 6799 if ${ac_cv_path_DATE+:} false; then : 6800 $as_echo_n "(cached) " >&6 6801 else 6802 case $DATE in 6803 [\\/]* | ?:[\\/]*) 6804 ac_cv_path_DATE="$DATE" # Let the user override the test with a path. 6805 ;; 6806 *) 6807 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 6808 for as_dir in $PATH 6809 do 6810 IFS=$as_save_IFS 6811 test -z "$as_dir" && as_dir=. 6812 for ac_exec_ext in '' $ac_executable_extensions; do 6813 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 6814 ac_cv_path_DATE="$as_dir/$ac_word$ac_exec_ext" 6815 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 6816 break 2 6817 fi 6818 done 6819 done 6820 IFS=$as_save_IFS 6821 6822 ;; 6823 esac 6824 fi 6825 DATE=$ac_cv_path_DATE 6826 if test -n "$DATE"; then 6827 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $DATE" >&5 6828 $as_echo "$DATE" >&6; } 6829 else 6830 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 6831 $as_echo "no" >&6; } 6832 fi 6833 6834 6835 test -n "$DATE" && break 6836 done 6837 6838 else 6839 # The variable is set, but is it from the command line or the environment? 6840 6841 # Try to remove the string !DATE! from our list. 6842 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!DATE!/} 6843 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 6844 # If it failed, the variable was not from the command line. Ignore it, 6845 # but warn the user (except for BASH, which is always set by the calling BASH). 6846 if test "xDATE" != xBASH; then 6847 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of DATE from the environment. Use command line variables instead." >&5 6848 $as_echo "$as_me: WARNING: Ignoring value of DATE from the environment. Use command line variables instead." >&2;} 6849 fi 6850 # Try to locate tool using the code snippet 6851 for ac_prog in date 6852 do 6853 # Extract the first word of "$ac_prog", so it can be a program name with args. 6854 set dummy $ac_prog; ac_word=$2 6855 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 6856 $as_echo_n "checking for $ac_word... " >&6; } 6857 if ${ac_cv_path_DATE+:} false; then : 6858 $as_echo_n "(cached) " >&6 6859 else 6860 case $DATE in 6861 [\\/]* | ?:[\\/]*) 6862 ac_cv_path_DATE="$DATE" # Let the user override the test with a path. 6863 ;; 6864 *) 6865 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 6866 for as_dir in $PATH 6867 do 6868 IFS=$as_save_IFS 6869 test -z "$as_dir" && as_dir=. 6870 for ac_exec_ext in '' $ac_executable_extensions; do 6871 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 6872 ac_cv_path_DATE="$as_dir/$ac_word$ac_exec_ext" 6873 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 6874 break 2 6875 fi 6876 done 6877 done 6878 IFS=$as_save_IFS 6879 6880 ;; 6881 esac 6882 fi 6883 DATE=$ac_cv_path_DATE 6884 if test -n "$DATE"; then 6885 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $DATE" >&5 6886 $as_echo "$DATE" >&6; } 6887 else 6888 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 6889 $as_echo "no" >&6; } 6890 fi 6891 6892 6893 test -n "$DATE" && break 6894 done 6895 6896 else 6897 # If it succeeded, then it was overridden by the user. We will use it 6898 # for the tool. 6899 6900 # First remove it from the list of overridden variables, so we can test 6901 # for unknown variables in the end. 6902 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 6903 6904 # Check if we try to supply an empty value 6905 if test "x$DATE" = x; then 6906 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool DATE= (no value)" >&5 6907 $as_echo "$as_me: Setting user supplied tool DATE= (no value)" >&6;} 6908 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for DATE" >&5 6909 $as_echo_n "checking for DATE... " >&6; } 6910 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 6911 $as_echo "disabled" >&6; } 6912 else 6913 # Check if the provided tool contains a complete path. 6914 tool_specified="$DATE" 6915 tool_basename="${tool_specified##*/}" 6916 if test "x$tool_basename" = "x$tool_specified"; then 6917 # A command without a complete path is provided, search $PATH. 6918 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool DATE=$tool_basename" >&5 6919 $as_echo "$as_me: Will search for user supplied tool DATE=$tool_basename" >&6;} 6920 # Extract the first word of "$tool_basename", so it can be a program name with args. 6921 set dummy $tool_basename; ac_word=$2 6922 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 6923 $as_echo_n "checking for $ac_word... " >&6; } 6924 if ${ac_cv_path_DATE+:} false; then : 6925 $as_echo_n "(cached) " >&6 6926 else 6927 case $DATE in 6928 [\\/]* | ?:[\\/]*) 6929 ac_cv_path_DATE="$DATE" # Let the user override the test with a path. 6930 ;; 6931 *) 6932 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 6933 for as_dir in $PATH 6934 do 6935 IFS=$as_save_IFS 6936 test -z "$as_dir" && as_dir=. 6937 for ac_exec_ext in '' $ac_executable_extensions; do 6938 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 6939 ac_cv_path_DATE="$as_dir/$ac_word$ac_exec_ext" 6940 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 6941 break 2 6942 fi 6943 done 6944 done 6945 IFS=$as_save_IFS 6946 6947 ;; 6948 esac 6949 fi 6950 DATE=$ac_cv_path_DATE 6951 if test -n "$DATE"; then 6952 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $DATE" >&5 6953 $as_echo "$DATE" >&6; } 6954 else 6955 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 6956 $as_echo "no" >&6; } 6957 fi 6958 6959 6960 if test "x$DATE" = x; then 6961 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 6962 fi 6963 else 6964 # Otherwise we believe it is a complete path. Use it as it is. 6965 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool DATE=$tool_specified" >&5 6966 $as_echo "$as_me: Will use user supplied tool DATE=$tool_specified" >&6;} 6967 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for DATE" >&5 6968 $as_echo_n "checking for DATE... " >&6; } 6969 if test ! -x "$tool_specified"; then 6970 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 6971 $as_echo "not found" >&6; } 6972 as_fn_error $? "User supplied tool DATE=$tool_specified does not exist or is not executable" "$LINENO" 5 6973 fi 6974 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 6975 $as_echo "$tool_specified" >&6; } 6976 fi 6977 fi 6978 fi 6979 6980 fi 6981 6982 6983 6984 if test "x$DATE" = x; then 6985 as_fn_error $? "Could not find required tool for DATE" "$LINENO" 5 6986 fi 6987 6988 6989 6990 6991 6992 # Publish this variable in the help. 6993 6994 6995 if [ -z "${DIFF+x}" ]; then 6996 # The variable is not set by user, try to locate tool using the code snippet 6997 for ac_prog in gdiff diff 6998 do 6999 # Extract the first word of "$ac_prog", so it can be a program name with args. 7000 set dummy $ac_prog; ac_word=$2 7001 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 7002 $as_echo_n "checking for $ac_word... " >&6; } 7003 if ${ac_cv_path_DIFF+:} false; then : 7004 $as_echo_n "(cached) " >&6 7005 else 7006 case $DIFF in 7007 [\\/]* | ?:[\\/]*) 7008 ac_cv_path_DIFF="$DIFF" # Let the user override the test with a path. 7009 ;; 7010 *) 7011 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 7012 for as_dir in $PATH 7013 do 7014 IFS=$as_save_IFS 7015 test -z "$as_dir" && as_dir=. 7016 for ac_exec_ext in '' $ac_executable_extensions; do 7017 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 7018 ac_cv_path_DIFF="$as_dir/$ac_word$ac_exec_ext" 7019 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 7020 break 2 7021 fi 7022 done 7023 done 7024 IFS=$as_save_IFS 7025 7026 ;; 7027 esac 7028 fi 7029 DIFF=$ac_cv_path_DIFF 7030 if test -n "$DIFF"; then 7031 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $DIFF" >&5 7032 $as_echo "$DIFF" >&6; } 7033 else 7034 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 7035 $as_echo "no" >&6; } 7036 fi 7037 7038 7039 test -n "$DIFF" && break 7040 done 7041 7042 else 7043 # The variable is set, but is it from the command line or the environment? 7044 7045 # Try to remove the string !DIFF! from our list. 7046 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!DIFF!/} 7047 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 7048 # If it failed, the variable was not from the command line. Ignore it, 7049 # but warn the user (except for BASH, which is always set by the calling BASH). 7050 if test "xDIFF" != xBASH; then 7051 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of DIFF from the environment. Use command line variables instead." >&5 7052 $as_echo "$as_me: WARNING: Ignoring value of DIFF from the environment. Use command line variables instead." >&2;} 7053 fi 7054 # Try to locate tool using the code snippet 7055 for ac_prog in gdiff diff 7056 do 7057 # Extract the first word of "$ac_prog", so it can be a program name with args. 7058 set dummy $ac_prog; ac_word=$2 7059 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 7060 $as_echo_n "checking for $ac_word... " >&6; } 7061 if ${ac_cv_path_DIFF+:} false; then : 7062 $as_echo_n "(cached) " >&6 7063 else 7064 case $DIFF in 7065 [\\/]* | ?:[\\/]*) 7066 ac_cv_path_DIFF="$DIFF" # Let the user override the test with a path. 7067 ;; 7068 *) 7069 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 7070 for as_dir in $PATH 7071 do 7072 IFS=$as_save_IFS 7073 test -z "$as_dir" && as_dir=. 7074 for ac_exec_ext in '' $ac_executable_extensions; do 7075 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 7076 ac_cv_path_DIFF="$as_dir/$ac_word$ac_exec_ext" 7077 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 7078 break 2 7079 fi 7080 done 7081 done 7082 IFS=$as_save_IFS 7083 7084 ;; 7085 esac 7086 fi 7087 DIFF=$ac_cv_path_DIFF 7088 if test -n "$DIFF"; then 7089 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $DIFF" >&5 7090 $as_echo "$DIFF" >&6; } 7091 else 7092 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 7093 $as_echo "no" >&6; } 7094 fi 7095 7096 7097 test -n "$DIFF" && break 7098 done 7099 7100 else 7101 # If it succeeded, then it was overridden by the user. We will use it 7102 # for the tool. 7103 7104 # First remove it from the list of overridden variables, so we can test 7105 # for unknown variables in the end. 7106 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 7107 7108 # Check if we try to supply an empty value 7109 if test "x$DIFF" = x; then 7110 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool DIFF= (no value)" >&5 7111 $as_echo "$as_me: Setting user supplied tool DIFF= (no value)" >&6;} 7112 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for DIFF" >&5 7113 $as_echo_n "checking for DIFF... " >&6; } 7114 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 7115 $as_echo "disabled" >&6; } 7116 else 7117 # Check if the provided tool contains a complete path. 7118 tool_specified="$DIFF" 7119 tool_basename="${tool_specified##*/}" 7120 if test "x$tool_basename" = "x$tool_specified"; then 7121 # A command without a complete path is provided, search $PATH. 7122 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool DIFF=$tool_basename" >&5 7123 $as_echo "$as_me: Will search for user supplied tool DIFF=$tool_basename" >&6;} 7124 # Extract the first word of "$tool_basename", so it can be a program name with args. 7125 set dummy $tool_basename; ac_word=$2 7126 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 7127 $as_echo_n "checking for $ac_word... " >&6; } 7128 if ${ac_cv_path_DIFF+:} false; then : 7129 $as_echo_n "(cached) " >&6 7130 else 7131 case $DIFF in 7132 [\\/]* | ?:[\\/]*) 7133 ac_cv_path_DIFF="$DIFF" # Let the user override the test with a path. 7134 ;; 7135 *) 7136 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 7137 for as_dir in $PATH 7138 do 7139 IFS=$as_save_IFS 7140 test -z "$as_dir" && as_dir=. 7141 for ac_exec_ext in '' $ac_executable_extensions; do 7142 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 7143 ac_cv_path_DIFF="$as_dir/$ac_word$ac_exec_ext" 7144 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 7145 break 2 7146 fi 7147 done 7148 done 7149 IFS=$as_save_IFS 7150 7151 ;; 7152 esac 7153 fi 7154 DIFF=$ac_cv_path_DIFF 7155 if test -n "$DIFF"; then 7156 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $DIFF" >&5 7157 $as_echo "$DIFF" >&6; } 7158 else 7159 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 7160 $as_echo "no" >&6; } 7161 fi 7162 7163 7164 if test "x$DIFF" = x; then 7165 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 7166 fi 7167 else 7168 # Otherwise we believe it is a complete path. Use it as it is. 7169 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool DIFF=$tool_specified" >&5 7170 $as_echo "$as_me: Will use user supplied tool DIFF=$tool_specified" >&6;} 7171 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for DIFF" >&5 7172 $as_echo_n "checking for DIFF... " >&6; } 7173 if test ! -x "$tool_specified"; then 7174 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 7175 $as_echo "not found" >&6; } 7176 as_fn_error $? "User supplied tool DIFF=$tool_specified does not exist or is not executable" "$LINENO" 5 7177 fi 7178 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 7179 $as_echo "$tool_specified" >&6; } 7180 fi 7181 fi 7182 fi 7183 7184 fi 7185 7186 7187 7188 if test "x$DIFF" = x; then 7189 as_fn_error $? "Could not find required tool for DIFF" "$LINENO" 5 7190 fi 7191 7192 7193 7194 7195 7196 # Publish this variable in the help. 7197 7198 7199 if [ -z "${DIRNAME+x}" ]; then 7200 # The variable is not set by user, try to locate tool using the code snippet 7201 for ac_prog in dirname 7202 do 7203 # Extract the first word of "$ac_prog", so it can be a program name with args. 7204 set dummy $ac_prog; ac_word=$2 7205 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 7206 $as_echo_n "checking for $ac_word... " >&6; } 7207 if ${ac_cv_path_DIRNAME+:} false; then : 7208 $as_echo_n "(cached) " >&6 7209 else 7210 case $DIRNAME in 7211 [\\/]* | ?:[\\/]*) 7212 ac_cv_path_DIRNAME="$DIRNAME" # Let the user override the test with a path. 7213 ;; 7214 *) 7215 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 7216 for as_dir in $PATH 7217 do 7218 IFS=$as_save_IFS 7219 test -z "$as_dir" && as_dir=. 7220 for ac_exec_ext in '' $ac_executable_extensions; do 7221 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 7222 ac_cv_path_DIRNAME="$as_dir/$ac_word$ac_exec_ext" 7223 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 7224 break 2 7225 fi 7226 done 7227 done 7228 IFS=$as_save_IFS 7229 7230 ;; 7231 esac 7232 fi 7233 DIRNAME=$ac_cv_path_DIRNAME 7234 if test -n "$DIRNAME"; then 7235 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $DIRNAME" >&5 7236 $as_echo "$DIRNAME" >&6; } 7237 else 7238 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 7239 $as_echo "no" >&6; } 7240 fi 7241 7242 7243 test -n "$DIRNAME" && break 7244 done 7245 7246 else 7247 # The variable is set, but is it from the command line or the environment? 7248 7249 # Try to remove the string !DIRNAME! from our list. 7250 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!DIRNAME!/} 7251 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 7252 # If it failed, the variable was not from the command line. Ignore it, 7253 # but warn the user (except for BASH, which is always set by the calling BASH). 7254 if test "xDIRNAME" != xBASH; then 7255 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of DIRNAME from the environment. Use command line variables instead." >&5 7256 $as_echo "$as_me: WARNING: Ignoring value of DIRNAME from the environment. Use command line variables instead." >&2;} 7257 fi 7258 # Try to locate tool using the code snippet 7259 for ac_prog in dirname 7260 do 7261 # Extract the first word of "$ac_prog", so it can be a program name with args. 7262 set dummy $ac_prog; ac_word=$2 7263 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 7264 $as_echo_n "checking for $ac_word... " >&6; } 7265 if ${ac_cv_path_DIRNAME+:} false; then : 7266 $as_echo_n "(cached) " >&6 7267 else 7268 case $DIRNAME in 7269 [\\/]* | ?:[\\/]*) 7270 ac_cv_path_DIRNAME="$DIRNAME" # Let the user override the test with a path. 7271 ;; 7272 *) 7273 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 7274 for as_dir in $PATH 7275 do 7276 IFS=$as_save_IFS 7277 test -z "$as_dir" && as_dir=. 7278 for ac_exec_ext in '' $ac_executable_extensions; do 7279 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 7280 ac_cv_path_DIRNAME="$as_dir/$ac_word$ac_exec_ext" 7281 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 7282 break 2 7283 fi 7284 done 7285 done 7286 IFS=$as_save_IFS 7287 7288 ;; 7289 esac 7290 fi 7291 DIRNAME=$ac_cv_path_DIRNAME 7292 if test -n "$DIRNAME"; then 7293 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $DIRNAME" >&5 7294 $as_echo "$DIRNAME" >&6; } 7295 else 7296 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 7297 $as_echo "no" >&6; } 7298 fi 7299 7300 7301 test -n "$DIRNAME" && break 7302 done 7303 7304 else 7305 # If it succeeded, then it was overridden by the user. We will use it 7306 # for the tool. 7307 7308 # First remove it from the list of overridden variables, so we can test 7309 # for unknown variables in the end. 7310 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 7311 7312 # Check if we try to supply an empty value 7313 if test "x$DIRNAME" = x; then 7314 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool DIRNAME= (no value)" >&5 7315 $as_echo "$as_me: Setting user supplied tool DIRNAME= (no value)" >&6;} 7316 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for DIRNAME" >&5 7317 $as_echo_n "checking for DIRNAME... " >&6; } 7318 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 7319 $as_echo "disabled" >&6; } 7320 else 7321 # Check if the provided tool contains a complete path. 7322 tool_specified="$DIRNAME" 7323 tool_basename="${tool_specified##*/}" 7324 if test "x$tool_basename" = "x$tool_specified"; then 7325 # A command without a complete path is provided, search $PATH. 7326 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool DIRNAME=$tool_basename" >&5 7327 $as_echo "$as_me: Will search for user supplied tool DIRNAME=$tool_basename" >&6;} 7328 # Extract the first word of "$tool_basename", so it can be a program name with args. 7329 set dummy $tool_basename; ac_word=$2 7330 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 7331 $as_echo_n "checking for $ac_word... " >&6; } 7332 if ${ac_cv_path_DIRNAME+:} false; then : 7333 $as_echo_n "(cached) " >&6 7334 else 7335 case $DIRNAME in 7336 [\\/]* | ?:[\\/]*) 7337 ac_cv_path_DIRNAME="$DIRNAME" # Let the user override the test with a path. 7338 ;; 7339 *) 7340 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 7341 for as_dir in $PATH 7342 do 7343 IFS=$as_save_IFS 7344 test -z "$as_dir" && as_dir=. 7345 for ac_exec_ext in '' $ac_executable_extensions; do 7346 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 7347 ac_cv_path_DIRNAME="$as_dir/$ac_word$ac_exec_ext" 7348 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 7349 break 2 7350 fi 7351 done 7352 done 7353 IFS=$as_save_IFS 7354 7355 ;; 7356 esac 7357 fi 7358 DIRNAME=$ac_cv_path_DIRNAME 7359 if test -n "$DIRNAME"; then 7360 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $DIRNAME" >&5 7361 $as_echo "$DIRNAME" >&6; } 7362 else 7363 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 7364 $as_echo "no" >&6; } 7365 fi 7366 7367 7368 if test "x$DIRNAME" = x; then 7369 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 7370 fi 7371 else 7372 # Otherwise we believe it is a complete path. Use it as it is. 7373 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool DIRNAME=$tool_specified" >&5 7374 $as_echo "$as_me: Will use user supplied tool DIRNAME=$tool_specified" >&6;} 7375 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for DIRNAME" >&5 7376 $as_echo_n "checking for DIRNAME... " >&6; } 7377 if test ! -x "$tool_specified"; then 7378 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 7379 $as_echo "not found" >&6; } 7380 as_fn_error $? "User supplied tool DIRNAME=$tool_specified does not exist or is not executable" "$LINENO" 5 7381 fi 7382 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 7383 $as_echo "$tool_specified" >&6; } 7384 fi 7385 fi 7386 fi 7387 7388 fi 7389 7390 7391 7392 if test "x$DIRNAME" = x; then 7393 as_fn_error $? "Could not find required tool for DIRNAME" "$LINENO" 5 7394 fi 7395 7396 7397 7398 7399 7400 # Publish this variable in the help. 7401 7402 7403 if [ -z "${ECHO+x}" ]; then 7404 # The variable is not set by user, try to locate tool using the code snippet 7405 for ac_prog in echo 7406 do 7407 # Extract the first word of "$ac_prog", so it can be a program name with args. 7408 set dummy $ac_prog; ac_word=$2 7409 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 7410 $as_echo_n "checking for $ac_word... " >&6; } 7411 if ${ac_cv_path_ECHO+:} false; then : 7412 $as_echo_n "(cached) " >&6 7413 else 7414 case $ECHO in 7415 [\\/]* | ?:[\\/]*) 7416 ac_cv_path_ECHO="$ECHO" # Let the user override the test with a path. 7417 ;; 7418 *) 7419 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 7420 for as_dir in $PATH 7421 do 7422 IFS=$as_save_IFS 7423 test -z "$as_dir" && as_dir=. 7424 for ac_exec_ext in '' $ac_executable_extensions; do 7425 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 7426 ac_cv_path_ECHO="$as_dir/$ac_word$ac_exec_ext" 7427 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 7428 break 2 7429 fi 7430 done 7431 done 7432 IFS=$as_save_IFS 7433 7434 ;; 7435 esac 7436 fi 7437 ECHO=$ac_cv_path_ECHO 7438 if test -n "$ECHO"; then 7439 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ECHO" >&5 7440 $as_echo "$ECHO" >&6; } 7441 else 7442 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 7443 $as_echo "no" >&6; } 7444 fi 7445 7446 7447 test -n "$ECHO" && break 7448 done 7449 7450 else 7451 # The variable is set, but is it from the command line or the environment? 7452 7453 # Try to remove the string !ECHO! from our list. 7454 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!ECHO!/} 7455 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 7456 # If it failed, the variable was not from the command line. Ignore it, 7457 # but warn the user (except for BASH, which is always set by the calling BASH). 7458 if test "xECHO" != xBASH; then 7459 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of ECHO from the environment. Use command line variables instead." >&5 7460 $as_echo "$as_me: WARNING: Ignoring value of ECHO from the environment. Use command line variables instead." >&2;} 7461 fi 7462 # Try to locate tool using the code snippet 7463 for ac_prog in echo 7464 do 7465 # Extract the first word of "$ac_prog", so it can be a program name with args. 7466 set dummy $ac_prog; ac_word=$2 7467 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 7468 $as_echo_n "checking for $ac_word... " >&6; } 7469 if ${ac_cv_path_ECHO+:} false; then : 7470 $as_echo_n "(cached) " >&6 7471 else 7472 case $ECHO in 7473 [\\/]* | ?:[\\/]*) 7474 ac_cv_path_ECHO="$ECHO" # Let the user override the test with a path. 7475 ;; 7476 *) 7477 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 7478 for as_dir in $PATH 7479 do 7480 IFS=$as_save_IFS 7481 test -z "$as_dir" && as_dir=. 7482 for ac_exec_ext in '' $ac_executable_extensions; do 7483 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 7484 ac_cv_path_ECHO="$as_dir/$ac_word$ac_exec_ext" 7485 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 7486 break 2 7487 fi 7488 done 7489 done 7490 IFS=$as_save_IFS 7491 7492 ;; 7493 esac 7494 fi 7495 ECHO=$ac_cv_path_ECHO 7496 if test -n "$ECHO"; then 7497 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ECHO" >&5 7498 $as_echo "$ECHO" >&6; } 7499 else 7500 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 7501 $as_echo "no" >&6; } 7502 fi 7503 7504 7505 test -n "$ECHO" && break 7506 done 7507 7508 else 7509 # If it succeeded, then it was overridden by the user. We will use it 7510 # for the tool. 7511 7512 # First remove it from the list of overridden variables, so we can test 7513 # for unknown variables in the end. 7514 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 7515 7516 # Check if we try to supply an empty value 7517 if test "x$ECHO" = x; then 7518 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool ECHO= (no value)" >&5 7519 $as_echo "$as_me: Setting user supplied tool ECHO= (no value)" >&6;} 7520 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ECHO" >&5 7521 $as_echo_n "checking for ECHO... " >&6; } 7522 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 7523 $as_echo "disabled" >&6; } 7524 else 7525 # Check if the provided tool contains a complete path. 7526 tool_specified="$ECHO" 7527 tool_basename="${tool_specified##*/}" 7528 if test "x$tool_basename" = "x$tool_specified"; then 7529 # A command without a complete path is provided, search $PATH. 7530 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool ECHO=$tool_basename" >&5 7531 $as_echo "$as_me: Will search for user supplied tool ECHO=$tool_basename" >&6;} 7532 # Extract the first word of "$tool_basename", so it can be a program name with args. 7533 set dummy $tool_basename; ac_word=$2 7534 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 7535 $as_echo_n "checking for $ac_word... " >&6; } 7536 if ${ac_cv_path_ECHO+:} false; then : 7537 $as_echo_n "(cached) " >&6 7538 else 7539 case $ECHO in 7540 [\\/]* | ?:[\\/]*) 7541 ac_cv_path_ECHO="$ECHO" # Let the user override the test with a path. 7542 ;; 7543 *) 7544 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 7545 for as_dir in $PATH 7546 do 7547 IFS=$as_save_IFS 7548 test -z "$as_dir" && as_dir=. 7549 for ac_exec_ext in '' $ac_executable_extensions; do 7550 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 7551 ac_cv_path_ECHO="$as_dir/$ac_word$ac_exec_ext" 7552 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 7553 break 2 7554 fi 7555 done 7556 done 7557 IFS=$as_save_IFS 7558 7559 ;; 7560 esac 7561 fi 7562 ECHO=$ac_cv_path_ECHO 7563 if test -n "$ECHO"; then 7564 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ECHO" >&5 7565 $as_echo "$ECHO" >&6; } 7566 else 7567 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 7568 $as_echo "no" >&6; } 7569 fi 7570 7571 7572 if test "x$ECHO" = x; then 7573 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 7574 fi 7575 else 7576 # Otherwise we believe it is a complete path. Use it as it is. 7577 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool ECHO=$tool_specified" >&5 7578 $as_echo "$as_me: Will use user supplied tool ECHO=$tool_specified" >&6;} 7579 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ECHO" >&5 7580 $as_echo_n "checking for ECHO... " >&6; } 7581 if test ! -x "$tool_specified"; then 7582 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 7583 $as_echo "not found" >&6; } 7584 as_fn_error $? "User supplied tool ECHO=$tool_specified does not exist or is not executable" "$LINENO" 5 7585 fi 7586 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 7587 $as_echo "$tool_specified" >&6; } 7588 fi 7589 fi 7590 fi 7591 7592 fi 7593 7594 7595 7596 if test "x$ECHO" = x; then 7597 as_fn_error $? "Could not find required tool for ECHO" "$LINENO" 5 7598 fi 7599 7600 7601 7602 7603 7604 # Publish this variable in the help. 7605 7606 7607 if [ -z "${EXPR+x}" ]; then 7608 # The variable is not set by user, try to locate tool using the code snippet 7609 for ac_prog in expr 7610 do 7611 # Extract the first word of "$ac_prog", so it can be a program name with args. 7612 set dummy $ac_prog; ac_word=$2 7613 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 7614 $as_echo_n "checking for $ac_word... " >&6; } 7615 if ${ac_cv_path_EXPR+:} false; then : 7616 $as_echo_n "(cached) " >&6 7617 else 7618 case $EXPR in 7619 [\\/]* | ?:[\\/]*) 7620 ac_cv_path_EXPR="$EXPR" # Let the user override the test with a path. 7621 ;; 7622 *) 7623 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 7624 for as_dir in $PATH 7625 do 7626 IFS=$as_save_IFS 7627 test -z "$as_dir" && as_dir=. 7628 for ac_exec_ext in '' $ac_executable_extensions; do 7629 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 7630 ac_cv_path_EXPR="$as_dir/$ac_word$ac_exec_ext" 7631 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 7632 break 2 7633 fi 7634 done 7635 done 7636 IFS=$as_save_IFS 7637 7638 ;; 7639 esac 7640 fi 7641 EXPR=$ac_cv_path_EXPR 7642 if test -n "$EXPR"; then 7643 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $EXPR" >&5 7644 $as_echo "$EXPR" >&6; } 7645 else 7646 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 7647 $as_echo "no" >&6; } 7648 fi 7649 7650 7651 test -n "$EXPR" && break 7652 done 7653 7654 else 7655 # The variable is set, but is it from the command line or the environment? 7656 7657 # Try to remove the string !EXPR! from our list. 7658 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!EXPR!/} 7659 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 7660 # If it failed, the variable was not from the command line. Ignore it, 7661 # but warn the user (except for BASH, which is always set by the calling BASH). 7662 if test "xEXPR" != xBASH; then 7663 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of EXPR from the environment. Use command line variables instead." >&5 7664 $as_echo "$as_me: WARNING: Ignoring value of EXPR from the environment. Use command line variables instead." >&2;} 7665 fi 7666 # Try to locate tool using the code snippet 7667 for ac_prog in expr 7668 do 7669 # Extract the first word of "$ac_prog", so it can be a program name with args. 7670 set dummy $ac_prog; ac_word=$2 7671 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 7672 $as_echo_n "checking for $ac_word... " >&6; } 7673 if ${ac_cv_path_EXPR+:} false; then : 7674 $as_echo_n "(cached) " >&6 7675 else 7676 case $EXPR in 7677 [\\/]* | ?:[\\/]*) 7678 ac_cv_path_EXPR="$EXPR" # Let the user override the test with a path. 7679 ;; 7680 *) 7681 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 7682 for as_dir in $PATH 7683 do 7684 IFS=$as_save_IFS 7685 test -z "$as_dir" && as_dir=. 7686 for ac_exec_ext in '' $ac_executable_extensions; do 7687 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 7688 ac_cv_path_EXPR="$as_dir/$ac_word$ac_exec_ext" 7689 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 7690 break 2 7691 fi 7692 done 7693 done 7694 IFS=$as_save_IFS 7695 7696 ;; 7697 esac 7698 fi 7699 EXPR=$ac_cv_path_EXPR 7700 if test -n "$EXPR"; then 7701 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $EXPR" >&5 7702 $as_echo "$EXPR" >&6; } 7703 else 7704 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 7705 $as_echo "no" >&6; } 7706 fi 7707 7708 7709 test -n "$EXPR" && break 7710 done 7711 7712 else 7713 # If it succeeded, then it was overridden by the user. We will use it 7714 # for the tool. 7715 7716 # First remove it from the list of overridden variables, so we can test 7717 # for unknown variables in the end. 7718 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 7719 7720 # Check if we try to supply an empty value 7721 if test "x$EXPR" = x; then 7722 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool EXPR= (no value)" >&5 7723 $as_echo "$as_me: Setting user supplied tool EXPR= (no value)" >&6;} 7724 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for EXPR" >&5 7725 $as_echo_n "checking for EXPR... " >&6; } 7726 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 7727 $as_echo "disabled" >&6; } 7728 else 7729 # Check if the provided tool contains a complete path. 7730 tool_specified="$EXPR" 7731 tool_basename="${tool_specified##*/}" 7732 if test "x$tool_basename" = "x$tool_specified"; then 7733 # A command without a complete path is provided, search $PATH. 7734 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool EXPR=$tool_basename" >&5 7735 $as_echo "$as_me: Will search for user supplied tool EXPR=$tool_basename" >&6;} 7736 # Extract the first word of "$tool_basename", so it can be a program name with args. 7737 set dummy $tool_basename; ac_word=$2 7738 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 7739 $as_echo_n "checking for $ac_word... " >&6; } 7740 if ${ac_cv_path_EXPR+:} false; then : 7741 $as_echo_n "(cached) " >&6 7742 else 7743 case $EXPR in 7744 [\\/]* | ?:[\\/]*) 7745 ac_cv_path_EXPR="$EXPR" # Let the user override the test with a path. 7746 ;; 7747 *) 7748 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 7749 for as_dir in $PATH 7750 do 7751 IFS=$as_save_IFS 7752 test -z "$as_dir" && as_dir=. 7753 for ac_exec_ext in '' $ac_executable_extensions; do 7754 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 7755 ac_cv_path_EXPR="$as_dir/$ac_word$ac_exec_ext" 7756 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 7757 break 2 7758 fi 7759 done 7760 done 7761 IFS=$as_save_IFS 7762 7763 ;; 7764 esac 7765 fi 7766 EXPR=$ac_cv_path_EXPR 7767 if test -n "$EXPR"; then 7768 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $EXPR" >&5 7769 $as_echo "$EXPR" >&6; } 7770 else 7771 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 7772 $as_echo "no" >&6; } 7773 fi 7774 7775 7776 if test "x$EXPR" = x; then 7777 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 7778 fi 7779 else 7780 # Otherwise we believe it is a complete path. Use it as it is. 7781 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool EXPR=$tool_specified" >&5 7782 $as_echo "$as_me: Will use user supplied tool EXPR=$tool_specified" >&6;} 7783 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for EXPR" >&5 7784 $as_echo_n "checking for EXPR... " >&6; } 7785 if test ! -x "$tool_specified"; then 7786 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 7787 $as_echo "not found" >&6; } 7788 as_fn_error $? "User supplied tool EXPR=$tool_specified does not exist or is not executable" "$LINENO" 5 7789 fi 7790 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 7791 $as_echo "$tool_specified" >&6; } 7792 fi 7793 fi 7794 fi 7795 7796 fi 7797 7798 7799 7800 if test "x$EXPR" = x; then 7801 as_fn_error $? "Could not find required tool for EXPR" "$LINENO" 5 7802 fi 7803 7804 7805 7806 7807 7808 # Publish this variable in the help. 7809 7810 7811 if [ -z "${FILE+x}" ]; then 7812 # The variable is not set by user, try to locate tool using the code snippet 7813 for ac_prog in file 7814 do 7815 # Extract the first word of "$ac_prog", so it can be a program name with args. 7816 set dummy $ac_prog; ac_word=$2 7817 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 7818 $as_echo_n "checking for $ac_word... " >&6; } 7819 if ${ac_cv_path_FILE+:} false; then : 7820 $as_echo_n "(cached) " >&6 7821 else 7822 case $FILE in 7823 [\\/]* | ?:[\\/]*) 7824 ac_cv_path_FILE="$FILE" # Let the user override the test with a path. 7825 ;; 7826 *) 7827 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 7828 for as_dir in $PATH 7829 do 7830 IFS=$as_save_IFS 7831 test -z "$as_dir" && as_dir=. 7832 for ac_exec_ext in '' $ac_executable_extensions; do 7833 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 7834 ac_cv_path_FILE="$as_dir/$ac_word$ac_exec_ext" 7835 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 7836 break 2 7837 fi 7838 done 7839 done 7840 IFS=$as_save_IFS 7841 7842 ;; 7843 esac 7844 fi 7845 FILE=$ac_cv_path_FILE 7846 if test -n "$FILE"; then 7847 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $FILE" >&5 7848 $as_echo "$FILE" >&6; } 7849 else 7850 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 7851 $as_echo "no" >&6; } 7852 fi 7853 7854 7855 test -n "$FILE" && break 7856 done 7857 7858 else 7859 # The variable is set, but is it from the command line or the environment? 7860 7861 # Try to remove the string !FILE! from our list. 7862 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!FILE!/} 7863 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 7864 # If it failed, the variable was not from the command line. Ignore it, 7865 # but warn the user (except for BASH, which is always set by the calling BASH). 7866 if test "xFILE" != xBASH; then 7867 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of FILE from the environment. Use command line variables instead." >&5 7868 $as_echo "$as_me: WARNING: Ignoring value of FILE from the environment. Use command line variables instead." >&2;} 7869 fi 7870 # Try to locate tool using the code snippet 7871 for ac_prog in file 7872 do 7873 # Extract the first word of "$ac_prog", so it can be a program name with args. 7874 set dummy $ac_prog; ac_word=$2 7875 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 7876 $as_echo_n "checking for $ac_word... " >&6; } 7877 if ${ac_cv_path_FILE+:} false; then : 7878 $as_echo_n "(cached) " >&6 7879 else 7880 case $FILE in 7881 [\\/]* | ?:[\\/]*) 7882 ac_cv_path_FILE="$FILE" # Let the user override the test with a path. 7883 ;; 7884 *) 7885 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 7886 for as_dir in $PATH 7887 do 7888 IFS=$as_save_IFS 7889 test -z "$as_dir" && as_dir=. 7890 for ac_exec_ext in '' $ac_executable_extensions; do 7891 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 7892 ac_cv_path_FILE="$as_dir/$ac_word$ac_exec_ext" 7893 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 7894 break 2 7895 fi 7896 done 7897 done 7898 IFS=$as_save_IFS 7899 7900 ;; 7901 esac 7902 fi 7903 FILE=$ac_cv_path_FILE 7904 if test -n "$FILE"; then 7905 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $FILE" >&5 7906 $as_echo "$FILE" >&6; } 7907 else 7908 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 7909 $as_echo "no" >&6; } 7910 fi 7911 7912 7913 test -n "$FILE" && break 7914 done 7915 7916 else 7917 # If it succeeded, then it was overridden by the user. We will use it 7918 # for the tool. 7919 7920 # First remove it from the list of overridden variables, so we can test 7921 # for unknown variables in the end. 7922 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 7923 7924 # Check if we try to supply an empty value 7925 if test "x$FILE" = x; then 7926 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool FILE= (no value)" >&5 7927 $as_echo "$as_me: Setting user supplied tool FILE= (no value)" >&6;} 7928 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for FILE" >&5 7929 $as_echo_n "checking for FILE... " >&6; } 7930 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 7931 $as_echo "disabled" >&6; } 7932 else 7933 # Check if the provided tool contains a complete path. 7934 tool_specified="$FILE" 7935 tool_basename="${tool_specified##*/}" 7936 if test "x$tool_basename" = "x$tool_specified"; then 7937 # A command without a complete path is provided, search $PATH. 7938 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool FILE=$tool_basename" >&5 7939 $as_echo "$as_me: Will search for user supplied tool FILE=$tool_basename" >&6;} 7940 # Extract the first word of "$tool_basename", so it can be a program name with args. 7941 set dummy $tool_basename; ac_word=$2 7942 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 7943 $as_echo_n "checking for $ac_word... " >&6; } 7944 if ${ac_cv_path_FILE+:} false; then : 7945 $as_echo_n "(cached) " >&6 7946 else 7947 case $FILE in 7948 [\\/]* | ?:[\\/]*) 7949 ac_cv_path_FILE="$FILE" # Let the user override the test with a path. 7950 ;; 7951 *) 7952 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 7953 for as_dir in $PATH 7954 do 7955 IFS=$as_save_IFS 7956 test -z "$as_dir" && as_dir=. 7957 for ac_exec_ext in '' $ac_executable_extensions; do 7958 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 7959 ac_cv_path_FILE="$as_dir/$ac_word$ac_exec_ext" 7960 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 7961 break 2 7962 fi 7963 done 7964 done 7965 IFS=$as_save_IFS 7966 7967 ;; 7968 esac 7969 fi 7970 FILE=$ac_cv_path_FILE 7971 if test -n "$FILE"; then 7972 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $FILE" >&5 7973 $as_echo "$FILE" >&6; } 7974 else 7975 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 7976 $as_echo "no" >&6; } 7977 fi 7978 7979 7980 if test "x$FILE" = x; then 7981 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 7982 fi 7983 else 7984 # Otherwise we believe it is a complete path. Use it as it is. 7985 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool FILE=$tool_specified" >&5 7986 $as_echo "$as_me: Will use user supplied tool FILE=$tool_specified" >&6;} 7987 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for FILE" >&5 7988 $as_echo_n "checking for FILE... " >&6; } 7989 if test ! -x "$tool_specified"; then 7990 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 7991 $as_echo "not found" >&6; } 7992 as_fn_error $? "User supplied tool FILE=$tool_specified does not exist or is not executable" "$LINENO" 5 7993 fi 7994 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 7995 $as_echo "$tool_specified" >&6; } 7996 fi 7997 fi 7998 fi 7999 8000 fi 8001 8002 8003 8004 if test "x$FILE" = x; then 8005 as_fn_error $? "Could not find required tool for FILE" "$LINENO" 5 8006 fi 8007 8008 8009 8010 8011 8012 # Publish this variable in the help. 8013 8014 8015 if [ -z "${FIND+x}" ]; then 8016 # The variable is not set by user, try to locate tool using the code snippet 8017 for ac_prog in find 8018 do 8019 # Extract the first word of "$ac_prog", so it can be a program name with args. 8020 set dummy $ac_prog; ac_word=$2 8021 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 8022 $as_echo_n "checking for $ac_word... " >&6; } 8023 if ${ac_cv_path_FIND+:} false; then : 8024 $as_echo_n "(cached) " >&6 8025 else 8026 case $FIND in 8027 [\\/]* | ?:[\\/]*) 8028 ac_cv_path_FIND="$FIND" # Let the user override the test with a path. 8029 ;; 8030 *) 8031 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 8032 for as_dir in $PATH 8033 do 8034 IFS=$as_save_IFS 8035 test -z "$as_dir" && as_dir=. 8036 for ac_exec_ext in '' $ac_executable_extensions; do 8037 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 8038 ac_cv_path_FIND="$as_dir/$ac_word$ac_exec_ext" 8039 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 8040 break 2 8041 fi 8042 done 8043 done 8044 IFS=$as_save_IFS 8045 8046 ;; 8047 esac 8048 fi 8049 FIND=$ac_cv_path_FIND 8050 if test -n "$FIND"; then 8051 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $FIND" >&5 8052 $as_echo "$FIND" >&6; } 8053 else 8054 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 8055 $as_echo "no" >&6; } 8056 fi 8057 8058 8059 test -n "$FIND" && break 8060 done 8061 8062 else 8063 # The variable is set, but is it from the command line or the environment? 8064 8065 # Try to remove the string !FIND! from our list. 8066 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!FIND!/} 8067 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 8068 # If it failed, the variable was not from the command line. Ignore it, 8069 # but warn the user (except for BASH, which is always set by the calling BASH). 8070 if test "xFIND" != xBASH; then 8071 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of FIND from the environment. Use command line variables instead." >&5 8072 $as_echo "$as_me: WARNING: Ignoring value of FIND from the environment. Use command line variables instead." >&2;} 8073 fi 8074 # Try to locate tool using the code snippet 8075 for ac_prog in find 8076 do 8077 # Extract the first word of "$ac_prog", so it can be a program name with args. 8078 set dummy $ac_prog; ac_word=$2 8079 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 8080 $as_echo_n "checking for $ac_word... " >&6; } 8081 if ${ac_cv_path_FIND+:} false; then : 8082 $as_echo_n "(cached) " >&6 8083 else 8084 case $FIND in 8085 [\\/]* | ?:[\\/]*) 8086 ac_cv_path_FIND="$FIND" # Let the user override the test with a path. 8087 ;; 8088 *) 8089 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 8090 for as_dir in $PATH 8091 do 8092 IFS=$as_save_IFS 8093 test -z "$as_dir" && as_dir=. 8094 for ac_exec_ext in '' $ac_executable_extensions; do 8095 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 8096 ac_cv_path_FIND="$as_dir/$ac_word$ac_exec_ext" 8097 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 8098 break 2 8099 fi 8100 done 8101 done 8102 IFS=$as_save_IFS 8103 8104 ;; 8105 esac 8106 fi 8107 FIND=$ac_cv_path_FIND 8108 if test -n "$FIND"; then 8109 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $FIND" >&5 8110 $as_echo "$FIND" >&6; } 8111 else 8112 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 8113 $as_echo "no" >&6; } 8114 fi 8115 8116 8117 test -n "$FIND" && break 8118 done 8119 8120 else 8121 # If it succeeded, then it was overridden by the user. We will use it 8122 # for the tool. 8123 8124 # First remove it from the list of overridden variables, so we can test 8125 # for unknown variables in the end. 8126 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 8127 8128 # Check if we try to supply an empty value 8129 if test "x$FIND" = x; then 8130 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool FIND= (no value)" >&5 8131 $as_echo "$as_me: Setting user supplied tool FIND= (no value)" >&6;} 8132 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for FIND" >&5 8133 $as_echo_n "checking for FIND... " >&6; } 8134 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 8135 $as_echo "disabled" >&6; } 8136 else 8137 # Check if the provided tool contains a complete path. 8138 tool_specified="$FIND" 8139 tool_basename="${tool_specified##*/}" 8140 if test "x$tool_basename" = "x$tool_specified"; then 8141 # A command without a complete path is provided, search $PATH. 8142 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool FIND=$tool_basename" >&5 8143 $as_echo "$as_me: Will search for user supplied tool FIND=$tool_basename" >&6;} 8144 # Extract the first word of "$tool_basename", so it can be a program name with args. 8145 set dummy $tool_basename; ac_word=$2 8146 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 8147 $as_echo_n "checking for $ac_word... " >&6; } 8148 if ${ac_cv_path_FIND+:} false; then : 8149 $as_echo_n "(cached) " >&6 8150 else 8151 case $FIND in 8152 [\\/]* | ?:[\\/]*) 8153 ac_cv_path_FIND="$FIND" # Let the user override the test with a path. 8154 ;; 8155 *) 8156 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 8157 for as_dir in $PATH 8158 do 8159 IFS=$as_save_IFS 8160 test -z "$as_dir" && as_dir=. 8161 for ac_exec_ext in '' $ac_executable_extensions; do 8162 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 8163 ac_cv_path_FIND="$as_dir/$ac_word$ac_exec_ext" 8164 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 8165 break 2 8166 fi 8167 done 8168 done 8169 IFS=$as_save_IFS 8170 8171 ;; 8172 esac 8173 fi 8174 FIND=$ac_cv_path_FIND 8175 if test -n "$FIND"; then 8176 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $FIND" >&5 8177 $as_echo "$FIND" >&6; } 8178 else 8179 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 8180 $as_echo "no" >&6; } 8181 fi 8182 8183 8184 if test "x$FIND" = x; then 8185 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 8186 fi 8187 else 8188 # Otherwise we believe it is a complete path. Use it as it is. 8189 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool FIND=$tool_specified" >&5 8190 $as_echo "$as_me: Will use user supplied tool FIND=$tool_specified" >&6;} 8191 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for FIND" >&5 8192 $as_echo_n "checking for FIND... " >&6; } 8193 if test ! -x "$tool_specified"; then 8194 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 8195 $as_echo "not found" >&6; } 8196 as_fn_error $? "User supplied tool FIND=$tool_specified does not exist or is not executable" "$LINENO" 5 8197 fi 8198 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 8199 $as_echo "$tool_specified" >&6; } 8200 fi 8201 fi 8202 fi 8203 8204 fi 8205 8206 8207 8208 if test "x$FIND" = x; then 8209 as_fn_error $? "Could not find required tool for FIND" "$LINENO" 5 8210 fi 8211 8212 8213 8214 8215 8216 # Publish this variable in the help. 8217 8218 8219 if [ -z "${HEAD+x}" ]; then 8220 # The variable is not set by user, try to locate tool using the code snippet 8221 for ac_prog in head 8222 do 8223 # Extract the first word of "$ac_prog", so it can be a program name with args. 8224 set dummy $ac_prog; ac_word=$2 8225 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 8226 $as_echo_n "checking for $ac_word... " >&6; } 8227 if ${ac_cv_path_HEAD+:} false; then : 8228 $as_echo_n "(cached) " >&6 8229 else 8230 case $HEAD in 8231 [\\/]* | ?:[\\/]*) 8232 ac_cv_path_HEAD="$HEAD" # Let the user override the test with a path. 8233 ;; 8234 *) 8235 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 8236 for as_dir in $PATH 8237 do 8238 IFS=$as_save_IFS 8239 test -z "$as_dir" && as_dir=. 8240 for ac_exec_ext in '' $ac_executable_extensions; do 8241 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 8242 ac_cv_path_HEAD="$as_dir/$ac_word$ac_exec_ext" 8243 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 8244 break 2 8245 fi 8246 done 8247 done 8248 IFS=$as_save_IFS 8249 8250 ;; 8251 esac 8252 fi 8253 HEAD=$ac_cv_path_HEAD 8254 if test -n "$HEAD"; then 8255 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $HEAD" >&5 8256 $as_echo "$HEAD" >&6; } 8257 else 8258 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 8259 $as_echo "no" >&6; } 8260 fi 8261 8262 8263 test -n "$HEAD" && break 8264 done 8265 8266 else 8267 # The variable is set, but is it from the command line or the environment? 8268 8269 # Try to remove the string !HEAD! from our list. 8270 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!HEAD!/} 8271 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 8272 # If it failed, the variable was not from the command line. Ignore it, 8273 # but warn the user (except for BASH, which is always set by the calling BASH). 8274 if test "xHEAD" != xBASH; then 8275 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of HEAD from the environment. Use command line variables instead." >&5 8276 $as_echo "$as_me: WARNING: Ignoring value of HEAD from the environment. Use command line variables instead." >&2;} 8277 fi 8278 # Try to locate tool using the code snippet 8279 for ac_prog in head 8280 do 8281 # Extract the first word of "$ac_prog", so it can be a program name with args. 8282 set dummy $ac_prog; ac_word=$2 8283 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 8284 $as_echo_n "checking for $ac_word... " >&6; } 8285 if ${ac_cv_path_HEAD+:} false; then : 8286 $as_echo_n "(cached) " >&6 8287 else 8288 case $HEAD in 8289 [\\/]* | ?:[\\/]*) 8290 ac_cv_path_HEAD="$HEAD" # Let the user override the test with a path. 8291 ;; 8292 *) 8293 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 8294 for as_dir in $PATH 8295 do 8296 IFS=$as_save_IFS 8297 test -z "$as_dir" && as_dir=. 8298 for ac_exec_ext in '' $ac_executable_extensions; do 8299 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 8300 ac_cv_path_HEAD="$as_dir/$ac_word$ac_exec_ext" 8301 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 8302 break 2 8303 fi 8304 done 8305 done 8306 IFS=$as_save_IFS 8307 8308 ;; 8309 esac 8310 fi 8311 HEAD=$ac_cv_path_HEAD 8312 if test -n "$HEAD"; then 8313 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $HEAD" >&5 8314 $as_echo "$HEAD" >&6; } 8315 else 8316 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 8317 $as_echo "no" >&6; } 8318 fi 8319 8320 8321 test -n "$HEAD" && break 8322 done 8323 8324 else 8325 # If it succeeded, then it was overridden by the user. We will use it 8326 # for the tool. 8327 8328 # First remove it from the list of overridden variables, so we can test 8329 # for unknown variables in the end. 8330 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 8331 8332 # Check if we try to supply an empty value 8333 if test "x$HEAD" = x; then 8334 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool HEAD= (no value)" >&5 8335 $as_echo "$as_me: Setting user supplied tool HEAD= (no value)" >&6;} 8336 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for HEAD" >&5 8337 $as_echo_n "checking for HEAD... " >&6; } 8338 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 8339 $as_echo "disabled" >&6; } 8340 else 8341 # Check if the provided tool contains a complete path. 8342 tool_specified="$HEAD" 8343 tool_basename="${tool_specified##*/}" 8344 if test "x$tool_basename" = "x$tool_specified"; then 8345 # A command without a complete path is provided, search $PATH. 8346 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool HEAD=$tool_basename" >&5 8347 $as_echo "$as_me: Will search for user supplied tool HEAD=$tool_basename" >&6;} 8348 # Extract the first word of "$tool_basename", so it can be a program name with args. 8349 set dummy $tool_basename; ac_word=$2 8350 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 8351 $as_echo_n "checking for $ac_word... " >&6; } 8352 if ${ac_cv_path_HEAD+:} false; then : 8353 $as_echo_n "(cached) " >&6 8354 else 8355 case $HEAD in 8356 [\\/]* | ?:[\\/]*) 8357 ac_cv_path_HEAD="$HEAD" # Let the user override the test with a path. 8358 ;; 8359 *) 8360 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 8361 for as_dir in $PATH 8362 do 8363 IFS=$as_save_IFS 8364 test -z "$as_dir" && as_dir=. 8365 for ac_exec_ext in '' $ac_executable_extensions; do 8366 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 8367 ac_cv_path_HEAD="$as_dir/$ac_word$ac_exec_ext" 8368 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 8369 break 2 8370 fi 8371 done 8372 done 8373 IFS=$as_save_IFS 8374 8375 ;; 8376 esac 8377 fi 8378 HEAD=$ac_cv_path_HEAD 8379 if test -n "$HEAD"; then 8380 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $HEAD" >&5 8381 $as_echo "$HEAD" >&6; } 8382 else 8383 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 8384 $as_echo "no" >&6; } 8385 fi 8386 8387 8388 if test "x$HEAD" = x; then 8389 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 8390 fi 8391 else 8392 # Otherwise we believe it is a complete path. Use it as it is. 8393 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool HEAD=$tool_specified" >&5 8394 $as_echo "$as_me: Will use user supplied tool HEAD=$tool_specified" >&6;} 8395 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for HEAD" >&5 8396 $as_echo_n "checking for HEAD... " >&6; } 8397 if test ! -x "$tool_specified"; then 8398 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 8399 $as_echo "not found" >&6; } 8400 as_fn_error $? "User supplied tool HEAD=$tool_specified does not exist or is not executable" "$LINENO" 5 8401 fi 8402 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 8403 $as_echo "$tool_specified" >&6; } 8404 fi 8405 fi 8406 fi 8407 8408 fi 8409 8410 8411 8412 if test "x$HEAD" = x; then 8413 as_fn_error $? "Could not find required tool for HEAD" "$LINENO" 5 8414 fi 8415 8416 8417 8418 8419 8420 # Publish this variable in the help. 8421 8422 8423 if [ -z "${GUNZIP+x}" ]; then 8424 # The variable is not set by user, try to locate tool using the code snippet 8425 for ac_prog in gunzip 8426 do 8427 # Extract the first word of "$ac_prog", so it can be a program name with args. 8428 set dummy $ac_prog; ac_word=$2 8429 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 8430 $as_echo_n "checking for $ac_word... " >&6; } 8431 if ${ac_cv_path_GUNZIP+:} false; then : 8432 $as_echo_n "(cached) " >&6 8433 else 8434 case $GUNZIP in 8435 [\\/]* | ?:[\\/]*) 8436 ac_cv_path_GUNZIP="$GUNZIP" # Let the user override the test with a path. 8437 ;; 8438 *) 8439 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 8440 for as_dir in $PATH 8441 do 8442 IFS=$as_save_IFS 8443 test -z "$as_dir" && as_dir=. 8444 for ac_exec_ext in '' $ac_executable_extensions; do 8445 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 8446 ac_cv_path_GUNZIP="$as_dir/$ac_word$ac_exec_ext" 8447 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 8448 break 2 8449 fi 8450 done 8451 done 8452 IFS=$as_save_IFS 8453 8454 ;; 8455 esac 8456 fi 8457 GUNZIP=$ac_cv_path_GUNZIP 8458 if test -n "$GUNZIP"; then 8459 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $GUNZIP" >&5 8460 $as_echo "$GUNZIP" >&6; } 8461 else 8462 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 8463 $as_echo "no" >&6; } 8464 fi 8465 8466 8467 test -n "$GUNZIP" && break 8468 done 8469 8470 else 8471 # The variable is set, but is it from the command line or the environment? 8472 8473 # Try to remove the string !GUNZIP! from our list. 8474 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!GUNZIP!/} 8475 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 8476 # If it failed, the variable was not from the command line. Ignore it, 8477 # but warn the user (except for BASH, which is always set by the calling BASH). 8478 if test "xGUNZIP" != xBASH; then 8479 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of GUNZIP from the environment. Use command line variables instead." >&5 8480 $as_echo "$as_me: WARNING: Ignoring value of GUNZIP from the environment. Use command line variables instead." >&2;} 8481 fi 8482 # Try to locate tool using the code snippet 8483 for ac_prog in gunzip 8484 do 8485 # Extract the first word of "$ac_prog", so it can be a program name with args. 8486 set dummy $ac_prog; ac_word=$2 8487 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 8488 $as_echo_n "checking for $ac_word... " >&6; } 8489 if ${ac_cv_path_GUNZIP+:} false; then : 8490 $as_echo_n "(cached) " >&6 8491 else 8492 case $GUNZIP in 8493 [\\/]* | ?:[\\/]*) 8494 ac_cv_path_GUNZIP="$GUNZIP" # Let the user override the test with a path. 8495 ;; 8496 *) 8497 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 8498 for as_dir in $PATH 8499 do 8500 IFS=$as_save_IFS 8501 test -z "$as_dir" && as_dir=. 8502 for ac_exec_ext in '' $ac_executable_extensions; do 8503 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 8504 ac_cv_path_GUNZIP="$as_dir/$ac_word$ac_exec_ext" 8505 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 8506 break 2 8507 fi 8508 done 8509 done 8510 IFS=$as_save_IFS 8511 8512 ;; 8513 esac 8514 fi 8515 GUNZIP=$ac_cv_path_GUNZIP 8516 if test -n "$GUNZIP"; then 8517 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $GUNZIP" >&5 8518 $as_echo "$GUNZIP" >&6; } 8519 else 8520 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 8521 $as_echo "no" >&6; } 8522 fi 8523 8524 8525 test -n "$GUNZIP" && break 8526 done 8527 8528 else 8529 # If it succeeded, then it was overridden by the user. We will use it 8530 # for the tool. 8531 8532 # First remove it from the list of overridden variables, so we can test 8533 # for unknown variables in the end. 8534 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 8535 8536 # Check if we try to supply an empty value 8537 if test "x$GUNZIP" = x; then 8538 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool GUNZIP= (no value)" >&5 8539 $as_echo "$as_me: Setting user supplied tool GUNZIP= (no value)" >&6;} 8540 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for GUNZIP" >&5 8541 $as_echo_n "checking for GUNZIP... " >&6; } 8542 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 8543 $as_echo "disabled" >&6; } 8544 else 8545 # Check if the provided tool contains a complete path. 8546 tool_specified="$GUNZIP" 8547 tool_basename="${tool_specified##*/}" 8548 if test "x$tool_basename" = "x$tool_specified"; then 8549 # A command without a complete path is provided, search $PATH. 8550 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool GUNZIP=$tool_basename" >&5 8551 $as_echo "$as_me: Will search for user supplied tool GUNZIP=$tool_basename" >&6;} 8552 # Extract the first word of "$tool_basename", so it can be a program name with args. 8553 set dummy $tool_basename; ac_word=$2 8554 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 8555 $as_echo_n "checking for $ac_word... " >&6; } 8556 if ${ac_cv_path_GUNZIP+:} false; then : 8557 $as_echo_n "(cached) " >&6 8558 else 8559 case $GUNZIP in 8560 [\\/]* | ?:[\\/]*) 8561 ac_cv_path_GUNZIP="$GUNZIP" # Let the user override the test with a path. 8562 ;; 8563 *) 8564 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 8565 for as_dir in $PATH 8566 do 8567 IFS=$as_save_IFS 8568 test -z "$as_dir" && as_dir=. 8569 for ac_exec_ext in '' $ac_executable_extensions; do 8570 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 8571 ac_cv_path_GUNZIP="$as_dir/$ac_word$ac_exec_ext" 8572 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 8573 break 2 8574 fi 8575 done 8576 done 8577 IFS=$as_save_IFS 8578 8579 ;; 8580 esac 8581 fi 8582 GUNZIP=$ac_cv_path_GUNZIP 8583 if test -n "$GUNZIP"; then 8584 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $GUNZIP" >&5 8585 $as_echo "$GUNZIP" >&6; } 8586 else 8587 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 8588 $as_echo "no" >&6; } 8589 fi 8590 8591 8592 if test "x$GUNZIP" = x; then 8593 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 8594 fi 8595 else 8596 # Otherwise we believe it is a complete path. Use it as it is. 8597 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool GUNZIP=$tool_specified" >&5 8598 $as_echo "$as_me: Will use user supplied tool GUNZIP=$tool_specified" >&6;} 8599 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for GUNZIP" >&5 8600 $as_echo_n "checking for GUNZIP... " >&6; } 8601 if test ! -x "$tool_specified"; then 8602 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 8603 $as_echo "not found" >&6; } 8604 as_fn_error $? "User supplied tool GUNZIP=$tool_specified does not exist or is not executable" "$LINENO" 5 8605 fi 8606 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 8607 $as_echo "$tool_specified" >&6; } 8608 fi 8609 fi 8610 fi 8611 8612 fi 8613 8614 8615 8616 if test "x$GUNZIP" = x; then 8617 as_fn_error $? "Could not find required tool for GUNZIP" "$LINENO" 5 8618 fi 8619 8620 8621 8622 8623 8624 # Publish this variable in the help. 8625 8626 8627 if [ -z "${GZIP+x}" ]; then 8628 # The variable is not set by user, try to locate tool using the code snippet 8629 for ac_prog in pigz gzip 8630 do 8631 # Extract the first word of "$ac_prog", so it can be a program name with args. 8632 set dummy $ac_prog; ac_word=$2 8633 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 8634 $as_echo_n "checking for $ac_word... " >&6; } 8635 if ${ac_cv_path_GZIP+:} false; then : 8636 $as_echo_n "(cached) " >&6 8637 else 8638 case $GZIP in 8639 [\\/]* | ?:[\\/]*) 8640 ac_cv_path_GZIP="$GZIP" # Let the user override the test with a path. 8641 ;; 8642 *) 8643 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 8644 for as_dir in $PATH 8645 do 8646 IFS=$as_save_IFS 8647 test -z "$as_dir" && as_dir=. 8648 for ac_exec_ext in '' $ac_executable_extensions; do 8649 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 8650 ac_cv_path_GZIP="$as_dir/$ac_word$ac_exec_ext" 8651 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 8652 break 2 8653 fi 8654 done 8655 done 8656 IFS=$as_save_IFS 8657 8658 ;; 8659 esac 8660 fi 8661 GZIP=$ac_cv_path_GZIP 8662 if test -n "$GZIP"; then 8663 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $GZIP" >&5 8664 $as_echo "$GZIP" >&6; } 8665 else 8666 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 8667 $as_echo "no" >&6; } 8668 fi 8669 8670 8671 test -n "$GZIP" && break 8672 done 8673 8674 else 8675 # The variable is set, but is it from the command line or the environment? 8676 8677 # Try to remove the string !GZIP! from our list. 8678 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!GZIP!/} 8679 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 8680 # If it failed, the variable was not from the command line. Ignore it, 8681 # but warn the user (except for BASH, which is always set by the calling BASH). 8682 if test "xGZIP" != xBASH; then 8683 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of GZIP from the environment. Use command line variables instead." >&5 8684 $as_echo "$as_me: WARNING: Ignoring value of GZIP from the environment. Use command line variables instead." >&2;} 8685 fi 8686 # Try to locate tool using the code snippet 8687 for ac_prog in pigz gzip 8688 do 8689 # Extract the first word of "$ac_prog", so it can be a program name with args. 8690 set dummy $ac_prog; ac_word=$2 8691 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 8692 $as_echo_n "checking for $ac_word... " >&6; } 8693 if ${ac_cv_path_GZIP+:} false; then : 8694 $as_echo_n "(cached) " >&6 8695 else 8696 case $GZIP in 8697 [\\/]* | ?:[\\/]*) 8698 ac_cv_path_GZIP="$GZIP" # Let the user override the test with a path. 8699 ;; 8700 *) 8701 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 8702 for as_dir in $PATH 8703 do 8704 IFS=$as_save_IFS 8705 test -z "$as_dir" && as_dir=. 8706 for ac_exec_ext in '' $ac_executable_extensions; do 8707 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 8708 ac_cv_path_GZIP="$as_dir/$ac_word$ac_exec_ext" 8709 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 8710 break 2 8711 fi 8712 done 8713 done 8714 IFS=$as_save_IFS 8715 8716 ;; 8717 esac 8718 fi 8719 GZIP=$ac_cv_path_GZIP 8720 if test -n "$GZIP"; then 8721 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $GZIP" >&5 8722 $as_echo "$GZIP" >&6; } 8723 else 8724 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 8725 $as_echo "no" >&6; } 8726 fi 8727 8728 8729 test -n "$GZIP" && break 8730 done 8731 8732 else 8733 # If it succeeded, then it was overridden by the user. We will use it 8734 # for the tool. 8735 8736 # First remove it from the list of overridden variables, so we can test 8737 # for unknown variables in the end. 8738 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 8739 8740 # Check if we try to supply an empty value 8741 if test "x$GZIP" = x; then 8742 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool GZIP= (no value)" >&5 8743 $as_echo "$as_me: Setting user supplied tool GZIP= (no value)" >&6;} 8744 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for GZIP" >&5 8745 $as_echo_n "checking for GZIP... " >&6; } 8746 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 8747 $as_echo "disabled" >&6; } 8748 else 8749 # Check if the provided tool contains a complete path. 8750 tool_specified="$GZIP" 8751 tool_basename="${tool_specified##*/}" 8752 if test "x$tool_basename" = "x$tool_specified"; then 8753 # A command without a complete path is provided, search $PATH. 8754 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool GZIP=$tool_basename" >&5 8755 $as_echo "$as_me: Will search for user supplied tool GZIP=$tool_basename" >&6;} 8756 # Extract the first word of "$tool_basename", so it can be a program name with args. 8757 set dummy $tool_basename; ac_word=$2 8758 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 8759 $as_echo_n "checking for $ac_word... " >&6; } 8760 if ${ac_cv_path_GZIP+:} false; then : 8761 $as_echo_n "(cached) " >&6 8762 else 8763 case $GZIP in 8764 [\\/]* | ?:[\\/]*) 8765 ac_cv_path_GZIP="$GZIP" # Let the user override the test with a path. 8766 ;; 8767 *) 8768 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 8769 for as_dir in $PATH 8770 do 8771 IFS=$as_save_IFS 8772 test -z "$as_dir" && as_dir=. 8773 for ac_exec_ext in '' $ac_executable_extensions; do 8774 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 8775 ac_cv_path_GZIP="$as_dir/$ac_word$ac_exec_ext" 8776 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 8777 break 2 8778 fi 8779 done 8780 done 8781 IFS=$as_save_IFS 8782 8783 ;; 8784 esac 8785 fi 8786 GZIP=$ac_cv_path_GZIP 8787 if test -n "$GZIP"; then 8788 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $GZIP" >&5 8789 $as_echo "$GZIP" >&6; } 8790 else 8791 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 8792 $as_echo "no" >&6; } 8793 fi 8794 8795 8796 if test "x$GZIP" = x; then 8797 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 8798 fi 8799 else 8800 # Otherwise we believe it is a complete path. Use it as it is. 8801 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool GZIP=$tool_specified" >&5 8802 $as_echo "$as_me: Will use user supplied tool GZIP=$tool_specified" >&6;} 8803 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for GZIP" >&5 8804 $as_echo_n "checking for GZIP... " >&6; } 8805 if test ! -x "$tool_specified"; then 8806 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 8807 $as_echo "not found" >&6; } 8808 as_fn_error $? "User supplied tool GZIP=$tool_specified does not exist or is not executable" "$LINENO" 5 8809 fi 8810 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 8811 $as_echo "$tool_specified" >&6; } 8812 fi 8813 fi 8814 fi 8815 8816 fi 8817 8818 8819 8820 if test "x$GZIP" = x; then 8821 as_fn_error $? "Could not find required tool for GZIP" "$LINENO" 5 8822 fi 8823 8824 8825 8826 8827 8828 # Publish this variable in the help. 8829 8830 8831 if [ -z "${LN+x}" ]; then 8832 # The variable is not set by user, try to locate tool using the code snippet 8833 for ac_prog in ln 8834 do 8835 # Extract the first word of "$ac_prog", so it can be a program name with args. 8836 set dummy $ac_prog; ac_word=$2 8837 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 8838 $as_echo_n "checking for $ac_word... " >&6; } 8839 if ${ac_cv_path_LN+:} false; then : 8840 $as_echo_n "(cached) " >&6 8841 else 8842 case $LN in 8843 [\\/]* | ?:[\\/]*) 8844 ac_cv_path_LN="$LN" # Let the user override the test with a path. 8845 ;; 8846 *) 8847 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 8848 for as_dir in $PATH 8849 do 8850 IFS=$as_save_IFS 8851 test -z "$as_dir" && as_dir=. 8852 for ac_exec_ext in '' $ac_executable_extensions; do 8853 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 8854 ac_cv_path_LN="$as_dir/$ac_word$ac_exec_ext" 8855 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 8856 break 2 8857 fi 8858 done 8859 done 8860 IFS=$as_save_IFS 8861 8862 ;; 8863 esac 8864 fi 8865 LN=$ac_cv_path_LN 8866 if test -n "$LN"; then 8867 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $LN" >&5 8868 $as_echo "$LN" >&6; } 8869 else 8870 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 8871 $as_echo "no" >&6; } 8872 fi 8873 8874 8875 test -n "$LN" && break 8876 done 8877 8878 else 8879 # The variable is set, but is it from the command line or the environment? 8880 8881 # Try to remove the string !LN! from our list. 8882 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!LN!/} 8883 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 8884 # If it failed, the variable was not from the command line. Ignore it, 8885 # but warn the user (except for BASH, which is always set by the calling BASH). 8886 if test "xLN" != xBASH; then 8887 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of LN from the environment. Use command line variables instead." >&5 8888 $as_echo "$as_me: WARNING: Ignoring value of LN from the environment. Use command line variables instead." >&2;} 8889 fi 8890 # Try to locate tool using the code snippet 8891 for ac_prog in ln 8892 do 8893 # Extract the first word of "$ac_prog", so it can be a program name with args. 8894 set dummy $ac_prog; ac_word=$2 8895 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 8896 $as_echo_n "checking for $ac_word... " >&6; } 8897 if ${ac_cv_path_LN+:} false; then : 8898 $as_echo_n "(cached) " >&6 8899 else 8900 case $LN in 8901 [\\/]* | ?:[\\/]*) 8902 ac_cv_path_LN="$LN" # Let the user override the test with a path. 8903 ;; 8904 *) 8905 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 8906 for as_dir in $PATH 8907 do 8908 IFS=$as_save_IFS 8909 test -z "$as_dir" && as_dir=. 8910 for ac_exec_ext in '' $ac_executable_extensions; do 8911 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 8912 ac_cv_path_LN="$as_dir/$ac_word$ac_exec_ext" 8913 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 8914 break 2 8915 fi 8916 done 8917 done 8918 IFS=$as_save_IFS 8919 8920 ;; 8921 esac 8922 fi 8923 LN=$ac_cv_path_LN 8924 if test -n "$LN"; then 8925 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $LN" >&5 8926 $as_echo "$LN" >&6; } 8927 else 8928 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 8929 $as_echo "no" >&6; } 8930 fi 8931 8932 8933 test -n "$LN" && break 8934 done 8935 8936 else 8937 # If it succeeded, then it was overridden by the user. We will use it 8938 # for the tool. 8939 8940 # First remove it from the list of overridden variables, so we can test 8941 # for unknown variables in the end. 8942 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 8943 8944 # Check if we try to supply an empty value 8945 if test "x$LN" = x; then 8946 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool LN= (no value)" >&5 8947 $as_echo "$as_me: Setting user supplied tool LN= (no value)" >&6;} 8948 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for LN" >&5 8949 $as_echo_n "checking for LN... " >&6; } 8950 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 8951 $as_echo "disabled" >&6; } 8952 else 8953 # Check if the provided tool contains a complete path. 8954 tool_specified="$LN" 8955 tool_basename="${tool_specified##*/}" 8956 if test "x$tool_basename" = "x$tool_specified"; then 8957 # A command without a complete path is provided, search $PATH. 8958 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool LN=$tool_basename" >&5 8959 $as_echo "$as_me: Will search for user supplied tool LN=$tool_basename" >&6;} 8960 # Extract the first word of "$tool_basename", so it can be a program name with args. 8961 set dummy $tool_basename; ac_word=$2 8962 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 8963 $as_echo_n "checking for $ac_word... " >&6; } 8964 if ${ac_cv_path_LN+:} false; then : 8965 $as_echo_n "(cached) " >&6 8966 else 8967 case $LN in 8968 [\\/]* | ?:[\\/]*) 8969 ac_cv_path_LN="$LN" # Let the user override the test with a path. 8970 ;; 8971 *) 8972 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 8973 for as_dir in $PATH 8974 do 8975 IFS=$as_save_IFS 8976 test -z "$as_dir" && as_dir=. 8977 for ac_exec_ext in '' $ac_executable_extensions; do 8978 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 8979 ac_cv_path_LN="$as_dir/$ac_word$ac_exec_ext" 8980 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 8981 break 2 8982 fi 8983 done 8984 done 8985 IFS=$as_save_IFS 8986 8987 ;; 8988 esac 8989 fi 8990 LN=$ac_cv_path_LN 8991 if test -n "$LN"; then 8992 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $LN" >&5 8993 $as_echo "$LN" >&6; } 8994 else 8995 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 8996 $as_echo "no" >&6; } 8997 fi 8998 8999 9000 if test "x$LN" = x; then 9001 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 9002 fi 9003 else 9004 # Otherwise we believe it is a complete path. Use it as it is. 9005 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool LN=$tool_specified" >&5 9006 $as_echo "$as_me: Will use user supplied tool LN=$tool_specified" >&6;} 9007 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for LN" >&5 9008 $as_echo_n "checking for LN... " >&6; } 9009 if test ! -x "$tool_specified"; then 9010 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 9011 $as_echo "not found" >&6; } 9012 as_fn_error $? "User supplied tool LN=$tool_specified does not exist or is not executable" "$LINENO" 5 9013 fi 9014 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 9015 $as_echo "$tool_specified" >&6; } 9016 fi 9017 fi 9018 fi 9019 9020 fi 9021 9022 9023 9024 if test "x$LN" = x; then 9025 as_fn_error $? "Could not find required tool for LN" "$LINENO" 5 9026 fi 9027 9028 9029 9030 9031 9032 # Publish this variable in the help. 9033 9034 9035 if [ -z "${LS+x}" ]; then 9036 # The variable is not set by user, try to locate tool using the code snippet 9037 for ac_prog in ls 9038 do 9039 # Extract the first word of "$ac_prog", so it can be a program name with args. 9040 set dummy $ac_prog; ac_word=$2 9041 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 9042 $as_echo_n "checking for $ac_word... " >&6; } 9043 if ${ac_cv_path_LS+:} false; then : 9044 $as_echo_n "(cached) " >&6 9045 else 9046 case $LS in 9047 [\\/]* | ?:[\\/]*) 9048 ac_cv_path_LS="$LS" # Let the user override the test with a path. 9049 ;; 9050 *) 9051 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 9052 for as_dir in $PATH 9053 do 9054 IFS=$as_save_IFS 9055 test -z "$as_dir" && as_dir=. 9056 for ac_exec_ext in '' $ac_executable_extensions; do 9057 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 9058 ac_cv_path_LS="$as_dir/$ac_word$ac_exec_ext" 9059 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 9060 break 2 9061 fi 9062 done 9063 done 9064 IFS=$as_save_IFS 9065 9066 ;; 9067 esac 9068 fi 9069 LS=$ac_cv_path_LS 9070 if test -n "$LS"; then 9071 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $LS" >&5 9072 $as_echo "$LS" >&6; } 9073 else 9074 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 9075 $as_echo "no" >&6; } 9076 fi 9077 9078 9079 test -n "$LS" && break 9080 done 9081 9082 else 9083 # The variable is set, but is it from the command line or the environment? 9084 9085 # Try to remove the string !LS! from our list. 9086 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!LS!/} 9087 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 9088 # If it failed, the variable was not from the command line. Ignore it, 9089 # but warn the user (except for BASH, which is always set by the calling BASH). 9090 if test "xLS" != xBASH; then 9091 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of LS from the environment. Use command line variables instead." >&5 9092 $as_echo "$as_me: WARNING: Ignoring value of LS from the environment. Use command line variables instead." >&2;} 9093 fi 9094 # Try to locate tool using the code snippet 9095 for ac_prog in ls 9096 do 9097 # Extract the first word of "$ac_prog", so it can be a program name with args. 9098 set dummy $ac_prog; ac_word=$2 9099 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 9100 $as_echo_n "checking for $ac_word... " >&6; } 9101 if ${ac_cv_path_LS+:} false; then : 9102 $as_echo_n "(cached) " >&6 9103 else 9104 case $LS in 9105 [\\/]* | ?:[\\/]*) 9106 ac_cv_path_LS="$LS" # Let the user override the test with a path. 9107 ;; 9108 *) 9109 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 9110 for as_dir in $PATH 9111 do 9112 IFS=$as_save_IFS 9113 test -z "$as_dir" && as_dir=. 9114 for ac_exec_ext in '' $ac_executable_extensions; do 9115 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 9116 ac_cv_path_LS="$as_dir/$ac_word$ac_exec_ext" 9117 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 9118 break 2 9119 fi 9120 done 9121 done 9122 IFS=$as_save_IFS 9123 9124 ;; 9125 esac 9126 fi 9127 LS=$ac_cv_path_LS 9128 if test -n "$LS"; then 9129 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $LS" >&5 9130 $as_echo "$LS" >&6; } 9131 else 9132 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 9133 $as_echo "no" >&6; } 9134 fi 9135 9136 9137 test -n "$LS" && break 9138 done 9139 9140 else 9141 # If it succeeded, then it was overridden by the user. We will use it 9142 # for the tool. 9143 9144 # First remove it from the list of overridden variables, so we can test 9145 # for unknown variables in the end. 9146 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 9147 9148 # Check if we try to supply an empty value 9149 if test "x$LS" = x; then 9150 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool LS= (no value)" >&5 9151 $as_echo "$as_me: Setting user supplied tool LS= (no value)" >&6;} 9152 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for LS" >&5 9153 $as_echo_n "checking for LS... " >&6; } 9154 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 9155 $as_echo "disabled" >&6; } 9156 else 9157 # Check if the provided tool contains a complete path. 9158 tool_specified="$LS" 9159 tool_basename="${tool_specified##*/}" 9160 if test "x$tool_basename" = "x$tool_specified"; then 9161 # A command without a complete path is provided, search $PATH. 9162 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool LS=$tool_basename" >&5 9163 $as_echo "$as_me: Will search for user supplied tool LS=$tool_basename" >&6;} 9164 # Extract the first word of "$tool_basename", so it can be a program name with args. 9165 set dummy $tool_basename; ac_word=$2 9166 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 9167 $as_echo_n "checking for $ac_word... " >&6; } 9168 if ${ac_cv_path_LS+:} false; then : 9169 $as_echo_n "(cached) " >&6 9170 else 9171 case $LS in 9172 [\\/]* | ?:[\\/]*) 9173 ac_cv_path_LS="$LS" # Let the user override the test with a path. 9174 ;; 9175 *) 9176 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 9177 for as_dir in $PATH 9178 do 9179 IFS=$as_save_IFS 9180 test -z "$as_dir" && as_dir=. 9181 for ac_exec_ext in '' $ac_executable_extensions; do 9182 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 9183 ac_cv_path_LS="$as_dir/$ac_word$ac_exec_ext" 9184 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 9185 break 2 9186 fi 9187 done 9188 done 9189 IFS=$as_save_IFS 9190 9191 ;; 9192 esac 9193 fi 9194 LS=$ac_cv_path_LS 9195 if test -n "$LS"; then 9196 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $LS" >&5 9197 $as_echo "$LS" >&6; } 9198 else 9199 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 9200 $as_echo "no" >&6; } 9201 fi 9202 9203 9204 if test "x$LS" = x; then 9205 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 9206 fi 9207 else 9208 # Otherwise we believe it is a complete path. Use it as it is. 9209 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool LS=$tool_specified" >&5 9210 $as_echo "$as_me: Will use user supplied tool LS=$tool_specified" >&6;} 9211 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for LS" >&5 9212 $as_echo_n "checking for LS... " >&6; } 9213 if test ! -x "$tool_specified"; then 9214 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 9215 $as_echo "not found" >&6; } 9216 as_fn_error $? "User supplied tool LS=$tool_specified does not exist or is not executable" "$LINENO" 5 9217 fi 9218 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 9219 $as_echo "$tool_specified" >&6; } 9220 fi 9221 fi 9222 fi 9223 9224 fi 9225 9226 9227 9228 if test "x$LS" = x; then 9229 as_fn_error $? "Could not find required tool for LS" "$LINENO" 5 9230 fi 9231 9232 9233 9234 9235 9236 # Publish this variable in the help. 9237 9238 9239 if [ -z "${MKDIR+x}" ]; then 9240 # The variable is not set by user, try to locate tool using the code snippet 9241 for ac_prog in mkdir 9242 do 9243 # Extract the first word of "$ac_prog", so it can be a program name with args. 9244 set dummy $ac_prog; ac_word=$2 9245 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 9246 $as_echo_n "checking for $ac_word... " >&6; } 9247 if ${ac_cv_path_MKDIR+:} false; then : 9248 $as_echo_n "(cached) " >&6 9249 else 9250 case $MKDIR in 9251 [\\/]* | ?:[\\/]*) 9252 ac_cv_path_MKDIR="$MKDIR" # Let the user override the test with a path. 9253 ;; 9254 *) 9255 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 9256 for as_dir in $PATH 9257 do 9258 IFS=$as_save_IFS 9259 test -z "$as_dir" && as_dir=. 9260 for ac_exec_ext in '' $ac_executable_extensions; do 9261 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 9262 ac_cv_path_MKDIR="$as_dir/$ac_word$ac_exec_ext" 9263 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 9264 break 2 9265 fi 9266 done 9267 done 9268 IFS=$as_save_IFS 9269 9270 ;; 9271 esac 9272 fi 9273 MKDIR=$ac_cv_path_MKDIR 9274 if test -n "$MKDIR"; then 9275 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MKDIR" >&5 9276 $as_echo "$MKDIR" >&6; } 9277 else 9278 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 9279 $as_echo "no" >&6; } 9280 fi 9281 9282 9283 test -n "$MKDIR" && break 9284 done 9285 9286 else 9287 # The variable is set, but is it from the command line or the environment? 9288 9289 # Try to remove the string !MKDIR! from our list. 9290 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!MKDIR!/} 9291 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 9292 # If it failed, the variable was not from the command line. Ignore it, 9293 # but warn the user (except for BASH, which is always set by the calling BASH). 9294 if test "xMKDIR" != xBASH; then 9295 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of MKDIR from the environment. Use command line variables instead." >&5 9296 $as_echo "$as_me: WARNING: Ignoring value of MKDIR from the environment. Use command line variables instead." >&2;} 9297 fi 9298 # Try to locate tool using the code snippet 9299 for ac_prog in mkdir 9300 do 9301 # Extract the first word of "$ac_prog", so it can be a program name with args. 9302 set dummy $ac_prog; ac_word=$2 9303 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 9304 $as_echo_n "checking for $ac_word... " >&6; } 9305 if ${ac_cv_path_MKDIR+:} false; then : 9306 $as_echo_n "(cached) " >&6 9307 else 9308 case $MKDIR in 9309 [\\/]* | ?:[\\/]*) 9310 ac_cv_path_MKDIR="$MKDIR" # Let the user override the test with a path. 9311 ;; 9312 *) 9313 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 9314 for as_dir in $PATH 9315 do 9316 IFS=$as_save_IFS 9317 test -z "$as_dir" && as_dir=. 9318 for ac_exec_ext in '' $ac_executable_extensions; do 9319 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 9320 ac_cv_path_MKDIR="$as_dir/$ac_word$ac_exec_ext" 9321 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 9322 break 2 9323 fi 9324 done 9325 done 9326 IFS=$as_save_IFS 9327 9328 ;; 9329 esac 9330 fi 9331 MKDIR=$ac_cv_path_MKDIR 9332 if test -n "$MKDIR"; then 9333 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MKDIR" >&5 9334 $as_echo "$MKDIR" >&6; } 9335 else 9336 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 9337 $as_echo "no" >&6; } 9338 fi 9339 9340 9341 test -n "$MKDIR" && break 9342 done 9343 9344 else 9345 # If it succeeded, then it was overridden by the user. We will use it 9346 # for the tool. 9347 9348 # First remove it from the list of overridden variables, so we can test 9349 # for unknown variables in the end. 9350 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 9351 9352 # Check if we try to supply an empty value 9353 if test "x$MKDIR" = x; then 9354 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool MKDIR= (no value)" >&5 9355 $as_echo "$as_me: Setting user supplied tool MKDIR= (no value)" >&6;} 9356 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for MKDIR" >&5 9357 $as_echo_n "checking for MKDIR... " >&6; } 9358 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 9359 $as_echo "disabled" >&6; } 9360 else 9361 # Check if the provided tool contains a complete path. 9362 tool_specified="$MKDIR" 9363 tool_basename="${tool_specified##*/}" 9364 if test "x$tool_basename" = "x$tool_specified"; then 9365 # A command without a complete path is provided, search $PATH. 9366 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool MKDIR=$tool_basename" >&5 9367 $as_echo "$as_me: Will search for user supplied tool MKDIR=$tool_basename" >&6;} 9368 # Extract the first word of "$tool_basename", so it can be a program name with args. 9369 set dummy $tool_basename; ac_word=$2 9370 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 9371 $as_echo_n "checking for $ac_word... " >&6; } 9372 if ${ac_cv_path_MKDIR+:} false; then : 9373 $as_echo_n "(cached) " >&6 9374 else 9375 case $MKDIR in 9376 [\\/]* | ?:[\\/]*) 9377 ac_cv_path_MKDIR="$MKDIR" # Let the user override the test with a path. 9378 ;; 9379 *) 9380 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 9381 for as_dir in $PATH 9382 do 9383 IFS=$as_save_IFS 9384 test -z "$as_dir" && as_dir=. 9385 for ac_exec_ext in '' $ac_executable_extensions; do 9386 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 9387 ac_cv_path_MKDIR="$as_dir/$ac_word$ac_exec_ext" 9388 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 9389 break 2 9390 fi 9391 done 9392 done 9393 IFS=$as_save_IFS 9394 9395 ;; 9396 esac 9397 fi 9398 MKDIR=$ac_cv_path_MKDIR 9399 if test -n "$MKDIR"; then 9400 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MKDIR" >&5 9401 $as_echo "$MKDIR" >&6; } 9402 else 9403 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 9404 $as_echo "no" >&6; } 9405 fi 9406 9407 9408 if test "x$MKDIR" = x; then 9409 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 9410 fi 9411 else 9412 # Otherwise we believe it is a complete path. Use it as it is. 9413 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool MKDIR=$tool_specified" >&5 9414 $as_echo "$as_me: Will use user supplied tool MKDIR=$tool_specified" >&6;} 9415 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for MKDIR" >&5 9416 $as_echo_n "checking for MKDIR... " >&6; } 9417 if test ! -x "$tool_specified"; then 9418 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 9419 $as_echo "not found" >&6; } 9420 as_fn_error $? "User supplied tool MKDIR=$tool_specified does not exist or is not executable" "$LINENO" 5 9421 fi 9422 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 9423 $as_echo "$tool_specified" >&6; } 9424 fi 9425 fi 9426 fi 9427 9428 fi 9429 9430 9431 9432 if test "x$MKDIR" = x; then 9433 as_fn_error $? "Could not find required tool for MKDIR" "$LINENO" 5 9434 fi 9435 9436 9437 9438 9439 9440 # Publish this variable in the help. 9441 9442 9443 if [ -z "${MKTEMP+x}" ]; then 9444 # The variable is not set by user, try to locate tool using the code snippet 9445 for ac_prog in mktemp 9446 do 9447 # Extract the first word of "$ac_prog", so it can be a program name with args. 9448 set dummy $ac_prog; ac_word=$2 9449 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 9450 $as_echo_n "checking for $ac_word... " >&6; } 9451 if ${ac_cv_path_MKTEMP+:} false; then : 9452 $as_echo_n "(cached) " >&6 9453 else 9454 case $MKTEMP in 9455 [\\/]* | ?:[\\/]*) 9456 ac_cv_path_MKTEMP="$MKTEMP" # Let the user override the test with a path. 9457 ;; 9458 *) 9459 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 9460 for as_dir in $PATH 9461 do 9462 IFS=$as_save_IFS 9463 test -z "$as_dir" && as_dir=. 9464 for ac_exec_ext in '' $ac_executable_extensions; do 9465 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 9466 ac_cv_path_MKTEMP="$as_dir/$ac_word$ac_exec_ext" 9467 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 9468 break 2 9469 fi 9470 done 9471 done 9472 IFS=$as_save_IFS 9473 9474 ;; 9475 esac 9476 fi 9477 MKTEMP=$ac_cv_path_MKTEMP 9478 if test -n "$MKTEMP"; then 9479 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MKTEMP" >&5 9480 $as_echo "$MKTEMP" >&6; } 9481 else 9482 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 9483 $as_echo "no" >&6; } 9484 fi 9485 9486 9487 test -n "$MKTEMP" && break 9488 done 9489 9490 else 9491 # The variable is set, but is it from the command line or the environment? 9492 9493 # Try to remove the string !MKTEMP! from our list. 9494 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!MKTEMP!/} 9495 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 9496 # If it failed, the variable was not from the command line. Ignore it, 9497 # but warn the user (except for BASH, which is always set by the calling BASH). 9498 if test "xMKTEMP" != xBASH; then 9499 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of MKTEMP from the environment. Use command line variables instead." >&5 9500 $as_echo "$as_me: WARNING: Ignoring value of MKTEMP from the environment. Use command line variables instead." >&2;} 9501 fi 9502 # Try to locate tool using the code snippet 9503 for ac_prog in mktemp 9504 do 9505 # Extract the first word of "$ac_prog", so it can be a program name with args. 9506 set dummy $ac_prog; ac_word=$2 9507 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 9508 $as_echo_n "checking for $ac_word... " >&6; } 9509 if ${ac_cv_path_MKTEMP+:} false; then : 9510 $as_echo_n "(cached) " >&6 9511 else 9512 case $MKTEMP in 9513 [\\/]* | ?:[\\/]*) 9514 ac_cv_path_MKTEMP="$MKTEMP" # Let the user override the test with a path. 9515 ;; 9516 *) 9517 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 9518 for as_dir in $PATH 9519 do 9520 IFS=$as_save_IFS 9521 test -z "$as_dir" && as_dir=. 9522 for ac_exec_ext in '' $ac_executable_extensions; do 9523 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 9524 ac_cv_path_MKTEMP="$as_dir/$ac_word$ac_exec_ext" 9525 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 9526 break 2 9527 fi 9528 done 9529 done 9530 IFS=$as_save_IFS 9531 9532 ;; 9533 esac 9534 fi 9535 MKTEMP=$ac_cv_path_MKTEMP 9536 if test -n "$MKTEMP"; then 9537 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MKTEMP" >&5 9538 $as_echo "$MKTEMP" >&6; } 9539 else 9540 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 9541 $as_echo "no" >&6; } 9542 fi 9543 9544 9545 test -n "$MKTEMP" && break 9546 done 9547 9548 else 9549 # If it succeeded, then it was overridden by the user. We will use it 9550 # for the tool. 9551 9552 # First remove it from the list of overridden variables, so we can test 9553 # for unknown variables in the end. 9554 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 9555 9556 # Check if we try to supply an empty value 9557 if test "x$MKTEMP" = x; then 9558 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool MKTEMP= (no value)" >&5 9559 $as_echo "$as_me: Setting user supplied tool MKTEMP= (no value)" >&6;} 9560 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for MKTEMP" >&5 9561 $as_echo_n "checking for MKTEMP... " >&6; } 9562 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 9563 $as_echo "disabled" >&6; } 9564 else 9565 # Check if the provided tool contains a complete path. 9566 tool_specified="$MKTEMP" 9567 tool_basename="${tool_specified##*/}" 9568 if test "x$tool_basename" = "x$tool_specified"; then 9569 # A command without a complete path is provided, search $PATH. 9570 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool MKTEMP=$tool_basename" >&5 9571 $as_echo "$as_me: Will search for user supplied tool MKTEMP=$tool_basename" >&6;} 9572 # Extract the first word of "$tool_basename", so it can be a program name with args. 9573 set dummy $tool_basename; ac_word=$2 9574 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 9575 $as_echo_n "checking for $ac_word... " >&6; } 9576 if ${ac_cv_path_MKTEMP+:} false; then : 9577 $as_echo_n "(cached) " >&6 9578 else 9579 case $MKTEMP in 9580 [\\/]* | ?:[\\/]*) 9581 ac_cv_path_MKTEMP="$MKTEMP" # Let the user override the test with a path. 9582 ;; 9583 *) 9584 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 9585 for as_dir in $PATH 9586 do 9587 IFS=$as_save_IFS 9588 test -z "$as_dir" && as_dir=. 9589 for ac_exec_ext in '' $ac_executable_extensions; do 9590 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 9591 ac_cv_path_MKTEMP="$as_dir/$ac_word$ac_exec_ext" 9592 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 9593 break 2 9594 fi 9595 done 9596 done 9597 IFS=$as_save_IFS 9598 9599 ;; 9600 esac 9601 fi 9602 MKTEMP=$ac_cv_path_MKTEMP 9603 if test -n "$MKTEMP"; then 9604 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MKTEMP" >&5 9605 $as_echo "$MKTEMP" >&6; } 9606 else 9607 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 9608 $as_echo "no" >&6; } 9609 fi 9610 9611 9612 if test "x$MKTEMP" = x; then 9613 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 9614 fi 9615 else 9616 # Otherwise we believe it is a complete path. Use it as it is. 9617 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool MKTEMP=$tool_specified" >&5 9618 $as_echo "$as_me: Will use user supplied tool MKTEMP=$tool_specified" >&6;} 9619 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for MKTEMP" >&5 9620 $as_echo_n "checking for MKTEMP... " >&6; } 9621 if test ! -x "$tool_specified"; then 9622 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 9623 $as_echo "not found" >&6; } 9624 as_fn_error $? "User supplied tool MKTEMP=$tool_specified does not exist or is not executable" "$LINENO" 5 9625 fi 9626 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 9627 $as_echo "$tool_specified" >&6; } 9628 fi 9629 fi 9630 fi 9631 9632 fi 9633 9634 9635 9636 if test "x$MKTEMP" = x; then 9637 as_fn_error $? "Could not find required tool for MKTEMP" "$LINENO" 5 9638 fi 9639 9640 9641 9642 9643 9644 # Publish this variable in the help. 9645 9646 9647 if [ -z "${MV+x}" ]; then 9648 # The variable is not set by user, try to locate tool using the code snippet 9649 for ac_prog in mv 9650 do 9651 # Extract the first word of "$ac_prog", so it can be a program name with args. 9652 set dummy $ac_prog; ac_word=$2 9653 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 9654 $as_echo_n "checking for $ac_word... " >&6; } 9655 if ${ac_cv_path_MV+:} false; then : 9656 $as_echo_n "(cached) " >&6 9657 else 9658 case $MV in 9659 [\\/]* | ?:[\\/]*) 9660 ac_cv_path_MV="$MV" # Let the user override the test with a path. 9661 ;; 9662 *) 9663 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 9664 for as_dir in $PATH 9665 do 9666 IFS=$as_save_IFS 9667 test -z "$as_dir" && as_dir=. 9668 for ac_exec_ext in '' $ac_executable_extensions; do 9669 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 9670 ac_cv_path_MV="$as_dir/$ac_word$ac_exec_ext" 9671 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 9672 break 2 9673 fi 9674 done 9675 done 9676 IFS=$as_save_IFS 9677 9678 ;; 9679 esac 9680 fi 9681 MV=$ac_cv_path_MV 9682 if test -n "$MV"; then 9683 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MV" >&5 9684 $as_echo "$MV" >&6; } 9685 else 9686 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 9687 $as_echo "no" >&6; } 9688 fi 9689 9690 9691 test -n "$MV" && break 9692 done 9693 9694 else 9695 # The variable is set, but is it from the command line or the environment? 9696 9697 # Try to remove the string !MV! from our list. 9698 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!MV!/} 9699 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 9700 # If it failed, the variable was not from the command line. Ignore it, 9701 # but warn the user (except for BASH, which is always set by the calling BASH). 9702 if test "xMV" != xBASH; then 9703 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of MV from the environment. Use command line variables instead." >&5 9704 $as_echo "$as_me: WARNING: Ignoring value of MV from the environment. Use command line variables instead." >&2;} 9705 fi 9706 # Try to locate tool using the code snippet 9707 for ac_prog in mv 9708 do 9709 # Extract the first word of "$ac_prog", so it can be a program name with args. 9710 set dummy $ac_prog; ac_word=$2 9711 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 9712 $as_echo_n "checking for $ac_word... " >&6; } 9713 if ${ac_cv_path_MV+:} false; then : 9714 $as_echo_n "(cached) " >&6 9715 else 9716 case $MV in 9717 [\\/]* | ?:[\\/]*) 9718 ac_cv_path_MV="$MV" # Let the user override the test with a path. 9719 ;; 9720 *) 9721 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 9722 for as_dir in $PATH 9723 do 9724 IFS=$as_save_IFS 9725 test -z "$as_dir" && as_dir=. 9726 for ac_exec_ext in '' $ac_executable_extensions; do 9727 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 9728 ac_cv_path_MV="$as_dir/$ac_word$ac_exec_ext" 9729 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 9730 break 2 9731 fi 9732 done 9733 done 9734 IFS=$as_save_IFS 9735 9736 ;; 9737 esac 9738 fi 9739 MV=$ac_cv_path_MV 9740 if test -n "$MV"; then 9741 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MV" >&5 9742 $as_echo "$MV" >&6; } 9743 else 9744 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 9745 $as_echo "no" >&6; } 9746 fi 9747 9748 9749 test -n "$MV" && break 9750 done 9751 9752 else 9753 # If it succeeded, then it was overridden by the user. We will use it 9754 # for the tool. 9755 9756 # First remove it from the list of overridden variables, so we can test 9757 # for unknown variables in the end. 9758 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 9759 9760 # Check if we try to supply an empty value 9761 if test "x$MV" = x; then 9762 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool MV= (no value)" >&5 9763 $as_echo "$as_me: Setting user supplied tool MV= (no value)" >&6;} 9764 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for MV" >&5 9765 $as_echo_n "checking for MV... " >&6; } 9766 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 9767 $as_echo "disabled" >&6; } 9768 else 9769 # Check if the provided tool contains a complete path. 9770 tool_specified="$MV" 9771 tool_basename="${tool_specified##*/}" 9772 if test "x$tool_basename" = "x$tool_specified"; then 9773 # A command without a complete path is provided, search $PATH. 9774 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool MV=$tool_basename" >&5 9775 $as_echo "$as_me: Will search for user supplied tool MV=$tool_basename" >&6;} 9776 # Extract the first word of "$tool_basename", so it can be a program name with args. 9777 set dummy $tool_basename; ac_word=$2 9778 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 9779 $as_echo_n "checking for $ac_word... " >&6; } 9780 if ${ac_cv_path_MV+:} false; then : 9781 $as_echo_n "(cached) " >&6 9782 else 9783 case $MV in 9784 [\\/]* | ?:[\\/]*) 9785 ac_cv_path_MV="$MV" # Let the user override the test with a path. 9786 ;; 9787 *) 9788 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 9789 for as_dir in $PATH 9790 do 9791 IFS=$as_save_IFS 9792 test -z "$as_dir" && as_dir=. 9793 for ac_exec_ext in '' $ac_executable_extensions; do 9794 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 9795 ac_cv_path_MV="$as_dir/$ac_word$ac_exec_ext" 9796 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 9797 break 2 9798 fi 9799 done 9800 done 9801 IFS=$as_save_IFS 9802 9803 ;; 9804 esac 9805 fi 9806 MV=$ac_cv_path_MV 9807 if test -n "$MV"; then 9808 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MV" >&5 9809 $as_echo "$MV" >&6; } 9810 else 9811 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 9812 $as_echo "no" >&6; } 9813 fi 9814 9815 9816 if test "x$MV" = x; then 9817 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 9818 fi 9819 else 9820 # Otherwise we believe it is a complete path. Use it as it is. 9821 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool MV=$tool_specified" >&5 9822 $as_echo "$as_me: Will use user supplied tool MV=$tool_specified" >&6;} 9823 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for MV" >&5 9824 $as_echo_n "checking for MV... " >&6; } 9825 if test ! -x "$tool_specified"; then 9826 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 9827 $as_echo "not found" >&6; } 9828 as_fn_error $? "User supplied tool MV=$tool_specified does not exist or is not executable" "$LINENO" 5 9829 fi 9830 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 9831 $as_echo "$tool_specified" >&6; } 9832 fi 9833 fi 9834 fi 9835 9836 fi 9837 9838 9839 9840 if test "x$MV" = x; then 9841 as_fn_error $? "Could not find required tool for MV" "$LINENO" 5 9842 fi 9843 9844 9845 9846 9847 9848 # Publish this variable in the help. 9849 9850 9851 if [ -z "${NAWK+x}" ]; then 9852 # The variable is not set by user, try to locate tool using the code snippet 9853 for ac_prog in nawk gawk awk 9854 do 9855 # Extract the first word of "$ac_prog", so it can be a program name with args. 9856 set dummy $ac_prog; ac_word=$2 9857 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 9858 $as_echo_n "checking for $ac_word... " >&6; } 9859 if ${ac_cv_path_NAWK+:} false; then : 9860 $as_echo_n "(cached) " >&6 9861 else 9862 case $NAWK in 9863 [\\/]* | ?:[\\/]*) 9864 ac_cv_path_NAWK="$NAWK" # Let the user override the test with a path. 9865 ;; 9866 *) 9867 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 9868 for as_dir in $PATH 9869 do 9870 IFS=$as_save_IFS 9871 test -z "$as_dir" && as_dir=. 9872 for ac_exec_ext in '' $ac_executable_extensions; do 9873 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 9874 ac_cv_path_NAWK="$as_dir/$ac_word$ac_exec_ext" 9875 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 9876 break 2 9877 fi 9878 done 9879 done 9880 IFS=$as_save_IFS 9881 9882 ;; 9883 esac 9884 fi 9885 NAWK=$ac_cv_path_NAWK 9886 if test -n "$NAWK"; then 9887 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $NAWK" >&5 9888 $as_echo "$NAWK" >&6; } 9889 else 9890 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 9891 $as_echo "no" >&6; } 9892 fi 9893 9894 9895 test -n "$NAWK" && break 9896 done 9897 9898 else 9899 # The variable is set, but is it from the command line or the environment? 9900 9901 # Try to remove the string !NAWK! from our list. 9902 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!NAWK!/} 9903 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 9904 # If it failed, the variable was not from the command line. Ignore it, 9905 # but warn the user (except for BASH, which is always set by the calling BASH). 9906 if test "xNAWK" != xBASH; then 9907 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of NAWK from the environment. Use command line variables instead." >&5 9908 $as_echo "$as_me: WARNING: Ignoring value of NAWK from the environment. Use command line variables instead." >&2;} 9909 fi 9910 # Try to locate tool using the code snippet 9911 for ac_prog in nawk gawk awk 9912 do 9913 # Extract the first word of "$ac_prog", so it can be a program name with args. 9914 set dummy $ac_prog; ac_word=$2 9915 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 9916 $as_echo_n "checking for $ac_word... " >&6; } 9917 if ${ac_cv_path_NAWK+:} false; then : 9918 $as_echo_n "(cached) " >&6 9919 else 9920 case $NAWK in 9921 [\\/]* | ?:[\\/]*) 9922 ac_cv_path_NAWK="$NAWK" # Let the user override the test with a path. 9923 ;; 9924 *) 9925 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 9926 for as_dir in $PATH 9927 do 9928 IFS=$as_save_IFS 9929 test -z "$as_dir" && as_dir=. 9930 for ac_exec_ext in '' $ac_executable_extensions; do 9931 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 9932 ac_cv_path_NAWK="$as_dir/$ac_word$ac_exec_ext" 9933 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 9934 break 2 9935 fi 9936 done 9937 done 9938 IFS=$as_save_IFS 9939 9940 ;; 9941 esac 9942 fi 9943 NAWK=$ac_cv_path_NAWK 9944 if test -n "$NAWK"; then 9945 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $NAWK" >&5 9946 $as_echo "$NAWK" >&6; } 9947 else 9948 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 9949 $as_echo "no" >&6; } 9950 fi 9951 9952 9953 test -n "$NAWK" && break 9954 done 9955 9956 else 9957 # If it succeeded, then it was overridden by the user. We will use it 9958 # for the tool. 9959 9960 # First remove it from the list of overridden variables, so we can test 9961 # for unknown variables in the end. 9962 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 9963 9964 # Check if we try to supply an empty value 9965 if test "x$NAWK" = x; then 9966 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool NAWK= (no value)" >&5 9967 $as_echo "$as_me: Setting user supplied tool NAWK= (no value)" >&6;} 9968 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for NAWK" >&5 9969 $as_echo_n "checking for NAWK... " >&6; } 9970 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 9971 $as_echo "disabled" >&6; } 9972 else 9973 # Check if the provided tool contains a complete path. 9974 tool_specified="$NAWK" 9975 tool_basename="${tool_specified##*/}" 9976 if test "x$tool_basename" = "x$tool_specified"; then 9977 # A command without a complete path is provided, search $PATH. 9978 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool NAWK=$tool_basename" >&5 9979 $as_echo "$as_me: Will search for user supplied tool NAWK=$tool_basename" >&6;} 9980 # Extract the first word of "$tool_basename", so it can be a program name with args. 9981 set dummy $tool_basename; ac_word=$2 9982 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 9983 $as_echo_n "checking for $ac_word... " >&6; } 9984 if ${ac_cv_path_NAWK+:} false; then : 9985 $as_echo_n "(cached) " >&6 9986 else 9987 case $NAWK in 9988 [\\/]* | ?:[\\/]*) 9989 ac_cv_path_NAWK="$NAWK" # Let the user override the test with a path. 9990 ;; 9991 *) 9992 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 9993 for as_dir in $PATH 9994 do 9995 IFS=$as_save_IFS 9996 test -z "$as_dir" && as_dir=. 9997 for ac_exec_ext in '' $ac_executable_extensions; do 9998 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 9999 ac_cv_path_NAWK="$as_dir/$ac_word$ac_exec_ext" 10000 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 10001 break 2 10002 fi 10003 done 10004 done 10005 IFS=$as_save_IFS 10006 10007 ;; 10008 esac 10009 fi 10010 NAWK=$ac_cv_path_NAWK 10011 if test -n "$NAWK"; then 10012 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $NAWK" >&5 10013 $as_echo "$NAWK" >&6; } 10014 else 10015 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 10016 $as_echo "no" >&6; } 10017 fi 10018 10019 10020 if test "x$NAWK" = x; then 10021 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 10022 fi 10023 else 10024 # Otherwise we believe it is a complete path. Use it as it is. 10025 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool NAWK=$tool_specified" >&5 10026 $as_echo "$as_me: Will use user supplied tool NAWK=$tool_specified" >&6;} 10027 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for NAWK" >&5 10028 $as_echo_n "checking for NAWK... " >&6; } 10029 if test ! -x "$tool_specified"; then 10030 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 10031 $as_echo "not found" >&6; } 10032 as_fn_error $? "User supplied tool NAWK=$tool_specified does not exist or is not executable" "$LINENO" 5 10033 fi 10034 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 10035 $as_echo "$tool_specified" >&6; } 10036 fi 10037 fi 10038 fi 10039 10040 fi 10041 10042 10043 10044 if test "x$NAWK" = x; then 10045 as_fn_error $? "Could not find required tool for NAWK" "$LINENO" 5 10046 fi 10047 10048 10049 10050 10051 10052 # Publish this variable in the help. 10053 10054 10055 if [ -z "${PRINTF+x}" ]; then 10056 # The variable is not set by user, try to locate tool using the code snippet 10057 for ac_prog in printf 10058 do 10059 # Extract the first word of "$ac_prog", so it can be a program name with args. 10060 set dummy $ac_prog; ac_word=$2 10061 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 10062 $as_echo_n "checking for $ac_word... " >&6; } 10063 if ${ac_cv_path_PRINTF+:} false; then : 10064 $as_echo_n "(cached) " >&6 10065 else 10066 case $PRINTF in 10067 [\\/]* | ?:[\\/]*) 10068 ac_cv_path_PRINTF="$PRINTF" # Let the user override the test with a path. 10069 ;; 10070 *) 10071 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 10072 for as_dir in $PATH 10073 do 10074 IFS=$as_save_IFS 10075 test -z "$as_dir" && as_dir=. 10076 for ac_exec_ext in '' $ac_executable_extensions; do 10077 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 10078 ac_cv_path_PRINTF="$as_dir/$ac_word$ac_exec_ext" 10079 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 10080 break 2 10081 fi 10082 done 10083 done 10084 IFS=$as_save_IFS 10085 10086 ;; 10087 esac 10088 fi 10089 PRINTF=$ac_cv_path_PRINTF 10090 if test -n "$PRINTF"; then 10091 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $PRINTF" >&5 10092 $as_echo "$PRINTF" >&6; } 10093 else 10094 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 10095 $as_echo "no" >&6; } 10096 fi 10097 10098 10099 test -n "$PRINTF" && break 10100 done 10101 10102 else 10103 # The variable is set, but is it from the command line or the environment? 10104 10105 # Try to remove the string !PRINTF! from our list. 10106 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!PRINTF!/} 10107 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 10108 # If it failed, the variable was not from the command line. Ignore it, 10109 # but warn the user (except for BASH, which is always set by the calling BASH). 10110 if test "xPRINTF" != xBASH; then 10111 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of PRINTF from the environment. Use command line variables instead." >&5 10112 $as_echo "$as_me: WARNING: Ignoring value of PRINTF from the environment. Use command line variables instead." >&2;} 10113 fi 10114 # Try to locate tool using the code snippet 10115 for ac_prog in printf 10116 do 10117 # Extract the first word of "$ac_prog", so it can be a program name with args. 10118 set dummy $ac_prog; ac_word=$2 10119 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 10120 $as_echo_n "checking for $ac_word... " >&6; } 10121 if ${ac_cv_path_PRINTF+:} false; then : 10122 $as_echo_n "(cached) " >&6 10123 else 10124 case $PRINTF in 10125 [\\/]* | ?:[\\/]*) 10126 ac_cv_path_PRINTF="$PRINTF" # Let the user override the test with a path. 10127 ;; 10128 *) 10129 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 10130 for as_dir in $PATH 10131 do 10132 IFS=$as_save_IFS 10133 test -z "$as_dir" && as_dir=. 10134 for ac_exec_ext in '' $ac_executable_extensions; do 10135 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 10136 ac_cv_path_PRINTF="$as_dir/$ac_word$ac_exec_ext" 10137 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 10138 break 2 10139 fi 10140 done 10141 done 10142 IFS=$as_save_IFS 10143 10144 ;; 10145 esac 10146 fi 10147 PRINTF=$ac_cv_path_PRINTF 10148 if test -n "$PRINTF"; then 10149 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $PRINTF" >&5 10150 $as_echo "$PRINTF" >&6; } 10151 else 10152 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 10153 $as_echo "no" >&6; } 10154 fi 10155 10156 10157 test -n "$PRINTF" && break 10158 done 10159 10160 else 10161 # If it succeeded, then it was overridden by the user. We will use it 10162 # for the tool. 10163 10164 # First remove it from the list of overridden variables, so we can test 10165 # for unknown variables in the end. 10166 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 10167 10168 # Check if we try to supply an empty value 10169 if test "x$PRINTF" = x; then 10170 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool PRINTF= (no value)" >&5 10171 $as_echo "$as_me: Setting user supplied tool PRINTF= (no value)" >&6;} 10172 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for PRINTF" >&5 10173 $as_echo_n "checking for PRINTF... " >&6; } 10174 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 10175 $as_echo "disabled" >&6; } 10176 else 10177 # Check if the provided tool contains a complete path. 10178 tool_specified="$PRINTF" 10179 tool_basename="${tool_specified##*/}" 10180 if test "x$tool_basename" = "x$tool_specified"; then 10181 # A command without a complete path is provided, search $PATH. 10182 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool PRINTF=$tool_basename" >&5 10183 $as_echo "$as_me: Will search for user supplied tool PRINTF=$tool_basename" >&6;} 10184 # Extract the first word of "$tool_basename", so it can be a program name with args. 10185 set dummy $tool_basename; ac_word=$2 10186 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 10187 $as_echo_n "checking for $ac_word... " >&6; } 10188 if ${ac_cv_path_PRINTF+:} false; then : 10189 $as_echo_n "(cached) " >&6 10190 else 10191 case $PRINTF in 10192 [\\/]* | ?:[\\/]*) 10193 ac_cv_path_PRINTF="$PRINTF" # Let the user override the test with a path. 10194 ;; 10195 *) 10196 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 10197 for as_dir in $PATH 10198 do 10199 IFS=$as_save_IFS 10200 test -z "$as_dir" && as_dir=. 10201 for ac_exec_ext in '' $ac_executable_extensions; do 10202 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 10203 ac_cv_path_PRINTF="$as_dir/$ac_word$ac_exec_ext" 10204 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 10205 break 2 10206 fi 10207 done 10208 done 10209 IFS=$as_save_IFS 10210 10211 ;; 10212 esac 10213 fi 10214 PRINTF=$ac_cv_path_PRINTF 10215 if test -n "$PRINTF"; then 10216 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $PRINTF" >&5 10217 $as_echo "$PRINTF" >&6; } 10218 else 10219 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 10220 $as_echo "no" >&6; } 10221 fi 10222 10223 10224 if test "x$PRINTF" = x; then 10225 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 10226 fi 10227 else 10228 # Otherwise we believe it is a complete path. Use it as it is. 10229 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool PRINTF=$tool_specified" >&5 10230 $as_echo "$as_me: Will use user supplied tool PRINTF=$tool_specified" >&6;} 10231 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for PRINTF" >&5 10232 $as_echo_n "checking for PRINTF... " >&6; } 10233 if test ! -x "$tool_specified"; then 10234 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 10235 $as_echo "not found" >&6; } 10236 as_fn_error $? "User supplied tool PRINTF=$tool_specified does not exist or is not executable" "$LINENO" 5 10237 fi 10238 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 10239 $as_echo "$tool_specified" >&6; } 10240 fi 10241 fi 10242 fi 10243 10244 fi 10245 10246 10247 10248 if test "x$PRINTF" = x; then 10249 as_fn_error $? "Could not find required tool for PRINTF" "$LINENO" 5 10250 fi 10251 10252 10253 10254 10255 10256 # Publish this variable in the help. 10257 10258 10259 if [ -z "${RM+x}" ]; then 10260 # The variable is not set by user, try to locate tool using the code snippet 10261 for ac_prog in rm 10262 do 10263 # Extract the first word of "$ac_prog", so it can be a program name with args. 10264 set dummy $ac_prog; ac_word=$2 10265 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 10266 $as_echo_n "checking for $ac_word... " >&6; } 10267 if ${ac_cv_path_RM+:} false; then : 10268 $as_echo_n "(cached) " >&6 10269 else 10270 case $RM in 10271 [\\/]* | ?:[\\/]*) 10272 ac_cv_path_RM="$RM" # Let the user override the test with a path. 10273 ;; 10274 *) 10275 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 10276 for as_dir in $PATH 10277 do 10278 IFS=$as_save_IFS 10279 test -z "$as_dir" && as_dir=. 10280 for ac_exec_ext in '' $ac_executable_extensions; do 10281 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 10282 ac_cv_path_RM="$as_dir/$ac_word$ac_exec_ext" 10283 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 10284 break 2 10285 fi 10286 done 10287 done 10288 IFS=$as_save_IFS 10289 10290 ;; 10291 esac 10292 fi 10293 RM=$ac_cv_path_RM 10294 if test -n "$RM"; then 10295 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $RM" >&5 10296 $as_echo "$RM" >&6; } 10297 else 10298 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 10299 $as_echo "no" >&6; } 10300 fi 10301 10302 10303 test -n "$RM" && break 10304 done 10305 10306 else 10307 # The variable is set, but is it from the command line or the environment? 10308 10309 # Try to remove the string !RM! from our list. 10310 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!RM!/} 10311 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 10312 # If it failed, the variable was not from the command line. Ignore it, 10313 # but warn the user (except for BASH, which is always set by the calling BASH). 10314 if test "xRM" != xBASH; then 10315 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of RM from the environment. Use command line variables instead." >&5 10316 $as_echo "$as_me: WARNING: Ignoring value of RM from the environment. Use command line variables instead." >&2;} 10317 fi 10318 # Try to locate tool using the code snippet 10319 for ac_prog in rm 10320 do 10321 # Extract the first word of "$ac_prog", so it can be a program name with args. 10322 set dummy $ac_prog; ac_word=$2 10323 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 10324 $as_echo_n "checking for $ac_word... " >&6; } 10325 if ${ac_cv_path_RM+:} false; then : 10326 $as_echo_n "(cached) " >&6 10327 else 10328 case $RM in 10329 [\\/]* | ?:[\\/]*) 10330 ac_cv_path_RM="$RM" # Let the user override the test with a path. 10331 ;; 10332 *) 10333 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 10334 for as_dir in $PATH 10335 do 10336 IFS=$as_save_IFS 10337 test -z "$as_dir" && as_dir=. 10338 for ac_exec_ext in '' $ac_executable_extensions; do 10339 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 10340 ac_cv_path_RM="$as_dir/$ac_word$ac_exec_ext" 10341 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 10342 break 2 10343 fi 10344 done 10345 done 10346 IFS=$as_save_IFS 10347 10348 ;; 10349 esac 10350 fi 10351 RM=$ac_cv_path_RM 10352 if test -n "$RM"; then 10353 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $RM" >&5 10354 $as_echo "$RM" >&6; } 10355 else 10356 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 10357 $as_echo "no" >&6; } 10358 fi 10359 10360 10361 test -n "$RM" && break 10362 done 10363 10364 else 10365 # If it succeeded, then it was overridden by the user. We will use it 10366 # for the tool. 10367 10368 # First remove it from the list of overridden variables, so we can test 10369 # for unknown variables in the end. 10370 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 10371 10372 # Check if we try to supply an empty value 10373 if test "x$RM" = x; then 10374 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool RM= (no value)" >&5 10375 $as_echo "$as_me: Setting user supplied tool RM= (no value)" >&6;} 10376 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for RM" >&5 10377 $as_echo_n "checking for RM... " >&6; } 10378 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 10379 $as_echo "disabled" >&6; } 10380 else 10381 # Check if the provided tool contains a complete path. 10382 tool_specified="$RM" 10383 tool_basename="${tool_specified##*/}" 10384 if test "x$tool_basename" = "x$tool_specified"; then 10385 # A command without a complete path is provided, search $PATH. 10386 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool RM=$tool_basename" >&5 10387 $as_echo "$as_me: Will search for user supplied tool RM=$tool_basename" >&6;} 10388 # Extract the first word of "$tool_basename", so it can be a program name with args. 10389 set dummy $tool_basename; ac_word=$2 10390 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 10391 $as_echo_n "checking for $ac_word... " >&6; } 10392 if ${ac_cv_path_RM+:} false; then : 10393 $as_echo_n "(cached) " >&6 10394 else 10395 case $RM in 10396 [\\/]* | ?:[\\/]*) 10397 ac_cv_path_RM="$RM" # Let the user override the test with a path. 10398 ;; 10399 *) 10400 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 10401 for as_dir in $PATH 10402 do 10403 IFS=$as_save_IFS 10404 test -z "$as_dir" && as_dir=. 10405 for ac_exec_ext in '' $ac_executable_extensions; do 10406 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 10407 ac_cv_path_RM="$as_dir/$ac_word$ac_exec_ext" 10408 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 10409 break 2 10410 fi 10411 done 10412 done 10413 IFS=$as_save_IFS 10414 10415 ;; 10416 esac 10417 fi 10418 RM=$ac_cv_path_RM 10419 if test -n "$RM"; then 10420 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $RM" >&5 10421 $as_echo "$RM" >&6; } 10422 else 10423 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 10424 $as_echo "no" >&6; } 10425 fi 10426 10427 10428 if test "x$RM" = x; then 10429 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 10430 fi 10431 else 10432 # Otherwise we believe it is a complete path. Use it as it is. 10433 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool RM=$tool_specified" >&5 10434 $as_echo "$as_me: Will use user supplied tool RM=$tool_specified" >&6;} 10435 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for RM" >&5 10436 $as_echo_n "checking for RM... " >&6; } 10437 if test ! -x "$tool_specified"; then 10438 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 10439 $as_echo "not found" >&6; } 10440 as_fn_error $? "User supplied tool RM=$tool_specified does not exist or is not executable" "$LINENO" 5 10441 fi 10442 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 10443 $as_echo "$tool_specified" >&6; } 10444 fi 10445 fi 10446 fi 10447 10448 fi 10449 10450 10451 10452 if test "x$RM" = x; then 10453 as_fn_error $? "Could not find required tool for RM" "$LINENO" 5 10454 fi 10455 10456 10457 10458 10459 10460 # Publish this variable in the help. 10461 10462 10463 if [ -z "${RMDIR+x}" ]; then 10464 # The variable is not set by user, try to locate tool using the code snippet 10465 for ac_prog in rmdir 10466 do 10467 # Extract the first word of "$ac_prog", so it can be a program name with args. 10468 set dummy $ac_prog; ac_word=$2 10469 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 10470 $as_echo_n "checking for $ac_word... " >&6; } 10471 if ${ac_cv_path_RMDIR+:} false; then : 10472 $as_echo_n "(cached) " >&6 10473 else 10474 case $RMDIR in 10475 [\\/]* | ?:[\\/]*) 10476 ac_cv_path_RMDIR="$RMDIR" # Let the user override the test with a path. 10477 ;; 10478 *) 10479 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 10480 for as_dir in $PATH 10481 do 10482 IFS=$as_save_IFS 10483 test -z "$as_dir" && as_dir=. 10484 for ac_exec_ext in '' $ac_executable_extensions; do 10485 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 10486 ac_cv_path_RMDIR="$as_dir/$ac_word$ac_exec_ext" 10487 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 10488 break 2 10489 fi 10490 done 10491 done 10492 IFS=$as_save_IFS 10493 10494 ;; 10495 esac 10496 fi 10497 RMDIR=$ac_cv_path_RMDIR 10498 if test -n "$RMDIR"; then 10499 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $RMDIR" >&5 10500 $as_echo "$RMDIR" >&6; } 10501 else 10502 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 10503 $as_echo "no" >&6; } 10504 fi 10505 10506 10507 test -n "$RMDIR" && break 10508 done 10509 10510 else 10511 # The variable is set, but is it from the command line or the environment? 10512 10513 # Try to remove the string !RMDIR! from our list. 10514 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!RMDIR!/} 10515 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 10516 # If it failed, the variable was not from the command line. Ignore it, 10517 # but warn the user (except for BASH, which is always set by the calling BASH). 10518 if test "xRMDIR" != xBASH; then 10519 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of RMDIR from the environment. Use command line variables instead." >&5 10520 $as_echo "$as_me: WARNING: Ignoring value of RMDIR from the environment. Use command line variables instead." >&2;} 10521 fi 10522 # Try to locate tool using the code snippet 10523 for ac_prog in rmdir 10524 do 10525 # Extract the first word of "$ac_prog", so it can be a program name with args. 10526 set dummy $ac_prog; ac_word=$2 10527 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 10528 $as_echo_n "checking for $ac_word... " >&6; } 10529 if ${ac_cv_path_RMDIR+:} false; then : 10530 $as_echo_n "(cached) " >&6 10531 else 10532 case $RMDIR in 10533 [\\/]* | ?:[\\/]*) 10534 ac_cv_path_RMDIR="$RMDIR" # Let the user override the test with a path. 10535 ;; 10536 *) 10537 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 10538 for as_dir in $PATH 10539 do 10540 IFS=$as_save_IFS 10541 test -z "$as_dir" && as_dir=. 10542 for ac_exec_ext in '' $ac_executable_extensions; do 10543 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 10544 ac_cv_path_RMDIR="$as_dir/$ac_word$ac_exec_ext" 10545 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 10546 break 2 10547 fi 10548 done 10549 done 10550 IFS=$as_save_IFS 10551 10552 ;; 10553 esac 10554 fi 10555 RMDIR=$ac_cv_path_RMDIR 10556 if test -n "$RMDIR"; then 10557 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $RMDIR" >&5 10558 $as_echo "$RMDIR" >&6; } 10559 else 10560 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 10561 $as_echo "no" >&6; } 10562 fi 10563 10564 10565 test -n "$RMDIR" && break 10566 done 10567 10568 else 10569 # If it succeeded, then it was overridden by the user. We will use it 10570 # for the tool. 10571 10572 # First remove it from the list of overridden variables, so we can test 10573 # for unknown variables in the end. 10574 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 10575 10576 # Check if we try to supply an empty value 10577 if test "x$RMDIR" = x; then 10578 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool RMDIR= (no value)" >&5 10579 $as_echo "$as_me: Setting user supplied tool RMDIR= (no value)" >&6;} 10580 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for RMDIR" >&5 10581 $as_echo_n "checking for RMDIR... " >&6; } 10582 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 10583 $as_echo "disabled" >&6; } 10584 else 10585 # Check if the provided tool contains a complete path. 10586 tool_specified="$RMDIR" 10587 tool_basename="${tool_specified##*/}" 10588 if test "x$tool_basename" = "x$tool_specified"; then 10589 # A command without a complete path is provided, search $PATH. 10590 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool RMDIR=$tool_basename" >&5 10591 $as_echo "$as_me: Will search for user supplied tool RMDIR=$tool_basename" >&6;} 10592 # Extract the first word of "$tool_basename", so it can be a program name with args. 10593 set dummy $tool_basename; ac_word=$2 10594 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 10595 $as_echo_n "checking for $ac_word... " >&6; } 10596 if ${ac_cv_path_RMDIR+:} false; then : 10597 $as_echo_n "(cached) " >&6 10598 else 10599 case $RMDIR in 10600 [\\/]* | ?:[\\/]*) 10601 ac_cv_path_RMDIR="$RMDIR" # Let the user override the test with a path. 10602 ;; 10603 *) 10604 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 10605 for as_dir in $PATH 10606 do 10607 IFS=$as_save_IFS 10608 test -z "$as_dir" && as_dir=. 10609 for ac_exec_ext in '' $ac_executable_extensions; do 10610 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 10611 ac_cv_path_RMDIR="$as_dir/$ac_word$ac_exec_ext" 10612 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 10613 break 2 10614 fi 10615 done 10616 done 10617 IFS=$as_save_IFS 10618 10619 ;; 10620 esac 10621 fi 10622 RMDIR=$ac_cv_path_RMDIR 10623 if test -n "$RMDIR"; then 10624 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $RMDIR" >&5 10625 $as_echo "$RMDIR" >&6; } 10626 else 10627 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 10628 $as_echo "no" >&6; } 10629 fi 10630 10631 10632 if test "x$RMDIR" = x; then 10633 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 10634 fi 10635 else 10636 # Otherwise we believe it is a complete path. Use it as it is. 10637 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool RMDIR=$tool_specified" >&5 10638 $as_echo "$as_me: Will use user supplied tool RMDIR=$tool_specified" >&6;} 10639 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for RMDIR" >&5 10640 $as_echo_n "checking for RMDIR... " >&6; } 10641 if test ! -x "$tool_specified"; then 10642 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 10643 $as_echo "not found" >&6; } 10644 as_fn_error $? "User supplied tool RMDIR=$tool_specified does not exist or is not executable" "$LINENO" 5 10645 fi 10646 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 10647 $as_echo "$tool_specified" >&6; } 10648 fi 10649 fi 10650 fi 10651 10652 fi 10653 10654 10655 10656 if test "x$RMDIR" = x; then 10657 as_fn_error $? "Could not find required tool for RMDIR" "$LINENO" 5 10658 fi 10659 10660 10661 10662 10663 10664 # Publish this variable in the help. 10665 10666 10667 if [ -z "${SH+x}" ]; then 10668 # The variable is not set by user, try to locate tool using the code snippet 10669 for ac_prog in sh 10670 do 10671 # Extract the first word of "$ac_prog", so it can be a program name with args. 10672 set dummy $ac_prog; ac_word=$2 10673 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 10674 $as_echo_n "checking for $ac_word... " >&6; } 10675 if ${ac_cv_path_SH+:} false; then : 10676 $as_echo_n "(cached) " >&6 10677 else 10678 case $SH in 10679 [\\/]* | ?:[\\/]*) 10680 ac_cv_path_SH="$SH" # Let the user override the test with a path. 10681 ;; 10682 *) 10683 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 10684 for as_dir in $PATH 10685 do 10686 IFS=$as_save_IFS 10687 test -z "$as_dir" && as_dir=. 10688 for ac_exec_ext in '' $ac_executable_extensions; do 10689 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 10690 ac_cv_path_SH="$as_dir/$ac_word$ac_exec_ext" 10691 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 10692 break 2 10693 fi 10694 done 10695 done 10696 IFS=$as_save_IFS 10697 10698 ;; 10699 esac 10700 fi 10701 SH=$ac_cv_path_SH 10702 if test -n "$SH"; then 10703 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $SH" >&5 10704 $as_echo "$SH" >&6; } 10705 else 10706 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 10707 $as_echo "no" >&6; } 10708 fi 10709 10710 10711 test -n "$SH" && break 10712 done 10713 10714 else 10715 # The variable is set, but is it from the command line or the environment? 10716 10717 # Try to remove the string !SH! from our list. 10718 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!SH!/} 10719 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 10720 # If it failed, the variable was not from the command line. Ignore it, 10721 # but warn the user (except for BASH, which is always set by the calling BASH). 10722 if test "xSH" != xBASH; then 10723 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of SH from the environment. Use command line variables instead." >&5 10724 $as_echo "$as_me: WARNING: Ignoring value of SH from the environment. Use command line variables instead." >&2;} 10725 fi 10726 # Try to locate tool using the code snippet 10727 for ac_prog in sh 10728 do 10729 # Extract the first word of "$ac_prog", so it can be a program name with args. 10730 set dummy $ac_prog; ac_word=$2 10731 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 10732 $as_echo_n "checking for $ac_word... " >&6; } 10733 if ${ac_cv_path_SH+:} false; then : 10734 $as_echo_n "(cached) " >&6 10735 else 10736 case $SH in 10737 [\\/]* | ?:[\\/]*) 10738 ac_cv_path_SH="$SH" # Let the user override the test with a path. 10739 ;; 10740 *) 10741 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 10742 for as_dir in $PATH 10743 do 10744 IFS=$as_save_IFS 10745 test -z "$as_dir" && as_dir=. 10746 for ac_exec_ext in '' $ac_executable_extensions; do 10747 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 10748 ac_cv_path_SH="$as_dir/$ac_word$ac_exec_ext" 10749 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 10750 break 2 10751 fi 10752 done 10753 done 10754 IFS=$as_save_IFS 10755 10756 ;; 10757 esac 10758 fi 10759 SH=$ac_cv_path_SH 10760 if test -n "$SH"; then 10761 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $SH" >&5 10762 $as_echo "$SH" >&6; } 10763 else 10764 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 10765 $as_echo "no" >&6; } 10766 fi 10767 10768 10769 test -n "$SH" && break 10770 done 10771 10772 else 10773 # If it succeeded, then it was overridden by the user. We will use it 10774 # for the tool. 10775 10776 # First remove it from the list of overridden variables, so we can test 10777 # for unknown variables in the end. 10778 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 10779 10780 # Check if we try to supply an empty value 10781 if test "x$SH" = x; then 10782 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool SH= (no value)" >&5 10783 $as_echo "$as_me: Setting user supplied tool SH= (no value)" >&6;} 10784 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for SH" >&5 10785 $as_echo_n "checking for SH... " >&6; } 10786 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 10787 $as_echo "disabled" >&6; } 10788 else 10789 # Check if the provided tool contains a complete path. 10790 tool_specified="$SH" 10791 tool_basename="${tool_specified##*/}" 10792 if test "x$tool_basename" = "x$tool_specified"; then 10793 # A command without a complete path is provided, search $PATH. 10794 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool SH=$tool_basename" >&5 10795 $as_echo "$as_me: Will search for user supplied tool SH=$tool_basename" >&6;} 10796 # Extract the first word of "$tool_basename", so it can be a program name with args. 10797 set dummy $tool_basename; ac_word=$2 10798 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 10799 $as_echo_n "checking for $ac_word... " >&6; } 10800 if ${ac_cv_path_SH+:} false; then : 10801 $as_echo_n "(cached) " >&6 10802 else 10803 case $SH in 10804 [\\/]* | ?:[\\/]*) 10805 ac_cv_path_SH="$SH" # Let the user override the test with a path. 10806 ;; 10807 *) 10808 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 10809 for as_dir in $PATH 10810 do 10811 IFS=$as_save_IFS 10812 test -z "$as_dir" && as_dir=. 10813 for ac_exec_ext in '' $ac_executable_extensions; do 10814 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 10815 ac_cv_path_SH="$as_dir/$ac_word$ac_exec_ext" 10816 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 10817 break 2 10818 fi 10819 done 10820 done 10821 IFS=$as_save_IFS 10822 10823 ;; 10824 esac 10825 fi 10826 SH=$ac_cv_path_SH 10827 if test -n "$SH"; then 10828 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $SH" >&5 10829 $as_echo "$SH" >&6; } 10830 else 10831 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 10832 $as_echo "no" >&6; } 10833 fi 10834 10835 10836 if test "x$SH" = x; then 10837 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 10838 fi 10839 else 10840 # Otherwise we believe it is a complete path. Use it as it is. 10841 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool SH=$tool_specified" >&5 10842 $as_echo "$as_me: Will use user supplied tool SH=$tool_specified" >&6;} 10843 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for SH" >&5 10844 $as_echo_n "checking for SH... " >&6; } 10845 if test ! -x "$tool_specified"; then 10846 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 10847 $as_echo "not found" >&6; } 10848 as_fn_error $? "User supplied tool SH=$tool_specified does not exist or is not executable" "$LINENO" 5 10849 fi 10850 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 10851 $as_echo "$tool_specified" >&6; } 10852 fi 10853 fi 10854 fi 10855 10856 fi 10857 10858 10859 10860 if test "x$SH" = x; then 10861 as_fn_error $? "Could not find required tool for SH" "$LINENO" 5 10862 fi 10863 10864 10865 10866 10867 10868 # Publish this variable in the help. 10869 10870 10871 if [ -z "${SORT+x}" ]; then 10872 # The variable is not set by user, try to locate tool using the code snippet 10873 for ac_prog in sort 10874 do 10875 # Extract the first word of "$ac_prog", so it can be a program name with args. 10876 set dummy $ac_prog; ac_word=$2 10877 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 10878 $as_echo_n "checking for $ac_word... " >&6; } 10879 if ${ac_cv_path_SORT+:} false; then : 10880 $as_echo_n "(cached) " >&6 10881 else 10882 case $SORT in 10883 [\\/]* | ?:[\\/]*) 10884 ac_cv_path_SORT="$SORT" # Let the user override the test with a path. 10885 ;; 10886 *) 10887 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 10888 for as_dir in $PATH 10889 do 10890 IFS=$as_save_IFS 10891 test -z "$as_dir" && as_dir=. 10892 for ac_exec_ext in '' $ac_executable_extensions; do 10893 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 10894 ac_cv_path_SORT="$as_dir/$ac_word$ac_exec_ext" 10895 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 10896 break 2 10897 fi 10898 done 10899 done 10900 IFS=$as_save_IFS 10901 10902 ;; 10903 esac 10904 fi 10905 SORT=$ac_cv_path_SORT 10906 if test -n "$SORT"; then 10907 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $SORT" >&5 10908 $as_echo "$SORT" >&6; } 10909 else 10910 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 10911 $as_echo "no" >&6; } 10912 fi 10913 10914 10915 test -n "$SORT" && break 10916 done 10917 10918 else 10919 # The variable is set, but is it from the command line or the environment? 10920 10921 # Try to remove the string !SORT! from our list. 10922 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!SORT!/} 10923 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 10924 # If it failed, the variable was not from the command line. Ignore it, 10925 # but warn the user (except for BASH, which is always set by the calling BASH). 10926 if test "xSORT" != xBASH; then 10927 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of SORT from the environment. Use command line variables instead." >&5 10928 $as_echo "$as_me: WARNING: Ignoring value of SORT from the environment. Use command line variables instead." >&2;} 10929 fi 10930 # Try to locate tool using the code snippet 10931 for ac_prog in sort 10932 do 10933 # Extract the first word of "$ac_prog", so it can be a program name with args. 10934 set dummy $ac_prog; ac_word=$2 10935 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 10936 $as_echo_n "checking for $ac_word... " >&6; } 10937 if ${ac_cv_path_SORT+:} false; then : 10938 $as_echo_n "(cached) " >&6 10939 else 10940 case $SORT in 10941 [\\/]* | ?:[\\/]*) 10942 ac_cv_path_SORT="$SORT" # Let the user override the test with a path. 10943 ;; 10944 *) 10945 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 10946 for as_dir in $PATH 10947 do 10948 IFS=$as_save_IFS 10949 test -z "$as_dir" && as_dir=. 10950 for ac_exec_ext in '' $ac_executable_extensions; do 10951 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 10952 ac_cv_path_SORT="$as_dir/$ac_word$ac_exec_ext" 10953 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 10954 break 2 10955 fi 10956 done 10957 done 10958 IFS=$as_save_IFS 10959 10960 ;; 10961 esac 10962 fi 10963 SORT=$ac_cv_path_SORT 10964 if test -n "$SORT"; then 10965 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $SORT" >&5 10966 $as_echo "$SORT" >&6; } 10967 else 10968 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 10969 $as_echo "no" >&6; } 10970 fi 10971 10972 10973 test -n "$SORT" && break 10974 done 10975 10976 else 10977 # If it succeeded, then it was overridden by the user. We will use it 10978 # for the tool. 10979 10980 # First remove it from the list of overridden variables, so we can test 10981 # for unknown variables in the end. 10982 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 10983 10984 # Check if we try to supply an empty value 10985 if test "x$SORT" = x; then 10986 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool SORT= (no value)" >&5 10987 $as_echo "$as_me: Setting user supplied tool SORT= (no value)" >&6;} 10988 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for SORT" >&5 10989 $as_echo_n "checking for SORT... " >&6; } 10990 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 10991 $as_echo "disabled" >&6; } 10992 else 10993 # Check if the provided tool contains a complete path. 10994 tool_specified="$SORT" 10995 tool_basename="${tool_specified##*/}" 10996 if test "x$tool_basename" = "x$tool_specified"; then 10997 # A command without a complete path is provided, search $PATH. 10998 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool SORT=$tool_basename" >&5 10999 $as_echo "$as_me: Will search for user supplied tool SORT=$tool_basename" >&6;} 11000 # Extract the first word of "$tool_basename", so it can be a program name with args. 11001 set dummy $tool_basename; ac_word=$2 11002 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 11003 $as_echo_n "checking for $ac_word... " >&6; } 11004 if ${ac_cv_path_SORT+:} false; then : 11005 $as_echo_n "(cached) " >&6 11006 else 11007 case $SORT in 11008 [\\/]* | ?:[\\/]*) 11009 ac_cv_path_SORT="$SORT" # Let the user override the test with a path. 11010 ;; 11011 *) 11012 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 11013 for as_dir in $PATH 11014 do 11015 IFS=$as_save_IFS 11016 test -z "$as_dir" && as_dir=. 11017 for ac_exec_ext in '' $ac_executable_extensions; do 11018 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 11019 ac_cv_path_SORT="$as_dir/$ac_word$ac_exec_ext" 11020 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 11021 break 2 11022 fi 11023 done 11024 done 11025 IFS=$as_save_IFS 11026 11027 ;; 11028 esac 11029 fi 11030 SORT=$ac_cv_path_SORT 11031 if test -n "$SORT"; then 11032 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $SORT" >&5 11033 $as_echo "$SORT" >&6; } 11034 else 11035 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 11036 $as_echo "no" >&6; } 11037 fi 11038 11039 11040 if test "x$SORT" = x; then 11041 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 11042 fi 11043 else 11044 # Otherwise we believe it is a complete path. Use it as it is. 11045 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool SORT=$tool_specified" >&5 11046 $as_echo "$as_me: Will use user supplied tool SORT=$tool_specified" >&6;} 11047 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for SORT" >&5 11048 $as_echo_n "checking for SORT... " >&6; } 11049 if test ! -x "$tool_specified"; then 11050 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 11051 $as_echo "not found" >&6; } 11052 as_fn_error $? "User supplied tool SORT=$tool_specified does not exist or is not executable" "$LINENO" 5 11053 fi 11054 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 11055 $as_echo "$tool_specified" >&6; } 11056 fi 11057 fi 11058 fi 11059 11060 fi 11061 11062 11063 11064 if test "x$SORT" = x; then 11065 as_fn_error $? "Could not find required tool for SORT" "$LINENO" 5 11066 fi 11067 11068 11069 11070 11071 11072 # Publish this variable in the help. 11073 11074 11075 if [ -z "${TAIL+x}" ]; then 11076 # The variable is not set by user, try to locate tool using the code snippet 11077 for ac_prog in tail 11078 do 11079 # Extract the first word of "$ac_prog", so it can be a program name with args. 11080 set dummy $ac_prog; ac_word=$2 11081 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 11082 $as_echo_n "checking for $ac_word... " >&6; } 11083 if ${ac_cv_path_TAIL+:} false; then : 11084 $as_echo_n "(cached) " >&6 11085 else 11086 case $TAIL in 11087 [\\/]* | ?:[\\/]*) 11088 ac_cv_path_TAIL="$TAIL" # Let the user override the test with a path. 11089 ;; 11090 *) 11091 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 11092 for as_dir in $PATH 11093 do 11094 IFS=$as_save_IFS 11095 test -z "$as_dir" && as_dir=. 11096 for ac_exec_ext in '' $ac_executable_extensions; do 11097 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 11098 ac_cv_path_TAIL="$as_dir/$ac_word$ac_exec_ext" 11099 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 11100 break 2 11101 fi 11102 done 11103 done 11104 IFS=$as_save_IFS 11105 11106 ;; 11107 esac 11108 fi 11109 TAIL=$ac_cv_path_TAIL 11110 if test -n "$TAIL"; then 11111 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $TAIL" >&5 11112 $as_echo "$TAIL" >&6; } 11113 else 11114 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 11115 $as_echo "no" >&6; } 11116 fi 11117 11118 11119 test -n "$TAIL" && break 11120 done 11121 11122 else 11123 # The variable is set, but is it from the command line or the environment? 11124 11125 # Try to remove the string !TAIL! from our list. 11126 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!TAIL!/} 11127 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 11128 # If it failed, the variable was not from the command line. Ignore it, 11129 # but warn the user (except for BASH, which is always set by the calling BASH). 11130 if test "xTAIL" != xBASH; then 11131 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of TAIL from the environment. Use command line variables instead." >&5 11132 $as_echo "$as_me: WARNING: Ignoring value of TAIL from the environment. Use command line variables instead." >&2;} 11133 fi 11134 # Try to locate tool using the code snippet 11135 for ac_prog in tail 11136 do 11137 # Extract the first word of "$ac_prog", so it can be a program name with args. 11138 set dummy $ac_prog; ac_word=$2 11139 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 11140 $as_echo_n "checking for $ac_word... " >&6; } 11141 if ${ac_cv_path_TAIL+:} false; then : 11142 $as_echo_n "(cached) " >&6 11143 else 11144 case $TAIL in 11145 [\\/]* | ?:[\\/]*) 11146 ac_cv_path_TAIL="$TAIL" # Let the user override the test with a path. 11147 ;; 11148 *) 11149 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 11150 for as_dir in $PATH 11151 do 11152 IFS=$as_save_IFS 11153 test -z "$as_dir" && as_dir=. 11154 for ac_exec_ext in '' $ac_executable_extensions; do 11155 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 11156 ac_cv_path_TAIL="$as_dir/$ac_word$ac_exec_ext" 11157 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 11158 break 2 11159 fi 11160 done 11161 done 11162 IFS=$as_save_IFS 11163 11164 ;; 11165 esac 11166 fi 11167 TAIL=$ac_cv_path_TAIL 11168 if test -n "$TAIL"; then 11169 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $TAIL" >&5 11170 $as_echo "$TAIL" >&6; } 11171 else 11172 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 11173 $as_echo "no" >&6; } 11174 fi 11175 11176 11177 test -n "$TAIL" && break 11178 done 11179 11180 else 11181 # If it succeeded, then it was overridden by the user. We will use it 11182 # for the tool. 11183 11184 # First remove it from the list of overridden variables, so we can test 11185 # for unknown variables in the end. 11186 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 11187 11188 # Check if we try to supply an empty value 11189 if test "x$TAIL" = x; then 11190 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool TAIL= (no value)" >&5 11191 $as_echo "$as_me: Setting user supplied tool TAIL= (no value)" >&6;} 11192 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for TAIL" >&5 11193 $as_echo_n "checking for TAIL... " >&6; } 11194 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 11195 $as_echo "disabled" >&6; } 11196 else 11197 # Check if the provided tool contains a complete path. 11198 tool_specified="$TAIL" 11199 tool_basename="${tool_specified##*/}" 11200 if test "x$tool_basename" = "x$tool_specified"; then 11201 # A command without a complete path is provided, search $PATH. 11202 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool TAIL=$tool_basename" >&5 11203 $as_echo "$as_me: Will search for user supplied tool TAIL=$tool_basename" >&6;} 11204 # Extract the first word of "$tool_basename", so it can be a program name with args. 11205 set dummy $tool_basename; ac_word=$2 11206 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 11207 $as_echo_n "checking for $ac_word... " >&6; } 11208 if ${ac_cv_path_TAIL+:} false; then : 11209 $as_echo_n "(cached) " >&6 11210 else 11211 case $TAIL in 11212 [\\/]* | ?:[\\/]*) 11213 ac_cv_path_TAIL="$TAIL" # Let the user override the test with a path. 11214 ;; 11215 *) 11216 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 11217 for as_dir in $PATH 11218 do 11219 IFS=$as_save_IFS 11220 test -z "$as_dir" && as_dir=. 11221 for ac_exec_ext in '' $ac_executable_extensions; do 11222 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 11223 ac_cv_path_TAIL="$as_dir/$ac_word$ac_exec_ext" 11224 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 11225 break 2 11226 fi 11227 done 11228 done 11229 IFS=$as_save_IFS 11230 11231 ;; 11232 esac 11233 fi 11234 TAIL=$ac_cv_path_TAIL 11235 if test -n "$TAIL"; then 11236 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $TAIL" >&5 11237 $as_echo "$TAIL" >&6; } 11238 else 11239 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 11240 $as_echo "no" >&6; } 11241 fi 11242 11243 11244 if test "x$TAIL" = x; then 11245 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 11246 fi 11247 else 11248 # Otherwise we believe it is a complete path. Use it as it is. 11249 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool TAIL=$tool_specified" >&5 11250 $as_echo "$as_me: Will use user supplied tool TAIL=$tool_specified" >&6;} 11251 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for TAIL" >&5 11252 $as_echo_n "checking for TAIL... " >&6; } 11253 if test ! -x "$tool_specified"; then 11254 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 11255 $as_echo "not found" >&6; } 11256 as_fn_error $? "User supplied tool TAIL=$tool_specified does not exist or is not executable" "$LINENO" 5 11257 fi 11258 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 11259 $as_echo "$tool_specified" >&6; } 11260 fi 11261 fi 11262 fi 11263 11264 fi 11265 11266 11267 11268 if test "x$TAIL" = x; then 11269 as_fn_error $? "Could not find required tool for TAIL" "$LINENO" 5 11270 fi 11271 11272 11273 11274 11275 11276 # Publish this variable in the help. 11277 11278 11279 if [ -z "${TAR+x}" ]; then 11280 # The variable is not set by user, try to locate tool using the code snippet 11281 for ac_prog in gtar tar 11282 do 11283 # Extract the first word of "$ac_prog", so it can be a program name with args. 11284 set dummy $ac_prog; ac_word=$2 11285 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 11286 $as_echo_n "checking for $ac_word... " >&6; } 11287 if ${ac_cv_path_TAR+:} false; then : 11288 $as_echo_n "(cached) " >&6 11289 else 11290 case $TAR in 11291 [\\/]* | ?:[\\/]*) 11292 ac_cv_path_TAR="$TAR" # Let the user override the test with a path. 11293 ;; 11294 *) 11295 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 11296 for as_dir in $PATH 11297 do 11298 IFS=$as_save_IFS 11299 test -z "$as_dir" && as_dir=. 11300 for ac_exec_ext in '' $ac_executable_extensions; do 11301 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 11302 ac_cv_path_TAR="$as_dir/$ac_word$ac_exec_ext" 11303 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 11304 break 2 11305 fi 11306 done 11307 done 11308 IFS=$as_save_IFS 11309 11310 ;; 11311 esac 11312 fi 11313 TAR=$ac_cv_path_TAR 11314 if test -n "$TAR"; then 11315 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $TAR" >&5 11316 $as_echo "$TAR" >&6; } 11317 else 11318 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 11319 $as_echo "no" >&6; } 11320 fi 11321 11322 11323 test -n "$TAR" && break 11324 done 11325 11326 else 11327 # The variable is set, but is it from the command line or the environment? 11328 11329 # Try to remove the string !TAR! from our list. 11330 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!TAR!/} 11331 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 11332 # If it failed, the variable was not from the command line. Ignore it, 11333 # but warn the user (except for BASH, which is always set by the calling BASH). 11334 if test "xTAR" != xBASH; then 11335 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of TAR from the environment. Use command line variables instead." >&5 11336 $as_echo "$as_me: WARNING: Ignoring value of TAR from the environment. Use command line variables instead." >&2;} 11337 fi 11338 # Try to locate tool using the code snippet 11339 for ac_prog in gtar tar 11340 do 11341 # Extract the first word of "$ac_prog", so it can be a program name with args. 11342 set dummy $ac_prog; ac_word=$2 11343 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 11344 $as_echo_n "checking for $ac_word... " >&6; } 11345 if ${ac_cv_path_TAR+:} false; then : 11346 $as_echo_n "(cached) " >&6 11347 else 11348 case $TAR in 11349 [\\/]* | ?:[\\/]*) 11350 ac_cv_path_TAR="$TAR" # Let the user override the test with a path. 11351 ;; 11352 *) 11353 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 11354 for as_dir in $PATH 11355 do 11356 IFS=$as_save_IFS 11357 test -z "$as_dir" && as_dir=. 11358 for ac_exec_ext in '' $ac_executable_extensions; do 11359 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 11360 ac_cv_path_TAR="$as_dir/$ac_word$ac_exec_ext" 11361 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 11362 break 2 11363 fi 11364 done 11365 done 11366 IFS=$as_save_IFS 11367 11368 ;; 11369 esac 11370 fi 11371 TAR=$ac_cv_path_TAR 11372 if test -n "$TAR"; then 11373 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $TAR" >&5 11374 $as_echo "$TAR" >&6; } 11375 else 11376 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 11377 $as_echo "no" >&6; } 11378 fi 11379 11380 11381 test -n "$TAR" && break 11382 done 11383 11384 else 11385 # If it succeeded, then it was overridden by the user. We will use it 11386 # for the tool. 11387 11388 # First remove it from the list of overridden variables, so we can test 11389 # for unknown variables in the end. 11390 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 11391 11392 # Check if we try to supply an empty value 11393 if test "x$TAR" = x; then 11394 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool TAR= (no value)" >&5 11395 $as_echo "$as_me: Setting user supplied tool TAR= (no value)" >&6;} 11396 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for TAR" >&5 11397 $as_echo_n "checking for TAR... " >&6; } 11398 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 11399 $as_echo "disabled" >&6; } 11400 else 11401 # Check if the provided tool contains a complete path. 11402 tool_specified="$TAR" 11403 tool_basename="${tool_specified##*/}" 11404 if test "x$tool_basename" = "x$tool_specified"; then 11405 # A command without a complete path is provided, search $PATH. 11406 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool TAR=$tool_basename" >&5 11407 $as_echo "$as_me: Will search for user supplied tool TAR=$tool_basename" >&6;} 11408 # Extract the first word of "$tool_basename", so it can be a program name with args. 11409 set dummy $tool_basename; ac_word=$2 11410 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 11411 $as_echo_n "checking for $ac_word... " >&6; } 11412 if ${ac_cv_path_TAR+:} false; then : 11413 $as_echo_n "(cached) " >&6 11414 else 11415 case $TAR in 11416 [\\/]* | ?:[\\/]*) 11417 ac_cv_path_TAR="$TAR" # Let the user override the test with a path. 11418 ;; 11419 *) 11420 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 11421 for as_dir in $PATH 11422 do 11423 IFS=$as_save_IFS 11424 test -z "$as_dir" && as_dir=. 11425 for ac_exec_ext in '' $ac_executable_extensions; do 11426 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 11427 ac_cv_path_TAR="$as_dir/$ac_word$ac_exec_ext" 11428 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 11429 break 2 11430 fi 11431 done 11432 done 11433 IFS=$as_save_IFS 11434 11435 ;; 11436 esac 11437 fi 11438 TAR=$ac_cv_path_TAR 11439 if test -n "$TAR"; then 11440 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $TAR" >&5 11441 $as_echo "$TAR" >&6; } 11442 else 11443 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 11444 $as_echo "no" >&6; } 11445 fi 11446 11447 11448 if test "x$TAR" = x; then 11449 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 11450 fi 11451 else 11452 # Otherwise we believe it is a complete path. Use it as it is. 11453 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool TAR=$tool_specified" >&5 11454 $as_echo "$as_me: Will use user supplied tool TAR=$tool_specified" >&6;} 11455 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for TAR" >&5 11456 $as_echo_n "checking for TAR... " >&6; } 11457 if test ! -x "$tool_specified"; then 11458 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 11459 $as_echo "not found" >&6; } 11460 as_fn_error $? "User supplied tool TAR=$tool_specified does not exist or is not executable" "$LINENO" 5 11461 fi 11462 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 11463 $as_echo "$tool_specified" >&6; } 11464 fi 11465 fi 11466 fi 11467 11468 fi 11469 11470 11471 11472 if test "x$TAR" = x; then 11473 as_fn_error $? "Could not find required tool for TAR" "$LINENO" 5 11474 fi 11475 11476 11477 11478 11479 11480 # Publish this variable in the help. 11481 11482 11483 if [ -z "${TEE+x}" ]; then 11484 # The variable is not set by user, try to locate tool using the code snippet 11485 for ac_prog in tee 11486 do 11487 # Extract the first word of "$ac_prog", so it can be a program name with args. 11488 set dummy $ac_prog; ac_word=$2 11489 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 11490 $as_echo_n "checking for $ac_word... " >&6; } 11491 if ${ac_cv_path_TEE+:} false; then : 11492 $as_echo_n "(cached) " >&6 11493 else 11494 case $TEE in 11495 [\\/]* | ?:[\\/]*) 11496 ac_cv_path_TEE="$TEE" # Let the user override the test with a path. 11497 ;; 11498 *) 11499 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 11500 for as_dir in $PATH 11501 do 11502 IFS=$as_save_IFS 11503 test -z "$as_dir" && as_dir=. 11504 for ac_exec_ext in '' $ac_executable_extensions; do 11505 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 11506 ac_cv_path_TEE="$as_dir/$ac_word$ac_exec_ext" 11507 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 11508 break 2 11509 fi 11510 done 11511 done 11512 IFS=$as_save_IFS 11513 11514 ;; 11515 esac 11516 fi 11517 TEE=$ac_cv_path_TEE 11518 if test -n "$TEE"; then 11519 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $TEE" >&5 11520 $as_echo "$TEE" >&6; } 11521 else 11522 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 11523 $as_echo "no" >&6; } 11524 fi 11525 11526 11527 test -n "$TEE" && break 11528 done 11529 11530 else 11531 # The variable is set, but is it from the command line or the environment? 11532 11533 # Try to remove the string !TEE! from our list. 11534 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!TEE!/} 11535 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 11536 # If it failed, the variable was not from the command line. Ignore it, 11537 # but warn the user (except for BASH, which is always set by the calling BASH). 11538 if test "xTEE" != xBASH; then 11539 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of TEE from the environment. Use command line variables instead." >&5 11540 $as_echo "$as_me: WARNING: Ignoring value of TEE from the environment. Use command line variables instead." >&2;} 11541 fi 11542 # Try to locate tool using the code snippet 11543 for ac_prog in tee 11544 do 11545 # Extract the first word of "$ac_prog", so it can be a program name with args. 11546 set dummy $ac_prog; ac_word=$2 11547 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 11548 $as_echo_n "checking for $ac_word... " >&6; } 11549 if ${ac_cv_path_TEE+:} false; then : 11550 $as_echo_n "(cached) " >&6 11551 else 11552 case $TEE in 11553 [\\/]* | ?:[\\/]*) 11554 ac_cv_path_TEE="$TEE" # Let the user override the test with a path. 11555 ;; 11556 *) 11557 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 11558 for as_dir in $PATH 11559 do 11560 IFS=$as_save_IFS 11561 test -z "$as_dir" && as_dir=. 11562 for ac_exec_ext in '' $ac_executable_extensions; do 11563 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 11564 ac_cv_path_TEE="$as_dir/$ac_word$ac_exec_ext" 11565 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 11566 break 2 11567 fi 11568 done 11569 done 11570 IFS=$as_save_IFS 11571 11572 ;; 11573 esac 11574 fi 11575 TEE=$ac_cv_path_TEE 11576 if test -n "$TEE"; then 11577 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $TEE" >&5 11578 $as_echo "$TEE" >&6; } 11579 else 11580 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 11581 $as_echo "no" >&6; } 11582 fi 11583 11584 11585 test -n "$TEE" && break 11586 done 11587 11588 else 11589 # If it succeeded, then it was overridden by the user. We will use it 11590 # for the tool. 11591 11592 # First remove it from the list of overridden variables, so we can test 11593 # for unknown variables in the end. 11594 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 11595 11596 # Check if we try to supply an empty value 11597 if test "x$TEE" = x; then 11598 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool TEE= (no value)" >&5 11599 $as_echo "$as_me: Setting user supplied tool TEE= (no value)" >&6;} 11600 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for TEE" >&5 11601 $as_echo_n "checking for TEE... " >&6; } 11602 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 11603 $as_echo "disabled" >&6; } 11604 else 11605 # Check if the provided tool contains a complete path. 11606 tool_specified="$TEE" 11607 tool_basename="${tool_specified##*/}" 11608 if test "x$tool_basename" = "x$tool_specified"; then 11609 # A command without a complete path is provided, search $PATH. 11610 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool TEE=$tool_basename" >&5 11611 $as_echo "$as_me: Will search for user supplied tool TEE=$tool_basename" >&6;} 11612 # Extract the first word of "$tool_basename", so it can be a program name with args. 11613 set dummy $tool_basename; ac_word=$2 11614 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 11615 $as_echo_n "checking for $ac_word... " >&6; } 11616 if ${ac_cv_path_TEE+:} false; then : 11617 $as_echo_n "(cached) " >&6 11618 else 11619 case $TEE in 11620 [\\/]* | ?:[\\/]*) 11621 ac_cv_path_TEE="$TEE" # Let the user override the test with a path. 11622 ;; 11623 *) 11624 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 11625 for as_dir in $PATH 11626 do 11627 IFS=$as_save_IFS 11628 test -z "$as_dir" && as_dir=. 11629 for ac_exec_ext in '' $ac_executable_extensions; do 11630 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 11631 ac_cv_path_TEE="$as_dir/$ac_word$ac_exec_ext" 11632 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 11633 break 2 11634 fi 11635 done 11636 done 11637 IFS=$as_save_IFS 11638 11639 ;; 11640 esac 11641 fi 11642 TEE=$ac_cv_path_TEE 11643 if test -n "$TEE"; then 11644 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $TEE" >&5 11645 $as_echo "$TEE" >&6; } 11646 else 11647 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 11648 $as_echo "no" >&6; } 11649 fi 11650 11651 11652 if test "x$TEE" = x; then 11653 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 11654 fi 11655 else 11656 # Otherwise we believe it is a complete path. Use it as it is. 11657 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool TEE=$tool_specified" >&5 11658 $as_echo "$as_me: Will use user supplied tool TEE=$tool_specified" >&6;} 11659 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for TEE" >&5 11660 $as_echo_n "checking for TEE... " >&6; } 11661 if test ! -x "$tool_specified"; then 11662 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 11663 $as_echo "not found" >&6; } 11664 as_fn_error $? "User supplied tool TEE=$tool_specified does not exist or is not executable" "$LINENO" 5 11665 fi 11666 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 11667 $as_echo "$tool_specified" >&6; } 11668 fi 11669 fi 11670 fi 11671 11672 fi 11673 11674 11675 11676 if test "x$TEE" = x; then 11677 as_fn_error $? "Could not find required tool for TEE" "$LINENO" 5 11678 fi 11679 11680 11681 11682 11683 11684 # Publish this variable in the help. 11685 11686 11687 if [ -z "${TOUCH+x}" ]; then 11688 # The variable is not set by user, try to locate tool using the code snippet 11689 for ac_prog in touch 11690 do 11691 # Extract the first word of "$ac_prog", so it can be a program name with args. 11692 set dummy $ac_prog; ac_word=$2 11693 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 11694 $as_echo_n "checking for $ac_word... " >&6; } 11695 if ${ac_cv_path_TOUCH+:} false; then : 11696 $as_echo_n "(cached) " >&6 11697 else 11698 case $TOUCH in 11699 [\\/]* | ?:[\\/]*) 11700 ac_cv_path_TOUCH="$TOUCH" # Let the user override the test with a path. 11701 ;; 11702 *) 11703 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 11704 for as_dir in $PATH 11705 do 11706 IFS=$as_save_IFS 11707 test -z "$as_dir" && as_dir=. 11708 for ac_exec_ext in '' $ac_executable_extensions; do 11709 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 11710 ac_cv_path_TOUCH="$as_dir/$ac_word$ac_exec_ext" 11711 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 11712 break 2 11713 fi 11714 done 11715 done 11716 IFS=$as_save_IFS 11717 11718 ;; 11719 esac 11720 fi 11721 TOUCH=$ac_cv_path_TOUCH 11722 if test -n "$TOUCH"; then 11723 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $TOUCH" >&5 11724 $as_echo "$TOUCH" >&6; } 11725 else 11726 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 11727 $as_echo "no" >&6; } 11728 fi 11729 11730 11731 test -n "$TOUCH" && break 11732 done 11733 11734 else 11735 # The variable is set, but is it from the command line or the environment? 11736 11737 # Try to remove the string !TOUCH! from our list. 11738 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!TOUCH!/} 11739 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 11740 # If it failed, the variable was not from the command line. Ignore it, 11741 # but warn the user (except for BASH, which is always set by the calling BASH). 11742 if test "xTOUCH" != xBASH; then 11743 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of TOUCH from the environment. Use command line variables instead." >&5 11744 $as_echo "$as_me: WARNING: Ignoring value of TOUCH from the environment. Use command line variables instead." >&2;} 11745 fi 11746 # Try to locate tool using the code snippet 11747 for ac_prog in touch 11748 do 11749 # Extract the first word of "$ac_prog", so it can be a program name with args. 11750 set dummy $ac_prog; ac_word=$2 11751 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 11752 $as_echo_n "checking for $ac_word... " >&6; } 11753 if ${ac_cv_path_TOUCH+:} false; then : 11754 $as_echo_n "(cached) " >&6 11755 else 11756 case $TOUCH in 11757 [\\/]* | ?:[\\/]*) 11758 ac_cv_path_TOUCH="$TOUCH" # Let the user override the test with a path. 11759 ;; 11760 *) 11761 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 11762 for as_dir in $PATH 11763 do 11764 IFS=$as_save_IFS 11765 test -z "$as_dir" && as_dir=. 11766 for ac_exec_ext in '' $ac_executable_extensions; do 11767 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 11768 ac_cv_path_TOUCH="$as_dir/$ac_word$ac_exec_ext" 11769 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 11770 break 2 11771 fi 11772 done 11773 done 11774 IFS=$as_save_IFS 11775 11776 ;; 11777 esac 11778 fi 11779 TOUCH=$ac_cv_path_TOUCH 11780 if test -n "$TOUCH"; then 11781 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $TOUCH" >&5 11782 $as_echo "$TOUCH" >&6; } 11783 else 11784 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 11785 $as_echo "no" >&6; } 11786 fi 11787 11788 11789 test -n "$TOUCH" && break 11790 done 11791 11792 else 11793 # If it succeeded, then it was overridden by the user. We will use it 11794 # for the tool. 11795 11796 # First remove it from the list of overridden variables, so we can test 11797 # for unknown variables in the end. 11798 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 11799 11800 # Check if we try to supply an empty value 11801 if test "x$TOUCH" = x; then 11802 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool TOUCH= (no value)" >&5 11803 $as_echo "$as_me: Setting user supplied tool TOUCH= (no value)" >&6;} 11804 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for TOUCH" >&5 11805 $as_echo_n "checking for TOUCH... " >&6; } 11806 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 11807 $as_echo "disabled" >&6; } 11808 else 11809 # Check if the provided tool contains a complete path. 11810 tool_specified="$TOUCH" 11811 tool_basename="${tool_specified##*/}" 11812 if test "x$tool_basename" = "x$tool_specified"; then 11813 # A command without a complete path is provided, search $PATH. 11814 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool TOUCH=$tool_basename" >&5 11815 $as_echo "$as_me: Will search for user supplied tool TOUCH=$tool_basename" >&6;} 11816 # Extract the first word of "$tool_basename", so it can be a program name with args. 11817 set dummy $tool_basename; ac_word=$2 11818 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 11819 $as_echo_n "checking for $ac_word... " >&6; } 11820 if ${ac_cv_path_TOUCH+:} false; then : 11821 $as_echo_n "(cached) " >&6 11822 else 11823 case $TOUCH in 11824 [\\/]* | ?:[\\/]*) 11825 ac_cv_path_TOUCH="$TOUCH" # Let the user override the test with a path. 11826 ;; 11827 *) 11828 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 11829 for as_dir in $PATH 11830 do 11831 IFS=$as_save_IFS 11832 test -z "$as_dir" && as_dir=. 11833 for ac_exec_ext in '' $ac_executable_extensions; do 11834 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 11835 ac_cv_path_TOUCH="$as_dir/$ac_word$ac_exec_ext" 11836 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 11837 break 2 11838 fi 11839 done 11840 done 11841 IFS=$as_save_IFS 11842 11843 ;; 11844 esac 11845 fi 11846 TOUCH=$ac_cv_path_TOUCH 11847 if test -n "$TOUCH"; then 11848 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $TOUCH" >&5 11849 $as_echo "$TOUCH" >&6; } 11850 else 11851 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 11852 $as_echo "no" >&6; } 11853 fi 11854 11855 11856 if test "x$TOUCH" = x; then 11857 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 11858 fi 11859 else 11860 # Otherwise we believe it is a complete path. Use it as it is. 11861 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool TOUCH=$tool_specified" >&5 11862 $as_echo "$as_me: Will use user supplied tool TOUCH=$tool_specified" >&6;} 11863 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for TOUCH" >&5 11864 $as_echo_n "checking for TOUCH... " >&6; } 11865 if test ! -x "$tool_specified"; then 11866 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 11867 $as_echo "not found" >&6; } 11868 as_fn_error $? "User supplied tool TOUCH=$tool_specified does not exist or is not executable" "$LINENO" 5 11869 fi 11870 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 11871 $as_echo "$tool_specified" >&6; } 11872 fi 11873 fi 11874 fi 11875 11876 fi 11877 11878 11879 11880 if test "x$TOUCH" = x; then 11881 as_fn_error $? "Could not find required tool for TOUCH" "$LINENO" 5 11882 fi 11883 11884 11885 11886 11887 11888 # Publish this variable in the help. 11889 11890 11891 if [ -z "${TR+x}" ]; then 11892 # The variable is not set by user, try to locate tool using the code snippet 11893 for ac_prog in tr 11894 do 11895 # Extract the first word of "$ac_prog", so it can be a program name with args. 11896 set dummy $ac_prog; ac_word=$2 11897 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 11898 $as_echo_n "checking for $ac_word... " >&6; } 11899 if ${ac_cv_path_TR+:} false; then : 11900 $as_echo_n "(cached) " >&6 11901 else 11902 case $TR in 11903 [\\/]* | ?:[\\/]*) 11904 ac_cv_path_TR="$TR" # Let the user override the test with a path. 11905 ;; 11906 *) 11907 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 11908 for as_dir in $PATH 11909 do 11910 IFS=$as_save_IFS 11911 test -z "$as_dir" && as_dir=. 11912 for ac_exec_ext in '' $ac_executable_extensions; do 11913 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 11914 ac_cv_path_TR="$as_dir/$ac_word$ac_exec_ext" 11915 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 11916 break 2 11917 fi 11918 done 11919 done 11920 IFS=$as_save_IFS 11921 11922 ;; 11923 esac 11924 fi 11925 TR=$ac_cv_path_TR 11926 if test -n "$TR"; then 11927 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $TR" >&5 11928 $as_echo "$TR" >&6; } 11929 else 11930 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 11931 $as_echo "no" >&6; } 11932 fi 11933 11934 11935 test -n "$TR" && break 11936 done 11937 11938 else 11939 # The variable is set, but is it from the command line or the environment? 11940 11941 # Try to remove the string !TR! from our list. 11942 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!TR!/} 11943 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 11944 # If it failed, the variable was not from the command line. Ignore it, 11945 # but warn the user (except for BASH, which is always set by the calling BASH). 11946 if test "xTR" != xBASH; then 11947 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of TR from the environment. Use command line variables instead." >&5 11948 $as_echo "$as_me: WARNING: Ignoring value of TR from the environment. Use command line variables instead." >&2;} 11949 fi 11950 # Try to locate tool using the code snippet 11951 for ac_prog in tr 11952 do 11953 # Extract the first word of "$ac_prog", so it can be a program name with args. 11954 set dummy $ac_prog; ac_word=$2 11955 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 11956 $as_echo_n "checking for $ac_word... " >&6; } 11957 if ${ac_cv_path_TR+:} false; then : 11958 $as_echo_n "(cached) " >&6 11959 else 11960 case $TR in 11961 [\\/]* | ?:[\\/]*) 11962 ac_cv_path_TR="$TR" # Let the user override the test with a path. 11963 ;; 11964 *) 11965 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 11966 for as_dir in $PATH 11967 do 11968 IFS=$as_save_IFS 11969 test -z "$as_dir" && as_dir=. 11970 for ac_exec_ext in '' $ac_executable_extensions; do 11971 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 11972 ac_cv_path_TR="$as_dir/$ac_word$ac_exec_ext" 11973 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 11974 break 2 11975 fi 11976 done 11977 done 11978 IFS=$as_save_IFS 11979 11980 ;; 11981 esac 11982 fi 11983 TR=$ac_cv_path_TR 11984 if test -n "$TR"; then 11985 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $TR" >&5 11986 $as_echo "$TR" >&6; } 11987 else 11988 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 11989 $as_echo "no" >&6; } 11990 fi 11991 11992 11993 test -n "$TR" && break 11994 done 11995 11996 else 11997 # If it succeeded, then it was overridden by the user. We will use it 11998 # for the tool. 11999 12000 # First remove it from the list of overridden variables, so we can test 12001 # for unknown variables in the end. 12002 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 12003 12004 # Check if we try to supply an empty value 12005 if test "x$TR" = x; then 12006 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool TR= (no value)" >&5 12007 $as_echo "$as_me: Setting user supplied tool TR= (no value)" >&6;} 12008 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for TR" >&5 12009 $as_echo_n "checking for TR... " >&6; } 12010 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 12011 $as_echo "disabled" >&6; } 12012 else 12013 # Check if the provided tool contains a complete path. 12014 tool_specified="$TR" 12015 tool_basename="${tool_specified##*/}" 12016 if test "x$tool_basename" = "x$tool_specified"; then 12017 # A command without a complete path is provided, search $PATH. 12018 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool TR=$tool_basename" >&5 12019 $as_echo "$as_me: Will search for user supplied tool TR=$tool_basename" >&6;} 12020 # Extract the first word of "$tool_basename", so it can be a program name with args. 12021 set dummy $tool_basename; ac_word=$2 12022 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 12023 $as_echo_n "checking for $ac_word... " >&6; } 12024 if ${ac_cv_path_TR+:} false; then : 12025 $as_echo_n "(cached) " >&6 12026 else 12027 case $TR in 12028 [\\/]* | ?:[\\/]*) 12029 ac_cv_path_TR="$TR" # Let the user override the test with a path. 12030 ;; 12031 *) 12032 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 12033 for as_dir in $PATH 12034 do 12035 IFS=$as_save_IFS 12036 test -z "$as_dir" && as_dir=. 12037 for ac_exec_ext in '' $ac_executable_extensions; do 12038 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 12039 ac_cv_path_TR="$as_dir/$ac_word$ac_exec_ext" 12040 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 12041 break 2 12042 fi 12043 done 12044 done 12045 IFS=$as_save_IFS 12046 12047 ;; 12048 esac 12049 fi 12050 TR=$ac_cv_path_TR 12051 if test -n "$TR"; then 12052 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $TR" >&5 12053 $as_echo "$TR" >&6; } 12054 else 12055 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 12056 $as_echo "no" >&6; } 12057 fi 12058 12059 12060 if test "x$TR" = x; then 12061 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 12062 fi 12063 else 12064 # Otherwise we believe it is a complete path. Use it as it is. 12065 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool TR=$tool_specified" >&5 12066 $as_echo "$as_me: Will use user supplied tool TR=$tool_specified" >&6;} 12067 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for TR" >&5 12068 $as_echo_n "checking for TR... " >&6; } 12069 if test ! -x "$tool_specified"; then 12070 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 12071 $as_echo "not found" >&6; } 12072 as_fn_error $? "User supplied tool TR=$tool_specified does not exist or is not executable" "$LINENO" 5 12073 fi 12074 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 12075 $as_echo "$tool_specified" >&6; } 12076 fi 12077 fi 12078 fi 12079 12080 fi 12081 12082 12083 12084 if test "x$TR" = x; then 12085 as_fn_error $? "Could not find required tool for TR" "$LINENO" 5 12086 fi 12087 12088 12089 12090 12091 12092 # Publish this variable in the help. 12093 12094 12095 if [ -z "${UNAME+x}" ]; then 12096 # The variable is not set by user, try to locate tool using the code snippet 12097 for ac_prog in uname 12098 do 12099 # Extract the first word of "$ac_prog", so it can be a program name with args. 12100 set dummy $ac_prog; ac_word=$2 12101 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 12102 $as_echo_n "checking for $ac_word... " >&6; } 12103 if ${ac_cv_path_UNAME+:} false; then : 12104 $as_echo_n "(cached) " >&6 12105 else 12106 case $UNAME in 12107 [\\/]* | ?:[\\/]*) 12108 ac_cv_path_UNAME="$UNAME" # Let the user override the test with a path. 12109 ;; 12110 *) 12111 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 12112 for as_dir in $PATH 12113 do 12114 IFS=$as_save_IFS 12115 test -z "$as_dir" && as_dir=. 12116 for ac_exec_ext in '' $ac_executable_extensions; do 12117 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 12118 ac_cv_path_UNAME="$as_dir/$ac_word$ac_exec_ext" 12119 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 12120 break 2 12121 fi 12122 done 12123 done 12124 IFS=$as_save_IFS 12125 12126 ;; 12127 esac 12128 fi 12129 UNAME=$ac_cv_path_UNAME 12130 if test -n "$UNAME"; then 12131 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $UNAME" >&5 12132 $as_echo "$UNAME" >&6; } 12133 else 12134 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 12135 $as_echo "no" >&6; } 12136 fi 12137 12138 12139 test -n "$UNAME" && break 12140 done 12141 12142 else 12143 # The variable is set, but is it from the command line or the environment? 12144 12145 # Try to remove the string !UNAME! from our list. 12146 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!UNAME!/} 12147 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 12148 # If it failed, the variable was not from the command line. Ignore it, 12149 # but warn the user (except for BASH, which is always set by the calling BASH). 12150 if test "xUNAME" != xBASH; then 12151 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of UNAME from the environment. Use command line variables instead." >&5 12152 $as_echo "$as_me: WARNING: Ignoring value of UNAME from the environment. Use command line variables instead." >&2;} 12153 fi 12154 # Try to locate tool using the code snippet 12155 for ac_prog in uname 12156 do 12157 # Extract the first word of "$ac_prog", so it can be a program name with args. 12158 set dummy $ac_prog; ac_word=$2 12159 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 12160 $as_echo_n "checking for $ac_word... " >&6; } 12161 if ${ac_cv_path_UNAME+:} false; then : 12162 $as_echo_n "(cached) " >&6 12163 else 12164 case $UNAME in 12165 [\\/]* | ?:[\\/]*) 12166 ac_cv_path_UNAME="$UNAME" # Let the user override the test with a path. 12167 ;; 12168 *) 12169 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 12170 for as_dir in $PATH 12171 do 12172 IFS=$as_save_IFS 12173 test -z "$as_dir" && as_dir=. 12174 for ac_exec_ext in '' $ac_executable_extensions; do 12175 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 12176 ac_cv_path_UNAME="$as_dir/$ac_word$ac_exec_ext" 12177 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 12178 break 2 12179 fi 12180 done 12181 done 12182 IFS=$as_save_IFS 12183 12184 ;; 12185 esac 12186 fi 12187 UNAME=$ac_cv_path_UNAME 12188 if test -n "$UNAME"; then 12189 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $UNAME" >&5 12190 $as_echo "$UNAME" >&6; } 12191 else 12192 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 12193 $as_echo "no" >&6; } 12194 fi 12195 12196 12197 test -n "$UNAME" && break 12198 done 12199 12200 else 12201 # If it succeeded, then it was overridden by the user. We will use it 12202 # for the tool. 12203 12204 # First remove it from the list of overridden variables, so we can test 12205 # for unknown variables in the end. 12206 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 12207 12208 # Check if we try to supply an empty value 12209 if test "x$UNAME" = x; then 12210 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool UNAME= (no value)" >&5 12211 $as_echo "$as_me: Setting user supplied tool UNAME= (no value)" >&6;} 12212 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for UNAME" >&5 12213 $as_echo_n "checking for UNAME... " >&6; } 12214 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 12215 $as_echo "disabled" >&6; } 12216 else 12217 # Check if the provided tool contains a complete path. 12218 tool_specified="$UNAME" 12219 tool_basename="${tool_specified##*/}" 12220 if test "x$tool_basename" = "x$tool_specified"; then 12221 # A command without a complete path is provided, search $PATH. 12222 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool UNAME=$tool_basename" >&5 12223 $as_echo "$as_me: Will search for user supplied tool UNAME=$tool_basename" >&6;} 12224 # Extract the first word of "$tool_basename", so it can be a program name with args. 12225 set dummy $tool_basename; ac_word=$2 12226 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 12227 $as_echo_n "checking for $ac_word... " >&6; } 12228 if ${ac_cv_path_UNAME+:} false; then : 12229 $as_echo_n "(cached) " >&6 12230 else 12231 case $UNAME in 12232 [\\/]* | ?:[\\/]*) 12233 ac_cv_path_UNAME="$UNAME" # Let the user override the test with a path. 12234 ;; 12235 *) 12236 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 12237 for as_dir in $PATH 12238 do 12239 IFS=$as_save_IFS 12240 test -z "$as_dir" && as_dir=. 12241 for ac_exec_ext in '' $ac_executable_extensions; do 12242 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 12243 ac_cv_path_UNAME="$as_dir/$ac_word$ac_exec_ext" 12244 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 12245 break 2 12246 fi 12247 done 12248 done 12249 IFS=$as_save_IFS 12250 12251 ;; 12252 esac 12253 fi 12254 UNAME=$ac_cv_path_UNAME 12255 if test -n "$UNAME"; then 12256 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $UNAME" >&5 12257 $as_echo "$UNAME" >&6; } 12258 else 12259 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 12260 $as_echo "no" >&6; } 12261 fi 12262 12263 12264 if test "x$UNAME" = x; then 12265 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 12266 fi 12267 else 12268 # Otherwise we believe it is a complete path. Use it as it is. 12269 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool UNAME=$tool_specified" >&5 12270 $as_echo "$as_me: Will use user supplied tool UNAME=$tool_specified" >&6;} 12271 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for UNAME" >&5 12272 $as_echo_n "checking for UNAME... " >&6; } 12273 if test ! -x "$tool_specified"; then 12274 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 12275 $as_echo "not found" >&6; } 12276 as_fn_error $? "User supplied tool UNAME=$tool_specified does not exist or is not executable" "$LINENO" 5 12277 fi 12278 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 12279 $as_echo "$tool_specified" >&6; } 12280 fi 12281 fi 12282 fi 12283 12284 fi 12285 12286 12287 12288 if test "x$UNAME" = x; then 12289 as_fn_error $? "Could not find required tool for UNAME" "$LINENO" 5 12290 fi 12291 12292 12293 12294 12295 12296 # Publish this variable in the help. 12297 12298 12299 if [ -z "${UNIQ+x}" ]; then 12300 # The variable is not set by user, try to locate tool using the code snippet 12301 for ac_prog in uniq 12302 do 12303 # Extract the first word of "$ac_prog", so it can be a program name with args. 12304 set dummy $ac_prog; ac_word=$2 12305 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 12306 $as_echo_n "checking for $ac_word... " >&6; } 12307 if ${ac_cv_path_UNIQ+:} false; then : 12308 $as_echo_n "(cached) " >&6 12309 else 12310 case $UNIQ in 12311 [\\/]* | ?:[\\/]*) 12312 ac_cv_path_UNIQ="$UNIQ" # Let the user override the test with a path. 12313 ;; 12314 *) 12315 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 12316 for as_dir in $PATH 12317 do 12318 IFS=$as_save_IFS 12319 test -z "$as_dir" && as_dir=. 12320 for ac_exec_ext in '' $ac_executable_extensions; do 12321 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 12322 ac_cv_path_UNIQ="$as_dir/$ac_word$ac_exec_ext" 12323 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 12324 break 2 12325 fi 12326 done 12327 done 12328 IFS=$as_save_IFS 12329 12330 ;; 12331 esac 12332 fi 12333 UNIQ=$ac_cv_path_UNIQ 12334 if test -n "$UNIQ"; then 12335 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $UNIQ" >&5 12336 $as_echo "$UNIQ" >&6; } 12337 else 12338 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 12339 $as_echo "no" >&6; } 12340 fi 12341 12342 12343 test -n "$UNIQ" && break 12344 done 12345 12346 else 12347 # The variable is set, but is it from the command line or the environment? 12348 12349 # Try to remove the string !UNIQ! from our list. 12350 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!UNIQ!/} 12351 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 12352 # If it failed, the variable was not from the command line. Ignore it, 12353 # but warn the user (except for BASH, which is always set by the calling BASH). 12354 if test "xUNIQ" != xBASH; then 12355 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of UNIQ from the environment. Use command line variables instead." >&5 12356 $as_echo "$as_me: WARNING: Ignoring value of UNIQ from the environment. Use command line variables instead." >&2;} 12357 fi 12358 # Try to locate tool using the code snippet 12359 for ac_prog in uniq 12360 do 12361 # Extract the first word of "$ac_prog", so it can be a program name with args. 12362 set dummy $ac_prog; ac_word=$2 12363 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 12364 $as_echo_n "checking for $ac_word... " >&6; } 12365 if ${ac_cv_path_UNIQ+:} false; then : 12366 $as_echo_n "(cached) " >&6 12367 else 12368 case $UNIQ in 12369 [\\/]* | ?:[\\/]*) 12370 ac_cv_path_UNIQ="$UNIQ" # Let the user override the test with a path. 12371 ;; 12372 *) 12373 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 12374 for as_dir in $PATH 12375 do 12376 IFS=$as_save_IFS 12377 test -z "$as_dir" && as_dir=. 12378 for ac_exec_ext in '' $ac_executable_extensions; do 12379 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 12380 ac_cv_path_UNIQ="$as_dir/$ac_word$ac_exec_ext" 12381 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 12382 break 2 12383 fi 12384 done 12385 done 12386 IFS=$as_save_IFS 12387 12388 ;; 12389 esac 12390 fi 12391 UNIQ=$ac_cv_path_UNIQ 12392 if test -n "$UNIQ"; then 12393 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $UNIQ" >&5 12394 $as_echo "$UNIQ" >&6; } 12395 else 12396 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 12397 $as_echo "no" >&6; } 12398 fi 12399 12400 12401 test -n "$UNIQ" && break 12402 done 12403 12404 else 12405 # If it succeeded, then it was overridden by the user. We will use it 12406 # for the tool. 12407 12408 # First remove it from the list of overridden variables, so we can test 12409 # for unknown variables in the end. 12410 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 12411 12412 # Check if we try to supply an empty value 12413 if test "x$UNIQ" = x; then 12414 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool UNIQ= (no value)" >&5 12415 $as_echo "$as_me: Setting user supplied tool UNIQ= (no value)" >&6;} 12416 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for UNIQ" >&5 12417 $as_echo_n "checking for UNIQ... " >&6; } 12418 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 12419 $as_echo "disabled" >&6; } 12420 else 12421 # Check if the provided tool contains a complete path. 12422 tool_specified="$UNIQ" 12423 tool_basename="${tool_specified##*/}" 12424 if test "x$tool_basename" = "x$tool_specified"; then 12425 # A command without a complete path is provided, search $PATH. 12426 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool UNIQ=$tool_basename" >&5 12427 $as_echo "$as_me: Will search for user supplied tool UNIQ=$tool_basename" >&6;} 12428 # Extract the first word of "$tool_basename", so it can be a program name with args. 12429 set dummy $tool_basename; ac_word=$2 12430 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 12431 $as_echo_n "checking for $ac_word... " >&6; } 12432 if ${ac_cv_path_UNIQ+:} false; then : 12433 $as_echo_n "(cached) " >&6 12434 else 12435 case $UNIQ in 12436 [\\/]* | ?:[\\/]*) 12437 ac_cv_path_UNIQ="$UNIQ" # Let the user override the test with a path. 12438 ;; 12439 *) 12440 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 12441 for as_dir in $PATH 12442 do 12443 IFS=$as_save_IFS 12444 test -z "$as_dir" && as_dir=. 12445 for ac_exec_ext in '' $ac_executable_extensions; do 12446 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 12447 ac_cv_path_UNIQ="$as_dir/$ac_word$ac_exec_ext" 12448 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 12449 break 2 12450 fi 12451 done 12452 done 12453 IFS=$as_save_IFS 12454 12455 ;; 12456 esac 12457 fi 12458 UNIQ=$ac_cv_path_UNIQ 12459 if test -n "$UNIQ"; then 12460 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $UNIQ" >&5 12461 $as_echo "$UNIQ" >&6; } 12462 else 12463 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 12464 $as_echo "no" >&6; } 12465 fi 12466 12467 12468 if test "x$UNIQ" = x; then 12469 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 12470 fi 12471 else 12472 # Otherwise we believe it is a complete path. Use it as it is. 12473 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool UNIQ=$tool_specified" >&5 12474 $as_echo "$as_me: Will use user supplied tool UNIQ=$tool_specified" >&6;} 12475 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for UNIQ" >&5 12476 $as_echo_n "checking for UNIQ... " >&6; } 12477 if test ! -x "$tool_specified"; then 12478 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 12479 $as_echo "not found" >&6; } 12480 as_fn_error $? "User supplied tool UNIQ=$tool_specified does not exist or is not executable" "$LINENO" 5 12481 fi 12482 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 12483 $as_echo "$tool_specified" >&6; } 12484 fi 12485 fi 12486 fi 12487 12488 fi 12489 12490 12491 12492 if test "x$UNIQ" = x; then 12493 as_fn_error $? "Could not find required tool for UNIQ" "$LINENO" 5 12494 fi 12495 12496 12497 12498 12499 12500 # Publish this variable in the help. 12501 12502 12503 if [ -z "${WC+x}" ]; then 12504 # The variable is not set by user, try to locate tool using the code snippet 12505 for ac_prog in wc 12506 do 12507 # Extract the first word of "$ac_prog", so it can be a program name with args. 12508 set dummy $ac_prog; ac_word=$2 12509 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 12510 $as_echo_n "checking for $ac_word... " >&6; } 12511 if ${ac_cv_path_WC+:} false; then : 12512 $as_echo_n "(cached) " >&6 12513 else 12514 case $WC in 12515 [\\/]* | ?:[\\/]*) 12516 ac_cv_path_WC="$WC" # Let the user override the test with a path. 12517 ;; 12518 *) 12519 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 12520 for as_dir in $PATH 12521 do 12522 IFS=$as_save_IFS 12523 test -z "$as_dir" && as_dir=. 12524 for ac_exec_ext in '' $ac_executable_extensions; do 12525 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 12526 ac_cv_path_WC="$as_dir/$ac_word$ac_exec_ext" 12527 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 12528 break 2 12529 fi 12530 done 12531 done 12532 IFS=$as_save_IFS 12533 12534 ;; 12535 esac 12536 fi 12537 WC=$ac_cv_path_WC 12538 if test -n "$WC"; then 12539 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $WC" >&5 12540 $as_echo "$WC" >&6; } 12541 else 12542 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 12543 $as_echo "no" >&6; } 12544 fi 12545 12546 12547 test -n "$WC" && break 12548 done 12549 12550 else 12551 # The variable is set, but is it from the command line or the environment? 12552 12553 # Try to remove the string !WC! from our list. 12554 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!WC!/} 12555 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 12556 # If it failed, the variable was not from the command line. Ignore it, 12557 # but warn the user (except for BASH, which is always set by the calling BASH). 12558 if test "xWC" != xBASH; then 12559 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of WC from the environment. Use command line variables instead." >&5 12560 $as_echo "$as_me: WARNING: Ignoring value of WC from the environment. Use command line variables instead." >&2;} 12561 fi 12562 # Try to locate tool using the code snippet 12563 for ac_prog in wc 12564 do 12565 # Extract the first word of "$ac_prog", so it can be a program name with args. 12566 set dummy $ac_prog; ac_word=$2 12567 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 12568 $as_echo_n "checking for $ac_word... " >&6; } 12569 if ${ac_cv_path_WC+:} false; then : 12570 $as_echo_n "(cached) " >&6 12571 else 12572 case $WC in 12573 [\\/]* | ?:[\\/]*) 12574 ac_cv_path_WC="$WC" # Let the user override the test with a path. 12575 ;; 12576 *) 12577 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 12578 for as_dir in $PATH 12579 do 12580 IFS=$as_save_IFS 12581 test -z "$as_dir" && as_dir=. 12582 for ac_exec_ext in '' $ac_executable_extensions; do 12583 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 12584 ac_cv_path_WC="$as_dir/$ac_word$ac_exec_ext" 12585 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 12586 break 2 12587 fi 12588 done 12589 done 12590 IFS=$as_save_IFS 12591 12592 ;; 12593 esac 12594 fi 12595 WC=$ac_cv_path_WC 12596 if test -n "$WC"; then 12597 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $WC" >&5 12598 $as_echo "$WC" >&6; } 12599 else 12600 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 12601 $as_echo "no" >&6; } 12602 fi 12603 12604 12605 test -n "$WC" && break 12606 done 12607 12608 else 12609 # If it succeeded, then it was overridden by the user. We will use it 12610 # for the tool. 12611 12612 # First remove it from the list of overridden variables, so we can test 12613 # for unknown variables in the end. 12614 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 12615 12616 # Check if we try to supply an empty value 12617 if test "x$WC" = x; then 12618 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool WC= (no value)" >&5 12619 $as_echo "$as_me: Setting user supplied tool WC= (no value)" >&6;} 12620 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for WC" >&5 12621 $as_echo_n "checking for WC... " >&6; } 12622 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 12623 $as_echo "disabled" >&6; } 12624 else 12625 # Check if the provided tool contains a complete path. 12626 tool_specified="$WC" 12627 tool_basename="${tool_specified##*/}" 12628 if test "x$tool_basename" = "x$tool_specified"; then 12629 # A command without a complete path is provided, search $PATH. 12630 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool WC=$tool_basename" >&5 12631 $as_echo "$as_me: Will search for user supplied tool WC=$tool_basename" >&6;} 12632 # Extract the first word of "$tool_basename", so it can be a program name with args. 12633 set dummy $tool_basename; ac_word=$2 12634 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 12635 $as_echo_n "checking for $ac_word... " >&6; } 12636 if ${ac_cv_path_WC+:} false; then : 12637 $as_echo_n "(cached) " >&6 12638 else 12639 case $WC in 12640 [\\/]* | ?:[\\/]*) 12641 ac_cv_path_WC="$WC" # Let the user override the test with a path. 12642 ;; 12643 *) 12644 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 12645 for as_dir in $PATH 12646 do 12647 IFS=$as_save_IFS 12648 test -z "$as_dir" && as_dir=. 12649 for ac_exec_ext in '' $ac_executable_extensions; do 12650 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 12651 ac_cv_path_WC="$as_dir/$ac_word$ac_exec_ext" 12652 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 12653 break 2 12654 fi 12655 done 12656 done 12657 IFS=$as_save_IFS 12658 12659 ;; 12660 esac 12661 fi 12662 WC=$ac_cv_path_WC 12663 if test -n "$WC"; then 12664 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $WC" >&5 12665 $as_echo "$WC" >&6; } 12666 else 12667 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 12668 $as_echo "no" >&6; } 12669 fi 12670 12671 12672 if test "x$WC" = x; then 12673 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 12674 fi 12675 else 12676 # Otherwise we believe it is a complete path. Use it as it is. 12677 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool WC=$tool_specified" >&5 12678 $as_echo "$as_me: Will use user supplied tool WC=$tool_specified" >&6;} 12679 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for WC" >&5 12680 $as_echo_n "checking for WC... " >&6; } 12681 if test ! -x "$tool_specified"; then 12682 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 12683 $as_echo "not found" >&6; } 12684 as_fn_error $? "User supplied tool WC=$tool_specified does not exist or is not executable" "$LINENO" 5 12685 fi 12686 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 12687 $as_echo "$tool_specified" >&6; } 12688 fi 12689 fi 12690 fi 12691 12692 fi 12693 12694 12695 12696 if test "x$WC" = x; then 12697 as_fn_error $? "Could not find required tool for WC" "$LINENO" 5 12698 fi 12699 12700 12701 12702 12703 12704 # Publish this variable in the help. 12705 12706 12707 if [ -z "${WHICH+x}" ]; then 12708 # The variable is not set by user, try to locate tool using the code snippet 12709 for ac_prog in which 12710 do 12711 # Extract the first word of "$ac_prog", so it can be a program name with args. 12712 set dummy $ac_prog; ac_word=$2 12713 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 12714 $as_echo_n "checking for $ac_word... " >&6; } 12715 if ${ac_cv_path_WHICH+:} false; then : 12716 $as_echo_n "(cached) " >&6 12717 else 12718 case $WHICH in 12719 [\\/]* | ?:[\\/]*) 12720 ac_cv_path_WHICH="$WHICH" # Let the user override the test with a path. 12721 ;; 12722 *) 12723 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 12724 for as_dir in $PATH 12725 do 12726 IFS=$as_save_IFS 12727 test -z "$as_dir" && as_dir=. 12728 for ac_exec_ext in '' $ac_executable_extensions; do 12729 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 12730 ac_cv_path_WHICH="$as_dir/$ac_word$ac_exec_ext" 12731 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 12732 break 2 12733 fi 12734 done 12735 done 12736 IFS=$as_save_IFS 12737 12738 ;; 12739 esac 12740 fi 12741 WHICH=$ac_cv_path_WHICH 12742 if test -n "$WHICH"; then 12743 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $WHICH" >&5 12744 $as_echo "$WHICH" >&6; } 12745 else 12746 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 12747 $as_echo "no" >&6; } 12748 fi 12749 12750 12751 test -n "$WHICH" && break 12752 done 12753 12754 else 12755 # The variable is set, but is it from the command line or the environment? 12756 12757 # Try to remove the string !WHICH! from our list. 12758 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!WHICH!/} 12759 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 12760 # If it failed, the variable was not from the command line. Ignore it, 12761 # but warn the user (except for BASH, which is always set by the calling BASH). 12762 if test "xWHICH" != xBASH; then 12763 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of WHICH from the environment. Use command line variables instead." >&5 12764 $as_echo "$as_me: WARNING: Ignoring value of WHICH from the environment. Use command line variables instead." >&2;} 12765 fi 12766 # Try to locate tool using the code snippet 12767 for ac_prog in which 12768 do 12769 # Extract the first word of "$ac_prog", so it can be a program name with args. 12770 set dummy $ac_prog; ac_word=$2 12771 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 12772 $as_echo_n "checking for $ac_word... " >&6; } 12773 if ${ac_cv_path_WHICH+:} false; then : 12774 $as_echo_n "(cached) " >&6 12775 else 12776 case $WHICH in 12777 [\\/]* | ?:[\\/]*) 12778 ac_cv_path_WHICH="$WHICH" # Let the user override the test with a path. 12779 ;; 12780 *) 12781 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 12782 for as_dir in $PATH 12783 do 12784 IFS=$as_save_IFS 12785 test -z "$as_dir" && as_dir=. 12786 for ac_exec_ext in '' $ac_executable_extensions; do 12787 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 12788 ac_cv_path_WHICH="$as_dir/$ac_word$ac_exec_ext" 12789 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 12790 break 2 12791 fi 12792 done 12793 done 12794 IFS=$as_save_IFS 12795 12796 ;; 12797 esac 12798 fi 12799 WHICH=$ac_cv_path_WHICH 12800 if test -n "$WHICH"; then 12801 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $WHICH" >&5 12802 $as_echo "$WHICH" >&6; } 12803 else 12804 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 12805 $as_echo "no" >&6; } 12806 fi 12807 12808 12809 test -n "$WHICH" && break 12810 done 12811 12812 else 12813 # If it succeeded, then it was overridden by the user. We will use it 12814 # for the tool. 12815 12816 # First remove it from the list of overridden variables, so we can test 12817 # for unknown variables in the end. 12818 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 12819 12820 # Check if we try to supply an empty value 12821 if test "x$WHICH" = x; then 12822 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool WHICH= (no value)" >&5 12823 $as_echo "$as_me: Setting user supplied tool WHICH= (no value)" >&6;} 12824 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for WHICH" >&5 12825 $as_echo_n "checking for WHICH... " >&6; } 12826 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 12827 $as_echo "disabled" >&6; } 12828 else 12829 # Check if the provided tool contains a complete path. 12830 tool_specified="$WHICH" 12831 tool_basename="${tool_specified##*/}" 12832 if test "x$tool_basename" = "x$tool_specified"; then 12833 # A command without a complete path is provided, search $PATH. 12834 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool WHICH=$tool_basename" >&5 12835 $as_echo "$as_me: Will search for user supplied tool WHICH=$tool_basename" >&6;} 12836 # Extract the first word of "$tool_basename", so it can be a program name with args. 12837 set dummy $tool_basename; ac_word=$2 12838 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 12839 $as_echo_n "checking for $ac_word... " >&6; } 12840 if ${ac_cv_path_WHICH+:} false; then : 12841 $as_echo_n "(cached) " >&6 12842 else 12843 case $WHICH in 12844 [\\/]* | ?:[\\/]*) 12845 ac_cv_path_WHICH="$WHICH" # Let the user override the test with a path. 12846 ;; 12847 *) 12848 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 12849 for as_dir in $PATH 12850 do 12851 IFS=$as_save_IFS 12852 test -z "$as_dir" && as_dir=. 12853 for ac_exec_ext in '' $ac_executable_extensions; do 12854 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 12855 ac_cv_path_WHICH="$as_dir/$ac_word$ac_exec_ext" 12856 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 12857 break 2 12858 fi 12859 done 12860 done 12861 IFS=$as_save_IFS 12862 12863 ;; 12864 esac 12865 fi 12866 WHICH=$ac_cv_path_WHICH 12867 if test -n "$WHICH"; then 12868 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $WHICH" >&5 12869 $as_echo "$WHICH" >&6; } 12870 else 12871 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 12872 $as_echo "no" >&6; } 12873 fi 12874 12875 12876 if test "x$WHICH" = x; then 12877 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 12878 fi 12879 else 12880 # Otherwise we believe it is a complete path. Use it as it is. 12881 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool WHICH=$tool_specified" >&5 12882 $as_echo "$as_me: Will use user supplied tool WHICH=$tool_specified" >&6;} 12883 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for WHICH" >&5 12884 $as_echo_n "checking for WHICH... " >&6; } 12885 if test ! -x "$tool_specified"; then 12886 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 12887 $as_echo "not found" >&6; } 12888 as_fn_error $? "User supplied tool WHICH=$tool_specified does not exist or is not executable" "$LINENO" 5 12889 fi 12890 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 12891 $as_echo "$tool_specified" >&6; } 12892 fi 12893 fi 12894 fi 12895 12896 fi 12897 12898 12899 12900 if test "x$WHICH" = x; then 12901 as_fn_error $? "Could not find required tool for WHICH" "$LINENO" 5 12902 fi 12903 12904 12905 12906 12907 12908 # Publish this variable in the help. 12909 12910 12911 if [ -z "${XARGS+x}" ]; then 12912 # The variable is not set by user, try to locate tool using the code snippet 12913 for ac_prog in xargs 12914 do 12915 # Extract the first word of "$ac_prog", so it can be a program name with args. 12916 set dummy $ac_prog; ac_word=$2 12917 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 12918 $as_echo_n "checking for $ac_word... " >&6; } 12919 if ${ac_cv_path_XARGS+:} false; then : 12920 $as_echo_n "(cached) " >&6 12921 else 12922 case $XARGS in 12923 [\\/]* | ?:[\\/]*) 12924 ac_cv_path_XARGS="$XARGS" # Let the user override the test with a path. 12925 ;; 12926 *) 12927 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 12928 for as_dir in $PATH 12929 do 12930 IFS=$as_save_IFS 12931 test -z "$as_dir" && as_dir=. 12932 for ac_exec_ext in '' $ac_executable_extensions; do 12933 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 12934 ac_cv_path_XARGS="$as_dir/$ac_word$ac_exec_ext" 12935 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 12936 break 2 12937 fi 12938 done 12939 done 12940 IFS=$as_save_IFS 12941 12942 ;; 12943 esac 12944 fi 12945 XARGS=$ac_cv_path_XARGS 12946 if test -n "$XARGS"; then 12947 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $XARGS" >&5 12948 $as_echo "$XARGS" >&6; } 12949 else 12950 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 12951 $as_echo "no" >&6; } 12952 fi 12953 12954 12955 test -n "$XARGS" && break 12956 done 12957 12958 else 12959 # The variable is set, but is it from the command line or the environment? 12960 12961 # Try to remove the string !XARGS! from our list. 12962 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!XARGS!/} 12963 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 12964 # If it failed, the variable was not from the command line. Ignore it, 12965 # but warn the user (except for BASH, which is always set by the calling BASH). 12966 if test "xXARGS" != xBASH; then 12967 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of XARGS from the environment. Use command line variables instead." >&5 12968 $as_echo "$as_me: WARNING: Ignoring value of XARGS from the environment. Use command line variables instead." >&2;} 12969 fi 12970 # Try to locate tool using the code snippet 12971 for ac_prog in xargs 12972 do 12973 # Extract the first word of "$ac_prog", so it can be a program name with args. 12974 set dummy $ac_prog; ac_word=$2 12975 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 12976 $as_echo_n "checking for $ac_word... " >&6; } 12977 if ${ac_cv_path_XARGS+:} false; then : 12978 $as_echo_n "(cached) " >&6 12979 else 12980 case $XARGS in 12981 [\\/]* | ?:[\\/]*) 12982 ac_cv_path_XARGS="$XARGS" # Let the user override the test with a path. 12983 ;; 12984 *) 12985 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 12986 for as_dir in $PATH 12987 do 12988 IFS=$as_save_IFS 12989 test -z "$as_dir" && as_dir=. 12990 for ac_exec_ext in '' $ac_executable_extensions; do 12991 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 12992 ac_cv_path_XARGS="$as_dir/$ac_word$ac_exec_ext" 12993 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 12994 break 2 12995 fi 12996 done 12997 done 12998 IFS=$as_save_IFS 12999 13000 ;; 13001 esac 13002 fi 13003 XARGS=$ac_cv_path_XARGS 13004 if test -n "$XARGS"; then 13005 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $XARGS" >&5 13006 $as_echo "$XARGS" >&6; } 13007 else 13008 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 13009 $as_echo "no" >&6; } 13010 fi 13011 13012 13013 test -n "$XARGS" && break 13014 done 13015 13016 else 13017 # If it succeeded, then it was overridden by the user. We will use it 13018 # for the tool. 13019 13020 # First remove it from the list of overridden variables, so we can test 13021 # for unknown variables in the end. 13022 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 13023 13024 # Check if we try to supply an empty value 13025 if test "x$XARGS" = x; then 13026 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool XARGS= (no value)" >&5 13027 $as_echo "$as_me: Setting user supplied tool XARGS= (no value)" >&6;} 13028 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for XARGS" >&5 13029 $as_echo_n "checking for XARGS... " >&6; } 13030 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 13031 $as_echo "disabled" >&6; } 13032 else 13033 # Check if the provided tool contains a complete path. 13034 tool_specified="$XARGS" 13035 tool_basename="${tool_specified##*/}" 13036 if test "x$tool_basename" = "x$tool_specified"; then 13037 # A command without a complete path is provided, search $PATH. 13038 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool XARGS=$tool_basename" >&5 13039 $as_echo "$as_me: Will search for user supplied tool XARGS=$tool_basename" >&6;} 13040 # Extract the first word of "$tool_basename", so it can be a program name with args. 13041 set dummy $tool_basename; ac_word=$2 13042 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 13043 $as_echo_n "checking for $ac_word... " >&6; } 13044 if ${ac_cv_path_XARGS+:} false; then : 13045 $as_echo_n "(cached) " >&6 13046 else 13047 case $XARGS in 13048 [\\/]* | ?:[\\/]*) 13049 ac_cv_path_XARGS="$XARGS" # Let the user override the test with a path. 13050 ;; 13051 *) 13052 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 13053 for as_dir in $PATH 13054 do 13055 IFS=$as_save_IFS 13056 test -z "$as_dir" && as_dir=. 13057 for ac_exec_ext in '' $ac_executable_extensions; do 13058 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 13059 ac_cv_path_XARGS="$as_dir/$ac_word$ac_exec_ext" 13060 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 13061 break 2 13062 fi 13063 done 13064 done 13065 IFS=$as_save_IFS 13066 13067 ;; 13068 esac 13069 fi 13070 XARGS=$ac_cv_path_XARGS 13071 if test -n "$XARGS"; then 13072 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $XARGS" >&5 13073 $as_echo "$XARGS" >&6; } 13074 else 13075 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 13076 $as_echo "no" >&6; } 13077 fi 13078 13079 13080 if test "x$XARGS" = x; then 13081 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 13082 fi 13083 else 13084 # Otherwise we believe it is a complete path. Use it as it is. 13085 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool XARGS=$tool_specified" >&5 13086 $as_echo "$as_me: Will use user supplied tool XARGS=$tool_specified" >&6;} 13087 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for XARGS" >&5 13088 $as_echo_n "checking for XARGS... " >&6; } 13089 if test ! -x "$tool_specified"; then 13090 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 13091 $as_echo "not found" >&6; } 13092 as_fn_error $? "User supplied tool XARGS=$tool_specified does not exist or is not executable" "$LINENO" 5 13093 fi 13094 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 13095 $as_echo "$tool_specified" >&6; } 13096 fi 13097 fi 13098 fi 13099 13100 fi 13101 13102 13103 13104 if test "x$XARGS" = x; then 13105 as_fn_error $? "Could not find required tool for XARGS" "$LINENO" 5 13106 fi 13107 13108 13109 13110 # Then required tools that require some special treatment. 13111 13112 13113 # Publish this variable in the help. 13114 13115 13116 if [ -z "${AWK+x}" ]; then 13117 # The variable is not set by user, try to locate tool using the code snippet 13118 for ac_prog in gawk mawk nawk awk 13119 do 13120 # Extract the first word of "$ac_prog", so it can be a program name with args. 13121 set dummy $ac_prog; ac_word=$2 13122 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 13123 $as_echo_n "checking for $ac_word... " >&6; } 13124 if ${ac_cv_prog_AWK+:} false; then : 13125 $as_echo_n "(cached) " >&6 13126 else 13127 if test -n "$AWK"; then 13128 ac_cv_prog_AWK="$AWK" # Let the user override the test. 13129 else 13130 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 13131 for as_dir in $PATH 13132 do 13133 IFS=$as_save_IFS 13134 test -z "$as_dir" && as_dir=. 13135 for ac_exec_ext in '' $ac_executable_extensions; do 13136 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 13137 ac_cv_prog_AWK="$ac_prog" 13138 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 13139 break 2 13140 fi 13141 done 13142 done 13143 IFS=$as_save_IFS 13144 13145 fi 13146 fi 13147 AWK=$ac_cv_prog_AWK 13148 if test -n "$AWK"; then 13149 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $AWK" >&5 13150 $as_echo "$AWK" >&6; } 13151 else 13152 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 13153 $as_echo "no" >&6; } 13154 fi 13155 13156 13157 test -n "$AWK" && break 13158 done 13159 13160 else 13161 # The variable is set, but is it from the command line or the environment? 13162 13163 # Try to remove the string !AWK! from our list. 13164 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!AWK!/} 13165 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 13166 # If it failed, the variable was not from the command line. Ignore it, 13167 # but warn the user (except for BASH, which is always set by the calling BASH). 13168 if test "xAWK" != xBASH; then 13169 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of AWK from the environment. Use command line variables instead." >&5 13170 $as_echo "$as_me: WARNING: Ignoring value of AWK from the environment. Use command line variables instead." >&2;} 13171 fi 13172 # Try to locate tool using the code snippet 13173 for ac_prog in gawk mawk nawk awk 13174 do 13175 # Extract the first word of "$ac_prog", so it can be a program name with args. 13176 set dummy $ac_prog; ac_word=$2 13177 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 13178 $as_echo_n "checking for $ac_word... " >&6; } 13179 if ${ac_cv_prog_AWK+:} false; then : 13180 $as_echo_n "(cached) " >&6 13181 else 13182 if test -n "$AWK"; then 13183 ac_cv_prog_AWK="$AWK" # Let the user override the test. 13184 else 13185 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 13186 for as_dir in $PATH 13187 do 13188 IFS=$as_save_IFS 13189 test -z "$as_dir" && as_dir=. 13190 for ac_exec_ext in '' $ac_executable_extensions; do 13191 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 13192 ac_cv_prog_AWK="$ac_prog" 13193 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 13194 break 2 13195 fi 13196 done 13197 done 13198 IFS=$as_save_IFS 13199 13200 fi 13201 fi 13202 AWK=$ac_cv_prog_AWK 13203 if test -n "$AWK"; then 13204 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $AWK" >&5 13205 $as_echo "$AWK" >&6; } 13206 else 13207 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 13208 $as_echo "no" >&6; } 13209 fi 13210 13211 13212 test -n "$AWK" && break 13213 done 13214 13215 else 13216 # If it succeeded, then it was overridden by the user. We will use it 13217 # for the tool. 13218 13219 # First remove it from the list of overridden variables, so we can test 13220 # for unknown variables in the end. 13221 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 13222 13223 # Check if we try to supply an empty value 13224 if test "x$AWK" = x; then 13225 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool AWK= (no value)" >&5 13226 $as_echo "$as_me: Setting user supplied tool AWK= (no value)" >&6;} 13227 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for AWK" >&5 13228 $as_echo_n "checking for AWK... " >&6; } 13229 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 13230 $as_echo "disabled" >&6; } 13231 else 13232 # Check if the provided tool contains a complete path. 13233 tool_specified="$AWK" 13234 tool_basename="${tool_specified##*/}" 13235 if test "x$tool_basename" = "x$tool_specified"; then 13236 # A command without a complete path is provided, search $PATH. 13237 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool AWK=$tool_basename" >&5 13238 $as_echo "$as_me: Will search for user supplied tool AWK=$tool_basename" >&6;} 13239 # Extract the first word of "$tool_basename", so it can be a program name with args. 13240 set dummy $tool_basename; ac_word=$2 13241 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 13242 $as_echo_n "checking for $ac_word... " >&6; } 13243 if ${ac_cv_path_AWK+:} false; then : 13244 $as_echo_n "(cached) " >&6 13245 else 13246 case $AWK in 13247 [\\/]* | ?:[\\/]*) 13248 ac_cv_path_AWK="$AWK" # Let the user override the test with a path. 13249 ;; 13250 *) 13251 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 13252 for as_dir in $PATH 13253 do 13254 IFS=$as_save_IFS 13255 test -z "$as_dir" && as_dir=. 13256 for ac_exec_ext in '' $ac_executable_extensions; do 13257 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 13258 ac_cv_path_AWK="$as_dir/$ac_word$ac_exec_ext" 13259 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 13260 break 2 13261 fi 13262 done 13263 done 13264 IFS=$as_save_IFS 13265 13266 ;; 13267 esac 13268 fi 13269 AWK=$ac_cv_path_AWK 13270 if test -n "$AWK"; then 13271 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $AWK" >&5 13272 $as_echo "$AWK" >&6; } 13273 else 13274 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 13275 $as_echo "no" >&6; } 13276 fi 13277 13278 13279 if test "x$AWK" = x; then 13280 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 13281 fi 13282 else 13283 # Otherwise we believe it is a complete path. Use it as it is. 13284 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool AWK=$tool_specified" >&5 13285 $as_echo "$as_me: Will use user supplied tool AWK=$tool_specified" >&6;} 13286 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for AWK" >&5 13287 $as_echo_n "checking for AWK... " >&6; } 13288 if test ! -x "$tool_specified"; then 13289 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 13290 $as_echo "not found" >&6; } 13291 as_fn_error $? "User supplied tool AWK=$tool_specified does not exist or is not executable" "$LINENO" 5 13292 fi 13293 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 13294 $as_echo "$tool_specified" >&6; } 13295 fi 13296 fi 13297 fi 13298 13299 fi 13300 13301 13302 if test "x$AWK" = x; then 13303 as_fn_error $? "Could not find required tool for AWK" "$LINENO" 5 13304 fi 13305 13306 13307 13308 13309 # Publish this variable in the help. 13310 13311 13312 if [ -z "${GREP+x}" ]; then 13313 # The variable is not set by user, try to locate tool using the code snippet 13314 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for grep that handles long lines and -e" >&5 13315 $as_echo_n "checking for grep that handles long lines and -e... " >&6; } 13316 if ${ac_cv_path_GREP+:} false; then : 13317 $as_echo_n "(cached) " >&6 13318 else 13319 if test -z "$GREP"; then 13320 ac_path_GREP_found=false 13321 # Loop through the user's path and test for each of PROGNAME-LIST 13322 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 13323 for as_dir in $PATH$PATH_SEPARATOR/usr/xpg4/bin 13324 do 13325 IFS=$as_save_IFS 13326 test -z "$as_dir" && as_dir=. 13327 for ac_prog in grep ggrep; do 13328 for ac_exec_ext in '' $ac_executable_extensions; do 13329 ac_path_GREP="$as_dir/$ac_prog$ac_exec_ext" 13330 as_fn_executable_p "$ac_path_GREP" || continue 13331 # Check for GNU ac_path_GREP and select it if it is found. 13332 # Check for GNU $ac_path_GREP 13333 case `"$ac_path_GREP" --version 2>&1` in 13334 *GNU*) 13335 ac_cv_path_GREP="$ac_path_GREP" ac_path_GREP_found=:;; 13336 *) 13337 ac_count=0 13338 $as_echo_n 0123456789 >"conftest.in" 13339 while : 13340 do 13341 cat "conftest.in" "conftest.in" >"conftest.tmp" 13342 mv "conftest.tmp" "conftest.in" 13343 cp "conftest.in" "conftest.nl" 13344 $as_echo 'GREP' >> "conftest.nl" 13345 "$ac_path_GREP" -e 'GREP$' -e '-(cannot match)-' < "conftest.nl" >"conftest.out" 2>/dev/null || break 13346 diff "conftest.out" "conftest.nl" >/dev/null 2>&1 || break 13347 as_fn_arith $ac_count + 1 && ac_count=$as_val 13348 if test $ac_count -gt ${ac_path_GREP_max-0}; then 13349 # Best one so far, save it but keep looking for a better one 13350 ac_cv_path_GREP="$ac_path_GREP" 13351 ac_path_GREP_max=$ac_count 13352 fi 13353 # 10*(2^10) chars as input seems more than enough 13354 test $ac_count -gt 10 && break 13355 done 13356 rm -f conftest.in conftest.tmp conftest.nl conftest.out;; 13357 esac 13358 13359 $ac_path_GREP_found && break 3 13360 done 13361 done 13362 done 13363 IFS=$as_save_IFS 13364 if test -z "$ac_cv_path_GREP"; then 13365 as_fn_error $? "no acceptable grep could be found in $PATH$PATH_SEPARATOR/usr/xpg4/bin" "$LINENO" 5 13366 fi 13367 else 13368 ac_cv_path_GREP=$GREP 13369 fi 13370 13371 fi 13372 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_path_GREP" >&5 13373 $as_echo "$ac_cv_path_GREP" >&6; } 13374 GREP="$ac_cv_path_GREP" 13375 13376 13377 else 13378 # The variable is set, but is it from the command line or the environment? 13379 13380 # Try to remove the string !GREP! from our list. 13381 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!GREP!/} 13382 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 13383 # If it failed, the variable was not from the command line. Ignore it, 13384 # but warn the user (except for BASH, which is always set by the calling BASH). 13385 if test "xGREP" != xBASH; then 13386 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of GREP from the environment. Use command line variables instead." >&5 13387 $as_echo "$as_me: WARNING: Ignoring value of GREP from the environment. Use command line variables instead." >&2;} 13388 fi 13389 # Try to locate tool using the code snippet 13390 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for grep that handles long lines and -e" >&5 13391 $as_echo_n "checking for grep that handles long lines and -e... " >&6; } 13392 if ${ac_cv_path_GREP+:} false; then : 13393 $as_echo_n "(cached) " >&6 13394 else 13395 if test -z "$GREP"; then 13396 ac_path_GREP_found=false 13397 # Loop through the user's path and test for each of PROGNAME-LIST 13398 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 13399 for as_dir in $PATH$PATH_SEPARATOR/usr/xpg4/bin 13400 do 13401 IFS=$as_save_IFS 13402 test -z "$as_dir" && as_dir=. 13403 for ac_prog in grep ggrep; do 13404 for ac_exec_ext in '' $ac_executable_extensions; do 13405 ac_path_GREP="$as_dir/$ac_prog$ac_exec_ext" 13406 as_fn_executable_p "$ac_path_GREP" || continue 13407 # Check for GNU ac_path_GREP and select it if it is found. 13408 # Check for GNU $ac_path_GREP 13409 case `"$ac_path_GREP" --version 2>&1` in 13410 *GNU*) 13411 ac_cv_path_GREP="$ac_path_GREP" ac_path_GREP_found=:;; 13412 *) 13413 ac_count=0 13414 $as_echo_n 0123456789 >"conftest.in" 13415 while : 13416 do 13417 cat "conftest.in" "conftest.in" >"conftest.tmp" 13418 mv "conftest.tmp" "conftest.in" 13419 cp "conftest.in" "conftest.nl" 13420 $as_echo 'GREP' >> "conftest.nl" 13421 "$ac_path_GREP" -e 'GREP$' -e '-(cannot match)-' < "conftest.nl" >"conftest.out" 2>/dev/null || break 13422 diff "conftest.out" "conftest.nl" >/dev/null 2>&1 || break 13423 as_fn_arith $ac_count + 1 && ac_count=$as_val 13424 if test $ac_count -gt ${ac_path_GREP_max-0}; then 13425 # Best one so far, save it but keep looking for a better one 13426 ac_cv_path_GREP="$ac_path_GREP" 13427 ac_path_GREP_max=$ac_count 13428 fi 13429 # 10*(2^10) chars as input seems more than enough 13430 test $ac_count -gt 10 && break 13431 done 13432 rm -f conftest.in conftest.tmp conftest.nl conftest.out;; 13433 esac 13434 13435 $ac_path_GREP_found && break 3 13436 done 13437 done 13438 done 13439 IFS=$as_save_IFS 13440 if test -z "$ac_cv_path_GREP"; then 13441 as_fn_error $? "no acceptable grep could be found in $PATH$PATH_SEPARATOR/usr/xpg4/bin" "$LINENO" 5 13442 fi 13443 else 13444 ac_cv_path_GREP=$GREP 13445 fi 13446 13447 fi 13448 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_path_GREP" >&5 13449 $as_echo "$ac_cv_path_GREP" >&6; } 13450 GREP="$ac_cv_path_GREP" 13451 13452 13453 else 13454 # If it succeeded, then it was overridden by the user. We will use it 13455 # for the tool. 13456 13457 # First remove it from the list of overridden variables, so we can test 13458 # for unknown variables in the end. 13459 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 13460 13461 # Check if we try to supply an empty value 13462 if test "x$GREP" = x; then 13463 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool GREP= (no value)" >&5 13464 $as_echo "$as_me: Setting user supplied tool GREP= (no value)" >&6;} 13465 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for GREP" >&5 13466 $as_echo_n "checking for GREP... " >&6; } 13467 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 13468 $as_echo "disabled" >&6; } 13469 else 13470 # Check if the provided tool contains a complete path. 13471 tool_specified="$GREP" 13472 tool_basename="${tool_specified##*/}" 13473 if test "x$tool_basename" = "x$tool_specified"; then 13474 # A command without a complete path is provided, search $PATH. 13475 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool GREP=$tool_basename" >&5 13476 $as_echo "$as_me: Will search for user supplied tool GREP=$tool_basename" >&6;} 13477 # Extract the first word of "$tool_basename", so it can be a program name with args. 13478 set dummy $tool_basename; ac_word=$2 13479 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 13480 $as_echo_n "checking for $ac_word... " >&6; } 13481 if ${ac_cv_path_GREP+:} false; then : 13482 $as_echo_n "(cached) " >&6 13483 else 13484 case $GREP in 13485 [\\/]* | ?:[\\/]*) 13486 ac_cv_path_GREP="$GREP" # Let the user override the test with a path. 13487 ;; 13488 *) 13489 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 13490 for as_dir in $PATH 13491 do 13492 IFS=$as_save_IFS 13493 test -z "$as_dir" && as_dir=. 13494 for ac_exec_ext in '' $ac_executable_extensions; do 13495 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 13496 ac_cv_path_GREP="$as_dir/$ac_word$ac_exec_ext" 13497 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 13498 break 2 13499 fi 13500 done 13501 done 13502 IFS=$as_save_IFS 13503 13504 ;; 13505 esac 13506 fi 13507 GREP=$ac_cv_path_GREP 13508 if test -n "$GREP"; then 13509 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $GREP" >&5 13510 $as_echo "$GREP" >&6; } 13511 else 13512 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 13513 $as_echo "no" >&6; } 13514 fi 13515 13516 13517 if test "x$GREP" = x; then 13518 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 13519 fi 13520 else 13521 # Otherwise we believe it is a complete path. Use it as it is. 13522 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool GREP=$tool_specified" >&5 13523 $as_echo "$as_me: Will use user supplied tool GREP=$tool_specified" >&6;} 13524 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for GREP" >&5 13525 $as_echo_n "checking for GREP... " >&6; } 13526 if test ! -x "$tool_specified"; then 13527 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 13528 $as_echo "not found" >&6; } 13529 as_fn_error $? "User supplied tool GREP=$tool_specified does not exist or is not executable" "$LINENO" 5 13530 fi 13531 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 13532 $as_echo "$tool_specified" >&6; } 13533 fi 13534 fi 13535 fi 13536 13537 fi 13538 13539 13540 if test "x$GREP" = x; then 13541 as_fn_error $? "Could not find required tool for GREP" "$LINENO" 5 13542 fi 13543 13544 13545 13546 13547 # Publish this variable in the help. 13548 13549 13550 if [ -z "${EGREP+x}" ]; then 13551 # The variable is not set by user, try to locate tool using the code snippet 13552 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for egrep" >&5 13553 $as_echo_n "checking for egrep... " >&6; } 13554 if ${ac_cv_path_EGREP+:} false; then : 13555 $as_echo_n "(cached) " >&6 13556 else 13557 if echo a | $GREP -E '(a|b)' >/dev/null 2>&1 13558 then ac_cv_path_EGREP="$GREP -E" 13559 else 13560 if test -z "$EGREP"; then 13561 ac_path_EGREP_found=false 13562 # Loop through the user's path and test for each of PROGNAME-LIST 13563 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 13564 for as_dir in $PATH$PATH_SEPARATOR/usr/xpg4/bin 13565 do 13566 IFS=$as_save_IFS 13567 test -z "$as_dir" && as_dir=. 13568 for ac_prog in egrep; do 13569 for ac_exec_ext in '' $ac_executable_extensions; do 13570 ac_path_EGREP="$as_dir/$ac_prog$ac_exec_ext" 13571 as_fn_executable_p "$ac_path_EGREP" || continue 13572 # Check for GNU ac_path_EGREP and select it if it is found. 13573 # Check for GNU $ac_path_EGREP 13574 case `"$ac_path_EGREP" --version 2>&1` in 13575 *GNU*) 13576 ac_cv_path_EGREP="$ac_path_EGREP" ac_path_EGREP_found=:;; 13577 *) 13578 ac_count=0 13579 $as_echo_n 0123456789 >"conftest.in" 13580 while : 13581 do 13582 cat "conftest.in" "conftest.in" >"conftest.tmp" 13583 mv "conftest.tmp" "conftest.in" 13584 cp "conftest.in" "conftest.nl" 13585 $as_echo 'EGREP' >> "conftest.nl" 13586 "$ac_path_EGREP" 'EGREP$' < "conftest.nl" >"conftest.out" 2>/dev/null || break 13587 diff "conftest.out" "conftest.nl" >/dev/null 2>&1 || break 13588 as_fn_arith $ac_count + 1 && ac_count=$as_val 13589 if test $ac_count -gt ${ac_path_EGREP_max-0}; then 13590 # Best one so far, save it but keep looking for a better one 13591 ac_cv_path_EGREP="$ac_path_EGREP" 13592 ac_path_EGREP_max=$ac_count 13593 fi 13594 # 10*(2^10) chars as input seems more than enough 13595 test $ac_count -gt 10 && break 13596 done 13597 rm -f conftest.in conftest.tmp conftest.nl conftest.out;; 13598 esac 13599 13600 $ac_path_EGREP_found && break 3 13601 done 13602 done 13603 done 13604 IFS=$as_save_IFS 13605 if test -z "$ac_cv_path_EGREP"; then 13606 as_fn_error $? "no acceptable egrep could be found in $PATH$PATH_SEPARATOR/usr/xpg4/bin" "$LINENO" 5 13607 fi 13608 else 13609 ac_cv_path_EGREP=$EGREP 13610 fi 13611 13612 fi 13613 fi 13614 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_path_EGREP" >&5 13615 $as_echo "$ac_cv_path_EGREP" >&6; } 13616 EGREP="$ac_cv_path_EGREP" 13617 13618 13619 else 13620 # The variable is set, but is it from the command line or the environment? 13621 13622 # Try to remove the string !EGREP! from our list. 13623 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!EGREP!/} 13624 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 13625 # If it failed, the variable was not from the command line. Ignore it, 13626 # but warn the user (except for BASH, which is always set by the calling BASH). 13627 if test "xEGREP" != xBASH; then 13628 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of EGREP from the environment. Use command line variables instead." >&5 13629 $as_echo "$as_me: WARNING: Ignoring value of EGREP from the environment. Use command line variables instead." >&2;} 13630 fi 13631 # Try to locate tool using the code snippet 13632 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for egrep" >&5 13633 $as_echo_n "checking for egrep... " >&6; } 13634 if ${ac_cv_path_EGREP+:} false; then : 13635 $as_echo_n "(cached) " >&6 13636 else 13637 if echo a | $GREP -E '(a|b)' >/dev/null 2>&1 13638 then ac_cv_path_EGREP="$GREP -E" 13639 else 13640 if test -z "$EGREP"; then 13641 ac_path_EGREP_found=false 13642 # Loop through the user's path and test for each of PROGNAME-LIST 13643 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 13644 for as_dir in $PATH$PATH_SEPARATOR/usr/xpg4/bin 13645 do 13646 IFS=$as_save_IFS 13647 test -z "$as_dir" && as_dir=. 13648 for ac_prog in egrep; do 13649 for ac_exec_ext in '' $ac_executable_extensions; do 13650 ac_path_EGREP="$as_dir/$ac_prog$ac_exec_ext" 13651 as_fn_executable_p "$ac_path_EGREP" || continue 13652 # Check for GNU ac_path_EGREP and select it if it is found. 13653 # Check for GNU $ac_path_EGREP 13654 case `"$ac_path_EGREP" --version 2>&1` in 13655 *GNU*) 13656 ac_cv_path_EGREP="$ac_path_EGREP" ac_path_EGREP_found=:;; 13657 *) 13658 ac_count=0 13659 $as_echo_n 0123456789 >"conftest.in" 13660 while : 13661 do 13662 cat "conftest.in" "conftest.in" >"conftest.tmp" 13663 mv "conftest.tmp" "conftest.in" 13664 cp "conftest.in" "conftest.nl" 13665 $as_echo 'EGREP' >> "conftest.nl" 13666 "$ac_path_EGREP" 'EGREP$' < "conftest.nl" >"conftest.out" 2>/dev/null || break 13667 diff "conftest.out" "conftest.nl" >/dev/null 2>&1 || break 13668 as_fn_arith $ac_count + 1 && ac_count=$as_val 13669 if test $ac_count -gt ${ac_path_EGREP_max-0}; then 13670 # Best one so far, save it but keep looking for a better one 13671 ac_cv_path_EGREP="$ac_path_EGREP" 13672 ac_path_EGREP_max=$ac_count 13673 fi 13674 # 10*(2^10) chars as input seems more than enough 13675 test $ac_count -gt 10 && break 13676 done 13677 rm -f conftest.in conftest.tmp conftest.nl conftest.out;; 13678 esac 13679 13680 $ac_path_EGREP_found && break 3 13681 done 13682 done 13683 done 13684 IFS=$as_save_IFS 13685 if test -z "$ac_cv_path_EGREP"; then 13686 as_fn_error $? "no acceptable egrep could be found in $PATH$PATH_SEPARATOR/usr/xpg4/bin" "$LINENO" 5 13687 fi 13688 else 13689 ac_cv_path_EGREP=$EGREP 13690 fi 13691 13692 fi 13693 fi 13694 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_path_EGREP" >&5 13695 $as_echo "$ac_cv_path_EGREP" >&6; } 13696 EGREP="$ac_cv_path_EGREP" 13697 13698 13699 else 13700 # If it succeeded, then it was overridden by the user. We will use it 13701 # for the tool. 13702 13703 # First remove it from the list of overridden variables, so we can test 13704 # for unknown variables in the end. 13705 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 13706 13707 # Check if we try to supply an empty value 13708 if test "x$EGREP" = x; then 13709 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool EGREP= (no value)" >&5 13710 $as_echo "$as_me: Setting user supplied tool EGREP= (no value)" >&6;} 13711 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for EGREP" >&5 13712 $as_echo_n "checking for EGREP... " >&6; } 13713 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 13714 $as_echo "disabled" >&6; } 13715 else 13716 # Check if the provided tool contains a complete path. 13717 tool_specified="$EGREP" 13718 tool_basename="${tool_specified##*/}" 13719 if test "x$tool_basename" = "x$tool_specified"; then 13720 # A command without a complete path is provided, search $PATH. 13721 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool EGREP=$tool_basename" >&5 13722 $as_echo "$as_me: Will search for user supplied tool EGREP=$tool_basename" >&6;} 13723 # Extract the first word of "$tool_basename", so it can be a program name with args. 13724 set dummy $tool_basename; ac_word=$2 13725 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 13726 $as_echo_n "checking for $ac_word... " >&6; } 13727 if ${ac_cv_path_EGREP+:} false; then : 13728 $as_echo_n "(cached) " >&6 13729 else 13730 case $EGREP in 13731 [\\/]* | ?:[\\/]*) 13732 ac_cv_path_EGREP="$EGREP" # Let the user override the test with a path. 13733 ;; 13734 *) 13735 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 13736 for as_dir in $PATH 13737 do 13738 IFS=$as_save_IFS 13739 test -z "$as_dir" && as_dir=. 13740 for ac_exec_ext in '' $ac_executable_extensions; do 13741 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 13742 ac_cv_path_EGREP="$as_dir/$ac_word$ac_exec_ext" 13743 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 13744 break 2 13745 fi 13746 done 13747 done 13748 IFS=$as_save_IFS 13749 13750 ;; 13751 esac 13752 fi 13753 EGREP=$ac_cv_path_EGREP 13754 if test -n "$EGREP"; then 13755 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $EGREP" >&5 13756 $as_echo "$EGREP" >&6; } 13757 else 13758 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 13759 $as_echo "no" >&6; } 13760 fi 13761 13762 13763 if test "x$EGREP" = x; then 13764 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 13765 fi 13766 else 13767 # Otherwise we believe it is a complete path. Use it as it is. 13768 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool EGREP=$tool_specified" >&5 13769 $as_echo "$as_me: Will use user supplied tool EGREP=$tool_specified" >&6;} 13770 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for EGREP" >&5 13771 $as_echo_n "checking for EGREP... " >&6; } 13772 if test ! -x "$tool_specified"; then 13773 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 13774 $as_echo "not found" >&6; } 13775 as_fn_error $? "User supplied tool EGREP=$tool_specified does not exist or is not executable" "$LINENO" 5 13776 fi 13777 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 13778 $as_echo "$tool_specified" >&6; } 13779 fi 13780 fi 13781 fi 13782 13783 fi 13784 13785 13786 if test "x$EGREP" = x; then 13787 as_fn_error $? "Could not find required tool for EGREP" "$LINENO" 5 13788 fi 13789 13790 13791 13792 13793 # Publish this variable in the help. 13794 13795 13796 if [ -z "${FGREP+x}" ]; then 13797 # The variable is not set by user, try to locate tool using the code snippet 13798 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for fgrep" >&5 13799 $as_echo_n "checking for fgrep... " >&6; } 13800 if ${ac_cv_path_FGREP+:} false; then : 13801 $as_echo_n "(cached) " >&6 13802 else 13803 if echo 'ab*c' | $GREP -F 'ab*c' >/dev/null 2>&1 13804 then ac_cv_path_FGREP="$GREP -F" 13805 else 13806 if test -z "$FGREP"; then 13807 ac_path_FGREP_found=false 13808 # Loop through the user's path and test for each of PROGNAME-LIST 13809 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 13810 for as_dir in $PATH$PATH_SEPARATOR/usr/xpg4/bin 13811 do 13812 IFS=$as_save_IFS 13813 test -z "$as_dir" && as_dir=. 13814 for ac_prog in fgrep; do 13815 for ac_exec_ext in '' $ac_executable_extensions; do 13816 ac_path_FGREP="$as_dir/$ac_prog$ac_exec_ext" 13817 as_fn_executable_p "$ac_path_FGREP" || continue 13818 # Check for GNU ac_path_FGREP and select it if it is found. 13819 # Check for GNU $ac_path_FGREP 13820 case `"$ac_path_FGREP" --version 2>&1` in 13821 *GNU*) 13822 ac_cv_path_FGREP="$ac_path_FGREP" ac_path_FGREP_found=:;; 13823 *) 13824 ac_count=0 13825 $as_echo_n 0123456789 >"conftest.in" 13826 while : 13827 do 13828 cat "conftest.in" "conftest.in" >"conftest.tmp" 13829 mv "conftest.tmp" "conftest.in" 13830 cp "conftest.in" "conftest.nl" 13831 $as_echo 'FGREP' >> "conftest.nl" 13832 "$ac_path_FGREP" FGREP < "conftest.nl" >"conftest.out" 2>/dev/null || break 13833 diff "conftest.out" "conftest.nl" >/dev/null 2>&1 || break 13834 as_fn_arith $ac_count + 1 && ac_count=$as_val 13835 if test $ac_count -gt ${ac_path_FGREP_max-0}; then 13836 # Best one so far, save it but keep looking for a better one 13837 ac_cv_path_FGREP="$ac_path_FGREP" 13838 ac_path_FGREP_max=$ac_count 13839 fi 13840 # 10*(2^10) chars as input seems more than enough 13841 test $ac_count -gt 10 && break 13842 done 13843 rm -f conftest.in conftest.tmp conftest.nl conftest.out;; 13844 esac 13845 13846 $ac_path_FGREP_found && break 3 13847 done 13848 done 13849 done 13850 IFS=$as_save_IFS 13851 if test -z "$ac_cv_path_FGREP"; then 13852 as_fn_error $? "no acceptable fgrep could be found in $PATH$PATH_SEPARATOR/usr/xpg4/bin" "$LINENO" 5 13853 fi 13854 else 13855 ac_cv_path_FGREP=$FGREP 13856 fi 13857 13858 fi 13859 fi 13860 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_path_FGREP" >&5 13861 $as_echo "$ac_cv_path_FGREP" >&6; } 13862 FGREP="$ac_cv_path_FGREP" 13863 13864 13865 else 13866 # The variable is set, but is it from the command line or the environment? 13867 13868 # Try to remove the string !FGREP! from our list. 13869 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!FGREP!/} 13870 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 13871 # If it failed, the variable was not from the command line. Ignore it, 13872 # but warn the user (except for BASH, which is always set by the calling BASH). 13873 if test "xFGREP" != xBASH; then 13874 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of FGREP from the environment. Use command line variables instead." >&5 13875 $as_echo "$as_me: WARNING: Ignoring value of FGREP from the environment. Use command line variables instead." >&2;} 13876 fi 13877 # Try to locate tool using the code snippet 13878 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for fgrep" >&5 13879 $as_echo_n "checking for fgrep... " >&6; } 13880 if ${ac_cv_path_FGREP+:} false; then : 13881 $as_echo_n "(cached) " >&6 13882 else 13883 if echo 'ab*c' | $GREP -F 'ab*c' >/dev/null 2>&1 13884 then ac_cv_path_FGREP="$GREP -F" 13885 else 13886 if test -z "$FGREP"; then 13887 ac_path_FGREP_found=false 13888 # Loop through the user's path and test for each of PROGNAME-LIST 13889 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 13890 for as_dir in $PATH$PATH_SEPARATOR/usr/xpg4/bin 13891 do 13892 IFS=$as_save_IFS 13893 test -z "$as_dir" && as_dir=. 13894 for ac_prog in fgrep; do 13895 for ac_exec_ext in '' $ac_executable_extensions; do 13896 ac_path_FGREP="$as_dir/$ac_prog$ac_exec_ext" 13897 as_fn_executable_p "$ac_path_FGREP" || continue 13898 # Check for GNU ac_path_FGREP and select it if it is found. 13899 # Check for GNU $ac_path_FGREP 13900 case `"$ac_path_FGREP" --version 2>&1` in 13901 *GNU*) 13902 ac_cv_path_FGREP="$ac_path_FGREP" ac_path_FGREP_found=:;; 13903 *) 13904 ac_count=0 13905 $as_echo_n 0123456789 >"conftest.in" 13906 while : 13907 do 13908 cat "conftest.in" "conftest.in" >"conftest.tmp" 13909 mv "conftest.tmp" "conftest.in" 13910 cp "conftest.in" "conftest.nl" 13911 $as_echo 'FGREP' >> "conftest.nl" 13912 "$ac_path_FGREP" FGREP < "conftest.nl" >"conftest.out" 2>/dev/null || break 13913 diff "conftest.out" "conftest.nl" >/dev/null 2>&1 || break 13914 as_fn_arith $ac_count + 1 && ac_count=$as_val 13915 if test $ac_count -gt ${ac_path_FGREP_max-0}; then 13916 # Best one so far, save it but keep looking for a better one 13917 ac_cv_path_FGREP="$ac_path_FGREP" 13918 ac_path_FGREP_max=$ac_count 13919 fi 13920 # 10*(2^10) chars as input seems more than enough 13921 test $ac_count -gt 10 && break 13922 done 13923 rm -f conftest.in conftest.tmp conftest.nl conftest.out;; 13924 esac 13925 13926 $ac_path_FGREP_found && break 3 13927 done 13928 done 13929 done 13930 IFS=$as_save_IFS 13931 if test -z "$ac_cv_path_FGREP"; then 13932 as_fn_error $? "no acceptable fgrep could be found in $PATH$PATH_SEPARATOR/usr/xpg4/bin" "$LINENO" 5 13933 fi 13934 else 13935 ac_cv_path_FGREP=$FGREP 13936 fi 13937 13938 fi 13939 fi 13940 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_path_FGREP" >&5 13941 $as_echo "$ac_cv_path_FGREP" >&6; } 13942 FGREP="$ac_cv_path_FGREP" 13943 13944 13945 else 13946 # If it succeeded, then it was overridden by the user. We will use it 13947 # for the tool. 13948 13949 # First remove it from the list of overridden variables, so we can test 13950 # for unknown variables in the end. 13951 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 13952 13953 # Check if we try to supply an empty value 13954 if test "x$FGREP" = x; then 13955 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool FGREP= (no value)" >&5 13956 $as_echo "$as_me: Setting user supplied tool FGREP= (no value)" >&6;} 13957 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for FGREP" >&5 13958 $as_echo_n "checking for FGREP... " >&6; } 13959 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 13960 $as_echo "disabled" >&6; } 13961 else 13962 # Check if the provided tool contains a complete path. 13963 tool_specified="$FGREP" 13964 tool_basename="${tool_specified##*/}" 13965 if test "x$tool_basename" = "x$tool_specified"; then 13966 # A command without a complete path is provided, search $PATH. 13967 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool FGREP=$tool_basename" >&5 13968 $as_echo "$as_me: Will search for user supplied tool FGREP=$tool_basename" >&6;} 13969 # Extract the first word of "$tool_basename", so it can be a program name with args. 13970 set dummy $tool_basename; ac_word=$2 13971 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 13972 $as_echo_n "checking for $ac_word... " >&6; } 13973 if ${ac_cv_path_FGREP+:} false; then : 13974 $as_echo_n "(cached) " >&6 13975 else 13976 case $FGREP in 13977 [\\/]* | ?:[\\/]*) 13978 ac_cv_path_FGREP="$FGREP" # Let the user override the test with a path. 13979 ;; 13980 *) 13981 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 13982 for as_dir in $PATH 13983 do 13984 IFS=$as_save_IFS 13985 test -z "$as_dir" && as_dir=. 13986 for ac_exec_ext in '' $ac_executable_extensions; do 13987 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 13988 ac_cv_path_FGREP="$as_dir/$ac_word$ac_exec_ext" 13989 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 13990 break 2 13991 fi 13992 done 13993 done 13994 IFS=$as_save_IFS 13995 13996 ;; 13997 esac 13998 fi 13999 FGREP=$ac_cv_path_FGREP 14000 if test -n "$FGREP"; then 14001 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $FGREP" >&5 14002 $as_echo "$FGREP" >&6; } 14003 else 14004 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 14005 $as_echo "no" >&6; } 14006 fi 14007 14008 14009 if test "x$FGREP" = x; then 14010 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 14011 fi 14012 else 14013 # Otherwise we believe it is a complete path. Use it as it is. 14014 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool FGREP=$tool_specified" >&5 14015 $as_echo "$as_me: Will use user supplied tool FGREP=$tool_specified" >&6;} 14016 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for FGREP" >&5 14017 $as_echo_n "checking for FGREP... " >&6; } 14018 if test ! -x "$tool_specified"; then 14019 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 14020 $as_echo "not found" >&6; } 14021 as_fn_error $? "User supplied tool FGREP=$tool_specified does not exist or is not executable" "$LINENO" 5 14022 fi 14023 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 14024 $as_echo "$tool_specified" >&6; } 14025 fi 14026 fi 14027 fi 14028 14029 fi 14030 14031 14032 if test "x$FGREP" = x; then 14033 as_fn_error $? "Could not find required tool for FGREP" "$LINENO" 5 14034 fi 14035 14036 14037 14038 14039 # Publish this variable in the help. 14040 14041 14042 if [ -z "${SED+x}" ]; then 14043 # The variable is not set by user, try to locate tool using the code snippet 14044 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for a sed that does not truncate output" >&5 14045 $as_echo_n "checking for a sed that does not truncate output... " >&6; } 14046 if ${ac_cv_path_SED+:} false; then : 14047 $as_echo_n "(cached) " >&6 14048 else 14049 ac_script=s/aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa/bbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbb/ 14050 for ac_i in 1 2 3 4 5 6 7; do 14051 ac_script="$ac_script$as_nl$ac_script" 14052 done 14053 echo "$ac_script" 2>/dev/null | sed 99q >conftest.sed 14054 { ac_script=; unset ac_script;} 14055 if test -z "$SED"; then 14056 ac_path_SED_found=false 14057 # Loop through the user's path and test for each of PROGNAME-LIST 14058 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 14059 for as_dir in $PATH 14060 do 14061 IFS=$as_save_IFS 14062 test -z "$as_dir" && as_dir=. 14063 for ac_prog in sed gsed; do 14064 for ac_exec_ext in '' $ac_executable_extensions; do 14065 ac_path_SED="$as_dir/$ac_prog$ac_exec_ext" 14066 as_fn_executable_p "$ac_path_SED" || continue 14067 # Check for GNU ac_path_SED and select it if it is found. 14068 # Check for GNU $ac_path_SED 14069 case `"$ac_path_SED" --version 2>&1` in 14070 *GNU*) 14071 ac_cv_path_SED="$ac_path_SED" ac_path_SED_found=:;; 14072 *) 14073 ac_count=0 14074 $as_echo_n 0123456789 >"conftest.in" 14075 while : 14076 do 14077 cat "conftest.in" "conftest.in" >"conftest.tmp" 14078 mv "conftest.tmp" "conftest.in" 14079 cp "conftest.in" "conftest.nl" 14080 $as_echo '' >> "conftest.nl" 14081 "$ac_path_SED" -f conftest.sed < "conftest.nl" >"conftest.out" 2>/dev/null || break 14082 diff "conftest.out" "conftest.nl" >/dev/null 2>&1 || break 14083 as_fn_arith $ac_count + 1 && ac_count=$as_val 14084 if test $ac_count -gt ${ac_path_SED_max-0}; then 14085 # Best one so far, save it but keep looking for a better one 14086 ac_cv_path_SED="$ac_path_SED" 14087 ac_path_SED_max=$ac_count 14088 fi 14089 # 10*(2^10) chars as input seems more than enough 14090 test $ac_count -gt 10 && break 14091 done 14092 rm -f conftest.in conftest.tmp conftest.nl conftest.out;; 14093 esac 14094 14095 $ac_path_SED_found && break 3 14096 done 14097 done 14098 done 14099 IFS=$as_save_IFS 14100 if test -z "$ac_cv_path_SED"; then 14101 as_fn_error $? "no acceptable sed could be found in \$PATH" "$LINENO" 5 14102 fi 14103 else 14104 ac_cv_path_SED=$SED 14105 fi 14106 14107 fi 14108 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_path_SED" >&5 14109 $as_echo "$ac_cv_path_SED" >&6; } 14110 SED="$ac_cv_path_SED" 14111 rm -f conftest.sed 14112 14113 else 14114 # The variable is set, but is it from the command line or the environment? 14115 14116 # Try to remove the string !SED! from our list. 14117 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!SED!/} 14118 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 14119 # If it failed, the variable was not from the command line. Ignore it, 14120 # but warn the user (except for BASH, which is always set by the calling BASH). 14121 if test "xSED" != xBASH; then 14122 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of SED from the environment. Use command line variables instead." >&5 14123 $as_echo "$as_me: WARNING: Ignoring value of SED from the environment. Use command line variables instead." >&2;} 14124 fi 14125 # Try to locate tool using the code snippet 14126 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for a sed that does not truncate output" >&5 14127 $as_echo_n "checking for a sed that does not truncate output... " >&6; } 14128 if ${ac_cv_path_SED+:} false; then : 14129 $as_echo_n "(cached) " >&6 14130 else 14131 ac_script=s/aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa/bbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbb/ 14132 for ac_i in 1 2 3 4 5 6 7; do 14133 ac_script="$ac_script$as_nl$ac_script" 14134 done 14135 echo "$ac_script" 2>/dev/null | sed 99q >conftest.sed 14136 { ac_script=; unset ac_script;} 14137 if test -z "$SED"; then 14138 ac_path_SED_found=false 14139 # Loop through the user's path and test for each of PROGNAME-LIST 14140 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 14141 for as_dir in $PATH 14142 do 14143 IFS=$as_save_IFS 14144 test -z "$as_dir" && as_dir=. 14145 for ac_prog in sed gsed; do 14146 for ac_exec_ext in '' $ac_executable_extensions; do 14147 ac_path_SED="$as_dir/$ac_prog$ac_exec_ext" 14148 as_fn_executable_p "$ac_path_SED" || continue 14149 # Check for GNU ac_path_SED and select it if it is found. 14150 # Check for GNU $ac_path_SED 14151 case `"$ac_path_SED" --version 2>&1` in 14152 *GNU*) 14153 ac_cv_path_SED="$ac_path_SED" ac_path_SED_found=:;; 14154 *) 14155 ac_count=0 14156 $as_echo_n 0123456789 >"conftest.in" 14157 while : 14158 do 14159 cat "conftest.in" "conftest.in" >"conftest.tmp" 14160 mv "conftest.tmp" "conftest.in" 14161 cp "conftest.in" "conftest.nl" 14162 $as_echo '' >> "conftest.nl" 14163 "$ac_path_SED" -f conftest.sed < "conftest.nl" >"conftest.out" 2>/dev/null || break 14164 diff "conftest.out" "conftest.nl" >/dev/null 2>&1 || break 14165 as_fn_arith $ac_count + 1 && ac_count=$as_val 14166 if test $ac_count -gt ${ac_path_SED_max-0}; then 14167 # Best one so far, save it but keep looking for a better one 14168 ac_cv_path_SED="$ac_path_SED" 14169 ac_path_SED_max=$ac_count 14170 fi 14171 # 10*(2^10) chars as input seems more than enough 14172 test $ac_count -gt 10 && break 14173 done 14174 rm -f conftest.in conftest.tmp conftest.nl conftest.out;; 14175 esac 14176 14177 $ac_path_SED_found && break 3 14178 done 14179 done 14180 done 14181 IFS=$as_save_IFS 14182 if test -z "$ac_cv_path_SED"; then 14183 as_fn_error $? "no acceptable sed could be found in \$PATH" "$LINENO" 5 14184 fi 14185 else 14186 ac_cv_path_SED=$SED 14187 fi 14188 14189 fi 14190 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_path_SED" >&5 14191 $as_echo "$ac_cv_path_SED" >&6; } 14192 SED="$ac_cv_path_SED" 14193 rm -f conftest.sed 14194 14195 else 14196 # If it succeeded, then it was overridden by the user. We will use it 14197 # for the tool. 14198 14199 # First remove it from the list of overridden variables, so we can test 14200 # for unknown variables in the end. 14201 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 14202 14203 # Check if we try to supply an empty value 14204 if test "x$SED" = x; then 14205 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool SED= (no value)" >&5 14206 $as_echo "$as_me: Setting user supplied tool SED= (no value)" >&6;} 14207 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for SED" >&5 14208 $as_echo_n "checking for SED... " >&6; } 14209 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 14210 $as_echo "disabled" >&6; } 14211 else 14212 # Check if the provided tool contains a complete path. 14213 tool_specified="$SED" 14214 tool_basename="${tool_specified##*/}" 14215 if test "x$tool_basename" = "x$tool_specified"; then 14216 # A command without a complete path is provided, search $PATH. 14217 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool SED=$tool_basename" >&5 14218 $as_echo "$as_me: Will search for user supplied tool SED=$tool_basename" >&6;} 14219 # Extract the first word of "$tool_basename", so it can be a program name with args. 14220 set dummy $tool_basename; ac_word=$2 14221 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 14222 $as_echo_n "checking for $ac_word... " >&6; } 14223 if ${ac_cv_path_SED+:} false; then : 14224 $as_echo_n "(cached) " >&6 14225 else 14226 case $SED in 14227 [\\/]* | ?:[\\/]*) 14228 ac_cv_path_SED="$SED" # Let the user override the test with a path. 14229 ;; 14230 *) 14231 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 14232 for as_dir in $PATH 14233 do 14234 IFS=$as_save_IFS 14235 test -z "$as_dir" && as_dir=. 14236 for ac_exec_ext in '' $ac_executable_extensions; do 14237 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 14238 ac_cv_path_SED="$as_dir/$ac_word$ac_exec_ext" 14239 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 14240 break 2 14241 fi 14242 done 14243 done 14244 IFS=$as_save_IFS 14245 14246 ;; 14247 esac 14248 fi 14249 SED=$ac_cv_path_SED 14250 if test -n "$SED"; then 14251 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $SED" >&5 14252 $as_echo "$SED" >&6; } 14253 else 14254 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 14255 $as_echo "no" >&6; } 14256 fi 14257 14258 14259 if test "x$SED" = x; then 14260 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 14261 fi 14262 else 14263 # Otherwise we believe it is a complete path. Use it as it is. 14264 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool SED=$tool_specified" >&5 14265 $as_echo "$as_me: Will use user supplied tool SED=$tool_specified" >&6;} 14266 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for SED" >&5 14267 $as_echo_n "checking for SED... " >&6; } 14268 if test ! -x "$tool_specified"; then 14269 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 14270 $as_echo "not found" >&6; } 14271 as_fn_error $? "User supplied tool SED=$tool_specified does not exist or is not executable" "$LINENO" 5 14272 fi 14273 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 14274 $as_echo "$tool_specified" >&6; } 14275 fi 14276 fi 14277 fi 14278 14279 fi 14280 14281 14282 if test "x$SED" = x; then 14283 as_fn_error $? "Could not find required tool for SED" "$LINENO" 5 14284 fi 14285 14286 14287 14288 # Always force rm. 14289 RM="$RM -f" 14290 14291 # pwd behaves differently on various platforms and some don't support the -L flag. 14292 # Always use the bash builtin pwd to get uniform behavior. 14293 THEPWDCMD=pwd 14294 14295 # These are not required on all platforms 14296 14297 14298 # Publish this variable in the help. 14299 14300 14301 if [ -z "${CYGPATH+x}" ]; then 14302 # The variable is not set by user, try to locate tool using the code snippet 14303 for ac_prog in cygpath 14304 do 14305 # Extract the first word of "$ac_prog", so it can be a program name with args. 14306 set dummy $ac_prog; ac_word=$2 14307 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 14308 $as_echo_n "checking for $ac_word... " >&6; } 14309 if ${ac_cv_path_CYGPATH+:} false; then : 14310 $as_echo_n "(cached) " >&6 14311 else 14312 case $CYGPATH in 14313 [\\/]* | ?:[\\/]*) 14314 ac_cv_path_CYGPATH="$CYGPATH" # Let the user override the test with a path. 14315 ;; 14316 *) 14317 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 14318 for as_dir in $PATH 14319 do 14320 IFS=$as_save_IFS 14321 test -z "$as_dir" && as_dir=. 14322 for ac_exec_ext in '' $ac_executable_extensions; do 14323 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 14324 ac_cv_path_CYGPATH="$as_dir/$ac_word$ac_exec_ext" 14325 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 14326 break 2 14327 fi 14328 done 14329 done 14330 IFS=$as_save_IFS 14331 14332 ;; 14333 esac 14334 fi 14335 CYGPATH=$ac_cv_path_CYGPATH 14336 if test -n "$CYGPATH"; then 14337 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CYGPATH" >&5 14338 $as_echo "$CYGPATH" >&6; } 14339 else 14340 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 14341 $as_echo "no" >&6; } 14342 fi 14343 14344 14345 test -n "$CYGPATH" && break 14346 done 14347 14348 else 14349 # The variable is set, but is it from the command line or the environment? 14350 14351 # Try to remove the string !CYGPATH! from our list. 14352 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!CYGPATH!/} 14353 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 14354 # If it failed, the variable was not from the command line. Ignore it, 14355 # but warn the user (except for BASH, which is always set by the calling BASH). 14356 if test "xCYGPATH" != xBASH; then 14357 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of CYGPATH from the environment. Use command line variables instead." >&5 14358 $as_echo "$as_me: WARNING: Ignoring value of CYGPATH from the environment. Use command line variables instead." >&2;} 14359 fi 14360 # Try to locate tool using the code snippet 14361 for ac_prog in cygpath 14362 do 14363 # Extract the first word of "$ac_prog", so it can be a program name with args. 14364 set dummy $ac_prog; ac_word=$2 14365 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 14366 $as_echo_n "checking for $ac_word... " >&6; } 14367 if ${ac_cv_path_CYGPATH+:} false; then : 14368 $as_echo_n "(cached) " >&6 14369 else 14370 case $CYGPATH in 14371 [\\/]* | ?:[\\/]*) 14372 ac_cv_path_CYGPATH="$CYGPATH" # Let the user override the test with a path. 14373 ;; 14374 *) 14375 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 14376 for as_dir in $PATH 14377 do 14378 IFS=$as_save_IFS 14379 test -z "$as_dir" && as_dir=. 14380 for ac_exec_ext in '' $ac_executable_extensions; do 14381 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 14382 ac_cv_path_CYGPATH="$as_dir/$ac_word$ac_exec_ext" 14383 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 14384 break 2 14385 fi 14386 done 14387 done 14388 IFS=$as_save_IFS 14389 14390 ;; 14391 esac 14392 fi 14393 CYGPATH=$ac_cv_path_CYGPATH 14394 if test -n "$CYGPATH"; then 14395 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CYGPATH" >&5 14396 $as_echo "$CYGPATH" >&6; } 14397 else 14398 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 14399 $as_echo "no" >&6; } 14400 fi 14401 14402 14403 test -n "$CYGPATH" && break 14404 done 14405 14406 else 14407 # If it succeeded, then it was overridden by the user. We will use it 14408 # for the tool. 14409 14410 # First remove it from the list of overridden variables, so we can test 14411 # for unknown variables in the end. 14412 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 14413 14414 # Check if we try to supply an empty value 14415 if test "x$CYGPATH" = x; then 14416 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool CYGPATH= (no value)" >&5 14417 $as_echo "$as_me: Setting user supplied tool CYGPATH= (no value)" >&6;} 14418 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for CYGPATH" >&5 14419 $as_echo_n "checking for CYGPATH... " >&6; } 14420 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 14421 $as_echo "disabled" >&6; } 14422 else 14423 # Check if the provided tool contains a complete path. 14424 tool_specified="$CYGPATH" 14425 tool_basename="${tool_specified##*/}" 14426 if test "x$tool_basename" = "x$tool_specified"; then 14427 # A command without a complete path is provided, search $PATH. 14428 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool CYGPATH=$tool_basename" >&5 14429 $as_echo "$as_me: Will search for user supplied tool CYGPATH=$tool_basename" >&6;} 14430 # Extract the first word of "$tool_basename", so it can be a program name with args. 14431 set dummy $tool_basename; ac_word=$2 14432 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 14433 $as_echo_n "checking for $ac_word... " >&6; } 14434 if ${ac_cv_path_CYGPATH+:} false; then : 14435 $as_echo_n "(cached) " >&6 14436 else 14437 case $CYGPATH in 14438 [\\/]* | ?:[\\/]*) 14439 ac_cv_path_CYGPATH="$CYGPATH" # Let the user override the test with a path. 14440 ;; 14441 *) 14442 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 14443 for as_dir in $PATH 14444 do 14445 IFS=$as_save_IFS 14446 test -z "$as_dir" && as_dir=. 14447 for ac_exec_ext in '' $ac_executable_extensions; do 14448 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 14449 ac_cv_path_CYGPATH="$as_dir/$ac_word$ac_exec_ext" 14450 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 14451 break 2 14452 fi 14453 done 14454 done 14455 IFS=$as_save_IFS 14456 14457 ;; 14458 esac 14459 fi 14460 CYGPATH=$ac_cv_path_CYGPATH 14461 if test -n "$CYGPATH"; then 14462 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CYGPATH" >&5 14463 $as_echo "$CYGPATH" >&6; } 14464 else 14465 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 14466 $as_echo "no" >&6; } 14467 fi 14468 14469 14470 if test "x$CYGPATH" = x; then 14471 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 14472 fi 14473 else 14474 # Otherwise we believe it is a complete path. Use it as it is. 14475 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool CYGPATH=$tool_specified" >&5 14476 $as_echo "$as_me: Will use user supplied tool CYGPATH=$tool_specified" >&6;} 14477 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for CYGPATH" >&5 14478 $as_echo_n "checking for CYGPATH... " >&6; } 14479 if test ! -x "$tool_specified"; then 14480 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 14481 $as_echo "not found" >&6; } 14482 as_fn_error $? "User supplied tool CYGPATH=$tool_specified does not exist or is not executable" "$LINENO" 5 14483 fi 14484 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 14485 $as_echo "$tool_specified" >&6; } 14486 fi 14487 fi 14488 fi 14489 14490 fi 14491 14492 14493 14494 14495 # Publish this variable in the help. 14496 14497 14498 if [ -z "${READLINK+x}" ]; then 14499 # The variable is not set by user, try to locate tool using the code snippet 14500 for ac_prog in greadlink readlink 14501 do 14502 # Extract the first word of "$ac_prog", so it can be a program name with args. 14503 set dummy $ac_prog; ac_word=$2 14504 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 14505 $as_echo_n "checking for $ac_word... " >&6; } 14506 if ${ac_cv_path_READLINK+:} false; then : 14507 $as_echo_n "(cached) " >&6 14508 else 14509 case $READLINK in 14510 [\\/]* | ?:[\\/]*) 14511 ac_cv_path_READLINK="$READLINK" # Let the user override the test with a path. 14512 ;; 14513 *) 14514 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 14515 for as_dir in $PATH 14516 do 14517 IFS=$as_save_IFS 14518 test -z "$as_dir" && as_dir=. 14519 for ac_exec_ext in '' $ac_executable_extensions; do 14520 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 14521 ac_cv_path_READLINK="$as_dir/$ac_word$ac_exec_ext" 14522 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 14523 break 2 14524 fi 14525 done 14526 done 14527 IFS=$as_save_IFS 14528 14529 ;; 14530 esac 14531 fi 14532 READLINK=$ac_cv_path_READLINK 14533 if test -n "$READLINK"; then 14534 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $READLINK" >&5 14535 $as_echo "$READLINK" >&6; } 14536 else 14537 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 14538 $as_echo "no" >&6; } 14539 fi 14540 14541 14542 test -n "$READLINK" && break 14543 done 14544 14545 else 14546 # The variable is set, but is it from the command line or the environment? 14547 14548 # Try to remove the string !READLINK! from our list. 14549 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!READLINK!/} 14550 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 14551 # If it failed, the variable was not from the command line. Ignore it, 14552 # but warn the user (except for BASH, which is always set by the calling BASH). 14553 if test "xREADLINK" != xBASH; then 14554 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of READLINK from the environment. Use command line variables instead." >&5 14555 $as_echo "$as_me: WARNING: Ignoring value of READLINK from the environment. Use command line variables instead." >&2;} 14556 fi 14557 # Try to locate tool using the code snippet 14558 for ac_prog in greadlink readlink 14559 do 14560 # Extract the first word of "$ac_prog", so it can be a program name with args. 14561 set dummy $ac_prog; ac_word=$2 14562 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 14563 $as_echo_n "checking for $ac_word... " >&6; } 14564 if ${ac_cv_path_READLINK+:} false; then : 14565 $as_echo_n "(cached) " >&6 14566 else 14567 case $READLINK in 14568 [\\/]* | ?:[\\/]*) 14569 ac_cv_path_READLINK="$READLINK" # Let the user override the test with a path. 14570 ;; 14571 *) 14572 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 14573 for as_dir in $PATH 14574 do 14575 IFS=$as_save_IFS 14576 test -z "$as_dir" && as_dir=. 14577 for ac_exec_ext in '' $ac_executable_extensions; do 14578 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 14579 ac_cv_path_READLINK="$as_dir/$ac_word$ac_exec_ext" 14580 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 14581 break 2 14582 fi 14583 done 14584 done 14585 IFS=$as_save_IFS 14586 14587 ;; 14588 esac 14589 fi 14590 READLINK=$ac_cv_path_READLINK 14591 if test -n "$READLINK"; then 14592 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $READLINK" >&5 14593 $as_echo "$READLINK" >&6; } 14594 else 14595 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 14596 $as_echo "no" >&6; } 14597 fi 14598 14599 14600 test -n "$READLINK" && break 14601 done 14602 14603 else 14604 # If it succeeded, then it was overridden by the user. We will use it 14605 # for the tool. 14606 14607 # First remove it from the list of overridden variables, so we can test 14608 # for unknown variables in the end. 14609 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 14610 14611 # Check if we try to supply an empty value 14612 if test "x$READLINK" = x; then 14613 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool READLINK= (no value)" >&5 14614 $as_echo "$as_me: Setting user supplied tool READLINK= (no value)" >&6;} 14615 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for READLINK" >&5 14616 $as_echo_n "checking for READLINK... " >&6; } 14617 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 14618 $as_echo "disabled" >&6; } 14619 else 14620 # Check if the provided tool contains a complete path. 14621 tool_specified="$READLINK" 14622 tool_basename="${tool_specified##*/}" 14623 if test "x$tool_basename" = "x$tool_specified"; then 14624 # A command without a complete path is provided, search $PATH. 14625 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool READLINK=$tool_basename" >&5 14626 $as_echo "$as_me: Will search for user supplied tool READLINK=$tool_basename" >&6;} 14627 # Extract the first word of "$tool_basename", so it can be a program name with args. 14628 set dummy $tool_basename; ac_word=$2 14629 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 14630 $as_echo_n "checking for $ac_word... " >&6; } 14631 if ${ac_cv_path_READLINK+:} false; then : 14632 $as_echo_n "(cached) " >&6 14633 else 14634 case $READLINK in 14635 [\\/]* | ?:[\\/]*) 14636 ac_cv_path_READLINK="$READLINK" # Let the user override the test with a path. 14637 ;; 14638 *) 14639 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 14640 for as_dir in $PATH 14641 do 14642 IFS=$as_save_IFS 14643 test -z "$as_dir" && as_dir=. 14644 for ac_exec_ext in '' $ac_executable_extensions; do 14645 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 14646 ac_cv_path_READLINK="$as_dir/$ac_word$ac_exec_ext" 14647 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 14648 break 2 14649 fi 14650 done 14651 done 14652 IFS=$as_save_IFS 14653 14654 ;; 14655 esac 14656 fi 14657 READLINK=$ac_cv_path_READLINK 14658 if test -n "$READLINK"; then 14659 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $READLINK" >&5 14660 $as_echo "$READLINK" >&6; } 14661 else 14662 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 14663 $as_echo "no" >&6; } 14664 fi 14665 14666 14667 if test "x$READLINK" = x; then 14668 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 14669 fi 14670 else 14671 # Otherwise we believe it is a complete path. Use it as it is. 14672 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool READLINK=$tool_specified" >&5 14673 $as_echo "$as_me: Will use user supplied tool READLINK=$tool_specified" >&6;} 14674 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for READLINK" >&5 14675 $as_echo_n "checking for READLINK... " >&6; } 14676 if test ! -x "$tool_specified"; then 14677 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 14678 $as_echo "not found" >&6; } 14679 as_fn_error $? "User supplied tool READLINK=$tool_specified does not exist or is not executable" "$LINENO" 5 14680 fi 14681 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 14682 $as_echo "$tool_specified" >&6; } 14683 fi 14684 fi 14685 fi 14686 14687 fi 14688 14689 14690 14691 14692 # Publish this variable in the help. 14693 14694 14695 if [ -z "${DF+x}" ]; then 14696 # The variable is not set by user, try to locate tool using the code snippet 14697 for ac_prog in df 14698 do 14699 # Extract the first word of "$ac_prog", so it can be a program name with args. 14700 set dummy $ac_prog; ac_word=$2 14701 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 14702 $as_echo_n "checking for $ac_word... " >&6; } 14703 if ${ac_cv_path_DF+:} false; then : 14704 $as_echo_n "(cached) " >&6 14705 else 14706 case $DF in 14707 [\\/]* | ?:[\\/]*) 14708 ac_cv_path_DF="$DF" # Let the user override the test with a path. 14709 ;; 14710 *) 14711 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 14712 for as_dir in $PATH 14713 do 14714 IFS=$as_save_IFS 14715 test -z "$as_dir" && as_dir=. 14716 for ac_exec_ext in '' $ac_executable_extensions; do 14717 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 14718 ac_cv_path_DF="$as_dir/$ac_word$ac_exec_ext" 14719 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 14720 break 2 14721 fi 14722 done 14723 done 14724 IFS=$as_save_IFS 14725 14726 ;; 14727 esac 14728 fi 14729 DF=$ac_cv_path_DF 14730 if test -n "$DF"; then 14731 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $DF" >&5 14732 $as_echo "$DF" >&6; } 14733 else 14734 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 14735 $as_echo "no" >&6; } 14736 fi 14737 14738 14739 test -n "$DF" && break 14740 done 14741 14742 else 14743 # The variable is set, but is it from the command line or the environment? 14744 14745 # Try to remove the string !DF! from our list. 14746 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!DF!/} 14747 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 14748 # If it failed, the variable was not from the command line. Ignore it, 14749 # but warn the user (except for BASH, which is always set by the calling BASH). 14750 if test "xDF" != xBASH; then 14751 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of DF from the environment. Use command line variables instead." >&5 14752 $as_echo "$as_me: WARNING: Ignoring value of DF from the environment. Use command line variables instead." >&2;} 14753 fi 14754 # Try to locate tool using the code snippet 14755 for ac_prog in df 14756 do 14757 # Extract the first word of "$ac_prog", so it can be a program name with args. 14758 set dummy $ac_prog; ac_word=$2 14759 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 14760 $as_echo_n "checking for $ac_word... " >&6; } 14761 if ${ac_cv_path_DF+:} false; then : 14762 $as_echo_n "(cached) " >&6 14763 else 14764 case $DF in 14765 [\\/]* | ?:[\\/]*) 14766 ac_cv_path_DF="$DF" # Let the user override the test with a path. 14767 ;; 14768 *) 14769 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 14770 for as_dir in $PATH 14771 do 14772 IFS=$as_save_IFS 14773 test -z "$as_dir" && as_dir=. 14774 for ac_exec_ext in '' $ac_executable_extensions; do 14775 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 14776 ac_cv_path_DF="$as_dir/$ac_word$ac_exec_ext" 14777 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 14778 break 2 14779 fi 14780 done 14781 done 14782 IFS=$as_save_IFS 14783 14784 ;; 14785 esac 14786 fi 14787 DF=$ac_cv_path_DF 14788 if test -n "$DF"; then 14789 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $DF" >&5 14790 $as_echo "$DF" >&6; } 14791 else 14792 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 14793 $as_echo "no" >&6; } 14794 fi 14795 14796 14797 test -n "$DF" && break 14798 done 14799 14800 else 14801 # If it succeeded, then it was overridden by the user. We will use it 14802 # for the tool. 14803 14804 # First remove it from the list of overridden variables, so we can test 14805 # for unknown variables in the end. 14806 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 14807 14808 # Check if we try to supply an empty value 14809 if test "x$DF" = x; then 14810 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool DF= (no value)" >&5 14811 $as_echo "$as_me: Setting user supplied tool DF= (no value)" >&6;} 14812 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for DF" >&5 14813 $as_echo_n "checking for DF... " >&6; } 14814 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 14815 $as_echo "disabled" >&6; } 14816 else 14817 # Check if the provided tool contains a complete path. 14818 tool_specified="$DF" 14819 tool_basename="${tool_specified##*/}" 14820 if test "x$tool_basename" = "x$tool_specified"; then 14821 # A command without a complete path is provided, search $PATH. 14822 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool DF=$tool_basename" >&5 14823 $as_echo "$as_me: Will search for user supplied tool DF=$tool_basename" >&6;} 14824 # Extract the first word of "$tool_basename", so it can be a program name with args. 14825 set dummy $tool_basename; ac_word=$2 14826 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 14827 $as_echo_n "checking for $ac_word... " >&6; } 14828 if ${ac_cv_path_DF+:} false; then : 14829 $as_echo_n "(cached) " >&6 14830 else 14831 case $DF in 14832 [\\/]* | ?:[\\/]*) 14833 ac_cv_path_DF="$DF" # Let the user override the test with a path. 14834 ;; 14835 *) 14836 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 14837 for as_dir in $PATH 14838 do 14839 IFS=$as_save_IFS 14840 test -z "$as_dir" && as_dir=. 14841 for ac_exec_ext in '' $ac_executable_extensions; do 14842 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 14843 ac_cv_path_DF="$as_dir/$ac_word$ac_exec_ext" 14844 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 14845 break 2 14846 fi 14847 done 14848 done 14849 IFS=$as_save_IFS 14850 14851 ;; 14852 esac 14853 fi 14854 DF=$ac_cv_path_DF 14855 if test -n "$DF"; then 14856 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $DF" >&5 14857 $as_echo "$DF" >&6; } 14858 else 14859 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 14860 $as_echo "no" >&6; } 14861 fi 14862 14863 14864 if test "x$DF" = x; then 14865 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 14866 fi 14867 else 14868 # Otherwise we believe it is a complete path. Use it as it is. 14869 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool DF=$tool_specified" >&5 14870 $as_echo "$as_me: Will use user supplied tool DF=$tool_specified" >&6;} 14871 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for DF" >&5 14872 $as_echo_n "checking for DF... " >&6; } 14873 if test ! -x "$tool_specified"; then 14874 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 14875 $as_echo "not found" >&6; } 14876 as_fn_error $? "User supplied tool DF=$tool_specified does not exist or is not executable" "$LINENO" 5 14877 fi 14878 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 14879 $as_echo "$tool_specified" >&6; } 14880 fi 14881 fi 14882 fi 14883 14884 fi 14885 14886 14887 14888 14889 # Publish this variable in the help. 14890 14891 14892 if [ -z "${CPIO+x}" ]; then 14893 # The variable is not set by user, try to locate tool using the code snippet 14894 for ac_prog in cpio bsdcpio 14895 do 14896 # Extract the first word of "$ac_prog", so it can be a program name with args. 14897 set dummy $ac_prog; ac_word=$2 14898 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 14899 $as_echo_n "checking for $ac_word... " >&6; } 14900 if ${ac_cv_path_CPIO+:} false; then : 14901 $as_echo_n "(cached) " >&6 14902 else 14903 case $CPIO in 14904 [\\/]* | ?:[\\/]*) 14905 ac_cv_path_CPIO="$CPIO" # Let the user override the test with a path. 14906 ;; 14907 *) 14908 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 14909 for as_dir in $PATH 14910 do 14911 IFS=$as_save_IFS 14912 test -z "$as_dir" && as_dir=. 14913 for ac_exec_ext in '' $ac_executable_extensions; do 14914 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 14915 ac_cv_path_CPIO="$as_dir/$ac_word$ac_exec_ext" 14916 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 14917 break 2 14918 fi 14919 done 14920 done 14921 IFS=$as_save_IFS 14922 14923 ;; 14924 esac 14925 fi 14926 CPIO=$ac_cv_path_CPIO 14927 if test -n "$CPIO"; then 14928 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CPIO" >&5 14929 $as_echo "$CPIO" >&6; } 14930 else 14931 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 14932 $as_echo "no" >&6; } 14933 fi 14934 14935 14936 test -n "$CPIO" && break 14937 done 14938 14939 else 14940 # The variable is set, but is it from the command line or the environment? 14941 14942 # Try to remove the string !CPIO! from our list. 14943 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!CPIO!/} 14944 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 14945 # If it failed, the variable was not from the command line. Ignore it, 14946 # but warn the user (except for BASH, which is always set by the calling BASH). 14947 if test "xCPIO" != xBASH; then 14948 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of CPIO from the environment. Use command line variables instead." >&5 14949 $as_echo "$as_me: WARNING: Ignoring value of CPIO from the environment. Use command line variables instead." >&2;} 14950 fi 14951 # Try to locate tool using the code snippet 14952 for ac_prog in cpio bsdcpio 14953 do 14954 # Extract the first word of "$ac_prog", so it can be a program name with args. 14955 set dummy $ac_prog; ac_word=$2 14956 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 14957 $as_echo_n "checking for $ac_word... " >&6; } 14958 if ${ac_cv_path_CPIO+:} false; then : 14959 $as_echo_n "(cached) " >&6 14960 else 14961 case $CPIO in 14962 [\\/]* | ?:[\\/]*) 14963 ac_cv_path_CPIO="$CPIO" # Let the user override the test with a path. 14964 ;; 14965 *) 14966 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 14967 for as_dir in $PATH 14968 do 14969 IFS=$as_save_IFS 14970 test -z "$as_dir" && as_dir=. 14971 for ac_exec_ext in '' $ac_executable_extensions; do 14972 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 14973 ac_cv_path_CPIO="$as_dir/$ac_word$ac_exec_ext" 14974 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 14975 break 2 14976 fi 14977 done 14978 done 14979 IFS=$as_save_IFS 14980 14981 ;; 14982 esac 14983 fi 14984 CPIO=$ac_cv_path_CPIO 14985 if test -n "$CPIO"; then 14986 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CPIO" >&5 14987 $as_echo "$CPIO" >&6; } 14988 else 14989 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 14990 $as_echo "no" >&6; } 14991 fi 14992 14993 14994 test -n "$CPIO" && break 14995 done 14996 14997 else 14998 # If it succeeded, then it was overridden by the user. We will use it 14999 # for the tool. 15000 15001 # First remove it from the list of overridden variables, so we can test 15002 # for unknown variables in the end. 15003 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 15004 15005 # Check if we try to supply an empty value 15006 if test "x$CPIO" = x; then 15007 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool CPIO= (no value)" >&5 15008 $as_echo "$as_me: Setting user supplied tool CPIO= (no value)" >&6;} 15009 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for CPIO" >&5 15010 $as_echo_n "checking for CPIO... " >&6; } 15011 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 15012 $as_echo "disabled" >&6; } 15013 else 15014 # Check if the provided tool contains a complete path. 15015 tool_specified="$CPIO" 15016 tool_basename="${tool_specified##*/}" 15017 if test "x$tool_basename" = "x$tool_specified"; then 15018 # A command without a complete path is provided, search $PATH. 15019 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool CPIO=$tool_basename" >&5 15020 $as_echo "$as_me: Will search for user supplied tool CPIO=$tool_basename" >&6;} 15021 # Extract the first word of "$tool_basename", so it can be a program name with args. 15022 set dummy $tool_basename; ac_word=$2 15023 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 15024 $as_echo_n "checking for $ac_word... " >&6; } 15025 if ${ac_cv_path_CPIO+:} false; then : 15026 $as_echo_n "(cached) " >&6 15027 else 15028 case $CPIO in 15029 [\\/]* | ?:[\\/]*) 15030 ac_cv_path_CPIO="$CPIO" # Let the user override the test with a path. 15031 ;; 15032 *) 15033 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 15034 for as_dir in $PATH 15035 do 15036 IFS=$as_save_IFS 15037 test -z "$as_dir" && as_dir=. 15038 for ac_exec_ext in '' $ac_executable_extensions; do 15039 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 15040 ac_cv_path_CPIO="$as_dir/$ac_word$ac_exec_ext" 15041 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 15042 break 2 15043 fi 15044 done 15045 done 15046 IFS=$as_save_IFS 15047 15048 ;; 15049 esac 15050 fi 15051 CPIO=$ac_cv_path_CPIO 15052 if test -n "$CPIO"; then 15053 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CPIO" >&5 15054 $as_echo "$CPIO" >&6; } 15055 else 15056 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 15057 $as_echo "no" >&6; } 15058 fi 15059 15060 15061 if test "x$CPIO" = x; then 15062 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 15063 fi 15064 else 15065 # Otherwise we believe it is a complete path. Use it as it is. 15066 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool CPIO=$tool_specified" >&5 15067 $as_echo "$as_me: Will use user supplied tool CPIO=$tool_specified" >&6;} 15068 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for CPIO" >&5 15069 $as_echo_n "checking for CPIO... " >&6; } 15070 if test ! -x "$tool_specified"; then 15071 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 15072 $as_echo "not found" >&6; } 15073 as_fn_error $? "User supplied tool CPIO=$tool_specified does not exist or is not executable" "$LINENO" 5 15074 fi 15075 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 15076 $as_echo "$tool_specified" >&6; } 15077 fi 15078 fi 15079 fi 15080 15081 fi 15082 15083 15084 15085 15086 # Publish this variable in the help. 15087 15088 15089 if [ -z "${NICE+x}" ]; then 15090 # The variable is not set by user, try to locate tool using the code snippet 15091 for ac_prog in nice 15092 do 15093 # Extract the first word of "$ac_prog", so it can be a program name with args. 15094 set dummy $ac_prog; ac_word=$2 15095 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 15096 $as_echo_n "checking for $ac_word... " >&6; } 15097 if ${ac_cv_path_NICE+:} false; then : 15098 $as_echo_n "(cached) " >&6 15099 else 15100 case $NICE in 15101 [\\/]* | ?:[\\/]*) 15102 ac_cv_path_NICE="$NICE" # Let the user override the test with a path. 15103 ;; 15104 *) 15105 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 15106 for as_dir in $PATH 15107 do 15108 IFS=$as_save_IFS 15109 test -z "$as_dir" && as_dir=. 15110 for ac_exec_ext in '' $ac_executable_extensions; do 15111 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 15112 ac_cv_path_NICE="$as_dir/$ac_word$ac_exec_ext" 15113 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 15114 break 2 15115 fi 15116 done 15117 done 15118 IFS=$as_save_IFS 15119 15120 ;; 15121 esac 15122 fi 15123 NICE=$ac_cv_path_NICE 15124 if test -n "$NICE"; then 15125 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $NICE" >&5 15126 $as_echo "$NICE" >&6; } 15127 else 15128 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 15129 $as_echo "no" >&6; } 15130 fi 15131 15132 15133 test -n "$NICE" && break 15134 done 15135 15136 else 15137 # The variable is set, but is it from the command line or the environment? 15138 15139 # Try to remove the string !NICE! from our list. 15140 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!NICE!/} 15141 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 15142 # If it failed, the variable was not from the command line. Ignore it, 15143 # but warn the user (except for BASH, which is always set by the calling BASH). 15144 if test "xNICE" != xBASH; then 15145 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of NICE from the environment. Use command line variables instead." >&5 15146 $as_echo "$as_me: WARNING: Ignoring value of NICE from the environment. Use command line variables instead." >&2;} 15147 fi 15148 # Try to locate tool using the code snippet 15149 for ac_prog in nice 15150 do 15151 # Extract the first word of "$ac_prog", so it can be a program name with args. 15152 set dummy $ac_prog; ac_word=$2 15153 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 15154 $as_echo_n "checking for $ac_word... " >&6; } 15155 if ${ac_cv_path_NICE+:} false; then : 15156 $as_echo_n "(cached) " >&6 15157 else 15158 case $NICE in 15159 [\\/]* | ?:[\\/]*) 15160 ac_cv_path_NICE="$NICE" # Let the user override the test with a path. 15161 ;; 15162 *) 15163 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 15164 for as_dir in $PATH 15165 do 15166 IFS=$as_save_IFS 15167 test -z "$as_dir" && as_dir=. 15168 for ac_exec_ext in '' $ac_executable_extensions; do 15169 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 15170 ac_cv_path_NICE="$as_dir/$ac_word$ac_exec_ext" 15171 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 15172 break 2 15173 fi 15174 done 15175 done 15176 IFS=$as_save_IFS 15177 15178 ;; 15179 esac 15180 fi 15181 NICE=$ac_cv_path_NICE 15182 if test -n "$NICE"; then 15183 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $NICE" >&5 15184 $as_echo "$NICE" >&6; } 15185 else 15186 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 15187 $as_echo "no" >&6; } 15188 fi 15189 15190 15191 test -n "$NICE" && break 15192 done 15193 15194 else 15195 # If it succeeded, then it was overridden by the user. We will use it 15196 # for the tool. 15197 15198 # First remove it from the list of overridden variables, so we can test 15199 # for unknown variables in the end. 15200 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 15201 15202 # Check if we try to supply an empty value 15203 if test "x$NICE" = x; then 15204 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool NICE= (no value)" >&5 15205 $as_echo "$as_me: Setting user supplied tool NICE= (no value)" >&6;} 15206 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for NICE" >&5 15207 $as_echo_n "checking for NICE... " >&6; } 15208 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 15209 $as_echo "disabled" >&6; } 15210 else 15211 # Check if the provided tool contains a complete path. 15212 tool_specified="$NICE" 15213 tool_basename="${tool_specified##*/}" 15214 if test "x$tool_basename" = "x$tool_specified"; then 15215 # A command without a complete path is provided, search $PATH. 15216 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool NICE=$tool_basename" >&5 15217 $as_echo "$as_me: Will search for user supplied tool NICE=$tool_basename" >&6;} 15218 # Extract the first word of "$tool_basename", so it can be a program name with args. 15219 set dummy $tool_basename; ac_word=$2 15220 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 15221 $as_echo_n "checking for $ac_word... " >&6; } 15222 if ${ac_cv_path_NICE+:} false; then : 15223 $as_echo_n "(cached) " >&6 15224 else 15225 case $NICE in 15226 [\\/]* | ?:[\\/]*) 15227 ac_cv_path_NICE="$NICE" # Let the user override the test with a path. 15228 ;; 15229 *) 15230 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 15231 for as_dir in $PATH 15232 do 15233 IFS=$as_save_IFS 15234 test -z "$as_dir" && as_dir=. 15235 for ac_exec_ext in '' $ac_executable_extensions; do 15236 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 15237 ac_cv_path_NICE="$as_dir/$ac_word$ac_exec_ext" 15238 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 15239 break 2 15240 fi 15241 done 15242 done 15243 IFS=$as_save_IFS 15244 15245 ;; 15246 esac 15247 fi 15248 NICE=$ac_cv_path_NICE 15249 if test -n "$NICE"; then 15250 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $NICE" >&5 15251 $as_echo "$NICE" >&6; } 15252 else 15253 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 15254 $as_echo "no" >&6; } 15255 fi 15256 15257 15258 if test "x$NICE" = x; then 15259 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 15260 fi 15261 else 15262 # Otherwise we believe it is a complete path. Use it as it is. 15263 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool NICE=$tool_specified" >&5 15264 $as_echo "$as_me: Will use user supplied tool NICE=$tool_specified" >&6;} 15265 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for NICE" >&5 15266 $as_echo_n "checking for NICE... " >&6; } 15267 if test ! -x "$tool_specified"; then 15268 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 15269 $as_echo "not found" >&6; } 15270 as_fn_error $? "User supplied tool NICE=$tool_specified does not exist or is not executable" "$LINENO" 5 15271 fi 15272 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 15273 $as_echo "$tool_specified" >&6; } 15274 fi 15275 fi 15276 fi 15277 15278 fi 15279 15280 15281 15282 15283 # Now we can determine OpenJDK build and target platforms. This is required to 15284 # have early on. 15285 # Make sure we can run config.sub. 15286 $SHELL "$ac_aux_dir/config.sub" sun4 >/dev/null 2>&1 || 15287 as_fn_error $? "cannot run $SHELL $ac_aux_dir/config.sub" "$LINENO" 5 15288 15289 { $as_echo "$as_me:${as_lineno-$LINENO}: checking build system type" >&5 15290 $as_echo_n "checking build system type... " >&6; } 15291 if ${ac_cv_build+:} false; then : 15292 $as_echo_n "(cached) " >&6 15293 else 15294 ac_build_alias=$build_alias 15295 test "x$ac_build_alias" = x && 15296 ac_build_alias=`$SHELL "$ac_aux_dir/config.guess"` 15297 test "x$ac_build_alias" = x && 15298 as_fn_error $? "cannot guess build type; you must specify one" "$LINENO" 5 15299 ac_cv_build=`$SHELL "$ac_aux_dir/config.sub" $ac_build_alias` || 15300 as_fn_error $? "$SHELL $ac_aux_dir/config.sub $ac_build_alias failed" "$LINENO" 5 15301 15302 fi 15303 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_build" >&5 15304 $as_echo "$ac_cv_build" >&6; } 15305 case $ac_cv_build in 15306 *-*-*) ;; 15307 *) as_fn_error $? "invalid value of canonical build" "$LINENO" 5;; 15308 esac 15309 build=$ac_cv_build 15310 ac_save_IFS=$IFS; IFS='-' 15311 set x $ac_cv_build 15312 shift 15313 build_cpu=$1 15314 build_vendor=$2 15315 shift; shift 15316 # Remember, the first character of IFS is used to create $*, 15317 # except with old shells: 15318 build_os=$* 15319 IFS=$ac_save_IFS 15320 case $build_os in *\ *) build_os=`echo "$build_os" | sed 's/ /-/g'`;; esac 15321 15322 15323 { $as_echo "$as_me:${as_lineno-$LINENO}: checking host system type" >&5 15324 $as_echo_n "checking host system type... " >&6; } 15325 if ${ac_cv_host+:} false; then : 15326 $as_echo_n "(cached) " >&6 15327 else 15328 if test "x$host_alias" = x; then 15329 ac_cv_host=$ac_cv_build 15330 else 15331 ac_cv_host=`$SHELL "$ac_aux_dir/config.sub" $host_alias` || 15332 as_fn_error $? "$SHELL $ac_aux_dir/config.sub $host_alias failed" "$LINENO" 5 15333 fi 15334 15335 fi 15336 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_host" >&5 15337 $as_echo "$ac_cv_host" >&6; } 15338 case $ac_cv_host in 15339 *-*-*) ;; 15340 *) as_fn_error $? "invalid value of canonical host" "$LINENO" 5;; 15341 esac 15342 host=$ac_cv_host 15343 ac_save_IFS=$IFS; IFS='-' 15344 set x $ac_cv_host 15345 shift 15346 host_cpu=$1 15347 host_vendor=$2 15348 shift; shift 15349 # Remember, the first character of IFS is used to create $*, 15350 # except with old shells: 15351 host_os=$* 15352 IFS=$ac_save_IFS 15353 case $host_os in *\ *) host_os=`echo "$host_os" | sed 's/ /-/g'`;; esac 15354 15355 15356 { $as_echo "$as_me:${as_lineno-$LINENO}: checking target system type" >&5 15357 $as_echo_n "checking target system type... " >&6; } 15358 if ${ac_cv_target+:} false; then : 15359 $as_echo_n "(cached) " >&6 15360 else 15361 if test "x$target_alias" = x; then 15362 ac_cv_target=$ac_cv_host 15363 else 15364 ac_cv_target=`$SHELL "$ac_aux_dir/config.sub" $target_alias` || 15365 as_fn_error $? "$SHELL $ac_aux_dir/config.sub $target_alias failed" "$LINENO" 5 15366 fi 15367 15368 fi 15369 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_target" >&5 15370 $as_echo "$ac_cv_target" >&6; } 15371 case $ac_cv_target in 15372 *-*-*) ;; 15373 *) as_fn_error $? "invalid value of canonical target" "$LINENO" 5;; 15374 esac 15375 target=$ac_cv_target 15376 ac_save_IFS=$IFS; IFS='-' 15377 set x $ac_cv_target 15378 shift 15379 target_cpu=$1 15380 target_vendor=$2 15381 shift; shift 15382 # Remember, the first character of IFS is used to create $*, 15383 # except with old shells: 15384 target_os=$* 15385 IFS=$ac_save_IFS 15386 case $target_os in *\ *) target_os=`echo "$target_os" | sed 's/ /-/g'`;; esac 15387 15388 15389 # The aliases save the names the user supplied, while $host etc. 15390 # will get canonicalized. 15391 test -n "$target_alias" && 15392 test "$program_prefix$program_suffix$program_transform_name" = \ 15393 NONENONEs,x,x, && 15394 program_prefix=${target_alias}- 15395 15396 # Figure out the build and target systems. # Note that in autoconf terminology, "build" is obvious, but "target" 15397 # is confusing; it assumes you are cross-compiling a cross-compiler (!) and "target" is thus the target of the 15398 # product you're building. The target of this build is called "host". Since this is confusing to most people, we 15399 # have not adopted that system, but use "target" as the platform we are building for. In some places though we need 15400 # to use the configure naming style. 15401 15402 15403 15404 15405 15406 # Copy the autoconf trip/quadruplet verbatim to OPENJDK_TARGET_AUTOCONF_NAME 15407 # (from the autoconf "host") and OPENJDK_BUILD_AUTOCONF_NAME 15408 # Note that we might later on rewrite e.g. OPENJDK_TARGET_CPU due to reduced build, 15409 # but this will not change the value of OPENJDK_TARGET_AUTOCONF_NAME. 15410 OPENJDK_TARGET_AUTOCONF_NAME="$host" 15411 OPENJDK_BUILD_AUTOCONF_NAME="$build" 15412 15413 15414 15415 # Convert the autoconf OS/CPU value to our own data, into the VAR_OS/CPU variables. 15416 15417 case "$build_os" in 15418 *linux*) 15419 VAR_OS=linux 15420 VAR_OS_TYPE=unix 15421 ;; 15422 *solaris*) 15423 VAR_OS=solaris 15424 VAR_OS_TYPE=unix 15425 ;; 15426 *darwin*) 15427 VAR_OS=macosx 15428 VAR_OS_TYPE=unix 15429 ;; 15430 *bsd*) 15431 VAR_OS=bsd 15432 VAR_OS_TYPE=unix 15433 ;; 15434 *cygwin*) 15435 VAR_OS=windows 15436 VAR_OS_ENV=windows.cygwin 15437 ;; 15438 *mingw*) 15439 VAR_OS=windows 15440 VAR_OS_ENV=windows.msys 15441 ;; 15442 *aix*) 15443 VAR_OS=aix 15444 VAR_OS_TYPE=unix 15445 ;; 15446 *) 15447 as_fn_error $? "unsupported operating system $build_os" "$LINENO" 5 15448 ;; 15449 esac 15450 15451 15452 # First argument is the cpu name from the trip/quad 15453 case "$build_cpu" in 15454 x86_64) 15455 VAR_CPU=x86_64 15456 VAR_CPU_ARCH=x86 15457 VAR_CPU_BITS=64 15458 VAR_CPU_ENDIAN=little 15459 ;; 15460 i?86) 15461 VAR_CPU=x86 15462 VAR_CPU_ARCH=x86 15463 VAR_CPU_BITS=32 15464 VAR_CPU_ENDIAN=little 15465 ;; 15466 arm*) 15467 VAR_CPU=arm 15468 VAR_CPU_ARCH=arm 15469 VAR_CPU_BITS=32 15470 VAR_CPU_ENDIAN=little 15471 ;; 15472 aarch64) 15473 VAR_CPU=aarch64 15474 VAR_CPU_ARCH=aarch64 15475 VAR_CPU_BITS=64 15476 VAR_CPU_ENDIAN=little 15477 ;; 15478 powerpc) 15479 VAR_CPU=ppc 15480 VAR_CPU_ARCH=ppc 15481 VAR_CPU_BITS=32 15482 VAR_CPU_ENDIAN=big 15483 ;; 15484 powerpc64) 15485 VAR_CPU=ppc64 15486 VAR_CPU_ARCH=ppc 15487 VAR_CPU_BITS=64 15488 VAR_CPU_ENDIAN=big 15489 ;; 15490 powerpc64le) 15491 VAR_CPU=ppc64le 15492 VAR_CPU_ARCH=ppc 15493 VAR_CPU_BITS=64 15494 VAR_CPU_ENDIAN=little 15495 ;; 15496 s390) 15497 VAR_CPU=s390 15498 VAR_CPU_ARCH=s390 15499 VAR_CPU_BITS=32 15500 VAR_CPU_ENDIAN=big 15501 ;; 15502 s390x) 15503 VAR_CPU=s390x 15504 VAR_CPU_ARCH=s390 15505 VAR_CPU_BITS=64 15506 VAR_CPU_ENDIAN=big 15507 ;; 15508 sparc) 15509 VAR_CPU=sparc 15510 VAR_CPU_ARCH=sparc 15511 VAR_CPU_BITS=32 15512 VAR_CPU_ENDIAN=big 15513 ;; 15514 sparcv9|sparc64) 15515 VAR_CPU=sparcv9 15516 VAR_CPU_ARCH=sparc 15517 VAR_CPU_BITS=64 15518 VAR_CPU_ENDIAN=big 15519 ;; 15520 *) 15521 as_fn_error $? "unsupported cpu $build_cpu" "$LINENO" 5 15522 ;; 15523 esac 15524 15525 # ..and setup our own variables. (Do this explicitely to facilitate searching) 15526 OPENJDK_BUILD_OS="$VAR_OS" 15527 if test "x$VAR_OS_TYPE" != x; then 15528 OPENJDK_BUILD_OS_TYPE="$VAR_OS_TYPE" 15529 else 15530 OPENJDK_BUILD_OS_TYPE="$VAR_OS" 15531 fi 15532 if test "x$VAR_OS_ENV" != x; then 15533 OPENJDK_BUILD_OS_ENV="$VAR_OS_ENV" 15534 else 15535 OPENJDK_BUILD_OS_ENV="$VAR_OS" 15536 fi 15537 OPENJDK_BUILD_CPU="$VAR_CPU" 15538 OPENJDK_BUILD_CPU_ARCH="$VAR_CPU_ARCH" 15539 OPENJDK_BUILD_CPU_BITS="$VAR_CPU_BITS" 15540 OPENJDK_BUILD_CPU_ENDIAN="$VAR_CPU_ENDIAN" 15541 15542 15543 15544 15545 15546 15547 15548 15549 { $as_echo "$as_me:${as_lineno-$LINENO}: checking openjdk-build os-cpu" >&5 15550 $as_echo_n "checking openjdk-build os-cpu... " >&6; } 15551 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $OPENJDK_BUILD_OS-$OPENJDK_BUILD_CPU" >&5 15552 $as_echo "$OPENJDK_BUILD_OS-$OPENJDK_BUILD_CPU" >&6; } 15553 15554 # Convert the autoconf OS/CPU value to our own data, into the VAR_OS/CPU variables. 15555 15556 case "$host_os" in 15557 *linux*) 15558 VAR_OS=linux 15559 VAR_OS_TYPE=unix 15560 ;; 15561 *solaris*) 15562 VAR_OS=solaris 15563 VAR_OS_TYPE=unix 15564 ;; 15565 *darwin*) 15566 VAR_OS=macosx 15567 VAR_OS_TYPE=unix 15568 ;; 15569 *bsd*) 15570 VAR_OS=bsd 15571 VAR_OS_TYPE=unix 15572 ;; 15573 *cygwin*) 15574 VAR_OS=windows 15575 VAR_OS_ENV=windows.cygwin 15576 ;; 15577 *mingw*) 15578 VAR_OS=windows 15579 VAR_OS_ENV=windows.msys 15580 ;; 15581 *aix*) 15582 VAR_OS=aix 15583 VAR_OS_TYPE=unix 15584 ;; 15585 *) 15586 as_fn_error $? "unsupported operating system $host_os" "$LINENO" 5 15587 ;; 15588 esac 15589 15590 15591 # First argument is the cpu name from the trip/quad 15592 case "$host_cpu" in 15593 x86_64) 15594 VAR_CPU=x86_64 15595 VAR_CPU_ARCH=x86 15596 VAR_CPU_BITS=64 15597 VAR_CPU_ENDIAN=little 15598 ;; 15599 i?86) 15600 VAR_CPU=x86 15601 VAR_CPU_ARCH=x86 15602 VAR_CPU_BITS=32 15603 VAR_CPU_ENDIAN=little 15604 ;; 15605 arm*) 15606 VAR_CPU=arm 15607 VAR_CPU_ARCH=arm 15608 VAR_CPU_BITS=32 15609 VAR_CPU_ENDIAN=little 15610 ;; 15611 aarch64) 15612 VAR_CPU=aarch64 15613 VAR_CPU_ARCH=aarch64 15614 VAR_CPU_BITS=64 15615 VAR_CPU_ENDIAN=little 15616 ;; 15617 powerpc) 15618 VAR_CPU=ppc 15619 VAR_CPU_ARCH=ppc 15620 VAR_CPU_BITS=32 15621 VAR_CPU_ENDIAN=big 15622 ;; 15623 powerpc64) 15624 VAR_CPU=ppc64 15625 VAR_CPU_ARCH=ppc 15626 VAR_CPU_BITS=64 15627 VAR_CPU_ENDIAN=big 15628 ;; 15629 powerpc64le) 15630 VAR_CPU=ppc64le 15631 VAR_CPU_ARCH=ppc 15632 VAR_CPU_BITS=64 15633 VAR_CPU_ENDIAN=little 15634 ;; 15635 s390) 15636 VAR_CPU=s390 15637 VAR_CPU_ARCH=s390 15638 VAR_CPU_BITS=32 15639 VAR_CPU_ENDIAN=big 15640 ;; 15641 s390x) 15642 VAR_CPU=s390x 15643 VAR_CPU_ARCH=s390 15644 VAR_CPU_BITS=64 15645 VAR_CPU_ENDIAN=big 15646 ;; 15647 sparc) 15648 VAR_CPU=sparc 15649 VAR_CPU_ARCH=sparc 15650 VAR_CPU_BITS=32 15651 VAR_CPU_ENDIAN=big 15652 ;; 15653 sparcv9|sparc64) 15654 VAR_CPU=sparcv9 15655 VAR_CPU_ARCH=sparc 15656 VAR_CPU_BITS=64 15657 VAR_CPU_ENDIAN=big 15658 ;; 15659 *) 15660 as_fn_error $? "unsupported cpu $host_cpu" "$LINENO" 5 15661 ;; 15662 esac 15663 15664 # ... and setup our own variables. (Do this explicitely to facilitate searching) 15665 OPENJDK_TARGET_OS="$VAR_OS" 15666 if test "x$VAR_OS_TYPE" != x; then 15667 OPENJDK_TARGET_OS_TYPE="$VAR_OS_TYPE" 15668 else 15669 OPENJDK_TARGET_OS_TYPE="$VAR_OS" 15670 fi 15671 if test "x$VAR_OS_ENV" != x; then 15672 OPENJDK_TARGET_OS_ENV="$VAR_OS_ENV" 15673 else 15674 OPENJDK_TARGET_OS_ENV="$VAR_OS" 15675 fi 15676 OPENJDK_TARGET_CPU="$VAR_CPU" 15677 OPENJDK_TARGET_CPU_ARCH="$VAR_CPU_ARCH" 15678 OPENJDK_TARGET_CPU_BITS="$VAR_CPU_BITS" 15679 OPENJDK_TARGET_CPU_ENDIAN="$VAR_CPU_ENDIAN" 15680 15681 15682 15683 15684 15685 15686 15687 15688 { $as_echo "$as_me:${as_lineno-$LINENO}: checking openjdk-target os-cpu" >&5 15689 $as_echo_n "checking openjdk-target os-cpu... " >&6; } 15690 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $OPENJDK_TARGET_OS-$OPENJDK_TARGET_CPU" >&5 15691 $as_echo "$OPENJDK_TARGET_OS-$OPENJDK_TARGET_CPU" >&6; } 15692 15693 15694 15695 # Check whether --with-target-bits was given. 15696 if test "${with_target_bits+set}" = set; then : 15697 withval=$with_target_bits; 15698 fi 15699 15700 15701 # We have three types of compiles: 15702 # native == normal compilation, target system == build system 15703 # cross == traditional cross compilation, target system != build system; special toolchain needed 15704 # reduced == using native compilers, but with special flags (e.g. -m32) to produce 32-bit builds on 64-bit machines 15705 # 15706 if test "x$OPENJDK_BUILD_AUTOCONF_NAME" != "x$OPENJDK_TARGET_AUTOCONF_NAME"; then 15707 # We're doing a proper cross-compilation 15708 COMPILE_TYPE="cross" 15709 else 15710 COMPILE_TYPE="native" 15711 fi 15712 15713 if test "x$with_target_bits" != x; then 15714 if test "x$COMPILE_TYPE" = "xcross"; then 15715 as_fn_error $? "It is not possible to combine --with-target-bits=X and proper cross-compilation. Choose either." "$LINENO" 5 15716 fi 15717 15718 if test "x$with_target_bits" = x32 && test "x$OPENJDK_TARGET_CPU_BITS" = x64; then 15719 # A reduced build is requested 15720 COMPILE_TYPE="reduced" 15721 OPENJDK_TARGET_CPU_BITS=32 15722 if test "x$OPENJDK_TARGET_CPU_ARCH" = "xx86"; then 15723 OPENJDK_TARGET_CPU=x86 15724 elif test "x$OPENJDK_TARGET_CPU_ARCH" = "xsparc"; then 15725 OPENJDK_TARGET_CPU=sparc 15726 else 15727 as_fn_error $? "Reduced build (--with-target-bits=32) is only supported on x86_64 and sparcv9" "$LINENO" 5 15728 fi 15729 elif test "x$with_target_bits" = x64 && test "x$OPENJDK_TARGET_CPU_BITS" = x32; then 15730 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 15731 elif test "x$with_target_bits" = "x$OPENJDK_TARGET_CPU_BITS"; then 15732 { $as_echo "$as_me:${as_lineno-$LINENO}: --with-target-bits are set to build platform address size; argument has no meaning" >&5 15733 $as_echo "$as_me: --with-target-bits are set to build platform address size; argument has no meaning" >&6;} 15734 else 15735 as_fn_error $? "--with-target-bits can only be 32 or 64, you specified $with_target_bits!" "$LINENO" 5 15736 fi 15737 fi 15738 15739 15740 { $as_echo "$as_me:${as_lineno-$LINENO}: checking compilation type" >&5 15741 $as_echo_n "checking compilation type... " >&6; } 15742 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $COMPILE_TYPE" >&5 15743 $as_echo "$COMPILE_TYPE" >&6; } 15744 15745 15746 if test "x$OPENJDK_TARGET_OS" = "xsolaris"; then 15747 REQUIRED_OS_NAME=SunOS 15748 REQUIRED_OS_VERSION=5.10 15749 fi 15750 if test "x$OPENJDK_TARGET_OS" = "xlinux"; then 15751 REQUIRED_OS_NAME=Linux 15752 REQUIRED_OS_VERSION=2.6 15753 fi 15754 if test "x$OPENJDK_TARGET_OS" = "xwindows"; then 15755 REQUIRED_OS_NAME=Windows 15756 if test "x$OPENJDK_TARGET_CPU_BITS" = "x64"; then 15757 REQUIRED_OS_VERSION=5.2 15758 else 15759 REQUIRED_OS_VERSION=5.1 15760 fi 15761 fi 15762 if test "x$OPENJDK_TARGET_OS" = "xmacosx"; then 15763 REQUIRED_OS_NAME=Darwin 15764 REQUIRED_OS_VERSION=11.2 15765 fi 15766 if test "x$OPENJDK_TARGET_OS" = "xaix"; then 15767 REQUIRED_OS_NAME=AIX 15768 REQUIRED_OS_VERSION=7.1 15769 fi 15770 15771 15772 15773 15774 15775 15776 # Also store the legacy naming of the cpu. 15777 # Ie i586 and amd64 instead of x86 and x86_64 15778 OPENJDK_TARGET_CPU_LEGACY="$OPENJDK_TARGET_CPU" 15779 if test "x$OPENJDK_TARGET_CPU" = xx86; then 15780 OPENJDK_TARGET_CPU_LEGACY="i586" 15781 elif test "x$OPENJDK_TARGET_OS" != xmacosx && test "x$OPENJDK_TARGET_CPU" = xx86_64; then 15782 # On all platforms except MacOSX replace x86_64 with amd64. 15783 OPENJDK_TARGET_CPU_LEGACY="amd64" 15784 fi 15785 15786 15787 # And the second legacy naming of the cpu. 15788 # Ie i386 and amd64 instead of x86 and x86_64. 15789 OPENJDK_TARGET_CPU_LEGACY_LIB="$OPENJDK_TARGET_CPU" 15790 if test "x$OPENJDK_TARGET_CPU" = xx86; then 15791 OPENJDK_TARGET_CPU_LEGACY_LIB="i386" 15792 elif test "x$OPENJDK_TARGET_CPU" = xx86_64; then 15793 OPENJDK_TARGET_CPU_LEGACY_LIB="amd64" 15794 fi 15795 15796 15797 # This is the name of the cpu (but using i386 and amd64 instead of 15798 # x86 and x86_64, respectively), preceeded by a /, to be used when 15799 # locating libraries. On macosx, it's empty, though. 15800 OPENJDK_TARGET_CPU_LIBDIR="/$OPENJDK_TARGET_CPU_LEGACY_LIB" 15801 if test "x$OPENJDK_TARGET_OS" = xmacosx; then 15802 OPENJDK_TARGET_CPU_LIBDIR="" 15803 fi 15804 15805 15806 # OPENJDK_TARGET_CPU_ISADIR is normally empty. On 64-bit Solaris systems, it is set to 15807 # /amd64 or /sparcv9. This string is appended to some library paths, like this: 15808 # /usr/lib${OPENJDK_TARGET_CPU_ISADIR}/libexample.so 15809 OPENJDK_TARGET_CPU_ISADIR="" 15810 if test "x$OPENJDK_TARGET_OS" = xsolaris; then 15811 if test "x$OPENJDK_TARGET_CPU" = xx86_64; then 15812 OPENJDK_TARGET_CPU_ISADIR="/amd64" 15813 elif test "x$OPENJDK_TARGET_CPU" = xsparcv9; then 15814 OPENJDK_TARGET_CPU_ISADIR="/sparcv9" 15815 fi 15816 fi 15817 15818 15819 # Setup OPENJDK_TARGET_CPU_OSARCH, which is used to set the os.arch Java system property 15820 OPENJDK_TARGET_CPU_OSARCH="$OPENJDK_TARGET_CPU" 15821 if test "x$OPENJDK_TARGET_OS" = xlinux && test "x$OPENJDK_TARGET_CPU" = xx86; then 15822 # On linux only, we replace x86 with i386. 15823 OPENJDK_TARGET_CPU_OSARCH="i386" 15824 elif test "x$OPENJDK_TARGET_OS" != xmacosx && test "x$OPENJDK_TARGET_CPU" = xx86_64; then 15825 # On all platforms except macosx, we replace x86_64 with amd64. 15826 OPENJDK_TARGET_CPU_OSARCH="amd64" 15827 fi 15828 15829 15830 OPENJDK_TARGET_CPU_JLI="$OPENJDK_TARGET_CPU" 15831 if test "x$OPENJDK_TARGET_CPU" = xx86; then 15832 OPENJDK_TARGET_CPU_JLI="i386" 15833 elif test "x$OPENJDK_TARGET_OS" != xmacosx && test "x$OPENJDK_TARGET_CPU" = xx86_64; then 15834 # On all platforms except macosx, we replace x86_64 with amd64. 15835 OPENJDK_TARGET_CPU_JLI="amd64" 15836 fi 15837 # Now setup the -D flags for building libjli. 15838 OPENJDK_TARGET_CPU_JLI_CFLAGS="-DLIBARCHNAME='\"$OPENJDK_TARGET_CPU_JLI\"'" 15839 if test "x$OPENJDK_TARGET_OS" = xsolaris; then 15840 if test "x$OPENJDK_TARGET_CPU_ARCH" = xsparc; then 15841 OPENJDK_TARGET_CPU_JLI_CFLAGS="$OPENJDK_TARGET_CPU_JLI_CFLAGS -DLIBARCH32NAME='\"sparc\"' -DLIBARCH64NAME='\"sparcv9\"'" 15842 elif test "x$OPENJDK_TARGET_CPU_ARCH" = xx86; then 15843 OPENJDK_TARGET_CPU_JLI_CFLAGS="$OPENJDK_TARGET_CPU_JLI_CFLAGS -DLIBARCH32NAME='\"i386\"' -DLIBARCH64NAME='\"amd64\"'" 15844 fi 15845 fi 15846 15847 15848 if test "x$OPENJDK_TARGET_OS" = xmacosx; then 15849 OPENJDK_TARGET_OS_EXPORT_DIR=macosx 15850 else 15851 OPENJDK_TARGET_OS_EXPORT_DIR=${OPENJDK_TARGET_OS_TYPE} 15852 fi 15853 15854 15855 # The new version string in JDK 9 also defined new naming of OS and ARCH for bundles 15856 # Macosx is osx and x86_64 is x64 15857 if test "x$OPENJDK_TARGET_OS" = xmacosx; then 15858 OPENJDK_TARGET_OS_BUNDLE="osx" 15859 else 15860 OPENJDK_TARGET_OS_BUNDLE="$OPENJDK_TARGET_OS" 15861 fi 15862 if test "x$OPENJDK_TARGET_CPU" = xx86_64; then 15863 OPENJDK_TARGET_CPU_BUNDLE="x64" 15864 else 15865 OPENJDK_TARGET_CPU_BUNDLE="$OPENJDK_TARGET_CPU" 15866 fi 15867 OPENJDK_TARGET_BUNDLE_PLATFORM="${OPENJDK_TARGET_OS_BUNDLE}-${OPENJDK_TARGET_CPU_BUNDLE}" 15868 15869 15870 15871 15872 if test "x$OPENJDK_TARGET_CPU_BITS" = x64; then 15873 A_LP64="LP64:=" 15874 # -D_LP64=1 is only set on linux and mac. Setting on windows causes diff in 15875 # unpack200.exe 15876 if test "x$OPENJDK_TARGET_OS" = xlinux || test "x$OPENJDK_TARGET_OS" = xmacosx; then 15877 OPENJDK_TARGET_ADD_LP64="-D_LP64=1" 15878 fi 15879 fi 15880 LP64=$A_LP64 15881 15882 15883 if test "x$COMPILE_TYPE" = "xcross"; then 15884 # FIXME: ... or should this include reduced builds..? 15885 DEFINE_CROSS_COMPILE_ARCH="CROSS_COMPILE_ARCH:=$OPENJDK_TARGET_CPU_LEGACY" 15886 else 15887 DEFINE_CROSS_COMPILE_ARCH="" 15888 fi 15889 15890 15891 # Convert openjdk platform names to hotspot names 15892 15893 HOTSPOT_TARGET_OS=${OPENJDK_TARGET_OS} 15894 if test "x$OPENJDK_TARGET_OS" = xmacosx; then 15895 HOTSPOT_TARGET_OS=bsd 15896 fi 15897 15898 15899 HOTSPOT_TARGET_OS_TYPE=${OPENJDK_TARGET_OS_TYPE} 15900 if test "x$OPENJDK_TARGET_OS_TYPE" = xunix; then 15901 HOTSPOT_TARGET_OS_TYPE=posix 15902 fi 15903 15904 15905 HOTSPOT_TARGET_CPU=${OPENJDK_TARGET_CPU} 15906 if test "x$OPENJDK_TARGET_CPU" = xx86; then 15907 HOTSPOT_TARGET_CPU=x86_32 15908 elif test "x$OPENJDK_TARGET_CPU" = xsparcv9; then 15909 HOTSPOT_TARGET_CPU=sparc 15910 elif test "x$OPENJDK_TARGET_CPU" = xppc64; then 15911 HOTSPOT_TARGET_CPU=ppc_64 15912 elif test "x$OPENJDK_TARGET_CPU" = xppc64le; then 15913 HOTSPOT_TARGET_CPU=ppc_64 15914 fi 15915 15916 15917 # This is identical with OPENJDK_*, but define anyway for consistency. 15918 HOTSPOT_TARGET_CPU_ARCH=${OPENJDK_TARGET_CPU_ARCH} 15919 15920 15921 # Setup HOTSPOT_TARGET_CPU_DEFINE 15922 if test "x$OPENJDK_TARGET_CPU" = xx86; then 15923 HOTSPOT_TARGET_CPU_DEFINE=IA32 15924 elif test "x$OPENJDK_TARGET_CPU" = xx86_64; then 15925 HOTSPOT_TARGET_CPU_DEFINE=AMD64 15926 elif test "x$OPENJDK_TARGET_CPU" = xsparcv9; then 15927 HOTSPOT_TARGET_CPU_DEFINE=SPARC 15928 elif test "x$OPENJDK_TARGET_CPU" = xaarch64; then 15929 HOTSPOT_TARGET_CPU_DEFINE=AARCH64 15930 elif test "x$OPENJDK_TARGET_CPU" = xppc64; then 15931 HOTSPOT_TARGET_CPU_DEFINE=PPC64 15932 elif test "x$OPENJDK_TARGET_CPU" = xppc64le; then 15933 HOTSPOT_TARGET_CPU_DEFINE=PPC64 15934 15935 # The cpu defines below are for zero, we don't support them directly. 15936 elif test "x$OPENJDK_TARGET_CPU" = xsparc; then 15937 HOTSPOT_TARGET_CPU_DEFINE=SPARC 15938 elif test "x$OPENJDK_TARGET_CPU" = xppc; then 15939 HOTSPOT_TARGET_CPU_DEFINE=PPC32 15940 elif test "x$OPENJDK_TARGET_CPU" = xs390; then 15941 HOTSPOT_TARGET_CPU_DEFINE=S390 15942 elif test "x$OPENJDK_TARGET_CPU" = xs390x; then 15943 HOTSPOT_TARGET_CPU_DEFINE=S390 15944 elif test "x$OPENJDK_TARGET_CPU" != x; then 15945 HOTSPOT_TARGET_CPU_DEFINE=$(echo $OPENJDK_TARGET_CPU | tr a-z A-Z) 15946 fi 15947 15948 15949 15950 15951 # Also store the legacy naming of the cpu. 15952 # Ie i586 and amd64 instead of x86 and x86_64 15953 OPENJDK_BUILD_CPU_LEGACY="$OPENJDK_BUILD_CPU" 15954 if test "x$OPENJDK_BUILD_CPU" = xx86; then 15955 OPENJDK_BUILD_CPU_LEGACY="i586" 15956 elif test "x$OPENJDK_BUILD_OS" != xmacosx && test "x$OPENJDK_BUILD_CPU" = xx86_64; then 15957 # On all platforms except MacOSX replace x86_64 with amd64. 15958 OPENJDK_BUILD_CPU_LEGACY="amd64" 15959 fi 15960 15961 15962 # And the second legacy naming of the cpu. 15963 # Ie i386 and amd64 instead of x86 and x86_64. 15964 OPENJDK_BUILD_CPU_LEGACY_LIB="$OPENJDK_BUILD_CPU" 15965 if test "x$OPENJDK_BUILD_CPU" = xx86; then 15966 OPENJDK_BUILD_CPU_LEGACY_LIB="i386" 15967 elif test "x$OPENJDK_BUILD_CPU" = xx86_64; then 15968 OPENJDK_BUILD_CPU_LEGACY_LIB="amd64" 15969 fi 15970 15971 15972 # This is the name of the cpu (but using i386 and amd64 instead of 15973 # x86 and x86_64, respectively), preceeded by a /, to be used when 15974 # locating libraries. On macosx, it's empty, though. 15975 OPENJDK_BUILD_CPU_LIBDIR="/$OPENJDK_BUILD_CPU_LEGACY_LIB" 15976 if test "x$OPENJDK_BUILD_OS" = xmacosx; then 15977 OPENJDK_BUILD_CPU_LIBDIR="" 15978 fi 15979 15980 15981 # OPENJDK_BUILD_CPU_ISADIR is normally empty. On 64-bit Solaris systems, it is set to 15982 # /amd64 or /sparcv9. This string is appended to some library paths, like this: 15983 # /usr/lib${OPENJDK_BUILD_CPU_ISADIR}/libexample.so 15984 OPENJDK_BUILD_CPU_ISADIR="" 15985 if test "x$OPENJDK_BUILD_OS" = xsolaris; then 15986 if test "x$OPENJDK_BUILD_CPU" = xx86_64; then 15987 OPENJDK_BUILD_CPU_ISADIR="/amd64" 15988 elif test "x$OPENJDK_BUILD_CPU" = xsparcv9; then 15989 OPENJDK_BUILD_CPU_ISADIR="/sparcv9" 15990 fi 15991 fi 15992 15993 15994 # Setup OPENJDK_BUILD_CPU_OSARCH, which is used to set the os.arch Java system property 15995 OPENJDK_BUILD_CPU_OSARCH="$OPENJDK_BUILD_CPU" 15996 if test "x$OPENJDK_BUILD_OS" = xlinux && test "x$OPENJDK_BUILD_CPU" = xx86; then 15997 # On linux only, we replace x86 with i386. 15998 OPENJDK_BUILD_CPU_OSARCH="i386" 15999 elif test "x$OPENJDK_BUILD_OS" != xmacosx && test "x$OPENJDK_BUILD_CPU" = xx86_64; then 16000 # On all platforms except macosx, we replace x86_64 with amd64. 16001 OPENJDK_BUILD_CPU_OSARCH="amd64" 16002 fi 16003 16004 16005 OPENJDK_BUILD_CPU_JLI="$OPENJDK_BUILD_CPU" 16006 if test "x$OPENJDK_BUILD_CPU" = xx86; then 16007 OPENJDK_BUILD_CPU_JLI="i386" 16008 elif test "x$OPENJDK_BUILD_OS" != xmacosx && test "x$OPENJDK_BUILD_CPU" = xx86_64; then 16009 # On all platforms except macosx, we replace x86_64 with amd64. 16010 OPENJDK_BUILD_CPU_JLI="amd64" 16011 fi 16012 # Now setup the -D flags for building libjli. 16013 OPENJDK_BUILD_CPU_JLI_CFLAGS="-DLIBARCHNAME='\"$OPENJDK_BUILD_CPU_JLI\"'" 16014 if test "x$OPENJDK_BUILD_OS" = xsolaris; then 16015 if test "x$OPENJDK_BUILD_CPU_ARCH" = xsparc; then 16016 OPENJDK_BUILD_CPU_JLI_CFLAGS="$OPENJDK_BUILD_CPU_JLI_CFLAGS -DLIBARCH32NAME='\"sparc\"' -DLIBARCH64NAME='\"sparcv9\"'" 16017 elif test "x$OPENJDK_BUILD_CPU_ARCH" = xx86; then 16018 OPENJDK_BUILD_CPU_JLI_CFLAGS="$OPENJDK_BUILD_CPU_JLI_CFLAGS -DLIBARCH32NAME='\"i386\"' -DLIBARCH64NAME='\"amd64\"'" 16019 fi 16020 fi 16021 16022 16023 if test "x$OPENJDK_BUILD_OS" = xmacosx; then 16024 OPENJDK_BUILD_OS_EXPORT_DIR=macosx 16025 else 16026 OPENJDK_BUILD_OS_EXPORT_DIR=${OPENJDK_BUILD_OS_TYPE} 16027 fi 16028 16029 16030 # The new version string in JDK 9 also defined new naming of OS and ARCH for bundles 16031 # Macosx is osx and x86_64 is x64 16032 if test "x$OPENJDK_BUILD_OS" = xmacosx; then 16033 OPENJDK_BUILD_OS_BUNDLE="osx" 16034 else 16035 OPENJDK_BUILD_OS_BUNDLE="$OPENJDK_TARGET_OS" 16036 fi 16037 if test "x$OPENJDK_BUILD_CPU" = xx86_64; then 16038 OPENJDK_BUILD_CPU_BUNDLE="x64" 16039 else 16040 OPENJDK_BUILD_CPU_BUNDLE="$OPENJDK_BUILD_CPU" 16041 fi 16042 OPENJDK_BUILD_BUNDLE_PLATFORM="${OPENJDK_BUILD_OS_BUNDLE}-${OPENJDK_BUILD_CPU_BUNDLE}" 16043 16044 16045 16046 16047 if test "x$OPENJDK_BUILD_CPU_BITS" = x64; then 16048 A_LP64="LP64:=" 16049 # -D_LP64=1 is only set on linux and mac. Setting on windows causes diff in 16050 # unpack200.exe 16051 if test "x$OPENJDK_BUILD_OS" = xlinux || test "x$OPENJDK_BUILD_OS" = xmacosx; then 16052 OPENJDK_BUILD_ADD_LP64="-D_LP64=1" 16053 fi 16054 fi 16055 LP64=$A_LP64 16056 16057 16058 if test "x$COMPILE_TYPE" = "xcross"; then 16059 # FIXME: ... or should this include reduced builds..? 16060 DEFINE_CROSS_COMPILE_ARCH="CROSS_COMPILE_ARCH:=$OPENJDK_BUILD_CPU_LEGACY" 16061 else 16062 DEFINE_CROSS_COMPILE_ARCH="" 16063 fi 16064 16065 16066 # Convert openjdk platform names to hotspot names 16067 16068 HOTSPOT_BUILD_OS=${OPENJDK_BUILD_OS} 16069 if test "x$OPENJDK_BUILD_OS" = xmacosx; then 16070 HOTSPOT_BUILD_OS=bsd 16071 fi 16072 16073 16074 HOTSPOT_BUILD_OS_TYPE=${OPENJDK_BUILD_OS_TYPE} 16075 if test "x$OPENJDK_BUILD_OS_TYPE" = xunix; then 16076 HOTSPOT_BUILD_OS_TYPE=posix 16077 fi 16078 16079 16080 HOTSPOT_BUILD_CPU=${OPENJDK_BUILD_CPU} 16081 if test "x$OPENJDK_BUILD_CPU" = xx86; then 16082 HOTSPOT_BUILD_CPU=x86_32 16083 elif test "x$OPENJDK_BUILD_CPU" = xsparcv9; then 16084 HOTSPOT_BUILD_CPU=sparc 16085 elif test "x$OPENJDK_BUILD_CPU" = xppc64; then 16086 HOTSPOT_BUILD_CPU=ppc_64 16087 elif test "x$OPENJDK_BUILD_CPU" = xppc64le; then 16088 HOTSPOT_BUILD_CPU=ppc_64 16089 fi 16090 16091 16092 # This is identical with OPENJDK_*, but define anyway for consistency. 16093 HOTSPOT_BUILD_CPU_ARCH=${OPENJDK_BUILD_CPU_ARCH} 16094 16095 16096 # Setup HOTSPOT_BUILD_CPU_DEFINE 16097 if test "x$OPENJDK_BUILD_CPU" = xx86; then 16098 HOTSPOT_BUILD_CPU_DEFINE=IA32 16099 elif test "x$OPENJDK_BUILD_CPU" = xx86_64; then 16100 HOTSPOT_BUILD_CPU_DEFINE=AMD64 16101 elif test "x$OPENJDK_BUILD_CPU" = xsparcv9; then 16102 HOTSPOT_BUILD_CPU_DEFINE=SPARC 16103 elif test "x$OPENJDK_BUILD_CPU" = xaarch64; then 16104 HOTSPOT_BUILD_CPU_DEFINE=AARCH64 16105 elif test "x$OPENJDK_BUILD_CPU" = xppc64; then 16106 HOTSPOT_BUILD_CPU_DEFINE=PPC64 16107 elif test "x$OPENJDK_BUILD_CPU" = xppc64le; then 16108 HOTSPOT_BUILD_CPU_DEFINE=PPC64 16109 16110 # The cpu defines below are for zero, we don't support them directly. 16111 elif test "x$OPENJDK_BUILD_CPU" = xsparc; then 16112 HOTSPOT_BUILD_CPU_DEFINE=SPARC 16113 elif test "x$OPENJDK_BUILD_CPU" = xppc; then 16114 HOTSPOT_BUILD_CPU_DEFINE=PPC32 16115 elif test "x$OPENJDK_BUILD_CPU" = xs390; then 16116 HOTSPOT_BUILD_CPU_DEFINE=S390 16117 elif test "x$OPENJDK_BUILD_CPU" = xs390x; then 16118 HOTSPOT_BUILD_CPU_DEFINE=S390 16119 elif test "x$OPENJDK_BUILD_CPU" != x; then 16120 HOTSPOT_BUILD_CPU_DEFINE=$(echo $OPENJDK_BUILD_CPU | tr a-z A-Z) 16121 fi 16122 16123 16124 16125 16126 # ZERO_ARCHDEF is used to enable architecture-specific code. 16127 # This is used in legacy hotspot build. 16128 ZERO_ARCHDEF="$HOTSPOT_TARGET_CPU_DEFINE" 16129 16130 16131 16132 16133 16134 # Continue setting up basic stuff. Most remaining code require fundamental tools. 16135 16136 # Save the current directory this script was started from 16137 CURDIR="$PWD" 16138 16139 # We might need to rewrite ORIGINAL_PATH, if it includes "#", to quote them 16140 # for make. We couldn't do this when we retrieved ORIGINAL_PATH, since SED 16141 # was not available at that time. 16142 REWRITTEN_PATH=`$ECHO "$ORIGINAL_PATH" | $SED -e 's/#/\\\\#/g'` 16143 if test "x$REWRITTEN_PATH" != "x$ORIGINAL_PATH"; then 16144 ORIGINAL_PATH="$REWRITTEN_PATH" 16145 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting ORIGINAL_PATH to $REWRITTEN_PATH" >&5 16146 $as_echo "$as_me: Rewriting ORIGINAL_PATH to $REWRITTEN_PATH" >&6;} 16147 fi 16148 16149 if test "x$OPENJDK_TARGET_OS" = "xwindows"; then 16150 PATH_SEP=";" 16151 16152 SRC_ROOT_LENGTH=`$THEPWDCMD -L|$WC -m` 16153 if test $SRC_ROOT_LENGTH -gt 100; then 16154 as_fn_error $? "Your base path is too long. It is $SRC_ROOT_LENGTH characters long, but only 100 is supported" "$LINENO" 5 16155 fi 16156 16157 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 16158 { $as_echo "$as_me:${as_lineno-$LINENO}: checking cygwin release" >&5 16159 $as_echo_n "checking cygwin release... " >&6; } 16160 CYGWIN_VERSION=`$UNAME -r` 16161 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CYGWIN_VERSION" >&5 16162 $as_echo "$CYGWIN_VERSION" >&6; } 16163 WINDOWS_ENV_VENDOR='cygwin' 16164 WINDOWS_ENV_VERSION="$CYGWIN_VERSION" 16165 16166 CYGWIN_VERSION_OLD=`$ECHO $CYGWIN_VERSION | $GREP -e '^1\.0-6'` 16167 if test "x$CYGWIN_VERSION_OLD" != x; then 16168 { $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 16169 $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;} 16170 as_fn_error $? "Cannot continue" "$LINENO" 5 16171 fi 16172 if test "x$CYGPATH" = x; then 16173 as_fn_error $? "Something is wrong with your cygwin installation since I cannot find cygpath.exe in your path" "$LINENO" 5 16174 fi 16175 { $as_echo "$as_me:${as_lineno-$LINENO}: checking cygwin root directory as unix-style path" >&5 16176 $as_echo_n "checking cygwin root directory as unix-style path... " >&6; } 16177 # The cmd output ends with Windows line endings (CR/LF), the grep command will strip that away 16178 cygwin_winpath_root=`cd / ; cmd /c cd | $GREP ".*"` 16179 # Force cygpath to report the proper root by including a trailing space, and then stripping it off again. 16180 CYGWIN_ROOT_PATH=`$CYGPATH -u "$cygwin_winpath_root " | $CUT -f 1 -d " "` 16181 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CYGWIN_ROOT_PATH" >&5 16182 $as_echo "$CYGWIN_ROOT_PATH" >&6; } 16183 WINDOWS_ENV_ROOT_PATH="$CYGWIN_ROOT_PATH" 16184 test_cygdrive_prefix=`$ECHO $CYGWIN_ROOT_PATH | $GREP ^/cygdrive/` 16185 if test "x$test_cygdrive_prefix" = x; then 16186 as_fn_error $? "Your cygdrive prefix is not /cygdrive. This is currently not supported. Change with mount -c." "$LINENO" 5 16187 fi 16188 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 16189 { $as_echo "$as_me:${as_lineno-$LINENO}: checking msys release" >&5 16190 $as_echo_n "checking msys release... " >&6; } 16191 MSYS_VERSION=`$UNAME -r` 16192 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MSYS_VERSION" >&5 16193 $as_echo "$MSYS_VERSION" >&6; } 16194 16195 WINDOWS_ENV_VENDOR='msys' 16196 WINDOWS_ENV_VERSION="$MSYS_VERSION" 16197 16198 { $as_echo "$as_me:${as_lineno-$LINENO}: checking msys root directory as unix-style path" >&5 16199 $as_echo_n "checking msys root directory as unix-style path... " >&6; } 16200 # The cmd output ends with Windows line endings (CR/LF), the grep command will strip that away 16201 MSYS_ROOT_PATH=`cd / ; cmd /c cd | $GREP ".*"` 16202 16203 windows_path="$MSYS_ROOT_PATH" 16204 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 16205 unix_path=`$CYGPATH -u "$windows_path"` 16206 MSYS_ROOT_PATH="$unix_path" 16207 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 16208 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 16209 MSYS_ROOT_PATH="$unix_path" 16210 fi 16211 16212 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MSYS_ROOT_PATH" >&5 16213 $as_echo "$MSYS_ROOT_PATH" >&6; } 16214 WINDOWS_ENV_ROOT_PATH="$MSYS_ROOT_PATH" 16215 else 16216 as_fn_error $? "Unknown Windows environment. Neither cygwin nor msys was detected." "$LINENO" 5 16217 fi 16218 16219 # Test if windows or unix (cygwin/msys) find is first in path. 16220 { $as_echo "$as_me:${as_lineno-$LINENO}: checking what kind of 'find' is first on the PATH" >&5 16221 $as_echo_n "checking what kind of 'find' is first on the PATH... " >&6; } 16222 FIND_BINARY_OUTPUT=`find --version 2>&1` 16223 if test "x`echo $FIND_BINARY_OUTPUT | $GREP GNU`" != x; then 16224 { $as_echo "$as_me:${as_lineno-$LINENO}: result: unix style" >&5 16225 $as_echo "unix style" >&6; } 16226 elif test "x`echo $FIND_BINARY_OUTPUT | $GREP FIND`" != x; then 16227 { $as_echo "$as_me:${as_lineno-$LINENO}: result: Windows" >&5 16228 $as_echo "Windows" >&6; } 16229 { $as_echo "$as_me:${as_lineno-$LINENO}: Your path contains Windows tools (C:\Windows\system32) before your unix (cygwin or msys) tools." >&5 16230 $as_echo "$as_me: Your path contains Windows tools (C:\Windows\system32) before your unix (cygwin or msys) tools." >&6;} 16231 { $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 16232 $as_echo "$as_me: This will not work. Please correct and make sure /usr/bin (or similar) is first in path." >&6;} 16233 as_fn_error $? "Cannot continue" "$LINENO" 5 16234 else 16235 { $as_echo "$as_me:${as_lineno-$LINENO}: result: unknown" >&5 16236 $as_echo "unknown" >&6; } 16237 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: It seems that your find utility is non-standard." >&5 16238 $as_echo "$as_me: WARNING: It seems that your find utility is non-standard." >&2;} 16239 fi 16240 16241 else 16242 PATH_SEP=":" 16243 fi 16244 16245 16246 # We get the top-level directory from the supporting wrappers. 16247 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for top-level directory" >&5 16248 $as_echo_n "checking for top-level directory... " >&6; } 16249 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $TOPDIR" >&5 16250 $as_echo "$TOPDIR" >&6; } 16251 16252 16253 # Save the original version of TOPDIR for string comparisons 16254 ORIGINAL_TOPDIR="$TOPDIR" 16255 16256 16257 # We can only call BASIC_FIXUP_PATH after BASIC_CHECK_PATHS_WINDOWS. 16258 16259 # Only process if variable expands to non-empty 16260 16261 if test "x$CURDIR" != x; then 16262 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 16263 16264 # Input might be given as Windows format, start by converting to 16265 # unix format. 16266 path="$CURDIR" 16267 new_path=`$CYGPATH -u "$path"` 16268 16269 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 16270 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 16271 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 16272 # "foo.exe" is OK but "foo" is an error. 16273 # 16274 # This test is therefore slightly more accurate than "test -f" to check for file precense. 16275 # It is also a way to make sure we got the proper file name for the real test later on. 16276 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 16277 if test "x$test_shortpath" = x; then 16278 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of CURDIR, which resolves as \"$path\", is invalid." >&5 16279 $as_echo "$as_me: The path of CURDIR, which resolves as \"$path\", is invalid." >&6;} 16280 as_fn_error $? "Cannot locate the the path of CURDIR" "$LINENO" 5 16281 fi 16282 16283 # Call helper function which possibly converts this using DOS-style short mode. 16284 # If so, the updated path is stored in $new_path. 16285 16286 input_path="$new_path" 16287 # Check if we need to convert this using DOS-style short mode. If the path 16288 # contains just simple characters, use it. Otherwise (spaces, weird characters), 16289 # take no chances and rewrite it. 16290 # Note: m4 eats our [], so we need to use [ and ] instead. 16291 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 16292 if test "x$has_forbidden_chars" != x; then 16293 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 16294 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 16295 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 16296 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 16297 # Going to short mode and back again did indeed matter. Since short mode is 16298 # case insensitive, let's make it lowercase to improve readability. 16299 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 16300 # Now convert it back to Unix-style (cygpath) 16301 input_path=`$CYGPATH -u "$shortmode_path"` 16302 new_path="$input_path" 16303 fi 16304 fi 16305 16306 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 16307 if test "x$test_cygdrive_prefix" = x; then 16308 # As a simple fix, exclude /usr/bin since it's not a real path. 16309 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 16310 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 16311 # a path prefixed by /cygdrive for fixpath to work. 16312 new_path="$CYGWIN_ROOT_PATH$input_path" 16313 fi 16314 fi 16315 16316 16317 if test "x$path" != "x$new_path"; then 16318 CURDIR="$new_path" 16319 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting CURDIR to \"$new_path\"" >&5 16320 $as_echo "$as_me: Rewriting CURDIR to \"$new_path\"" >&6;} 16321 fi 16322 16323 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 16324 16325 path="$CURDIR" 16326 has_colon=`$ECHO $path | $GREP ^.:` 16327 new_path="$path" 16328 if test "x$has_colon" = x; then 16329 # Not in mixed or Windows style, start by that. 16330 new_path=`cmd //c echo $path` 16331 fi 16332 16333 16334 input_path="$new_path" 16335 # Check if we need to convert this using DOS-style short mode. If the path 16336 # contains just simple characters, use it. Otherwise (spaces, weird characters), 16337 # take no chances and rewrite it. 16338 # Note: m4 eats our [], so we need to use [ and ] instead. 16339 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 16340 if test "x$has_forbidden_chars" != x; then 16341 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 16342 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 16343 fi 16344 16345 16346 windows_path="$new_path" 16347 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 16348 unix_path=`$CYGPATH -u "$windows_path"` 16349 new_path="$unix_path" 16350 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 16351 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 16352 new_path="$unix_path" 16353 fi 16354 16355 if test "x$path" != "x$new_path"; then 16356 CURDIR="$new_path" 16357 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting CURDIR to \"$new_path\"" >&5 16358 $as_echo "$as_me: Rewriting CURDIR to \"$new_path\"" >&6;} 16359 fi 16360 16361 # Save the first 10 bytes of this path to the storage, so fixpath can work. 16362 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 16363 16364 else 16365 # We're on a unix platform. Hooray! :) 16366 path="$CURDIR" 16367 has_space=`$ECHO "$path" | $GREP " "` 16368 if test "x$has_space" != x; then 16369 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of CURDIR, which resolves as \"$path\", is invalid." >&5 16370 $as_echo "$as_me: The path of CURDIR, which resolves as \"$path\", is invalid." >&6;} 16371 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 16372 fi 16373 16374 # Use eval to expand a potential ~ 16375 eval path="$path" 16376 if test ! -f "$path" && test ! -d "$path"; then 16377 as_fn_error $? "The path of CURDIR, which resolves as \"$path\", is not found." "$LINENO" 5 16378 fi 16379 16380 if test -d "$path"; then 16381 CURDIR="`cd "$path"; $THEPWDCMD -L`" 16382 else 16383 dir="`$DIRNAME "$path"`" 16384 base="`$BASENAME "$path"`" 16385 CURDIR="`cd "$dir"; $THEPWDCMD -L`/$base" 16386 fi 16387 fi 16388 fi 16389 16390 16391 # Only process if variable expands to non-empty 16392 16393 if test "x$TOPDIR" != x; then 16394 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 16395 16396 # Input might be given as Windows format, start by converting to 16397 # unix format. 16398 path="$TOPDIR" 16399 new_path=`$CYGPATH -u "$path"` 16400 16401 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 16402 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 16403 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 16404 # "foo.exe" is OK but "foo" is an error. 16405 # 16406 # This test is therefore slightly more accurate than "test -f" to check for file precense. 16407 # It is also a way to make sure we got the proper file name for the real test later on. 16408 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 16409 if test "x$test_shortpath" = x; then 16410 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of TOPDIR, which resolves as \"$path\", is invalid." >&5 16411 $as_echo "$as_me: The path of TOPDIR, which resolves as \"$path\", is invalid." >&6;} 16412 as_fn_error $? "Cannot locate the the path of TOPDIR" "$LINENO" 5 16413 fi 16414 16415 # Call helper function which possibly converts this using DOS-style short mode. 16416 # If so, the updated path is stored in $new_path. 16417 16418 input_path="$new_path" 16419 # Check if we need to convert this using DOS-style short mode. If the path 16420 # contains just simple characters, use it. Otherwise (spaces, weird characters), 16421 # take no chances and rewrite it. 16422 # Note: m4 eats our [], so we need to use [ and ] instead. 16423 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 16424 if test "x$has_forbidden_chars" != x; then 16425 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 16426 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 16427 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 16428 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 16429 # Going to short mode and back again did indeed matter. Since short mode is 16430 # case insensitive, let's make it lowercase to improve readability. 16431 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 16432 # Now convert it back to Unix-style (cygpath) 16433 input_path=`$CYGPATH -u "$shortmode_path"` 16434 new_path="$input_path" 16435 fi 16436 fi 16437 16438 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 16439 if test "x$test_cygdrive_prefix" = x; then 16440 # As a simple fix, exclude /usr/bin since it's not a real path. 16441 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 16442 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 16443 # a path prefixed by /cygdrive for fixpath to work. 16444 new_path="$CYGWIN_ROOT_PATH$input_path" 16445 fi 16446 fi 16447 16448 16449 if test "x$path" != "x$new_path"; then 16450 TOPDIR="$new_path" 16451 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting TOPDIR to \"$new_path\"" >&5 16452 $as_echo "$as_me: Rewriting TOPDIR to \"$new_path\"" >&6;} 16453 fi 16454 16455 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 16456 16457 path="$TOPDIR" 16458 has_colon=`$ECHO $path | $GREP ^.:` 16459 new_path="$path" 16460 if test "x$has_colon" = x; then 16461 # Not in mixed or Windows style, start by that. 16462 new_path=`cmd //c echo $path` 16463 fi 16464 16465 16466 input_path="$new_path" 16467 # Check if we need to convert this using DOS-style short mode. If the path 16468 # contains just simple characters, use it. Otherwise (spaces, weird characters), 16469 # take no chances and rewrite it. 16470 # Note: m4 eats our [], so we need to use [ and ] instead. 16471 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 16472 if test "x$has_forbidden_chars" != x; then 16473 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 16474 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 16475 fi 16476 16477 16478 windows_path="$new_path" 16479 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 16480 unix_path=`$CYGPATH -u "$windows_path"` 16481 new_path="$unix_path" 16482 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 16483 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 16484 new_path="$unix_path" 16485 fi 16486 16487 if test "x$path" != "x$new_path"; then 16488 TOPDIR="$new_path" 16489 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting TOPDIR to \"$new_path\"" >&5 16490 $as_echo "$as_me: Rewriting TOPDIR to \"$new_path\"" >&6;} 16491 fi 16492 16493 # Save the first 10 bytes of this path to the storage, so fixpath can work. 16494 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 16495 16496 else 16497 # We're on a unix platform. Hooray! :) 16498 path="$TOPDIR" 16499 has_space=`$ECHO "$path" | $GREP " "` 16500 if test "x$has_space" != x; then 16501 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of TOPDIR, which resolves as \"$path\", is invalid." >&5 16502 $as_echo "$as_me: The path of TOPDIR, which resolves as \"$path\", is invalid." >&6;} 16503 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 16504 fi 16505 16506 # Use eval to expand a potential ~ 16507 eval path="$path" 16508 if test ! -f "$path" && test ! -d "$path"; then 16509 as_fn_error $? "The path of TOPDIR, which resolves as \"$path\", is not found." "$LINENO" 5 16510 fi 16511 16512 if test -d "$path"; then 16513 TOPDIR="`cd "$path"; $THEPWDCMD -L`" 16514 else 16515 dir="`$DIRNAME "$path"`" 16516 base="`$BASENAME "$path"`" 16517 TOPDIR="`cd "$dir"; $THEPWDCMD -L`/$base" 16518 fi 16519 fi 16520 fi 16521 16522 # SRC_ROOT is a traditional alias for TOPDIR. 16523 SRC_ROOT=$TOPDIR 16524 16525 # Calculate a canonical version of TOPDIR for string comparisons 16526 CANONICAL_TOPDIR=$TOPDIR 16527 16528 if test "x$OPENJDK_BUILD_OS" != xwindows; then 16529 # Follow a chain of symbolic links. Use readlink 16530 # where it exists, else fall back to horribly 16531 # complicated shell code. 16532 if test "x$READLINK_TESTED" != yes; then 16533 # On MacOSX there is a readlink tool with a different 16534 # purpose than the GNU readlink tool. Check the found readlink. 16535 ISGNU=`$READLINK --version 2>&1 | $GREP GNU` 16536 if test "x$ISGNU" = x; then 16537 # A readlink that we do not know how to use. 16538 # Are there other non-GNU readlinks out there? 16539 READLINK_TESTED=yes 16540 READLINK= 16541 fi 16542 fi 16543 16544 if test "x$READLINK" != x; then 16545 CANONICAL_TOPDIR=`$READLINK -f $CANONICAL_TOPDIR` 16546 else 16547 # Save the current directory for restoring afterwards 16548 STARTDIR=$PWD 16549 COUNTER=0 16550 sym_link_dir=`$DIRNAME $CANONICAL_TOPDIR` 16551 sym_link_file=`$BASENAME $CANONICAL_TOPDIR` 16552 cd $sym_link_dir 16553 # Use -P flag to resolve symlinks in directories. 16554 cd `$THEPWDCMD -P` 16555 sym_link_dir=`$THEPWDCMD -P` 16556 # Resolve file symlinks 16557 while test $COUNTER -lt 20; do 16558 ISLINK=`$LS -l $sym_link_dir/$sym_link_file | $GREP '\->' | $SED -e 's/.*-> \(.*\)/\1/'` 16559 if test "x$ISLINK" == x; then 16560 # This is not a symbolic link! We are done! 16561 break 16562 fi 16563 # Again resolve directory symlinks since the target of the just found 16564 # link could be in a different directory 16565 cd `$DIRNAME $ISLINK` 16566 sym_link_dir=`$THEPWDCMD -P` 16567 sym_link_file=`$BASENAME $ISLINK` 16568 let COUNTER=COUNTER+1 16569 done 16570 cd $STARTDIR 16571 CANONICAL_TOPDIR=$sym_link_dir/$sym_link_file 16572 fi 16573 fi 16574 16575 16576 16577 # Locate the directory of this script. 16578 AUTOCONF_DIR=$TOPDIR/common/autoconf 16579 16580 # Setup username (for use in adhoc version strings etc) 16581 # Outer [ ] to quote m4. 16582 USERNAME=`$ECHO "$USER" | $TR -d -c '[a-z][A-Z][0-9]'` 16583 16584 16585 16586 # Check if it's a pure open build or if custom sources are to be used. 16587 16588 # Check whether --enable-openjdk-only was given. 16589 if test "${enable_openjdk_only+set}" = set; then : 16590 enableval=$enable_openjdk_only; 16591 else 16592 enable_openjdk_only="no" 16593 fi 16594 16595 16596 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if custom source is suppressed (openjdk-only)" >&5 16597 $as_echo_n "checking if custom source is suppressed (openjdk-only)... " >&6; } 16598 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $enable_openjdk_only" >&5 16599 $as_echo "$enable_openjdk_only" >&6; } 16600 if test "x$enable_openjdk_only" = "xyes"; then 16601 SUPPRESS_CUSTOM_EXTENSIONS="true" 16602 elif test "x$enable_openjdk_only" = "xno"; then 16603 SUPPRESS_CUSTOM_EXTENSIONS="false" 16604 else 16605 as_fn_error $? "Invalid value for --enable-openjdk-only: $enable_openjdk_only" "$LINENO" 5 16606 fi 16607 16608 # custom-make-dir is deprecated. Please use your custom-hook.m4 to override 16609 # the IncludeCustomExtension macro. 16610 16611 16612 # Check whether --with-custom-make-dir was given. 16613 if test "${with_custom_make_dir+set}" = set; then : 16614 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 16615 $as_echo "$as_me: WARNING: Option --with-custom-make-dir is deprecated and will be ignored." >&2;} 16616 fi 16617 16618 16619 16620 16621 # These are needed to be able to create a configuration name (and thus the output directory) 16622 16623 { $as_echo "$as_me:${as_lineno-$LINENO}: checking which variant of the JDK to build" >&5 16624 $as_echo_n "checking which variant of the JDK to build... " >&6; } 16625 16626 # Check whether --with-jdk-variant was given. 16627 if test "${with_jdk_variant+set}" = set; then : 16628 withval=$with_jdk_variant; 16629 fi 16630 16631 16632 if test "x$with_jdk_variant" = xnormal || test "x$with_jdk_variant" = x; then 16633 JDK_VARIANT="normal" 16634 else 16635 as_fn_error $? "The available JDK variants are: normal" "$LINENO" 5 16636 fi 16637 16638 16639 16640 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $JDK_VARIANT" >&5 16641 $as_echo "$JDK_VARIANT" >&6; } 16642 16643 16644 DEBUG_LEVEL="release" 16645 { $as_echo "$as_me:${as_lineno-$LINENO}: checking which debug level to use" >&5 16646 $as_echo_n "checking which debug level to use... " >&6; } 16647 # Check whether --enable-debug was given. 16648 if test "${enable_debug+set}" = set; then : 16649 enableval=$enable_debug; 16650 ENABLE_DEBUG="${enableval}" 16651 DEBUG_LEVEL="fastdebug" 16652 16653 else 16654 ENABLE_DEBUG="no" 16655 fi 16656 16657 16658 16659 # Check whether --with-debug-level was given. 16660 if test "${with_debug_level+set}" = set; then : 16661 withval=$with_debug_level; 16662 DEBUG_LEVEL="${withval}" 16663 if test "x$ENABLE_DEBUG" = xyes; then 16664 as_fn_error $? "You cannot use both --enable-debug and --with-debug-level at the same time." "$LINENO" 5 16665 fi 16666 16667 fi 16668 16669 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $DEBUG_LEVEL" >&5 16670 $as_echo "$DEBUG_LEVEL" >&6; } 16671 16672 if test "x$DEBUG_LEVEL" != xrelease && \ 16673 test "x$DEBUG_LEVEL" != xoptimized && \ 16674 test "x$DEBUG_LEVEL" != xfastdebug && \ 16675 test "x$DEBUG_LEVEL" != xslowdebug; then 16676 as_fn_error $? "Allowed debug levels are: release, fastdebug, slowdebug and optimized" "$LINENO" 5 16677 fi 16678 16679 # Translate DEBUG_LEVEL to debug level used by Hotspot 16680 HOTSPOT_DEBUG_LEVEL="$DEBUG_LEVEL" 16681 if test "x$DEBUG_LEVEL" = xrelease; then 16682 HOTSPOT_DEBUG_LEVEL="product" 16683 elif test "x$DEBUG_LEVEL" = xslowdebug; then 16684 HOTSPOT_DEBUG_LEVEL="debug" 16685 fi 16686 16687 if test "x$DEBUG_LEVEL" = xoptimized; then 16688 # The debug level 'optimized' is a little special because it is currently only 16689 # applicable to the HotSpot build where it means to build a completely 16690 # optimized version of the VM without any debugging code (like for the 16691 # 'release' debug level which is called 'product' in the HotSpot build) but 16692 # with the exception that it can contain additional code which is otherwise 16693 # protected by '#ifndef PRODUCT' macros. These 'optimized' builds are used to 16694 # test new and/or experimental features which are not intended for customer 16695 # shipment. Because these new features need to be tested and benchmarked in 16696 # real world scenarios, we want to build the containing JDK at the 'release' 16697 # debug level. 16698 DEBUG_LEVEL="release" 16699 fi 16700 16701 16702 16703 16704 16705 16706 # Check whether --with-jvm-variants was given. 16707 if test "${with_jvm_variants+set}" = set; then : 16708 withval=$with_jvm_variants; 16709 fi 16710 16711 16712 if test "x$with_jvm_variants" = x; then 16713 with_jvm_variants="server" 16714 fi 16715 JVM_VARIANTS_OPT="$with_jvm_variants" 16716 16717 # Has the user listed more than one variant? 16718 # Additional [] needed to keep m4 from mangling shell constructs. 16719 if [[ "$JVM_VARIANTS_OPT" =~ "," ]] ; then 16720 BUILDING_MULTIPLE_JVM_VARIANTS=true 16721 else 16722 BUILDING_MULTIPLE_JVM_VARIANTS=false 16723 fi 16724 # Replace the commas with AND for use in the build directory name. 16725 JVM_VARIANTS_WITH_AND=`$ECHO "$JVM_VARIANTS_OPT" | $SED -e 's/,/AND/g'` 16726 16727 { $as_echo "$as_me:${as_lineno-$LINENO}: checking which variants of the JVM to build" >&5 16728 $as_echo_n "checking which variants of the JVM to build... " >&6; } 16729 # JVM_VARIANTS is a space-separated list. 16730 # Also use minimal, not minimal1 (which is kept for backwards compatibility). 16731 JVM_VARIANTS=`$ECHO $JVM_VARIANTS_OPT | $SED -e 's/,/ /g' -e 's/minimal1/minimal/'` 16732 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $JVM_VARIANTS" >&5 16733 $as_echo "$JVM_VARIANTS" >&6; } 16734 16735 # Check that the selected variants are valid 16736 16737 # grep filter function inspired by a comment to http://stackoverflow.com/a/1617326 16738 # Notice that the original variant failes on SLES 10 and 11 16739 NEEDLE=${VALID_JVM_VARIANTS// /$'\n'} 16740 STACK=${JVM_VARIANTS// /$'\n'} 16741 INVALID_VARIANTS=`$GREP -Fvx "${NEEDLE}" <<< "${STACK}"` 16742 if test "x$INVALID_VARIANTS" != x; then 16743 { $as_echo "$as_me:${as_lineno-$LINENO}: Unknown variant(s) specified: $INVALID_VARIANTS" >&5 16744 $as_echo "$as_me: Unknown variant(s) specified: $INVALID_VARIANTS" >&6;} 16745 as_fn_error $? "The available JVM variants are: $VALID_JVM_VARIANTS" "$LINENO" 5 16746 fi 16747 16748 # All "special" variants share the same output directory ("server") 16749 VALID_MULTIPLE_JVM_VARIANTS="server client minimal" 16750 NEEDLE=${VALID_MULTIPLE_JVM_VARIANTS// /$'\n'} 16751 STACK=${JVM_VARIANTS// /$'\n'} 16752 INVALID_MULTIPLE_VARIANTS=`$GREP -Fvx "${NEEDLE}" <<< "${STACK}"` 16753 if test "x$INVALID_MULTIPLE_VARIANTS" != x && test "x$BUILDING_MULTIPLE_JVM_VARIANTS" = xtrue; then 16754 as_fn_error $? "You cannot build multiple variants with anything else than $VALID_MULTIPLE_JVM_VARIANTS." "$LINENO" 5 16755 fi 16756 16757 16758 16759 16760 if [[ " $JVM_VARIANTS " =~ " zero " ]] || [[ " $JVM_VARIANTS " =~ " zeroshark " ]] ; then 16761 # zero behaves as a platform and rewrites these values. This is really weird. :( 16762 # We are guaranteed that we do not build any other variants when building zero. 16763 HOTSPOT_TARGET_CPU=zero 16764 HOTSPOT_TARGET_CPU_ARCH=zero 16765 fi 16766 16767 16768 # With basic setup done, call the custom early hook. 16769 16770 16771 # Check if we have devkits, extra paths or sysroot set. 16772 16773 16774 # Check whether --with-devkit was given. 16775 if test "${with_devkit+set}" = set; then : 16776 withval=$with_devkit; 16777 16778 # Only process if variable expands to non-empty 16779 16780 if test "x$with_devkit" != x; then 16781 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 16782 16783 # Input might be given as Windows format, start by converting to 16784 # unix format. 16785 path="$with_devkit" 16786 new_path=`$CYGPATH -u "$path"` 16787 16788 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 16789 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 16790 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 16791 # "foo.exe" is OK but "foo" is an error. 16792 # 16793 # This test is therefore slightly more accurate than "test -f" to check for file precense. 16794 # It is also a way to make sure we got the proper file name for the real test later on. 16795 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 16796 if test "x$test_shortpath" = x; then 16797 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of with_devkit, which resolves as \"$path\", is invalid." >&5 16798 $as_echo "$as_me: The path of with_devkit, which resolves as \"$path\", is invalid." >&6;} 16799 as_fn_error $? "Cannot locate the the path of with_devkit" "$LINENO" 5 16800 fi 16801 16802 # Call helper function which possibly converts this using DOS-style short mode. 16803 # If so, the updated path is stored in $new_path. 16804 16805 input_path="$new_path" 16806 # Check if we need to convert this using DOS-style short mode. If the path 16807 # contains just simple characters, use it. Otherwise (spaces, weird characters), 16808 # take no chances and rewrite it. 16809 # Note: m4 eats our [], so we need to use [ and ] instead. 16810 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 16811 if test "x$has_forbidden_chars" != x; then 16812 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 16813 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 16814 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 16815 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 16816 # Going to short mode and back again did indeed matter. Since short mode is 16817 # case insensitive, let's make it lowercase to improve readability. 16818 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 16819 # Now convert it back to Unix-style (cygpath) 16820 input_path=`$CYGPATH -u "$shortmode_path"` 16821 new_path="$input_path" 16822 fi 16823 fi 16824 16825 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 16826 if test "x$test_cygdrive_prefix" = x; then 16827 # As a simple fix, exclude /usr/bin since it's not a real path. 16828 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 16829 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 16830 # a path prefixed by /cygdrive for fixpath to work. 16831 new_path="$CYGWIN_ROOT_PATH$input_path" 16832 fi 16833 fi 16834 16835 16836 if test "x$path" != "x$new_path"; then 16837 with_devkit="$new_path" 16838 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting with_devkit to \"$new_path\"" >&5 16839 $as_echo "$as_me: Rewriting with_devkit to \"$new_path\"" >&6;} 16840 fi 16841 16842 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 16843 16844 path="$with_devkit" 16845 has_colon=`$ECHO $path | $GREP ^.:` 16846 new_path="$path" 16847 if test "x$has_colon" = x; then 16848 # Not in mixed or Windows style, start by that. 16849 new_path=`cmd //c echo $path` 16850 fi 16851 16852 16853 input_path="$new_path" 16854 # Check if we need to convert this using DOS-style short mode. If the path 16855 # contains just simple characters, use it. Otherwise (spaces, weird characters), 16856 # take no chances and rewrite it. 16857 # Note: m4 eats our [], so we need to use [ and ] instead. 16858 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 16859 if test "x$has_forbidden_chars" != x; then 16860 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 16861 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 16862 fi 16863 16864 16865 windows_path="$new_path" 16866 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 16867 unix_path=`$CYGPATH -u "$windows_path"` 16868 new_path="$unix_path" 16869 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 16870 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 16871 new_path="$unix_path" 16872 fi 16873 16874 if test "x$path" != "x$new_path"; then 16875 with_devkit="$new_path" 16876 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting with_devkit to \"$new_path\"" >&5 16877 $as_echo "$as_me: Rewriting with_devkit to \"$new_path\"" >&6;} 16878 fi 16879 16880 # Save the first 10 bytes of this path to the storage, so fixpath can work. 16881 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 16882 16883 else 16884 # We're on a unix platform. Hooray! :) 16885 path="$with_devkit" 16886 has_space=`$ECHO "$path" | $GREP " "` 16887 if test "x$has_space" != x; then 16888 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of with_devkit, which resolves as \"$path\", is invalid." >&5 16889 $as_echo "$as_me: The path of with_devkit, which resolves as \"$path\", is invalid." >&6;} 16890 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 16891 fi 16892 16893 # Use eval to expand a potential ~ 16894 eval path="$path" 16895 if test ! -f "$path" && test ! -d "$path"; then 16896 as_fn_error $? "The path of with_devkit, which resolves as \"$path\", is not found." "$LINENO" 5 16897 fi 16898 16899 if test -d "$path"; then 16900 with_devkit="`cd "$path"; $THEPWDCMD -L`" 16901 else 16902 dir="`$DIRNAME "$path"`" 16903 base="`$BASENAME "$path"`" 16904 with_devkit="`cd "$dir"; $THEPWDCMD -L`/$base" 16905 fi 16906 fi 16907 fi 16908 16909 DEVKIT_ROOT="$with_devkit" 16910 # Check for a meta data info file in the root of the devkit 16911 if test -f "$DEVKIT_ROOT/devkit.info"; then 16912 . $DEVKIT_ROOT/devkit.info 16913 # This potentially sets the following: 16914 # A descriptive name of the devkit 16915 16916 if test "x$DEVKIT_NAME" = x; then 16917 eval DEVKIT_NAME="\${DEVKIT_NAME_${OPENJDK_TARGET_CPU}}" 16918 fi 16919 16920 # Corresponds to --with-extra-path 16921 16922 if test "x$DEVKIT_EXTRA_PATH" = x; then 16923 eval DEVKIT_EXTRA_PATH="\${DEVKIT_EXTRA_PATH_${OPENJDK_TARGET_CPU}}" 16924 fi 16925 16926 # Corresponds to --with-toolchain-path 16927 16928 if test "x$DEVKIT_TOOLCHAIN_PATH" = x; then 16929 eval DEVKIT_TOOLCHAIN_PATH="\${DEVKIT_TOOLCHAIN_PATH_${OPENJDK_TARGET_CPU}}" 16930 fi 16931 16932 # Corresponds to --with-sysroot 16933 16934 if test "x$DEVKIT_SYSROOT" = x; then 16935 eval DEVKIT_SYSROOT="\${DEVKIT_SYSROOT_${OPENJDK_TARGET_CPU}}" 16936 fi 16937 16938 16939 # Identifies the Visual Studio version in the devkit 16940 16941 if test "x$DEVKIT_VS_VERSION" = x; then 16942 eval DEVKIT_VS_VERSION="\${DEVKIT_VS_VERSION_${OPENJDK_TARGET_CPU}}" 16943 fi 16944 16945 # The Visual Studio include environment variable 16946 16947 if test "x$DEVKIT_VS_INCLUDE" = x; then 16948 eval DEVKIT_VS_INCLUDE="\${DEVKIT_VS_INCLUDE_${OPENJDK_TARGET_CPU}}" 16949 fi 16950 16951 # The Visual Studio lib environment variable 16952 16953 if test "x$DEVKIT_VS_LIB" = x; then 16954 eval DEVKIT_VS_LIB="\${DEVKIT_VS_LIB_${OPENJDK_TARGET_CPU}}" 16955 fi 16956 16957 # Corresponds to --with-msvcr-dll 16958 16959 if test "x$DEVKIT_MSVCR_DLL" = x; then 16960 eval DEVKIT_MSVCR_DLL="\${DEVKIT_MSVCR_DLL_${OPENJDK_TARGET_CPU}}" 16961 fi 16962 16963 # Corresponds to --with-msvcp-dll 16964 16965 if test "x$DEVKIT_MSVCP_DLL" = x; then 16966 eval DEVKIT_MSVCP_DLL="\${DEVKIT_MSVCP_DLL_${OPENJDK_TARGET_CPU}}" 16967 fi 16968 16969 fi 16970 16971 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for devkit" >&5 16972 $as_echo_n "checking for devkit... " >&6; } 16973 if test "x$DEVKIT_NAME" != x; then 16974 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $DEVKIT_NAME in $DEVKIT_ROOT" >&5 16975 $as_echo "$DEVKIT_NAME in $DEVKIT_ROOT" >&6; } 16976 else 16977 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $DEVKIT_ROOT" >&5 16978 $as_echo "$DEVKIT_ROOT" >&6; } 16979 fi 16980 16981 16982 if test "x$DEVKIT_EXTRA_PATH" != x; then 16983 if test "x$EXTRA_PATH" = x; then 16984 EXTRA_PATH="$DEVKIT_EXTRA_PATH" 16985 else 16986 EXTRA_PATH="$DEVKIT_EXTRA_PATH:$EXTRA_PATH" 16987 fi 16988 fi 16989 16990 16991 # Fallback default of just /bin if DEVKIT_PATH is not defined 16992 if test "x$DEVKIT_TOOLCHAIN_PATH" = x; then 16993 DEVKIT_TOOLCHAIN_PATH="$DEVKIT_ROOT/bin" 16994 fi 16995 16996 if test "x$DEVKIT_TOOLCHAIN_PATH" != x; then 16997 if test "x$TOOLCHAIN_PATH" = x; then 16998 TOOLCHAIN_PATH="$DEVKIT_TOOLCHAIN_PATH" 16999 else 17000 TOOLCHAIN_PATH="$DEVKIT_TOOLCHAIN_PATH:$TOOLCHAIN_PATH" 17001 fi 17002 fi 17003 17004 17005 # If DEVKIT_SYSROOT is set, use that, otherwise try a couple of known 17006 # places for backwards compatiblity. 17007 if test "x$DEVKIT_SYSROOT" != x; then 17008 SYSROOT="$DEVKIT_SYSROOT" 17009 elif test -d "$DEVKIT_ROOT/$host_alias/libc"; then 17010 SYSROOT="$DEVKIT_ROOT/$host_alias/libc" 17011 elif test -d "$DEVKIT_ROOT/$host/sys-root"; then 17012 SYSROOT="$DEVKIT_ROOT/$host/sys-root" 17013 fi 17014 17015 17016 fi 17017 17018 17019 # You can force the sysroot if the sysroot encoded into the compiler tools 17020 # is not correct. 17021 17022 # Check whether --with-sys-root was given. 17023 if test "${with_sys_root+set}" = set; then : 17024 withval=$with_sys_root; SYSROOT=$with_sys_root 17025 17026 fi 17027 17028 17029 17030 # Check whether --with-sysroot was given. 17031 if test "${with_sysroot+set}" = set; then : 17032 withval=$with_sysroot; SYSROOT=$with_sysroot 17033 17034 fi 17035 17036 17037 17038 # Check whether --with-tools-dir was given. 17039 if test "${with_tools_dir+set}" = set; then : 17040 withval=$with_tools_dir; 17041 if test "x$with_tools_dir" != x; then 17042 if test "x$TOOLCHAIN_PATH" = x; then 17043 TOOLCHAIN_PATH="$with_tools_dir" 17044 else 17045 TOOLCHAIN_PATH="$with_tools_dir:$TOOLCHAIN_PATH" 17046 fi 17047 fi 17048 17049 17050 fi 17051 17052 17053 17054 # Check whether --with-toolchain-path was given. 17055 if test "${with_toolchain_path+set}" = set; then : 17056 withval=$with_toolchain_path; 17057 if test "x$with_toolchain_path" != x; then 17058 if test "x$TOOLCHAIN_PATH" = x; then 17059 TOOLCHAIN_PATH="$with_toolchain_path" 17060 else 17061 TOOLCHAIN_PATH="$with_toolchain_path:$TOOLCHAIN_PATH" 17062 fi 17063 fi 17064 17065 17066 fi 17067 17068 17069 17070 # Check whether --with-extra-path was given. 17071 if test "${with_extra_path+set}" = set; then : 17072 withval=$with_extra_path; 17073 if test "x$with_extra_path" != x; then 17074 if test "x$EXTRA_PATH" = x; then 17075 EXTRA_PATH="$with_extra_path" 17076 else 17077 EXTRA_PATH="$with_extra_path:$EXTRA_PATH" 17078 fi 17079 fi 17080 17081 17082 fi 17083 17084 17085 if test "x$OPENJDK_BUILD_OS" = "xmacosx"; then 17086 # If a devkit has been supplied, find xcodebuild in the toolchain_path. 17087 # If not, detect if Xcode is installed by running xcodebuild -version 17088 # if no Xcode installed, xcodebuild exits with 1 17089 # if Xcode is installed, even if xcode-select is misconfigured, then it exits with 0 17090 if test "x$DEVKIT_ROOT" != x || /usr/bin/xcodebuild -version >/dev/null 2>&1; then 17091 # We need to use xcodebuild in the toolchain dir provided by the user, this will 17092 # fall back on the stub binary in /usr/bin/xcodebuild 17093 # Extract the first word of "xcodebuild", so it can be a program name with args. 17094 set dummy xcodebuild; ac_word=$2 17095 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 17096 $as_echo_n "checking for $ac_word... " >&6; } 17097 if ${ac_cv_path_XCODEBUILD+:} false; then : 17098 $as_echo_n "(cached) " >&6 17099 else 17100 case $XCODEBUILD in 17101 [\\/]* | ?:[\\/]*) 17102 ac_cv_path_XCODEBUILD="$XCODEBUILD" # Let the user override the test with a path. 17103 ;; 17104 *) 17105 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 17106 for as_dir in $TOOLCHAIN_PATH 17107 do 17108 IFS=$as_save_IFS 17109 test -z "$as_dir" && as_dir=. 17110 for ac_exec_ext in '' $ac_executable_extensions; do 17111 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 17112 ac_cv_path_XCODEBUILD="$as_dir/$ac_word$ac_exec_ext" 17113 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 17114 break 2 17115 fi 17116 done 17117 done 17118 IFS=$as_save_IFS 17119 17120 test -z "$ac_cv_path_XCODEBUILD" && ac_cv_path_XCODEBUILD="/usr/bin/xcodebuild" 17121 ;; 17122 esac 17123 fi 17124 XCODEBUILD=$ac_cv_path_XCODEBUILD 17125 if test -n "$XCODEBUILD"; then 17126 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $XCODEBUILD" >&5 17127 $as_echo "$XCODEBUILD" >&6; } 17128 else 17129 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 17130 $as_echo "no" >&6; } 17131 fi 17132 17133 17134 else 17135 # this should result in SYSROOT being empty, unless --with-sysroot is provided 17136 # when only the command line tools are installed there are no SDKs, so headers 17137 # are copied into the system frameworks 17138 XCODEBUILD= 17139 17140 fi 17141 17142 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for sdk name" >&5 17143 $as_echo_n "checking for sdk name... " >&6; } 17144 17145 # Check whether --with-sdk-name was given. 17146 if test "${with_sdk_name+set}" = set; then : 17147 withval=$with_sdk_name; SDKNAME=$with_sdk_name 17148 17149 fi 17150 17151 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $SDKNAME" >&5 17152 $as_echo "$SDKNAME" >&6; } 17153 17154 # if toolchain path is specified then don't rely on system headers, they may not compile 17155 HAVE_SYSTEM_FRAMEWORK_HEADERS=0 17156 test -z "$TOOLCHAIN_PATH" && \ 17157 HAVE_SYSTEM_FRAMEWORK_HEADERS=`test ! -f /System/Library/Frameworks/Foundation.framework/Headers/Foundation.h; echo $?` 17158 17159 if test -z "$SYSROOT"; then 17160 if test -n "$XCODEBUILD"; then 17161 # if we don't have system headers, use default SDK name (last resort) 17162 if test -z "$SDKNAME" -a $HAVE_SYSTEM_FRAMEWORK_HEADERS -eq 0; then 17163 SDKNAME=${SDKNAME:-macosx} 17164 fi 17165 17166 if test -n "$SDKNAME"; then 17167 # Call xcodebuild to determine SYSROOT 17168 SYSROOT=`"$XCODEBUILD" -sdk $SDKNAME -version | $GREP '^Path: ' | $SED 's/Path: //'` 17169 fi 17170 else 17171 if test $HAVE_SYSTEM_FRAMEWORK_HEADERS -eq 0; then 17172 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 17173 fi 17174 fi 17175 else 17176 # warn user if --with-sdk-name was also set 17177 if test -n "$with_sdk_name"; then 17178 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Both SYSROOT and --with-sdk-name are set, only SYSROOT will be used" >&5 17179 $as_echo "$as_me: WARNING: Both SYSROOT and --with-sdk-name are set, only SYSROOT will be used" >&2;} 17180 fi 17181 fi 17182 17183 if test $HAVE_SYSTEM_FRAMEWORK_HEADERS -eq 0 -a -z "$SYSROOT"; then 17184 # If no system framework headers, then SYSROOT must be set, or we won't build 17185 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 17186 fi 17187 17188 # Perform a basic sanity test 17189 if test ! -f "$SYSROOT/System/Library/Frameworks/Foundation.framework/Headers/Foundation.h"; then 17190 if test -z "$SYSROOT"; then 17191 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 17192 else 17193 as_fn_error $? "Invalid SDK or SYSROOT path, dependent framework headers not found" "$LINENO" 5 17194 fi 17195 fi 17196 17197 # set SDKROOT too, Xcode tools will pick it up 17198 SDKROOT=$SYSROOT 17199 17200 fi 17201 17202 # Prepend the extra path to the global path 17203 17204 if test "x$EXTRA_PATH" != x; then 17205 if test "x$PATH" = x; then 17206 PATH="$EXTRA_PATH" 17207 else 17208 PATH="$EXTRA_PATH:$PATH" 17209 fi 17210 fi 17211 17212 17213 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for sysroot" >&5 17214 $as_echo_n "checking for sysroot... " >&6; } 17215 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $SYSROOT" >&5 17216 $as_echo "$SYSROOT" >&6; } 17217 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for toolchain path" >&5 17218 $as_echo_n "checking for toolchain path... " >&6; } 17219 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $TOOLCHAIN_PATH" >&5 17220 $as_echo "$TOOLCHAIN_PATH" >&6; } 17221 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for extra path" >&5 17222 $as_echo_n "checking for extra path... " >&6; } 17223 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $EXTRA_PATH" >&5 17224 $as_echo "$EXTRA_PATH" >&6; } 17225 17226 17227 # To properly create a configuration name, we need to have the OpenJDK target 17228 # and options (variants and debug level) parsed. 17229 17230 17231 17232 # Check whether --with-conf-name was given. 17233 if test "${with_conf_name+set}" = set; then : 17234 withval=$with_conf_name; CONF_NAME=${with_conf_name} 17235 fi 17236 17237 17238 # Test from where we are running configure, in or outside of src root. 17239 { $as_echo "$as_me:${as_lineno-$LINENO}: checking where to store configuration" >&5 17240 $as_echo_n "checking where to store configuration... " >&6; } 17241 if test "x$CURDIR" = "x$SRC_ROOT" || test "x$CURDIR" = "x$SRC_ROOT/common" \ 17242 || test "x$CURDIR" = "x$SRC_ROOT/common/autoconf" \ 17243 || test "x$CURDIR" = "x$SRC_ROOT/make" ; then 17244 # We are running configure from the src root. 17245 # Create a default ./build/target-variant-debuglevel output root. 17246 if test "x${CONF_NAME}" = x; then 17247 { $as_echo "$as_me:${as_lineno-$LINENO}: result: in default location" >&5 17248 $as_echo "in default location" >&6; } 17249 CONF_NAME="${OPENJDK_TARGET_OS}-${OPENJDK_TARGET_CPU}-${JDK_VARIANT}-${JVM_VARIANTS_WITH_AND}-${DEBUG_LEVEL}" 17250 else 17251 { $as_echo "$as_me:${as_lineno-$LINENO}: result: in build directory with custom name" >&5 17252 $as_echo "in build directory with custom name" >&6; } 17253 fi 17254 OUTPUT_ROOT="$SRC_ROOT/build/${CONF_NAME}" 17255 $MKDIR -p "$OUTPUT_ROOT" 17256 if test ! -d "$OUTPUT_ROOT"; then 17257 as_fn_error $? "Could not create build directory $OUTPUT_ROOT" "$LINENO" 5 17258 fi 17259 else 17260 # We are running configure from outside of the src dir. 17261 # Then use the current directory as output dir! 17262 # If configuration is situated in normal build directory, just use the build 17263 # directory name as configuration name, otherwise use the complete path. 17264 if test "x${CONF_NAME}" = x; then 17265 CONF_NAME=`$ECHO $CURDIR | $SED -e "s!^${SRC_ROOT}/build/!!"` 17266 fi 17267 OUTPUT_ROOT="$CURDIR" 17268 { $as_echo "$as_me:${as_lineno-$LINENO}: result: in current directory" >&5 17269 $as_echo "in current directory" >&6; } 17270 17271 # WARNING: This might be a bad thing to do. You need to be sure you want to 17272 # have a configuration in this directory. Do some sanity checks! 17273 17274 if test ! -e "$OUTPUT_ROOT/spec.gmk"; then 17275 # If we have a spec.gmk, we have run here before and we are OK. Otherwise, check for 17276 # other files 17277 files_present=`$LS $OUTPUT_ROOT` 17278 # Configure has already touched config.log and confdefs.h in the current dir when this check 17279 # is performed. 17280 filtered_files=`$ECHO "$files_present" \ 17281 | $SED -e 's/config.log//g' \ 17282 -e 's/configure.log//g' \ 17283 -e 's/confdefs.h//g' \ 17284 -e 's/ //g' \ 17285 | $TR -d '\n'` 17286 if test "x$filtered_files" != x; then 17287 { $as_echo "$as_me:${as_lineno-$LINENO}: Current directory is $CURDIR." >&5 17288 $as_echo "$as_me: Current directory is $CURDIR." >&6;} 17289 { $as_echo "$as_me:${as_lineno-$LINENO}: Since this is not the source root, configure will output the configuration here" >&5 17290 $as_echo "$as_me: Since this is not the source root, configure will output the configuration here" >&6;} 17291 { $as_echo "$as_me:${as_lineno-$LINENO}: (as opposed to creating a configuration in <src_root>/build/<conf-name>)." >&5 17292 $as_echo "$as_me: (as opposed to creating a configuration in <src_root>/build/<conf-name>)." >&6;} 17293 { $as_echo "$as_me:${as_lineno-$LINENO}: However, this directory is not empty. This is not allowed, since it could" >&5 17294 $as_echo "$as_me: However, this directory is not empty. This is not allowed, since it could" >&6;} 17295 { $as_echo "$as_me:${as_lineno-$LINENO}: seriously mess up just about everything." >&5 17296 $as_echo "$as_me: seriously mess up just about everything." >&6;} 17297 { $as_echo "$as_me:${as_lineno-$LINENO}: Try 'cd $SRC_ROOT' and restart configure" >&5 17298 $as_echo "$as_me: Try 'cd $SRC_ROOT' and restart configure" >&6;} 17299 { $as_echo "$as_me:${as_lineno-$LINENO}: (or create a new empty directory and cd to it)." >&5 17300 $as_echo "$as_me: (or create a new empty directory and cd to it)." >&6;} 17301 as_fn_error $? "Will not continue creating configuration in $CURDIR" "$LINENO" 5 17302 fi 17303 fi 17304 fi 17305 { $as_echo "$as_me:${as_lineno-$LINENO}: checking what configuration name to use" >&5 17306 $as_echo_n "checking what configuration name to use... " >&6; } 17307 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CONF_NAME" >&5 17308 $as_echo "$CONF_NAME" >&6; } 17309 17310 17311 # Only process if variable expands to non-empty 17312 17313 if test "x$OUTPUT_ROOT" != x; then 17314 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 17315 17316 # Input might be given as Windows format, start by converting to 17317 # unix format. 17318 path="$OUTPUT_ROOT" 17319 new_path=`$CYGPATH -u "$path"` 17320 17321 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 17322 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 17323 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 17324 # "foo.exe" is OK but "foo" is an error. 17325 # 17326 # This test is therefore slightly more accurate than "test -f" to check for file precense. 17327 # It is also a way to make sure we got the proper file name for the real test later on. 17328 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 17329 if test "x$test_shortpath" = x; then 17330 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of OUTPUT_ROOT, which resolves as \"$path\", is invalid." >&5 17331 $as_echo "$as_me: The path of OUTPUT_ROOT, which resolves as \"$path\", is invalid." >&6;} 17332 as_fn_error $? "Cannot locate the the path of OUTPUT_ROOT" "$LINENO" 5 17333 fi 17334 17335 # Call helper function which possibly converts this using DOS-style short mode. 17336 # If so, the updated path is stored in $new_path. 17337 17338 input_path="$new_path" 17339 # Check if we need to convert this using DOS-style short mode. If the path 17340 # contains just simple characters, use it. Otherwise (spaces, weird characters), 17341 # take no chances and rewrite it. 17342 # Note: m4 eats our [], so we need to use [ and ] instead. 17343 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 17344 if test "x$has_forbidden_chars" != x; then 17345 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 17346 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 17347 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 17348 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 17349 # Going to short mode and back again did indeed matter. Since short mode is 17350 # case insensitive, let's make it lowercase to improve readability. 17351 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 17352 # Now convert it back to Unix-style (cygpath) 17353 input_path=`$CYGPATH -u "$shortmode_path"` 17354 new_path="$input_path" 17355 fi 17356 fi 17357 17358 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 17359 if test "x$test_cygdrive_prefix" = x; then 17360 # As a simple fix, exclude /usr/bin since it's not a real path. 17361 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 17362 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 17363 # a path prefixed by /cygdrive for fixpath to work. 17364 new_path="$CYGWIN_ROOT_PATH$input_path" 17365 fi 17366 fi 17367 17368 17369 if test "x$path" != "x$new_path"; then 17370 OUTPUT_ROOT="$new_path" 17371 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting OUTPUT_ROOT to \"$new_path\"" >&5 17372 $as_echo "$as_me: Rewriting OUTPUT_ROOT to \"$new_path\"" >&6;} 17373 fi 17374 17375 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 17376 17377 path="$OUTPUT_ROOT" 17378 has_colon=`$ECHO $path | $GREP ^.:` 17379 new_path="$path" 17380 if test "x$has_colon" = x; then 17381 # Not in mixed or Windows style, start by that. 17382 new_path=`cmd //c echo $path` 17383 fi 17384 17385 17386 input_path="$new_path" 17387 # Check if we need to convert this using DOS-style short mode. If the path 17388 # contains just simple characters, use it. Otherwise (spaces, weird characters), 17389 # take no chances and rewrite it. 17390 # Note: m4 eats our [], so we need to use [ and ] instead. 17391 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 17392 if test "x$has_forbidden_chars" != x; then 17393 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 17394 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 17395 fi 17396 17397 17398 windows_path="$new_path" 17399 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 17400 unix_path=`$CYGPATH -u "$windows_path"` 17401 new_path="$unix_path" 17402 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 17403 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 17404 new_path="$unix_path" 17405 fi 17406 17407 if test "x$path" != "x$new_path"; then 17408 OUTPUT_ROOT="$new_path" 17409 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting OUTPUT_ROOT to \"$new_path\"" >&5 17410 $as_echo "$as_me: Rewriting OUTPUT_ROOT to \"$new_path\"" >&6;} 17411 fi 17412 17413 # Save the first 10 bytes of this path to the storage, so fixpath can work. 17414 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 17415 17416 else 17417 # We're on a unix platform. Hooray! :) 17418 path="$OUTPUT_ROOT" 17419 has_space=`$ECHO "$path" | $GREP " "` 17420 if test "x$has_space" != x; then 17421 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of OUTPUT_ROOT, which resolves as \"$path\", is invalid." >&5 17422 $as_echo "$as_me: The path of OUTPUT_ROOT, which resolves as \"$path\", is invalid." >&6;} 17423 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 17424 fi 17425 17426 # Use eval to expand a potential ~ 17427 eval path="$path" 17428 if test ! -f "$path" && test ! -d "$path"; then 17429 as_fn_error $? "The path of OUTPUT_ROOT, which resolves as \"$path\", is not found." "$LINENO" 5 17430 fi 17431 17432 if test -d "$path"; then 17433 OUTPUT_ROOT="`cd "$path"; $THEPWDCMD -L`" 17434 else 17435 dir="`$DIRNAME "$path"`" 17436 base="`$BASENAME "$path"`" 17437 OUTPUT_ROOT="`cd "$dir"; $THEPWDCMD -L`/$base" 17438 fi 17439 fi 17440 fi 17441 17442 17443 CONFIGURESUPPORT_OUTPUTDIR="$OUTPUT_ROOT/configure-support" 17444 $MKDIR -p "$CONFIGURESUPPORT_OUTPUTDIR" 17445 17446 SPEC=$OUTPUT_ROOT/spec.gmk 17447 17448 CONF_NAME=$CONF_NAME 17449 17450 OUTPUT_ROOT=$OUTPUT_ROOT 17451 17452 17453 17454 # The spec.gmk file contains all variables for the make system. 17455 ac_config_files="$ac_config_files $OUTPUT_ROOT/spec.gmk:$AUTOCONF_DIR/spec.gmk.in" 17456 17457 # The bootcycle-spec.gmk file contains support for boot cycle builds. 17458 ac_config_files="$ac_config_files $OUTPUT_ROOT/bootcycle-spec.gmk:$AUTOCONF_DIR/bootcycle-spec.gmk.in" 17459 17460 # The buildjdk-spec.gmk file contains support for building a buildjdk when cross compiling. 17461 ac_config_files="$ac_config_files $OUTPUT_ROOT/buildjdk-spec.gmk:$AUTOCONF_DIR/buildjdk-spec.gmk.in" 17462 17463 # The compare.sh is used to compare the build output to other builds. 17464 ac_config_files="$ac_config_files $OUTPUT_ROOT/compare.sh:$AUTOCONF_DIR/compare.sh.in" 17465 17466 # The generated Makefile knows where the spec.gmk is and where the source is. 17467 # You can run make from the OUTPUT_ROOT, or from the top-level Makefile 17468 # which will look for generated configurations 17469 ac_config_files="$ac_config_files $OUTPUT_ROOT/Makefile:$AUTOCONF_DIR/Makefile.in" 17470 17471 17472 17473 # Must be done before we can call HELP_MSG_MISSING_DEPENDENCY. 17474 17475 for ac_prog in apt-get yum port pkgutil pkgadd 17476 do 17477 # Extract the first word of "$ac_prog", so it can be a program name with args. 17478 set dummy $ac_prog; ac_word=$2 17479 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 17480 $as_echo_n "checking for $ac_word... " >&6; } 17481 if ${ac_cv_prog_PKGHANDLER+:} false; then : 17482 $as_echo_n "(cached) " >&6 17483 else 17484 if test -n "$PKGHANDLER"; then 17485 ac_cv_prog_PKGHANDLER="$PKGHANDLER" # Let the user override the test. 17486 else 17487 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 17488 for as_dir in $PATH 17489 do 17490 IFS=$as_save_IFS 17491 test -z "$as_dir" && as_dir=. 17492 for ac_exec_ext in '' $ac_executable_extensions; do 17493 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 17494 ac_cv_prog_PKGHANDLER="$ac_prog" 17495 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 17496 break 2 17497 fi 17498 done 17499 done 17500 IFS=$as_save_IFS 17501 17502 fi 17503 fi 17504 PKGHANDLER=$ac_cv_prog_PKGHANDLER 17505 if test -n "$PKGHANDLER"; then 17506 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $PKGHANDLER" >&5 17507 $as_echo "$PKGHANDLER" >&6; } 17508 else 17509 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 17510 $as_echo "no" >&6; } 17511 fi 17512 17513 17514 test -n "$PKGHANDLER" && break 17515 done 17516 17517 17518 17519 # Setup tools that requires more complex handling, or that is not needed by the configure script. 17520 17521 17522 17523 # Publish this variable in the help. 17524 17525 17526 if [ -z "${MAKE+x}" ]; then 17527 # The variable is not set by user, try to locate tool using the code snippet 17528 17529 # Try our hardest to locate a correct version of GNU make 17530 for ac_prog in gmake 17531 do 17532 # Extract the first word of "$ac_prog", so it can be a program name with args. 17533 set dummy $ac_prog; ac_word=$2 17534 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 17535 $as_echo_n "checking for $ac_word... " >&6; } 17536 if ${ac_cv_path_CHECK_GMAKE+:} false; then : 17537 $as_echo_n "(cached) " >&6 17538 else 17539 case $CHECK_GMAKE in 17540 [\\/]* | ?:[\\/]*) 17541 ac_cv_path_CHECK_GMAKE="$CHECK_GMAKE" # Let the user override the test with a path. 17542 ;; 17543 *) 17544 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 17545 for as_dir in $PATH 17546 do 17547 IFS=$as_save_IFS 17548 test -z "$as_dir" && as_dir=. 17549 for ac_exec_ext in '' $ac_executable_extensions; do 17550 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 17551 ac_cv_path_CHECK_GMAKE="$as_dir/$ac_word$ac_exec_ext" 17552 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 17553 break 2 17554 fi 17555 done 17556 done 17557 IFS=$as_save_IFS 17558 17559 ;; 17560 esac 17561 fi 17562 CHECK_GMAKE=$ac_cv_path_CHECK_GMAKE 17563 if test -n "$CHECK_GMAKE"; then 17564 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CHECK_GMAKE" >&5 17565 $as_echo "$CHECK_GMAKE" >&6; } 17566 else 17567 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 17568 $as_echo "no" >&6; } 17569 fi 17570 17571 17572 test -n "$CHECK_GMAKE" && break 17573 done 17574 17575 17576 MAKE_CANDIDATE=""$CHECK_GMAKE"" 17577 DESCRIPTION="gmake in PATH" 17578 17579 # On Cygwin, we require a newer version of make than on other platforms 17580 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 17581 MAKE_VERSION_EXPR="-e 4\." 17582 MAKE_REQUIRED_VERSION="4.0" 17583 else 17584 MAKE_VERSION_EXPR="-e 3\.8[12] -e 4\." 17585 MAKE_REQUIRED_VERSION="3.81" 17586 fi 17587 17588 if test "x$MAKE_CANDIDATE" != x; then 17589 { $as_echo "$as_me:${as_lineno-$LINENO}: Testing potential make at $MAKE_CANDIDATE, found using $DESCRIPTION" >&5 17590 $as_echo "$as_me: Testing potential make at $MAKE_CANDIDATE, found using $DESCRIPTION" >&6;} 17591 MAKE_VERSION_STRING=`$MAKE_CANDIDATE --version | $HEAD -n 1` 17592 IS_GNU_MAKE=`$ECHO $MAKE_VERSION_STRING | $GREP 'GNU Make'` 17593 if test "x$IS_GNU_MAKE" = x; then 17594 { $as_echo "$as_me:${as_lineno-$LINENO}: Found potential make at $MAKE_CANDIDATE, however, this is not GNU Make. Ignoring." >&5 17595 $as_echo "$as_me: Found potential make at $MAKE_CANDIDATE, however, this is not GNU Make. Ignoring." >&6;} 17596 else 17597 IS_MODERN_MAKE=`$ECHO $MAKE_VERSION_STRING | $GREP $MAKE_VERSION_EXPR` 17598 if test "x$IS_MODERN_MAKE" = x; then 17599 { $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 17600 $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;} 17601 else 17602 if test "x$OPENJDK_BUILD_OS" = "xwindows"; then 17603 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 17604 MAKE_EXPECTED_ENV='cygwin' 17605 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 17606 MAKE_EXPECTED_ENV='msys' 17607 else 17608 as_fn_error $? "Unknown Windows environment" "$LINENO" 5 17609 fi 17610 MAKE_BUILT_FOR=`$MAKE_CANDIDATE --version | $GREP -i 'built for'` 17611 IS_MAKE_CORRECT_ENV=`$ECHO $MAKE_BUILT_FOR | $GREP $MAKE_EXPECTED_ENV` 17612 else 17613 # Not relevant for non-Windows 17614 IS_MAKE_CORRECT_ENV=true 17615 fi 17616 if test "x$IS_MAKE_CORRECT_ENV" = x; then 17617 { $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 17618 $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;} 17619 else 17620 FOUND_MAKE=$MAKE_CANDIDATE 17621 17622 # Only process if variable expands to non-empty 17623 17624 if test "x$FOUND_MAKE" != x; then 17625 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 17626 17627 # First separate the path from the arguments. This will split at the first 17628 # space. 17629 complete="$FOUND_MAKE" 17630 path="${complete%% *}" 17631 tmp="$complete EOL" 17632 arguments="${tmp#* }" 17633 17634 # Input might be given as Windows format, start by converting to 17635 # unix format. 17636 new_path=`$CYGPATH -u "$path"` 17637 17638 # Now try to locate executable using which 17639 new_path=`$WHICH "$new_path" 2> /dev/null` 17640 # bat and cmd files are not always considered executable in cygwin causing which 17641 # to not find them 17642 if test "x$new_path" = x \ 17643 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 17644 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 17645 new_path=`$CYGPATH -u "$path"` 17646 fi 17647 if test "x$new_path" = x; then 17648 # Oops. Which didn't find the executable. 17649 # The splitting of arguments from the executable at a space might have been incorrect, 17650 # since paths with space are more likely in Windows. Give it another try with the whole 17651 # argument. 17652 path="$complete" 17653 arguments="EOL" 17654 new_path=`$CYGPATH -u "$path"` 17655 new_path=`$WHICH "$new_path" 2> /dev/null` 17656 # bat and cmd files are not always considered executable in cygwin causing which 17657 # to not find them 17658 if test "x$new_path" = x \ 17659 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 17660 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 17661 new_path=`$CYGPATH -u "$path"` 17662 fi 17663 if test "x$new_path" = x; then 17664 # It's still not found. Now this is an unrecoverable error. 17665 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of FOUND_MAKE, which resolves as \"$complete\", is not found." >&5 17666 $as_echo "$as_me: The path of FOUND_MAKE, which resolves as \"$complete\", is not found." >&6;} 17667 has_space=`$ECHO "$complete" | $GREP " "` 17668 if test "x$has_space" != x; then 17669 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 17670 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 17671 fi 17672 as_fn_error $? "Cannot locate the the path of FOUND_MAKE" "$LINENO" 5 17673 fi 17674 fi 17675 17676 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 17677 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 17678 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 17679 # "foo.exe" is OK but "foo" is an error. 17680 # 17681 # This test is therefore slightly more accurate than "test -f" to check for file presence. 17682 # It is also a way to make sure we got the proper file name for the real test later on. 17683 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 17684 if test "x$test_shortpath" = x; then 17685 # Short path failed, file does not exist as specified. 17686 # Try adding .exe or .cmd 17687 if test -f "${new_path}.exe"; then 17688 input_to_shortpath="${new_path}.exe" 17689 elif test -f "${new_path}.cmd"; then 17690 input_to_shortpath="${new_path}.cmd" 17691 else 17692 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of FOUND_MAKE, which resolves as \"$new_path\", is invalid." >&5 17693 $as_echo "$as_me: The path of FOUND_MAKE, which resolves as \"$new_path\", is invalid." >&6;} 17694 { $as_echo "$as_me:${as_lineno-$LINENO}: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&5 17695 $as_echo "$as_me: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&6;} 17696 as_fn_error $? "Cannot locate the the path of FOUND_MAKE" "$LINENO" 5 17697 fi 17698 else 17699 input_to_shortpath="$new_path" 17700 fi 17701 17702 # Call helper function which possibly converts this using DOS-style short mode. 17703 # If so, the updated path is stored in $new_path. 17704 new_path="$input_to_shortpath" 17705 17706 input_path="$input_to_shortpath" 17707 # Check if we need to convert this using DOS-style short mode. If the path 17708 # contains just simple characters, use it. Otherwise (spaces, weird characters), 17709 # take no chances and rewrite it. 17710 # Note: m4 eats our [], so we need to use [ and ] instead. 17711 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 17712 if test "x$has_forbidden_chars" != x; then 17713 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 17714 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 17715 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 17716 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 17717 # Going to short mode and back again did indeed matter. Since short mode is 17718 # case insensitive, let's make it lowercase to improve readability. 17719 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 17720 # Now convert it back to Unix-style (cygpath) 17721 input_path=`$CYGPATH -u "$shortmode_path"` 17722 new_path="$input_path" 17723 fi 17724 fi 17725 17726 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 17727 if test "x$test_cygdrive_prefix" = x; then 17728 # As a simple fix, exclude /usr/bin since it's not a real path. 17729 if test "x`$ECHO $input_to_shortpath | $GREP ^/usr/bin/`" = x; then 17730 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 17731 # a path prefixed by /cygdrive for fixpath to work. 17732 new_path="$CYGWIN_ROOT_PATH$input_path" 17733 fi 17734 fi 17735 17736 # remove trailing .exe if any 17737 new_path="${new_path/%.exe/}" 17738 17739 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 17740 17741 # First separate the path from the arguments. This will split at the first 17742 # space. 17743 complete="$FOUND_MAKE" 17744 path="${complete%% *}" 17745 tmp="$complete EOL" 17746 arguments="${tmp#* }" 17747 17748 # Input might be given as Windows format, start by converting to 17749 # unix format. 17750 new_path="$path" 17751 17752 windows_path="$new_path" 17753 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 17754 unix_path=`$CYGPATH -u "$windows_path"` 17755 new_path="$unix_path" 17756 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 17757 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 17758 new_path="$unix_path" 17759 fi 17760 17761 17762 # Now try to locate executable using which 17763 new_path=`$WHICH "$new_path" 2> /dev/null` 17764 17765 if test "x$new_path" = x; then 17766 # Oops. Which didn't find the executable. 17767 # The splitting of arguments from the executable at a space might have been incorrect, 17768 # since paths with space are more likely in Windows. Give it another try with the whole 17769 # argument. 17770 path="$complete" 17771 arguments="EOL" 17772 new_path="$path" 17773 17774 windows_path="$new_path" 17775 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 17776 unix_path=`$CYGPATH -u "$windows_path"` 17777 new_path="$unix_path" 17778 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 17779 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 17780 new_path="$unix_path" 17781 fi 17782 17783 17784 new_path=`$WHICH "$new_path" 2> /dev/null` 17785 # bat and cmd files are not always considered executable in MSYS causing which 17786 # to not find them 17787 if test "x$new_path" = x \ 17788 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 17789 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 17790 new_path="$path" 17791 17792 windows_path="$new_path" 17793 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 17794 unix_path=`$CYGPATH -u "$windows_path"` 17795 new_path="$unix_path" 17796 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 17797 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 17798 new_path="$unix_path" 17799 fi 17800 17801 fi 17802 17803 if test "x$new_path" = x; then 17804 # It's still not found. Now this is an unrecoverable error. 17805 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of FOUND_MAKE, which resolves as \"$complete\", is not found." >&5 17806 $as_echo "$as_me: The path of FOUND_MAKE, which resolves as \"$complete\", is not found." >&6;} 17807 has_space=`$ECHO "$complete" | $GREP " "` 17808 if test "x$has_space" != x; then 17809 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 17810 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 17811 fi 17812 as_fn_error $? "Cannot locate the the path of FOUND_MAKE" "$LINENO" 5 17813 fi 17814 fi 17815 17816 # Now new_path has a complete unix path to the binary 17817 if test "x`$ECHO $new_path | $GREP ^/bin/`" != x; then 17818 # Keep paths in /bin as-is, but remove trailing .exe if any 17819 new_path="${new_path/%.exe/}" 17820 # Do not save /bin paths to all_fixpath_prefixes! 17821 else 17822 # Not in mixed or Windows style, start by that. 17823 new_path=`cmd //c echo $new_path` 17824 17825 input_path="$new_path" 17826 # Check if we need to convert this using DOS-style short mode. If the path 17827 # contains just simple characters, use it. Otherwise (spaces, weird characters), 17828 # take no chances and rewrite it. 17829 # Note: m4 eats our [], so we need to use [ and ] instead. 17830 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 17831 if test "x$has_forbidden_chars" != x; then 17832 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 17833 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 17834 fi 17835 17836 # Output is in $new_path 17837 17838 windows_path="$new_path" 17839 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 17840 unix_path=`$CYGPATH -u "$windows_path"` 17841 new_path="$unix_path" 17842 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 17843 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 17844 new_path="$unix_path" 17845 fi 17846 17847 # remove trailing .exe if any 17848 new_path="${new_path/%.exe/}" 17849 17850 # Save the first 10 bytes of this path to the storage, so fixpath can work. 17851 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 17852 fi 17853 17854 else 17855 # We're on a unix platform. Hooray! :) 17856 # First separate the path from the arguments. This will split at the first 17857 # space. 17858 complete="$FOUND_MAKE" 17859 path="${complete%% *}" 17860 tmp="$complete EOL" 17861 arguments="${tmp#* }" 17862 17863 # Cannot rely on the command "which" here since it doesn't always work. 17864 is_absolute_path=`$ECHO "$path" | $GREP ^/` 17865 if test -z "$is_absolute_path"; then 17866 # Path to executable is not absolute. Find it. 17867 IFS_save="$IFS" 17868 IFS=: 17869 for p in $PATH; do 17870 if test -f "$p/$path" && test -x "$p/$path"; then 17871 new_path="$p/$path" 17872 break 17873 fi 17874 done 17875 IFS="$IFS_save" 17876 else 17877 # This is an absolute path, we can use it without further modifications. 17878 new_path="$path" 17879 fi 17880 17881 if test "x$new_path" = x; then 17882 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of FOUND_MAKE, which resolves as \"$complete\", is not found." >&5 17883 $as_echo "$as_me: The path of FOUND_MAKE, which resolves as \"$complete\", is not found." >&6;} 17884 has_space=`$ECHO "$complete" | $GREP " "` 17885 if test "x$has_space" != x; then 17886 { $as_echo "$as_me:${as_lineno-$LINENO}: This might be caused by spaces in the path, which is not allowed." >&5 17887 $as_echo "$as_me: This might be caused by spaces in the path, which is not allowed." >&6;} 17888 fi 17889 as_fn_error $? "Cannot locate the the path of FOUND_MAKE" "$LINENO" 5 17890 fi 17891 fi 17892 17893 # Now join together the path and the arguments once again 17894 if test "x$arguments" != xEOL; then 17895 new_complete="$new_path ${arguments% *}" 17896 else 17897 new_complete="$new_path" 17898 fi 17899 17900 if test "x$complete" != "x$new_complete"; then 17901 FOUND_MAKE="$new_complete" 17902 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting FOUND_MAKE to \"$new_complete\"" >&5 17903 $as_echo "$as_me: Rewriting FOUND_MAKE to \"$new_complete\"" >&6;} 17904 fi 17905 fi 17906 17907 fi 17908 fi 17909 fi 17910 fi 17911 17912 17913 if test "x$FOUND_MAKE" = x; then 17914 for ac_prog in make 17915 do 17916 # Extract the first word of "$ac_prog", so it can be a program name with args. 17917 set dummy $ac_prog; ac_word=$2 17918 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 17919 $as_echo_n "checking for $ac_word... " >&6; } 17920 if ${ac_cv_path_CHECK_MAKE+:} false; then : 17921 $as_echo_n "(cached) " >&6 17922 else 17923 case $CHECK_MAKE in 17924 [\\/]* | ?:[\\/]*) 17925 ac_cv_path_CHECK_MAKE="$CHECK_MAKE" # Let the user override the test with a path. 17926 ;; 17927 *) 17928 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 17929 for as_dir in $PATH 17930 do 17931 IFS=$as_save_IFS 17932 test -z "$as_dir" && as_dir=. 17933 for ac_exec_ext in '' $ac_executable_extensions; do 17934 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 17935 ac_cv_path_CHECK_MAKE="$as_dir/$ac_word$ac_exec_ext" 17936 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 17937 break 2 17938 fi 17939 done 17940 done 17941 IFS=$as_save_IFS 17942 17943 ;; 17944 esac 17945 fi 17946 CHECK_MAKE=$ac_cv_path_CHECK_MAKE 17947 if test -n "$CHECK_MAKE"; then 17948 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CHECK_MAKE" >&5 17949 $as_echo "$CHECK_MAKE" >&6; } 17950 else 17951 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 17952 $as_echo "no" >&6; } 17953 fi 17954 17955 17956 test -n "$CHECK_MAKE" && break 17957 done 17958 17959 17960 MAKE_CANDIDATE=""$CHECK_MAKE"" 17961 DESCRIPTION="make in PATH" 17962 17963 # On Cygwin, we require a newer version of make than on other platforms 17964 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 17965 MAKE_VERSION_EXPR="-e 4\." 17966 MAKE_REQUIRED_VERSION="4.0" 17967 else 17968 MAKE_VERSION_EXPR="-e 3\.8[12] -e 4\." 17969 MAKE_REQUIRED_VERSION="3.81" 17970 fi 17971 17972 if test "x$MAKE_CANDIDATE" != x; then 17973 { $as_echo "$as_me:${as_lineno-$LINENO}: Testing potential make at $MAKE_CANDIDATE, found using $DESCRIPTION" >&5 17974 $as_echo "$as_me: Testing potential make at $MAKE_CANDIDATE, found using $DESCRIPTION" >&6;} 17975 MAKE_VERSION_STRING=`$MAKE_CANDIDATE --version | $HEAD -n 1` 17976 IS_GNU_MAKE=`$ECHO $MAKE_VERSION_STRING | $GREP 'GNU Make'` 17977 if test "x$IS_GNU_MAKE" = x; then 17978 { $as_echo "$as_me:${as_lineno-$LINENO}: Found potential make at $MAKE_CANDIDATE, however, this is not GNU Make. Ignoring." >&5 17979 $as_echo "$as_me: Found potential make at $MAKE_CANDIDATE, however, this is not GNU Make. Ignoring." >&6;} 17980 else 17981 IS_MODERN_MAKE=`$ECHO $MAKE_VERSION_STRING | $GREP $MAKE_VERSION_EXPR` 17982 if test "x$IS_MODERN_MAKE" = x; then 17983 { $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 17984 $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;} 17985 else 17986 if test "x$OPENJDK_BUILD_OS" = "xwindows"; then 17987 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 17988 MAKE_EXPECTED_ENV='cygwin' 17989 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 17990 MAKE_EXPECTED_ENV='msys' 17991 else 17992 as_fn_error $? "Unknown Windows environment" "$LINENO" 5 17993 fi 17994 MAKE_BUILT_FOR=`$MAKE_CANDIDATE --version | $GREP -i 'built for'` 17995 IS_MAKE_CORRECT_ENV=`$ECHO $MAKE_BUILT_FOR | $GREP $MAKE_EXPECTED_ENV` 17996 else 17997 # Not relevant for non-Windows 17998 IS_MAKE_CORRECT_ENV=true 17999 fi 18000 if test "x$IS_MAKE_CORRECT_ENV" = x; then 18001 { $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 18002 $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;} 18003 else 18004 FOUND_MAKE=$MAKE_CANDIDATE 18005 18006 # Only process if variable expands to non-empty 18007 18008 if test "x$FOUND_MAKE" != x; then 18009 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 18010 18011 # First separate the path from the arguments. This will split at the first 18012 # space. 18013 complete="$FOUND_MAKE" 18014 path="${complete%% *}" 18015 tmp="$complete EOL" 18016 arguments="${tmp#* }" 18017 18018 # Input might be given as Windows format, start by converting to 18019 # unix format. 18020 new_path=`$CYGPATH -u "$path"` 18021 18022 # Now try to locate executable using which 18023 new_path=`$WHICH "$new_path" 2> /dev/null` 18024 # bat and cmd files are not always considered executable in cygwin causing which 18025 # to not find them 18026 if test "x$new_path" = x \ 18027 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 18028 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 18029 new_path=`$CYGPATH -u "$path"` 18030 fi 18031 if test "x$new_path" = x; then 18032 # Oops. Which didn't find the executable. 18033 # The splitting of arguments from the executable at a space might have been incorrect, 18034 # since paths with space are more likely in Windows. Give it another try with the whole 18035 # argument. 18036 path="$complete" 18037 arguments="EOL" 18038 new_path=`$CYGPATH -u "$path"` 18039 new_path=`$WHICH "$new_path" 2> /dev/null` 18040 # bat and cmd files are not always considered executable in cygwin causing which 18041 # to not find them 18042 if test "x$new_path" = x \ 18043 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 18044 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 18045 new_path=`$CYGPATH -u "$path"` 18046 fi 18047 if test "x$new_path" = x; then 18048 # It's still not found. Now this is an unrecoverable error. 18049 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of FOUND_MAKE, which resolves as \"$complete\", is not found." >&5 18050 $as_echo "$as_me: The path of FOUND_MAKE, which resolves as \"$complete\", is not found." >&6;} 18051 has_space=`$ECHO "$complete" | $GREP " "` 18052 if test "x$has_space" != x; then 18053 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 18054 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 18055 fi 18056 as_fn_error $? "Cannot locate the the path of FOUND_MAKE" "$LINENO" 5 18057 fi 18058 fi 18059 18060 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 18061 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 18062 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 18063 # "foo.exe" is OK but "foo" is an error. 18064 # 18065 # This test is therefore slightly more accurate than "test -f" to check for file presence. 18066 # It is also a way to make sure we got the proper file name for the real test later on. 18067 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 18068 if test "x$test_shortpath" = x; then 18069 # Short path failed, file does not exist as specified. 18070 # Try adding .exe or .cmd 18071 if test -f "${new_path}.exe"; then 18072 input_to_shortpath="${new_path}.exe" 18073 elif test -f "${new_path}.cmd"; then 18074 input_to_shortpath="${new_path}.cmd" 18075 else 18076 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of FOUND_MAKE, which resolves as \"$new_path\", is invalid." >&5 18077 $as_echo "$as_me: The path of FOUND_MAKE, which resolves as \"$new_path\", is invalid." >&6;} 18078 { $as_echo "$as_me:${as_lineno-$LINENO}: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&5 18079 $as_echo "$as_me: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&6;} 18080 as_fn_error $? "Cannot locate the the path of FOUND_MAKE" "$LINENO" 5 18081 fi 18082 else 18083 input_to_shortpath="$new_path" 18084 fi 18085 18086 # Call helper function which possibly converts this using DOS-style short mode. 18087 # If so, the updated path is stored in $new_path. 18088 new_path="$input_to_shortpath" 18089 18090 input_path="$input_to_shortpath" 18091 # Check if we need to convert this using DOS-style short mode. If the path 18092 # contains just simple characters, use it. Otherwise (spaces, weird characters), 18093 # take no chances and rewrite it. 18094 # Note: m4 eats our [], so we need to use [ and ] instead. 18095 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 18096 if test "x$has_forbidden_chars" != x; then 18097 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 18098 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 18099 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 18100 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 18101 # Going to short mode and back again did indeed matter. Since short mode is 18102 # case insensitive, let's make it lowercase to improve readability. 18103 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 18104 # Now convert it back to Unix-style (cygpath) 18105 input_path=`$CYGPATH -u "$shortmode_path"` 18106 new_path="$input_path" 18107 fi 18108 fi 18109 18110 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 18111 if test "x$test_cygdrive_prefix" = x; then 18112 # As a simple fix, exclude /usr/bin since it's not a real path. 18113 if test "x`$ECHO $input_to_shortpath | $GREP ^/usr/bin/`" = x; then 18114 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 18115 # a path prefixed by /cygdrive for fixpath to work. 18116 new_path="$CYGWIN_ROOT_PATH$input_path" 18117 fi 18118 fi 18119 18120 # remove trailing .exe if any 18121 new_path="${new_path/%.exe/}" 18122 18123 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 18124 18125 # First separate the path from the arguments. This will split at the first 18126 # space. 18127 complete="$FOUND_MAKE" 18128 path="${complete%% *}" 18129 tmp="$complete EOL" 18130 arguments="${tmp#* }" 18131 18132 # Input might be given as Windows format, start by converting to 18133 # unix format. 18134 new_path="$path" 18135 18136 windows_path="$new_path" 18137 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 18138 unix_path=`$CYGPATH -u "$windows_path"` 18139 new_path="$unix_path" 18140 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 18141 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 18142 new_path="$unix_path" 18143 fi 18144 18145 18146 # Now try to locate executable using which 18147 new_path=`$WHICH "$new_path" 2> /dev/null` 18148 18149 if test "x$new_path" = x; then 18150 # Oops. Which didn't find the executable. 18151 # The splitting of arguments from the executable at a space might have been incorrect, 18152 # since paths with space are more likely in Windows. Give it another try with the whole 18153 # argument. 18154 path="$complete" 18155 arguments="EOL" 18156 new_path="$path" 18157 18158 windows_path="$new_path" 18159 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 18160 unix_path=`$CYGPATH -u "$windows_path"` 18161 new_path="$unix_path" 18162 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 18163 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 18164 new_path="$unix_path" 18165 fi 18166 18167 18168 new_path=`$WHICH "$new_path" 2> /dev/null` 18169 # bat and cmd files are not always considered executable in MSYS causing which 18170 # to not find them 18171 if test "x$new_path" = x \ 18172 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 18173 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 18174 new_path="$path" 18175 18176 windows_path="$new_path" 18177 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 18178 unix_path=`$CYGPATH -u "$windows_path"` 18179 new_path="$unix_path" 18180 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 18181 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 18182 new_path="$unix_path" 18183 fi 18184 18185 fi 18186 18187 if test "x$new_path" = x; then 18188 # It's still not found. Now this is an unrecoverable error. 18189 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of FOUND_MAKE, which resolves as \"$complete\", is not found." >&5 18190 $as_echo "$as_me: The path of FOUND_MAKE, which resolves as \"$complete\", is not found." >&6;} 18191 has_space=`$ECHO "$complete" | $GREP " "` 18192 if test "x$has_space" != x; then 18193 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 18194 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 18195 fi 18196 as_fn_error $? "Cannot locate the the path of FOUND_MAKE" "$LINENO" 5 18197 fi 18198 fi 18199 18200 # Now new_path has a complete unix path to the binary 18201 if test "x`$ECHO $new_path | $GREP ^/bin/`" != x; then 18202 # Keep paths in /bin as-is, but remove trailing .exe if any 18203 new_path="${new_path/%.exe/}" 18204 # Do not save /bin paths to all_fixpath_prefixes! 18205 else 18206 # Not in mixed or Windows style, start by that. 18207 new_path=`cmd //c echo $new_path` 18208 18209 input_path="$new_path" 18210 # Check if we need to convert this using DOS-style short mode. If the path 18211 # contains just simple characters, use it. Otherwise (spaces, weird characters), 18212 # take no chances and rewrite it. 18213 # Note: m4 eats our [], so we need to use [ and ] instead. 18214 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 18215 if test "x$has_forbidden_chars" != x; then 18216 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 18217 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 18218 fi 18219 18220 # Output is in $new_path 18221 18222 windows_path="$new_path" 18223 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 18224 unix_path=`$CYGPATH -u "$windows_path"` 18225 new_path="$unix_path" 18226 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 18227 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 18228 new_path="$unix_path" 18229 fi 18230 18231 # remove trailing .exe if any 18232 new_path="${new_path/%.exe/}" 18233 18234 # Save the first 10 bytes of this path to the storage, so fixpath can work. 18235 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 18236 fi 18237 18238 else 18239 # We're on a unix platform. Hooray! :) 18240 # First separate the path from the arguments. This will split at the first 18241 # space. 18242 complete="$FOUND_MAKE" 18243 path="${complete%% *}" 18244 tmp="$complete EOL" 18245 arguments="${tmp#* }" 18246 18247 # Cannot rely on the command "which" here since it doesn't always work. 18248 is_absolute_path=`$ECHO "$path" | $GREP ^/` 18249 if test -z "$is_absolute_path"; then 18250 # Path to executable is not absolute. Find it. 18251 IFS_save="$IFS" 18252 IFS=: 18253 for p in $PATH; do 18254 if test -f "$p/$path" && test -x "$p/$path"; then 18255 new_path="$p/$path" 18256 break 18257 fi 18258 done 18259 IFS="$IFS_save" 18260 else 18261 # This is an absolute path, we can use it without further modifications. 18262 new_path="$path" 18263 fi 18264 18265 if test "x$new_path" = x; then 18266 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of FOUND_MAKE, which resolves as \"$complete\", is not found." >&5 18267 $as_echo "$as_me: The path of FOUND_MAKE, which resolves as \"$complete\", is not found." >&6;} 18268 has_space=`$ECHO "$complete" | $GREP " "` 18269 if test "x$has_space" != x; then 18270 { $as_echo "$as_me:${as_lineno-$LINENO}: This might be caused by spaces in the path, which is not allowed." >&5 18271 $as_echo "$as_me: This might be caused by spaces in the path, which is not allowed." >&6;} 18272 fi 18273 as_fn_error $? "Cannot locate the the path of FOUND_MAKE" "$LINENO" 5 18274 fi 18275 fi 18276 18277 # Now join together the path and the arguments once again 18278 if test "x$arguments" != xEOL; then 18279 new_complete="$new_path ${arguments% *}" 18280 else 18281 new_complete="$new_path" 18282 fi 18283 18284 if test "x$complete" != "x$new_complete"; then 18285 FOUND_MAKE="$new_complete" 18286 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting FOUND_MAKE to \"$new_complete\"" >&5 18287 $as_echo "$as_me: Rewriting FOUND_MAKE to \"$new_complete\"" >&6;} 18288 fi 18289 fi 18290 18291 fi 18292 fi 18293 fi 18294 fi 18295 18296 fi 18297 18298 if test "x$FOUND_MAKE" = x; then 18299 if test "x$TOOLCHAIN_PATH" != x; then 18300 # We have a toolchain path, check that as well before giving up. 18301 OLD_PATH=$PATH 18302 PATH=$TOOLCHAIN_PATH:$PATH 18303 for ac_prog in gmake 18304 do 18305 # Extract the first word of "$ac_prog", so it can be a program name with args. 18306 set dummy $ac_prog; ac_word=$2 18307 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 18308 $as_echo_n "checking for $ac_word... " >&6; } 18309 if ${ac_cv_path_CHECK_TOOLSDIR_GMAKE+:} false; then : 18310 $as_echo_n "(cached) " >&6 18311 else 18312 case $CHECK_TOOLSDIR_GMAKE in 18313 [\\/]* | ?:[\\/]*) 18314 ac_cv_path_CHECK_TOOLSDIR_GMAKE="$CHECK_TOOLSDIR_GMAKE" # Let the user override the test with a path. 18315 ;; 18316 *) 18317 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 18318 for as_dir in $PATH 18319 do 18320 IFS=$as_save_IFS 18321 test -z "$as_dir" && as_dir=. 18322 for ac_exec_ext in '' $ac_executable_extensions; do 18323 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 18324 ac_cv_path_CHECK_TOOLSDIR_GMAKE="$as_dir/$ac_word$ac_exec_ext" 18325 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 18326 break 2 18327 fi 18328 done 18329 done 18330 IFS=$as_save_IFS 18331 18332 ;; 18333 esac 18334 fi 18335 CHECK_TOOLSDIR_GMAKE=$ac_cv_path_CHECK_TOOLSDIR_GMAKE 18336 if test -n "$CHECK_TOOLSDIR_GMAKE"; then 18337 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CHECK_TOOLSDIR_GMAKE" >&5 18338 $as_echo "$CHECK_TOOLSDIR_GMAKE" >&6; } 18339 else 18340 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 18341 $as_echo "no" >&6; } 18342 fi 18343 18344 18345 test -n "$CHECK_TOOLSDIR_GMAKE" && break 18346 done 18347 18348 18349 MAKE_CANDIDATE=""$CHECK_TOOLSDIR_GMAKE"" 18350 DESCRIPTION="gmake in tools-dir" 18351 18352 # On Cygwin, we require a newer version of make than on other platforms 18353 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 18354 MAKE_VERSION_EXPR="-e 4\." 18355 MAKE_REQUIRED_VERSION="4.0" 18356 else 18357 MAKE_VERSION_EXPR="-e 3\.8[12] -e 4\." 18358 MAKE_REQUIRED_VERSION="3.81" 18359 fi 18360 18361 if test "x$MAKE_CANDIDATE" != x; then 18362 { $as_echo "$as_me:${as_lineno-$LINENO}: Testing potential make at $MAKE_CANDIDATE, found using $DESCRIPTION" >&5 18363 $as_echo "$as_me: Testing potential make at $MAKE_CANDIDATE, found using $DESCRIPTION" >&6;} 18364 MAKE_VERSION_STRING=`$MAKE_CANDIDATE --version | $HEAD -n 1` 18365 IS_GNU_MAKE=`$ECHO $MAKE_VERSION_STRING | $GREP 'GNU Make'` 18366 if test "x$IS_GNU_MAKE" = x; then 18367 { $as_echo "$as_me:${as_lineno-$LINENO}: Found potential make at $MAKE_CANDIDATE, however, this is not GNU Make. Ignoring." >&5 18368 $as_echo "$as_me: Found potential make at $MAKE_CANDIDATE, however, this is not GNU Make. Ignoring." >&6;} 18369 else 18370 IS_MODERN_MAKE=`$ECHO $MAKE_VERSION_STRING | $GREP $MAKE_VERSION_EXPR` 18371 if test "x$IS_MODERN_MAKE" = x; then 18372 { $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 18373 $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;} 18374 else 18375 if test "x$OPENJDK_BUILD_OS" = "xwindows"; then 18376 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 18377 MAKE_EXPECTED_ENV='cygwin' 18378 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 18379 MAKE_EXPECTED_ENV='msys' 18380 else 18381 as_fn_error $? "Unknown Windows environment" "$LINENO" 5 18382 fi 18383 MAKE_BUILT_FOR=`$MAKE_CANDIDATE --version | $GREP -i 'built for'` 18384 IS_MAKE_CORRECT_ENV=`$ECHO $MAKE_BUILT_FOR | $GREP $MAKE_EXPECTED_ENV` 18385 else 18386 # Not relevant for non-Windows 18387 IS_MAKE_CORRECT_ENV=true 18388 fi 18389 if test "x$IS_MAKE_CORRECT_ENV" = x; then 18390 { $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 18391 $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;} 18392 else 18393 FOUND_MAKE=$MAKE_CANDIDATE 18394 18395 # Only process if variable expands to non-empty 18396 18397 if test "x$FOUND_MAKE" != x; then 18398 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 18399 18400 # First separate the path from the arguments. This will split at the first 18401 # space. 18402 complete="$FOUND_MAKE" 18403 path="${complete%% *}" 18404 tmp="$complete EOL" 18405 arguments="${tmp#* }" 18406 18407 # Input might be given as Windows format, start by converting to 18408 # unix format. 18409 new_path=`$CYGPATH -u "$path"` 18410 18411 # Now try to locate executable using which 18412 new_path=`$WHICH "$new_path" 2> /dev/null` 18413 # bat and cmd files are not always considered executable in cygwin causing which 18414 # to not find them 18415 if test "x$new_path" = x \ 18416 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 18417 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 18418 new_path=`$CYGPATH -u "$path"` 18419 fi 18420 if test "x$new_path" = x; then 18421 # Oops. Which didn't find the executable. 18422 # The splitting of arguments from the executable at a space might have been incorrect, 18423 # since paths with space are more likely in Windows. Give it another try with the whole 18424 # argument. 18425 path="$complete" 18426 arguments="EOL" 18427 new_path=`$CYGPATH -u "$path"` 18428 new_path=`$WHICH "$new_path" 2> /dev/null` 18429 # bat and cmd files are not always considered executable in cygwin causing which 18430 # to not find them 18431 if test "x$new_path" = x \ 18432 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 18433 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 18434 new_path=`$CYGPATH -u "$path"` 18435 fi 18436 if test "x$new_path" = x; then 18437 # It's still not found. Now this is an unrecoverable error. 18438 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of FOUND_MAKE, which resolves as \"$complete\", is not found." >&5 18439 $as_echo "$as_me: The path of FOUND_MAKE, which resolves as \"$complete\", is not found." >&6;} 18440 has_space=`$ECHO "$complete" | $GREP " "` 18441 if test "x$has_space" != x; then 18442 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 18443 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 18444 fi 18445 as_fn_error $? "Cannot locate the the path of FOUND_MAKE" "$LINENO" 5 18446 fi 18447 fi 18448 18449 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 18450 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 18451 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 18452 # "foo.exe" is OK but "foo" is an error. 18453 # 18454 # This test is therefore slightly more accurate than "test -f" to check for file presence. 18455 # It is also a way to make sure we got the proper file name for the real test later on. 18456 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 18457 if test "x$test_shortpath" = x; then 18458 # Short path failed, file does not exist as specified. 18459 # Try adding .exe or .cmd 18460 if test -f "${new_path}.exe"; then 18461 input_to_shortpath="${new_path}.exe" 18462 elif test -f "${new_path}.cmd"; then 18463 input_to_shortpath="${new_path}.cmd" 18464 else 18465 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of FOUND_MAKE, which resolves as \"$new_path\", is invalid." >&5 18466 $as_echo "$as_me: The path of FOUND_MAKE, which resolves as \"$new_path\", is invalid." >&6;} 18467 { $as_echo "$as_me:${as_lineno-$LINENO}: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&5 18468 $as_echo "$as_me: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&6;} 18469 as_fn_error $? "Cannot locate the the path of FOUND_MAKE" "$LINENO" 5 18470 fi 18471 else 18472 input_to_shortpath="$new_path" 18473 fi 18474 18475 # Call helper function which possibly converts this using DOS-style short mode. 18476 # If so, the updated path is stored in $new_path. 18477 new_path="$input_to_shortpath" 18478 18479 input_path="$input_to_shortpath" 18480 # Check if we need to convert this using DOS-style short mode. If the path 18481 # contains just simple characters, use it. Otherwise (spaces, weird characters), 18482 # take no chances and rewrite it. 18483 # Note: m4 eats our [], so we need to use [ and ] instead. 18484 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 18485 if test "x$has_forbidden_chars" != x; then 18486 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 18487 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 18488 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 18489 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 18490 # Going to short mode and back again did indeed matter. Since short mode is 18491 # case insensitive, let's make it lowercase to improve readability. 18492 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 18493 # Now convert it back to Unix-style (cygpath) 18494 input_path=`$CYGPATH -u "$shortmode_path"` 18495 new_path="$input_path" 18496 fi 18497 fi 18498 18499 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 18500 if test "x$test_cygdrive_prefix" = x; then 18501 # As a simple fix, exclude /usr/bin since it's not a real path. 18502 if test "x`$ECHO $input_to_shortpath | $GREP ^/usr/bin/`" = x; then 18503 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 18504 # a path prefixed by /cygdrive for fixpath to work. 18505 new_path="$CYGWIN_ROOT_PATH$input_path" 18506 fi 18507 fi 18508 18509 # remove trailing .exe if any 18510 new_path="${new_path/%.exe/}" 18511 18512 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 18513 18514 # First separate the path from the arguments. This will split at the first 18515 # space. 18516 complete="$FOUND_MAKE" 18517 path="${complete%% *}" 18518 tmp="$complete EOL" 18519 arguments="${tmp#* }" 18520 18521 # Input might be given as Windows format, start by converting to 18522 # unix format. 18523 new_path="$path" 18524 18525 windows_path="$new_path" 18526 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 18527 unix_path=`$CYGPATH -u "$windows_path"` 18528 new_path="$unix_path" 18529 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 18530 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 18531 new_path="$unix_path" 18532 fi 18533 18534 18535 # Now try to locate executable using which 18536 new_path=`$WHICH "$new_path" 2> /dev/null` 18537 18538 if test "x$new_path" = x; then 18539 # Oops. Which didn't find the executable. 18540 # The splitting of arguments from the executable at a space might have been incorrect, 18541 # since paths with space are more likely in Windows. Give it another try with the whole 18542 # argument. 18543 path="$complete" 18544 arguments="EOL" 18545 new_path="$path" 18546 18547 windows_path="$new_path" 18548 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 18549 unix_path=`$CYGPATH -u "$windows_path"` 18550 new_path="$unix_path" 18551 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 18552 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 18553 new_path="$unix_path" 18554 fi 18555 18556 18557 new_path=`$WHICH "$new_path" 2> /dev/null` 18558 # bat and cmd files are not always considered executable in MSYS causing which 18559 # to not find them 18560 if test "x$new_path" = x \ 18561 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 18562 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 18563 new_path="$path" 18564 18565 windows_path="$new_path" 18566 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 18567 unix_path=`$CYGPATH -u "$windows_path"` 18568 new_path="$unix_path" 18569 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 18570 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 18571 new_path="$unix_path" 18572 fi 18573 18574 fi 18575 18576 if test "x$new_path" = x; then 18577 # It's still not found. Now this is an unrecoverable error. 18578 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of FOUND_MAKE, which resolves as \"$complete\", is not found." >&5 18579 $as_echo "$as_me: The path of FOUND_MAKE, which resolves as \"$complete\", is not found." >&6;} 18580 has_space=`$ECHO "$complete" | $GREP " "` 18581 if test "x$has_space" != x; then 18582 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 18583 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 18584 fi 18585 as_fn_error $? "Cannot locate the the path of FOUND_MAKE" "$LINENO" 5 18586 fi 18587 fi 18588 18589 # Now new_path has a complete unix path to the binary 18590 if test "x`$ECHO $new_path | $GREP ^/bin/`" != x; then 18591 # Keep paths in /bin as-is, but remove trailing .exe if any 18592 new_path="${new_path/%.exe/}" 18593 # Do not save /bin paths to all_fixpath_prefixes! 18594 else 18595 # Not in mixed or Windows style, start by that. 18596 new_path=`cmd //c echo $new_path` 18597 18598 input_path="$new_path" 18599 # Check if we need to convert this using DOS-style short mode. If the path 18600 # contains just simple characters, use it. Otherwise (spaces, weird characters), 18601 # take no chances and rewrite it. 18602 # Note: m4 eats our [], so we need to use [ and ] instead. 18603 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 18604 if test "x$has_forbidden_chars" != x; then 18605 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 18606 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 18607 fi 18608 18609 # Output is in $new_path 18610 18611 windows_path="$new_path" 18612 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 18613 unix_path=`$CYGPATH -u "$windows_path"` 18614 new_path="$unix_path" 18615 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 18616 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 18617 new_path="$unix_path" 18618 fi 18619 18620 # remove trailing .exe if any 18621 new_path="${new_path/%.exe/}" 18622 18623 # Save the first 10 bytes of this path to the storage, so fixpath can work. 18624 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 18625 fi 18626 18627 else 18628 # We're on a unix platform. Hooray! :) 18629 # First separate the path from the arguments. This will split at the first 18630 # space. 18631 complete="$FOUND_MAKE" 18632 path="${complete%% *}" 18633 tmp="$complete EOL" 18634 arguments="${tmp#* }" 18635 18636 # Cannot rely on the command "which" here since it doesn't always work. 18637 is_absolute_path=`$ECHO "$path" | $GREP ^/` 18638 if test -z "$is_absolute_path"; then 18639 # Path to executable is not absolute. Find it. 18640 IFS_save="$IFS" 18641 IFS=: 18642 for p in $PATH; do 18643 if test -f "$p/$path" && test -x "$p/$path"; then 18644 new_path="$p/$path" 18645 break 18646 fi 18647 done 18648 IFS="$IFS_save" 18649 else 18650 # This is an absolute path, we can use it without further modifications. 18651 new_path="$path" 18652 fi 18653 18654 if test "x$new_path" = x; then 18655 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of FOUND_MAKE, which resolves as \"$complete\", is not found." >&5 18656 $as_echo "$as_me: The path of FOUND_MAKE, which resolves as \"$complete\", is not found." >&6;} 18657 has_space=`$ECHO "$complete" | $GREP " "` 18658 if test "x$has_space" != x; then 18659 { $as_echo "$as_me:${as_lineno-$LINENO}: This might be caused by spaces in the path, which is not allowed." >&5 18660 $as_echo "$as_me: This might be caused by spaces in the path, which is not allowed." >&6;} 18661 fi 18662 as_fn_error $? "Cannot locate the the path of FOUND_MAKE" "$LINENO" 5 18663 fi 18664 fi 18665 18666 # Now join together the path and the arguments once again 18667 if test "x$arguments" != xEOL; then 18668 new_complete="$new_path ${arguments% *}" 18669 else 18670 new_complete="$new_path" 18671 fi 18672 18673 if test "x$complete" != "x$new_complete"; then 18674 FOUND_MAKE="$new_complete" 18675 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting FOUND_MAKE to \"$new_complete\"" >&5 18676 $as_echo "$as_me: Rewriting FOUND_MAKE to \"$new_complete\"" >&6;} 18677 fi 18678 fi 18679 18680 fi 18681 fi 18682 fi 18683 fi 18684 18685 if test "x$FOUND_MAKE" = x; then 18686 for ac_prog in make 18687 do 18688 # Extract the first word of "$ac_prog", so it can be a program name with args. 18689 set dummy $ac_prog; ac_word=$2 18690 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 18691 $as_echo_n "checking for $ac_word... " >&6; } 18692 if ${ac_cv_path_CHECK_TOOLSDIR_MAKE+:} false; then : 18693 $as_echo_n "(cached) " >&6 18694 else 18695 case $CHECK_TOOLSDIR_MAKE in 18696 [\\/]* | ?:[\\/]*) 18697 ac_cv_path_CHECK_TOOLSDIR_MAKE="$CHECK_TOOLSDIR_MAKE" # Let the user override the test with a path. 18698 ;; 18699 *) 18700 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 18701 for as_dir in $PATH 18702 do 18703 IFS=$as_save_IFS 18704 test -z "$as_dir" && as_dir=. 18705 for ac_exec_ext in '' $ac_executable_extensions; do 18706 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 18707 ac_cv_path_CHECK_TOOLSDIR_MAKE="$as_dir/$ac_word$ac_exec_ext" 18708 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 18709 break 2 18710 fi 18711 done 18712 done 18713 IFS=$as_save_IFS 18714 18715 ;; 18716 esac 18717 fi 18718 CHECK_TOOLSDIR_MAKE=$ac_cv_path_CHECK_TOOLSDIR_MAKE 18719 if test -n "$CHECK_TOOLSDIR_MAKE"; then 18720 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CHECK_TOOLSDIR_MAKE" >&5 18721 $as_echo "$CHECK_TOOLSDIR_MAKE" >&6; } 18722 else 18723 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 18724 $as_echo "no" >&6; } 18725 fi 18726 18727 18728 test -n "$CHECK_TOOLSDIR_MAKE" && break 18729 done 18730 18731 18732 MAKE_CANDIDATE=""$CHECK_TOOLSDIR_MAKE"" 18733 DESCRIPTION="make in tools-dir" 18734 18735 # On Cygwin, we require a newer version of make than on other platforms 18736 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 18737 MAKE_VERSION_EXPR="-e 4\." 18738 MAKE_REQUIRED_VERSION="4.0" 18739 else 18740 MAKE_VERSION_EXPR="-e 3\.8[12] -e 4\." 18741 MAKE_REQUIRED_VERSION="3.81" 18742 fi 18743 18744 if test "x$MAKE_CANDIDATE" != x; then 18745 { $as_echo "$as_me:${as_lineno-$LINENO}: Testing potential make at $MAKE_CANDIDATE, found using $DESCRIPTION" >&5 18746 $as_echo "$as_me: Testing potential make at $MAKE_CANDIDATE, found using $DESCRIPTION" >&6;} 18747 MAKE_VERSION_STRING=`$MAKE_CANDIDATE --version | $HEAD -n 1` 18748 IS_GNU_MAKE=`$ECHO $MAKE_VERSION_STRING | $GREP 'GNU Make'` 18749 if test "x$IS_GNU_MAKE" = x; then 18750 { $as_echo "$as_me:${as_lineno-$LINENO}: Found potential make at $MAKE_CANDIDATE, however, this is not GNU Make. Ignoring." >&5 18751 $as_echo "$as_me: Found potential make at $MAKE_CANDIDATE, however, this is not GNU Make. Ignoring." >&6;} 18752 else 18753 IS_MODERN_MAKE=`$ECHO $MAKE_VERSION_STRING | $GREP $MAKE_VERSION_EXPR` 18754 if test "x$IS_MODERN_MAKE" = x; then 18755 { $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 18756 $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;} 18757 else 18758 if test "x$OPENJDK_BUILD_OS" = "xwindows"; then 18759 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 18760 MAKE_EXPECTED_ENV='cygwin' 18761 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 18762 MAKE_EXPECTED_ENV='msys' 18763 else 18764 as_fn_error $? "Unknown Windows environment" "$LINENO" 5 18765 fi 18766 MAKE_BUILT_FOR=`$MAKE_CANDIDATE --version | $GREP -i 'built for'` 18767 IS_MAKE_CORRECT_ENV=`$ECHO $MAKE_BUILT_FOR | $GREP $MAKE_EXPECTED_ENV` 18768 else 18769 # Not relevant for non-Windows 18770 IS_MAKE_CORRECT_ENV=true 18771 fi 18772 if test "x$IS_MAKE_CORRECT_ENV" = x; then 18773 { $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 18774 $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;} 18775 else 18776 FOUND_MAKE=$MAKE_CANDIDATE 18777 18778 # Only process if variable expands to non-empty 18779 18780 if test "x$FOUND_MAKE" != x; then 18781 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 18782 18783 # First separate the path from the arguments. This will split at the first 18784 # space. 18785 complete="$FOUND_MAKE" 18786 path="${complete%% *}" 18787 tmp="$complete EOL" 18788 arguments="${tmp#* }" 18789 18790 # Input might be given as Windows format, start by converting to 18791 # unix format. 18792 new_path=`$CYGPATH -u "$path"` 18793 18794 # Now try to locate executable using which 18795 new_path=`$WHICH "$new_path" 2> /dev/null` 18796 # bat and cmd files are not always considered executable in cygwin causing which 18797 # to not find them 18798 if test "x$new_path" = x \ 18799 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 18800 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 18801 new_path=`$CYGPATH -u "$path"` 18802 fi 18803 if test "x$new_path" = x; then 18804 # Oops. Which didn't find the executable. 18805 # The splitting of arguments from the executable at a space might have been incorrect, 18806 # since paths with space are more likely in Windows. Give it another try with the whole 18807 # argument. 18808 path="$complete" 18809 arguments="EOL" 18810 new_path=`$CYGPATH -u "$path"` 18811 new_path=`$WHICH "$new_path" 2> /dev/null` 18812 # bat and cmd files are not always considered executable in cygwin causing which 18813 # to not find them 18814 if test "x$new_path" = x \ 18815 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 18816 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 18817 new_path=`$CYGPATH -u "$path"` 18818 fi 18819 if test "x$new_path" = x; then 18820 # It's still not found. Now this is an unrecoverable error. 18821 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of FOUND_MAKE, which resolves as \"$complete\", is not found." >&5 18822 $as_echo "$as_me: The path of FOUND_MAKE, which resolves as \"$complete\", is not found." >&6;} 18823 has_space=`$ECHO "$complete" | $GREP " "` 18824 if test "x$has_space" != x; then 18825 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 18826 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 18827 fi 18828 as_fn_error $? "Cannot locate the the path of FOUND_MAKE" "$LINENO" 5 18829 fi 18830 fi 18831 18832 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 18833 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 18834 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 18835 # "foo.exe" is OK but "foo" is an error. 18836 # 18837 # This test is therefore slightly more accurate than "test -f" to check for file presence. 18838 # It is also a way to make sure we got the proper file name for the real test later on. 18839 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 18840 if test "x$test_shortpath" = x; then 18841 # Short path failed, file does not exist as specified. 18842 # Try adding .exe or .cmd 18843 if test -f "${new_path}.exe"; then 18844 input_to_shortpath="${new_path}.exe" 18845 elif test -f "${new_path}.cmd"; then 18846 input_to_shortpath="${new_path}.cmd" 18847 else 18848 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of FOUND_MAKE, which resolves as \"$new_path\", is invalid." >&5 18849 $as_echo "$as_me: The path of FOUND_MAKE, which resolves as \"$new_path\", is invalid." >&6;} 18850 { $as_echo "$as_me:${as_lineno-$LINENO}: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&5 18851 $as_echo "$as_me: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&6;} 18852 as_fn_error $? "Cannot locate the the path of FOUND_MAKE" "$LINENO" 5 18853 fi 18854 else 18855 input_to_shortpath="$new_path" 18856 fi 18857 18858 # Call helper function which possibly converts this using DOS-style short mode. 18859 # If so, the updated path is stored in $new_path. 18860 new_path="$input_to_shortpath" 18861 18862 input_path="$input_to_shortpath" 18863 # Check if we need to convert this using DOS-style short mode. If the path 18864 # contains just simple characters, use it. Otherwise (spaces, weird characters), 18865 # take no chances and rewrite it. 18866 # Note: m4 eats our [], so we need to use [ and ] instead. 18867 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 18868 if test "x$has_forbidden_chars" != x; then 18869 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 18870 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 18871 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 18872 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 18873 # Going to short mode and back again did indeed matter. Since short mode is 18874 # case insensitive, let's make it lowercase to improve readability. 18875 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 18876 # Now convert it back to Unix-style (cygpath) 18877 input_path=`$CYGPATH -u "$shortmode_path"` 18878 new_path="$input_path" 18879 fi 18880 fi 18881 18882 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 18883 if test "x$test_cygdrive_prefix" = x; then 18884 # As a simple fix, exclude /usr/bin since it's not a real path. 18885 if test "x`$ECHO $input_to_shortpath | $GREP ^/usr/bin/`" = x; then 18886 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 18887 # a path prefixed by /cygdrive for fixpath to work. 18888 new_path="$CYGWIN_ROOT_PATH$input_path" 18889 fi 18890 fi 18891 18892 # remove trailing .exe if any 18893 new_path="${new_path/%.exe/}" 18894 18895 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 18896 18897 # First separate the path from the arguments. This will split at the first 18898 # space. 18899 complete="$FOUND_MAKE" 18900 path="${complete%% *}" 18901 tmp="$complete EOL" 18902 arguments="${tmp#* }" 18903 18904 # Input might be given as Windows format, start by converting to 18905 # unix format. 18906 new_path="$path" 18907 18908 windows_path="$new_path" 18909 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 18910 unix_path=`$CYGPATH -u "$windows_path"` 18911 new_path="$unix_path" 18912 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 18913 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 18914 new_path="$unix_path" 18915 fi 18916 18917 18918 # Now try to locate executable using which 18919 new_path=`$WHICH "$new_path" 2> /dev/null` 18920 18921 if test "x$new_path" = x; then 18922 # Oops. Which didn't find the executable. 18923 # The splitting of arguments from the executable at a space might have been incorrect, 18924 # since paths with space are more likely in Windows. Give it another try with the whole 18925 # argument. 18926 path="$complete" 18927 arguments="EOL" 18928 new_path="$path" 18929 18930 windows_path="$new_path" 18931 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 18932 unix_path=`$CYGPATH -u "$windows_path"` 18933 new_path="$unix_path" 18934 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 18935 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 18936 new_path="$unix_path" 18937 fi 18938 18939 18940 new_path=`$WHICH "$new_path" 2> /dev/null` 18941 # bat and cmd files are not always considered executable in MSYS causing which 18942 # to not find them 18943 if test "x$new_path" = x \ 18944 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 18945 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 18946 new_path="$path" 18947 18948 windows_path="$new_path" 18949 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 18950 unix_path=`$CYGPATH -u "$windows_path"` 18951 new_path="$unix_path" 18952 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 18953 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 18954 new_path="$unix_path" 18955 fi 18956 18957 fi 18958 18959 if test "x$new_path" = x; then 18960 # It's still not found. Now this is an unrecoverable error. 18961 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of FOUND_MAKE, which resolves as \"$complete\", is not found." >&5 18962 $as_echo "$as_me: The path of FOUND_MAKE, which resolves as \"$complete\", is not found." >&6;} 18963 has_space=`$ECHO "$complete" | $GREP " "` 18964 if test "x$has_space" != x; then 18965 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 18966 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 18967 fi 18968 as_fn_error $? "Cannot locate the the path of FOUND_MAKE" "$LINENO" 5 18969 fi 18970 fi 18971 18972 # Now new_path has a complete unix path to the binary 18973 if test "x`$ECHO $new_path | $GREP ^/bin/`" != x; then 18974 # Keep paths in /bin as-is, but remove trailing .exe if any 18975 new_path="${new_path/%.exe/}" 18976 # Do not save /bin paths to all_fixpath_prefixes! 18977 else 18978 # Not in mixed or Windows style, start by that. 18979 new_path=`cmd //c echo $new_path` 18980 18981 input_path="$new_path" 18982 # Check if we need to convert this using DOS-style short mode. If the path 18983 # contains just simple characters, use it. Otherwise (spaces, weird characters), 18984 # take no chances and rewrite it. 18985 # Note: m4 eats our [], so we need to use [ and ] instead. 18986 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 18987 if test "x$has_forbidden_chars" != x; then 18988 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 18989 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 18990 fi 18991 18992 # Output is in $new_path 18993 18994 windows_path="$new_path" 18995 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 18996 unix_path=`$CYGPATH -u "$windows_path"` 18997 new_path="$unix_path" 18998 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 18999 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 19000 new_path="$unix_path" 19001 fi 19002 19003 # remove trailing .exe if any 19004 new_path="${new_path/%.exe/}" 19005 19006 # Save the first 10 bytes of this path to the storage, so fixpath can work. 19007 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 19008 fi 19009 19010 else 19011 # We're on a unix platform. Hooray! :) 19012 # First separate the path from the arguments. This will split at the first 19013 # space. 19014 complete="$FOUND_MAKE" 19015 path="${complete%% *}" 19016 tmp="$complete EOL" 19017 arguments="${tmp#* }" 19018 19019 # Cannot rely on the command "which" here since it doesn't always work. 19020 is_absolute_path=`$ECHO "$path" | $GREP ^/` 19021 if test -z "$is_absolute_path"; then 19022 # Path to executable is not absolute. Find it. 19023 IFS_save="$IFS" 19024 IFS=: 19025 for p in $PATH; do 19026 if test -f "$p/$path" && test -x "$p/$path"; then 19027 new_path="$p/$path" 19028 break 19029 fi 19030 done 19031 IFS="$IFS_save" 19032 else 19033 # This is an absolute path, we can use it without further modifications. 19034 new_path="$path" 19035 fi 19036 19037 if test "x$new_path" = x; then 19038 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of FOUND_MAKE, which resolves as \"$complete\", is not found." >&5 19039 $as_echo "$as_me: The path of FOUND_MAKE, which resolves as \"$complete\", is not found." >&6;} 19040 has_space=`$ECHO "$complete" | $GREP " "` 19041 if test "x$has_space" != x; then 19042 { $as_echo "$as_me:${as_lineno-$LINENO}: This might be caused by spaces in the path, which is not allowed." >&5 19043 $as_echo "$as_me: This might be caused by spaces in the path, which is not allowed." >&6;} 19044 fi 19045 as_fn_error $? "Cannot locate the the path of FOUND_MAKE" "$LINENO" 5 19046 fi 19047 fi 19048 19049 # Now join together the path and the arguments once again 19050 if test "x$arguments" != xEOL; then 19051 new_complete="$new_path ${arguments% *}" 19052 else 19053 new_complete="$new_path" 19054 fi 19055 19056 if test "x$complete" != "x$new_complete"; then 19057 FOUND_MAKE="$new_complete" 19058 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting FOUND_MAKE to \"$new_complete\"" >&5 19059 $as_echo "$as_me: Rewriting FOUND_MAKE to \"$new_complete\"" >&6;} 19060 fi 19061 fi 19062 19063 fi 19064 fi 19065 fi 19066 fi 19067 19068 fi 19069 PATH=$OLD_PATH 19070 fi 19071 fi 19072 19073 if test "x$FOUND_MAKE" = x; then 19074 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 19075 fi 19076 19077 else 19078 # The variable is set, but is it from the command line or the environment? 19079 19080 # Try to remove the string !MAKE! from our list. 19081 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!MAKE!/} 19082 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 19083 # If it failed, the variable was not from the command line. Ignore it, 19084 # but warn the user (except for BASH, which is always set by the calling BASH). 19085 if test "xMAKE" != xBASH; then 19086 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of MAKE from the environment. Use command line variables instead." >&5 19087 $as_echo "$as_me: WARNING: Ignoring value of MAKE from the environment. Use command line variables instead." >&2;} 19088 fi 19089 # Try to locate tool using the code snippet 19090 19091 # Try our hardest to locate a correct version of GNU make 19092 for ac_prog in gmake 19093 do 19094 # Extract the first word of "$ac_prog", so it can be a program name with args. 19095 set dummy $ac_prog; ac_word=$2 19096 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 19097 $as_echo_n "checking for $ac_word... " >&6; } 19098 if ${ac_cv_path_CHECK_GMAKE+:} false; then : 19099 $as_echo_n "(cached) " >&6 19100 else 19101 case $CHECK_GMAKE in 19102 [\\/]* | ?:[\\/]*) 19103 ac_cv_path_CHECK_GMAKE="$CHECK_GMAKE" # Let the user override the test with a path. 19104 ;; 19105 *) 19106 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 19107 for as_dir in $PATH 19108 do 19109 IFS=$as_save_IFS 19110 test -z "$as_dir" && as_dir=. 19111 for ac_exec_ext in '' $ac_executable_extensions; do 19112 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 19113 ac_cv_path_CHECK_GMAKE="$as_dir/$ac_word$ac_exec_ext" 19114 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 19115 break 2 19116 fi 19117 done 19118 done 19119 IFS=$as_save_IFS 19120 19121 ;; 19122 esac 19123 fi 19124 CHECK_GMAKE=$ac_cv_path_CHECK_GMAKE 19125 if test -n "$CHECK_GMAKE"; then 19126 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CHECK_GMAKE" >&5 19127 $as_echo "$CHECK_GMAKE" >&6; } 19128 else 19129 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 19130 $as_echo "no" >&6; } 19131 fi 19132 19133 19134 test -n "$CHECK_GMAKE" && break 19135 done 19136 19137 19138 MAKE_CANDIDATE=""$CHECK_GMAKE"" 19139 DESCRIPTION="gmake in PATH" 19140 19141 # On Cygwin, we require a newer version of make than on other platforms 19142 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 19143 MAKE_VERSION_EXPR="-e 4\." 19144 MAKE_REQUIRED_VERSION="4.0" 19145 else 19146 MAKE_VERSION_EXPR="-e 3\.8[12] -e 4\." 19147 MAKE_REQUIRED_VERSION="3.81" 19148 fi 19149 19150 if test "x$MAKE_CANDIDATE" != x; then 19151 { $as_echo "$as_me:${as_lineno-$LINENO}: Testing potential make at $MAKE_CANDIDATE, found using $DESCRIPTION" >&5 19152 $as_echo "$as_me: Testing potential make at $MAKE_CANDIDATE, found using $DESCRIPTION" >&6;} 19153 MAKE_VERSION_STRING=`$MAKE_CANDIDATE --version | $HEAD -n 1` 19154 IS_GNU_MAKE=`$ECHO $MAKE_VERSION_STRING | $GREP 'GNU Make'` 19155 if test "x$IS_GNU_MAKE" = x; then 19156 { $as_echo "$as_me:${as_lineno-$LINENO}: Found potential make at $MAKE_CANDIDATE, however, this is not GNU Make. Ignoring." >&5 19157 $as_echo "$as_me: Found potential make at $MAKE_CANDIDATE, however, this is not GNU Make. Ignoring." >&6;} 19158 else 19159 IS_MODERN_MAKE=`$ECHO $MAKE_VERSION_STRING | $GREP $MAKE_VERSION_EXPR` 19160 if test "x$IS_MODERN_MAKE" = x; then 19161 { $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 19162 $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;} 19163 else 19164 if test "x$OPENJDK_BUILD_OS" = "xwindows"; then 19165 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 19166 MAKE_EXPECTED_ENV='cygwin' 19167 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 19168 MAKE_EXPECTED_ENV='msys' 19169 else 19170 as_fn_error $? "Unknown Windows environment" "$LINENO" 5 19171 fi 19172 MAKE_BUILT_FOR=`$MAKE_CANDIDATE --version | $GREP -i 'built for'` 19173 IS_MAKE_CORRECT_ENV=`$ECHO $MAKE_BUILT_FOR | $GREP $MAKE_EXPECTED_ENV` 19174 else 19175 # Not relevant for non-Windows 19176 IS_MAKE_CORRECT_ENV=true 19177 fi 19178 if test "x$IS_MAKE_CORRECT_ENV" = x; then 19179 { $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 19180 $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;} 19181 else 19182 FOUND_MAKE=$MAKE_CANDIDATE 19183 19184 # Only process if variable expands to non-empty 19185 19186 if test "x$FOUND_MAKE" != x; then 19187 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 19188 19189 # First separate the path from the arguments. This will split at the first 19190 # space. 19191 complete="$FOUND_MAKE" 19192 path="${complete%% *}" 19193 tmp="$complete EOL" 19194 arguments="${tmp#* }" 19195 19196 # Input might be given as Windows format, start by converting to 19197 # unix format. 19198 new_path=`$CYGPATH -u "$path"` 19199 19200 # Now try to locate executable using which 19201 new_path=`$WHICH "$new_path" 2> /dev/null` 19202 # bat and cmd files are not always considered executable in cygwin causing which 19203 # to not find them 19204 if test "x$new_path" = x \ 19205 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 19206 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 19207 new_path=`$CYGPATH -u "$path"` 19208 fi 19209 if test "x$new_path" = x; then 19210 # Oops. Which didn't find the executable. 19211 # The splitting of arguments from the executable at a space might have been incorrect, 19212 # since paths with space are more likely in Windows. Give it another try with the whole 19213 # argument. 19214 path="$complete" 19215 arguments="EOL" 19216 new_path=`$CYGPATH -u "$path"` 19217 new_path=`$WHICH "$new_path" 2> /dev/null` 19218 # bat and cmd files are not always considered executable in cygwin causing which 19219 # to not find them 19220 if test "x$new_path" = x \ 19221 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 19222 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 19223 new_path=`$CYGPATH -u "$path"` 19224 fi 19225 if test "x$new_path" = x; then 19226 # It's still not found. Now this is an unrecoverable error. 19227 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of FOUND_MAKE, which resolves as \"$complete\", is not found." >&5 19228 $as_echo "$as_me: The path of FOUND_MAKE, which resolves as \"$complete\", is not found." >&6;} 19229 has_space=`$ECHO "$complete" | $GREP " "` 19230 if test "x$has_space" != x; then 19231 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 19232 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 19233 fi 19234 as_fn_error $? "Cannot locate the the path of FOUND_MAKE" "$LINENO" 5 19235 fi 19236 fi 19237 19238 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 19239 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 19240 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 19241 # "foo.exe" is OK but "foo" is an error. 19242 # 19243 # This test is therefore slightly more accurate than "test -f" to check for file presence. 19244 # It is also a way to make sure we got the proper file name for the real test later on. 19245 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 19246 if test "x$test_shortpath" = x; then 19247 # Short path failed, file does not exist as specified. 19248 # Try adding .exe or .cmd 19249 if test -f "${new_path}.exe"; then 19250 input_to_shortpath="${new_path}.exe" 19251 elif test -f "${new_path}.cmd"; then 19252 input_to_shortpath="${new_path}.cmd" 19253 else 19254 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of FOUND_MAKE, which resolves as \"$new_path\", is invalid." >&5 19255 $as_echo "$as_me: The path of FOUND_MAKE, which resolves as \"$new_path\", is invalid." >&6;} 19256 { $as_echo "$as_me:${as_lineno-$LINENO}: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&5 19257 $as_echo "$as_me: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&6;} 19258 as_fn_error $? "Cannot locate the the path of FOUND_MAKE" "$LINENO" 5 19259 fi 19260 else 19261 input_to_shortpath="$new_path" 19262 fi 19263 19264 # Call helper function which possibly converts this using DOS-style short mode. 19265 # If so, the updated path is stored in $new_path. 19266 new_path="$input_to_shortpath" 19267 19268 input_path="$input_to_shortpath" 19269 # Check if we need to convert this using DOS-style short mode. If the path 19270 # contains just simple characters, use it. Otherwise (spaces, weird characters), 19271 # take no chances and rewrite it. 19272 # Note: m4 eats our [], so we need to use [ and ] instead. 19273 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 19274 if test "x$has_forbidden_chars" != x; then 19275 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 19276 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 19277 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 19278 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 19279 # Going to short mode and back again did indeed matter. Since short mode is 19280 # case insensitive, let's make it lowercase to improve readability. 19281 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 19282 # Now convert it back to Unix-style (cygpath) 19283 input_path=`$CYGPATH -u "$shortmode_path"` 19284 new_path="$input_path" 19285 fi 19286 fi 19287 19288 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 19289 if test "x$test_cygdrive_prefix" = x; then 19290 # As a simple fix, exclude /usr/bin since it's not a real path. 19291 if test "x`$ECHO $input_to_shortpath | $GREP ^/usr/bin/`" = x; then 19292 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 19293 # a path prefixed by /cygdrive for fixpath to work. 19294 new_path="$CYGWIN_ROOT_PATH$input_path" 19295 fi 19296 fi 19297 19298 # remove trailing .exe if any 19299 new_path="${new_path/%.exe/}" 19300 19301 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 19302 19303 # First separate the path from the arguments. This will split at the first 19304 # space. 19305 complete="$FOUND_MAKE" 19306 path="${complete%% *}" 19307 tmp="$complete EOL" 19308 arguments="${tmp#* }" 19309 19310 # Input might be given as Windows format, start by converting to 19311 # unix format. 19312 new_path="$path" 19313 19314 windows_path="$new_path" 19315 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 19316 unix_path=`$CYGPATH -u "$windows_path"` 19317 new_path="$unix_path" 19318 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 19319 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 19320 new_path="$unix_path" 19321 fi 19322 19323 19324 # Now try to locate executable using which 19325 new_path=`$WHICH "$new_path" 2> /dev/null` 19326 19327 if test "x$new_path" = x; then 19328 # Oops. Which didn't find the executable. 19329 # The splitting of arguments from the executable at a space might have been incorrect, 19330 # since paths with space are more likely in Windows. Give it another try with the whole 19331 # argument. 19332 path="$complete" 19333 arguments="EOL" 19334 new_path="$path" 19335 19336 windows_path="$new_path" 19337 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 19338 unix_path=`$CYGPATH -u "$windows_path"` 19339 new_path="$unix_path" 19340 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 19341 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 19342 new_path="$unix_path" 19343 fi 19344 19345 19346 new_path=`$WHICH "$new_path" 2> /dev/null` 19347 # bat and cmd files are not always considered executable in MSYS causing which 19348 # to not find them 19349 if test "x$new_path" = x \ 19350 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 19351 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 19352 new_path="$path" 19353 19354 windows_path="$new_path" 19355 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 19356 unix_path=`$CYGPATH -u "$windows_path"` 19357 new_path="$unix_path" 19358 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 19359 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 19360 new_path="$unix_path" 19361 fi 19362 19363 fi 19364 19365 if test "x$new_path" = x; then 19366 # It's still not found. Now this is an unrecoverable error. 19367 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of FOUND_MAKE, which resolves as \"$complete\", is not found." >&5 19368 $as_echo "$as_me: The path of FOUND_MAKE, which resolves as \"$complete\", is not found." >&6;} 19369 has_space=`$ECHO "$complete" | $GREP " "` 19370 if test "x$has_space" != x; then 19371 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 19372 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 19373 fi 19374 as_fn_error $? "Cannot locate the the path of FOUND_MAKE" "$LINENO" 5 19375 fi 19376 fi 19377 19378 # Now new_path has a complete unix path to the binary 19379 if test "x`$ECHO $new_path | $GREP ^/bin/`" != x; then 19380 # Keep paths in /bin as-is, but remove trailing .exe if any 19381 new_path="${new_path/%.exe/}" 19382 # Do not save /bin paths to all_fixpath_prefixes! 19383 else 19384 # Not in mixed or Windows style, start by that. 19385 new_path=`cmd //c echo $new_path` 19386 19387 input_path="$new_path" 19388 # Check if we need to convert this using DOS-style short mode. If the path 19389 # contains just simple characters, use it. Otherwise (spaces, weird characters), 19390 # take no chances and rewrite it. 19391 # Note: m4 eats our [], so we need to use [ and ] instead. 19392 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 19393 if test "x$has_forbidden_chars" != x; then 19394 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 19395 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 19396 fi 19397 19398 # Output is in $new_path 19399 19400 windows_path="$new_path" 19401 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 19402 unix_path=`$CYGPATH -u "$windows_path"` 19403 new_path="$unix_path" 19404 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 19405 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 19406 new_path="$unix_path" 19407 fi 19408 19409 # remove trailing .exe if any 19410 new_path="${new_path/%.exe/}" 19411 19412 # Save the first 10 bytes of this path to the storage, so fixpath can work. 19413 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 19414 fi 19415 19416 else 19417 # We're on a unix platform. Hooray! :) 19418 # First separate the path from the arguments. This will split at the first 19419 # space. 19420 complete="$FOUND_MAKE" 19421 path="${complete%% *}" 19422 tmp="$complete EOL" 19423 arguments="${tmp#* }" 19424 19425 # Cannot rely on the command "which" here since it doesn't always work. 19426 is_absolute_path=`$ECHO "$path" | $GREP ^/` 19427 if test -z "$is_absolute_path"; then 19428 # Path to executable is not absolute. Find it. 19429 IFS_save="$IFS" 19430 IFS=: 19431 for p in $PATH; do 19432 if test -f "$p/$path" && test -x "$p/$path"; then 19433 new_path="$p/$path" 19434 break 19435 fi 19436 done 19437 IFS="$IFS_save" 19438 else 19439 # This is an absolute path, we can use it without further modifications. 19440 new_path="$path" 19441 fi 19442 19443 if test "x$new_path" = x; then 19444 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of FOUND_MAKE, which resolves as \"$complete\", is not found." >&5 19445 $as_echo "$as_me: The path of FOUND_MAKE, which resolves as \"$complete\", is not found." >&6;} 19446 has_space=`$ECHO "$complete" | $GREP " "` 19447 if test "x$has_space" != x; then 19448 { $as_echo "$as_me:${as_lineno-$LINENO}: This might be caused by spaces in the path, which is not allowed." >&5 19449 $as_echo "$as_me: This might be caused by spaces in the path, which is not allowed." >&6;} 19450 fi 19451 as_fn_error $? "Cannot locate the the path of FOUND_MAKE" "$LINENO" 5 19452 fi 19453 fi 19454 19455 # Now join together the path and the arguments once again 19456 if test "x$arguments" != xEOL; then 19457 new_complete="$new_path ${arguments% *}" 19458 else 19459 new_complete="$new_path" 19460 fi 19461 19462 if test "x$complete" != "x$new_complete"; then 19463 FOUND_MAKE="$new_complete" 19464 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting FOUND_MAKE to \"$new_complete\"" >&5 19465 $as_echo "$as_me: Rewriting FOUND_MAKE to \"$new_complete\"" >&6;} 19466 fi 19467 fi 19468 19469 fi 19470 fi 19471 fi 19472 fi 19473 19474 19475 if test "x$FOUND_MAKE" = x; then 19476 for ac_prog in make 19477 do 19478 # Extract the first word of "$ac_prog", so it can be a program name with args. 19479 set dummy $ac_prog; ac_word=$2 19480 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 19481 $as_echo_n "checking for $ac_word... " >&6; } 19482 if ${ac_cv_path_CHECK_MAKE+:} false; then : 19483 $as_echo_n "(cached) " >&6 19484 else 19485 case $CHECK_MAKE in 19486 [\\/]* | ?:[\\/]*) 19487 ac_cv_path_CHECK_MAKE="$CHECK_MAKE" # Let the user override the test with a path. 19488 ;; 19489 *) 19490 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 19491 for as_dir in $PATH 19492 do 19493 IFS=$as_save_IFS 19494 test -z "$as_dir" && as_dir=. 19495 for ac_exec_ext in '' $ac_executable_extensions; do 19496 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 19497 ac_cv_path_CHECK_MAKE="$as_dir/$ac_word$ac_exec_ext" 19498 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 19499 break 2 19500 fi 19501 done 19502 done 19503 IFS=$as_save_IFS 19504 19505 ;; 19506 esac 19507 fi 19508 CHECK_MAKE=$ac_cv_path_CHECK_MAKE 19509 if test -n "$CHECK_MAKE"; then 19510 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CHECK_MAKE" >&5 19511 $as_echo "$CHECK_MAKE" >&6; } 19512 else 19513 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 19514 $as_echo "no" >&6; } 19515 fi 19516 19517 19518 test -n "$CHECK_MAKE" && break 19519 done 19520 19521 19522 MAKE_CANDIDATE=""$CHECK_MAKE"" 19523 DESCRIPTION="make in PATH" 19524 19525 # On Cygwin, we require a newer version of make than on other platforms 19526 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 19527 MAKE_VERSION_EXPR="-e 4\." 19528 MAKE_REQUIRED_VERSION="4.0" 19529 else 19530 MAKE_VERSION_EXPR="-e 3\.8[12] -e 4\." 19531 MAKE_REQUIRED_VERSION="3.81" 19532 fi 19533 19534 if test "x$MAKE_CANDIDATE" != x; then 19535 { $as_echo "$as_me:${as_lineno-$LINENO}: Testing potential make at $MAKE_CANDIDATE, found using $DESCRIPTION" >&5 19536 $as_echo "$as_me: Testing potential make at $MAKE_CANDIDATE, found using $DESCRIPTION" >&6;} 19537 MAKE_VERSION_STRING=`$MAKE_CANDIDATE --version | $HEAD -n 1` 19538 IS_GNU_MAKE=`$ECHO $MAKE_VERSION_STRING | $GREP 'GNU Make'` 19539 if test "x$IS_GNU_MAKE" = x; then 19540 { $as_echo "$as_me:${as_lineno-$LINENO}: Found potential make at $MAKE_CANDIDATE, however, this is not GNU Make. Ignoring." >&5 19541 $as_echo "$as_me: Found potential make at $MAKE_CANDIDATE, however, this is not GNU Make. Ignoring." >&6;} 19542 else 19543 IS_MODERN_MAKE=`$ECHO $MAKE_VERSION_STRING | $GREP $MAKE_VERSION_EXPR` 19544 if test "x$IS_MODERN_MAKE" = x; then 19545 { $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 19546 $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;} 19547 else 19548 if test "x$OPENJDK_BUILD_OS" = "xwindows"; then 19549 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 19550 MAKE_EXPECTED_ENV='cygwin' 19551 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 19552 MAKE_EXPECTED_ENV='msys' 19553 else 19554 as_fn_error $? "Unknown Windows environment" "$LINENO" 5 19555 fi 19556 MAKE_BUILT_FOR=`$MAKE_CANDIDATE --version | $GREP -i 'built for'` 19557 IS_MAKE_CORRECT_ENV=`$ECHO $MAKE_BUILT_FOR | $GREP $MAKE_EXPECTED_ENV` 19558 else 19559 # Not relevant for non-Windows 19560 IS_MAKE_CORRECT_ENV=true 19561 fi 19562 if test "x$IS_MAKE_CORRECT_ENV" = x; then 19563 { $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 19564 $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;} 19565 else 19566 FOUND_MAKE=$MAKE_CANDIDATE 19567 19568 # Only process if variable expands to non-empty 19569 19570 if test "x$FOUND_MAKE" != x; then 19571 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 19572 19573 # First separate the path from the arguments. This will split at the first 19574 # space. 19575 complete="$FOUND_MAKE" 19576 path="${complete%% *}" 19577 tmp="$complete EOL" 19578 arguments="${tmp#* }" 19579 19580 # Input might be given as Windows format, start by converting to 19581 # unix format. 19582 new_path=`$CYGPATH -u "$path"` 19583 19584 # Now try to locate executable using which 19585 new_path=`$WHICH "$new_path" 2> /dev/null` 19586 # bat and cmd files are not always considered executable in cygwin causing which 19587 # to not find them 19588 if test "x$new_path" = x \ 19589 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 19590 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 19591 new_path=`$CYGPATH -u "$path"` 19592 fi 19593 if test "x$new_path" = x; then 19594 # Oops. Which didn't find the executable. 19595 # The splitting of arguments from the executable at a space might have been incorrect, 19596 # since paths with space are more likely in Windows. Give it another try with the whole 19597 # argument. 19598 path="$complete" 19599 arguments="EOL" 19600 new_path=`$CYGPATH -u "$path"` 19601 new_path=`$WHICH "$new_path" 2> /dev/null` 19602 # bat and cmd files are not always considered executable in cygwin causing which 19603 # to not find them 19604 if test "x$new_path" = x \ 19605 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 19606 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 19607 new_path=`$CYGPATH -u "$path"` 19608 fi 19609 if test "x$new_path" = x; then 19610 # It's still not found. Now this is an unrecoverable error. 19611 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of FOUND_MAKE, which resolves as \"$complete\", is not found." >&5 19612 $as_echo "$as_me: The path of FOUND_MAKE, which resolves as \"$complete\", is not found." >&6;} 19613 has_space=`$ECHO "$complete" | $GREP " "` 19614 if test "x$has_space" != x; then 19615 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 19616 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 19617 fi 19618 as_fn_error $? "Cannot locate the the path of FOUND_MAKE" "$LINENO" 5 19619 fi 19620 fi 19621 19622 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 19623 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 19624 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 19625 # "foo.exe" is OK but "foo" is an error. 19626 # 19627 # This test is therefore slightly more accurate than "test -f" to check for file presence. 19628 # It is also a way to make sure we got the proper file name for the real test later on. 19629 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 19630 if test "x$test_shortpath" = x; then 19631 # Short path failed, file does not exist as specified. 19632 # Try adding .exe or .cmd 19633 if test -f "${new_path}.exe"; then 19634 input_to_shortpath="${new_path}.exe" 19635 elif test -f "${new_path}.cmd"; then 19636 input_to_shortpath="${new_path}.cmd" 19637 else 19638 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of FOUND_MAKE, which resolves as \"$new_path\", is invalid." >&5 19639 $as_echo "$as_me: The path of FOUND_MAKE, which resolves as \"$new_path\", is invalid." >&6;} 19640 { $as_echo "$as_me:${as_lineno-$LINENO}: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&5 19641 $as_echo "$as_me: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&6;} 19642 as_fn_error $? "Cannot locate the the path of FOUND_MAKE" "$LINENO" 5 19643 fi 19644 else 19645 input_to_shortpath="$new_path" 19646 fi 19647 19648 # Call helper function which possibly converts this using DOS-style short mode. 19649 # If so, the updated path is stored in $new_path. 19650 new_path="$input_to_shortpath" 19651 19652 input_path="$input_to_shortpath" 19653 # Check if we need to convert this using DOS-style short mode. If the path 19654 # contains just simple characters, use it. Otherwise (spaces, weird characters), 19655 # take no chances and rewrite it. 19656 # Note: m4 eats our [], so we need to use [ and ] instead. 19657 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 19658 if test "x$has_forbidden_chars" != x; then 19659 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 19660 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 19661 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 19662 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 19663 # Going to short mode and back again did indeed matter. Since short mode is 19664 # case insensitive, let's make it lowercase to improve readability. 19665 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 19666 # Now convert it back to Unix-style (cygpath) 19667 input_path=`$CYGPATH -u "$shortmode_path"` 19668 new_path="$input_path" 19669 fi 19670 fi 19671 19672 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 19673 if test "x$test_cygdrive_prefix" = x; then 19674 # As a simple fix, exclude /usr/bin since it's not a real path. 19675 if test "x`$ECHO $input_to_shortpath | $GREP ^/usr/bin/`" = x; then 19676 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 19677 # a path prefixed by /cygdrive for fixpath to work. 19678 new_path="$CYGWIN_ROOT_PATH$input_path" 19679 fi 19680 fi 19681 19682 # remove trailing .exe if any 19683 new_path="${new_path/%.exe/}" 19684 19685 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 19686 19687 # First separate the path from the arguments. This will split at the first 19688 # space. 19689 complete="$FOUND_MAKE" 19690 path="${complete%% *}" 19691 tmp="$complete EOL" 19692 arguments="${tmp#* }" 19693 19694 # Input might be given as Windows format, start by converting to 19695 # unix format. 19696 new_path="$path" 19697 19698 windows_path="$new_path" 19699 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 19700 unix_path=`$CYGPATH -u "$windows_path"` 19701 new_path="$unix_path" 19702 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 19703 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 19704 new_path="$unix_path" 19705 fi 19706 19707 19708 # Now try to locate executable using which 19709 new_path=`$WHICH "$new_path" 2> /dev/null` 19710 19711 if test "x$new_path" = x; then 19712 # Oops. Which didn't find the executable. 19713 # The splitting of arguments from the executable at a space might have been incorrect, 19714 # since paths with space are more likely in Windows. Give it another try with the whole 19715 # argument. 19716 path="$complete" 19717 arguments="EOL" 19718 new_path="$path" 19719 19720 windows_path="$new_path" 19721 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 19722 unix_path=`$CYGPATH -u "$windows_path"` 19723 new_path="$unix_path" 19724 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 19725 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 19726 new_path="$unix_path" 19727 fi 19728 19729 19730 new_path=`$WHICH "$new_path" 2> /dev/null` 19731 # bat and cmd files are not always considered executable in MSYS causing which 19732 # to not find them 19733 if test "x$new_path" = x \ 19734 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 19735 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 19736 new_path="$path" 19737 19738 windows_path="$new_path" 19739 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 19740 unix_path=`$CYGPATH -u "$windows_path"` 19741 new_path="$unix_path" 19742 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 19743 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 19744 new_path="$unix_path" 19745 fi 19746 19747 fi 19748 19749 if test "x$new_path" = x; then 19750 # It's still not found. Now this is an unrecoverable error. 19751 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of FOUND_MAKE, which resolves as \"$complete\", is not found." >&5 19752 $as_echo "$as_me: The path of FOUND_MAKE, which resolves as \"$complete\", is not found." >&6;} 19753 has_space=`$ECHO "$complete" | $GREP " "` 19754 if test "x$has_space" != x; then 19755 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 19756 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 19757 fi 19758 as_fn_error $? "Cannot locate the the path of FOUND_MAKE" "$LINENO" 5 19759 fi 19760 fi 19761 19762 # Now new_path has a complete unix path to the binary 19763 if test "x`$ECHO $new_path | $GREP ^/bin/`" != x; then 19764 # Keep paths in /bin as-is, but remove trailing .exe if any 19765 new_path="${new_path/%.exe/}" 19766 # Do not save /bin paths to all_fixpath_prefixes! 19767 else 19768 # Not in mixed or Windows style, start by that. 19769 new_path=`cmd //c echo $new_path` 19770 19771 input_path="$new_path" 19772 # Check if we need to convert this using DOS-style short mode. If the path 19773 # contains just simple characters, use it. Otherwise (spaces, weird characters), 19774 # take no chances and rewrite it. 19775 # Note: m4 eats our [], so we need to use [ and ] instead. 19776 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 19777 if test "x$has_forbidden_chars" != x; then 19778 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 19779 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 19780 fi 19781 19782 # Output is in $new_path 19783 19784 windows_path="$new_path" 19785 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 19786 unix_path=`$CYGPATH -u "$windows_path"` 19787 new_path="$unix_path" 19788 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 19789 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 19790 new_path="$unix_path" 19791 fi 19792 19793 # remove trailing .exe if any 19794 new_path="${new_path/%.exe/}" 19795 19796 # Save the first 10 bytes of this path to the storage, so fixpath can work. 19797 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 19798 fi 19799 19800 else 19801 # We're on a unix platform. Hooray! :) 19802 # First separate the path from the arguments. This will split at the first 19803 # space. 19804 complete="$FOUND_MAKE" 19805 path="${complete%% *}" 19806 tmp="$complete EOL" 19807 arguments="${tmp#* }" 19808 19809 # Cannot rely on the command "which" here since it doesn't always work. 19810 is_absolute_path=`$ECHO "$path" | $GREP ^/` 19811 if test -z "$is_absolute_path"; then 19812 # Path to executable is not absolute. Find it. 19813 IFS_save="$IFS" 19814 IFS=: 19815 for p in $PATH; do 19816 if test -f "$p/$path" && test -x "$p/$path"; then 19817 new_path="$p/$path" 19818 break 19819 fi 19820 done 19821 IFS="$IFS_save" 19822 else 19823 # This is an absolute path, we can use it without further modifications. 19824 new_path="$path" 19825 fi 19826 19827 if test "x$new_path" = x; then 19828 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of FOUND_MAKE, which resolves as \"$complete\", is not found." >&5 19829 $as_echo "$as_me: The path of FOUND_MAKE, which resolves as \"$complete\", is not found." >&6;} 19830 has_space=`$ECHO "$complete" | $GREP " "` 19831 if test "x$has_space" != x; then 19832 { $as_echo "$as_me:${as_lineno-$LINENO}: This might be caused by spaces in the path, which is not allowed." >&5 19833 $as_echo "$as_me: This might be caused by spaces in the path, which is not allowed." >&6;} 19834 fi 19835 as_fn_error $? "Cannot locate the the path of FOUND_MAKE" "$LINENO" 5 19836 fi 19837 fi 19838 19839 # Now join together the path and the arguments once again 19840 if test "x$arguments" != xEOL; then 19841 new_complete="$new_path ${arguments% *}" 19842 else 19843 new_complete="$new_path" 19844 fi 19845 19846 if test "x$complete" != "x$new_complete"; then 19847 FOUND_MAKE="$new_complete" 19848 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting FOUND_MAKE to \"$new_complete\"" >&5 19849 $as_echo "$as_me: Rewriting FOUND_MAKE to \"$new_complete\"" >&6;} 19850 fi 19851 fi 19852 19853 fi 19854 fi 19855 fi 19856 fi 19857 19858 fi 19859 19860 if test "x$FOUND_MAKE" = x; then 19861 if test "x$TOOLCHAIN_PATH" != x; then 19862 # We have a toolchain path, check that as well before giving up. 19863 OLD_PATH=$PATH 19864 PATH=$TOOLCHAIN_PATH:$PATH 19865 for ac_prog in gmake 19866 do 19867 # Extract the first word of "$ac_prog", so it can be a program name with args. 19868 set dummy $ac_prog; ac_word=$2 19869 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 19870 $as_echo_n "checking for $ac_word... " >&6; } 19871 if ${ac_cv_path_CHECK_TOOLSDIR_GMAKE+:} false; then : 19872 $as_echo_n "(cached) " >&6 19873 else 19874 case $CHECK_TOOLSDIR_GMAKE in 19875 [\\/]* | ?:[\\/]*) 19876 ac_cv_path_CHECK_TOOLSDIR_GMAKE="$CHECK_TOOLSDIR_GMAKE" # Let the user override the test with a path. 19877 ;; 19878 *) 19879 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 19880 for as_dir in $PATH 19881 do 19882 IFS=$as_save_IFS 19883 test -z "$as_dir" && as_dir=. 19884 for ac_exec_ext in '' $ac_executable_extensions; do 19885 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 19886 ac_cv_path_CHECK_TOOLSDIR_GMAKE="$as_dir/$ac_word$ac_exec_ext" 19887 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 19888 break 2 19889 fi 19890 done 19891 done 19892 IFS=$as_save_IFS 19893 19894 ;; 19895 esac 19896 fi 19897 CHECK_TOOLSDIR_GMAKE=$ac_cv_path_CHECK_TOOLSDIR_GMAKE 19898 if test -n "$CHECK_TOOLSDIR_GMAKE"; then 19899 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CHECK_TOOLSDIR_GMAKE" >&5 19900 $as_echo "$CHECK_TOOLSDIR_GMAKE" >&6; } 19901 else 19902 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 19903 $as_echo "no" >&6; } 19904 fi 19905 19906 19907 test -n "$CHECK_TOOLSDIR_GMAKE" && break 19908 done 19909 19910 19911 MAKE_CANDIDATE=""$CHECK_TOOLSDIR_GMAKE"" 19912 DESCRIPTION="gmake in tools-dir" 19913 19914 # On Cygwin, we require a newer version of make than on other platforms 19915 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 19916 MAKE_VERSION_EXPR="-e 4\." 19917 MAKE_REQUIRED_VERSION="4.0" 19918 else 19919 MAKE_VERSION_EXPR="-e 3\.8[12] -e 4\." 19920 MAKE_REQUIRED_VERSION="3.81" 19921 fi 19922 19923 if test "x$MAKE_CANDIDATE" != x; then 19924 { $as_echo "$as_me:${as_lineno-$LINENO}: Testing potential make at $MAKE_CANDIDATE, found using $DESCRIPTION" >&5 19925 $as_echo "$as_me: Testing potential make at $MAKE_CANDIDATE, found using $DESCRIPTION" >&6;} 19926 MAKE_VERSION_STRING=`$MAKE_CANDIDATE --version | $HEAD -n 1` 19927 IS_GNU_MAKE=`$ECHO $MAKE_VERSION_STRING | $GREP 'GNU Make'` 19928 if test "x$IS_GNU_MAKE" = x; then 19929 { $as_echo "$as_me:${as_lineno-$LINENO}: Found potential make at $MAKE_CANDIDATE, however, this is not GNU Make. Ignoring." >&5 19930 $as_echo "$as_me: Found potential make at $MAKE_CANDIDATE, however, this is not GNU Make. Ignoring." >&6;} 19931 else 19932 IS_MODERN_MAKE=`$ECHO $MAKE_VERSION_STRING | $GREP $MAKE_VERSION_EXPR` 19933 if test "x$IS_MODERN_MAKE" = x; then 19934 { $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 19935 $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;} 19936 else 19937 if test "x$OPENJDK_BUILD_OS" = "xwindows"; then 19938 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 19939 MAKE_EXPECTED_ENV='cygwin' 19940 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 19941 MAKE_EXPECTED_ENV='msys' 19942 else 19943 as_fn_error $? "Unknown Windows environment" "$LINENO" 5 19944 fi 19945 MAKE_BUILT_FOR=`$MAKE_CANDIDATE --version | $GREP -i 'built for'` 19946 IS_MAKE_CORRECT_ENV=`$ECHO $MAKE_BUILT_FOR | $GREP $MAKE_EXPECTED_ENV` 19947 else 19948 # Not relevant for non-Windows 19949 IS_MAKE_CORRECT_ENV=true 19950 fi 19951 if test "x$IS_MAKE_CORRECT_ENV" = x; then 19952 { $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 19953 $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;} 19954 else 19955 FOUND_MAKE=$MAKE_CANDIDATE 19956 19957 # Only process if variable expands to non-empty 19958 19959 if test "x$FOUND_MAKE" != x; then 19960 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 19961 19962 # First separate the path from the arguments. This will split at the first 19963 # space. 19964 complete="$FOUND_MAKE" 19965 path="${complete%% *}" 19966 tmp="$complete EOL" 19967 arguments="${tmp#* }" 19968 19969 # Input might be given as Windows format, start by converting to 19970 # unix format. 19971 new_path=`$CYGPATH -u "$path"` 19972 19973 # Now try to locate executable using which 19974 new_path=`$WHICH "$new_path" 2> /dev/null` 19975 # bat and cmd files are not always considered executable in cygwin causing which 19976 # to not find them 19977 if test "x$new_path" = x \ 19978 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 19979 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 19980 new_path=`$CYGPATH -u "$path"` 19981 fi 19982 if test "x$new_path" = x; then 19983 # Oops. Which didn't find the executable. 19984 # The splitting of arguments from the executable at a space might have been incorrect, 19985 # since paths with space are more likely in Windows. Give it another try with the whole 19986 # argument. 19987 path="$complete" 19988 arguments="EOL" 19989 new_path=`$CYGPATH -u "$path"` 19990 new_path=`$WHICH "$new_path" 2> /dev/null` 19991 # bat and cmd files are not always considered executable in cygwin causing which 19992 # to not find them 19993 if test "x$new_path" = x \ 19994 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 19995 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 19996 new_path=`$CYGPATH -u "$path"` 19997 fi 19998 if test "x$new_path" = x; then 19999 # It's still not found. Now this is an unrecoverable error. 20000 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of FOUND_MAKE, which resolves as \"$complete\", is not found." >&5 20001 $as_echo "$as_me: The path of FOUND_MAKE, which resolves as \"$complete\", is not found." >&6;} 20002 has_space=`$ECHO "$complete" | $GREP " "` 20003 if test "x$has_space" != x; then 20004 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 20005 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 20006 fi 20007 as_fn_error $? "Cannot locate the the path of FOUND_MAKE" "$LINENO" 5 20008 fi 20009 fi 20010 20011 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 20012 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 20013 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 20014 # "foo.exe" is OK but "foo" is an error. 20015 # 20016 # This test is therefore slightly more accurate than "test -f" to check for file presence. 20017 # It is also a way to make sure we got the proper file name for the real test later on. 20018 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 20019 if test "x$test_shortpath" = x; then 20020 # Short path failed, file does not exist as specified. 20021 # Try adding .exe or .cmd 20022 if test -f "${new_path}.exe"; then 20023 input_to_shortpath="${new_path}.exe" 20024 elif test -f "${new_path}.cmd"; then 20025 input_to_shortpath="${new_path}.cmd" 20026 else 20027 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of FOUND_MAKE, which resolves as \"$new_path\", is invalid." >&5 20028 $as_echo "$as_me: The path of FOUND_MAKE, which resolves as \"$new_path\", is invalid." >&6;} 20029 { $as_echo "$as_me:${as_lineno-$LINENO}: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&5 20030 $as_echo "$as_me: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&6;} 20031 as_fn_error $? "Cannot locate the the path of FOUND_MAKE" "$LINENO" 5 20032 fi 20033 else 20034 input_to_shortpath="$new_path" 20035 fi 20036 20037 # Call helper function which possibly converts this using DOS-style short mode. 20038 # If so, the updated path is stored in $new_path. 20039 new_path="$input_to_shortpath" 20040 20041 input_path="$input_to_shortpath" 20042 # Check if we need to convert this using DOS-style short mode. If the path 20043 # contains just simple characters, use it. Otherwise (spaces, weird characters), 20044 # take no chances and rewrite it. 20045 # Note: m4 eats our [], so we need to use [ and ] instead. 20046 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 20047 if test "x$has_forbidden_chars" != x; then 20048 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 20049 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 20050 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 20051 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 20052 # Going to short mode and back again did indeed matter. Since short mode is 20053 # case insensitive, let's make it lowercase to improve readability. 20054 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 20055 # Now convert it back to Unix-style (cygpath) 20056 input_path=`$CYGPATH -u "$shortmode_path"` 20057 new_path="$input_path" 20058 fi 20059 fi 20060 20061 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 20062 if test "x$test_cygdrive_prefix" = x; then 20063 # As a simple fix, exclude /usr/bin since it's not a real path. 20064 if test "x`$ECHO $input_to_shortpath | $GREP ^/usr/bin/`" = x; then 20065 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 20066 # a path prefixed by /cygdrive for fixpath to work. 20067 new_path="$CYGWIN_ROOT_PATH$input_path" 20068 fi 20069 fi 20070 20071 # remove trailing .exe if any 20072 new_path="${new_path/%.exe/}" 20073 20074 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 20075 20076 # First separate the path from the arguments. This will split at the first 20077 # space. 20078 complete="$FOUND_MAKE" 20079 path="${complete%% *}" 20080 tmp="$complete EOL" 20081 arguments="${tmp#* }" 20082 20083 # Input might be given as Windows format, start by converting to 20084 # unix format. 20085 new_path="$path" 20086 20087 windows_path="$new_path" 20088 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 20089 unix_path=`$CYGPATH -u "$windows_path"` 20090 new_path="$unix_path" 20091 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 20092 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 20093 new_path="$unix_path" 20094 fi 20095 20096 20097 # Now try to locate executable using which 20098 new_path=`$WHICH "$new_path" 2> /dev/null` 20099 20100 if test "x$new_path" = x; then 20101 # Oops. Which didn't find the executable. 20102 # The splitting of arguments from the executable at a space might have been incorrect, 20103 # since paths with space are more likely in Windows. Give it another try with the whole 20104 # argument. 20105 path="$complete" 20106 arguments="EOL" 20107 new_path="$path" 20108 20109 windows_path="$new_path" 20110 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 20111 unix_path=`$CYGPATH -u "$windows_path"` 20112 new_path="$unix_path" 20113 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 20114 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 20115 new_path="$unix_path" 20116 fi 20117 20118 20119 new_path=`$WHICH "$new_path" 2> /dev/null` 20120 # bat and cmd files are not always considered executable in MSYS causing which 20121 # to not find them 20122 if test "x$new_path" = x \ 20123 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 20124 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 20125 new_path="$path" 20126 20127 windows_path="$new_path" 20128 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 20129 unix_path=`$CYGPATH -u "$windows_path"` 20130 new_path="$unix_path" 20131 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 20132 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 20133 new_path="$unix_path" 20134 fi 20135 20136 fi 20137 20138 if test "x$new_path" = x; then 20139 # It's still not found. Now this is an unrecoverable error. 20140 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of FOUND_MAKE, which resolves as \"$complete\", is not found." >&5 20141 $as_echo "$as_me: The path of FOUND_MAKE, which resolves as \"$complete\", is not found." >&6;} 20142 has_space=`$ECHO "$complete" | $GREP " "` 20143 if test "x$has_space" != x; then 20144 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 20145 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 20146 fi 20147 as_fn_error $? "Cannot locate the the path of FOUND_MAKE" "$LINENO" 5 20148 fi 20149 fi 20150 20151 # Now new_path has a complete unix path to the binary 20152 if test "x`$ECHO $new_path | $GREP ^/bin/`" != x; then 20153 # Keep paths in /bin as-is, but remove trailing .exe if any 20154 new_path="${new_path/%.exe/}" 20155 # Do not save /bin paths to all_fixpath_prefixes! 20156 else 20157 # Not in mixed or Windows style, start by that. 20158 new_path=`cmd //c echo $new_path` 20159 20160 input_path="$new_path" 20161 # Check if we need to convert this using DOS-style short mode. If the path 20162 # contains just simple characters, use it. Otherwise (spaces, weird characters), 20163 # take no chances and rewrite it. 20164 # Note: m4 eats our [], so we need to use [ and ] instead. 20165 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 20166 if test "x$has_forbidden_chars" != x; then 20167 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 20168 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 20169 fi 20170 20171 # Output is in $new_path 20172 20173 windows_path="$new_path" 20174 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 20175 unix_path=`$CYGPATH -u "$windows_path"` 20176 new_path="$unix_path" 20177 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 20178 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 20179 new_path="$unix_path" 20180 fi 20181 20182 # remove trailing .exe if any 20183 new_path="${new_path/%.exe/}" 20184 20185 # Save the first 10 bytes of this path to the storage, so fixpath can work. 20186 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 20187 fi 20188 20189 else 20190 # We're on a unix platform. Hooray! :) 20191 # First separate the path from the arguments. This will split at the first 20192 # space. 20193 complete="$FOUND_MAKE" 20194 path="${complete%% *}" 20195 tmp="$complete EOL" 20196 arguments="${tmp#* }" 20197 20198 # Cannot rely on the command "which" here since it doesn't always work. 20199 is_absolute_path=`$ECHO "$path" | $GREP ^/` 20200 if test -z "$is_absolute_path"; then 20201 # Path to executable is not absolute. Find it. 20202 IFS_save="$IFS" 20203 IFS=: 20204 for p in $PATH; do 20205 if test -f "$p/$path" && test -x "$p/$path"; then 20206 new_path="$p/$path" 20207 break 20208 fi 20209 done 20210 IFS="$IFS_save" 20211 else 20212 # This is an absolute path, we can use it without further modifications. 20213 new_path="$path" 20214 fi 20215 20216 if test "x$new_path" = x; then 20217 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of FOUND_MAKE, which resolves as \"$complete\", is not found." >&5 20218 $as_echo "$as_me: The path of FOUND_MAKE, which resolves as \"$complete\", is not found." >&6;} 20219 has_space=`$ECHO "$complete" | $GREP " "` 20220 if test "x$has_space" != x; then 20221 { $as_echo "$as_me:${as_lineno-$LINENO}: This might be caused by spaces in the path, which is not allowed." >&5 20222 $as_echo "$as_me: This might be caused by spaces in the path, which is not allowed." >&6;} 20223 fi 20224 as_fn_error $? "Cannot locate the the path of FOUND_MAKE" "$LINENO" 5 20225 fi 20226 fi 20227 20228 # Now join together the path and the arguments once again 20229 if test "x$arguments" != xEOL; then 20230 new_complete="$new_path ${arguments% *}" 20231 else 20232 new_complete="$new_path" 20233 fi 20234 20235 if test "x$complete" != "x$new_complete"; then 20236 FOUND_MAKE="$new_complete" 20237 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting FOUND_MAKE to \"$new_complete\"" >&5 20238 $as_echo "$as_me: Rewriting FOUND_MAKE to \"$new_complete\"" >&6;} 20239 fi 20240 fi 20241 20242 fi 20243 fi 20244 fi 20245 fi 20246 20247 if test "x$FOUND_MAKE" = x; then 20248 for ac_prog in make 20249 do 20250 # Extract the first word of "$ac_prog", so it can be a program name with args. 20251 set dummy $ac_prog; ac_word=$2 20252 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 20253 $as_echo_n "checking for $ac_word... " >&6; } 20254 if ${ac_cv_path_CHECK_TOOLSDIR_MAKE+:} false; then : 20255 $as_echo_n "(cached) " >&6 20256 else 20257 case $CHECK_TOOLSDIR_MAKE in 20258 [\\/]* | ?:[\\/]*) 20259 ac_cv_path_CHECK_TOOLSDIR_MAKE="$CHECK_TOOLSDIR_MAKE" # Let the user override the test with a path. 20260 ;; 20261 *) 20262 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 20263 for as_dir in $PATH 20264 do 20265 IFS=$as_save_IFS 20266 test -z "$as_dir" && as_dir=. 20267 for ac_exec_ext in '' $ac_executable_extensions; do 20268 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 20269 ac_cv_path_CHECK_TOOLSDIR_MAKE="$as_dir/$ac_word$ac_exec_ext" 20270 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 20271 break 2 20272 fi 20273 done 20274 done 20275 IFS=$as_save_IFS 20276 20277 ;; 20278 esac 20279 fi 20280 CHECK_TOOLSDIR_MAKE=$ac_cv_path_CHECK_TOOLSDIR_MAKE 20281 if test -n "$CHECK_TOOLSDIR_MAKE"; then 20282 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CHECK_TOOLSDIR_MAKE" >&5 20283 $as_echo "$CHECK_TOOLSDIR_MAKE" >&6; } 20284 else 20285 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 20286 $as_echo "no" >&6; } 20287 fi 20288 20289 20290 test -n "$CHECK_TOOLSDIR_MAKE" && break 20291 done 20292 20293 20294 MAKE_CANDIDATE=""$CHECK_TOOLSDIR_MAKE"" 20295 DESCRIPTION="make in tools-dir" 20296 20297 # On Cygwin, we require a newer version of make than on other platforms 20298 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 20299 MAKE_VERSION_EXPR="-e 4\." 20300 MAKE_REQUIRED_VERSION="4.0" 20301 else 20302 MAKE_VERSION_EXPR="-e 3\.8[12] -e 4\." 20303 MAKE_REQUIRED_VERSION="3.81" 20304 fi 20305 20306 if test "x$MAKE_CANDIDATE" != x; then 20307 { $as_echo "$as_me:${as_lineno-$LINENO}: Testing potential make at $MAKE_CANDIDATE, found using $DESCRIPTION" >&5 20308 $as_echo "$as_me: Testing potential make at $MAKE_CANDIDATE, found using $DESCRIPTION" >&6;} 20309 MAKE_VERSION_STRING=`$MAKE_CANDIDATE --version | $HEAD -n 1` 20310 IS_GNU_MAKE=`$ECHO $MAKE_VERSION_STRING | $GREP 'GNU Make'` 20311 if test "x$IS_GNU_MAKE" = x; then 20312 { $as_echo "$as_me:${as_lineno-$LINENO}: Found potential make at $MAKE_CANDIDATE, however, this is not GNU Make. Ignoring." >&5 20313 $as_echo "$as_me: Found potential make at $MAKE_CANDIDATE, however, this is not GNU Make. Ignoring." >&6;} 20314 else 20315 IS_MODERN_MAKE=`$ECHO $MAKE_VERSION_STRING | $GREP $MAKE_VERSION_EXPR` 20316 if test "x$IS_MODERN_MAKE" = x; then 20317 { $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 20318 $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;} 20319 else 20320 if test "x$OPENJDK_BUILD_OS" = "xwindows"; then 20321 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 20322 MAKE_EXPECTED_ENV='cygwin' 20323 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 20324 MAKE_EXPECTED_ENV='msys' 20325 else 20326 as_fn_error $? "Unknown Windows environment" "$LINENO" 5 20327 fi 20328 MAKE_BUILT_FOR=`$MAKE_CANDIDATE --version | $GREP -i 'built for'` 20329 IS_MAKE_CORRECT_ENV=`$ECHO $MAKE_BUILT_FOR | $GREP $MAKE_EXPECTED_ENV` 20330 else 20331 # Not relevant for non-Windows 20332 IS_MAKE_CORRECT_ENV=true 20333 fi 20334 if test "x$IS_MAKE_CORRECT_ENV" = x; then 20335 { $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 20336 $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;} 20337 else 20338 FOUND_MAKE=$MAKE_CANDIDATE 20339 20340 # Only process if variable expands to non-empty 20341 20342 if test "x$FOUND_MAKE" != x; then 20343 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 20344 20345 # First separate the path from the arguments. This will split at the first 20346 # space. 20347 complete="$FOUND_MAKE" 20348 path="${complete%% *}" 20349 tmp="$complete EOL" 20350 arguments="${tmp#* }" 20351 20352 # Input might be given as Windows format, start by converting to 20353 # unix format. 20354 new_path=`$CYGPATH -u "$path"` 20355 20356 # Now try to locate executable using which 20357 new_path=`$WHICH "$new_path" 2> /dev/null` 20358 # bat and cmd files are not always considered executable in cygwin causing which 20359 # to not find them 20360 if test "x$new_path" = x \ 20361 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 20362 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 20363 new_path=`$CYGPATH -u "$path"` 20364 fi 20365 if test "x$new_path" = x; then 20366 # Oops. Which didn't find the executable. 20367 # The splitting of arguments from the executable at a space might have been incorrect, 20368 # since paths with space are more likely in Windows. Give it another try with the whole 20369 # argument. 20370 path="$complete" 20371 arguments="EOL" 20372 new_path=`$CYGPATH -u "$path"` 20373 new_path=`$WHICH "$new_path" 2> /dev/null` 20374 # bat and cmd files are not always considered executable in cygwin causing which 20375 # to not find them 20376 if test "x$new_path" = x \ 20377 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 20378 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 20379 new_path=`$CYGPATH -u "$path"` 20380 fi 20381 if test "x$new_path" = x; then 20382 # It's still not found. Now this is an unrecoverable error. 20383 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of FOUND_MAKE, which resolves as \"$complete\", is not found." >&5 20384 $as_echo "$as_me: The path of FOUND_MAKE, which resolves as \"$complete\", is not found." >&6;} 20385 has_space=`$ECHO "$complete" | $GREP " "` 20386 if test "x$has_space" != x; then 20387 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 20388 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 20389 fi 20390 as_fn_error $? "Cannot locate the the path of FOUND_MAKE" "$LINENO" 5 20391 fi 20392 fi 20393 20394 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 20395 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 20396 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 20397 # "foo.exe" is OK but "foo" is an error. 20398 # 20399 # This test is therefore slightly more accurate than "test -f" to check for file presence. 20400 # It is also a way to make sure we got the proper file name for the real test later on. 20401 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 20402 if test "x$test_shortpath" = x; then 20403 # Short path failed, file does not exist as specified. 20404 # Try adding .exe or .cmd 20405 if test -f "${new_path}.exe"; then 20406 input_to_shortpath="${new_path}.exe" 20407 elif test -f "${new_path}.cmd"; then 20408 input_to_shortpath="${new_path}.cmd" 20409 else 20410 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of FOUND_MAKE, which resolves as \"$new_path\", is invalid." >&5 20411 $as_echo "$as_me: The path of FOUND_MAKE, which resolves as \"$new_path\", is invalid." >&6;} 20412 { $as_echo "$as_me:${as_lineno-$LINENO}: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&5 20413 $as_echo "$as_me: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&6;} 20414 as_fn_error $? "Cannot locate the the path of FOUND_MAKE" "$LINENO" 5 20415 fi 20416 else 20417 input_to_shortpath="$new_path" 20418 fi 20419 20420 # Call helper function which possibly converts this using DOS-style short mode. 20421 # If so, the updated path is stored in $new_path. 20422 new_path="$input_to_shortpath" 20423 20424 input_path="$input_to_shortpath" 20425 # Check if we need to convert this using DOS-style short mode. If the path 20426 # contains just simple characters, use it. Otherwise (spaces, weird characters), 20427 # take no chances and rewrite it. 20428 # Note: m4 eats our [], so we need to use [ and ] instead. 20429 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 20430 if test "x$has_forbidden_chars" != x; then 20431 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 20432 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 20433 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 20434 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 20435 # Going to short mode and back again did indeed matter. Since short mode is 20436 # case insensitive, let's make it lowercase to improve readability. 20437 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 20438 # Now convert it back to Unix-style (cygpath) 20439 input_path=`$CYGPATH -u "$shortmode_path"` 20440 new_path="$input_path" 20441 fi 20442 fi 20443 20444 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 20445 if test "x$test_cygdrive_prefix" = x; then 20446 # As a simple fix, exclude /usr/bin since it's not a real path. 20447 if test "x`$ECHO $input_to_shortpath | $GREP ^/usr/bin/`" = x; then 20448 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 20449 # a path prefixed by /cygdrive for fixpath to work. 20450 new_path="$CYGWIN_ROOT_PATH$input_path" 20451 fi 20452 fi 20453 20454 # remove trailing .exe if any 20455 new_path="${new_path/%.exe/}" 20456 20457 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 20458 20459 # First separate the path from the arguments. This will split at the first 20460 # space. 20461 complete="$FOUND_MAKE" 20462 path="${complete%% *}" 20463 tmp="$complete EOL" 20464 arguments="${tmp#* }" 20465 20466 # Input might be given as Windows format, start by converting to 20467 # unix format. 20468 new_path="$path" 20469 20470 windows_path="$new_path" 20471 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 20472 unix_path=`$CYGPATH -u "$windows_path"` 20473 new_path="$unix_path" 20474 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 20475 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 20476 new_path="$unix_path" 20477 fi 20478 20479 20480 # Now try to locate executable using which 20481 new_path=`$WHICH "$new_path" 2> /dev/null` 20482 20483 if test "x$new_path" = x; then 20484 # Oops. Which didn't find the executable. 20485 # The splitting of arguments from the executable at a space might have been incorrect, 20486 # since paths with space are more likely in Windows. Give it another try with the whole 20487 # argument. 20488 path="$complete" 20489 arguments="EOL" 20490 new_path="$path" 20491 20492 windows_path="$new_path" 20493 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 20494 unix_path=`$CYGPATH -u "$windows_path"` 20495 new_path="$unix_path" 20496 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 20497 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 20498 new_path="$unix_path" 20499 fi 20500 20501 20502 new_path=`$WHICH "$new_path" 2> /dev/null` 20503 # bat and cmd files are not always considered executable in MSYS causing which 20504 # to not find them 20505 if test "x$new_path" = x \ 20506 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 20507 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 20508 new_path="$path" 20509 20510 windows_path="$new_path" 20511 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 20512 unix_path=`$CYGPATH -u "$windows_path"` 20513 new_path="$unix_path" 20514 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 20515 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 20516 new_path="$unix_path" 20517 fi 20518 20519 fi 20520 20521 if test "x$new_path" = x; then 20522 # It's still not found. Now this is an unrecoverable error. 20523 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of FOUND_MAKE, which resolves as \"$complete\", is not found." >&5 20524 $as_echo "$as_me: The path of FOUND_MAKE, which resolves as \"$complete\", is not found." >&6;} 20525 has_space=`$ECHO "$complete" | $GREP " "` 20526 if test "x$has_space" != x; then 20527 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 20528 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 20529 fi 20530 as_fn_error $? "Cannot locate the the path of FOUND_MAKE" "$LINENO" 5 20531 fi 20532 fi 20533 20534 # Now new_path has a complete unix path to the binary 20535 if test "x`$ECHO $new_path | $GREP ^/bin/`" != x; then 20536 # Keep paths in /bin as-is, but remove trailing .exe if any 20537 new_path="${new_path/%.exe/}" 20538 # Do not save /bin paths to all_fixpath_prefixes! 20539 else 20540 # Not in mixed or Windows style, start by that. 20541 new_path=`cmd //c echo $new_path` 20542 20543 input_path="$new_path" 20544 # Check if we need to convert this using DOS-style short mode. If the path 20545 # contains just simple characters, use it. Otherwise (spaces, weird characters), 20546 # take no chances and rewrite it. 20547 # Note: m4 eats our [], so we need to use [ and ] instead. 20548 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 20549 if test "x$has_forbidden_chars" != x; then 20550 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 20551 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 20552 fi 20553 20554 # Output is in $new_path 20555 20556 windows_path="$new_path" 20557 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 20558 unix_path=`$CYGPATH -u "$windows_path"` 20559 new_path="$unix_path" 20560 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 20561 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 20562 new_path="$unix_path" 20563 fi 20564 20565 # remove trailing .exe if any 20566 new_path="${new_path/%.exe/}" 20567 20568 # Save the first 10 bytes of this path to the storage, so fixpath can work. 20569 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 20570 fi 20571 20572 else 20573 # We're on a unix platform. Hooray! :) 20574 # First separate the path from the arguments. This will split at the first 20575 # space. 20576 complete="$FOUND_MAKE" 20577 path="${complete%% *}" 20578 tmp="$complete EOL" 20579 arguments="${tmp#* }" 20580 20581 # Cannot rely on the command "which" here since it doesn't always work. 20582 is_absolute_path=`$ECHO "$path" | $GREP ^/` 20583 if test -z "$is_absolute_path"; then 20584 # Path to executable is not absolute. Find it. 20585 IFS_save="$IFS" 20586 IFS=: 20587 for p in $PATH; do 20588 if test -f "$p/$path" && test -x "$p/$path"; then 20589 new_path="$p/$path" 20590 break 20591 fi 20592 done 20593 IFS="$IFS_save" 20594 else 20595 # This is an absolute path, we can use it without further modifications. 20596 new_path="$path" 20597 fi 20598 20599 if test "x$new_path" = x; then 20600 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of FOUND_MAKE, which resolves as \"$complete\", is not found." >&5 20601 $as_echo "$as_me: The path of FOUND_MAKE, which resolves as \"$complete\", is not found." >&6;} 20602 has_space=`$ECHO "$complete" | $GREP " "` 20603 if test "x$has_space" != x; then 20604 { $as_echo "$as_me:${as_lineno-$LINENO}: This might be caused by spaces in the path, which is not allowed." >&5 20605 $as_echo "$as_me: This might be caused by spaces in the path, which is not allowed." >&6;} 20606 fi 20607 as_fn_error $? "Cannot locate the the path of FOUND_MAKE" "$LINENO" 5 20608 fi 20609 fi 20610 20611 # Now join together the path and the arguments once again 20612 if test "x$arguments" != xEOL; then 20613 new_complete="$new_path ${arguments% *}" 20614 else 20615 new_complete="$new_path" 20616 fi 20617 20618 if test "x$complete" != "x$new_complete"; then 20619 FOUND_MAKE="$new_complete" 20620 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting FOUND_MAKE to \"$new_complete\"" >&5 20621 $as_echo "$as_me: Rewriting FOUND_MAKE to \"$new_complete\"" >&6;} 20622 fi 20623 fi 20624 20625 fi 20626 fi 20627 fi 20628 fi 20629 20630 fi 20631 PATH=$OLD_PATH 20632 fi 20633 fi 20634 20635 if test "x$FOUND_MAKE" = x; then 20636 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 20637 fi 20638 20639 else 20640 # If it succeeded, then it was overridden by the user. We will use it 20641 # for the tool. 20642 20643 # First remove it from the list of overridden variables, so we can test 20644 # for unknown variables in the end. 20645 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 20646 20647 # Check if we try to supply an empty value 20648 if test "x$MAKE" = x; then 20649 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool MAKE= (no value)" >&5 20650 $as_echo "$as_me: Setting user supplied tool MAKE= (no value)" >&6;} 20651 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for MAKE" >&5 20652 $as_echo_n "checking for MAKE... " >&6; } 20653 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 20654 $as_echo "disabled" >&6; } 20655 else 20656 # Check if the provided tool contains a complete path. 20657 tool_specified="$MAKE" 20658 tool_basename="${tool_specified##*/}" 20659 if test "x$tool_basename" = "x$tool_specified"; then 20660 # A command without a complete path is provided, search $PATH. 20661 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool MAKE=$tool_basename" >&5 20662 $as_echo "$as_me: Will search for user supplied tool MAKE=$tool_basename" >&6;} 20663 # Extract the first word of "$tool_basename", so it can be a program name with args. 20664 set dummy $tool_basename; ac_word=$2 20665 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 20666 $as_echo_n "checking for $ac_word... " >&6; } 20667 if ${ac_cv_path_MAKE+:} false; then : 20668 $as_echo_n "(cached) " >&6 20669 else 20670 case $MAKE in 20671 [\\/]* | ?:[\\/]*) 20672 ac_cv_path_MAKE="$MAKE" # Let the user override the test with a path. 20673 ;; 20674 *) 20675 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 20676 for as_dir in $PATH 20677 do 20678 IFS=$as_save_IFS 20679 test -z "$as_dir" && as_dir=. 20680 for ac_exec_ext in '' $ac_executable_extensions; do 20681 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 20682 ac_cv_path_MAKE="$as_dir/$ac_word$ac_exec_ext" 20683 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 20684 break 2 20685 fi 20686 done 20687 done 20688 IFS=$as_save_IFS 20689 20690 ;; 20691 esac 20692 fi 20693 MAKE=$ac_cv_path_MAKE 20694 if test -n "$MAKE"; then 20695 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MAKE" >&5 20696 $as_echo "$MAKE" >&6; } 20697 else 20698 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 20699 $as_echo "no" >&6; } 20700 fi 20701 20702 20703 if test "x$MAKE" = x; then 20704 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 20705 fi 20706 else 20707 # Otherwise we believe it is a complete path. Use it as it is. 20708 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool MAKE=$tool_specified" >&5 20709 $as_echo "$as_me: Will use user supplied tool MAKE=$tool_specified" >&6;} 20710 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for MAKE" >&5 20711 $as_echo_n "checking for MAKE... " >&6; } 20712 if test ! -x "$tool_specified"; then 20713 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 20714 $as_echo "not found" >&6; } 20715 as_fn_error $? "User supplied tool MAKE=$tool_specified does not exist or is not executable" "$LINENO" 5 20716 fi 20717 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 20718 $as_echo "$tool_specified" >&6; } 20719 fi 20720 fi 20721 fi 20722 20723 # If MAKE was set by user, verify the version 20724 20725 MAKE_CANDIDATE=""$MAKE"" 20726 DESCRIPTION="user supplied MAKE=$MAKE" 20727 20728 # On Cygwin, we require a newer version of make than on other platforms 20729 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 20730 MAKE_VERSION_EXPR="-e 4\." 20731 MAKE_REQUIRED_VERSION="4.0" 20732 else 20733 MAKE_VERSION_EXPR="-e 3\.8[12] -e 4\." 20734 MAKE_REQUIRED_VERSION="3.81" 20735 fi 20736 20737 if test "x$MAKE_CANDIDATE" != x; then 20738 { $as_echo "$as_me:${as_lineno-$LINENO}: Testing potential make at $MAKE_CANDIDATE, found using $DESCRIPTION" >&5 20739 $as_echo "$as_me: Testing potential make at $MAKE_CANDIDATE, found using $DESCRIPTION" >&6;} 20740 MAKE_VERSION_STRING=`$MAKE_CANDIDATE --version | $HEAD -n 1` 20741 IS_GNU_MAKE=`$ECHO $MAKE_VERSION_STRING | $GREP 'GNU Make'` 20742 if test "x$IS_GNU_MAKE" = x; then 20743 { $as_echo "$as_me:${as_lineno-$LINENO}: Found potential make at $MAKE_CANDIDATE, however, this is not GNU Make. Ignoring." >&5 20744 $as_echo "$as_me: Found potential make at $MAKE_CANDIDATE, however, this is not GNU Make. Ignoring." >&6;} 20745 else 20746 IS_MODERN_MAKE=`$ECHO $MAKE_VERSION_STRING | $GREP $MAKE_VERSION_EXPR` 20747 if test "x$IS_MODERN_MAKE" = x; then 20748 { $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 20749 $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;} 20750 else 20751 if test "x$OPENJDK_BUILD_OS" = "xwindows"; then 20752 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 20753 MAKE_EXPECTED_ENV='cygwin' 20754 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 20755 MAKE_EXPECTED_ENV='msys' 20756 else 20757 as_fn_error $? "Unknown Windows environment" "$LINENO" 5 20758 fi 20759 MAKE_BUILT_FOR=`$MAKE_CANDIDATE --version | $GREP -i 'built for'` 20760 IS_MAKE_CORRECT_ENV=`$ECHO $MAKE_BUILT_FOR | $GREP $MAKE_EXPECTED_ENV` 20761 else 20762 # Not relevant for non-Windows 20763 IS_MAKE_CORRECT_ENV=true 20764 fi 20765 if test "x$IS_MAKE_CORRECT_ENV" = x; then 20766 { $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 20767 $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;} 20768 else 20769 FOUND_MAKE=$MAKE_CANDIDATE 20770 20771 # Only process if variable expands to non-empty 20772 20773 if test "x$FOUND_MAKE" != x; then 20774 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 20775 20776 # First separate the path from the arguments. This will split at the first 20777 # space. 20778 complete="$FOUND_MAKE" 20779 path="${complete%% *}" 20780 tmp="$complete EOL" 20781 arguments="${tmp#* }" 20782 20783 # Input might be given as Windows format, start by converting to 20784 # unix format. 20785 new_path=`$CYGPATH -u "$path"` 20786 20787 # Now try to locate executable using which 20788 new_path=`$WHICH "$new_path" 2> /dev/null` 20789 # bat and cmd files are not always considered executable in cygwin causing which 20790 # to not find them 20791 if test "x$new_path" = x \ 20792 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 20793 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 20794 new_path=`$CYGPATH -u "$path"` 20795 fi 20796 if test "x$new_path" = x; then 20797 # Oops. Which didn't find the executable. 20798 # The splitting of arguments from the executable at a space might have been incorrect, 20799 # since paths with space are more likely in Windows. Give it another try with the whole 20800 # argument. 20801 path="$complete" 20802 arguments="EOL" 20803 new_path=`$CYGPATH -u "$path"` 20804 new_path=`$WHICH "$new_path" 2> /dev/null` 20805 # bat and cmd files are not always considered executable in cygwin causing which 20806 # to not find them 20807 if test "x$new_path" = x \ 20808 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 20809 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 20810 new_path=`$CYGPATH -u "$path"` 20811 fi 20812 if test "x$new_path" = x; then 20813 # It's still not found. Now this is an unrecoverable error. 20814 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of FOUND_MAKE, which resolves as \"$complete\", is not found." >&5 20815 $as_echo "$as_me: The path of FOUND_MAKE, which resolves as \"$complete\", is not found." >&6;} 20816 has_space=`$ECHO "$complete" | $GREP " "` 20817 if test "x$has_space" != x; then 20818 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 20819 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 20820 fi 20821 as_fn_error $? "Cannot locate the the path of FOUND_MAKE" "$LINENO" 5 20822 fi 20823 fi 20824 20825 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 20826 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 20827 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 20828 # "foo.exe" is OK but "foo" is an error. 20829 # 20830 # This test is therefore slightly more accurate than "test -f" to check for file presence. 20831 # It is also a way to make sure we got the proper file name for the real test later on. 20832 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 20833 if test "x$test_shortpath" = x; then 20834 # Short path failed, file does not exist as specified. 20835 # Try adding .exe or .cmd 20836 if test -f "${new_path}.exe"; then 20837 input_to_shortpath="${new_path}.exe" 20838 elif test -f "${new_path}.cmd"; then 20839 input_to_shortpath="${new_path}.cmd" 20840 else 20841 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of FOUND_MAKE, which resolves as \"$new_path\", is invalid." >&5 20842 $as_echo "$as_me: The path of FOUND_MAKE, which resolves as \"$new_path\", is invalid." >&6;} 20843 { $as_echo "$as_me:${as_lineno-$LINENO}: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&5 20844 $as_echo "$as_me: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&6;} 20845 as_fn_error $? "Cannot locate the the path of FOUND_MAKE" "$LINENO" 5 20846 fi 20847 else 20848 input_to_shortpath="$new_path" 20849 fi 20850 20851 # Call helper function which possibly converts this using DOS-style short mode. 20852 # If so, the updated path is stored in $new_path. 20853 new_path="$input_to_shortpath" 20854 20855 input_path="$input_to_shortpath" 20856 # Check if we need to convert this using DOS-style short mode. If the path 20857 # contains just simple characters, use it. Otherwise (spaces, weird characters), 20858 # take no chances and rewrite it. 20859 # Note: m4 eats our [], so we need to use [ and ] instead. 20860 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 20861 if test "x$has_forbidden_chars" != x; then 20862 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 20863 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 20864 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 20865 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 20866 # Going to short mode and back again did indeed matter. Since short mode is 20867 # case insensitive, let's make it lowercase to improve readability. 20868 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 20869 # Now convert it back to Unix-style (cygpath) 20870 input_path=`$CYGPATH -u "$shortmode_path"` 20871 new_path="$input_path" 20872 fi 20873 fi 20874 20875 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 20876 if test "x$test_cygdrive_prefix" = x; then 20877 # As a simple fix, exclude /usr/bin since it's not a real path. 20878 if test "x`$ECHO $input_to_shortpath | $GREP ^/usr/bin/`" = x; then 20879 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 20880 # a path prefixed by /cygdrive for fixpath to work. 20881 new_path="$CYGWIN_ROOT_PATH$input_path" 20882 fi 20883 fi 20884 20885 # remove trailing .exe if any 20886 new_path="${new_path/%.exe/}" 20887 20888 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 20889 20890 # First separate the path from the arguments. This will split at the first 20891 # space. 20892 complete="$FOUND_MAKE" 20893 path="${complete%% *}" 20894 tmp="$complete EOL" 20895 arguments="${tmp#* }" 20896 20897 # Input might be given as Windows format, start by converting to 20898 # unix format. 20899 new_path="$path" 20900 20901 windows_path="$new_path" 20902 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 20903 unix_path=`$CYGPATH -u "$windows_path"` 20904 new_path="$unix_path" 20905 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 20906 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 20907 new_path="$unix_path" 20908 fi 20909 20910 20911 # Now try to locate executable using which 20912 new_path=`$WHICH "$new_path" 2> /dev/null` 20913 20914 if test "x$new_path" = x; then 20915 # Oops. Which didn't find the executable. 20916 # The splitting of arguments from the executable at a space might have been incorrect, 20917 # since paths with space are more likely in Windows. Give it another try with the whole 20918 # argument. 20919 path="$complete" 20920 arguments="EOL" 20921 new_path="$path" 20922 20923 windows_path="$new_path" 20924 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 20925 unix_path=`$CYGPATH -u "$windows_path"` 20926 new_path="$unix_path" 20927 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 20928 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 20929 new_path="$unix_path" 20930 fi 20931 20932 20933 new_path=`$WHICH "$new_path" 2> /dev/null` 20934 # bat and cmd files are not always considered executable in MSYS causing which 20935 # to not find them 20936 if test "x$new_path" = x \ 20937 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 20938 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 20939 new_path="$path" 20940 20941 windows_path="$new_path" 20942 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 20943 unix_path=`$CYGPATH -u "$windows_path"` 20944 new_path="$unix_path" 20945 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 20946 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 20947 new_path="$unix_path" 20948 fi 20949 20950 fi 20951 20952 if test "x$new_path" = x; then 20953 # It's still not found. Now this is an unrecoverable error. 20954 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of FOUND_MAKE, which resolves as \"$complete\", is not found." >&5 20955 $as_echo "$as_me: The path of FOUND_MAKE, which resolves as \"$complete\", is not found." >&6;} 20956 has_space=`$ECHO "$complete" | $GREP " "` 20957 if test "x$has_space" != x; then 20958 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 20959 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 20960 fi 20961 as_fn_error $? "Cannot locate the the path of FOUND_MAKE" "$LINENO" 5 20962 fi 20963 fi 20964 20965 # Now new_path has a complete unix path to the binary 20966 if test "x`$ECHO $new_path | $GREP ^/bin/`" != x; then 20967 # Keep paths in /bin as-is, but remove trailing .exe if any 20968 new_path="${new_path/%.exe/}" 20969 # Do not save /bin paths to all_fixpath_prefixes! 20970 else 20971 # Not in mixed or Windows style, start by that. 20972 new_path=`cmd //c echo $new_path` 20973 20974 input_path="$new_path" 20975 # Check if we need to convert this using DOS-style short mode. If the path 20976 # contains just simple characters, use it. Otherwise (spaces, weird characters), 20977 # take no chances and rewrite it. 20978 # Note: m4 eats our [], so we need to use [ and ] instead. 20979 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 20980 if test "x$has_forbidden_chars" != x; then 20981 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 20982 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 20983 fi 20984 20985 # Output is in $new_path 20986 20987 windows_path="$new_path" 20988 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 20989 unix_path=`$CYGPATH -u "$windows_path"` 20990 new_path="$unix_path" 20991 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 20992 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 20993 new_path="$unix_path" 20994 fi 20995 20996 # remove trailing .exe if any 20997 new_path="${new_path/%.exe/}" 20998 20999 # Save the first 10 bytes of this path to the storage, so fixpath can work. 21000 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 21001 fi 21002 21003 else 21004 # We're on a unix platform. Hooray! :) 21005 # First separate the path from the arguments. This will split at the first 21006 # space. 21007 complete="$FOUND_MAKE" 21008 path="${complete%% *}" 21009 tmp="$complete EOL" 21010 arguments="${tmp#* }" 21011 21012 # Cannot rely on the command "which" here since it doesn't always work. 21013 is_absolute_path=`$ECHO "$path" | $GREP ^/` 21014 if test -z "$is_absolute_path"; then 21015 # Path to executable is not absolute. Find it. 21016 IFS_save="$IFS" 21017 IFS=: 21018 for p in $PATH; do 21019 if test -f "$p/$path" && test -x "$p/$path"; then 21020 new_path="$p/$path" 21021 break 21022 fi 21023 done 21024 IFS="$IFS_save" 21025 else 21026 # This is an absolute path, we can use it without further modifications. 21027 new_path="$path" 21028 fi 21029 21030 if test "x$new_path" = x; then 21031 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of FOUND_MAKE, which resolves as \"$complete\", is not found." >&5 21032 $as_echo "$as_me: The path of FOUND_MAKE, which resolves as \"$complete\", is not found." >&6;} 21033 has_space=`$ECHO "$complete" | $GREP " "` 21034 if test "x$has_space" != x; then 21035 { $as_echo "$as_me:${as_lineno-$LINENO}: This might be caused by spaces in the path, which is not allowed." >&5 21036 $as_echo "$as_me: This might be caused by spaces in the path, which is not allowed." >&6;} 21037 fi 21038 as_fn_error $? "Cannot locate the the path of FOUND_MAKE" "$LINENO" 5 21039 fi 21040 fi 21041 21042 # Now join together the path and the arguments once again 21043 if test "x$arguments" != xEOL; then 21044 new_complete="$new_path ${arguments% *}" 21045 else 21046 new_complete="$new_path" 21047 fi 21048 21049 if test "x$complete" != "x$new_complete"; then 21050 FOUND_MAKE="$new_complete" 21051 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting FOUND_MAKE to \"$new_complete\"" >&5 21052 $as_echo "$as_me: Rewriting FOUND_MAKE to \"$new_complete\"" >&6;} 21053 fi 21054 fi 21055 21056 fi 21057 fi 21058 fi 21059 fi 21060 21061 if test "x$FOUND_MAKE" = x; then 21062 as_fn_error $? "The specified make (by MAKE=$MAKE) is not GNU make $MAKE_REQUIRED_VERSION or newer." "$LINENO" 5 21063 fi 21064 21065 fi 21066 21067 21068 MAKE=$FOUND_MAKE 21069 21070 { $as_echo "$as_me:${as_lineno-$LINENO}: Using GNU make at $FOUND_MAKE (version: $MAKE_VERSION_STRING)" >&5 21071 $as_echo "$as_me: Using GNU make at $FOUND_MAKE (version: $MAKE_VERSION_STRING)" >&6;} 21072 21073 21074 # Check if make supports the output sync option and if so, setup using it. 21075 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if make --output-sync is supported" >&5 21076 $as_echo_n "checking if make --output-sync is supported... " >&6; } 21077 if $MAKE --version -O > /dev/null 2>&1; then 21078 OUTPUT_SYNC_SUPPORTED=true 21079 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 21080 $as_echo "yes" >&6; } 21081 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for output-sync value" >&5 21082 $as_echo_n "checking for output-sync value... " >&6; } 21083 21084 # Check whether --with-output-sync was given. 21085 if test "${with_output_sync+set}" = set; then : 21086 withval=$with_output_sync; OUTPUT_SYNC=$with_output_sync 21087 fi 21088 21089 if test "x$OUTPUT_SYNC" = "x"; then 21090 OUTPUT_SYNC=none 21091 fi 21092 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $OUTPUT_SYNC" >&5 21093 $as_echo "$OUTPUT_SYNC" >&6; } 21094 if ! $MAKE --version -O$OUTPUT_SYNC > /dev/null 2>&1; then 21095 as_fn_error $? "Make did not the support the value $OUTPUT_SYNC as output sync type." "$LINENO" 5 21096 fi 21097 else 21098 OUTPUT_SYNC_SUPPORTED=false 21099 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 21100 $as_echo "no" >&6; } 21101 fi 21102 21103 21104 21105 21106 21107 21108 # Test if find supports -delete 21109 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if find supports -delete" >&5 21110 $as_echo_n "checking if find supports -delete... " >&6; } 21111 FIND_DELETE="-delete" 21112 21113 DELETEDIR=`$MKTEMP -d tmp.XXXXXXXXXX` || (echo Could not create temporary directory!; exit $?) 21114 21115 echo Hejsan > $DELETEDIR/TestIfFindSupportsDelete 21116 21117 TEST_DELETE=`$FIND "$DELETEDIR" -name TestIfFindSupportsDelete $FIND_DELETE 2>&1` 21118 if test -f $DELETEDIR/TestIfFindSupportsDelete; then 21119 # No, it does not. 21120 $RM $DELETEDIR/TestIfFindSupportsDelete 21121 if test "x$OPENJDK_TARGET_OS" = "xaix"; then 21122 # AIX 'find' is buggy if called with '-exec {} \+' and an empty file list 21123 FIND_DELETE="-print | $XARGS $RM" 21124 else 21125 FIND_DELETE="-exec $RM \{\} \+" 21126 fi 21127 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 21128 $as_echo "no" >&6; } 21129 else 21130 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 21131 $as_echo "yes" >&6; } 21132 fi 21133 $RMDIR $DELETEDIR 21134 21135 21136 21137 # Test which kind of tar was found 21138 if test "x$($TAR --version | $GREP "GNU tar")" != "x"; then 21139 TAR_TYPE="gnu" 21140 elif test "x$($TAR -v | $GREP "bsdtar")" != "x"; then 21141 TAR_TYPE="bsd" 21142 elif test "x$OPENJDK_BUILD_OS" = "xsolaris"; then 21143 TAR_TYPE="solaris" 21144 fi 21145 { $as_echo "$as_me:${as_lineno-$LINENO}: checking what type of tar was found" >&5 21146 $as_echo_n "checking what type of tar was found... " >&6; } 21147 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $TAR_TYPE" >&5 21148 $as_echo "$TAR_TYPE" >&6; } 21149 21150 TAR_CREATE_FILE_PARAM="" 21151 21152 if test "x$TAR_TYPE" = "xgnu"; then 21153 TAR_INCLUDE_PARAM="T" 21154 TAR_SUPPORTS_TRANSFORM="true" 21155 if test "x$OPENJDK_TARGET_OS" = "xsolaris"; then 21156 # When using gnu tar for Solaris targets, need to use compatibility mode 21157 TAR_CREATE_EXTRA_PARAM="--format=ustar" 21158 fi 21159 else 21160 TAR_INCLUDE_PARAM="I" 21161 TAR_SUPPORTS_TRANSFORM="false" 21162 fi 21163 21164 21165 21166 21167 21168 21169 # These tools might not be installed by default, 21170 # need hint on how to install them. 21171 21172 21173 21174 # Publish this variable in the help. 21175 21176 21177 if [ -z "${UNZIP+x}" ]; then 21178 # The variable is not set by user, try to locate tool using the code snippet 21179 for ac_prog in unzip 21180 do 21181 # Extract the first word of "$ac_prog", so it can be a program name with args. 21182 set dummy $ac_prog; ac_word=$2 21183 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 21184 $as_echo_n "checking for $ac_word... " >&6; } 21185 if ${ac_cv_path_UNZIP+:} false; then : 21186 $as_echo_n "(cached) " >&6 21187 else 21188 case $UNZIP in 21189 [\\/]* | ?:[\\/]*) 21190 ac_cv_path_UNZIP="$UNZIP" # Let the user override the test with a path. 21191 ;; 21192 *) 21193 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 21194 for as_dir in $PATH 21195 do 21196 IFS=$as_save_IFS 21197 test -z "$as_dir" && as_dir=. 21198 for ac_exec_ext in '' $ac_executable_extensions; do 21199 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 21200 ac_cv_path_UNZIP="$as_dir/$ac_word$ac_exec_ext" 21201 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 21202 break 2 21203 fi 21204 done 21205 done 21206 IFS=$as_save_IFS 21207 21208 ;; 21209 esac 21210 fi 21211 UNZIP=$ac_cv_path_UNZIP 21212 if test -n "$UNZIP"; then 21213 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $UNZIP" >&5 21214 $as_echo "$UNZIP" >&6; } 21215 else 21216 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 21217 $as_echo "no" >&6; } 21218 fi 21219 21220 21221 test -n "$UNZIP" && break 21222 done 21223 21224 else 21225 # The variable is set, but is it from the command line or the environment? 21226 21227 # Try to remove the string !UNZIP! from our list. 21228 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!UNZIP!/} 21229 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 21230 # If it failed, the variable was not from the command line. Ignore it, 21231 # but warn the user (except for BASH, which is always set by the calling BASH). 21232 if test "xUNZIP" != xBASH; then 21233 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of UNZIP from the environment. Use command line variables instead." >&5 21234 $as_echo "$as_me: WARNING: Ignoring value of UNZIP from the environment. Use command line variables instead." >&2;} 21235 fi 21236 # Try to locate tool using the code snippet 21237 for ac_prog in unzip 21238 do 21239 # Extract the first word of "$ac_prog", so it can be a program name with args. 21240 set dummy $ac_prog; ac_word=$2 21241 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 21242 $as_echo_n "checking for $ac_word... " >&6; } 21243 if ${ac_cv_path_UNZIP+:} false; then : 21244 $as_echo_n "(cached) " >&6 21245 else 21246 case $UNZIP in 21247 [\\/]* | ?:[\\/]*) 21248 ac_cv_path_UNZIP="$UNZIP" # Let the user override the test with a path. 21249 ;; 21250 *) 21251 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 21252 for as_dir in $PATH 21253 do 21254 IFS=$as_save_IFS 21255 test -z "$as_dir" && as_dir=. 21256 for ac_exec_ext in '' $ac_executable_extensions; do 21257 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 21258 ac_cv_path_UNZIP="$as_dir/$ac_word$ac_exec_ext" 21259 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 21260 break 2 21261 fi 21262 done 21263 done 21264 IFS=$as_save_IFS 21265 21266 ;; 21267 esac 21268 fi 21269 UNZIP=$ac_cv_path_UNZIP 21270 if test -n "$UNZIP"; then 21271 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $UNZIP" >&5 21272 $as_echo "$UNZIP" >&6; } 21273 else 21274 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 21275 $as_echo "no" >&6; } 21276 fi 21277 21278 21279 test -n "$UNZIP" && break 21280 done 21281 21282 else 21283 # If it succeeded, then it was overridden by the user. We will use it 21284 # for the tool. 21285 21286 # First remove it from the list of overridden variables, so we can test 21287 # for unknown variables in the end. 21288 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 21289 21290 # Check if we try to supply an empty value 21291 if test "x$UNZIP" = x; then 21292 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool UNZIP= (no value)" >&5 21293 $as_echo "$as_me: Setting user supplied tool UNZIP= (no value)" >&6;} 21294 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for UNZIP" >&5 21295 $as_echo_n "checking for UNZIP... " >&6; } 21296 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 21297 $as_echo "disabled" >&6; } 21298 else 21299 # Check if the provided tool contains a complete path. 21300 tool_specified="$UNZIP" 21301 tool_basename="${tool_specified##*/}" 21302 if test "x$tool_basename" = "x$tool_specified"; then 21303 # A command without a complete path is provided, search $PATH. 21304 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool UNZIP=$tool_basename" >&5 21305 $as_echo "$as_me: Will search for user supplied tool UNZIP=$tool_basename" >&6;} 21306 # Extract the first word of "$tool_basename", so it can be a program name with args. 21307 set dummy $tool_basename; ac_word=$2 21308 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 21309 $as_echo_n "checking for $ac_word... " >&6; } 21310 if ${ac_cv_path_UNZIP+:} false; then : 21311 $as_echo_n "(cached) " >&6 21312 else 21313 case $UNZIP in 21314 [\\/]* | ?:[\\/]*) 21315 ac_cv_path_UNZIP="$UNZIP" # Let the user override the test with a path. 21316 ;; 21317 *) 21318 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 21319 for as_dir in $PATH 21320 do 21321 IFS=$as_save_IFS 21322 test -z "$as_dir" && as_dir=. 21323 for ac_exec_ext in '' $ac_executable_extensions; do 21324 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 21325 ac_cv_path_UNZIP="$as_dir/$ac_word$ac_exec_ext" 21326 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 21327 break 2 21328 fi 21329 done 21330 done 21331 IFS=$as_save_IFS 21332 21333 ;; 21334 esac 21335 fi 21336 UNZIP=$ac_cv_path_UNZIP 21337 if test -n "$UNZIP"; then 21338 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $UNZIP" >&5 21339 $as_echo "$UNZIP" >&6; } 21340 else 21341 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 21342 $as_echo "no" >&6; } 21343 fi 21344 21345 21346 if test "x$UNZIP" = x; then 21347 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 21348 fi 21349 else 21350 # Otherwise we believe it is a complete path. Use it as it is. 21351 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool UNZIP=$tool_specified" >&5 21352 $as_echo "$as_me: Will use user supplied tool UNZIP=$tool_specified" >&6;} 21353 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for UNZIP" >&5 21354 $as_echo_n "checking for UNZIP... " >&6; } 21355 if test ! -x "$tool_specified"; then 21356 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 21357 $as_echo "not found" >&6; } 21358 as_fn_error $? "User supplied tool UNZIP=$tool_specified does not exist or is not executable" "$LINENO" 5 21359 fi 21360 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 21361 $as_echo "$tool_specified" >&6; } 21362 fi 21363 fi 21364 fi 21365 21366 fi 21367 21368 21369 21370 if test "x$UNZIP" = x; then 21371 as_fn_error $? "Could not find required tool for UNZIP" "$LINENO" 5 21372 fi 21373 21374 21375 21376 21377 21378 # Publish this variable in the help. 21379 21380 21381 if [ -z "${ZIP+x}" ]; then 21382 # The variable is not set by user, try to locate tool using the code snippet 21383 for ac_prog in zip 21384 do 21385 # Extract the first word of "$ac_prog", so it can be a program name with args. 21386 set dummy $ac_prog; ac_word=$2 21387 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 21388 $as_echo_n "checking for $ac_word... " >&6; } 21389 if ${ac_cv_path_ZIP+:} false; then : 21390 $as_echo_n "(cached) " >&6 21391 else 21392 case $ZIP in 21393 [\\/]* | ?:[\\/]*) 21394 ac_cv_path_ZIP="$ZIP" # Let the user override the test with a path. 21395 ;; 21396 *) 21397 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 21398 for as_dir in $PATH 21399 do 21400 IFS=$as_save_IFS 21401 test -z "$as_dir" && as_dir=. 21402 for ac_exec_ext in '' $ac_executable_extensions; do 21403 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 21404 ac_cv_path_ZIP="$as_dir/$ac_word$ac_exec_ext" 21405 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 21406 break 2 21407 fi 21408 done 21409 done 21410 IFS=$as_save_IFS 21411 21412 ;; 21413 esac 21414 fi 21415 ZIP=$ac_cv_path_ZIP 21416 if test -n "$ZIP"; then 21417 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ZIP" >&5 21418 $as_echo "$ZIP" >&6; } 21419 else 21420 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 21421 $as_echo "no" >&6; } 21422 fi 21423 21424 21425 test -n "$ZIP" && break 21426 done 21427 21428 else 21429 # The variable is set, but is it from the command line or the environment? 21430 21431 # Try to remove the string !ZIP! from our list. 21432 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!ZIP!/} 21433 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 21434 # If it failed, the variable was not from the command line. Ignore it, 21435 # but warn the user (except for BASH, which is always set by the calling BASH). 21436 if test "xZIP" != xBASH; then 21437 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of ZIP from the environment. Use command line variables instead." >&5 21438 $as_echo "$as_me: WARNING: Ignoring value of ZIP from the environment. Use command line variables instead." >&2;} 21439 fi 21440 # Try to locate tool using the code snippet 21441 for ac_prog in zip 21442 do 21443 # Extract the first word of "$ac_prog", so it can be a program name with args. 21444 set dummy $ac_prog; ac_word=$2 21445 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 21446 $as_echo_n "checking for $ac_word... " >&6; } 21447 if ${ac_cv_path_ZIP+:} false; then : 21448 $as_echo_n "(cached) " >&6 21449 else 21450 case $ZIP in 21451 [\\/]* | ?:[\\/]*) 21452 ac_cv_path_ZIP="$ZIP" # Let the user override the test with a path. 21453 ;; 21454 *) 21455 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 21456 for as_dir in $PATH 21457 do 21458 IFS=$as_save_IFS 21459 test -z "$as_dir" && as_dir=. 21460 for ac_exec_ext in '' $ac_executable_extensions; do 21461 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 21462 ac_cv_path_ZIP="$as_dir/$ac_word$ac_exec_ext" 21463 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 21464 break 2 21465 fi 21466 done 21467 done 21468 IFS=$as_save_IFS 21469 21470 ;; 21471 esac 21472 fi 21473 ZIP=$ac_cv_path_ZIP 21474 if test -n "$ZIP"; then 21475 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ZIP" >&5 21476 $as_echo "$ZIP" >&6; } 21477 else 21478 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 21479 $as_echo "no" >&6; } 21480 fi 21481 21482 21483 test -n "$ZIP" && break 21484 done 21485 21486 else 21487 # If it succeeded, then it was overridden by the user. We will use it 21488 # for the tool. 21489 21490 # First remove it from the list of overridden variables, so we can test 21491 # for unknown variables in the end. 21492 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 21493 21494 # Check if we try to supply an empty value 21495 if test "x$ZIP" = x; then 21496 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool ZIP= (no value)" >&5 21497 $as_echo "$as_me: Setting user supplied tool ZIP= (no value)" >&6;} 21498 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ZIP" >&5 21499 $as_echo_n "checking for ZIP... " >&6; } 21500 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 21501 $as_echo "disabled" >&6; } 21502 else 21503 # Check if the provided tool contains a complete path. 21504 tool_specified="$ZIP" 21505 tool_basename="${tool_specified##*/}" 21506 if test "x$tool_basename" = "x$tool_specified"; then 21507 # A command without a complete path is provided, search $PATH. 21508 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool ZIP=$tool_basename" >&5 21509 $as_echo "$as_me: Will search for user supplied tool ZIP=$tool_basename" >&6;} 21510 # Extract the first word of "$tool_basename", so it can be a program name with args. 21511 set dummy $tool_basename; ac_word=$2 21512 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 21513 $as_echo_n "checking for $ac_word... " >&6; } 21514 if ${ac_cv_path_ZIP+:} false; then : 21515 $as_echo_n "(cached) " >&6 21516 else 21517 case $ZIP in 21518 [\\/]* | ?:[\\/]*) 21519 ac_cv_path_ZIP="$ZIP" # Let the user override the test with a path. 21520 ;; 21521 *) 21522 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 21523 for as_dir in $PATH 21524 do 21525 IFS=$as_save_IFS 21526 test -z "$as_dir" && as_dir=. 21527 for ac_exec_ext in '' $ac_executable_extensions; do 21528 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 21529 ac_cv_path_ZIP="$as_dir/$ac_word$ac_exec_ext" 21530 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 21531 break 2 21532 fi 21533 done 21534 done 21535 IFS=$as_save_IFS 21536 21537 ;; 21538 esac 21539 fi 21540 ZIP=$ac_cv_path_ZIP 21541 if test -n "$ZIP"; then 21542 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ZIP" >&5 21543 $as_echo "$ZIP" >&6; } 21544 else 21545 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 21546 $as_echo "no" >&6; } 21547 fi 21548 21549 21550 if test "x$ZIP" = x; then 21551 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 21552 fi 21553 else 21554 # Otherwise we believe it is a complete path. Use it as it is. 21555 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool ZIP=$tool_specified" >&5 21556 $as_echo "$as_me: Will use user supplied tool ZIP=$tool_specified" >&6;} 21557 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ZIP" >&5 21558 $as_echo_n "checking for ZIP... " >&6; } 21559 if test ! -x "$tool_specified"; then 21560 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 21561 $as_echo "not found" >&6; } 21562 as_fn_error $? "User supplied tool ZIP=$tool_specified does not exist or is not executable" "$LINENO" 5 21563 fi 21564 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 21565 $as_echo "$tool_specified" >&6; } 21566 fi 21567 fi 21568 fi 21569 21570 fi 21571 21572 21573 21574 if test "x$ZIP" = x; then 21575 as_fn_error $? "Could not find required tool for ZIP" "$LINENO" 5 21576 fi 21577 21578 21579 21580 # Non-required basic tools 21581 21582 21583 21584 # Publish this variable in the help. 21585 21586 21587 if [ -z "${LDD+x}" ]; then 21588 # The variable is not set by user, try to locate tool using the code snippet 21589 for ac_prog in ldd 21590 do 21591 # Extract the first word of "$ac_prog", so it can be a program name with args. 21592 set dummy $ac_prog; ac_word=$2 21593 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 21594 $as_echo_n "checking for $ac_word... " >&6; } 21595 if ${ac_cv_path_LDD+:} false; then : 21596 $as_echo_n "(cached) " >&6 21597 else 21598 case $LDD in 21599 [\\/]* | ?:[\\/]*) 21600 ac_cv_path_LDD="$LDD" # Let the user override the test with a path. 21601 ;; 21602 *) 21603 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 21604 for as_dir in $PATH 21605 do 21606 IFS=$as_save_IFS 21607 test -z "$as_dir" && as_dir=. 21608 for ac_exec_ext in '' $ac_executable_extensions; do 21609 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 21610 ac_cv_path_LDD="$as_dir/$ac_word$ac_exec_ext" 21611 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 21612 break 2 21613 fi 21614 done 21615 done 21616 IFS=$as_save_IFS 21617 21618 ;; 21619 esac 21620 fi 21621 LDD=$ac_cv_path_LDD 21622 if test -n "$LDD"; then 21623 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $LDD" >&5 21624 $as_echo "$LDD" >&6; } 21625 else 21626 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 21627 $as_echo "no" >&6; } 21628 fi 21629 21630 21631 test -n "$LDD" && break 21632 done 21633 21634 else 21635 # The variable is set, but is it from the command line or the environment? 21636 21637 # Try to remove the string !LDD! from our list. 21638 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!LDD!/} 21639 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 21640 # If it failed, the variable was not from the command line. Ignore it, 21641 # but warn the user (except for BASH, which is always set by the calling BASH). 21642 if test "xLDD" != xBASH; then 21643 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of LDD from the environment. Use command line variables instead." >&5 21644 $as_echo "$as_me: WARNING: Ignoring value of LDD from the environment. Use command line variables instead." >&2;} 21645 fi 21646 # Try to locate tool using the code snippet 21647 for ac_prog in ldd 21648 do 21649 # Extract the first word of "$ac_prog", so it can be a program name with args. 21650 set dummy $ac_prog; ac_word=$2 21651 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 21652 $as_echo_n "checking for $ac_word... " >&6; } 21653 if ${ac_cv_path_LDD+:} false; then : 21654 $as_echo_n "(cached) " >&6 21655 else 21656 case $LDD in 21657 [\\/]* | ?:[\\/]*) 21658 ac_cv_path_LDD="$LDD" # Let the user override the test with a path. 21659 ;; 21660 *) 21661 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 21662 for as_dir in $PATH 21663 do 21664 IFS=$as_save_IFS 21665 test -z "$as_dir" && as_dir=. 21666 for ac_exec_ext in '' $ac_executable_extensions; do 21667 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 21668 ac_cv_path_LDD="$as_dir/$ac_word$ac_exec_ext" 21669 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 21670 break 2 21671 fi 21672 done 21673 done 21674 IFS=$as_save_IFS 21675 21676 ;; 21677 esac 21678 fi 21679 LDD=$ac_cv_path_LDD 21680 if test -n "$LDD"; then 21681 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $LDD" >&5 21682 $as_echo "$LDD" >&6; } 21683 else 21684 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 21685 $as_echo "no" >&6; } 21686 fi 21687 21688 21689 test -n "$LDD" && break 21690 done 21691 21692 else 21693 # If it succeeded, then it was overridden by the user. We will use it 21694 # for the tool. 21695 21696 # First remove it from the list of overridden variables, so we can test 21697 # for unknown variables in the end. 21698 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 21699 21700 # Check if we try to supply an empty value 21701 if test "x$LDD" = x; then 21702 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool LDD= (no value)" >&5 21703 $as_echo "$as_me: Setting user supplied tool LDD= (no value)" >&6;} 21704 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for LDD" >&5 21705 $as_echo_n "checking for LDD... " >&6; } 21706 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 21707 $as_echo "disabled" >&6; } 21708 else 21709 # Check if the provided tool contains a complete path. 21710 tool_specified="$LDD" 21711 tool_basename="${tool_specified##*/}" 21712 if test "x$tool_basename" = "x$tool_specified"; then 21713 # A command without a complete path is provided, search $PATH. 21714 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool LDD=$tool_basename" >&5 21715 $as_echo "$as_me: Will search for user supplied tool LDD=$tool_basename" >&6;} 21716 # Extract the first word of "$tool_basename", so it can be a program name with args. 21717 set dummy $tool_basename; ac_word=$2 21718 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 21719 $as_echo_n "checking for $ac_word... " >&6; } 21720 if ${ac_cv_path_LDD+:} false; then : 21721 $as_echo_n "(cached) " >&6 21722 else 21723 case $LDD in 21724 [\\/]* | ?:[\\/]*) 21725 ac_cv_path_LDD="$LDD" # Let the user override the test with a path. 21726 ;; 21727 *) 21728 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 21729 for as_dir in $PATH 21730 do 21731 IFS=$as_save_IFS 21732 test -z "$as_dir" && as_dir=. 21733 for ac_exec_ext in '' $ac_executable_extensions; do 21734 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 21735 ac_cv_path_LDD="$as_dir/$ac_word$ac_exec_ext" 21736 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 21737 break 2 21738 fi 21739 done 21740 done 21741 IFS=$as_save_IFS 21742 21743 ;; 21744 esac 21745 fi 21746 LDD=$ac_cv_path_LDD 21747 if test -n "$LDD"; then 21748 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $LDD" >&5 21749 $as_echo "$LDD" >&6; } 21750 else 21751 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 21752 $as_echo "no" >&6; } 21753 fi 21754 21755 21756 if test "x$LDD" = x; then 21757 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 21758 fi 21759 else 21760 # Otherwise we believe it is a complete path. Use it as it is. 21761 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool LDD=$tool_specified" >&5 21762 $as_echo "$as_me: Will use user supplied tool LDD=$tool_specified" >&6;} 21763 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for LDD" >&5 21764 $as_echo_n "checking for LDD... " >&6; } 21765 if test ! -x "$tool_specified"; then 21766 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 21767 $as_echo "not found" >&6; } 21768 as_fn_error $? "User supplied tool LDD=$tool_specified does not exist or is not executable" "$LINENO" 5 21769 fi 21770 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 21771 $as_echo "$tool_specified" >&6; } 21772 fi 21773 fi 21774 fi 21775 21776 fi 21777 21778 21779 if test "x$LDD" = "x"; then 21780 # List shared lib dependencies is used for 21781 # debug output and checking for forbidden dependencies. 21782 # We can build without it. 21783 LDD="true" 21784 fi 21785 21786 21787 # Publish this variable in the help. 21788 21789 21790 if [ -z "${OTOOL+x}" ]; then 21791 # The variable is not set by user, try to locate tool using the code snippet 21792 for ac_prog in otool 21793 do 21794 # Extract the first word of "$ac_prog", so it can be a program name with args. 21795 set dummy $ac_prog; ac_word=$2 21796 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 21797 $as_echo_n "checking for $ac_word... " >&6; } 21798 if ${ac_cv_path_OTOOL+:} false; then : 21799 $as_echo_n "(cached) " >&6 21800 else 21801 case $OTOOL in 21802 [\\/]* | ?:[\\/]*) 21803 ac_cv_path_OTOOL="$OTOOL" # Let the user override the test with a path. 21804 ;; 21805 *) 21806 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 21807 for as_dir in $PATH 21808 do 21809 IFS=$as_save_IFS 21810 test -z "$as_dir" && as_dir=. 21811 for ac_exec_ext in '' $ac_executable_extensions; do 21812 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 21813 ac_cv_path_OTOOL="$as_dir/$ac_word$ac_exec_ext" 21814 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 21815 break 2 21816 fi 21817 done 21818 done 21819 IFS=$as_save_IFS 21820 21821 ;; 21822 esac 21823 fi 21824 OTOOL=$ac_cv_path_OTOOL 21825 if test -n "$OTOOL"; then 21826 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $OTOOL" >&5 21827 $as_echo "$OTOOL" >&6; } 21828 else 21829 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 21830 $as_echo "no" >&6; } 21831 fi 21832 21833 21834 test -n "$OTOOL" && break 21835 done 21836 21837 else 21838 # The variable is set, but is it from the command line or the environment? 21839 21840 # Try to remove the string !OTOOL! from our list. 21841 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!OTOOL!/} 21842 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 21843 # If it failed, the variable was not from the command line. Ignore it, 21844 # but warn the user (except for BASH, which is always set by the calling BASH). 21845 if test "xOTOOL" != xBASH; then 21846 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of OTOOL from the environment. Use command line variables instead." >&5 21847 $as_echo "$as_me: WARNING: Ignoring value of OTOOL from the environment. Use command line variables instead." >&2;} 21848 fi 21849 # Try to locate tool using the code snippet 21850 for ac_prog in otool 21851 do 21852 # Extract the first word of "$ac_prog", so it can be a program name with args. 21853 set dummy $ac_prog; ac_word=$2 21854 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 21855 $as_echo_n "checking for $ac_word... " >&6; } 21856 if ${ac_cv_path_OTOOL+:} false; then : 21857 $as_echo_n "(cached) " >&6 21858 else 21859 case $OTOOL in 21860 [\\/]* | ?:[\\/]*) 21861 ac_cv_path_OTOOL="$OTOOL" # Let the user override the test with a path. 21862 ;; 21863 *) 21864 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 21865 for as_dir in $PATH 21866 do 21867 IFS=$as_save_IFS 21868 test -z "$as_dir" && as_dir=. 21869 for ac_exec_ext in '' $ac_executable_extensions; do 21870 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 21871 ac_cv_path_OTOOL="$as_dir/$ac_word$ac_exec_ext" 21872 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 21873 break 2 21874 fi 21875 done 21876 done 21877 IFS=$as_save_IFS 21878 21879 ;; 21880 esac 21881 fi 21882 OTOOL=$ac_cv_path_OTOOL 21883 if test -n "$OTOOL"; then 21884 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $OTOOL" >&5 21885 $as_echo "$OTOOL" >&6; } 21886 else 21887 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 21888 $as_echo "no" >&6; } 21889 fi 21890 21891 21892 test -n "$OTOOL" && break 21893 done 21894 21895 else 21896 # If it succeeded, then it was overridden by the user. We will use it 21897 # for the tool. 21898 21899 # First remove it from the list of overridden variables, so we can test 21900 # for unknown variables in the end. 21901 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 21902 21903 # Check if we try to supply an empty value 21904 if test "x$OTOOL" = x; then 21905 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool OTOOL= (no value)" >&5 21906 $as_echo "$as_me: Setting user supplied tool OTOOL= (no value)" >&6;} 21907 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for OTOOL" >&5 21908 $as_echo_n "checking for OTOOL... " >&6; } 21909 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 21910 $as_echo "disabled" >&6; } 21911 else 21912 # Check if the provided tool contains a complete path. 21913 tool_specified="$OTOOL" 21914 tool_basename="${tool_specified##*/}" 21915 if test "x$tool_basename" = "x$tool_specified"; then 21916 # A command without a complete path is provided, search $PATH. 21917 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool OTOOL=$tool_basename" >&5 21918 $as_echo "$as_me: Will search for user supplied tool OTOOL=$tool_basename" >&6;} 21919 # Extract the first word of "$tool_basename", so it can be a program name with args. 21920 set dummy $tool_basename; ac_word=$2 21921 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 21922 $as_echo_n "checking for $ac_word... " >&6; } 21923 if ${ac_cv_path_OTOOL+:} false; then : 21924 $as_echo_n "(cached) " >&6 21925 else 21926 case $OTOOL in 21927 [\\/]* | ?:[\\/]*) 21928 ac_cv_path_OTOOL="$OTOOL" # Let the user override the test with a path. 21929 ;; 21930 *) 21931 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 21932 for as_dir in $PATH 21933 do 21934 IFS=$as_save_IFS 21935 test -z "$as_dir" && as_dir=. 21936 for ac_exec_ext in '' $ac_executable_extensions; do 21937 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 21938 ac_cv_path_OTOOL="$as_dir/$ac_word$ac_exec_ext" 21939 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 21940 break 2 21941 fi 21942 done 21943 done 21944 IFS=$as_save_IFS 21945 21946 ;; 21947 esac 21948 fi 21949 OTOOL=$ac_cv_path_OTOOL 21950 if test -n "$OTOOL"; then 21951 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $OTOOL" >&5 21952 $as_echo "$OTOOL" >&6; } 21953 else 21954 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 21955 $as_echo "no" >&6; } 21956 fi 21957 21958 21959 if test "x$OTOOL" = x; then 21960 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 21961 fi 21962 else 21963 # Otherwise we believe it is a complete path. Use it as it is. 21964 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool OTOOL=$tool_specified" >&5 21965 $as_echo "$as_me: Will use user supplied tool OTOOL=$tool_specified" >&6;} 21966 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for OTOOL" >&5 21967 $as_echo_n "checking for OTOOL... " >&6; } 21968 if test ! -x "$tool_specified"; then 21969 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 21970 $as_echo "not found" >&6; } 21971 as_fn_error $? "User supplied tool OTOOL=$tool_specified does not exist or is not executable" "$LINENO" 5 21972 fi 21973 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 21974 $as_echo "$tool_specified" >&6; } 21975 fi 21976 fi 21977 fi 21978 21979 fi 21980 21981 21982 if test "x$OTOOL" = "x"; then 21983 OTOOL="true" 21984 fi 21985 21986 21987 # Publish this variable in the help. 21988 21989 21990 if [ -z "${READELF+x}" ]; then 21991 # The variable is not set by user, try to locate tool using the code snippet 21992 for ac_prog in greadelf readelf 21993 do 21994 # Extract the first word of "$ac_prog", so it can be a program name with args. 21995 set dummy $ac_prog; ac_word=$2 21996 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 21997 $as_echo_n "checking for $ac_word... " >&6; } 21998 if ${ac_cv_path_READELF+:} false; then : 21999 $as_echo_n "(cached) " >&6 22000 else 22001 case $READELF in 22002 [\\/]* | ?:[\\/]*) 22003 ac_cv_path_READELF="$READELF" # Let the user override the test with a path. 22004 ;; 22005 *) 22006 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 22007 for as_dir in $PATH 22008 do 22009 IFS=$as_save_IFS 22010 test -z "$as_dir" && as_dir=. 22011 for ac_exec_ext in '' $ac_executable_extensions; do 22012 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 22013 ac_cv_path_READELF="$as_dir/$ac_word$ac_exec_ext" 22014 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 22015 break 2 22016 fi 22017 done 22018 done 22019 IFS=$as_save_IFS 22020 22021 ;; 22022 esac 22023 fi 22024 READELF=$ac_cv_path_READELF 22025 if test -n "$READELF"; then 22026 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $READELF" >&5 22027 $as_echo "$READELF" >&6; } 22028 else 22029 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 22030 $as_echo "no" >&6; } 22031 fi 22032 22033 22034 test -n "$READELF" && break 22035 done 22036 22037 else 22038 # The variable is set, but is it from the command line or the environment? 22039 22040 # Try to remove the string !READELF! from our list. 22041 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!READELF!/} 22042 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 22043 # If it failed, the variable was not from the command line. Ignore it, 22044 # but warn the user (except for BASH, which is always set by the calling BASH). 22045 if test "xREADELF" != xBASH; then 22046 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of READELF from the environment. Use command line variables instead." >&5 22047 $as_echo "$as_me: WARNING: Ignoring value of READELF from the environment. Use command line variables instead." >&2;} 22048 fi 22049 # Try to locate tool using the code snippet 22050 for ac_prog in greadelf readelf 22051 do 22052 # Extract the first word of "$ac_prog", so it can be a program name with args. 22053 set dummy $ac_prog; ac_word=$2 22054 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 22055 $as_echo_n "checking for $ac_word... " >&6; } 22056 if ${ac_cv_path_READELF+:} false; then : 22057 $as_echo_n "(cached) " >&6 22058 else 22059 case $READELF in 22060 [\\/]* | ?:[\\/]*) 22061 ac_cv_path_READELF="$READELF" # Let the user override the test with a path. 22062 ;; 22063 *) 22064 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 22065 for as_dir in $PATH 22066 do 22067 IFS=$as_save_IFS 22068 test -z "$as_dir" && as_dir=. 22069 for ac_exec_ext in '' $ac_executable_extensions; do 22070 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 22071 ac_cv_path_READELF="$as_dir/$ac_word$ac_exec_ext" 22072 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 22073 break 2 22074 fi 22075 done 22076 done 22077 IFS=$as_save_IFS 22078 22079 ;; 22080 esac 22081 fi 22082 READELF=$ac_cv_path_READELF 22083 if test -n "$READELF"; then 22084 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $READELF" >&5 22085 $as_echo "$READELF" >&6; } 22086 else 22087 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 22088 $as_echo "no" >&6; } 22089 fi 22090 22091 22092 test -n "$READELF" && break 22093 done 22094 22095 else 22096 # If it succeeded, then it was overridden by the user. We will use it 22097 # for the tool. 22098 22099 # First remove it from the list of overridden variables, so we can test 22100 # for unknown variables in the end. 22101 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 22102 22103 # Check if we try to supply an empty value 22104 if test "x$READELF" = x; then 22105 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool READELF= (no value)" >&5 22106 $as_echo "$as_me: Setting user supplied tool READELF= (no value)" >&6;} 22107 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for READELF" >&5 22108 $as_echo_n "checking for READELF... " >&6; } 22109 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 22110 $as_echo "disabled" >&6; } 22111 else 22112 # Check if the provided tool contains a complete path. 22113 tool_specified="$READELF" 22114 tool_basename="${tool_specified##*/}" 22115 if test "x$tool_basename" = "x$tool_specified"; then 22116 # A command without a complete path is provided, search $PATH. 22117 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool READELF=$tool_basename" >&5 22118 $as_echo "$as_me: Will search for user supplied tool READELF=$tool_basename" >&6;} 22119 # Extract the first word of "$tool_basename", so it can be a program name with args. 22120 set dummy $tool_basename; ac_word=$2 22121 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 22122 $as_echo_n "checking for $ac_word... " >&6; } 22123 if ${ac_cv_path_READELF+:} false; then : 22124 $as_echo_n "(cached) " >&6 22125 else 22126 case $READELF in 22127 [\\/]* | ?:[\\/]*) 22128 ac_cv_path_READELF="$READELF" # Let the user override the test with a path. 22129 ;; 22130 *) 22131 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 22132 for as_dir in $PATH 22133 do 22134 IFS=$as_save_IFS 22135 test -z "$as_dir" && as_dir=. 22136 for ac_exec_ext in '' $ac_executable_extensions; do 22137 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 22138 ac_cv_path_READELF="$as_dir/$ac_word$ac_exec_ext" 22139 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 22140 break 2 22141 fi 22142 done 22143 done 22144 IFS=$as_save_IFS 22145 22146 ;; 22147 esac 22148 fi 22149 READELF=$ac_cv_path_READELF 22150 if test -n "$READELF"; then 22151 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $READELF" >&5 22152 $as_echo "$READELF" >&6; } 22153 else 22154 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 22155 $as_echo "no" >&6; } 22156 fi 22157 22158 22159 if test "x$READELF" = x; then 22160 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 22161 fi 22162 else 22163 # Otherwise we believe it is a complete path. Use it as it is. 22164 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool READELF=$tool_specified" >&5 22165 $as_echo "$as_me: Will use user supplied tool READELF=$tool_specified" >&6;} 22166 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for READELF" >&5 22167 $as_echo_n "checking for READELF... " >&6; } 22168 if test ! -x "$tool_specified"; then 22169 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 22170 $as_echo "not found" >&6; } 22171 as_fn_error $? "User supplied tool READELF=$tool_specified does not exist or is not executable" "$LINENO" 5 22172 fi 22173 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 22174 $as_echo "$tool_specified" >&6; } 22175 fi 22176 fi 22177 fi 22178 22179 fi 22180 22181 22182 22183 22184 # Publish this variable in the help. 22185 22186 22187 if [ -z "${HG+x}" ]; then 22188 # The variable is not set by user, try to locate tool using the code snippet 22189 for ac_prog in hg 22190 do 22191 # Extract the first word of "$ac_prog", so it can be a program name with args. 22192 set dummy $ac_prog; ac_word=$2 22193 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 22194 $as_echo_n "checking for $ac_word... " >&6; } 22195 if ${ac_cv_path_HG+:} false; then : 22196 $as_echo_n "(cached) " >&6 22197 else 22198 case $HG in 22199 [\\/]* | ?:[\\/]*) 22200 ac_cv_path_HG="$HG" # Let the user override the test with a path. 22201 ;; 22202 *) 22203 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 22204 for as_dir in $PATH 22205 do 22206 IFS=$as_save_IFS 22207 test -z "$as_dir" && as_dir=. 22208 for ac_exec_ext in '' $ac_executable_extensions; do 22209 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 22210 ac_cv_path_HG="$as_dir/$ac_word$ac_exec_ext" 22211 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 22212 break 2 22213 fi 22214 done 22215 done 22216 IFS=$as_save_IFS 22217 22218 ;; 22219 esac 22220 fi 22221 HG=$ac_cv_path_HG 22222 if test -n "$HG"; then 22223 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $HG" >&5 22224 $as_echo "$HG" >&6; } 22225 else 22226 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 22227 $as_echo "no" >&6; } 22228 fi 22229 22230 22231 test -n "$HG" && break 22232 done 22233 22234 else 22235 # The variable is set, but is it from the command line or the environment? 22236 22237 # Try to remove the string !HG! from our list. 22238 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!HG!/} 22239 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 22240 # If it failed, the variable was not from the command line. Ignore it, 22241 # but warn the user (except for BASH, which is always set by the calling BASH). 22242 if test "xHG" != xBASH; then 22243 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of HG from the environment. Use command line variables instead." >&5 22244 $as_echo "$as_me: WARNING: Ignoring value of HG from the environment. Use command line variables instead." >&2;} 22245 fi 22246 # Try to locate tool using the code snippet 22247 for ac_prog in hg 22248 do 22249 # Extract the first word of "$ac_prog", so it can be a program name with args. 22250 set dummy $ac_prog; ac_word=$2 22251 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 22252 $as_echo_n "checking for $ac_word... " >&6; } 22253 if ${ac_cv_path_HG+:} false; then : 22254 $as_echo_n "(cached) " >&6 22255 else 22256 case $HG in 22257 [\\/]* | ?:[\\/]*) 22258 ac_cv_path_HG="$HG" # Let the user override the test with a path. 22259 ;; 22260 *) 22261 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 22262 for as_dir in $PATH 22263 do 22264 IFS=$as_save_IFS 22265 test -z "$as_dir" && as_dir=. 22266 for ac_exec_ext in '' $ac_executable_extensions; do 22267 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 22268 ac_cv_path_HG="$as_dir/$ac_word$ac_exec_ext" 22269 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 22270 break 2 22271 fi 22272 done 22273 done 22274 IFS=$as_save_IFS 22275 22276 ;; 22277 esac 22278 fi 22279 HG=$ac_cv_path_HG 22280 if test -n "$HG"; then 22281 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $HG" >&5 22282 $as_echo "$HG" >&6; } 22283 else 22284 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 22285 $as_echo "no" >&6; } 22286 fi 22287 22288 22289 test -n "$HG" && break 22290 done 22291 22292 else 22293 # If it succeeded, then it was overridden by the user. We will use it 22294 # for the tool. 22295 22296 # First remove it from the list of overridden variables, so we can test 22297 # for unknown variables in the end. 22298 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 22299 22300 # Check if we try to supply an empty value 22301 if test "x$HG" = x; then 22302 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool HG= (no value)" >&5 22303 $as_echo "$as_me: Setting user supplied tool HG= (no value)" >&6;} 22304 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for HG" >&5 22305 $as_echo_n "checking for HG... " >&6; } 22306 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 22307 $as_echo "disabled" >&6; } 22308 else 22309 # Check if the provided tool contains a complete path. 22310 tool_specified="$HG" 22311 tool_basename="${tool_specified##*/}" 22312 if test "x$tool_basename" = "x$tool_specified"; then 22313 # A command without a complete path is provided, search $PATH. 22314 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool HG=$tool_basename" >&5 22315 $as_echo "$as_me: Will search for user supplied tool HG=$tool_basename" >&6;} 22316 # Extract the first word of "$tool_basename", so it can be a program name with args. 22317 set dummy $tool_basename; ac_word=$2 22318 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 22319 $as_echo_n "checking for $ac_word... " >&6; } 22320 if ${ac_cv_path_HG+:} false; then : 22321 $as_echo_n "(cached) " >&6 22322 else 22323 case $HG in 22324 [\\/]* | ?:[\\/]*) 22325 ac_cv_path_HG="$HG" # Let the user override the test with a path. 22326 ;; 22327 *) 22328 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 22329 for as_dir in $PATH 22330 do 22331 IFS=$as_save_IFS 22332 test -z "$as_dir" && as_dir=. 22333 for ac_exec_ext in '' $ac_executable_extensions; do 22334 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 22335 ac_cv_path_HG="$as_dir/$ac_word$ac_exec_ext" 22336 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 22337 break 2 22338 fi 22339 done 22340 done 22341 IFS=$as_save_IFS 22342 22343 ;; 22344 esac 22345 fi 22346 HG=$ac_cv_path_HG 22347 if test -n "$HG"; then 22348 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $HG" >&5 22349 $as_echo "$HG" >&6; } 22350 else 22351 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 22352 $as_echo "no" >&6; } 22353 fi 22354 22355 22356 if test "x$HG" = x; then 22357 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 22358 fi 22359 else 22360 # Otherwise we believe it is a complete path. Use it as it is. 22361 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool HG=$tool_specified" >&5 22362 $as_echo "$as_me: Will use user supplied tool HG=$tool_specified" >&6;} 22363 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for HG" >&5 22364 $as_echo_n "checking for HG... " >&6; } 22365 if test ! -x "$tool_specified"; then 22366 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 22367 $as_echo "not found" >&6; } 22368 as_fn_error $? "User supplied tool HG=$tool_specified does not exist or is not executable" "$LINENO" 5 22369 fi 22370 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 22371 $as_echo "$tool_specified" >&6; } 22372 fi 22373 fi 22374 fi 22375 22376 fi 22377 22378 22379 22380 22381 # Publish this variable in the help. 22382 22383 22384 if [ -z "${STAT+x}" ]; then 22385 # The variable is not set by user, try to locate tool using the code snippet 22386 for ac_prog in stat 22387 do 22388 # Extract the first word of "$ac_prog", so it can be a program name with args. 22389 set dummy $ac_prog; ac_word=$2 22390 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 22391 $as_echo_n "checking for $ac_word... " >&6; } 22392 if ${ac_cv_path_STAT+:} false; then : 22393 $as_echo_n "(cached) " >&6 22394 else 22395 case $STAT in 22396 [\\/]* | ?:[\\/]*) 22397 ac_cv_path_STAT="$STAT" # Let the user override the test with a path. 22398 ;; 22399 *) 22400 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 22401 for as_dir in $PATH 22402 do 22403 IFS=$as_save_IFS 22404 test -z "$as_dir" && as_dir=. 22405 for ac_exec_ext in '' $ac_executable_extensions; do 22406 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 22407 ac_cv_path_STAT="$as_dir/$ac_word$ac_exec_ext" 22408 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 22409 break 2 22410 fi 22411 done 22412 done 22413 IFS=$as_save_IFS 22414 22415 ;; 22416 esac 22417 fi 22418 STAT=$ac_cv_path_STAT 22419 if test -n "$STAT"; then 22420 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $STAT" >&5 22421 $as_echo "$STAT" >&6; } 22422 else 22423 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 22424 $as_echo "no" >&6; } 22425 fi 22426 22427 22428 test -n "$STAT" && break 22429 done 22430 22431 else 22432 # The variable is set, but is it from the command line or the environment? 22433 22434 # Try to remove the string !STAT! from our list. 22435 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!STAT!/} 22436 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 22437 # If it failed, the variable was not from the command line. Ignore it, 22438 # but warn the user (except for BASH, which is always set by the calling BASH). 22439 if test "xSTAT" != xBASH; then 22440 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of STAT from the environment. Use command line variables instead." >&5 22441 $as_echo "$as_me: WARNING: Ignoring value of STAT from the environment. Use command line variables instead." >&2;} 22442 fi 22443 # Try to locate tool using the code snippet 22444 for ac_prog in stat 22445 do 22446 # Extract the first word of "$ac_prog", so it can be a program name with args. 22447 set dummy $ac_prog; ac_word=$2 22448 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 22449 $as_echo_n "checking for $ac_word... " >&6; } 22450 if ${ac_cv_path_STAT+:} false; then : 22451 $as_echo_n "(cached) " >&6 22452 else 22453 case $STAT in 22454 [\\/]* | ?:[\\/]*) 22455 ac_cv_path_STAT="$STAT" # Let the user override the test with a path. 22456 ;; 22457 *) 22458 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 22459 for as_dir in $PATH 22460 do 22461 IFS=$as_save_IFS 22462 test -z "$as_dir" && as_dir=. 22463 for ac_exec_ext in '' $ac_executable_extensions; do 22464 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 22465 ac_cv_path_STAT="$as_dir/$ac_word$ac_exec_ext" 22466 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 22467 break 2 22468 fi 22469 done 22470 done 22471 IFS=$as_save_IFS 22472 22473 ;; 22474 esac 22475 fi 22476 STAT=$ac_cv_path_STAT 22477 if test -n "$STAT"; then 22478 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $STAT" >&5 22479 $as_echo "$STAT" >&6; } 22480 else 22481 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 22482 $as_echo "no" >&6; } 22483 fi 22484 22485 22486 test -n "$STAT" && break 22487 done 22488 22489 else 22490 # If it succeeded, then it was overridden by the user. We will use it 22491 # for the tool. 22492 22493 # First remove it from the list of overridden variables, so we can test 22494 # for unknown variables in the end. 22495 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 22496 22497 # Check if we try to supply an empty value 22498 if test "x$STAT" = x; then 22499 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool STAT= (no value)" >&5 22500 $as_echo "$as_me: Setting user supplied tool STAT= (no value)" >&6;} 22501 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for STAT" >&5 22502 $as_echo_n "checking for STAT... " >&6; } 22503 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 22504 $as_echo "disabled" >&6; } 22505 else 22506 # Check if the provided tool contains a complete path. 22507 tool_specified="$STAT" 22508 tool_basename="${tool_specified##*/}" 22509 if test "x$tool_basename" = "x$tool_specified"; then 22510 # A command without a complete path is provided, search $PATH. 22511 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool STAT=$tool_basename" >&5 22512 $as_echo "$as_me: Will search for user supplied tool STAT=$tool_basename" >&6;} 22513 # Extract the first word of "$tool_basename", so it can be a program name with args. 22514 set dummy $tool_basename; ac_word=$2 22515 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 22516 $as_echo_n "checking for $ac_word... " >&6; } 22517 if ${ac_cv_path_STAT+:} false; then : 22518 $as_echo_n "(cached) " >&6 22519 else 22520 case $STAT in 22521 [\\/]* | ?:[\\/]*) 22522 ac_cv_path_STAT="$STAT" # Let the user override the test with a path. 22523 ;; 22524 *) 22525 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 22526 for as_dir in $PATH 22527 do 22528 IFS=$as_save_IFS 22529 test -z "$as_dir" && as_dir=. 22530 for ac_exec_ext in '' $ac_executable_extensions; do 22531 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 22532 ac_cv_path_STAT="$as_dir/$ac_word$ac_exec_ext" 22533 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 22534 break 2 22535 fi 22536 done 22537 done 22538 IFS=$as_save_IFS 22539 22540 ;; 22541 esac 22542 fi 22543 STAT=$ac_cv_path_STAT 22544 if test -n "$STAT"; then 22545 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $STAT" >&5 22546 $as_echo "$STAT" >&6; } 22547 else 22548 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 22549 $as_echo "no" >&6; } 22550 fi 22551 22552 22553 if test "x$STAT" = x; then 22554 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 22555 fi 22556 else 22557 # Otherwise we believe it is a complete path. Use it as it is. 22558 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool STAT=$tool_specified" >&5 22559 $as_echo "$as_me: Will use user supplied tool STAT=$tool_specified" >&6;} 22560 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for STAT" >&5 22561 $as_echo_n "checking for STAT... " >&6; } 22562 if test ! -x "$tool_specified"; then 22563 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 22564 $as_echo "not found" >&6; } 22565 as_fn_error $? "User supplied tool STAT=$tool_specified does not exist or is not executable" "$LINENO" 5 22566 fi 22567 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 22568 $as_echo "$tool_specified" >&6; } 22569 fi 22570 fi 22571 fi 22572 22573 fi 22574 22575 22576 22577 22578 # Publish this variable in the help. 22579 22580 22581 if [ -z "${TIME+x}" ]; then 22582 # The variable is not set by user, try to locate tool using the code snippet 22583 for ac_prog in time 22584 do 22585 # Extract the first word of "$ac_prog", so it can be a program name with args. 22586 set dummy $ac_prog; ac_word=$2 22587 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 22588 $as_echo_n "checking for $ac_word... " >&6; } 22589 if ${ac_cv_path_TIME+:} false; then : 22590 $as_echo_n "(cached) " >&6 22591 else 22592 case $TIME in 22593 [\\/]* | ?:[\\/]*) 22594 ac_cv_path_TIME="$TIME" # Let the user override the test with a path. 22595 ;; 22596 *) 22597 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 22598 for as_dir in $PATH 22599 do 22600 IFS=$as_save_IFS 22601 test -z "$as_dir" && as_dir=. 22602 for ac_exec_ext in '' $ac_executable_extensions; do 22603 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 22604 ac_cv_path_TIME="$as_dir/$ac_word$ac_exec_ext" 22605 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 22606 break 2 22607 fi 22608 done 22609 done 22610 IFS=$as_save_IFS 22611 22612 ;; 22613 esac 22614 fi 22615 TIME=$ac_cv_path_TIME 22616 if test -n "$TIME"; then 22617 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $TIME" >&5 22618 $as_echo "$TIME" >&6; } 22619 else 22620 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 22621 $as_echo "no" >&6; } 22622 fi 22623 22624 22625 test -n "$TIME" && break 22626 done 22627 22628 else 22629 # The variable is set, but is it from the command line or the environment? 22630 22631 # Try to remove the string !TIME! from our list. 22632 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!TIME!/} 22633 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 22634 # If it failed, the variable was not from the command line. Ignore it, 22635 # but warn the user (except for BASH, which is always set by the calling BASH). 22636 if test "xTIME" != xBASH; then 22637 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of TIME from the environment. Use command line variables instead." >&5 22638 $as_echo "$as_me: WARNING: Ignoring value of TIME from the environment. Use command line variables instead." >&2;} 22639 fi 22640 # Try to locate tool using the code snippet 22641 for ac_prog in time 22642 do 22643 # Extract the first word of "$ac_prog", so it can be a program name with args. 22644 set dummy $ac_prog; ac_word=$2 22645 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 22646 $as_echo_n "checking for $ac_word... " >&6; } 22647 if ${ac_cv_path_TIME+:} false; then : 22648 $as_echo_n "(cached) " >&6 22649 else 22650 case $TIME in 22651 [\\/]* | ?:[\\/]*) 22652 ac_cv_path_TIME="$TIME" # Let the user override the test with a path. 22653 ;; 22654 *) 22655 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 22656 for as_dir in $PATH 22657 do 22658 IFS=$as_save_IFS 22659 test -z "$as_dir" && as_dir=. 22660 for ac_exec_ext in '' $ac_executable_extensions; do 22661 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 22662 ac_cv_path_TIME="$as_dir/$ac_word$ac_exec_ext" 22663 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 22664 break 2 22665 fi 22666 done 22667 done 22668 IFS=$as_save_IFS 22669 22670 ;; 22671 esac 22672 fi 22673 TIME=$ac_cv_path_TIME 22674 if test -n "$TIME"; then 22675 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $TIME" >&5 22676 $as_echo "$TIME" >&6; } 22677 else 22678 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 22679 $as_echo "no" >&6; } 22680 fi 22681 22682 22683 test -n "$TIME" && break 22684 done 22685 22686 else 22687 # If it succeeded, then it was overridden by the user. We will use it 22688 # for the tool. 22689 22690 # First remove it from the list of overridden variables, so we can test 22691 # for unknown variables in the end. 22692 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 22693 22694 # Check if we try to supply an empty value 22695 if test "x$TIME" = x; then 22696 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool TIME= (no value)" >&5 22697 $as_echo "$as_me: Setting user supplied tool TIME= (no value)" >&6;} 22698 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for TIME" >&5 22699 $as_echo_n "checking for TIME... " >&6; } 22700 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 22701 $as_echo "disabled" >&6; } 22702 else 22703 # Check if the provided tool contains a complete path. 22704 tool_specified="$TIME" 22705 tool_basename="${tool_specified##*/}" 22706 if test "x$tool_basename" = "x$tool_specified"; then 22707 # A command without a complete path is provided, search $PATH. 22708 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool TIME=$tool_basename" >&5 22709 $as_echo "$as_me: Will search for user supplied tool TIME=$tool_basename" >&6;} 22710 # Extract the first word of "$tool_basename", so it can be a program name with args. 22711 set dummy $tool_basename; ac_word=$2 22712 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 22713 $as_echo_n "checking for $ac_word... " >&6; } 22714 if ${ac_cv_path_TIME+:} false; then : 22715 $as_echo_n "(cached) " >&6 22716 else 22717 case $TIME in 22718 [\\/]* | ?:[\\/]*) 22719 ac_cv_path_TIME="$TIME" # Let the user override the test with a path. 22720 ;; 22721 *) 22722 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 22723 for as_dir in $PATH 22724 do 22725 IFS=$as_save_IFS 22726 test -z "$as_dir" && as_dir=. 22727 for ac_exec_ext in '' $ac_executable_extensions; do 22728 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 22729 ac_cv_path_TIME="$as_dir/$ac_word$ac_exec_ext" 22730 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 22731 break 2 22732 fi 22733 done 22734 done 22735 IFS=$as_save_IFS 22736 22737 ;; 22738 esac 22739 fi 22740 TIME=$ac_cv_path_TIME 22741 if test -n "$TIME"; then 22742 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $TIME" >&5 22743 $as_echo "$TIME" >&6; } 22744 else 22745 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 22746 $as_echo "no" >&6; } 22747 fi 22748 22749 22750 if test "x$TIME" = x; then 22751 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 22752 fi 22753 else 22754 # Otherwise we believe it is a complete path. Use it as it is. 22755 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool TIME=$tool_specified" >&5 22756 $as_echo "$as_me: Will use user supplied tool TIME=$tool_specified" >&6;} 22757 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for TIME" >&5 22758 $as_echo_n "checking for TIME... " >&6; } 22759 if test ! -x "$tool_specified"; then 22760 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 22761 $as_echo "not found" >&6; } 22762 as_fn_error $? "User supplied tool TIME=$tool_specified does not exist or is not executable" "$LINENO" 5 22763 fi 22764 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 22765 $as_echo "$tool_specified" >&6; } 22766 fi 22767 fi 22768 fi 22769 22770 fi 22771 22772 22773 22774 22775 # Publish this variable in the help. 22776 22777 22778 if [ -z "${DTRACE+x}" ]; then 22779 # The variable is not set by user, try to locate tool using the code snippet 22780 for ac_prog in dtrace 22781 do 22782 # Extract the first word of "$ac_prog", so it can be a program name with args. 22783 set dummy $ac_prog; ac_word=$2 22784 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 22785 $as_echo_n "checking for $ac_word... " >&6; } 22786 if ${ac_cv_path_DTRACE+:} false; then : 22787 $as_echo_n "(cached) " >&6 22788 else 22789 case $DTRACE in 22790 [\\/]* | ?:[\\/]*) 22791 ac_cv_path_DTRACE="$DTRACE" # Let the user override the test with a path. 22792 ;; 22793 *) 22794 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 22795 for as_dir in $PATH 22796 do 22797 IFS=$as_save_IFS 22798 test -z "$as_dir" && as_dir=. 22799 for ac_exec_ext in '' $ac_executable_extensions; do 22800 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 22801 ac_cv_path_DTRACE="$as_dir/$ac_word$ac_exec_ext" 22802 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 22803 break 2 22804 fi 22805 done 22806 done 22807 IFS=$as_save_IFS 22808 22809 ;; 22810 esac 22811 fi 22812 DTRACE=$ac_cv_path_DTRACE 22813 if test -n "$DTRACE"; then 22814 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $DTRACE" >&5 22815 $as_echo "$DTRACE" >&6; } 22816 else 22817 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 22818 $as_echo "no" >&6; } 22819 fi 22820 22821 22822 test -n "$DTRACE" && break 22823 done 22824 22825 else 22826 # The variable is set, but is it from the command line or the environment? 22827 22828 # Try to remove the string !DTRACE! from our list. 22829 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!DTRACE!/} 22830 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 22831 # If it failed, the variable was not from the command line. Ignore it, 22832 # but warn the user (except for BASH, which is always set by the calling BASH). 22833 if test "xDTRACE" != xBASH; then 22834 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of DTRACE from the environment. Use command line variables instead." >&5 22835 $as_echo "$as_me: WARNING: Ignoring value of DTRACE from the environment. Use command line variables instead." >&2;} 22836 fi 22837 # Try to locate tool using the code snippet 22838 for ac_prog in dtrace 22839 do 22840 # Extract the first word of "$ac_prog", so it can be a program name with args. 22841 set dummy $ac_prog; ac_word=$2 22842 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 22843 $as_echo_n "checking for $ac_word... " >&6; } 22844 if ${ac_cv_path_DTRACE+:} false; then : 22845 $as_echo_n "(cached) " >&6 22846 else 22847 case $DTRACE in 22848 [\\/]* | ?:[\\/]*) 22849 ac_cv_path_DTRACE="$DTRACE" # Let the user override the test with a path. 22850 ;; 22851 *) 22852 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 22853 for as_dir in $PATH 22854 do 22855 IFS=$as_save_IFS 22856 test -z "$as_dir" && as_dir=. 22857 for ac_exec_ext in '' $ac_executable_extensions; do 22858 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 22859 ac_cv_path_DTRACE="$as_dir/$ac_word$ac_exec_ext" 22860 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 22861 break 2 22862 fi 22863 done 22864 done 22865 IFS=$as_save_IFS 22866 22867 ;; 22868 esac 22869 fi 22870 DTRACE=$ac_cv_path_DTRACE 22871 if test -n "$DTRACE"; then 22872 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $DTRACE" >&5 22873 $as_echo "$DTRACE" >&6; } 22874 else 22875 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 22876 $as_echo "no" >&6; } 22877 fi 22878 22879 22880 test -n "$DTRACE" && break 22881 done 22882 22883 else 22884 # If it succeeded, then it was overridden by the user. We will use it 22885 # for the tool. 22886 22887 # First remove it from the list of overridden variables, so we can test 22888 # for unknown variables in the end. 22889 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 22890 22891 # Check if we try to supply an empty value 22892 if test "x$DTRACE" = x; then 22893 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool DTRACE= (no value)" >&5 22894 $as_echo "$as_me: Setting user supplied tool DTRACE= (no value)" >&6;} 22895 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for DTRACE" >&5 22896 $as_echo_n "checking for DTRACE... " >&6; } 22897 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 22898 $as_echo "disabled" >&6; } 22899 else 22900 # Check if the provided tool contains a complete path. 22901 tool_specified="$DTRACE" 22902 tool_basename="${tool_specified##*/}" 22903 if test "x$tool_basename" = "x$tool_specified"; then 22904 # A command without a complete path is provided, search $PATH. 22905 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool DTRACE=$tool_basename" >&5 22906 $as_echo "$as_me: Will search for user supplied tool DTRACE=$tool_basename" >&6;} 22907 # Extract the first word of "$tool_basename", so it can be a program name with args. 22908 set dummy $tool_basename; ac_word=$2 22909 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 22910 $as_echo_n "checking for $ac_word... " >&6; } 22911 if ${ac_cv_path_DTRACE+:} false; then : 22912 $as_echo_n "(cached) " >&6 22913 else 22914 case $DTRACE in 22915 [\\/]* | ?:[\\/]*) 22916 ac_cv_path_DTRACE="$DTRACE" # Let the user override the test with a path. 22917 ;; 22918 *) 22919 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 22920 for as_dir in $PATH 22921 do 22922 IFS=$as_save_IFS 22923 test -z "$as_dir" && as_dir=. 22924 for ac_exec_ext in '' $ac_executable_extensions; do 22925 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 22926 ac_cv_path_DTRACE="$as_dir/$ac_word$ac_exec_ext" 22927 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 22928 break 2 22929 fi 22930 done 22931 done 22932 IFS=$as_save_IFS 22933 22934 ;; 22935 esac 22936 fi 22937 DTRACE=$ac_cv_path_DTRACE 22938 if test -n "$DTRACE"; then 22939 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $DTRACE" >&5 22940 $as_echo "$DTRACE" >&6; } 22941 else 22942 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 22943 $as_echo "no" >&6; } 22944 fi 22945 22946 22947 if test "x$DTRACE" = x; then 22948 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 22949 fi 22950 else 22951 # Otherwise we believe it is a complete path. Use it as it is. 22952 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool DTRACE=$tool_specified" >&5 22953 $as_echo "$as_me: Will use user supplied tool DTRACE=$tool_specified" >&6;} 22954 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for DTRACE" >&5 22955 $as_echo_n "checking for DTRACE... " >&6; } 22956 if test ! -x "$tool_specified"; then 22957 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 22958 $as_echo "not found" >&6; } 22959 as_fn_error $? "User supplied tool DTRACE=$tool_specified does not exist or is not executable" "$LINENO" 5 22960 fi 22961 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 22962 $as_echo "$tool_specified" >&6; } 22963 fi 22964 fi 22965 fi 22966 22967 fi 22968 22969 22970 22971 22972 # Publish this variable in the help. 22973 22974 22975 if [ -z "${PATCH+x}" ]; then 22976 # The variable is not set by user, try to locate tool using the code snippet 22977 for ac_prog in gpatch patch 22978 do 22979 # Extract the first word of "$ac_prog", so it can be a program name with args. 22980 set dummy $ac_prog; ac_word=$2 22981 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 22982 $as_echo_n "checking for $ac_word... " >&6; } 22983 if ${ac_cv_path_PATCH+:} false; then : 22984 $as_echo_n "(cached) " >&6 22985 else 22986 case $PATCH in 22987 [\\/]* | ?:[\\/]*) 22988 ac_cv_path_PATCH="$PATCH" # Let the user override the test with a path. 22989 ;; 22990 *) 22991 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 22992 for as_dir in $PATH 22993 do 22994 IFS=$as_save_IFS 22995 test -z "$as_dir" && as_dir=. 22996 for ac_exec_ext in '' $ac_executable_extensions; do 22997 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 22998 ac_cv_path_PATCH="$as_dir/$ac_word$ac_exec_ext" 22999 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 23000 break 2 23001 fi 23002 done 23003 done 23004 IFS=$as_save_IFS 23005 23006 ;; 23007 esac 23008 fi 23009 PATCH=$ac_cv_path_PATCH 23010 if test -n "$PATCH"; then 23011 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $PATCH" >&5 23012 $as_echo "$PATCH" >&6; } 23013 else 23014 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 23015 $as_echo "no" >&6; } 23016 fi 23017 23018 23019 test -n "$PATCH" && break 23020 done 23021 23022 else 23023 # The variable is set, but is it from the command line or the environment? 23024 23025 # Try to remove the string !PATCH! from our list. 23026 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!PATCH!/} 23027 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 23028 # If it failed, the variable was not from the command line. Ignore it, 23029 # but warn the user (except for BASH, which is always set by the calling BASH). 23030 if test "xPATCH" != xBASH; then 23031 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of PATCH from the environment. Use command line variables instead." >&5 23032 $as_echo "$as_me: WARNING: Ignoring value of PATCH from the environment. Use command line variables instead." >&2;} 23033 fi 23034 # Try to locate tool using the code snippet 23035 for ac_prog in gpatch patch 23036 do 23037 # Extract the first word of "$ac_prog", so it can be a program name with args. 23038 set dummy $ac_prog; ac_word=$2 23039 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 23040 $as_echo_n "checking for $ac_word... " >&6; } 23041 if ${ac_cv_path_PATCH+:} false; then : 23042 $as_echo_n "(cached) " >&6 23043 else 23044 case $PATCH in 23045 [\\/]* | ?:[\\/]*) 23046 ac_cv_path_PATCH="$PATCH" # Let the user override the test with a path. 23047 ;; 23048 *) 23049 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 23050 for as_dir in $PATH 23051 do 23052 IFS=$as_save_IFS 23053 test -z "$as_dir" && as_dir=. 23054 for ac_exec_ext in '' $ac_executable_extensions; do 23055 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 23056 ac_cv_path_PATCH="$as_dir/$ac_word$ac_exec_ext" 23057 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 23058 break 2 23059 fi 23060 done 23061 done 23062 IFS=$as_save_IFS 23063 23064 ;; 23065 esac 23066 fi 23067 PATCH=$ac_cv_path_PATCH 23068 if test -n "$PATCH"; then 23069 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $PATCH" >&5 23070 $as_echo "$PATCH" >&6; } 23071 else 23072 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 23073 $as_echo "no" >&6; } 23074 fi 23075 23076 23077 test -n "$PATCH" && break 23078 done 23079 23080 else 23081 # If it succeeded, then it was overridden by the user. We will use it 23082 # for the tool. 23083 23084 # First remove it from the list of overridden variables, so we can test 23085 # for unknown variables in the end. 23086 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 23087 23088 # Check if we try to supply an empty value 23089 if test "x$PATCH" = x; then 23090 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool PATCH= (no value)" >&5 23091 $as_echo "$as_me: Setting user supplied tool PATCH= (no value)" >&6;} 23092 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for PATCH" >&5 23093 $as_echo_n "checking for PATCH... " >&6; } 23094 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 23095 $as_echo "disabled" >&6; } 23096 else 23097 # Check if the provided tool contains a complete path. 23098 tool_specified="$PATCH" 23099 tool_basename="${tool_specified##*/}" 23100 if test "x$tool_basename" = "x$tool_specified"; then 23101 # A command without a complete path is provided, search $PATH. 23102 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool PATCH=$tool_basename" >&5 23103 $as_echo "$as_me: Will search for user supplied tool PATCH=$tool_basename" >&6;} 23104 # Extract the first word of "$tool_basename", so it can be a program name with args. 23105 set dummy $tool_basename; ac_word=$2 23106 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 23107 $as_echo_n "checking for $ac_word... " >&6; } 23108 if ${ac_cv_path_PATCH+:} false; then : 23109 $as_echo_n "(cached) " >&6 23110 else 23111 case $PATCH in 23112 [\\/]* | ?:[\\/]*) 23113 ac_cv_path_PATCH="$PATCH" # Let the user override the test with a path. 23114 ;; 23115 *) 23116 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 23117 for as_dir in $PATH 23118 do 23119 IFS=$as_save_IFS 23120 test -z "$as_dir" && as_dir=. 23121 for ac_exec_ext in '' $ac_executable_extensions; do 23122 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 23123 ac_cv_path_PATCH="$as_dir/$ac_word$ac_exec_ext" 23124 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 23125 break 2 23126 fi 23127 done 23128 done 23129 IFS=$as_save_IFS 23130 23131 ;; 23132 esac 23133 fi 23134 PATCH=$ac_cv_path_PATCH 23135 if test -n "$PATCH"; then 23136 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $PATCH" >&5 23137 $as_echo "$PATCH" >&6; } 23138 else 23139 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 23140 $as_echo "no" >&6; } 23141 fi 23142 23143 23144 if test "x$PATCH" = x; then 23145 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 23146 fi 23147 else 23148 # Otherwise we believe it is a complete path. Use it as it is. 23149 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool PATCH=$tool_specified" >&5 23150 $as_echo "$as_me: Will use user supplied tool PATCH=$tool_specified" >&6;} 23151 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for PATCH" >&5 23152 $as_echo_n "checking for PATCH... " >&6; } 23153 if test ! -x "$tool_specified"; then 23154 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 23155 $as_echo "not found" >&6; } 23156 as_fn_error $? "User supplied tool PATCH=$tool_specified does not exist or is not executable" "$LINENO" 5 23157 fi 23158 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 23159 $as_echo "$tool_specified" >&6; } 23160 fi 23161 fi 23162 fi 23163 23164 fi 23165 23166 23167 # Check if it's GNU time 23168 IS_GNU_TIME=`$TIME --version 2>&1 | $GREP 'GNU time'` 23169 if test "x$IS_GNU_TIME" != x; then 23170 IS_GNU_TIME=yes 23171 else 23172 IS_GNU_TIME=no 23173 fi 23174 23175 23176 if test "x$OPENJDK_TARGET_OS" = "xmacosx"; then 23177 23178 23179 23180 # Publish this variable in the help. 23181 23182 23183 if [ -z "${DSYMUTIL+x}" ]; then 23184 # The variable is not set by user, try to locate tool using the code snippet 23185 for ac_prog in dsymutil 23186 do 23187 # Extract the first word of "$ac_prog", so it can be a program name with args. 23188 set dummy $ac_prog; ac_word=$2 23189 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 23190 $as_echo_n "checking for $ac_word... " >&6; } 23191 if ${ac_cv_path_DSYMUTIL+:} false; then : 23192 $as_echo_n "(cached) " >&6 23193 else 23194 case $DSYMUTIL in 23195 [\\/]* | ?:[\\/]*) 23196 ac_cv_path_DSYMUTIL="$DSYMUTIL" # Let the user override the test with a path. 23197 ;; 23198 *) 23199 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 23200 for as_dir in $PATH 23201 do 23202 IFS=$as_save_IFS 23203 test -z "$as_dir" && as_dir=. 23204 for ac_exec_ext in '' $ac_executable_extensions; do 23205 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 23206 ac_cv_path_DSYMUTIL="$as_dir/$ac_word$ac_exec_ext" 23207 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 23208 break 2 23209 fi 23210 done 23211 done 23212 IFS=$as_save_IFS 23213 23214 ;; 23215 esac 23216 fi 23217 DSYMUTIL=$ac_cv_path_DSYMUTIL 23218 if test -n "$DSYMUTIL"; then 23219 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $DSYMUTIL" >&5 23220 $as_echo "$DSYMUTIL" >&6; } 23221 else 23222 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 23223 $as_echo "no" >&6; } 23224 fi 23225 23226 23227 test -n "$DSYMUTIL" && break 23228 done 23229 23230 else 23231 # The variable is set, but is it from the command line or the environment? 23232 23233 # Try to remove the string !DSYMUTIL! from our list. 23234 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!DSYMUTIL!/} 23235 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 23236 # If it failed, the variable was not from the command line. Ignore it, 23237 # but warn the user (except for BASH, which is always set by the calling BASH). 23238 if test "xDSYMUTIL" != xBASH; then 23239 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of DSYMUTIL from the environment. Use command line variables instead." >&5 23240 $as_echo "$as_me: WARNING: Ignoring value of DSYMUTIL from the environment. Use command line variables instead." >&2;} 23241 fi 23242 # Try to locate tool using the code snippet 23243 for ac_prog in dsymutil 23244 do 23245 # Extract the first word of "$ac_prog", so it can be a program name with args. 23246 set dummy $ac_prog; ac_word=$2 23247 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 23248 $as_echo_n "checking for $ac_word... " >&6; } 23249 if ${ac_cv_path_DSYMUTIL+:} false; then : 23250 $as_echo_n "(cached) " >&6 23251 else 23252 case $DSYMUTIL in 23253 [\\/]* | ?:[\\/]*) 23254 ac_cv_path_DSYMUTIL="$DSYMUTIL" # Let the user override the test with a path. 23255 ;; 23256 *) 23257 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 23258 for as_dir in $PATH 23259 do 23260 IFS=$as_save_IFS 23261 test -z "$as_dir" && as_dir=. 23262 for ac_exec_ext in '' $ac_executable_extensions; do 23263 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 23264 ac_cv_path_DSYMUTIL="$as_dir/$ac_word$ac_exec_ext" 23265 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 23266 break 2 23267 fi 23268 done 23269 done 23270 IFS=$as_save_IFS 23271 23272 ;; 23273 esac 23274 fi 23275 DSYMUTIL=$ac_cv_path_DSYMUTIL 23276 if test -n "$DSYMUTIL"; then 23277 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $DSYMUTIL" >&5 23278 $as_echo "$DSYMUTIL" >&6; } 23279 else 23280 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 23281 $as_echo "no" >&6; } 23282 fi 23283 23284 23285 test -n "$DSYMUTIL" && break 23286 done 23287 23288 else 23289 # If it succeeded, then it was overridden by the user. We will use it 23290 # for the tool. 23291 23292 # First remove it from the list of overridden variables, so we can test 23293 # for unknown variables in the end. 23294 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 23295 23296 # Check if we try to supply an empty value 23297 if test "x$DSYMUTIL" = x; then 23298 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool DSYMUTIL= (no value)" >&5 23299 $as_echo "$as_me: Setting user supplied tool DSYMUTIL= (no value)" >&6;} 23300 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for DSYMUTIL" >&5 23301 $as_echo_n "checking for DSYMUTIL... " >&6; } 23302 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 23303 $as_echo "disabled" >&6; } 23304 else 23305 # Check if the provided tool contains a complete path. 23306 tool_specified="$DSYMUTIL" 23307 tool_basename="${tool_specified##*/}" 23308 if test "x$tool_basename" = "x$tool_specified"; then 23309 # A command without a complete path is provided, search $PATH. 23310 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool DSYMUTIL=$tool_basename" >&5 23311 $as_echo "$as_me: Will search for user supplied tool DSYMUTIL=$tool_basename" >&6;} 23312 # Extract the first word of "$tool_basename", so it can be a program name with args. 23313 set dummy $tool_basename; ac_word=$2 23314 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 23315 $as_echo_n "checking for $ac_word... " >&6; } 23316 if ${ac_cv_path_DSYMUTIL+:} false; then : 23317 $as_echo_n "(cached) " >&6 23318 else 23319 case $DSYMUTIL in 23320 [\\/]* | ?:[\\/]*) 23321 ac_cv_path_DSYMUTIL="$DSYMUTIL" # Let the user override the test with a path. 23322 ;; 23323 *) 23324 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 23325 for as_dir in $PATH 23326 do 23327 IFS=$as_save_IFS 23328 test -z "$as_dir" && as_dir=. 23329 for ac_exec_ext in '' $ac_executable_extensions; do 23330 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 23331 ac_cv_path_DSYMUTIL="$as_dir/$ac_word$ac_exec_ext" 23332 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 23333 break 2 23334 fi 23335 done 23336 done 23337 IFS=$as_save_IFS 23338 23339 ;; 23340 esac 23341 fi 23342 DSYMUTIL=$ac_cv_path_DSYMUTIL 23343 if test -n "$DSYMUTIL"; then 23344 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $DSYMUTIL" >&5 23345 $as_echo "$DSYMUTIL" >&6; } 23346 else 23347 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 23348 $as_echo "no" >&6; } 23349 fi 23350 23351 23352 if test "x$DSYMUTIL" = x; then 23353 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 23354 fi 23355 else 23356 # Otherwise we believe it is a complete path. Use it as it is. 23357 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool DSYMUTIL=$tool_specified" >&5 23358 $as_echo "$as_me: Will use user supplied tool DSYMUTIL=$tool_specified" >&6;} 23359 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for DSYMUTIL" >&5 23360 $as_echo_n "checking for DSYMUTIL... " >&6; } 23361 if test ! -x "$tool_specified"; then 23362 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 23363 $as_echo "not found" >&6; } 23364 as_fn_error $? "User supplied tool DSYMUTIL=$tool_specified does not exist or is not executable" "$LINENO" 5 23365 fi 23366 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 23367 $as_echo "$tool_specified" >&6; } 23368 fi 23369 fi 23370 fi 23371 23372 fi 23373 23374 23375 23376 if test "x$DSYMUTIL" = x; then 23377 as_fn_error $? "Could not find required tool for DSYMUTIL" "$LINENO" 5 23378 fi 23379 23380 23381 23382 23383 23384 # Publish this variable in the help. 23385 23386 23387 if [ -z "${XATTR+x}" ]; then 23388 # The variable is not set by user, try to locate tool using the code snippet 23389 for ac_prog in xattr 23390 do 23391 # Extract the first word of "$ac_prog", so it can be a program name with args. 23392 set dummy $ac_prog; ac_word=$2 23393 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 23394 $as_echo_n "checking for $ac_word... " >&6; } 23395 if ${ac_cv_path_XATTR+:} false; then : 23396 $as_echo_n "(cached) " >&6 23397 else 23398 case $XATTR in 23399 [\\/]* | ?:[\\/]*) 23400 ac_cv_path_XATTR="$XATTR" # Let the user override the test with a path. 23401 ;; 23402 *) 23403 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 23404 for as_dir in $PATH 23405 do 23406 IFS=$as_save_IFS 23407 test -z "$as_dir" && as_dir=. 23408 for ac_exec_ext in '' $ac_executable_extensions; do 23409 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 23410 ac_cv_path_XATTR="$as_dir/$ac_word$ac_exec_ext" 23411 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 23412 break 2 23413 fi 23414 done 23415 done 23416 IFS=$as_save_IFS 23417 23418 ;; 23419 esac 23420 fi 23421 XATTR=$ac_cv_path_XATTR 23422 if test -n "$XATTR"; then 23423 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $XATTR" >&5 23424 $as_echo "$XATTR" >&6; } 23425 else 23426 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 23427 $as_echo "no" >&6; } 23428 fi 23429 23430 23431 test -n "$XATTR" && break 23432 done 23433 23434 else 23435 # The variable is set, but is it from the command line or the environment? 23436 23437 # Try to remove the string !XATTR! from our list. 23438 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!XATTR!/} 23439 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 23440 # If it failed, the variable was not from the command line. Ignore it, 23441 # but warn the user (except for BASH, which is always set by the calling BASH). 23442 if test "xXATTR" != xBASH; then 23443 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of XATTR from the environment. Use command line variables instead." >&5 23444 $as_echo "$as_me: WARNING: Ignoring value of XATTR from the environment. Use command line variables instead." >&2;} 23445 fi 23446 # Try to locate tool using the code snippet 23447 for ac_prog in xattr 23448 do 23449 # Extract the first word of "$ac_prog", so it can be a program name with args. 23450 set dummy $ac_prog; ac_word=$2 23451 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 23452 $as_echo_n "checking for $ac_word... " >&6; } 23453 if ${ac_cv_path_XATTR+:} false; then : 23454 $as_echo_n "(cached) " >&6 23455 else 23456 case $XATTR in 23457 [\\/]* | ?:[\\/]*) 23458 ac_cv_path_XATTR="$XATTR" # Let the user override the test with a path. 23459 ;; 23460 *) 23461 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 23462 for as_dir in $PATH 23463 do 23464 IFS=$as_save_IFS 23465 test -z "$as_dir" && as_dir=. 23466 for ac_exec_ext in '' $ac_executable_extensions; do 23467 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 23468 ac_cv_path_XATTR="$as_dir/$ac_word$ac_exec_ext" 23469 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 23470 break 2 23471 fi 23472 done 23473 done 23474 IFS=$as_save_IFS 23475 23476 ;; 23477 esac 23478 fi 23479 XATTR=$ac_cv_path_XATTR 23480 if test -n "$XATTR"; then 23481 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $XATTR" >&5 23482 $as_echo "$XATTR" >&6; } 23483 else 23484 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 23485 $as_echo "no" >&6; } 23486 fi 23487 23488 23489 test -n "$XATTR" && break 23490 done 23491 23492 else 23493 # If it succeeded, then it was overridden by the user. We will use it 23494 # for the tool. 23495 23496 # First remove it from the list of overridden variables, so we can test 23497 # for unknown variables in the end. 23498 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 23499 23500 # Check if we try to supply an empty value 23501 if test "x$XATTR" = x; then 23502 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool XATTR= (no value)" >&5 23503 $as_echo "$as_me: Setting user supplied tool XATTR= (no value)" >&6;} 23504 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for XATTR" >&5 23505 $as_echo_n "checking for XATTR... " >&6; } 23506 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 23507 $as_echo "disabled" >&6; } 23508 else 23509 # Check if the provided tool contains a complete path. 23510 tool_specified="$XATTR" 23511 tool_basename="${tool_specified##*/}" 23512 if test "x$tool_basename" = "x$tool_specified"; then 23513 # A command without a complete path is provided, search $PATH. 23514 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool XATTR=$tool_basename" >&5 23515 $as_echo "$as_me: Will search for user supplied tool XATTR=$tool_basename" >&6;} 23516 # Extract the first word of "$tool_basename", so it can be a program name with args. 23517 set dummy $tool_basename; ac_word=$2 23518 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 23519 $as_echo_n "checking for $ac_word... " >&6; } 23520 if ${ac_cv_path_XATTR+:} false; then : 23521 $as_echo_n "(cached) " >&6 23522 else 23523 case $XATTR in 23524 [\\/]* | ?:[\\/]*) 23525 ac_cv_path_XATTR="$XATTR" # Let the user override the test with a path. 23526 ;; 23527 *) 23528 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 23529 for as_dir in $PATH 23530 do 23531 IFS=$as_save_IFS 23532 test -z "$as_dir" && as_dir=. 23533 for ac_exec_ext in '' $ac_executable_extensions; do 23534 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 23535 ac_cv_path_XATTR="$as_dir/$ac_word$ac_exec_ext" 23536 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 23537 break 2 23538 fi 23539 done 23540 done 23541 IFS=$as_save_IFS 23542 23543 ;; 23544 esac 23545 fi 23546 XATTR=$ac_cv_path_XATTR 23547 if test -n "$XATTR"; then 23548 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $XATTR" >&5 23549 $as_echo "$XATTR" >&6; } 23550 else 23551 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 23552 $as_echo "no" >&6; } 23553 fi 23554 23555 23556 if test "x$XATTR" = x; then 23557 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 23558 fi 23559 else 23560 # Otherwise we believe it is a complete path. Use it as it is. 23561 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool XATTR=$tool_specified" >&5 23562 $as_echo "$as_me: Will use user supplied tool XATTR=$tool_specified" >&6;} 23563 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for XATTR" >&5 23564 $as_echo_n "checking for XATTR... " >&6; } 23565 if test ! -x "$tool_specified"; then 23566 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 23567 $as_echo "not found" >&6; } 23568 as_fn_error $? "User supplied tool XATTR=$tool_specified does not exist or is not executable" "$LINENO" 5 23569 fi 23570 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 23571 $as_echo "$tool_specified" >&6; } 23572 fi 23573 fi 23574 fi 23575 23576 fi 23577 23578 23579 23580 if test "x$XATTR" = x; then 23581 as_fn_error $? "Could not find required tool for XATTR" "$LINENO" 5 23582 fi 23583 23584 23585 23586 23587 # Publish this variable in the help. 23588 23589 23590 if [ -z "${CODESIGN+x}" ]; then 23591 # The variable is not set by user, try to locate tool using the code snippet 23592 for ac_prog in codesign 23593 do 23594 # Extract the first word of "$ac_prog", so it can be a program name with args. 23595 set dummy $ac_prog; ac_word=$2 23596 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 23597 $as_echo_n "checking for $ac_word... " >&6; } 23598 if ${ac_cv_path_CODESIGN+:} false; then : 23599 $as_echo_n "(cached) " >&6 23600 else 23601 case $CODESIGN in 23602 [\\/]* | ?:[\\/]*) 23603 ac_cv_path_CODESIGN="$CODESIGN" # Let the user override the test with a path. 23604 ;; 23605 *) 23606 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 23607 for as_dir in $PATH 23608 do 23609 IFS=$as_save_IFS 23610 test -z "$as_dir" && as_dir=. 23611 for ac_exec_ext in '' $ac_executable_extensions; do 23612 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 23613 ac_cv_path_CODESIGN="$as_dir/$ac_word$ac_exec_ext" 23614 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 23615 break 2 23616 fi 23617 done 23618 done 23619 IFS=$as_save_IFS 23620 23621 ;; 23622 esac 23623 fi 23624 CODESIGN=$ac_cv_path_CODESIGN 23625 if test -n "$CODESIGN"; then 23626 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CODESIGN" >&5 23627 $as_echo "$CODESIGN" >&6; } 23628 else 23629 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 23630 $as_echo "no" >&6; } 23631 fi 23632 23633 23634 test -n "$CODESIGN" && break 23635 done 23636 23637 else 23638 # The variable is set, but is it from the command line or the environment? 23639 23640 # Try to remove the string !CODESIGN! from our list. 23641 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!CODESIGN!/} 23642 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 23643 # If it failed, the variable was not from the command line. Ignore it, 23644 # but warn the user (except for BASH, which is always set by the calling BASH). 23645 if test "xCODESIGN" != xBASH; then 23646 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of CODESIGN from the environment. Use command line variables instead." >&5 23647 $as_echo "$as_me: WARNING: Ignoring value of CODESIGN from the environment. Use command line variables instead." >&2;} 23648 fi 23649 # Try to locate tool using the code snippet 23650 for ac_prog in codesign 23651 do 23652 # Extract the first word of "$ac_prog", so it can be a program name with args. 23653 set dummy $ac_prog; ac_word=$2 23654 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 23655 $as_echo_n "checking for $ac_word... " >&6; } 23656 if ${ac_cv_path_CODESIGN+:} false; then : 23657 $as_echo_n "(cached) " >&6 23658 else 23659 case $CODESIGN in 23660 [\\/]* | ?:[\\/]*) 23661 ac_cv_path_CODESIGN="$CODESIGN" # Let the user override the test with a path. 23662 ;; 23663 *) 23664 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 23665 for as_dir in $PATH 23666 do 23667 IFS=$as_save_IFS 23668 test -z "$as_dir" && as_dir=. 23669 for ac_exec_ext in '' $ac_executable_extensions; do 23670 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 23671 ac_cv_path_CODESIGN="$as_dir/$ac_word$ac_exec_ext" 23672 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 23673 break 2 23674 fi 23675 done 23676 done 23677 IFS=$as_save_IFS 23678 23679 ;; 23680 esac 23681 fi 23682 CODESIGN=$ac_cv_path_CODESIGN 23683 if test -n "$CODESIGN"; then 23684 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CODESIGN" >&5 23685 $as_echo "$CODESIGN" >&6; } 23686 else 23687 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 23688 $as_echo "no" >&6; } 23689 fi 23690 23691 23692 test -n "$CODESIGN" && break 23693 done 23694 23695 else 23696 # If it succeeded, then it was overridden by the user. We will use it 23697 # for the tool. 23698 23699 # First remove it from the list of overridden variables, so we can test 23700 # for unknown variables in the end. 23701 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 23702 23703 # Check if we try to supply an empty value 23704 if test "x$CODESIGN" = x; then 23705 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool CODESIGN= (no value)" >&5 23706 $as_echo "$as_me: Setting user supplied tool CODESIGN= (no value)" >&6;} 23707 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for CODESIGN" >&5 23708 $as_echo_n "checking for CODESIGN... " >&6; } 23709 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 23710 $as_echo "disabled" >&6; } 23711 else 23712 # Check if the provided tool contains a complete path. 23713 tool_specified="$CODESIGN" 23714 tool_basename="${tool_specified##*/}" 23715 if test "x$tool_basename" = "x$tool_specified"; then 23716 # A command without a complete path is provided, search $PATH. 23717 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool CODESIGN=$tool_basename" >&5 23718 $as_echo "$as_me: Will search for user supplied tool CODESIGN=$tool_basename" >&6;} 23719 # Extract the first word of "$tool_basename", so it can be a program name with args. 23720 set dummy $tool_basename; ac_word=$2 23721 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 23722 $as_echo_n "checking for $ac_word... " >&6; } 23723 if ${ac_cv_path_CODESIGN+:} false; then : 23724 $as_echo_n "(cached) " >&6 23725 else 23726 case $CODESIGN in 23727 [\\/]* | ?:[\\/]*) 23728 ac_cv_path_CODESIGN="$CODESIGN" # Let the user override the test with a path. 23729 ;; 23730 *) 23731 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 23732 for as_dir in $PATH 23733 do 23734 IFS=$as_save_IFS 23735 test -z "$as_dir" && as_dir=. 23736 for ac_exec_ext in '' $ac_executable_extensions; do 23737 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 23738 ac_cv_path_CODESIGN="$as_dir/$ac_word$ac_exec_ext" 23739 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 23740 break 2 23741 fi 23742 done 23743 done 23744 IFS=$as_save_IFS 23745 23746 ;; 23747 esac 23748 fi 23749 CODESIGN=$ac_cv_path_CODESIGN 23750 if test -n "$CODESIGN"; then 23751 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CODESIGN" >&5 23752 $as_echo "$CODESIGN" >&6; } 23753 else 23754 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 23755 $as_echo "no" >&6; } 23756 fi 23757 23758 23759 if test "x$CODESIGN" = x; then 23760 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 23761 fi 23762 else 23763 # Otherwise we believe it is a complete path. Use it as it is. 23764 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool CODESIGN=$tool_specified" >&5 23765 $as_echo "$as_me: Will use user supplied tool CODESIGN=$tool_specified" >&6;} 23766 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for CODESIGN" >&5 23767 $as_echo_n "checking for CODESIGN... " >&6; } 23768 if test ! -x "$tool_specified"; then 23769 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 23770 $as_echo "not found" >&6; } 23771 as_fn_error $? "User supplied tool CODESIGN=$tool_specified does not exist or is not executable" "$LINENO" 5 23772 fi 23773 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 23774 $as_echo "$tool_specified" >&6; } 23775 fi 23776 fi 23777 fi 23778 23779 fi 23780 23781 23782 if test "x$CODESIGN" != "x"; then 23783 # Verify that the openjdk_codesign certificate is present 23784 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if openjdk_codesign certificate is present" >&5 23785 $as_echo_n "checking if openjdk_codesign certificate is present... " >&6; } 23786 $RM codesign-testfile 23787 $TOUCH codesign-testfile 23788 $CODESIGN -s openjdk_codesign codesign-testfile 2>&5 >&5 || CODESIGN= 23789 $RM codesign-testfile 23790 if test "x$CODESIGN" = x; then 23791 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 23792 $as_echo "no" >&6; } 23793 else 23794 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 23795 $as_echo "yes" >&6; } 23796 fi 23797 fi 23798 23799 23800 23801 # Publish this variable in the help. 23802 23803 23804 if [ -z "${SETFILE+x}" ]; then 23805 # The variable is not set by user, try to locate tool using the code snippet 23806 for ac_prog in SetFile 23807 do 23808 # Extract the first word of "$ac_prog", so it can be a program name with args. 23809 set dummy $ac_prog; ac_word=$2 23810 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 23811 $as_echo_n "checking for $ac_word... " >&6; } 23812 if ${ac_cv_path_SETFILE+:} false; then : 23813 $as_echo_n "(cached) " >&6 23814 else 23815 case $SETFILE in 23816 [\\/]* | ?:[\\/]*) 23817 ac_cv_path_SETFILE="$SETFILE" # Let the user override the test with a path. 23818 ;; 23819 *) 23820 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 23821 for as_dir in $PATH 23822 do 23823 IFS=$as_save_IFS 23824 test -z "$as_dir" && as_dir=. 23825 for ac_exec_ext in '' $ac_executable_extensions; do 23826 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 23827 ac_cv_path_SETFILE="$as_dir/$ac_word$ac_exec_ext" 23828 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 23829 break 2 23830 fi 23831 done 23832 done 23833 IFS=$as_save_IFS 23834 23835 ;; 23836 esac 23837 fi 23838 SETFILE=$ac_cv_path_SETFILE 23839 if test -n "$SETFILE"; then 23840 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $SETFILE" >&5 23841 $as_echo "$SETFILE" >&6; } 23842 else 23843 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 23844 $as_echo "no" >&6; } 23845 fi 23846 23847 23848 test -n "$SETFILE" && break 23849 done 23850 23851 else 23852 # The variable is set, but is it from the command line or the environment? 23853 23854 # Try to remove the string !SETFILE! from our list. 23855 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!SETFILE!/} 23856 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 23857 # If it failed, the variable was not from the command line. Ignore it, 23858 # but warn the user (except for BASH, which is always set by the calling BASH). 23859 if test "xSETFILE" != xBASH; then 23860 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of SETFILE from the environment. Use command line variables instead." >&5 23861 $as_echo "$as_me: WARNING: Ignoring value of SETFILE from the environment. Use command line variables instead." >&2;} 23862 fi 23863 # Try to locate tool using the code snippet 23864 for ac_prog in SetFile 23865 do 23866 # Extract the first word of "$ac_prog", so it can be a program name with args. 23867 set dummy $ac_prog; ac_word=$2 23868 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 23869 $as_echo_n "checking for $ac_word... " >&6; } 23870 if ${ac_cv_path_SETFILE+:} false; then : 23871 $as_echo_n "(cached) " >&6 23872 else 23873 case $SETFILE in 23874 [\\/]* | ?:[\\/]*) 23875 ac_cv_path_SETFILE="$SETFILE" # Let the user override the test with a path. 23876 ;; 23877 *) 23878 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 23879 for as_dir in $PATH 23880 do 23881 IFS=$as_save_IFS 23882 test -z "$as_dir" && as_dir=. 23883 for ac_exec_ext in '' $ac_executable_extensions; do 23884 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 23885 ac_cv_path_SETFILE="$as_dir/$ac_word$ac_exec_ext" 23886 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 23887 break 2 23888 fi 23889 done 23890 done 23891 IFS=$as_save_IFS 23892 23893 ;; 23894 esac 23895 fi 23896 SETFILE=$ac_cv_path_SETFILE 23897 if test -n "$SETFILE"; then 23898 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $SETFILE" >&5 23899 $as_echo "$SETFILE" >&6; } 23900 else 23901 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 23902 $as_echo "no" >&6; } 23903 fi 23904 23905 23906 test -n "$SETFILE" && break 23907 done 23908 23909 else 23910 # If it succeeded, then it was overridden by the user. We will use it 23911 # for the tool. 23912 23913 # First remove it from the list of overridden variables, so we can test 23914 # for unknown variables in the end. 23915 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 23916 23917 # Check if we try to supply an empty value 23918 if test "x$SETFILE" = x; then 23919 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool SETFILE= (no value)" >&5 23920 $as_echo "$as_me: Setting user supplied tool SETFILE= (no value)" >&6;} 23921 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for SETFILE" >&5 23922 $as_echo_n "checking for SETFILE... " >&6; } 23923 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 23924 $as_echo "disabled" >&6; } 23925 else 23926 # Check if the provided tool contains a complete path. 23927 tool_specified="$SETFILE" 23928 tool_basename="${tool_specified##*/}" 23929 if test "x$tool_basename" = "x$tool_specified"; then 23930 # A command without a complete path is provided, search $PATH. 23931 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool SETFILE=$tool_basename" >&5 23932 $as_echo "$as_me: Will search for user supplied tool SETFILE=$tool_basename" >&6;} 23933 # Extract the first word of "$tool_basename", so it can be a program name with args. 23934 set dummy $tool_basename; ac_word=$2 23935 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 23936 $as_echo_n "checking for $ac_word... " >&6; } 23937 if ${ac_cv_path_SETFILE+:} false; then : 23938 $as_echo_n "(cached) " >&6 23939 else 23940 case $SETFILE in 23941 [\\/]* | ?:[\\/]*) 23942 ac_cv_path_SETFILE="$SETFILE" # Let the user override the test with a path. 23943 ;; 23944 *) 23945 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 23946 for as_dir in $PATH 23947 do 23948 IFS=$as_save_IFS 23949 test -z "$as_dir" && as_dir=. 23950 for ac_exec_ext in '' $ac_executable_extensions; do 23951 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 23952 ac_cv_path_SETFILE="$as_dir/$ac_word$ac_exec_ext" 23953 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 23954 break 2 23955 fi 23956 done 23957 done 23958 IFS=$as_save_IFS 23959 23960 ;; 23961 esac 23962 fi 23963 SETFILE=$ac_cv_path_SETFILE 23964 if test -n "$SETFILE"; then 23965 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $SETFILE" >&5 23966 $as_echo "$SETFILE" >&6; } 23967 else 23968 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 23969 $as_echo "no" >&6; } 23970 fi 23971 23972 23973 if test "x$SETFILE" = x; then 23974 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 23975 fi 23976 else 23977 # Otherwise we believe it is a complete path. Use it as it is. 23978 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool SETFILE=$tool_specified" >&5 23979 $as_echo "$as_me: Will use user supplied tool SETFILE=$tool_specified" >&6;} 23980 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for SETFILE" >&5 23981 $as_echo_n "checking for SETFILE... " >&6; } 23982 if test ! -x "$tool_specified"; then 23983 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 23984 $as_echo "not found" >&6; } 23985 as_fn_error $? "User supplied tool SETFILE=$tool_specified does not exist or is not executable" "$LINENO" 5 23986 fi 23987 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 23988 $as_echo "$tool_specified" >&6; } 23989 fi 23990 fi 23991 fi 23992 23993 fi 23994 23995 23996 23997 if test "x$SETFILE" = x; then 23998 as_fn_error $? "Could not find required tool for SETFILE" "$LINENO" 5 23999 fi 24000 24001 24002 fi 24003 24004 24005 # Test if bash supports pipefail. 24006 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if bash supports pipefail" >&5 24007 $as_echo_n "checking if bash supports pipefail... " >&6; } 24008 if ${BASH} -c 'set -o pipefail'; then 24009 BASH_ARGS="$BASH_ARGS -o pipefail" 24010 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 24011 $as_echo "yes" >&6; } 24012 else 24013 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 24014 $as_echo "no" >&6; } 24015 fi 24016 24017 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if bash supports errexit (-e)" >&5 24018 $as_echo_n "checking if bash supports errexit (-e)... " >&6; } 24019 if ${BASH} -e -c 'true'; then 24020 BASH_ARGS="$BASH_ARGS -e" 24021 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 24022 $as_echo "yes" >&6; } 24023 else 24024 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 24025 $as_echo "no" >&6; } 24026 fi 24027 24028 24029 24030 24031 # Check if pkg-config is available. 24032 24033 24034 if test "x$ac_cv_env_PKG_CONFIG_set" != "xset"; then 24035 if test -n "$ac_tool_prefix"; then 24036 # Extract the first word of "${ac_tool_prefix}pkg-config", so it can be a program name with args. 24037 set dummy ${ac_tool_prefix}pkg-config; ac_word=$2 24038 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 24039 $as_echo_n "checking for $ac_word... " >&6; } 24040 if ${ac_cv_path_PKG_CONFIG+:} false; then : 24041 $as_echo_n "(cached) " >&6 24042 else 24043 case $PKG_CONFIG in 24044 [\\/]* | ?:[\\/]*) 24045 ac_cv_path_PKG_CONFIG="$PKG_CONFIG" # Let the user override the test with a path. 24046 ;; 24047 *) 24048 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 24049 for as_dir in $PATH 24050 do 24051 IFS=$as_save_IFS 24052 test -z "$as_dir" && as_dir=. 24053 for ac_exec_ext in '' $ac_executable_extensions; do 24054 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 24055 ac_cv_path_PKG_CONFIG="$as_dir/$ac_word$ac_exec_ext" 24056 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 24057 break 2 24058 fi 24059 done 24060 done 24061 IFS=$as_save_IFS 24062 24063 ;; 24064 esac 24065 fi 24066 PKG_CONFIG=$ac_cv_path_PKG_CONFIG 24067 if test -n "$PKG_CONFIG"; then 24068 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $PKG_CONFIG" >&5 24069 $as_echo "$PKG_CONFIG" >&6; } 24070 else 24071 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 24072 $as_echo "no" >&6; } 24073 fi 24074 24075 24076 fi 24077 if test -z "$ac_cv_path_PKG_CONFIG"; then 24078 ac_pt_PKG_CONFIG=$PKG_CONFIG 24079 # Extract the first word of "pkg-config", so it can be a program name with args. 24080 set dummy pkg-config; ac_word=$2 24081 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 24082 $as_echo_n "checking for $ac_word... " >&6; } 24083 if ${ac_cv_path_ac_pt_PKG_CONFIG+:} false; then : 24084 $as_echo_n "(cached) " >&6 24085 else 24086 case $ac_pt_PKG_CONFIG in 24087 [\\/]* | ?:[\\/]*) 24088 ac_cv_path_ac_pt_PKG_CONFIG="$ac_pt_PKG_CONFIG" # Let the user override the test with a path. 24089 ;; 24090 *) 24091 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 24092 for as_dir in $PATH 24093 do 24094 IFS=$as_save_IFS 24095 test -z "$as_dir" && as_dir=. 24096 for ac_exec_ext in '' $ac_executable_extensions; do 24097 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 24098 ac_cv_path_ac_pt_PKG_CONFIG="$as_dir/$ac_word$ac_exec_ext" 24099 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 24100 break 2 24101 fi 24102 done 24103 done 24104 IFS=$as_save_IFS 24105 24106 ;; 24107 esac 24108 fi 24109 ac_pt_PKG_CONFIG=$ac_cv_path_ac_pt_PKG_CONFIG 24110 if test -n "$ac_pt_PKG_CONFIG"; then 24111 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_pt_PKG_CONFIG" >&5 24112 $as_echo "$ac_pt_PKG_CONFIG" >&6; } 24113 else 24114 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 24115 $as_echo "no" >&6; } 24116 fi 24117 24118 if test "x$ac_pt_PKG_CONFIG" = x; then 24119 PKG_CONFIG="" 24120 else 24121 case $cross_compiling:$ac_tool_warned in 24122 yes:) 24123 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5 24124 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;} 24125 ac_tool_warned=yes ;; 24126 esac 24127 PKG_CONFIG=$ac_pt_PKG_CONFIG 24128 fi 24129 else 24130 PKG_CONFIG="$ac_cv_path_PKG_CONFIG" 24131 fi 24132 24133 fi 24134 if test -n "$PKG_CONFIG"; then 24135 _pkg_min_version=0.9.0 24136 { $as_echo "$as_me:${as_lineno-$LINENO}: checking pkg-config is at least version $_pkg_min_version" >&5 24137 $as_echo_n "checking pkg-config is at least version $_pkg_min_version... " >&6; } 24138 if $PKG_CONFIG --atleast-pkgconfig-version $_pkg_min_version; then 24139 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 24140 $as_echo "yes" >&6; } 24141 else 24142 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 24143 $as_echo "no" >&6; } 24144 PKG_CONFIG="" 24145 fi 24146 24147 fi 24148 24149 # After basic tools have been setup, we can check build os specific details. 24150 24151 ############################################################################### 24152 24153 # Note that this is the build platform OS version! 24154 24155 OS_VERSION="`uname -r | ${SED} 's!\.! !g' | ${SED} 's!-! !g'`" 24156 OS_VERSION_MAJOR="`${ECHO} ${OS_VERSION} | ${CUT} -f 1 -d ' '`" 24157 OS_VERSION_MINOR="`${ECHO} ${OS_VERSION} | ${CUT} -f 2 -d ' '`" 24158 OS_VERSION_MICRO="`${ECHO} ${OS_VERSION} | ${CUT} -f 3 -d ' '`" 24159 24160 24161 24162 24163 24164 # Misc basic settings 24165 24166 24167 # Check whether --with-default-make-target was given. 24168 if test "${with_default_make_target+set}" = set; then : 24169 withval=$with_default_make_target; 24170 fi 24171 24172 if test "x$with_default_make_target" = "x" \ 24173 || test "x$with_default_make_target" = "xyes"; then 24174 DEFAULT_MAKE_TARGET="exploded-image" 24175 elif test "x$with_default_make_target" = "xno"; then 24176 as_fn_error $? "--without-default-make-target is not a valid option" "$LINENO" 5 24177 else 24178 DEFAULT_MAKE_TARGET="$with_default_make_target" 24179 fi 24180 24181 24182 24183 24184 ############################################################################### 24185 # 24186 # Determine OpenJDK variants, options and version numbers. 24187 # 24188 ############################################################################### 24189 24190 # We need build & target for this. 24191 24192 # Should we build a JDK without a graphical UI? 24193 { $as_echo "$as_me:${as_lineno-$LINENO}: checking headless only" >&5 24194 $as_echo_n "checking headless only... " >&6; } 24195 # Check whether --enable-headless-only was given. 24196 if test "${enable_headless_only+set}" = set; then : 24197 enableval=$enable_headless_only; 24198 fi 24199 24200 24201 if test "x$enable_headless_only" = "xyes"; then 24202 ENABLE_HEADLESS_ONLY="true" 24203 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 24204 $as_echo "yes" >&6; } 24205 elif test "x$enable_headless_only" = "xno"; then 24206 ENABLE_HEADLESS_ONLY="false" 24207 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 24208 $as_echo "no" >&6; } 24209 elif test "x$enable_headless_only" = "x"; then 24210 ENABLE_HEADLESS_ONLY="false" 24211 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 24212 $as_echo "no" >&6; } 24213 else 24214 as_fn_error $? "--enable-headless-only can only take yes or no" "$LINENO" 5 24215 fi 24216 24217 24218 24219 # Choose cacerts source file 24220 24221 # Check whether --with-cacerts-file was given. 24222 if test "${with_cacerts_file+set}" = set; then : 24223 withval=$with_cacerts_file; 24224 fi 24225 24226 if test "x$with_cacerts_file" != x; then 24227 CACERTS_FILE=$with_cacerts_file 24228 fi 24229 24230 24231 # Enable or disable unlimited crypto 24232 # Check whether --enable-unlimited-crypto was given. 24233 if test "${enable_unlimited_crypto+set}" = set; then : 24234 enableval=$enable_unlimited_crypto; 24235 else 24236 enable_unlimited_crypto=no 24237 fi 24238 24239 if test "x$enable_unlimited_crypto" = "xyes"; then 24240 UNLIMITED_CRYPTO=true 24241 else 24242 UNLIMITED_CRYPTO=false 24243 fi 24244 24245 24246 # Should we build the serviceability agent (SA)? 24247 INCLUDE_SA=true 24248 if [[ " $JVM_VARIANTS " =~ " zero " ]] || [[ " $JVM_VARIANTS " =~ " zeroshark " ]] ; then 24249 INCLUDE_SA=false 24250 fi 24251 if test "x$OPENJDK_TARGET_OS" = xaix ; then 24252 INCLUDE_SA=false 24253 fi 24254 24255 24256 # Compress jars 24257 COMPRESS_JARS=false 24258 24259 24260 24261 # Setup default copyright year. Mostly overridden when building close to a new year. 24262 24263 # Check whether --with-copyright-year was given. 24264 if test "${with_copyright_year+set}" = set; then : 24265 withval=$with_copyright_year; 24266 fi 24267 24268 if test "x$with_copyright_year" = xyes; then 24269 as_fn_error $? "Copyright year must have a value" "$LINENO" 5 24270 elif test "x$with_copyright_year" != x; then 24271 COPYRIGHT_YEAR="$with_copyright_year" 24272 else 24273 COPYRIGHT_YEAR=`$DATE +'%Y'` 24274 fi 24275 24276 24277 24278 # Check whether --enable-keep-packaged-modules was given. 24279 if test "${enable_keep_packaged_modules+set}" = set; then : 24280 enableval=$enable_keep_packaged_modules; 24281 fi 24282 24283 24284 if test "x$enable_keep_packaged_modules" = "xyes"; then 24285 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if packaged modules are kept" >&5 24286 $as_echo_n "checking if packaged modules are kept... " >&6; } 24287 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 24288 $as_echo "yes" >&6; } 24289 JLINK_KEEP_PACKAGED_MODULES=true 24290 elif test "x$enable_keep_packaged_modules" = "xno"; then 24291 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if packaged modules are kept" >&5 24292 $as_echo_n "checking if packaged modules are kept... " >&6; } 24293 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 24294 $as_echo "no" >&6; } 24295 JLINK_KEEP_PACKAGED_MODULES=false 24296 elif test "x$enable_keep_packaged_modules" = "x"; then 24297 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes (default)" >&5 24298 $as_echo "yes (default)" >&6; } 24299 JLINK_KEEP_PACKAGED_MODULES=true 24300 else 24301 as_fn_error $? "--enable-keep-packaged-modules accepts no argument" "$LINENO" 5 24302 fi 24303 24304 24305 24306 24307 # Warn user that old version arguments are deprecated. 24308 24309 24310 # Check whether --with-milestone was given. 24311 if test "${with_milestone+set}" = set; then : 24312 withval=$with_milestone; { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Option --with-milestone is deprecated and will be ignored." >&5 24313 $as_echo "$as_me: WARNING: Option --with-milestone is deprecated and will be ignored." >&2;} 24314 fi 24315 24316 24317 24318 24319 # Check whether --with-update-version was given. 24320 if test "${with_update_version+set}" = set; then : 24321 withval=$with_update_version; { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Option --with-update-version is deprecated and will be ignored." >&5 24322 $as_echo "$as_me: WARNING: Option --with-update-version is deprecated and will be ignored." >&2;} 24323 fi 24324 24325 24326 24327 24328 # Check whether --with-user-release-suffix was given. 24329 if test "${with_user_release_suffix+set}" = set; then : 24330 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 24331 $as_echo "$as_me: WARNING: Option --with-user-release-suffix is deprecated and will be ignored." >&2;} 24332 fi 24333 24334 24335 24336 24337 # Check whether --with-build-number was given. 24338 if test "${with_build_number+set}" = set; then : 24339 withval=$with_build_number; { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Option --with-build-number is deprecated and will be ignored." >&5 24340 $as_echo "$as_me: WARNING: Option --with-build-number is deprecated and will be ignored." >&2;} 24341 fi 24342 24343 24344 24345 # Source the version numbers file 24346 . $AUTOCONF_DIR/version-numbers 24347 24348 # Some non-version number information is set in that file 24349 24350 24351 24352 24353 24354 24355 24356 24357 24358 # Override version from arguments 24359 24360 # If --with-version-string is set, process it first. It is possible to 24361 # override parts with more specific flags, since these are processed later. 24362 24363 # Check whether --with-version-string was given. 24364 if test "${with_version_string+set}" = set; then : 24365 withval=$with_version_string; 24366 fi 24367 24368 if test "x$with_version_string" = xyes; then 24369 as_fn_error $? "--with-version-string must have a value" "$LINENO" 5 24370 elif test "x$with_version_string" != x; then 24371 # Additional [] needed to keep m4 from mangling shell constructs. 24372 if [[ $with_version_string =~ ^([0-9]+)(\.([0-9]+))?(\.([0-9]+))?(\.([0-9]+))?(-([a-zA-Z]+))?((\+)([0-9]+)?(-([-a-zA-Z0-9.]+))?)?$ ]] ; then 24373 VERSION_MAJOR=${BASH_REMATCH[1]} 24374 VERSION_MINOR=${BASH_REMATCH[3]} 24375 VERSION_SECURITY=${BASH_REMATCH[5]} 24376 VERSION_PATCH=${BASH_REMATCH[7]} 24377 VERSION_PRE=${BASH_REMATCH[9]} 24378 version_plus_separator=${BASH_REMATCH[11]} 24379 VERSION_BUILD=${BASH_REMATCH[12]} 24380 VERSION_OPT=${BASH_REMATCH[14]} 24381 # Unspecified numerical fields are interpreted as 0. 24382 if test "x$VERSION_MINOR" = x; then 24383 VERSION_MINOR=0 24384 fi 24385 if test "x$VERSION_SECURITY" = x; then 24386 VERSION_SECURITY=0 24387 fi 24388 if test "x$VERSION_PATCH" = x; then 24389 VERSION_PATCH=0 24390 fi 24391 if test "x$version_plus_separator" != x \ 24392 && test "x$VERSION_BUILD$VERSION_OPT" = x; then 24393 as_fn_error $? "Version string contains + but both 'BUILD' and 'OPT' are missing" "$LINENO" 5 24394 fi 24395 # Stop the version part process from setting default values. 24396 # We still allow them to explicitely override though. 24397 NO_DEFAULT_VERSION_PARTS=true 24398 else 24399 as_fn_error $? "--with-version-string fails to parse as a valid version string: $with_version_string" "$LINENO" 5 24400 fi 24401 fi 24402 24403 24404 # Check whether --with-version-pre was given. 24405 if test "${with_version_pre+set}" = set; then : 24406 withval=$with_version_pre; with_version_pre_present=true 24407 else 24408 with_version_pre_present=false 24409 fi 24410 24411 24412 if test "x$with_version_pre_present" = xtrue; then 24413 if test "x$with_version_pre" = xyes; then 24414 as_fn_error $? "--with-version-pre must have a value" "$LINENO" 5 24415 elif test "x$with_version_pre" = xno; then 24416 # Interpret --without-* as empty string instead of the literal "no" 24417 VERSION_PRE= 24418 else 24419 # Only [a-zA-Z] is allowed in the VERSION_PRE. Outer [ ] to quote m4. 24420 VERSION_PRE=`$ECHO "$with_version_pre" | $TR -c -d '[a-z][A-Z]'` 24421 if test "x$VERSION_PRE" != "x$with_version_pre"; then 24422 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: --with-version-pre value has been sanitized from '$with_version_pre' to '$VERSION_PRE'" >&5 24423 $as_echo "$as_me: WARNING: --with-version-pre value has been sanitized from '$with_version_pre' to '$VERSION_PRE'" >&2;} 24424 fi 24425 fi 24426 else 24427 if test "x$NO_DEFAULT_VERSION_PARTS" != xtrue; then 24428 # Default is to use "internal" as pre 24429 VERSION_PRE="internal" 24430 fi 24431 fi 24432 24433 24434 # Check whether --with-version-opt was given. 24435 if test "${with_version_opt+set}" = set; then : 24436 withval=$with_version_opt; with_version_opt_present=true 24437 else 24438 with_version_opt_present=false 24439 fi 24440 24441 24442 if test "x$with_version_opt_present" = xtrue; then 24443 if test "x$with_version_opt" = xyes; then 24444 as_fn_error $? "--with-version-opt must have a value" "$LINENO" 5 24445 elif test "x$with_version_opt" = xno; then 24446 # Interpret --without-* as empty string instead of the literal "no" 24447 VERSION_OPT= 24448 else 24449 # Only [-.a-zA-Z0-9] is allowed in the VERSION_OPT. Outer [ ] to quote m4. 24450 VERSION_OPT=`$ECHO "$with_version_opt" | $TR -c -d '[a-z][A-Z][0-9].-'` 24451 if test "x$VERSION_OPT" != "x$with_version_opt"; then 24452 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: --with-version-opt value has been sanitized from '$with_version_opt' to '$VERSION_OPT'" >&5 24453 $as_echo "$as_me: WARNING: --with-version-opt value has been sanitized from '$with_version_opt' to '$VERSION_OPT'" >&2;} 24454 fi 24455 fi 24456 else 24457 if test "x$NO_DEFAULT_VERSION_PARTS" != xtrue; then 24458 # Default is to calculate a string like this <timestamp>.<username>.<base dir name> 24459 timestamp=`$DATE '+%Y-%m-%d-%H%M%S'` 24460 # Outer [ ] to quote m4. 24461 basedirname=`$BASENAME "$TOPDIR" | $TR -d -c '[a-z][A-Z][0-9].-'` 24462 VERSION_OPT="$timestamp.$USERNAME.$basedirname" 24463 fi 24464 fi 24465 24466 24467 # Check whether --with-version-build was given. 24468 if test "${with_version_build+set}" = set; then : 24469 withval=$with_version_build; with_version_build_present=true 24470 else 24471 with_version_build_present=false 24472 fi 24473 24474 24475 if test "x$with_version_build_present" = xtrue; then 24476 if test "x$with_version_build" = xyes; then 24477 as_fn_error $? "--with-version-build must have a value" "$LINENO" 5 24478 elif test "x$with_version_build" = xno; then 24479 # Interpret --without-* as empty string instead of the literal "no" 24480 VERSION_BUILD= 24481 elif test "x$with_version_build" = x; then 24482 VERSION_BUILD= 24483 else 24484 24485 # Additional [] needed to keep m4 from mangling shell constructs. 24486 if ! [[ "$with_version_build" =~ ^0*([1-9][0-9]*)|(0)$ ]] ; then 24487 as_fn_error $? "\"$with_version_build\" is not a valid numerical value for VERSION_BUILD" "$LINENO" 5 24488 fi 24489 # Extract the version number without leading zeros. 24490 cleaned_value=${BASH_REMATCH[1]} 24491 if test "x$cleaned_value" = x; then 24492 # Special case for zero 24493 cleaned_value=${BASH_REMATCH[2]} 24494 fi 24495 24496 if test $cleaned_value -gt 255; then 24497 as_fn_error $? "VERSION_BUILD is given as $with_version_build. This is greater than 255 which is not allowed." "$LINENO" 5 24498 fi 24499 if test "x$cleaned_value" != "x$with_version_build"; then 24500 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Value for VERSION_BUILD has been sanitized from '$with_version_build' to '$cleaned_value'" >&5 24501 $as_echo "$as_me: WARNING: Value for VERSION_BUILD has been sanitized from '$with_version_build' to '$cleaned_value'" >&2;} 24502 fi 24503 VERSION_BUILD=$cleaned_value 24504 24505 fi 24506 else 24507 if test "x$NO_DEFAULT_VERSION_PARTS" != xtrue; then 24508 # Default is to not have a build number. 24509 VERSION_BUILD="" 24510 # FIXME: Until all code can cope with an empty VERSION_BUILD, set it to 0. 24511 VERSION_BUILD=0 24512 fi 24513 fi 24514 24515 24516 # Check whether --with-version-major was given. 24517 if test "${with_version_major+set}" = set; then : 24518 withval=$with_version_major; with_version_major_present=true 24519 else 24520 with_version_major_present=false 24521 fi 24522 24523 24524 if test "x$with_version_major_present" = xtrue; then 24525 if test "x$with_version_major" = xyes; then 24526 as_fn_error $? "--with-version-major must have a value" "$LINENO" 5 24527 else 24528 24529 # Additional [] needed to keep m4 from mangling shell constructs. 24530 if ! [[ "$with_version_major" =~ ^0*([1-9][0-9]*)|(0)$ ]] ; then 24531 as_fn_error $? "\"$with_version_major\" is not a valid numerical value for VERSION_MAJOR" "$LINENO" 5 24532 fi 24533 # Extract the version number without leading zeros. 24534 cleaned_value=${BASH_REMATCH[1]} 24535 if test "x$cleaned_value" = x; then 24536 # Special case for zero 24537 cleaned_value=${BASH_REMATCH[2]} 24538 fi 24539 24540 if test $cleaned_value -gt 255; then 24541 as_fn_error $? "VERSION_MAJOR is given as $with_version_major. This is greater than 255 which is not allowed." "$LINENO" 5 24542 fi 24543 if test "x$cleaned_value" != "x$with_version_major"; then 24544 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Value for VERSION_MAJOR has been sanitized from '$with_version_major' to '$cleaned_value'" >&5 24545 $as_echo "$as_me: WARNING: Value for VERSION_MAJOR has been sanitized from '$with_version_major' to '$cleaned_value'" >&2;} 24546 fi 24547 VERSION_MAJOR=$cleaned_value 24548 24549 fi 24550 else 24551 if test "x$NO_DEFAULT_VERSION_PARTS" != xtrue; then 24552 # Default is to get value from version-numbers 24553 VERSION_MAJOR="$DEFAULT_VERSION_MAJOR" 24554 fi 24555 fi 24556 24557 24558 # Check whether --with-version-minor was given. 24559 if test "${with_version_minor+set}" = set; then : 24560 withval=$with_version_minor; with_version_minor_present=true 24561 else 24562 with_version_minor_present=false 24563 fi 24564 24565 24566 if test "x$with_version_minor_present" = xtrue; then 24567 if test "x$with_version_minor" = xyes; then 24568 as_fn_error $? "--with-version-minor must have a value" "$LINENO" 5 24569 elif test "x$with_version_minor" = xno; then 24570 # Interpret --without-* as empty string (i.e. 0) instead of the literal "no" 24571 VERSION_MINOR=0 24572 elif test "x$with_version_minor" = x; then 24573 VERSION_MINOR=0 24574 else 24575 24576 # Additional [] needed to keep m4 from mangling shell constructs. 24577 if ! [[ "$with_version_minor" =~ ^0*([1-9][0-9]*)|(0)$ ]] ; then 24578 as_fn_error $? "\"$with_version_minor\" is not a valid numerical value for VERSION_MINOR" "$LINENO" 5 24579 fi 24580 # Extract the version number without leading zeros. 24581 cleaned_value=${BASH_REMATCH[1]} 24582 if test "x$cleaned_value" = x; then 24583 # Special case for zero 24584 cleaned_value=${BASH_REMATCH[2]} 24585 fi 24586 24587 if test $cleaned_value -gt 255; then 24588 as_fn_error $? "VERSION_MINOR is given as $with_version_minor. This is greater than 255 which is not allowed." "$LINENO" 5 24589 fi 24590 if test "x$cleaned_value" != "x$with_version_minor"; then 24591 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Value for VERSION_MINOR has been sanitized from '$with_version_minor' to '$cleaned_value'" >&5 24592 $as_echo "$as_me: WARNING: Value for VERSION_MINOR has been sanitized from '$with_version_minor' to '$cleaned_value'" >&2;} 24593 fi 24594 VERSION_MINOR=$cleaned_value 24595 24596 fi 24597 else 24598 if test "x$NO_DEFAULT_VERSION_PARTS" != xtrue; then 24599 # Default is 0, if unspecified 24600 VERSION_MINOR=0 24601 fi 24602 fi 24603 24604 24605 # Check whether --with-version-security was given. 24606 if test "${with_version_security+set}" = set; then : 24607 withval=$with_version_security; with_version_security_present=true 24608 else 24609 with_version_security_present=false 24610 fi 24611 24612 24613 if test "x$with_version_security_present" = xtrue; then 24614 if test "x$with_version_security" = xyes; then 24615 as_fn_error $? "--with-version-security must have a value" "$LINENO" 5 24616 elif test "x$with_version_security" = xno; then 24617 # Interpret --without-* as empty string (i.e. 0) instead of the literal "no" 24618 VERSION_SECURITY=0 24619 elif test "x$with_version_security" = x; then 24620 VERSION_SECURITY=0 24621 else 24622 24623 # Additional [] needed to keep m4 from mangling shell constructs. 24624 if ! [[ "$with_version_security" =~ ^0*([1-9][0-9]*)|(0)$ ]] ; then 24625 as_fn_error $? "\"$with_version_security\" is not a valid numerical value for VERSION_SECURITY" "$LINENO" 5 24626 fi 24627 # Extract the version number without leading zeros. 24628 cleaned_value=${BASH_REMATCH[1]} 24629 if test "x$cleaned_value" = x; then 24630 # Special case for zero 24631 cleaned_value=${BASH_REMATCH[2]} 24632 fi 24633 24634 if test $cleaned_value -gt 255; then 24635 as_fn_error $? "VERSION_SECURITY is given as $with_version_security. This is greater than 255 which is not allowed." "$LINENO" 5 24636 fi 24637 if test "x$cleaned_value" != "x$with_version_security"; then 24638 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Value for VERSION_SECURITY has been sanitized from '$with_version_security' to '$cleaned_value'" >&5 24639 $as_echo "$as_me: WARNING: Value for VERSION_SECURITY has been sanitized from '$with_version_security' to '$cleaned_value'" >&2;} 24640 fi 24641 VERSION_SECURITY=$cleaned_value 24642 24643 fi 24644 else 24645 if test "x$NO_DEFAULT_VERSION_PARTS" != xtrue; then 24646 # Default is 0, if unspecified 24647 VERSION_SECURITY=0 24648 fi 24649 fi 24650 24651 24652 # Check whether --with-version-patch was given. 24653 if test "${with_version_patch+set}" = set; then : 24654 withval=$with_version_patch; with_version_patch_present=true 24655 else 24656 with_version_patch_present=false 24657 fi 24658 24659 24660 if test "x$with_version_patch_present" = xtrue; then 24661 if test "x$with_version_patch" = xyes; then 24662 as_fn_error $? "--with-version-patch must have a value" "$LINENO" 5 24663 elif test "x$with_version_patch" = xno; then 24664 # Interpret --without-* as empty string (i.e. 0) instead of the literal "no" 24665 VERSION_PATCH=0 24666 elif test "x$with_version_patch" = x; then 24667 VERSION_PATCH=0 24668 else 24669 24670 # Additional [] needed to keep m4 from mangling shell constructs. 24671 if ! [[ "$with_version_patch" =~ ^0*([1-9][0-9]*)|(0)$ ]] ; then 24672 as_fn_error $? "\"$with_version_patch\" is not a valid numerical value for VERSION_PATCH" "$LINENO" 5 24673 fi 24674 # Extract the version number without leading zeros. 24675 cleaned_value=${BASH_REMATCH[1]} 24676 if test "x$cleaned_value" = x; then 24677 # Special case for zero 24678 cleaned_value=${BASH_REMATCH[2]} 24679 fi 24680 24681 if test $cleaned_value -gt 255; then 24682 as_fn_error $? "VERSION_PATCH is given as $with_version_patch. This is greater than 255 which is not allowed." "$LINENO" 5 24683 fi 24684 if test "x$cleaned_value" != "x$with_version_patch"; then 24685 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Value for VERSION_PATCH has been sanitized from '$with_version_patch' to '$cleaned_value'" >&5 24686 $as_echo "$as_me: WARNING: Value for VERSION_PATCH has been sanitized from '$with_version_patch' to '$cleaned_value'" >&2;} 24687 fi 24688 VERSION_PATCH=$cleaned_value 24689 24690 fi 24691 else 24692 if test "x$NO_DEFAULT_VERSION_PARTS" != xtrue; then 24693 # Default is 0, if unspecified 24694 VERSION_PATCH=0 24695 fi 24696 fi 24697 24698 # Calculate derived version properties 24699 24700 # Set VERSION_IS_GA based on if VERSION_PRE has a value 24701 if test "x$VERSION_PRE" = x; then 24702 VERSION_IS_GA=true 24703 else 24704 VERSION_IS_GA=false 24705 fi 24706 24707 # VERSION_NUMBER but always with exactly 4 positions, with 0 for empty positions. 24708 VERSION_NUMBER_FOUR_POSITIONS=$VERSION_MAJOR.$VERSION_MINOR.$VERSION_SECURITY.$VERSION_PATCH 24709 24710 stripped_version_number=$VERSION_NUMBER_FOUR_POSITIONS 24711 # Strip trailing zeroes from stripped_version_number 24712 for i in 1 2 3 ; do stripped_version_number=${stripped_version_number%.0} ; done 24713 VERSION_NUMBER=$stripped_version_number 24714 24715 # The complete version string, with additional build information 24716 if test "x$VERSION_BUILD$VERSION_OPT" = x; then 24717 VERSION_STRING=$VERSION_NUMBER${VERSION_PRE:+-$VERSION_PRE} 24718 else 24719 # If either build or opt is set, we need a + separator 24720 VERSION_STRING=$VERSION_NUMBER${VERSION_PRE:+-$VERSION_PRE}+$VERSION_BUILD${VERSION_OPT:+-$VERSION_OPT} 24721 fi 24722 24723 # The short version string, just VERSION_NUMBER and PRE, if present. 24724 VERSION_SHORT=$VERSION_NUMBER${VERSION_PRE:+-$VERSION_PRE} 24725 24726 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for version string" >&5 24727 $as_echo_n "checking for version string... " >&6; } 24728 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $VERSION_STRING" >&5 24729 $as_echo "$VERSION_STRING" >&6; } 24730 24731 24732 24733 24734 24735 24736 24737 24738 24739 24740 24741 24742 24743 24744 24745 ############################################################################### 24746 # 24747 # Setup BootJDK, used to bootstrap the build. 24748 # 24749 ############################################################################### 24750 24751 24752 BOOT_JDK_FOUND=no 24753 24754 # Check whether --with-boot-jdk was given. 24755 if test "${with_boot_jdk+set}" = set; then : 24756 withval=$with_boot_jdk; 24757 fi 24758 24759 24760 # We look for the Boot JDK through various means, going from more certain to 24761 # more of a guess-work. After each test, BOOT_JDK_FOUND is set to "yes" if 24762 # we detected something (if so, the path to the jdk is in BOOT_JDK). But we 24763 # must check if this is indeed valid; otherwise we'll continue looking. 24764 24765 # Test: Is bootjdk explicitely set by command line arguments? 24766 24767 if test "x$BOOT_JDK_FOUND" = xno; then 24768 # Now execute the test 24769 24770 if test "x$with_boot_jdk" != x; then 24771 BOOT_JDK=$with_boot_jdk 24772 BOOT_JDK_FOUND=maybe 24773 { $as_echo "$as_me:${as_lineno-$LINENO}: Found potential Boot JDK using configure arguments" >&5 24774 $as_echo "$as_me: Found potential Boot JDK using configure arguments" >&6;} 24775 fi 24776 24777 24778 # If previous step claimed to have found a JDK, check it to see if it seems to be valid. 24779 if test "x$BOOT_JDK_FOUND" = xmaybe; then 24780 # Do we have a bin/java? 24781 if test ! -x "$BOOT_JDK/bin/java"; then 24782 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&5 24783 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&6;} 24784 BOOT_JDK_FOUND=no 24785 else 24786 # Do we have a bin/javac? 24787 if test ! -x "$BOOT_JDK/bin/javac"; then 24788 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&5 24789 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&6;} 24790 { $as_echo "$as_me:${as_lineno-$LINENO}: (This might be an JRE instead of an JDK)" >&5 24791 $as_echo "$as_me: (This might be an JRE instead of an JDK)" >&6;} 24792 BOOT_JDK_FOUND=no 24793 else 24794 # Oh, this is looking good! We probably have found a proper JDK. Is it the correct version? 24795 BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | $HEAD -n 1` 24796 24797 # Extra M4 quote needed to protect [] in grep expression. 24798 FOUND_CORRECT_VERSION=`$ECHO $BOOT_JDK_VERSION | $EGREP '\"9([\.+-].*)?\"|(1\.[89]\.)'` 24799 if test "x$FOUND_CORRECT_VERSION" = x; then 24800 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&5 24801 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&6;} 24802 { $as_echo "$as_me:${as_lineno-$LINENO}: (Your Boot JDK must be version 8 or 9)" >&5 24803 $as_echo "$as_me: (Your Boot JDK must be version 8 or 9)" >&6;} 24804 BOOT_JDK_FOUND=no 24805 else 24806 # We're done! :-) 24807 BOOT_JDK_FOUND=yes 24808 24809 # Only process if variable expands to non-empty 24810 24811 if test "x$BOOT_JDK" != x; then 24812 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 24813 24814 # Input might be given as Windows format, start by converting to 24815 # unix format. 24816 path="$BOOT_JDK" 24817 new_path=`$CYGPATH -u "$path"` 24818 24819 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 24820 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 24821 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 24822 # "foo.exe" is OK but "foo" is an error. 24823 # 24824 # This test is therefore slightly more accurate than "test -f" to check for file precense. 24825 # It is also a way to make sure we got the proper file name for the real test later on. 24826 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 24827 if test "x$test_shortpath" = x; then 24828 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5 24829 $as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;} 24830 as_fn_error $? "Cannot locate the the path of BOOT_JDK" "$LINENO" 5 24831 fi 24832 24833 # Call helper function which possibly converts this using DOS-style short mode. 24834 # If so, the updated path is stored in $new_path. 24835 24836 input_path="$new_path" 24837 # Check if we need to convert this using DOS-style short mode. If the path 24838 # contains just simple characters, use it. Otherwise (spaces, weird characters), 24839 # take no chances and rewrite it. 24840 # Note: m4 eats our [], so we need to use [ and ] instead. 24841 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 24842 if test "x$has_forbidden_chars" != x; then 24843 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 24844 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 24845 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 24846 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 24847 # Going to short mode and back again did indeed matter. Since short mode is 24848 # case insensitive, let's make it lowercase to improve readability. 24849 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 24850 # Now convert it back to Unix-style (cygpath) 24851 input_path=`$CYGPATH -u "$shortmode_path"` 24852 new_path="$input_path" 24853 fi 24854 fi 24855 24856 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 24857 if test "x$test_cygdrive_prefix" = x; then 24858 # As a simple fix, exclude /usr/bin since it's not a real path. 24859 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 24860 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 24861 # a path prefixed by /cygdrive for fixpath to work. 24862 new_path="$CYGWIN_ROOT_PATH$input_path" 24863 fi 24864 fi 24865 24866 24867 if test "x$path" != "x$new_path"; then 24868 BOOT_JDK="$new_path" 24869 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5 24870 $as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;} 24871 fi 24872 24873 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 24874 24875 path="$BOOT_JDK" 24876 has_colon=`$ECHO $path | $GREP ^.:` 24877 new_path="$path" 24878 if test "x$has_colon" = x; then 24879 # Not in mixed or Windows style, start by that. 24880 new_path=`cmd //c echo $path` 24881 fi 24882 24883 24884 input_path="$new_path" 24885 # Check if we need to convert this using DOS-style short mode. If the path 24886 # contains just simple characters, use it. Otherwise (spaces, weird characters), 24887 # take no chances and rewrite it. 24888 # Note: m4 eats our [], so we need to use [ and ] instead. 24889 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 24890 if test "x$has_forbidden_chars" != x; then 24891 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 24892 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 24893 fi 24894 24895 24896 windows_path="$new_path" 24897 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 24898 unix_path=`$CYGPATH -u "$windows_path"` 24899 new_path="$unix_path" 24900 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 24901 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 24902 new_path="$unix_path" 24903 fi 24904 24905 if test "x$path" != "x$new_path"; then 24906 BOOT_JDK="$new_path" 24907 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5 24908 $as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;} 24909 fi 24910 24911 # Save the first 10 bytes of this path to the storage, so fixpath can work. 24912 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 24913 24914 else 24915 # We're on a unix platform. Hooray! :) 24916 path="$BOOT_JDK" 24917 has_space=`$ECHO "$path" | $GREP " "` 24918 if test "x$has_space" != x; then 24919 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5 24920 $as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;} 24921 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 24922 fi 24923 24924 # Use eval to expand a potential ~ 24925 eval path="$path" 24926 if test ! -f "$path" && test ! -d "$path"; then 24927 as_fn_error $? "The path of BOOT_JDK, which resolves as \"$path\", is not found." "$LINENO" 5 24928 fi 24929 24930 if test -d "$path"; then 24931 BOOT_JDK="`cd "$path"; $THEPWDCMD -L`" 24932 else 24933 dir="`$DIRNAME "$path"`" 24934 base="`$BASENAME "$path"`" 24935 BOOT_JDK="`cd "$dir"; $THEPWDCMD -L`/$base" 24936 fi 24937 fi 24938 fi 24939 24940 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for Boot JDK" >&5 24941 $as_echo_n "checking for Boot JDK... " >&6; } 24942 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK" >&5 24943 $as_echo "$BOOT_JDK" >&6; } 24944 { $as_echo "$as_me:${as_lineno-$LINENO}: checking Boot JDK version" >&5 24945 $as_echo_n "checking Boot JDK version... " >&6; } 24946 BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | $TR '\n\r' ' '` 24947 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK_VERSION" >&5 24948 $as_echo "$BOOT_JDK_VERSION" >&6; } 24949 fi # end check jdk version 24950 fi # end check javac 24951 fi # end check java 24952 fi # end check boot jdk found 24953 fi 24954 24955 if test "x$with_boot_jdk" != x && test "x$BOOT_JDK_FOUND" = xno; then 24956 # Having specified an argument which is incorrect will produce an instant failure; 24957 # we should not go on looking 24958 as_fn_error $? "The path given by --with-boot-jdk does not contain a valid Boot JDK" "$LINENO" 5 24959 fi 24960 24961 # Test: On MacOS X, can we find a boot jdk using /usr/libexec/java_home? 24962 24963 if test "x$BOOT_JDK_FOUND" = xno; then 24964 # Now execute the test 24965 24966 if test "x$OPENJDK_TARGET_OS" = xmacosx; then 24967 # First check at user selected default 24968 24969 if test "x$BOOT_JDK_FOUND" = xno; then 24970 # Now execute the test 24971 24972 if test -x /usr/libexec/java_home; then 24973 BOOT_JDK=`/usr/libexec/java_home ` 24974 BOOT_JDK_FOUND=maybe 24975 { $as_echo "$as_me:${as_lineno-$LINENO}: Found potential Boot JDK using /usr/libexec/java_home " >&5 24976 $as_echo "$as_me: Found potential Boot JDK using /usr/libexec/java_home " >&6;} 24977 fi 24978 24979 24980 # If previous step claimed to have found a JDK, check it to see if it seems to be valid. 24981 if test "x$BOOT_JDK_FOUND" = xmaybe; then 24982 # Do we have a bin/java? 24983 if test ! -x "$BOOT_JDK/bin/java"; then 24984 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&5 24985 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&6;} 24986 BOOT_JDK_FOUND=no 24987 else 24988 # Do we have a bin/javac? 24989 if test ! -x "$BOOT_JDK/bin/javac"; then 24990 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&5 24991 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&6;} 24992 { $as_echo "$as_me:${as_lineno-$LINENO}: (This might be an JRE instead of an JDK)" >&5 24993 $as_echo "$as_me: (This might be an JRE instead of an JDK)" >&6;} 24994 BOOT_JDK_FOUND=no 24995 else 24996 # Oh, this is looking good! We probably have found a proper JDK. Is it the correct version? 24997 BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | $HEAD -n 1` 24998 24999 # Extra M4 quote needed to protect [] in grep expression. 25000 FOUND_CORRECT_VERSION=`$ECHO $BOOT_JDK_VERSION | $EGREP '\"9([\.+-].*)?\"|(1\.[89]\.)'` 25001 if test "x$FOUND_CORRECT_VERSION" = x; then 25002 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&5 25003 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&6;} 25004 { $as_echo "$as_me:${as_lineno-$LINENO}: (Your Boot JDK must be version 8 or 9)" >&5 25005 $as_echo "$as_me: (Your Boot JDK must be version 8 or 9)" >&6;} 25006 BOOT_JDK_FOUND=no 25007 else 25008 # We're done! :-) 25009 BOOT_JDK_FOUND=yes 25010 25011 # Only process if variable expands to non-empty 25012 25013 if test "x$BOOT_JDK" != x; then 25014 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 25015 25016 # Input might be given as Windows format, start by converting to 25017 # unix format. 25018 path="$BOOT_JDK" 25019 new_path=`$CYGPATH -u "$path"` 25020 25021 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 25022 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 25023 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 25024 # "foo.exe" is OK but "foo" is an error. 25025 # 25026 # This test is therefore slightly more accurate than "test -f" to check for file precense. 25027 # It is also a way to make sure we got the proper file name for the real test later on. 25028 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 25029 if test "x$test_shortpath" = x; then 25030 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5 25031 $as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;} 25032 as_fn_error $? "Cannot locate the the path of BOOT_JDK" "$LINENO" 5 25033 fi 25034 25035 # Call helper function which possibly converts this using DOS-style short mode. 25036 # If so, the updated path is stored in $new_path. 25037 25038 input_path="$new_path" 25039 # Check if we need to convert this using DOS-style short mode. If the path 25040 # contains just simple characters, use it. Otherwise (spaces, weird characters), 25041 # take no chances and rewrite it. 25042 # Note: m4 eats our [], so we need to use [ and ] instead. 25043 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 25044 if test "x$has_forbidden_chars" != x; then 25045 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 25046 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 25047 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 25048 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 25049 # Going to short mode and back again did indeed matter. Since short mode is 25050 # case insensitive, let's make it lowercase to improve readability. 25051 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 25052 # Now convert it back to Unix-style (cygpath) 25053 input_path=`$CYGPATH -u "$shortmode_path"` 25054 new_path="$input_path" 25055 fi 25056 fi 25057 25058 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 25059 if test "x$test_cygdrive_prefix" = x; then 25060 # As a simple fix, exclude /usr/bin since it's not a real path. 25061 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 25062 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 25063 # a path prefixed by /cygdrive for fixpath to work. 25064 new_path="$CYGWIN_ROOT_PATH$input_path" 25065 fi 25066 fi 25067 25068 25069 if test "x$path" != "x$new_path"; then 25070 BOOT_JDK="$new_path" 25071 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5 25072 $as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;} 25073 fi 25074 25075 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 25076 25077 path="$BOOT_JDK" 25078 has_colon=`$ECHO $path | $GREP ^.:` 25079 new_path="$path" 25080 if test "x$has_colon" = x; then 25081 # Not in mixed or Windows style, start by that. 25082 new_path=`cmd //c echo $path` 25083 fi 25084 25085 25086 input_path="$new_path" 25087 # Check if we need to convert this using DOS-style short mode. If the path 25088 # contains just simple characters, use it. Otherwise (spaces, weird characters), 25089 # take no chances and rewrite it. 25090 # Note: m4 eats our [], so we need to use [ and ] instead. 25091 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 25092 if test "x$has_forbidden_chars" != x; then 25093 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 25094 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 25095 fi 25096 25097 25098 windows_path="$new_path" 25099 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 25100 unix_path=`$CYGPATH -u "$windows_path"` 25101 new_path="$unix_path" 25102 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 25103 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 25104 new_path="$unix_path" 25105 fi 25106 25107 if test "x$path" != "x$new_path"; then 25108 BOOT_JDK="$new_path" 25109 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5 25110 $as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;} 25111 fi 25112 25113 # Save the first 10 bytes of this path to the storage, so fixpath can work. 25114 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 25115 25116 else 25117 # We're on a unix platform. Hooray! :) 25118 path="$BOOT_JDK" 25119 has_space=`$ECHO "$path" | $GREP " "` 25120 if test "x$has_space" != x; then 25121 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5 25122 $as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;} 25123 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 25124 fi 25125 25126 # Use eval to expand a potential ~ 25127 eval path="$path" 25128 if test ! -f "$path" && test ! -d "$path"; then 25129 as_fn_error $? "The path of BOOT_JDK, which resolves as \"$path\", is not found." "$LINENO" 5 25130 fi 25131 25132 if test -d "$path"; then 25133 BOOT_JDK="`cd "$path"; $THEPWDCMD -L`" 25134 else 25135 dir="`$DIRNAME "$path"`" 25136 base="`$BASENAME "$path"`" 25137 BOOT_JDK="`cd "$dir"; $THEPWDCMD -L`/$base" 25138 fi 25139 fi 25140 fi 25141 25142 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for Boot JDK" >&5 25143 $as_echo_n "checking for Boot JDK... " >&6; } 25144 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK" >&5 25145 $as_echo "$BOOT_JDK" >&6; } 25146 { $as_echo "$as_me:${as_lineno-$LINENO}: checking Boot JDK version" >&5 25147 $as_echo_n "checking Boot JDK version... " >&6; } 25148 BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | $TR '\n\r' ' '` 25149 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK_VERSION" >&5 25150 $as_echo "$BOOT_JDK_VERSION" >&6; } 25151 fi # end check jdk version 25152 fi # end check javac 25153 fi # end check java 25154 fi # end check boot jdk found 25155 fi 25156 25157 # If that did not work out (e.g. too old), try explicit versions instead 25158 25159 if test "x$BOOT_JDK_FOUND" = xno; then 25160 # Now execute the test 25161 25162 if test -x /usr/libexec/java_home; then 25163 BOOT_JDK=`/usr/libexec/java_home -v 1.9` 25164 BOOT_JDK_FOUND=maybe 25165 { $as_echo "$as_me:${as_lineno-$LINENO}: Found potential Boot JDK using /usr/libexec/java_home -v 1.9" >&5 25166 $as_echo "$as_me: Found potential Boot JDK using /usr/libexec/java_home -v 1.9" >&6;} 25167 fi 25168 25169 25170 # If previous step claimed to have found a JDK, check it to see if it seems to be valid. 25171 if test "x$BOOT_JDK_FOUND" = xmaybe; then 25172 # Do we have a bin/java? 25173 if test ! -x "$BOOT_JDK/bin/java"; then 25174 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&5 25175 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&6;} 25176 BOOT_JDK_FOUND=no 25177 else 25178 # Do we have a bin/javac? 25179 if test ! -x "$BOOT_JDK/bin/javac"; then 25180 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&5 25181 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&6;} 25182 { $as_echo "$as_me:${as_lineno-$LINENO}: (This might be an JRE instead of an JDK)" >&5 25183 $as_echo "$as_me: (This might be an JRE instead of an JDK)" >&6;} 25184 BOOT_JDK_FOUND=no 25185 else 25186 # Oh, this is looking good! We probably have found a proper JDK. Is it the correct version? 25187 BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | $HEAD -n 1` 25188 25189 # Extra M4 quote needed to protect [] in grep expression. 25190 FOUND_CORRECT_VERSION=`$ECHO $BOOT_JDK_VERSION | $EGREP '\"9([\.+-].*)?\"|(1\.[89]\.)'` 25191 if test "x$FOUND_CORRECT_VERSION" = x; then 25192 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&5 25193 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&6;} 25194 { $as_echo "$as_me:${as_lineno-$LINENO}: (Your Boot JDK must be version 8 or 9)" >&5 25195 $as_echo "$as_me: (Your Boot JDK must be version 8 or 9)" >&6;} 25196 BOOT_JDK_FOUND=no 25197 else 25198 # We're done! :-) 25199 BOOT_JDK_FOUND=yes 25200 25201 # Only process if variable expands to non-empty 25202 25203 if test "x$BOOT_JDK" != x; then 25204 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 25205 25206 # Input might be given as Windows format, start by converting to 25207 # unix format. 25208 path="$BOOT_JDK" 25209 new_path=`$CYGPATH -u "$path"` 25210 25211 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 25212 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 25213 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 25214 # "foo.exe" is OK but "foo" is an error. 25215 # 25216 # This test is therefore slightly more accurate than "test -f" to check for file precense. 25217 # It is also a way to make sure we got the proper file name for the real test later on. 25218 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 25219 if test "x$test_shortpath" = x; then 25220 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5 25221 $as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;} 25222 as_fn_error $? "Cannot locate the the path of BOOT_JDK" "$LINENO" 5 25223 fi 25224 25225 # Call helper function which possibly converts this using DOS-style short mode. 25226 # If so, the updated path is stored in $new_path. 25227 25228 input_path="$new_path" 25229 # Check if we need to convert this using DOS-style short mode. If the path 25230 # contains just simple characters, use it. Otherwise (spaces, weird characters), 25231 # take no chances and rewrite it. 25232 # Note: m4 eats our [], so we need to use [ and ] instead. 25233 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 25234 if test "x$has_forbidden_chars" != x; then 25235 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 25236 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 25237 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 25238 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 25239 # Going to short mode and back again did indeed matter. Since short mode is 25240 # case insensitive, let's make it lowercase to improve readability. 25241 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 25242 # Now convert it back to Unix-style (cygpath) 25243 input_path=`$CYGPATH -u "$shortmode_path"` 25244 new_path="$input_path" 25245 fi 25246 fi 25247 25248 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 25249 if test "x$test_cygdrive_prefix" = x; then 25250 # As a simple fix, exclude /usr/bin since it's not a real path. 25251 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 25252 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 25253 # a path prefixed by /cygdrive for fixpath to work. 25254 new_path="$CYGWIN_ROOT_PATH$input_path" 25255 fi 25256 fi 25257 25258 25259 if test "x$path" != "x$new_path"; then 25260 BOOT_JDK="$new_path" 25261 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5 25262 $as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;} 25263 fi 25264 25265 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 25266 25267 path="$BOOT_JDK" 25268 has_colon=`$ECHO $path | $GREP ^.:` 25269 new_path="$path" 25270 if test "x$has_colon" = x; then 25271 # Not in mixed or Windows style, start by that. 25272 new_path=`cmd //c echo $path` 25273 fi 25274 25275 25276 input_path="$new_path" 25277 # Check if we need to convert this using DOS-style short mode. If the path 25278 # contains just simple characters, use it. Otherwise (spaces, weird characters), 25279 # take no chances and rewrite it. 25280 # Note: m4 eats our [], so we need to use [ and ] instead. 25281 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 25282 if test "x$has_forbidden_chars" != x; then 25283 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 25284 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 25285 fi 25286 25287 25288 windows_path="$new_path" 25289 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 25290 unix_path=`$CYGPATH -u "$windows_path"` 25291 new_path="$unix_path" 25292 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 25293 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 25294 new_path="$unix_path" 25295 fi 25296 25297 if test "x$path" != "x$new_path"; then 25298 BOOT_JDK="$new_path" 25299 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5 25300 $as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;} 25301 fi 25302 25303 # Save the first 10 bytes of this path to the storage, so fixpath can work. 25304 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 25305 25306 else 25307 # We're on a unix platform. Hooray! :) 25308 path="$BOOT_JDK" 25309 has_space=`$ECHO "$path" | $GREP " "` 25310 if test "x$has_space" != x; then 25311 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5 25312 $as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;} 25313 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 25314 fi 25315 25316 # Use eval to expand a potential ~ 25317 eval path="$path" 25318 if test ! -f "$path" && test ! -d "$path"; then 25319 as_fn_error $? "The path of BOOT_JDK, which resolves as \"$path\", is not found." "$LINENO" 5 25320 fi 25321 25322 if test -d "$path"; then 25323 BOOT_JDK="`cd "$path"; $THEPWDCMD -L`" 25324 else 25325 dir="`$DIRNAME "$path"`" 25326 base="`$BASENAME "$path"`" 25327 BOOT_JDK="`cd "$dir"; $THEPWDCMD -L`/$base" 25328 fi 25329 fi 25330 fi 25331 25332 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for Boot JDK" >&5 25333 $as_echo_n "checking for Boot JDK... " >&6; } 25334 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK" >&5 25335 $as_echo "$BOOT_JDK" >&6; } 25336 { $as_echo "$as_me:${as_lineno-$LINENO}: checking Boot JDK version" >&5 25337 $as_echo_n "checking Boot JDK version... " >&6; } 25338 BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | $TR '\n\r' ' '` 25339 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK_VERSION" >&5 25340 $as_echo "$BOOT_JDK_VERSION" >&6; } 25341 fi # end check jdk version 25342 fi # end check javac 25343 fi # end check java 25344 fi # end check boot jdk found 25345 fi 25346 25347 25348 if test "x$BOOT_JDK_FOUND" = xno; then 25349 # Now execute the test 25350 25351 if test -x /usr/libexec/java_home; then 25352 BOOT_JDK=`/usr/libexec/java_home -v 1.8` 25353 BOOT_JDK_FOUND=maybe 25354 { $as_echo "$as_me:${as_lineno-$LINENO}: Found potential Boot JDK using /usr/libexec/java_home -v 1.8" >&5 25355 $as_echo "$as_me: Found potential Boot JDK using /usr/libexec/java_home -v 1.8" >&6;} 25356 fi 25357 25358 25359 # If previous step claimed to have found a JDK, check it to see if it seems to be valid. 25360 if test "x$BOOT_JDK_FOUND" = xmaybe; then 25361 # Do we have a bin/java? 25362 if test ! -x "$BOOT_JDK/bin/java"; then 25363 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&5 25364 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&6;} 25365 BOOT_JDK_FOUND=no 25366 else 25367 # Do we have a bin/javac? 25368 if test ! -x "$BOOT_JDK/bin/javac"; then 25369 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&5 25370 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&6;} 25371 { $as_echo "$as_me:${as_lineno-$LINENO}: (This might be an JRE instead of an JDK)" >&5 25372 $as_echo "$as_me: (This might be an JRE instead of an JDK)" >&6;} 25373 BOOT_JDK_FOUND=no 25374 else 25375 # Oh, this is looking good! We probably have found a proper JDK. Is it the correct version? 25376 BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | $HEAD -n 1` 25377 25378 # Extra M4 quote needed to protect [] in grep expression. 25379 FOUND_CORRECT_VERSION=`$ECHO $BOOT_JDK_VERSION | $EGREP '\"9([\.+-].*)?\"|(1\.[89]\.)'` 25380 if test "x$FOUND_CORRECT_VERSION" = x; then 25381 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&5 25382 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&6;} 25383 { $as_echo "$as_me:${as_lineno-$LINENO}: (Your Boot JDK must be version 8 or 9)" >&5 25384 $as_echo "$as_me: (Your Boot JDK must be version 8 or 9)" >&6;} 25385 BOOT_JDK_FOUND=no 25386 else 25387 # We're done! :-) 25388 BOOT_JDK_FOUND=yes 25389 25390 # Only process if variable expands to non-empty 25391 25392 if test "x$BOOT_JDK" != x; then 25393 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 25394 25395 # Input might be given as Windows format, start by converting to 25396 # unix format. 25397 path="$BOOT_JDK" 25398 new_path=`$CYGPATH -u "$path"` 25399 25400 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 25401 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 25402 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 25403 # "foo.exe" is OK but "foo" is an error. 25404 # 25405 # This test is therefore slightly more accurate than "test -f" to check for file precense. 25406 # It is also a way to make sure we got the proper file name for the real test later on. 25407 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 25408 if test "x$test_shortpath" = x; then 25409 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5 25410 $as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;} 25411 as_fn_error $? "Cannot locate the the path of BOOT_JDK" "$LINENO" 5 25412 fi 25413 25414 # Call helper function which possibly converts this using DOS-style short mode. 25415 # If so, the updated path is stored in $new_path. 25416 25417 input_path="$new_path" 25418 # Check if we need to convert this using DOS-style short mode. If the path 25419 # contains just simple characters, use it. Otherwise (spaces, weird characters), 25420 # take no chances and rewrite it. 25421 # Note: m4 eats our [], so we need to use [ and ] instead. 25422 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 25423 if test "x$has_forbidden_chars" != x; then 25424 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 25425 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 25426 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 25427 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 25428 # Going to short mode and back again did indeed matter. Since short mode is 25429 # case insensitive, let's make it lowercase to improve readability. 25430 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 25431 # Now convert it back to Unix-style (cygpath) 25432 input_path=`$CYGPATH -u "$shortmode_path"` 25433 new_path="$input_path" 25434 fi 25435 fi 25436 25437 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 25438 if test "x$test_cygdrive_prefix" = x; then 25439 # As a simple fix, exclude /usr/bin since it's not a real path. 25440 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 25441 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 25442 # a path prefixed by /cygdrive for fixpath to work. 25443 new_path="$CYGWIN_ROOT_PATH$input_path" 25444 fi 25445 fi 25446 25447 25448 if test "x$path" != "x$new_path"; then 25449 BOOT_JDK="$new_path" 25450 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5 25451 $as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;} 25452 fi 25453 25454 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 25455 25456 path="$BOOT_JDK" 25457 has_colon=`$ECHO $path | $GREP ^.:` 25458 new_path="$path" 25459 if test "x$has_colon" = x; then 25460 # Not in mixed or Windows style, start by that. 25461 new_path=`cmd //c echo $path` 25462 fi 25463 25464 25465 input_path="$new_path" 25466 # Check if we need to convert this using DOS-style short mode. If the path 25467 # contains just simple characters, use it. Otherwise (spaces, weird characters), 25468 # take no chances and rewrite it. 25469 # Note: m4 eats our [], so we need to use [ and ] instead. 25470 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 25471 if test "x$has_forbidden_chars" != x; then 25472 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 25473 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 25474 fi 25475 25476 25477 windows_path="$new_path" 25478 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 25479 unix_path=`$CYGPATH -u "$windows_path"` 25480 new_path="$unix_path" 25481 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 25482 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 25483 new_path="$unix_path" 25484 fi 25485 25486 if test "x$path" != "x$new_path"; then 25487 BOOT_JDK="$new_path" 25488 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5 25489 $as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;} 25490 fi 25491 25492 # Save the first 10 bytes of this path to the storage, so fixpath can work. 25493 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 25494 25495 else 25496 # We're on a unix platform. Hooray! :) 25497 path="$BOOT_JDK" 25498 has_space=`$ECHO "$path" | $GREP " "` 25499 if test "x$has_space" != x; then 25500 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5 25501 $as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;} 25502 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 25503 fi 25504 25505 # Use eval to expand a potential ~ 25506 eval path="$path" 25507 if test ! -f "$path" && test ! -d "$path"; then 25508 as_fn_error $? "The path of BOOT_JDK, which resolves as \"$path\", is not found." "$LINENO" 5 25509 fi 25510 25511 if test -d "$path"; then 25512 BOOT_JDK="`cd "$path"; $THEPWDCMD -L`" 25513 else 25514 dir="`$DIRNAME "$path"`" 25515 base="`$BASENAME "$path"`" 25516 BOOT_JDK="`cd "$dir"; $THEPWDCMD -L`/$base" 25517 fi 25518 fi 25519 fi 25520 25521 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for Boot JDK" >&5 25522 $as_echo_n "checking for Boot JDK... " >&6; } 25523 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK" >&5 25524 $as_echo "$BOOT_JDK" >&6; } 25525 { $as_echo "$as_me:${as_lineno-$LINENO}: checking Boot JDK version" >&5 25526 $as_echo_n "checking Boot JDK version... " >&6; } 25527 BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | $TR '\n\r' ' '` 25528 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK_VERSION" >&5 25529 $as_echo "$BOOT_JDK_VERSION" >&6; } 25530 fi # end check jdk version 25531 fi # end check javac 25532 fi # end check java 25533 fi # end check boot jdk found 25534 fi 25535 25536 25537 if test "x$BOOT_JDK_FOUND" = xno; then 25538 # Now execute the test 25539 25540 if test -x /usr/libexec/java_home; then 25541 BOOT_JDK=`/usr/libexec/java_home -v 1.7` 25542 BOOT_JDK_FOUND=maybe 25543 { $as_echo "$as_me:${as_lineno-$LINENO}: Found potential Boot JDK using /usr/libexec/java_home -v 1.7" >&5 25544 $as_echo "$as_me: Found potential Boot JDK using /usr/libexec/java_home -v 1.7" >&6;} 25545 fi 25546 25547 25548 # If previous step claimed to have found a JDK, check it to see if it seems to be valid. 25549 if test "x$BOOT_JDK_FOUND" = xmaybe; then 25550 # Do we have a bin/java? 25551 if test ! -x "$BOOT_JDK/bin/java"; then 25552 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&5 25553 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&6;} 25554 BOOT_JDK_FOUND=no 25555 else 25556 # Do we have a bin/javac? 25557 if test ! -x "$BOOT_JDK/bin/javac"; then 25558 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&5 25559 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&6;} 25560 { $as_echo "$as_me:${as_lineno-$LINENO}: (This might be an JRE instead of an JDK)" >&5 25561 $as_echo "$as_me: (This might be an JRE instead of an JDK)" >&6;} 25562 BOOT_JDK_FOUND=no 25563 else 25564 # Oh, this is looking good! We probably have found a proper JDK. Is it the correct version? 25565 BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | $HEAD -n 1` 25566 25567 # Extra M4 quote needed to protect [] in grep expression. 25568 FOUND_CORRECT_VERSION=`$ECHO $BOOT_JDK_VERSION | $EGREP '\"9([\.+-].*)?\"|(1\.[89]\.)'` 25569 if test "x$FOUND_CORRECT_VERSION" = x; then 25570 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&5 25571 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&6;} 25572 { $as_echo "$as_me:${as_lineno-$LINENO}: (Your Boot JDK must be version 8 or 9)" >&5 25573 $as_echo "$as_me: (Your Boot JDK must be version 8 or 9)" >&6;} 25574 BOOT_JDK_FOUND=no 25575 else 25576 # We're done! :-) 25577 BOOT_JDK_FOUND=yes 25578 25579 # Only process if variable expands to non-empty 25580 25581 if test "x$BOOT_JDK" != x; then 25582 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 25583 25584 # Input might be given as Windows format, start by converting to 25585 # unix format. 25586 path="$BOOT_JDK" 25587 new_path=`$CYGPATH -u "$path"` 25588 25589 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 25590 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 25591 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 25592 # "foo.exe" is OK but "foo" is an error. 25593 # 25594 # This test is therefore slightly more accurate than "test -f" to check for file precense. 25595 # It is also a way to make sure we got the proper file name for the real test later on. 25596 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 25597 if test "x$test_shortpath" = x; then 25598 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5 25599 $as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;} 25600 as_fn_error $? "Cannot locate the the path of BOOT_JDK" "$LINENO" 5 25601 fi 25602 25603 # Call helper function which possibly converts this using DOS-style short mode. 25604 # If so, the updated path is stored in $new_path. 25605 25606 input_path="$new_path" 25607 # Check if we need to convert this using DOS-style short mode. If the path 25608 # contains just simple characters, use it. Otherwise (spaces, weird characters), 25609 # take no chances and rewrite it. 25610 # Note: m4 eats our [], so we need to use [ and ] instead. 25611 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 25612 if test "x$has_forbidden_chars" != x; then 25613 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 25614 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 25615 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 25616 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 25617 # Going to short mode and back again did indeed matter. Since short mode is 25618 # case insensitive, let's make it lowercase to improve readability. 25619 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 25620 # Now convert it back to Unix-style (cygpath) 25621 input_path=`$CYGPATH -u "$shortmode_path"` 25622 new_path="$input_path" 25623 fi 25624 fi 25625 25626 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 25627 if test "x$test_cygdrive_prefix" = x; then 25628 # As a simple fix, exclude /usr/bin since it's not a real path. 25629 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 25630 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 25631 # a path prefixed by /cygdrive for fixpath to work. 25632 new_path="$CYGWIN_ROOT_PATH$input_path" 25633 fi 25634 fi 25635 25636 25637 if test "x$path" != "x$new_path"; then 25638 BOOT_JDK="$new_path" 25639 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5 25640 $as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;} 25641 fi 25642 25643 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 25644 25645 path="$BOOT_JDK" 25646 has_colon=`$ECHO $path | $GREP ^.:` 25647 new_path="$path" 25648 if test "x$has_colon" = x; then 25649 # Not in mixed or Windows style, start by that. 25650 new_path=`cmd //c echo $path` 25651 fi 25652 25653 25654 input_path="$new_path" 25655 # Check if we need to convert this using DOS-style short mode. If the path 25656 # contains just simple characters, use it. Otherwise (spaces, weird characters), 25657 # take no chances and rewrite it. 25658 # Note: m4 eats our [], so we need to use [ and ] instead. 25659 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 25660 if test "x$has_forbidden_chars" != x; then 25661 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 25662 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 25663 fi 25664 25665 25666 windows_path="$new_path" 25667 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 25668 unix_path=`$CYGPATH -u "$windows_path"` 25669 new_path="$unix_path" 25670 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 25671 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 25672 new_path="$unix_path" 25673 fi 25674 25675 if test "x$path" != "x$new_path"; then 25676 BOOT_JDK="$new_path" 25677 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5 25678 $as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;} 25679 fi 25680 25681 # Save the first 10 bytes of this path to the storage, so fixpath can work. 25682 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 25683 25684 else 25685 # We're on a unix platform. Hooray! :) 25686 path="$BOOT_JDK" 25687 has_space=`$ECHO "$path" | $GREP " "` 25688 if test "x$has_space" != x; then 25689 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5 25690 $as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;} 25691 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 25692 fi 25693 25694 # Use eval to expand a potential ~ 25695 eval path="$path" 25696 if test ! -f "$path" && test ! -d "$path"; then 25697 as_fn_error $? "The path of BOOT_JDK, which resolves as \"$path\", is not found." "$LINENO" 5 25698 fi 25699 25700 if test -d "$path"; then 25701 BOOT_JDK="`cd "$path"; $THEPWDCMD -L`" 25702 else 25703 dir="`$DIRNAME "$path"`" 25704 base="`$BASENAME "$path"`" 25705 BOOT_JDK="`cd "$dir"; $THEPWDCMD -L`/$base" 25706 fi 25707 fi 25708 fi 25709 25710 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for Boot JDK" >&5 25711 $as_echo_n "checking for Boot JDK... " >&6; } 25712 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK" >&5 25713 $as_echo "$BOOT_JDK" >&6; } 25714 { $as_echo "$as_me:${as_lineno-$LINENO}: checking Boot JDK version" >&5 25715 $as_echo_n "checking Boot JDK version... " >&6; } 25716 BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | $TR '\n\r' ' '` 25717 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK_VERSION" >&5 25718 $as_echo "$BOOT_JDK_VERSION" >&6; } 25719 fi # end check jdk version 25720 fi # end check javac 25721 fi # end check java 25722 fi # end check boot jdk found 25723 fi 25724 25725 fi 25726 25727 25728 # If previous step claimed to have found a JDK, check it to see if it seems to be valid. 25729 if test "x$BOOT_JDK_FOUND" = xmaybe; then 25730 # Do we have a bin/java? 25731 if test ! -x "$BOOT_JDK/bin/java"; then 25732 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&5 25733 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&6;} 25734 BOOT_JDK_FOUND=no 25735 else 25736 # Do we have a bin/javac? 25737 if test ! -x "$BOOT_JDK/bin/javac"; then 25738 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&5 25739 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&6;} 25740 { $as_echo "$as_me:${as_lineno-$LINENO}: (This might be an JRE instead of an JDK)" >&5 25741 $as_echo "$as_me: (This might be an JRE instead of an JDK)" >&6;} 25742 BOOT_JDK_FOUND=no 25743 else 25744 # Oh, this is looking good! We probably have found a proper JDK. Is it the correct version? 25745 BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | $HEAD -n 1` 25746 25747 # Extra M4 quote needed to protect [] in grep expression. 25748 FOUND_CORRECT_VERSION=`$ECHO $BOOT_JDK_VERSION | $EGREP '\"9([\.+-].*)?\"|(1\.[89]\.)'` 25749 if test "x$FOUND_CORRECT_VERSION" = x; then 25750 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&5 25751 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&6;} 25752 { $as_echo "$as_me:${as_lineno-$LINENO}: (Your Boot JDK must be version 8 or 9)" >&5 25753 $as_echo "$as_me: (Your Boot JDK must be version 8 or 9)" >&6;} 25754 BOOT_JDK_FOUND=no 25755 else 25756 # We're done! :-) 25757 BOOT_JDK_FOUND=yes 25758 25759 # Only process if variable expands to non-empty 25760 25761 if test "x$BOOT_JDK" != x; then 25762 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 25763 25764 # Input might be given as Windows format, start by converting to 25765 # unix format. 25766 path="$BOOT_JDK" 25767 new_path=`$CYGPATH -u "$path"` 25768 25769 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 25770 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 25771 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 25772 # "foo.exe" is OK but "foo" is an error. 25773 # 25774 # This test is therefore slightly more accurate than "test -f" to check for file precense. 25775 # It is also a way to make sure we got the proper file name for the real test later on. 25776 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 25777 if test "x$test_shortpath" = x; then 25778 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5 25779 $as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;} 25780 as_fn_error $? "Cannot locate the the path of BOOT_JDK" "$LINENO" 5 25781 fi 25782 25783 # Call helper function which possibly converts this using DOS-style short mode. 25784 # If so, the updated path is stored in $new_path. 25785 25786 input_path="$new_path" 25787 # Check if we need to convert this using DOS-style short mode. If the path 25788 # contains just simple characters, use it. Otherwise (spaces, weird characters), 25789 # take no chances and rewrite it. 25790 # Note: m4 eats our [], so we need to use [ and ] instead. 25791 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 25792 if test "x$has_forbidden_chars" != x; then 25793 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 25794 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 25795 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 25796 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 25797 # Going to short mode and back again did indeed matter. Since short mode is 25798 # case insensitive, let's make it lowercase to improve readability. 25799 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 25800 # Now convert it back to Unix-style (cygpath) 25801 input_path=`$CYGPATH -u "$shortmode_path"` 25802 new_path="$input_path" 25803 fi 25804 fi 25805 25806 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 25807 if test "x$test_cygdrive_prefix" = x; then 25808 # As a simple fix, exclude /usr/bin since it's not a real path. 25809 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 25810 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 25811 # a path prefixed by /cygdrive for fixpath to work. 25812 new_path="$CYGWIN_ROOT_PATH$input_path" 25813 fi 25814 fi 25815 25816 25817 if test "x$path" != "x$new_path"; then 25818 BOOT_JDK="$new_path" 25819 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5 25820 $as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;} 25821 fi 25822 25823 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 25824 25825 path="$BOOT_JDK" 25826 has_colon=`$ECHO $path | $GREP ^.:` 25827 new_path="$path" 25828 if test "x$has_colon" = x; then 25829 # Not in mixed or Windows style, start by that. 25830 new_path=`cmd //c echo $path` 25831 fi 25832 25833 25834 input_path="$new_path" 25835 # Check if we need to convert this using DOS-style short mode. If the path 25836 # contains just simple characters, use it. Otherwise (spaces, weird characters), 25837 # take no chances and rewrite it. 25838 # Note: m4 eats our [], so we need to use [ and ] instead. 25839 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 25840 if test "x$has_forbidden_chars" != x; then 25841 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 25842 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 25843 fi 25844 25845 25846 windows_path="$new_path" 25847 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 25848 unix_path=`$CYGPATH -u "$windows_path"` 25849 new_path="$unix_path" 25850 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 25851 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 25852 new_path="$unix_path" 25853 fi 25854 25855 if test "x$path" != "x$new_path"; then 25856 BOOT_JDK="$new_path" 25857 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5 25858 $as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;} 25859 fi 25860 25861 # Save the first 10 bytes of this path to the storage, so fixpath can work. 25862 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 25863 25864 else 25865 # We're on a unix platform. Hooray! :) 25866 path="$BOOT_JDK" 25867 has_space=`$ECHO "$path" | $GREP " "` 25868 if test "x$has_space" != x; then 25869 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5 25870 $as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;} 25871 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 25872 fi 25873 25874 # Use eval to expand a potential ~ 25875 eval path="$path" 25876 if test ! -f "$path" && test ! -d "$path"; then 25877 as_fn_error $? "The path of BOOT_JDK, which resolves as \"$path\", is not found." "$LINENO" 5 25878 fi 25879 25880 if test -d "$path"; then 25881 BOOT_JDK="`cd "$path"; $THEPWDCMD -L`" 25882 else 25883 dir="`$DIRNAME "$path"`" 25884 base="`$BASENAME "$path"`" 25885 BOOT_JDK="`cd "$dir"; $THEPWDCMD -L`/$base" 25886 fi 25887 fi 25888 fi 25889 25890 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for Boot JDK" >&5 25891 $as_echo_n "checking for Boot JDK... " >&6; } 25892 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK" >&5 25893 $as_echo "$BOOT_JDK" >&6; } 25894 { $as_echo "$as_me:${as_lineno-$LINENO}: checking Boot JDK version" >&5 25895 $as_echo_n "checking Boot JDK version... " >&6; } 25896 BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | $TR '\n\r' ' '` 25897 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK_VERSION" >&5 25898 $as_echo "$BOOT_JDK_VERSION" >&6; } 25899 fi # end check jdk version 25900 fi # end check javac 25901 fi # end check java 25902 fi # end check boot jdk found 25903 fi 25904 25905 25906 # Test: Is $JAVA_HOME set? 25907 25908 if test "x$BOOT_JDK_FOUND" = xno; then 25909 # Now execute the test 25910 25911 if test "x$JAVA_HOME" != x; then 25912 JAVA_HOME_PROCESSED="$JAVA_HOME" 25913 25914 # Only process if variable expands to non-empty 25915 25916 if test "x$JAVA_HOME_PROCESSED" != x; then 25917 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 25918 25919 # Input might be given as Windows format, start by converting to 25920 # unix format. 25921 path="$JAVA_HOME_PROCESSED" 25922 new_path=`$CYGPATH -u "$path"` 25923 25924 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 25925 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 25926 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 25927 # "foo.exe" is OK but "foo" is an error. 25928 # 25929 # This test is therefore slightly more accurate than "test -f" to check for file precense. 25930 # It is also a way to make sure we got the proper file name for the real test later on. 25931 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 25932 if test "x$test_shortpath" = x; then 25933 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of JAVA_HOME_PROCESSED, which resolves as \"$path\", is invalid." >&5 25934 $as_echo "$as_me: The path of JAVA_HOME_PROCESSED, which resolves as \"$path\", is invalid." >&6;} 25935 as_fn_error $? "Cannot locate the the path of JAVA_HOME_PROCESSED" "$LINENO" 5 25936 fi 25937 25938 # Call helper function which possibly converts this using DOS-style short mode. 25939 # If so, the updated path is stored in $new_path. 25940 25941 input_path="$new_path" 25942 # Check if we need to convert this using DOS-style short mode. If the path 25943 # contains just simple characters, use it. Otherwise (spaces, weird characters), 25944 # take no chances and rewrite it. 25945 # Note: m4 eats our [], so we need to use [ and ] instead. 25946 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 25947 if test "x$has_forbidden_chars" != x; then 25948 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 25949 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 25950 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 25951 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 25952 # Going to short mode and back again did indeed matter. Since short mode is 25953 # case insensitive, let's make it lowercase to improve readability. 25954 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 25955 # Now convert it back to Unix-style (cygpath) 25956 input_path=`$CYGPATH -u "$shortmode_path"` 25957 new_path="$input_path" 25958 fi 25959 fi 25960 25961 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 25962 if test "x$test_cygdrive_prefix" = x; then 25963 # As a simple fix, exclude /usr/bin since it's not a real path. 25964 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 25965 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 25966 # a path prefixed by /cygdrive for fixpath to work. 25967 new_path="$CYGWIN_ROOT_PATH$input_path" 25968 fi 25969 fi 25970 25971 25972 if test "x$path" != "x$new_path"; then 25973 JAVA_HOME_PROCESSED="$new_path" 25974 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting JAVA_HOME_PROCESSED to \"$new_path\"" >&5 25975 $as_echo "$as_me: Rewriting JAVA_HOME_PROCESSED to \"$new_path\"" >&6;} 25976 fi 25977 25978 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 25979 25980 path="$JAVA_HOME_PROCESSED" 25981 has_colon=`$ECHO $path | $GREP ^.:` 25982 new_path="$path" 25983 if test "x$has_colon" = x; then 25984 # Not in mixed or Windows style, start by that. 25985 new_path=`cmd //c echo $path` 25986 fi 25987 25988 25989 input_path="$new_path" 25990 # Check if we need to convert this using DOS-style short mode. If the path 25991 # contains just simple characters, use it. Otherwise (spaces, weird characters), 25992 # take no chances and rewrite it. 25993 # Note: m4 eats our [], so we need to use [ and ] instead. 25994 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 25995 if test "x$has_forbidden_chars" != x; then 25996 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 25997 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 25998 fi 25999 26000 26001 windows_path="$new_path" 26002 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 26003 unix_path=`$CYGPATH -u "$windows_path"` 26004 new_path="$unix_path" 26005 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 26006 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 26007 new_path="$unix_path" 26008 fi 26009 26010 if test "x$path" != "x$new_path"; then 26011 JAVA_HOME_PROCESSED="$new_path" 26012 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting JAVA_HOME_PROCESSED to \"$new_path\"" >&5 26013 $as_echo "$as_me: Rewriting JAVA_HOME_PROCESSED to \"$new_path\"" >&6;} 26014 fi 26015 26016 # Save the first 10 bytes of this path to the storage, so fixpath can work. 26017 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 26018 26019 else 26020 # We're on a unix platform. Hooray! :) 26021 path="$JAVA_HOME_PROCESSED" 26022 has_space=`$ECHO "$path" | $GREP " "` 26023 if test "x$has_space" != x; then 26024 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of JAVA_HOME_PROCESSED, which resolves as \"$path\", is invalid." >&5 26025 $as_echo "$as_me: The path of JAVA_HOME_PROCESSED, which resolves as \"$path\", is invalid." >&6;} 26026 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 26027 fi 26028 26029 # Use eval to expand a potential ~ 26030 eval path="$path" 26031 if test ! -f "$path" && test ! -d "$path"; then 26032 as_fn_error $? "The path of JAVA_HOME_PROCESSED, which resolves as \"$path\", is not found." "$LINENO" 5 26033 fi 26034 26035 if test -d "$path"; then 26036 JAVA_HOME_PROCESSED="`cd "$path"; $THEPWDCMD -L`" 26037 else 26038 dir="`$DIRNAME "$path"`" 26039 base="`$BASENAME "$path"`" 26040 JAVA_HOME_PROCESSED="`cd "$dir"; $THEPWDCMD -L`/$base" 26041 fi 26042 fi 26043 fi 26044 26045 if test ! -d "$JAVA_HOME_PROCESSED"; then 26046 { $as_echo "$as_me:${as_lineno-$LINENO}: Your JAVA_HOME points to a non-existing directory!" >&5 26047 $as_echo "$as_me: Your JAVA_HOME points to a non-existing directory!" >&6;} 26048 else 26049 # Aha, the user has set a JAVA_HOME 26050 # let us use that as the Boot JDK. 26051 BOOT_JDK="$JAVA_HOME_PROCESSED" 26052 BOOT_JDK_FOUND=maybe 26053 { $as_echo "$as_me:${as_lineno-$LINENO}: Found potential Boot JDK using JAVA_HOME" >&5 26054 $as_echo "$as_me: Found potential Boot JDK using JAVA_HOME" >&6;} 26055 fi 26056 fi 26057 26058 26059 # If previous step claimed to have found a JDK, check it to see if it seems to be valid. 26060 if test "x$BOOT_JDK_FOUND" = xmaybe; then 26061 # Do we have a bin/java? 26062 if test ! -x "$BOOT_JDK/bin/java"; then 26063 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&5 26064 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&6;} 26065 BOOT_JDK_FOUND=no 26066 else 26067 # Do we have a bin/javac? 26068 if test ! -x "$BOOT_JDK/bin/javac"; then 26069 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&5 26070 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&6;} 26071 { $as_echo "$as_me:${as_lineno-$LINENO}: (This might be an JRE instead of an JDK)" >&5 26072 $as_echo "$as_me: (This might be an JRE instead of an JDK)" >&6;} 26073 BOOT_JDK_FOUND=no 26074 else 26075 # Oh, this is looking good! We probably have found a proper JDK. Is it the correct version? 26076 BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | $HEAD -n 1` 26077 26078 # Extra M4 quote needed to protect [] in grep expression. 26079 FOUND_CORRECT_VERSION=`$ECHO $BOOT_JDK_VERSION | $EGREP '\"9([\.+-].*)?\"|(1\.[89]\.)'` 26080 if test "x$FOUND_CORRECT_VERSION" = x; then 26081 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&5 26082 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&6;} 26083 { $as_echo "$as_me:${as_lineno-$LINENO}: (Your Boot JDK must be version 8 or 9)" >&5 26084 $as_echo "$as_me: (Your Boot JDK must be version 8 or 9)" >&6;} 26085 BOOT_JDK_FOUND=no 26086 else 26087 # We're done! :-) 26088 BOOT_JDK_FOUND=yes 26089 26090 # Only process if variable expands to non-empty 26091 26092 if test "x$BOOT_JDK" != x; then 26093 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 26094 26095 # Input might be given as Windows format, start by converting to 26096 # unix format. 26097 path="$BOOT_JDK" 26098 new_path=`$CYGPATH -u "$path"` 26099 26100 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 26101 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 26102 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 26103 # "foo.exe" is OK but "foo" is an error. 26104 # 26105 # This test is therefore slightly more accurate than "test -f" to check for file precense. 26106 # It is also a way to make sure we got the proper file name for the real test later on. 26107 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 26108 if test "x$test_shortpath" = x; then 26109 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5 26110 $as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;} 26111 as_fn_error $? "Cannot locate the the path of BOOT_JDK" "$LINENO" 5 26112 fi 26113 26114 # Call helper function which possibly converts this using DOS-style short mode. 26115 # If so, the updated path is stored in $new_path. 26116 26117 input_path="$new_path" 26118 # Check if we need to convert this using DOS-style short mode. If the path 26119 # contains just simple characters, use it. Otherwise (spaces, weird characters), 26120 # take no chances and rewrite it. 26121 # Note: m4 eats our [], so we need to use [ and ] instead. 26122 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 26123 if test "x$has_forbidden_chars" != x; then 26124 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 26125 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 26126 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 26127 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 26128 # Going to short mode and back again did indeed matter. Since short mode is 26129 # case insensitive, let's make it lowercase to improve readability. 26130 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 26131 # Now convert it back to Unix-style (cygpath) 26132 input_path=`$CYGPATH -u "$shortmode_path"` 26133 new_path="$input_path" 26134 fi 26135 fi 26136 26137 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 26138 if test "x$test_cygdrive_prefix" = x; then 26139 # As a simple fix, exclude /usr/bin since it's not a real path. 26140 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 26141 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 26142 # a path prefixed by /cygdrive for fixpath to work. 26143 new_path="$CYGWIN_ROOT_PATH$input_path" 26144 fi 26145 fi 26146 26147 26148 if test "x$path" != "x$new_path"; then 26149 BOOT_JDK="$new_path" 26150 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5 26151 $as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;} 26152 fi 26153 26154 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 26155 26156 path="$BOOT_JDK" 26157 has_colon=`$ECHO $path | $GREP ^.:` 26158 new_path="$path" 26159 if test "x$has_colon" = x; then 26160 # Not in mixed or Windows style, start by that. 26161 new_path=`cmd //c echo $path` 26162 fi 26163 26164 26165 input_path="$new_path" 26166 # Check if we need to convert this using DOS-style short mode. If the path 26167 # contains just simple characters, use it. Otherwise (spaces, weird characters), 26168 # take no chances and rewrite it. 26169 # Note: m4 eats our [], so we need to use [ and ] instead. 26170 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 26171 if test "x$has_forbidden_chars" != x; then 26172 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 26173 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 26174 fi 26175 26176 26177 windows_path="$new_path" 26178 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 26179 unix_path=`$CYGPATH -u "$windows_path"` 26180 new_path="$unix_path" 26181 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 26182 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 26183 new_path="$unix_path" 26184 fi 26185 26186 if test "x$path" != "x$new_path"; then 26187 BOOT_JDK="$new_path" 26188 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5 26189 $as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;} 26190 fi 26191 26192 # Save the first 10 bytes of this path to the storage, so fixpath can work. 26193 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 26194 26195 else 26196 # We're on a unix platform. Hooray! :) 26197 path="$BOOT_JDK" 26198 has_space=`$ECHO "$path" | $GREP " "` 26199 if test "x$has_space" != x; then 26200 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5 26201 $as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;} 26202 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 26203 fi 26204 26205 # Use eval to expand a potential ~ 26206 eval path="$path" 26207 if test ! -f "$path" && test ! -d "$path"; then 26208 as_fn_error $? "The path of BOOT_JDK, which resolves as \"$path\", is not found." "$LINENO" 5 26209 fi 26210 26211 if test -d "$path"; then 26212 BOOT_JDK="`cd "$path"; $THEPWDCMD -L`" 26213 else 26214 dir="`$DIRNAME "$path"`" 26215 base="`$BASENAME "$path"`" 26216 BOOT_JDK="`cd "$dir"; $THEPWDCMD -L`/$base" 26217 fi 26218 fi 26219 fi 26220 26221 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for Boot JDK" >&5 26222 $as_echo_n "checking for Boot JDK... " >&6; } 26223 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK" >&5 26224 $as_echo "$BOOT_JDK" >&6; } 26225 { $as_echo "$as_me:${as_lineno-$LINENO}: checking Boot JDK version" >&5 26226 $as_echo_n "checking Boot JDK version... " >&6; } 26227 BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | $TR '\n\r' ' '` 26228 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK_VERSION" >&5 26229 $as_echo "$BOOT_JDK_VERSION" >&6; } 26230 fi # end check jdk version 26231 fi # end check javac 26232 fi # end check java 26233 fi # end check boot jdk found 26234 fi 26235 26236 26237 # Test: Is there a java or javac in the PATH, which is a symlink to the JDK? 26238 26239 if test "x$BOOT_JDK_FOUND" = xno; then 26240 # Now execute the test 26241 26242 # Extract the first word of "javac", so it can be a program name with args. 26243 set dummy javac; ac_word=$2 26244 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 26245 $as_echo_n "checking for $ac_word... " >&6; } 26246 if ${ac_cv_path_JAVAC_CHECK+:} false; then : 26247 $as_echo_n "(cached) " >&6 26248 else 26249 case $JAVAC_CHECK in 26250 [\\/]* | ?:[\\/]*) 26251 ac_cv_path_JAVAC_CHECK="$JAVAC_CHECK" # Let the user override the test with a path. 26252 ;; 26253 *) 26254 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 26255 for as_dir in $PATH 26256 do 26257 IFS=$as_save_IFS 26258 test -z "$as_dir" && as_dir=. 26259 for ac_exec_ext in '' $ac_executable_extensions; do 26260 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 26261 ac_cv_path_JAVAC_CHECK="$as_dir/$ac_word$ac_exec_ext" 26262 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 26263 break 2 26264 fi 26265 done 26266 done 26267 IFS=$as_save_IFS 26268 26269 ;; 26270 esac 26271 fi 26272 JAVAC_CHECK=$ac_cv_path_JAVAC_CHECK 26273 if test -n "$JAVAC_CHECK"; then 26274 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $JAVAC_CHECK" >&5 26275 $as_echo "$JAVAC_CHECK" >&6; } 26276 else 26277 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 26278 $as_echo "no" >&6; } 26279 fi 26280 26281 26282 # Extract the first word of "java", so it can be a program name with args. 26283 set dummy java; ac_word=$2 26284 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 26285 $as_echo_n "checking for $ac_word... " >&6; } 26286 if ${ac_cv_path_JAVA_CHECK+:} false; then : 26287 $as_echo_n "(cached) " >&6 26288 else 26289 case $JAVA_CHECK in 26290 [\\/]* | ?:[\\/]*) 26291 ac_cv_path_JAVA_CHECK="$JAVA_CHECK" # Let the user override the test with a path. 26292 ;; 26293 *) 26294 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 26295 for as_dir in $PATH 26296 do 26297 IFS=$as_save_IFS 26298 test -z "$as_dir" && as_dir=. 26299 for ac_exec_ext in '' $ac_executable_extensions; do 26300 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 26301 ac_cv_path_JAVA_CHECK="$as_dir/$ac_word$ac_exec_ext" 26302 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 26303 break 2 26304 fi 26305 done 26306 done 26307 IFS=$as_save_IFS 26308 26309 ;; 26310 esac 26311 fi 26312 JAVA_CHECK=$ac_cv_path_JAVA_CHECK 26313 if test -n "$JAVA_CHECK"; then 26314 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $JAVA_CHECK" >&5 26315 $as_echo "$JAVA_CHECK" >&6; } 26316 else 26317 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 26318 $as_echo "no" >&6; } 26319 fi 26320 26321 26322 BINARY="$JAVAC_CHECK" 26323 if test "x$JAVAC_CHECK" = x; then 26324 BINARY="$JAVA_CHECK" 26325 fi 26326 if test "x$BINARY" != x; then 26327 # So there is a java(c) binary, it might be part of a JDK. 26328 # Lets find the JDK/JRE directory by following symbolic links. 26329 # Linux/GNU systems often have links from /usr/bin/java to 26330 # /etc/alternatives/java to the real JDK binary. 26331 26332 if test "x$OPENJDK_BUILD_OS" != xwindows; then 26333 # Follow a chain of symbolic links. Use readlink 26334 # where it exists, else fall back to horribly 26335 # complicated shell code. 26336 if test "x$READLINK_TESTED" != yes; then 26337 # On MacOSX there is a readlink tool with a different 26338 # purpose than the GNU readlink tool. Check the found readlink. 26339 ISGNU=`$READLINK --version 2>&1 | $GREP GNU` 26340 if test "x$ISGNU" = x; then 26341 # A readlink that we do not know how to use. 26342 # Are there other non-GNU readlinks out there? 26343 READLINK_TESTED=yes 26344 READLINK= 26345 fi 26346 fi 26347 26348 if test "x$READLINK" != x; then 26349 BINARY=`$READLINK -f $BINARY` 26350 else 26351 # Save the current directory for restoring afterwards 26352 STARTDIR=$PWD 26353 COUNTER=0 26354 sym_link_dir=`$DIRNAME $BINARY` 26355 sym_link_file=`$BASENAME $BINARY` 26356 cd $sym_link_dir 26357 # Use -P flag to resolve symlinks in directories. 26358 cd `$THEPWDCMD -P` 26359 sym_link_dir=`$THEPWDCMD -P` 26360 # Resolve file symlinks 26361 while test $COUNTER -lt 20; do 26362 ISLINK=`$LS -l $sym_link_dir/$sym_link_file | $GREP '\->' | $SED -e 's/.*-> \(.*\)/\1/'` 26363 if test "x$ISLINK" == x; then 26364 # This is not a symbolic link! We are done! 26365 break 26366 fi 26367 # Again resolve directory symlinks since the target of the just found 26368 # link could be in a different directory 26369 cd `$DIRNAME $ISLINK` 26370 sym_link_dir=`$THEPWDCMD -P` 26371 sym_link_file=`$BASENAME $ISLINK` 26372 let COUNTER=COUNTER+1 26373 done 26374 cd $STARTDIR 26375 BINARY=$sym_link_dir/$sym_link_file 26376 fi 26377 fi 26378 26379 BOOT_JDK=`dirname "$BINARY"` 26380 BOOT_JDK=`cd "$BOOT_JDK/.."; pwd` 26381 if test -x "$BOOT_JDK/bin/javac" && test -x "$BOOT_JDK/bin/java"; then 26382 # Looks like we found ourselves an JDK 26383 BOOT_JDK_FOUND=maybe 26384 { $as_echo "$as_me:${as_lineno-$LINENO}: Found potential Boot JDK using java(c) in PATH" >&5 26385 $as_echo "$as_me: Found potential Boot JDK using java(c) in PATH" >&6;} 26386 fi 26387 fi 26388 26389 26390 # If previous step claimed to have found a JDK, check it to see if it seems to be valid. 26391 if test "x$BOOT_JDK_FOUND" = xmaybe; then 26392 # Do we have a bin/java? 26393 if test ! -x "$BOOT_JDK/bin/java"; then 26394 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&5 26395 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&6;} 26396 BOOT_JDK_FOUND=no 26397 else 26398 # Do we have a bin/javac? 26399 if test ! -x "$BOOT_JDK/bin/javac"; then 26400 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&5 26401 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&6;} 26402 { $as_echo "$as_me:${as_lineno-$LINENO}: (This might be an JRE instead of an JDK)" >&5 26403 $as_echo "$as_me: (This might be an JRE instead of an JDK)" >&6;} 26404 BOOT_JDK_FOUND=no 26405 else 26406 # Oh, this is looking good! We probably have found a proper JDK. Is it the correct version? 26407 BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | $HEAD -n 1` 26408 26409 # Extra M4 quote needed to protect [] in grep expression. 26410 FOUND_CORRECT_VERSION=`$ECHO $BOOT_JDK_VERSION | $EGREP '\"9([\.+-].*)?\"|(1\.[89]\.)'` 26411 if test "x$FOUND_CORRECT_VERSION" = x; then 26412 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&5 26413 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&6;} 26414 { $as_echo "$as_me:${as_lineno-$LINENO}: (Your Boot JDK must be version 8 or 9)" >&5 26415 $as_echo "$as_me: (Your Boot JDK must be version 8 or 9)" >&6;} 26416 BOOT_JDK_FOUND=no 26417 else 26418 # We're done! :-) 26419 BOOT_JDK_FOUND=yes 26420 26421 # Only process if variable expands to non-empty 26422 26423 if test "x$BOOT_JDK" != x; then 26424 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 26425 26426 # Input might be given as Windows format, start by converting to 26427 # unix format. 26428 path="$BOOT_JDK" 26429 new_path=`$CYGPATH -u "$path"` 26430 26431 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 26432 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 26433 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 26434 # "foo.exe" is OK but "foo" is an error. 26435 # 26436 # This test is therefore slightly more accurate than "test -f" to check for file precense. 26437 # It is also a way to make sure we got the proper file name for the real test later on. 26438 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 26439 if test "x$test_shortpath" = x; then 26440 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5 26441 $as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;} 26442 as_fn_error $? "Cannot locate the the path of BOOT_JDK" "$LINENO" 5 26443 fi 26444 26445 # Call helper function which possibly converts this using DOS-style short mode. 26446 # If so, the updated path is stored in $new_path. 26447 26448 input_path="$new_path" 26449 # Check if we need to convert this using DOS-style short mode. If the path 26450 # contains just simple characters, use it. Otherwise (spaces, weird characters), 26451 # take no chances and rewrite it. 26452 # Note: m4 eats our [], so we need to use [ and ] instead. 26453 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 26454 if test "x$has_forbidden_chars" != x; then 26455 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 26456 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 26457 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 26458 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 26459 # Going to short mode and back again did indeed matter. Since short mode is 26460 # case insensitive, let's make it lowercase to improve readability. 26461 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 26462 # Now convert it back to Unix-style (cygpath) 26463 input_path=`$CYGPATH -u "$shortmode_path"` 26464 new_path="$input_path" 26465 fi 26466 fi 26467 26468 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 26469 if test "x$test_cygdrive_prefix" = x; then 26470 # As a simple fix, exclude /usr/bin since it's not a real path. 26471 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 26472 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 26473 # a path prefixed by /cygdrive for fixpath to work. 26474 new_path="$CYGWIN_ROOT_PATH$input_path" 26475 fi 26476 fi 26477 26478 26479 if test "x$path" != "x$new_path"; then 26480 BOOT_JDK="$new_path" 26481 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5 26482 $as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;} 26483 fi 26484 26485 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 26486 26487 path="$BOOT_JDK" 26488 has_colon=`$ECHO $path | $GREP ^.:` 26489 new_path="$path" 26490 if test "x$has_colon" = x; then 26491 # Not in mixed or Windows style, start by that. 26492 new_path=`cmd //c echo $path` 26493 fi 26494 26495 26496 input_path="$new_path" 26497 # Check if we need to convert this using DOS-style short mode. If the path 26498 # contains just simple characters, use it. Otherwise (spaces, weird characters), 26499 # take no chances and rewrite it. 26500 # Note: m4 eats our [], so we need to use [ and ] instead. 26501 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 26502 if test "x$has_forbidden_chars" != x; then 26503 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 26504 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 26505 fi 26506 26507 26508 windows_path="$new_path" 26509 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 26510 unix_path=`$CYGPATH -u "$windows_path"` 26511 new_path="$unix_path" 26512 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 26513 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 26514 new_path="$unix_path" 26515 fi 26516 26517 if test "x$path" != "x$new_path"; then 26518 BOOT_JDK="$new_path" 26519 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5 26520 $as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;} 26521 fi 26522 26523 # Save the first 10 bytes of this path to the storage, so fixpath can work. 26524 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 26525 26526 else 26527 # We're on a unix platform. Hooray! :) 26528 path="$BOOT_JDK" 26529 has_space=`$ECHO "$path" | $GREP " "` 26530 if test "x$has_space" != x; then 26531 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5 26532 $as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;} 26533 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 26534 fi 26535 26536 # Use eval to expand a potential ~ 26537 eval path="$path" 26538 if test ! -f "$path" && test ! -d "$path"; then 26539 as_fn_error $? "The path of BOOT_JDK, which resolves as \"$path\", is not found." "$LINENO" 5 26540 fi 26541 26542 if test -d "$path"; then 26543 BOOT_JDK="`cd "$path"; $THEPWDCMD -L`" 26544 else 26545 dir="`$DIRNAME "$path"`" 26546 base="`$BASENAME "$path"`" 26547 BOOT_JDK="`cd "$dir"; $THEPWDCMD -L`/$base" 26548 fi 26549 fi 26550 fi 26551 26552 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for Boot JDK" >&5 26553 $as_echo_n "checking for Boot JDK... " >&6; } 26554 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK" >&5 26555 $as_echo "$BOOT_JDK" >&6; } 26556 { $as_echo "$as_me:${as_lineno-$LINENO}: checking Boot JDK version" >&5 26557 $as_echo_n "checking Boot JDK version... " >&6; } 26558 BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | $TR '\n\r' ' '` 26559 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK_VERSION" >&5 26560 $as_echo "$BOOT_JDK_VERSION" >&6; } 26561 fi # end check jdk version 26562 fi # end check javac 26563 fi # end check java 26564 fi # end check boot jdk found 26565 fi 26566 26567 26568 # Test: Is there a JDK installed in default, well-known locations? 26569 26570 if test "x$BOOT_JDK_FOUND" = xno; then 26571 # Now execute the test 26572 26573 if test "x$OPENJDK_TARGET_OS" = xwindows; then 26574 26575 if test "x$BOOT_JDK_FOUND" = xno; then 26576 # Now execute the test 26577 26578 if test "x$ProgramW6432" != x; then 26579 VIRTUAL_DIR="$ProgramW6432/Java" 26580 26581 windows_path="$VIRTUAL_DIR" 26582 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 26583 unix_path=`$CYGPATH -u "$windows_path"` 26584 VIRTUAL_DIR="$unix_path" 26585 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 26586 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 26587 VIRTUAL_DIR="$unix_path" 26588 fi 26589 26590 26591 BOOT_JDK_PREFIX="$VIRTUAL_DIR" 26592 BOOT_JDK_SUFFIX="" 26593 ALL_JDKS_FOUND=`$LS "$BOOT_JDK_PREFIX" 2> /dev/null | $SORT -r` 26594 if test "x$ALL_JDKS_FOUND" != x; then 26595 for JDK_TO_TRY in $ALL_JDKS_FOUND ; do 26596 26597 if test "x$BOOT_JDK_FOUND" = xno; then 26598 # Now execute the test 26599 26600 BOOT_JDK="${BOOT_JDK_PREFIX}/${JDK_TO_TRY}${BOOT_JDK_SUFFIX}" 26601 if test -d "$BOOT_JDK"; then 26602 BOOT_JDK_FOUND=maybe 26603 { $as_echo "$as_me:${as_lineno-$LINENO}: Found potential Boot JDK using well-known locations (in $BOOT_JDK_PREFIX/$JDK_TO_TRY)" >&5 26604 $as_echo "$as_me: Found potential Boot JDK using well-known locations (in $BOOT_JDK_PREFIX/$JDK_TO_TRY)" >&6;} 26605 fi 26606 26607 26608 # If previous step claimed to have found a JDK, check it to see if it seems to be valid. 26609 if test "x$BOOT_JDK_FOUND" = xmaybe; then 26610 # Do we have a bin/java? 26611 if test ! -x "$BOOT_JDK/bin/java"; then 26612 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&5 26613 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&6;} 26614 BOOT_JDK_FOUND=no 26615 else 26616 # Do we have a bin/javac? 26617 if test ! -x "$BOOT_JDK/bin/javac"; then 26618 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&5 26619 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&6;} 26620 { $as_echo "$as_me:${as_lineno-$LINENO}: (This might be an JRE instead of an JDK)" >&5 26621 $as_echo "$as_me: (This might be an JRE instead of an JDK)" >&6;} 26622 BOOT_JDK_FOUND=no 26623 else 26624 # Oh, this is looking good! We probably have found a proper JDK. Is it the correct version? 26625 BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | $HEAD -n 1` 26626 26627 # Extra M4 quote needed to protect [] in grep expression. 26628 FOUND_CORRECT_VERSION=`$ECHO $BOOT_JDK_VERSION | $EGREP '\"9([\.+-].*)?\"|(1\.[89]\.)'` 26629 if test "x$FOUND_CORRECT_VERSION" = x; then 26630 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&5 26631 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&6;} 26632 { $as_echo "$as_me:${as_lineno-$LINENO}: (Your Boot JDK must be version 8 or 9)" >&5 26633 $as_echo "$as_me: (Your Boot JDK must be version 8 or 9)" >&6;} 26634 BOOT_JDK_FOUND=no 26635 else 26636 # We're done! :-) 26637 BOOT_JDK_FOUND=yes 26638 26639 # Only process if variable expands to non-empty 26640 26641 if test "x$BOOT_JDK" != x; then 26642 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 26643 26644 # Input might be given as Windows format, start by converting to 26645 # unix format. 26646 path="$BOOT_JDK" 26647 new_path=`$CYGPATH -u "$path"` 26648 26649 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 26650 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 26651 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 26652 # "foo.exe" is OK but "foo" is an error. 26653 # 26654 # This test is therefore slightly more accurate than "test -f" to check for file precense. 26655 # It is also a way to make sure we got the proper file name for the real test later on. 26656 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 26657 if test "x$test_shortpath" = x; then 26658 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5 26659 $as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;} 26660 as_fn_error $? "Cannot locate the the path of BOOT_JDK" "$LINENO" 5 26661 fi 26662 26663 # Call helper function which possibly converts this using DOS-style short mode. 26664 # If so, the updated path is stored in $new_path. 26665 26666 input_path="$new_path" 26667 # Check if we need to convert this using DOS-style short mode. If the path 26668 # contains just simple characters, use it. Otherwise (spaces, weird characters), 26669 # take no chances and rewrite it. 26670 # Note: m4 eats our [], so we need to use [ and ] instead. 26671 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 26672 if test "x$has_forbidden_chars" != x; then 26673 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 26674 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 26675 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 26676 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 26677 # Going to short mode and back again did indeed matter. Since short mode is 26678 # case insensitive, let's make it lowercase to improve readability. 26679 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 26680 # Now convert it back to Unix-style (cygpath) 26681 input_path=`$CYGPATH -u "$shortmode_path"` 26682 new_path="$input_path" 26683 fi 26684 fi 26685 26686 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 26687 if test "x$test_cygdrive_prefix" = x; then 26688 # As a simple fix, exclude /usr/bin since it's not a real path. 26689 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 26690 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 26691 # a path prefixed by /cygdrive for fixpath to work. 26692 new_path="$CYGWIN_ROOT_PATH$input_path" 26693 fi 26694 fi 26695 26696 26697 if test "x$path" != "x$new_path"; then 26698 BOOT_JDK="$new_path" 26699 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5 26700 $as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;} 26701 fi 26702 26703 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 26704 26705 path="$BOOT_JDK" 26706 has_colon=`$ECHO $path | $GREP ^.:` 26707 new_path="$path" 26708 if test "x$has_colon" = x; then 26709 # Not in mixed or Windows style, start by that. 26710 new_path=`cmd //c echo $path` 26711 fi 26712 26713 26714 input_path="$new_path" 26715 # Check if we need to convert this using DOS-style short mode. If the path 26716 # contains just simple characters, use it. Otherwise (spaces, weird characters), 26717 # take no chances and rewrite it. 26718 # Note: m4 eats our [], so we need to use [ and ] instead. 26719 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 26720 if test "x$has_forbidden_chars" != x; then 26721 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 26722 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 26723 fi 26724 26725 26726 windows_path="$new_path" 26727 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 26728 unix_path=`$CYGPATH -u "$windows_path"` 26729 new_path="$unix_path" 26730 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 26731 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 26732 new_path="$unix_path" 26733 fi 26734 26735 if test "x$path" != "x$new_path"; then 26736 BOOT_JDK="$new_path" 26737 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5 26738 $as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;} 26739 fi 26740 26741 # Save the first 10 bytes of this path to the storage, so fixpath can work. 26742 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 26743 26744 else 26745 # We're on a unix platform. Hooray! :) 26746 path="$BOOT_JDK" 26747 has_space=`$ECHO "$path" | $GREP " "` 26748 if test "x$has_space" != x; then 26749 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5 26750 $as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;} 26751 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 26752 fi 26753 26754 # Use eval to expand a potential ~ 26755 eval path="$path" 26756 if test ! -f "$path" && test ! -d "$path"; then 26757 as_fn_error $? "The path of BOOT_JDK, which resolves as \"$path\", is not found." "$LINENO" 5 26758 fi 26759 26760 if test -d "$path"; then 26761 BOOT_JDK="`cd "$path"; $THEPWDCMD -L`" 26762 else 26763 dir="`$DIRNAME "$path"`" 26764 base="`$BASENAME "$path"`" 26765 BOOT_JDK="`cd "$dir"; $THEPWDCMD -L`/$base" 26766 fi 26767 fi 26768 fi 26769 26770 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for Boot JDK" >&5 26771 $as_echo_n "checking for Boot JDK... " >&6; } 26772 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK" >&5 26773 $as_echo "$BOOT_JDK" >&6; } 26774 { $as_echo "$as_me:${as_lineno-$LINENO}: checking Boot JDK version" >&5 26775 $as_echo_n "checking Boot JDK version... " >&6; } 26776 BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | $TR '\n\r' ' '` 26777 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK_VERSION" >&5 26778 $as_echo "$BOOT_JDK_VERSION" >&6; } 26779 fi # end check jdk version 26780 fi # end check javac 26781 fi # end check java 26782 fi # end check boot jdk found 26783 fi 26784 26785 done 26786 fi 26787 26788 fi 26789 26790 26791 # If previous step claimed to have found a JDK, check it to see if it seems to be valid. 26792 if test "x$BOOT_JDK_FOUND" = xmaybe; then 26793 # Do we have a bin/java? 26794 if test ! -x "$BOOT_JDK/bin/java"; then 26795 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&5 26796 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&6;} 26797 BOOT_JDK_FOUND=no 26798 else 26799 # Do we have a bin/javac? 26800 if test ! -x "$BOOT_JDK/bin/javac"; then 26801 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&5 26802 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&6;} 26803 { $as_echo "$as_me:${as_lineno-$LINENO}: (This might be an JRE instead of an JDK)" >&5 26804 $as_echo "$as_me: (This might be an JRE instead of an JDK)" >&6;} 26805 BOOT_JDK_FOUND=no 26806 else 26807 # Oh, this is looking good! We probably have found a proper JDK. Is it the correct version? 26808 BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | $HEAD -n 1` 26809 26810 # Extra M4 quote needed to protect [] in grep expression. 26811 FOUND_CORRECT_VERSION=`$ECHO $BOOT_JDK_VERSION | $EGREP '\"9([\.+-].*)?\"|(1\.[89]\.)'` 26812 if test "x$FOUND_CORRECT_VERSION" = x; then 26813 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&5 26814 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&6;} 26815 { $as_echo "$as_me:${as_lineno-$LINENO}: (Your Boot JDK must be version 8 or 9)" >&5 26816 $as_echo "$as_me: (Your Boot JDK must be version 8 or 9)" >&6;} 26817 BOOT_JDK_FOUND=no 26818 else 26819 # We're done! :-) 26820 BOOT_JDK_FOUND=yes 26821 26822 # Only process if variable expands to non-empty 26823 26824 if test "x$BOOT_JDK" != x; then 26825 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 26826 26827 # Input might be given as Windows format, start by converting to 26828 # unix format. 26829 path="$BOOT_JDK" 26830 new_path=`$CYGPATH -u "$path"` 26831 26832 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 26833 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 26834 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 26835 # "foo.exe" is OK but "foo" is an error. 26836 # 26837 # This test is therefore slightly more accurate than "test -f" to check for file precense. 26838 # It is also a way to make sure we got the proper file name for the real test later on. 26839 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 26840 if test "x$test_shortpath" = x; then 26841 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5 26842 $as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;} 26843 as_fn_error $? "Cannot locate the the path of BOOT_JDK" "$LINENO" 5 26844 fi 26845 26846 # Call helper function which possibly converts this using DOS-style short mode. 26847 # If so, the updated path is stored in $new_path. 26848 26849 input_path="$new_path" 26850 # Check if we need to convert this using DOS-style short mode. If the path 26851 # contains just simple characters, use it. Otherwise (spaces, weird characters), 26852 # take no chances and rewrite it. 26853 # Note: m4 eats our [], so we need to use [ and ] instead. 26854 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 26855 if test "x$has_forbidden_chars" != x; then 26856 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 26857 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 26858 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 26859 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 26860 # Going to short mode and back again did indeed matter. Since short mode is 26861 # case insensitive, let's make it lowercase to improve readability. 26862 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 26863 # Now convert it back to Unix-style (cygpath) 26864 input_path=`$CYGPATH -u "$shortmode_path"` 26865 new_path="$input_path" 26866 fi 26867 fi 26868 26869 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 26870 if test "x$test_cygdrive_prefix" = x; then 26871 # As a simple fix, exclude /usr/bin since it's not a real path. 26872 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 26873 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 26874 # a path prefixed by /cygdrive for fixpath to work. 26875 new_path="$CYGWIN_ROOT_PATH$input_path" 26876 fi 26877 fi 26878 26879 26880 if test "x$path" != "x$new_path"; then 26881 BOOT_JDK="$new_path" 26882 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5 26883 $as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;} 26884 fi 26885 26886 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 26887 26888 path="$BOOT_JDK" 26889 has_colon=`$ECHO $path | $GREP ^.:` 26890 new_path="$path" 26891 if test "x$has_colon" = x; then 26892 # Not in mixed or Windows style, start by that. 26893 new_path=`cmd //c echo $path` 26894 fi 26895 26896 26897 input_path="$new_path" 26898 # Check if we need to convert this using DOS-style short mode. If the path 26899 # contains just simple characters, use it. Otherwise (spaces, weird characters), 26900 # take no chances and rewrite it. 26901 # Note: m4 eats our [], so we need to use [ and ] instead. 26902 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 26903 if test "x$has_forbidden_chars" != x; then 26904 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 26905 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 26906 fi 26907 26908 26909 windows_path="$new_path" 26910 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 26911 unix_path=`$CYGPATH -u "$windows_path"` 26912 new_path="$unix_path" 26913 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 26914 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 26915 new_path="$unix_path" 26916 fi 26917 26918 if test "x$path" != "x$new_path"; then 26919 BOOT_JDK="$new_path" 26920 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5 26921 $as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;} 26922 fi 26923 26924 # Save the first 10 bytes of this path to the storage, so fixpath can work. 26925 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 26926 26927 else 26928 # We're on a unix platform. Hooray! :) 26929 path="$BOOT_JDK" 26930 has_space=`$ECHO "$path" | $GREP " "` 26931 if test "x$has_space" != x; then 26932 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5 26933 $as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;} 26934 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 26935 fi 26936 26937 # Use eval to expand a potential ~ 26938 eval path="$path" 26939 if test ! -f "$path" && test ! -d "$path"; then 26940 as_fn_error $? "The path of BOOT_JDK, which resolves as \"$path\", is not found." "$LINENO" 5 26941 fi 26942 26943 if test -d "$path"; then 26944 BOOT_JDK="`cd "$path"; $THEPWDCMD -L`" 26945 else 26946 dir="`$DIRNAME "$path"`" 26947 base="`$BASENAME "$path"`" 26948 BOOT_JDK="`cd "$dir"; $THEPWDCMD -L`/$base" 26949 fi 26950 fi 26951 fi 26952 26953 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for Boot JDK" >&5 26954 $as_echo_n "checking for Boot JDK... " >&6; } 26955 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK" >&5 26956 $as_echo "$BOOT_JDK" >&6; } 26957 { $as_echo "$as_me:${as_lineno-$LINENO}: checking Boot JDK version" >&5 26958 $as_echo_n "checking Boot JDK version... " >&6; } 26959 BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | $TR '\n\r' ' '` 26960 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK_VERSION" >&5 26961 $as_echo "$BOOT_JDK_VERSION" >&6; } 26962 fi # end check jdk version 26963 fi # end check javac 26964 fi # end check java 26965 fi # end check boot jdk found 26966 fi 26967 26968 26969 if test "x$BOOT_JDK_FOUND" = xno; then 26970 # Now execute the test 26971 26972 if test "x$PROGRAMW6432" != x; then 26973 VIRTUAL_DIR="$PROGRAMW6432/Java" 26974 26975 windows_path="$VIRTUAL_DIR" 26976 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 26977 unix_path=`$CYGPATH -u "$windows_path"` 26978 VIRTUAL_DIR="$unix_path" 26979 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 26980 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 26981 VIRTUAL_DIR="$unix_path" 26982 fi 26983 26984 26985 BOOT_JDK_PREFIX="$VIRTUAL_DIR" 26986 BOOT_JDK_SUFFIX="" 26987 ALL_JDKS_FOUND=`$LS "$BOOT_JDK_PREFIX" 2> /dev/null | $SORT -r` 26988 if test "x$ALL_JDKS_FOUND" != x; then 26989 for JDK_TO_TRY in $ALL_JDKS_FOUND ; do 26990 26991 if test "x$BOOT_JDK_FOUND" = xno; then 26992 # Now execute the test 26993 26994 BOOT_JDK="${BOOT_JDK_PREFIX}/${JDK_TO_TRY}${BOOT_JDK_SUFFIX}" 26995 if test -d "$BOOT_JDK"; then 26996 BOOT_JDK_FOUND=maybe 26997 { $as_echo "$as_me:${as_lineno-$LINENO}: Found potential Boot JDK using well-known locations (in $BOOT_JDK_PREFIX/$JDK_TO_TRY)" >&5 26998 $as_echo "$as_me: Found potential Boot JDK using well-known locations (in $BOOT_JDK_PREFIX/$JDK_TO_TRY)" >&6;} 26999 fi 27000 27001 27002 # If previous step claimed to have found a JDK, check it to see if it seems to be valid. 27003 if test "x$BOOT_JDK_FOUND" = xmaybe; then 27004 # Do we have a bin/java? 27005 if test ! -x "$BOOT_JDK/bin/java"; then 27006 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&5 27007 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&6;} 27008 BOOT_JDK_FOUND=no 27009 else 27010 # Do we have a bin/javac? 27011 if test ! -x "$BOOT_JDK/bin/javac"; then 27012 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&5 27013 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&6;} 27014 { $as_echo "$as_me:${as_lineno-$LINENO}: (This might be an JRE instead of an JDK)" >&5 27015 $as_echo "$as_me: (This might be an JRE instead of an JDK)" >&6;} 27016 BOOT_JDK_FOUND=no 27017 else 27018 # Oh, this is looking good! We probably have found a proper JDK. Is it the correct version? 27019 BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | $HEAD -n 1` 27020 27021 # Extra M4 quote needed to protect [] in grep expression. 27022 FOUND_CORRECT_VERSION=`$ECHO $BOOT_JDK_VERSION | $EGREP '\"9([\.+-].*)?\"|(1\.[89]\.)'` 27023 if test "x$FOUND_CORRECT_VERSION" = x; then 27024 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&5 27025 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&6;} 27026 { $as_echo "$as_me:${as_lineno-$LINENO}: (Your Boot JDK must be version 8 or 9)" >&5 27027 $as_echo "$as_me: (Your Boot JDK must be version 8 or 9)" >&6;} 27028 BOOT_JDK_FOUND=no 27029 else 27030 # We're done! :-) 27031 BOOT_JDK_FOUND=yes 27032 27033 # Only process if variable expands to non-empty 27034 27035 if test "x$BOOT_JDK" != x; then 27036 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 27037 27038 # Input might be given as Windows format, start by converting to 27039 # unix format. 27040 path="$BOOT_JDK" 27041 new_path=`$CYGPATH -u "$path"` 27042 27043 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 27044 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 27045 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 27046 # "foo.exe" is OK but "foo" is an error. 27047 # 27048 # This test is therefore slightly more accurate than "test -f" to check for file precense. 27049 # It is also a way to make sure we got the proper file name for the real test later on. 27050 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 27051 if test "x$test_shortpath" = x; then 27052 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5 27053 $as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;} 27054 as_fn_error $? "Cannot locate the the path of BOOT_JDK" "$LINENO" 5 27055 fi 27056 27057 # Call helper function which possibly converts this using DOS-style short mode. 27058 # If so, the updated path is stored in $new_path. 27059 27060 input_path="$new_path" 27061 # Check if we need to convert this using DOS-style short mode. If the path 27062 # contains just simple characters, use it. Otherwise (spaces, weird characters), 27063 # take no chances and rewrite it. 27064 # Note: m4 eats our [], so we need to use [ and ] instead. 27065 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 27066 if test "x$has_forbidden_chars" != x; then 27067 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 27068 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 27069 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 27070 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 27071 # Going to short mode and back again did indeed matter. Since short mode is 27072 # case insensitive, let's make it lowercase to improve readability. 27073 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 27074 # Now convert it back to Unix-style (cygpath) 27075 input_path=`$CYGPATH -u "$shortmode_path"` 27076 new_path="$input_path" 27077 fi 27078 fi 27079 27080 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 27081 if test "x$test_cygdrive_prefix" = x; then 27082 # As a simple fix, exclude /usr/bin since it's not a real path. 27083 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 27084 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 27085 # a path prefixed by /cygdrive for fixpath to work. 27086 new_path="$CYGWIN_ROOT_PATH$input_path" 27087 fi 27088 fi 27089 27090 27091 if test "x$path" != "x$new_path"; then 27092 BOOT_JDK="$new_path" 27093 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5 27094 $as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;} 27095 fi 27096 27097 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 27098 27099 path="$BOOT_JDK" 27100 has_colon=`$ECHO $path | $GREP ^.:` 27101 new_path="$path" 27102 if test "x$has_colon" = x; then 27103 # Not in mixed or Windows style, start by that. 27104 new_path=`cmd //c echo $path` 27105 fi 27106 27107 27108 input_path="$new_path" 27109 # Check if we need to convert this using DOS-style short mode. If the path 27110 # contains just simple characters, use it. Otherwise (spaces, weird characters), 27111 # take no chances and rewrite it. 27112 # Note: m4 eats our [], so we need to use [ and ] instead. 27113 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 27114 if test "x$has_forbidden_chars" != x; then 27115 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 27116 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 27117 fi 27118 27119 27120 windows_path="$new_path" 27121 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 27122 unix_path=`$CYGPATH -u "$windows_path"` 27123 new_path="$unix_path" 27124 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 27125 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 27126 new_path="$unix_path" 27127 fi 27128 27129 if test "x$path" != "x$new_path"; then 27130 BOOT_JDK="$new_path" 27131 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5 27132 $as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;} 27133 fi 27134 27135 # Save the first 10 bytes of this path to the storage, so fixpath can work. 27136 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 27137 27138 else 27139 # We're on a unix platform. Hooray! :) 27140 path="$BOOT_JDK" 27141 has_space=`$ECHO "$path" | $GREP " "` 27142 if test "x$has_space" != x; then 27143 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5 27144 $as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;} 27145 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 27146 fi 27147 27148 # Use eval to expand a potential ~ 27149 eval path="$path" 27150 if test ! -f "$path" && test ! -d "$path"; then 27151 as_fn_error $? "The path of BOOT_JDK, which resolves as \"$path\", is not found." "$LINENO" 5 27152 fi 27153 27154 if test -d "$path"; then 27155 BOOT_JDK="`cd "$path"; $THEPWDCMD -L`" 27156 else 27157 dir="`$DIRNAME "$path"`" 27158 base="`$BASENAME "$path"`" 27159 BOOT_JDK="`cd "$dir"; $THEPWDCMD -L`/$base" 27160 fi 27161 fi 27162 fi 27163 27164 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for Boot JDK" >&5 27165 $as_echo_n "checking for Boot JDK... " >&6; } 27166 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK" >&5 27167 $as_echo "$BOOT_JDK" >&6; } 27168 { $as_echo "$as_me:${as_lineno-$LINENO}: checking Boot JDK version" >&5 27169 $as_echo_n "checking Boot JDK version... " >&6; } 27170 BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | $TR '\n\r' ' '` 27171 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK_VERSION" >&5 27172 $as_echo "$BOOT_JDK_VERSION" >&6; } 27173 fi # end check jdk version 27174 fi # end check javac 27175 fi # end check java 27176 fi # end check boot jdk found 27177 fi 27178 27179 done 27180 fi 27181 27182 fi 27183 27184 27185 # If previous step claimed to have found a JDK, check it to see if it seems to be valid. 27186 if test "x$BOOT_JDK_FOUND" = xmaybe; then 27187 # Do we have a bin/java? 27188 if test ! -x "$BOOT_JDK/bin/java"; then 27189 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&5 27190 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&6;} 27191 BOOT_JDK_FOUND=no 27192 else 27193 # Do we have a bin/javac? 27194 if test ! -x "$BOOT_JDK/bin/javac"; then 27195 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&5 27196 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&6;} 27197 { $as_echo "$as_me:${as_lineno-$LINENO}: (This might be an JRE instead of an JDK)" >&5 27198 $as_echo "$as_me: (This might be an JRE instead of an JDK)" >&6;} 27199 BOOT_JDK_FOUND=no 27200 else 27201 # Oh, this is looking good! We probably have found a proper JDK. Is it the correct version? 27202 BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | $HEAD -n 1` 27203 27204 # Extra M4 quote needed to protect [] in grep expression. 27205 FOUND_CORRECT_VERSION=`$ECHO $BOOT_JDK_VERSION | $EGREP '\"9([\.+-].*)?\"|(1\.[89]\.)'` 27206 if test "x$FOUND_CORRECT_VERSION" = x; then 27207 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&5 27208 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&6;} 27209 { $as_echo "$as_me:${as_lineno-$LINENO}: (Your Boot JDK must be version 8 or 9)" >&5 27210 $as_echo "$as_me: (Your Boot JDK must be version 8 or 9)" >&6;} 27211 BOOT_JDK_FOUND=no 27212 else 27213 # We're done! :-) 27214 BOOT_JDK_FOUND=yes 27215 27216 # Only process if variable expands to non-empty 27217 27218 if test "x$BOOT_JDK" != x; then 27219 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 27220 27221 # Input might be given as Windows format, start by converting to 27222 # unix format. 27223 path="$BOOT_JDK" 27224 new_path=`$CYGPATH -u "$path"` 27225 27226 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 27227 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 27228 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 27229 # "foo.exe" is OK but "foo" is an error. 27230 # 27231 # This test is therefore slightly more accurate than "test -f" to check for file precense. 27232 # It is also a way to make sure we got the proper file name for the real test later on. 27233 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 27234 if test "x$test_shortpath" = x; then 27235 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5 27236 $as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;} 27237 as_fn_error $? "Cannot locate the the path of BOOT_JDK" "$LINENO" 5 27238 fi 27239 27240 # Call helper function which possibly converts this using DOS-style short mode. 27241 # If so, the updated path is stored in $new_path. 27242 27243 input_path="$new_path" 27244 # Check if we need to convert this using DOS-style short mode. If the path 27245 # contains just simple characters, use it. Otherwise (spaces, weird characters), 27246 # take no chances and rewrite it. 27247 # Note: m4 eats our [], so we need to use [ and ] instead. 27248 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 27249 if test "x$has_forbidden_chars" != x; then 27250 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 27251 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 27252 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 27253 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 27254 # Going to short mode and back again did indeed matter. Since short mode is 27255 # case insensitive, let's make it lowercase to improve readability. 27256 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 27257 # Now convert it back to Unix-style (cygpath) 27258 input_path=`$CYGPATH -u "$shortmode_path"` 27259 new_path="$input_path" 27260 fi 27261 fi 27262 27263 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 27264 if test "x$test_cygdrive_prefix" = x; then 27265 # As a simple fix, exclude /usr/bin since it's not a real path. 27266 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 27267 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 27268 # a path prefixed by /cygdrive for fixpath to work. 27269 new_path="$CYGWIN_ROOT_PATH$input_path" 27270 fi 27271 fi 27272 27273 27274 if test "x$path" != "x$new_path"; then 27275 BOOT_JDK="$new_path" 27276 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5 27277 $as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;} 27278 fi 27279 27280 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 27281 27282 path="$BOOT_JDK" 27283 has_colon=`$ECHO $path | $GREP ^.:` 27284 new_path="$path" 27285 if test "x$has_colon" = x; then 27286 # Not in mixed or Windows style, start by that. 27287 new_path=`cmd //c echo $path` 27288 fi 27289 27290 27291 input_path="$new_path" 27292 # Check if we need to convert this using DOS-style short mode. If the path 27293 # contains just simple characters, use it. Otherwise (spaces, weird characters), 27294 # take no chances and rewrite it. 27295 # Note: m4 eats our [], so we need to use [ and ] instead. 27296 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 27297 if test "x$has_forbidden_chars" != x; then 27298 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 27299 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 27300 fi 27301 27302 27303 windows_path="$new_path" 27304 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 27305 unix_path=`$CYGPATH -u "$windows_path"` 27306 new_path="$unix_path" 27307 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 27308 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 27309 new_path="$unix_path" 27310 fi 27311 27312 if test "x$path" != "x$new_path"; then 27313 BOOT_JDK="$new_path" 27314 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5 27315 $as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;} 27316 fi 27317 27318 # Save the first 10 bytes of this path to the storage, so fixpath can work. 27319 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 27320 27321 else 27322 # We're on a unix platform. Hooray! :) 27323 path="$BOOT_JDK" 27324 has_space=`$ECHO "$path" | $GREP " "` 27325 if test "x$has_space" != x; then 27326 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5 27327 $as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;} 27328 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 27329 fi 27330 27331 # Use eval to expand a potential ~ 27332 eval path="$path" 27333 if test ! -f "$path" && test ! -d "$path"; then 27334 as_fn_error $? "The path of BOOT_JDK, which resolves as \"$path\", is not found." "$LINENO" 5 27335 fi 27336 27337 if test -d "$path"; then 27338 BOOT_JDK="`cd "$path"; $THEPWDCMD -L`" 27339 else 27340 dir="`$DIRNAME "$path"`" 27341 base="`$BASENAME "$path"`" 27342 BOOT_JDK="`cd "$dir"; $THEPWDCMD -L`/$base" 27343 fi 27344 fi 27345 fi 27346 27347 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for Boot JDK" >&5 27348 $as_echo_n "checking for Boot JDK... " >&6; } 27349 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK" >&5 27350 $as_echo "$BOOT_JDK" >&6; } 27351 { $as_echo "$as_me:${as_lineno-$LINENO}: checking Boot JDK version" >&5 27352 $as_echo_n "checking Boot JDK version... " >&6; } 27353 BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | $TR '\n\r' ' '` 27354 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK_VERSION" >&5 27355 $as_echo "$BOOT_JDK_VERSION" >&6; } 27356 fi # end check jdk version 27357 fi # end check javac 27358 fi # end check java 27359 fi # end check boot jdk found 27360 fi 27361 27362 27363 if test "x$BOOT_JDK_FOUND" = xno; then 27364 # Now execute the test 27365 27366 if test "x$PROGRAMFILES" != x; then 27367 VIRTUAL_DIR="$PROGRAMFILES/Java" 27368 27369 windows_path="$VIRTUAL_DIR" 27370 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 27371 unix_path=`$CYGPATH -u "$windows_path"` 27372 VIRTUAL_DIR="$unix_path" 27373 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 27374 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 27375 VIRTUAL_DIR="$unix_path" 27376 fi 27377 27378 27379 BOOT_JDK_PREFIX="$VIRTUAL_DIR" 27380 BOOT_JDK_SUFFIX="" 27381 ALL_JDKS_FOUND=`$LS "$BOOT_JDK_PREFIX" 2> /dev/null | $SORT -r` 27382 if test "x$ALL_JDKS_FOUND" != x; then 27383 for JDK_TO_TRY in $ALL_JDKS_FOUND ; do 27384 27385 if test "x$BOOT_JDK_FOUND" = xno; then 27386 # Now execute the test 27387 27388 BOOT_JDK="${BOOT_JDK_PREFIX}/${JDK_TO_TRY}${BOOT_JDK_SUFFIX}" 27389 if test -d "$BOOT_JDK"; then 27390 BOOT_JDK_FOUND=maybe 27391 { $as_echo "$as_me:${as_lineno-$LINENO}: Found potential Boot JDK using well-known locations (in $BOOT_JDK_PREFIX/$JDK_TO_TRY)" >&5 27392 $as_echo "$as_me: Found potential Boot JDK using well-known locations (in $BOOT_JDK_PREFIX/$JDK_TO_TRY)" >&6;} 27393 fi 27394 27395 27396 # If previous step claimed to have found a JDK, check it to see if it seems to be valid. 27397 if test "x$BOOT_JDK_FOUND" = xmaybe; then 27398 # Do we have a bin/java? 27399 if test ! -x "$BOOT_JDK/bin/java"; then 27400 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&5 27401 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&6;} 27402 BOOT_JDK_FOUND=no 27403 else 27404 # Do we have a bin/javac? 27405 if test ! -x "$BOOT_JDK/bin/javac"; then 27406 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&5 27407 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&6;} 27408 { $as_echo "$as_me:${as_lineno-$LINENO}: (This might be an JRE instead of an JDK)" >&5 27409 $as_echo "$as_me: (This might be an JRE instead of an JDK)" >&6;} 27410 BOOT_JDK_FOUND=no 27411 else 27412 # Oh, this is looking good! We probably have found a proper JDK. Is it the correct version? 27413 BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | $HEAD -n 1` 27414 27415 # Extra M4 quote needed to protect [] in grep expression. 27416 FOUND_CORRECT_VERSION=`$ECHO $BOOT_JDK_VERSION | $EGREP '\"9([\.+-].*)?\"|(1\.[89]\.)'` 27417 if test "x$FOUND_CORRECT_VERSION" = x; then 27418 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&5 27419 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&6;} 27420 { $as_echo "$as_me:${as_lineno-$LINENO}: (Your Boot JDK must be version 8 or 9)" >&5 27421 $as_echo "$as_me: (Your Boot JDK must be version 8 or 9)" >&6;} 27422 BOOT_JDK_FOUND=no 27423 else 27424 # We're done! :-) 27425 BOOT_JDK_FOUND=yes 27426 27427 # Only process if variable expands to non-empty 27428 27429 if test "x$BOOT_JDK" != x; then 27430 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 27431 27432 # Input might be given as Windows format, start by converting to 27433 # unix format. 27434 path="$BOOT_JDK" 27435 new_path=`$CYGPATH -u "$path"` 27436 27437 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 27438 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 27439 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 27440 # "foo.exe" is OK but "foo" is an error. 27441 # 27442 # This test is therefore slightly more accurate than "test -f" to check for file precense. 27443 # It is also a way to make sure we got the proper file name for the real test later on. 27444 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 27445 if test "x$test_shortpath" = x; then 27446 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5 27447 $as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;} 27448 as_fn_error $? "Cannot locate the the path of BOOT_JDK" "$LINENO" 5 27449 fi 27450 27451 # Call helper function which possibly converts this using DOS-style short mode. 27452 # If so, the updated path is stored in $new_path. 27453 27454 input_path="$new_path" 27455 # Check if we need to convert this using DOS-style short mode. If the path 27456 # contains just simple characters, use it. Otherwise (spaces, weird characters), 27457 # take no chances and rewrite it. 27458 # Note: m4 eats our [], so we need to use [ and ] instead. 27459 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 27460 if test "x$has_forbidden_chars" != x; then 27461 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 27462 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 27463 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 27464 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 27465 # Going to short mode and back again did indeed matter. Since short mode is 27466 # case insensitive, let's make it lowercase to improve readability. 27467 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 27468 # Now convert it back to Unix-style (cygpath) 27469 input_path=`$CYGPATH -u "$shortmode_path"` 27470 new_path="$input_path" 27471 fi 27472 fi 27473 27474 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 27475 if test "x$test_cygdrive_prefix" = x; then 27476 # As a simple fix, exclude /usr/bin since it's not a real path. 27477 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 27478 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 27479 # a path prefixed by /cygdrive for fixpath to work. 27480 new_path="$CYGWIN_ROOT_PATH$input_path" 27481 fi 27482 fi 27483 27484 27485 if test "x$path" != "x$new_path"; then 27486 BOOT_JDK="$new_path" 27487 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5 27488 $as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;} 27489 fi 27490 27491 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 27492 27493 path="$BOOT_JDK" 27494 has_colon=`$ECHO $path | $GREP ^.:` 27495 new_path="$path" 27496 if test "x$has_colon" = x; then 27497 # Not in mixed or Windows style, start by that. 27498 new_path=`cmd //c echo $path` 27499 fi 27500 27501 27502 input_path="$new_path" 27503 # Check if we need to convert this using DOS-style short mode. If the path 27504 # contains just simple characters, use it. Otherwise (spaces, weird characters), 27505 # take no chances and rewrite it. 27506 # Note: m4 eats our [], so we need to use [ and ] instead. 27507 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 27508 if test "x$has_forbidden_chars" != x; then 27509 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 27510 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 27511 fi 27512 27513 27514 windows_path="$new_path" 27515 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 27516 unix_path=`$CYGPATH -u "$windows_path"` 27517 new_path="$unix_path" 27518 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 27519 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 27520 new_path="$unix_path" 27521 fi 27522 27523 if test "x$path" != "x$new_path"; then 27524 BOOT_JDK="$new_path" 27525 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5 27526 $as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;} 27527 fi 27528 27529 # Save the first 10 bytes of this path to the storage, so fixpath can work. 27530 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 27531 27532 else 27533 # We're on a unix platform. Hooray! :) 27534 path="$BOOT_JDK" 27535 has_space=`$ECHO "$path" | $GREP " "` 27536 if test "x$has_space" != x; then 27537 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5 27538 $as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;} 27539 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 27540 fi 27541 27542 # Use eval to expand a potential ~ 27543 eval path="$path" 27544 if test ! -f "$path" && test ! -d "$path"; then 27545 as_fn_error $? "The path of BOOT_JDK, which resolves as \"$path\", is not found." "$LINENO" 5 27546 fi 27547 27548 if test -d "$path"; then 27549 BOOT_JDK="`cd "$path"; $THEPWDCMD -L`" 27550 else 27551 dir="`$DIRNAME "$path"`" 27552 base="`$BASENAME "$path"`" 27553 BOOT_JDK="`cd "$dir"; $THEPWDCMD -L`/$base" 27554 fi 27555 fi 27556 fi 27557 27558 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for Boot JDK" >&5 27559 $as_echo_n "checking for Boot JDK... " >&6; } 27560 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK" >&5 27561 $as_echo "$BOOT_JDK" >&6; } 27562 { $as_echo "$as_me:${as_lineno-$LINENO}: checking Boot JDK version" >&5 27563 $as_echo_n "checking Boot JDK version... " >&6; } 27564 BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | $TR '\n\r' ' '` 27565 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK_VERSION" >&5 27566 $as_echo "$BOOT_JDK_VERSION" >&6; } 27567 fi # end check jdk version 27568 fi # end check javac 27569 fi # end check java 27570 fi # end check boot jdk found 27571 fi 27572 27573 done 27574 fi 27575 27576 fi 27577 27578 27579 # If previous step claimed to have found a JDK, check it to see if it seems to be valid. 27580 if test "x$BOOT_JDK_FOUND" = xmaybe; then 27581 # Do we have a bin/java? 27582 if test ! -x "$BOOT_JDK/bin/java"; then 27583 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&5 27584 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&6;} 27585 BOOT_JDK_FOUND=no 27586 else 27587 # Do we have a bin/javac? 27588 if test ! -x "$BOOT_JDK/bin/javac"; then 27589 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&5 27590 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&6;} 27591 { $as_echo "$as_me:${as_lineno-$LINENO}: (This might be an JRE instead of an JDK)" >&5 27592 $as_echo "$as_me: (This might be an JRE instead of an JDK)" >&6;} 27593 BOOT_JDK_FOUND=no 27594 else 27595 # Oh, this is looking good! We probably have found a proper JDK. Is it the correct version? 27596 BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | $HEAD -n 1` 27597 27598 # Extra M4 quote needed to protect [] in grep expression. 27599 FOUND_CORRECT_VERSION=`$ECHO $BOOT_JDK_VERSION | $EGREP '\"9([\.+-].*)?\"|(1\.[89]\.)'` 27600 if test "x$FOUND_CORRECT_VERSION" = x; then 27601 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&5 27602 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&6;} 27603 { $as_echo "$as_me:${as_lineno-$LINENO}: (Your Boot JDK must be version 8 or 9)" >&5 27604 $as_echo "$as_me: (Your Boot JDK must be version 8 or 9)" >&6;} 27605 BOOT_JDK_FOUND=no 27606 else 27607 # We're done! :-) 27608 BOOT_JDK_FOUND=yes 27609 27610 # Only process if variable expands to non-empty 27611 27612 if test "x$BOOT_JDK" != x; then 27613 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 27614 27615 # Input might be given as Windows format, start by converting to 27616 # unix format. 27617 path="$BOOT_JDK" 27618 new_path=`$CYGPATH -u "$path"` 27619 27620 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 27621 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 27622 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 27623 # "foo.exe" is OK but "foo" is an error. 27624 # 27625 # This test is therefore slightly more accurate than "test -f" to check for file precense. 27626 # It is also a way to make sure we got the proper file name for the real test later on. 27627 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 27628 if test "x$test_shortpath" = x; then 27629 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5 27630 $as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;} 27631 as_fn_error $? "Cannot locate the the path of BOOT_JDK" "$LINENO" 5 27632 fi 27633 27634 # Call helper function which possibly converts this using DOS-style short mode. 27635 # If so, the updated path is stored in $new_path. 27636 27637 input_path="$new_path" 27638 # Check if we need to convert this using DOS-style short mode. If the path 27639 # contains just simple characters, use it. Otherwise (spaces, weird characters), 27640 # take no chances and rewrite it. 27641 # Note: m4 eats our [], so we need to use [ and ] instead. 27642 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 27643 if test "x$has_forbidden_chars" != x; then 27644 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 27645 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 27646 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 27647 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 27648 # Going to short mode and back again did indeed matter. Since short mode is 27649 # case insensitive, let's make it lowercase to improve readability. 27650 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 27651 # Now convert it back to Unix-style (cygpath) 27652 input_path=`$CYGPATH -u "$shortmode_path"` 27653 new_path="$input_path" 27654 fi 27655 fi 27656 27657 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 27658 if test "x$test_cygdrive_prefix" = x; then 27659 # As a simple fix, exclude /usr/bin since it's not a real path. 27660 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 27661 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 27662 # a path prefixed by /cygdrive for fixpath to work. 27663 new_path="$CYGWIN_ROOT_PATH$input_path" 27664 fi 27665 fi 27666 27667 27668 if test "x$path" != "x$new_path"; then 27669 BOOT_JDK="$new_path" 27670 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5 27671 $as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;} 27672 fi 27673 27674 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 27675 27676 path="$BOOT_JDK" 27677 has_colon=`$ECHO $path | $GREP ^.:` 27678 new_path="$path" 27679 if test "x$has_colon" = x; then 27680 # Not in mixed or Windows style, start by that. 27681 new_path=`cmd //c echo $path` 27682 fi 27683 27684 27685 input_path="$new_path" 27686 # Check if we need to convert this using DOS-style short mode. If the path 27687 # contains just simple characters, use it. Otherwise (spaces, weird characters), 27688 # take no chances and rewrite it. 27689 # Note: m4 eats our [], so we need to use [ and ] instead. 27690 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 27691 if test "x$has_forbidden_chars" != x; then 27692 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 27693 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 27694 fi 27695 27696 27697 windows_path="$new_path" 27698 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 27699 unix_path=`$CYGPATH -u "$windows_path"` 27700 new_path="$unix_path" 27701 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 27702 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 27703 new_path="$unix_path" 27704 fi 27705 27706 if test "x$path" != "x$new_path"; then 27707 BOOT_JDK="$new_path" 27708 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5 27709 $as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;} 27710 fi 27711 27712 # Save the first 10 bytes of this path to the storage, so fixpath can work. 27713 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 27714 27715 else 27716 # We're on a unix platform. Hooray! :) 27717 path="$BOOT_JDK" 27718 has_space=`$ECHO "$path" | $GREP " "` 27719 if test "x$has_space" != x; then 27720 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5 27721 $as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;} 27722 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 27723 fi 27724 27725 # Use eval to expand a potential ~ 27726 eval path="$path" 27727 if test ! -f "$path" && test ! -d "$path"; then 27728 as_fn_error $? "The path of BOOT_JDK, which resolves as \"$path\", is not found." "$LINENO" 5 27729 fi 27730 27731 if test -d "$path"; then 27732 BOOT_JDK="`cd "$path"; $THEPWDCMD -L`" 27733 else 27734 dir="`$DIRNAME "$path"`" 27735 base="`$BASENAME "$path"`" 27736 BOOT_JDK="`cd "$dir"; $THEPWDCMD -L`/$base" 27737 fi 27738 fi 27739 fi 27740 27741 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for Boot JDK" >&5 27742 $as_echo_n "checking for Boot JDK... " >&6; } 27743 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK" >&5 27744 $as_echo "$BOOT_JDK" >&6; } 27745 { $as_echo "$as_me:${as_lineno-$LINENO}: checking Boot JDK version" >&5 27746 $as_echo_n "checking Boot JDK version... " >&6; } 27747 BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | $TR '\n\r' ' '` 27748 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK_VERSION" >&5 27749 $as_echo "$BOOT_JDK_VERSION" >&6; } 27750 fi # end check jdk version 27751 fi # end check javac 27752 fi # end check java 27753 fi # end check boot jdk found 27754 fi 27755 27756 27757 if test "x$BOOT_JDK_FOUND" = xno; then 27758 # Now execute the test 27759 27760 if test "x$ProgramFiles" != x; then 27761 VIRTUAL_DIR="$ProgramFiles/Java" 27762 27763 windows_path="$VIRTUAL_DIR" 27764 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 27765 unix_path=`$CYGPATH -u "$windows_path"` 27766 VIRTUAL_DIR="$unix_path" 27767 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 27768 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 27769 VIRTUAL_DIR="$unix_path" 27770 fi 27771 27772 27773 BOOT_JDK_PREFIX="$VIRTUAL_DIR" 27774 BOOT_JDK_SUFFIX="" 27775 ALL_JDKS_FOUND=`$LS "$BOOT_JDK_PREFIX" 2> /dev/null | $SORT -r` 27776 if test "x$ALL_JDKS_FOUND" != x; then 27777 for JDK_TO_TRY in $ALL_JDKS_FOUND ; do 27778 27779 if test "x$BOOT_JDK_FOUND" = xno; then 27780 # Now execute the test 27781 27782 BOOT_JDK="${BOOT_JDK_PREFIX}/${JDK_TO_TRY}${BOOT_JDK_SUFFIX}" 27783 if test -d "$BOOT_JDK"; then 27784 BOOT_JDK_FOUND=maybe 27785 { $as_echo "$as_me:${as_lineno-$LINENO}: Found potential Boot JDK using well-known locations (in $BOOT_JDK_PREFIX/$JDK_TO_TRY)" >&5 27786 $as_echo "$as_me: Found potential Boot JDK using well-known locations (in $BOOT_JDK_PREFIX/$JDK_TO_TRY)" >&6;} 27787 fi 27788 27789 27790 # If previous step claimed to have found a JDK, check it to see if it seems to be valid. 27791 if test "x$BOOT_JDK_FOUND" = xmaybe; then 27792 # Do we have a bin/java? 27793 if test ! -x "$BOOT_JDK/bin/java"; then 27794 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&5 27795 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&6;} 27796 BOOT_JDK_FOUND=no 27797 else 27798 # Do we have a bin/javac? 27799 if test ! -x "$BOOT_JDK/bin/javac"; then 27800 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&5 27801 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&6;} 27802 { $as_echo "$as_me:${as_lineno-$LINENO}: (This might be an JRE instead of an JDK)" >&5 27803 $as_echo "$as_me: (This might be an JRE instead of an JDK)" >&6;} 27804 BOOT_JDK_FOUND=no 27805 else 27806 # Oh, this is looking good! We probably have found a proper JDK. Is it the correct version? 27807 BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | $HEAD -n 1` 27808 27809 # Extra M4 quote needed to protect [] in grep expression. 27810 FOUND_CORRECT_VERSION=`$ECHO $BOOT_JDK_VERSION | $EGREP '\"9([\.+-].*)?\"|(1\.[89]\.)'` 27811 if test "x$FOUND_CORRECT_VERSION" = x; then 27812 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&5 27813 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&6;} 27814 { $as_echo "$as_me:${as_lineno-$LINENO}: (Your Boot JDK must be version 8 or 9)" >&5 27815 $as_echo "$as_me: (Your Boot JDK must be version 8 or 9)" >&6;} 27816 BOOT_JDK_FOUND=no 27817 else 27818 # We're done! :-) 27819 BOOT_JDK_FOUND=yes 27820 27821 # Only process if variable expands to non-empty 27822 27823 if test "x$BOOT_JDK" != x; then 27824 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 27825 27826 # Input might be given as Windows format, start by converting to 27827 # unix format. 27828 path="$BOOT_JDK" 27829 new_path=`$CYGPATH -u "$path"` 27830 27831 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 27832 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 27833 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 27834 # "foo.exe" is OK but "foo" is an error. 27835 # 27836 # This test is therefore slightly more accurate than "test -f" to check for file precense. 27837 # It is also a way to make sure we got the proper file name for the real test later on. 27838 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 27839 if test "x$test_shortpath" = x; then 27840 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5 27841 $as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;} 27842 as_fn_error $? "Cannot locate the the path of BOOT_JDK" "$LINENO" 5 27843 fi 27844 27845 # Call helper function which possibly converts this using DOS-style short mode. 27846 # If so, the updated path is stored in $new_path. 27847 27848 input_path="$new_path" 27849 # Check if we need to convert this using DOS-style short mode. If the path 27850 # contains just simple characters, use it. Otherwise (spaces, weird characters), 27851 # take no chances and rewrite it. 27852 # Note: m4 eats our [], so we need to use [ and ] instead. 27853 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 27854 if test "x$has_forbidden_chars" != x; then 27855 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 27856 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 27857 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 27858 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 27859 # Going to short mode and back again did indeed matter. Since short mode is 27860 # case insensitive, let's make it lowercase to improve readability. 27861 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 27862 # Now convert it back to Unix-style (cygpath) 27863 input_path=`$CYGPATH -u "$shortmode_path"` 27864 new_path="$input_path" 27865 fi 27866 fi 27867 27868 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 27869 if test "x$test_cygdrive_prefix" = x; then 27870 # As a simple fix, exclude /usr/bin since it's not a real path. 27871 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 27872 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 27873 # a path prefixed by /cygdrive for fixpath to work. 27874 new_path="$CYGWIN_ROOT_PATH$input_path" 27875 fi 27876 fi 27877 27878 27879 if test "x$path" != "x$new_path"; then 27880 BOOT_JDK="$new_path" 27881 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5 27882 $as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;} 27883 fi 27884 27885 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 27886 27887 path="$BOOT_JDK" 27888 has_colon=`$ECHO $path | $GREP ^.:` 27889 new_path="$path" 27890 if test "x$has_colon" = x; then 27891 # Not in mixed or Windows style, start by that. 27892 new_path=`cmd //c echo $path` 27893 fi 27894 27895 27896 input_path="$new_path" 27897 # Check if we need to convert this using DOS-style short mode. If the path 27898 # contains just simple characters, use it. Otherwise (spaces, weird characters), 27899 # take no chances and rewrite it. 27900 # Note: m4 eats our [], so we need to use [ and ] instead. 27901 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 27902 if test "x$has_forbidden_chars" != x; then 27903 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 27904 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 27905 fi 27906 27907 27908 windows_path="$new_path" 27909 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 27910 unix_path=`$CYGPATH -u "$windows_path"` 27911 new_path="$unix_path" 27912 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 27913 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 27914 new_path="$unix_path" 27915 fi 27916 27917 if test "x$path" != "x$new_path"; then 27918 BOOT_JDK="$new_path" 27919 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5 27920 $as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;} 27921 fi 27922 27923 # Save the first 10 bytes of this path to the storage, so fixpath can work. 27924 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 27925 27926 else 27927 # We're on a unix platform. Hooray! :) 27928 path="$BOOT_JDK" 27929 has_space=`$ECHO "$path" | $GREP " "` 27930 if test "x$has_space" != x; then 27931 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5 27932 $as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;} 27933 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 27934 fi 27935 27936 # Use eval to expand a potential ~ 27937 eval path="$path" 27938 if test ! -f "$path" && test ! -d "$path"; then 27939 as_fn_error $? "The path of BOOT_JDK, which resolves as \"$path\", is not found." "$LINENO" 5 27940 fi 27941 27942 if test -d "$path"; then 27943 BOOT_JDK="`cd "$path"; $THEPWDCMD -L`" 27944 else 27945 dir="`$DIRNAME "$path"`" 27946 base="`$BASENAME "$path"`" 27947 BOOT_JDK="`cd "$dir"; $THEPWDCMD -L`/$base" 27948 fi 27949 fi 27950 fi 27951 27952 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for Boot JDK" >&5 27953 $as_echo_n "checking for Boot JDK... " >&6; } 27954 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK" >&5 27955 $as_echo "$BOOT_JDK" >&6; } 27956 { $as_echo "$as_me:${as_lineno-$LINENO}: checking Boot JDK version" >&5 27957 $as_echo_n "checking Boot JDK version... " >&6; } 27958 BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | $TR '\n\r' ' '` 27959 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK_VERSION" >&5 27960 $as_echo "$BOOT_JDK_VERSION" >&6; } 27961 fi # end check jdk version 27962 fi # end check javac 27963 fi # end check java 27964 fi # end check boot jdk found 27965 fi 27966 27967 done 27968 fi 27969 27970 fi 27971 27972 27973 # If previous step claimed to have found a JDK, check it to see if it seems to be valid. 27974 if test "x$BOOT_JDK_FOUND" = xmaybe; then 27975 # Do we have a bin/java? 27976 if test ! -x "$BOOT_JDK/bin/java"; then 27977 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&5 27978 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&6;} 27979 BOOT_JDK_FOUND=no 27980 else 27981 # Do we have a bin/javac? 27982 if test ! -x "$BOOT_JDK/bin/javac"; then 27983 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&5 27984 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&6;} 27985 { $as_echo "$as_me:${as_lineno-$LINENO}: (This might be an JRE instead of an JDK)" >&5 27986 $as_echo "$as_me: (This might be an JRE instead of an JDK)" >&6;} 27987 BOOT_JDK_FOUND=no 27988 else 27989 # Oh, this is looking good! We probably have found a proper JDK. Is it the correct version? 27990 BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | $HEAD -n 1` 27991 27992 # Extra M4 quote needed to protect [] in grep expression. 27993 FOUND_CORRECT_VERSION=`$ECHO $BOOT_JDK_VERSION | $EGREP '\"9([\.+-].*)?\"|(1\.[89]\.)'` 27994 if test "x$FOUND_CORRECT_VERSION" = x; then 27995 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&5 27996 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&6;} 27997 { $as_echo "$as_me:${as_lineno-$LINENO}: (Your Boot JDK must be version 8 or 9)" >&5 27998 $as_echo "$as_me: (Your Boot JDK must be version 8 or 9)" >&6;} 27999 BOOT_JDK_FOUND=no 28000 else 28001 # We're done! :-) 28002 BOOT_JDK_FOUND=yes 28003 28004 # Only process if variable expands to non-empty 28005 28006 if test "x$BOOT_JDK" != x; then 28007 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 28008 28009 # Input might be given as Windows format, start by converting to 28010 # unix format. 28011 path="$BOOT_JDK" 28012 new_path=`$CYGPATH -u "$path"` 28013 28014 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 28015 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 28016 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 28017 # "foo.exe" is OK but "foo" is an error. 28018 # 28019 # This test is therefore slightly more accurate than "test -f" to check for file precense. 28020 # It is also a way to make sure we got the proper file name for the real test later on. 28021 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 28022 if test "x$test_shortpath" = x; then 28023 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5 28024 $as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;} 28025 as_fn_error $? "Cannot locate the the path of BOOT_JDK" "$LINENO" 5 28026 fi 28027 28028 # Call helper function which possibly converts this using DOS-style short mode. 28029 # If so, the updated path is stored in $new_path. 28030 28031 input_path="$new_path" 28032 # Check if we need to convert this using DOS-style short mode. If the path 28033 # contains just simple characters, use it. Otherwise (spaces, weird characters), 28034 # take no chances and rewrite it. 28035 # Note: m4 eats our [], so we need to use [ and ] instead. 28036 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 28037 if test "x$has_forbidden_chars" != x; then 28038 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 28039 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 28040 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 28041 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 28042 # Going to short mode and back again did indeed matter. Since short mode is 28043 # case insensitive, let's make it lowercase to improve readability. 28044 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 28045 # Now convert it back to Unix-style (cygpath) 28046 input_path=`$CYGPATH -u "$shortmode_path"` 28047 new_path="$input_path" 28048 fi 28049 fi 28050 28051 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 28052 if test "x$test_cygdrive_prefix" = x; then 28053 # As a simple fix, exclude /usr/bin since it's not a real path. 28054 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 28055 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 28056 # a path prefixed by /cygdrive for fixpath to work. 28057 new_path="$CYGWIN_ROOT_PATH$input_path" 28058 fi 28059 fi 28060 28061 28062 if test "x$path" != "x$new_path"; then 28063 BOOT_JDK="$new_path" 28064 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5 28065 $as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;} 28066 fi 28067 28068 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 28069 28070 path="$BOOT_JDK" 28071 has_colon=`$ECHO $path | $GREP ^.:` 28072 new_path="$path" 28073 if test "x$has_colon" = x; then 28074 # Not in mixed or Windows style, start by that. 28075 new_path=`cmd //c echo $path` 28076 fi 28077 28078 28079 input_path="$new_path" 28080 # Check if we need to convert this using DOS-style short mode. If the path 28081 # contains just simple characters, use it. Otherwise (spaces, weird characters), 28082 # take no chances and rewrite it. 28083 # Note: m4 eats our [], so we need to use [ and ] instead. 28084 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 28085 if test "x$has_forbidden_chars" != x; then 28086 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 28087 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 28088 fi 28089 28090 28091 windows_path="$new_path" 28092 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 28093 unix_path=`$CYGPATH -u "$windows_path"` 28094 new_path="$unix_path" 28095 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 28096 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 28097 new_path="$unix_path" 28098 fi 28099 28100 if test "x$path" != "x$new_path"; then 28101 BOOT_JDK="$new_path" 28102 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5 28103 $as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;} 28104 fi 28105 28106 # Save the first 10 bytes of this path to the storage, so fixpath can work. 28107 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 28108 28109 else 28110 # We're on a unix platform. Hooray! :) 28111 path="$BOOT_JDK" 28112 has_space=`$ECHO "$path" | $GREP " "` 28113 if test "x$has_space" != x; then 28114 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5 28115 $as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;} 28116 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 28117 fi 28118 28119 # Use eval to expand a potential ~ 28120 eval path="$path" 28121 if test ! -f "$path" && test ! -d "$path"; then 28122 as_fn_error $? "The path of BOOT_JDK, which resolves as \"$path\", is not found." "$LINENO" 5 28123 fi 28124 28125 if test -d "$path"; then 28126 BOOT_JDK="`cd "$path"; $THEPWDCMD -L`" 28127 else 28128 dir="`$DIRNAME "$path"`" 28129 base="`$BASENAME "$path"`" 28130 BOOT_JDK="`cd "$dir"; $THEPWDCMD -L`/$base" 28131 fi 28132 fi 28133 fi 28134 28135 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for Boot JDK" >&5 28136 $as_echo_n "checking for Boot JDK... " >&6; } 28137 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK" >&5 28138 $as_echo "$BOOT_JDK" >&6; } 28139 { $as_echo "$as_me:${as_lineno-$LINENO}: checking Boot JDK version" >&5 28140 $as_echo_n "checking Boot JDK version... " >&6; } 28141 BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | $TR '\n\r' ' '` 28142 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK_VERSION" >&5 28143 $as_echo "$BOOT_JDK_VERSION" >&6; } 28144 fi # end check jdk version 28145 fi # end check javac 28146 fi # end check java 28147 fi # end check boot jdk found 28148 fi 28149 28150 28151 if test "x$BOOT_JDK_FOUND" = xno; then 28152 # Now execute the test 28153 28154 BOOT_JDK_PREFIX="/cygdrive/c/Program Files/Java" 28155 BOOT_JDK_SUFFIX="" 28156 ALL_JDKS_FOUND=`$LS "$BOOT_JDK_PREFIX" 2> /dev/null | $SORT -r` 28157 if test "x$ALL_JDKS_FOUND" != x; then 28158 for JDK_TO_TRY in $ALL_JDKS_FOUND ; do 28159 28160 if test "x$BOOT_JDK_FOUND" = xno; then 28161 # Now execute the test 28162 28163 BOOT_JDK="${BOOT_JDK_PREFIX}/${JDK_TO_TRY}${BOOT_JDK_SUFFIX}" 28164 if test -d "$BOOT_JDK"; then 28165 BOOT_JDK_FOUND=maybe 28166 { $as_echo "$as_me:${as_lineno-$LINENO}: Found potential Boot JDK using well-known locations (in $BOOT_JDK_PREFIX/$JDK_TO_TRY)" >&5 28167 $as_echo "$as_me: Found potential Boot JDK using well-known locations (in $BOOT_JDK_PREFIX/$JDK_TO_TRY)" >&6;} 28168 fi 28169 28170 28171 # If previous step claimed to have found a JDK, check it to see if it seems to be valid. 28172 if test "x$BOOT_JDK_FOUND" = xmaybe; then 28173 # Do we have a bin/java? 28174 if test ! -x "$BOOT_JDK/bin/java"; then 28175 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&5 28176 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&6;} 28177 BOOT_JDK_FOUND=no 28178 else 28179 # Do we have a bin/javac? 28180 if test ! -x "$BOOT_JDK/bin/javac"; then 28181 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&5 28182 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&6;} 28183 { $as_echo "$as_me:${as_lineno-$LINENO}: (This might be an JRE instead of an JDK)" >&5 28184 $as_echo "$as_me: (This might be an JRE instead of an JDK)" >&6;} 28185 BOOT_JDK_FOUND=no 28186 else 28187 # Oh, this is looking good! We probably have found a proper JDK. Is it the correct version? 28188 BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | $HEAD -n 1` 28189 28190 # Extra M4 quote needed to protect [] in grep expression. 28191 FOUND_CORRECT_VERSION=`$ECHO $BOOT_JDK_VERSION | $EGREP '\"9([\.+-].*)?\"|(1\.[89]\.)'` 28192 if test "x$FOUND_CORRECT_VERSION" = x; then 28193 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&5 28194 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&6;} 28195 { $as_echo "$as_me:${as_lineno-$LINENO}: (Your Boot JDK must be version 8 or 9)" >&5 28196 $as_echo "$as_me: (Your Boot JDK must be version 8 or 9)" >&6;} 28197 BOOT_JDK_FOUND=no 28198 else 28199 # We're done! :-) 28200 BOOT_JDK_FOUND=yes 28201 28202 # Only process if variable expands to non-empty 28203 28204 if test "x$BOOT_JDK" != x; then 28205 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 28206 28207 # Input might be given as Windows format, start by converting to 28208 # unix format. 28209 path="$BOOT_JDK" 28210 new_path=`$CYGPATH -u "$path"` 28211 28212 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 28213 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 28214 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 28215 # "foo.exe" is OK but "foo" is an error. 28216 # 28217 # This test is therefore slightly more accurate than "test -f" to check for file precense. 28218 # It is also a way to make sure we got the proper file name for the real test later on. 28219 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 28220 if test "x$test_shortpath" = x; then 28221 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5 28222 $as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;} 28223 as_fn_error $? "Cannot locate the the path of BOOT_JDK" "$LINENO" 5 28224 fi 28225 28226 # Call helper function which possibly converts this using DOS-style short mode. 28227 # If so, the updated path is stored in $new_path. 28228 28229 input_path="$new_path" 28230 # Check if we need to convert this using DOS-style short mode. If the path 28231 # contains just simple characters, use it. Otherwise (spaces, weird characters), 28232 # take no chances and rewrite it. 28233 # Note: m4 eats our [], so we need to use [ and ] instead. 28234 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 28235 if test "x$has_forbidden_chars" != x; then 28236 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 28237 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 28238 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 28239 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 28240 # Going to short mode and back again did indeed matter. Since short mode is 28241 # case insensitive, let's make it lowercase to improve readability. 28242 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 28243 # Now convert it back to Unix-style (cygpath) 28244 input_path=`$CYGPATH -u "$shortmode_path"` 28245 new_path="$input_path" 28246 fi 28247 fi 28248 28249 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 28250 if test "x$test_cygdrive_prefix" = x; then 28251 # As a simple fix, exclude /usr/bin since it's not a real path. 28252 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 28253 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 28254 # a path prefixed by /cygdrive for fixpath to work. 28255 new_path="$CYGWIN_ROOT_PATH$input_path" 28256 fi 28257 fi 28258 28259 28260 if test "x$path" != "x$new_path"; then 28261 BOOT_JDK="$new_path" 28262 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5 28263 $as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;} 28264 fi 28265 28266 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 28267 28268 path="$BOOT_JDK" 28269 has_colon=`$ECHO $path | $GREP ^.:` 28270 new_path="$path" 28271 if test "x$has_colon" = x; then 28272 # Not in mixed or Windows style, start by that. 28273 new_path=`cmd //c echo $path` 28274 fi 28275 28276 28277 input_path="$new_path" 28278 # Check if we need to convert this using DOS-style short mode. If the path 28279 # contains just simple characters, use it. Otherwise (spaces, weird characters), 28280 # take no chances and rewrite it. 28281 # Note: m4 eats our [], so we need to use [ and ] instead. 28282 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 28283 if test "x$has_forbidden_chars" != x; then 28284 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 28285 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 28286 fi 28287 28288 28289 windows_path="$new_path" 28290 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 28291 unix_path=`$CYGPATH -u "$windows_path"` 28292 new_path="$unix_path" 28293 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 28294 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 28295 new_path="$unix_path" 28296 fi 28297 28298 if test "x$path" != "x$new_path"; then 28299 BOOT_JDK="$new_path" 28300 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5 28301 $as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;} 28302 fi 28303 28304 # Save the first 10 bytes of this path to the storage, so fixpath can work. 28305 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 28306 28307 else 28308 # We're on a unix platform. Hooray! :) 28309 path="$BOOT_JDK" 28310 has_space=`$ECHO "$path" | $GREP " "` 28311 if test "x$has_space" != x; then 28312 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5 28313 $as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;} 28314 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 28315 fi 28316 28317 # Use eval to expand a potential ~ 28318 eval path="$path" 28319 if test ! -f "$path" && test ! -d "$path"; then 28320 as_fn_error $? "The path of BOOT_JDK, which resolves as \"$path\", is not found." "$LINENO" 5 28321 fi 28322 28323 if test -d "$path"; then 28324 BOOT_JDK="`cd "$path"; $THEPWDCMD -L`" 28325 else 28326 dir="`$DIRNAME "$path"`" 28327 base="`$BASENAME "$path"`" 28328 BOOT_JDK="`cd "$dir"; $THEPWDCMD -L`/$base" 28329 fi 28330 fi 28331 fi 28332 28333 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for Boot JDK" >&5 28334 $as_echo_n "checking for Boot JDK... " >&6; } 28335 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK" >&5 28336 $as_echo "$BOOT_JDK" >&6; } 28337 { $as_echo "$as_me:${as_lineno-$LINENO}: checking Boot JDK version" >&5 28338 $as_echo_n "checking Boot JDK version... " >&6; } 28339 BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | $TR '\n\r' ' '` 28340 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK_VERSION" >&5 28341 $as_echo "$BOOT_JDK_VERSION" >&6; } 28342 fi # end check jdk version 28343 fi # end check javac 28344 fi # end check java 28345 fi # end check boot jdk found 28346 fi 28347 28348 done 28349 fi 28350 28351 28352 # If previous step claimed to have found a JDK, check it to see if it seems to be valid. 28353 if test "x$BOOT_JDK_FOUND" = xmaybe; then 28354 # Do we have a bin/java? 28355 if test ! -x "$BOOT_JDK/bin/java"; then 28356 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&5 28357 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&6;} 28358 BOOT_JDK_FOUND=no 28359 else 28360 # Do we have a bin/javac? 28361 if test ! -x "$BOOT_JDK/bin/javac"; then 28362 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&5 28363 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&6;} 28364 { $as_echo "$as_me:${as_lineno-$LINENO}: (This might be an JRE instead of an JDK)" >&5 28365 $as_echo "$as_me: (This might be an JRE instead of an JDK)" >&6;} 28366 BOOT_JDK_FOUND=no 28367 else 28368 # Oh, this is looking good! We probably have found a proper JDK. Is it the correct version? 28369 BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | $HEAD -n 1` 28370 28371 # Extra M4 quote needed to protect [] in grep expression. 28372 FOUND_CORRECT_VERSION=`$ECHO $BOOT_JDK_VERSION | $EGREP '\"9([\.+-].*)?\"|(1\.[89]\.)'` 28373 if test "x$FOUND_CORRECT_VERSION" = x; then 28374 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&5 28375 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&6;} 28376 { $as_echo "$as_me:${as_lineno-$LINENO}: (Your Boot JDK must be version 8 or 9)" >&5 28377 $as_echo "$as_me: (Your Boot JDK must be version 8 or 9)" >&6;} 28378 BOOT_JDK_FOUND=no 28379 else 28380 # We're done! :-) 28381 BOOT_JDK_FOUND=yes 28382 28383 # Only process if variable expands to non-empty 28384 28385 if test "x$BOOT_JDK" != x; then 28386 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 28387 28388 # Input might be given as Windows format, start by converting to 28389 # unix format. 28390 path="$BOOT_JDK" 28391 new_path=`$CYGPATH -u "$path"` 28392 28393 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 28394 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 28395 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 28396 # "foo.exe" is OK but "foo" is an error. 28397 # 28398 # This test is therefore slightly more accurate than "test -f" to check for file precense. 28399 # It is also a way to make sure we got the proper file name for the real test later on. 28400 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 28401 if test "x$test_shortpath" = x; then 28402 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5 28403 $as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;} 28404 as_fn_error $? "Cannot locate the the path of BOOT_JDK" "$LINENO" 5 28405 fi 28406 28407 # Call helper function which possibly converts this using DOS-style short mode. 28408 # If so, the updated path is stored in $new_path. 28409 28410 input_path="$new_path" 28411 # Check if we need to convert this using DOS-style short mode. If the path 28412 # contains just simple characters, use it. Otherwise (spaces, weird characters), 28413 # take no chances and rewrite it. 28414 # Note: m4 eats our [], so we need to use [ and ] instead. 28415 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 28416 if test "x$has_forbidden_chars" != x; then 28417 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 28418 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 28419 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 28420 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 28421 # Going to short mode and back again did indeed matter. Since short mode is 28422 # case insensitive, let's make it lowercase to improve readability. 28423 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 28424 # Now convert it back to Unix-style (cygpath) 28425 input_path=`$CYGPATH -u "$shortmode_path"` 28426 new_path="$input_path" 28427 fi 28428 fi 28429 28430 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 28431 if test "x$test_cygdrive_prefix" = x; then 28432 # As a simple fix, exclude /usr/bin since it's not a real path. 28433 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 28434 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 28435 # a path prefixed by /cygdrive for fixpath to work. 28436 new_path="$CYGWIN_ROOT_PATH$input_path" 28437 fi 28438 fi 28439 28440 28441 if test "x$path" != "x$new_path"; then 28442 BOOT_JDK="$new_path" 28443 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5 28444 $as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;} 28445 fi 28446 28447 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 28448 28449 path="$BOOT_JDK" 28450 has_colon=`$ECHO $path | $GREP ^.:` 28451 new_path="$path" 28452 if test "x$has_colon" = x; then 28453 # Not in mixed or Windows style, start by that. 28454 new_path=`cmd //c echo $path` 28455 fi 28456 28457 28458 input_path="$new_path" 28459 # Check if we need to convert this using DOS-style short mode. If the path 28460 # contains just simple characters, use it. Otherwise (spaces, weird characters), 28461 # take no chances and rewrite it. 28462 # Note: m4 eats our [], so we need to use [ and ] instead. 28463 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 28464 if test "x$has_forbidden_chars" != x; then 28465 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 28466 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 28467 fi 28468 28469 28470 windows_path="$new_path" 28471 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 28472 unix_path=`$CYGPATH -u "$windows_path"` 28473 new_path="$unix_path" 28474 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 28475 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 28476 new_path="$unix_path" 28477 fi 28478 28479 if test "x$path" != "x$new_path"; then 28480 BOOT_JDK="$new_path" 28481 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5 28482 $as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;} 28483 fi 28484 28485 # Save the first 10 bytes of this path to the storage, so fixpath can work. 28486 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 28487 28488 else 28489 # We're on a unix platform. Hooray! :) 28490 path="$BOOT_JDK" 28491 has_space=`$ECHO "$path" | $GREP " "` 28492 if test "x$has_space" != x; then 28493 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5 28494 $as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;} 28495 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 28496 fi 28497 28498 # Use eval to expand a potential ~ 28499 eval path="$path" 28500 if test ! -f "$path" && test ! -d "$path"; then 28501 as_fn_error $? "The path of BOOT_JDK, which resolves as \"$path\", is not found." "$LINENO" 5 28502 fi 28503 28504 if test -d "$path"; then 28505 BOOT_JDK="`cd "$path"; $THEPWDCMD -L`" 28506 else 28507 dir="`$DIRNAME "$path"`" 28508 base="`$BASENAME "$path"`" 28509 BOOT_JDK="`cd "$dir"; $THEPWDCMD -L`/$base" 28510 fi 28511 fi 28512 fi 28513 28514 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for Boot JDK" >&5 28515 $as_echo_n "checking for Boot JDK... " >&6; } 28516 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK" >&5 28517 $as_echo "$BOOT_JDK" >&6; } 28518 { $as_echo "$as_me:${as_lineno-$LINENO}: checking Boot JDK version" >&5 28519 $as_echo_n "checking Boot JDK version... " >&6; } 28520 BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | $TR '\n\r' ' '` 28521 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK_VERSION" >&5 28522 $as_echo "$BOOT_JDK_VERSION" >&6; } 28523 fi # end check jdk version 28524 fi # end check javac 28525 fi # end check java 28526 fi # end check boot jdk found 28527 fi 28528 28529 elif test "x$OPENJDK_TARGET_OS" = xmacosx; then 28530 28531 if test "x$BOOT_JDK_FOUND" = xno; then 28532 # Now execute the test 28533 28534 BOOT_JDK_PREFIX="/Library/Java/JavaVirtualMachines" 28535 BOOT_JDK_SUFFIX="/Contents/Home" 28536 ALL_JDKS_FOUND=`$LS "$BOOT_JDK_PREFIX" 2> /dev/null | $SORT -r` 28537 if test "x$ALL_JDKS_FOUND" != x; then 28538 for JDK_TO_TRY in $ALL_JDKS_FOUND ; do 28539 28540 if test "x$BOOT_JDK_FOUND" = xno; then 28541 # Now execute the test 28542 28543 BOOT_JDK="${BOOT_JDK_PREFIX}/${JDK_TO_TRY}${BOOT_JDK_SUFFIX}" 28544 if test -d "$BOOT_JDK"; then 28545 BOOT_JDK_FOUND=maybe 28546 { $as_echo "$as_me:${as_lineno-$LINENO}: Found potential Boot JDK using well-known locations (in $BOOT_JDK_PREFIX/$JDK_TO_TRY)" >&5 28547 $as_echo "$as_me: Found potential Boot JDK using well-known locations (in $BOOT_JDK_PREFIX/$JDK_TO_TRY)" >&6;} 28548 fi 28549 28550 28551 # If previous step claimed to have found a JDK, check it to see if it seems to be valid. 28552 if test "x$BOOT_JDK_FOUND" = xmaybe; then 28553 # Do we have a bin/java? 28554 if test ! -x "$BOOT_JDK/bin/java"; then 28555 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&5 28556 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&6;} 28557 BOOT_JDK_FOUND=no 28558 else 28559 # Do we have a bin/javac? 28560 if test ! -x "$BOOT_JDK/bin/javac"; then 28561 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&5 28562 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&6;} 28563 { $as_echo "$as_me:${as_lineno-$LINENO}: (This might be an JRE instead of an JDK)" >&5 28564 $as_echo "$as_me: (This might be an JRE instead of an JDK)" >&6;} 28565 BOOT_JDK_FOUND=no 28566 else 28567 # Oh, this is looking good! We probably have found a proper JDK. Is it the correct version? 28568 BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | $HEAD -n 1` 28569 28570 # Extra M4 quote needed to protect [] in grep expression. 28571 FOUND_CORRECT_VERSION=`$ECHO $BOOT_JDK_VERSION | $EGREP '\"9([\.+-].*)?\"|(1\.[89]\.)'` 28572 if test "x$FOUND_CORRECT_VERSION" = x; then 28573 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&5 28574 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&6;} 28575 { $as_echo "$as_me:${as_lineno-$LINENO}: (Your Boot JDK must be version 8 or 9)" >&5 28576 $as_echo "$as_me: (Your Boot JDK must be version 8 or 9)" >&6;} 28577 BOOT_JDK_FOUND=no 28578 else 28579 # We're done! :-) 28580 BOOT_JDK_FOUND=yes 28581 28582 # Only process if variable expands to non-empty 28583 28584 if test "x$BOOT_JDK" != x; then 28585 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 28586 28587 # Input might be given as Windows format, start by converting to 28588 # unix format. 28589 path="$BOOT_JDK" 28590 new_path=`$CYGPATH -u "$path"` 28591 28592 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 28593 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 28594 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 28595 # "foo.exe" is OK but "foo" is an error. 28596 # 28597 # This test is therefore slightly more accurate than "test -f" to check for file precense. 28598 # It is also a way to make sure we got the proper file name for the real test later on. 28599 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 28600 if test "x$test_shortpath" = x; then 28601 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5 28602 $as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;} 28603 as_fn_error $? "Cannot locate the the path of BOOT_JDK" "$LINENO" 5 28604 fi 28605 28606 # Call helper function which possibly converts this using DOS-style short mode. 28607 # If so, the updated path is stored in $new_path. 28608 28609 input_path="$new_path" 28610 # Check if we need to convert this using DOS-style short mode. If the path 28611 # contains just simple characters, use it. Otherwise (spaces, weird characters), 28612 # take no chances and rewrite it. 28613 # Note: m4 eats our [], so we need to use [ and ] instead. 28614 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 28615 if test "x$has_forbidden_chars" != x; then 28616 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 28617 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 28618 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 28619 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 28620 # Going to short mode and back again did indeed matter. Since short mode is 28621 # case insensitive, let's make it lowercase to improve readability. 28622 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 28623 # Now convert it back to Unix-style (cygpath) 28624 input_path=`$CYGPATH -u "$shortmode_path"` 28625 new_path="$input_path" 28626 fi 28627 fi 28628 28629 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 28630 if test "x$test_cygdrive_prefix" = x; then 28631 # As a simple fix, exclude /usr/bin since it's not a real path. 28632 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 28633 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 28634 # a path prefixed by /cygdrive for fixpath to work. 28635 new_path="$CYGWIN_ROOT_PATH$input_path" 28636 fi 28637 fi 28638 28639 28640 if test "x$path" != "x$new_path"; then 28641 BOOT_JDK="$new_path" 28642 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5 28643 $as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;} 28644 fi 28645 28646 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 28647 28648 path="$BOOT_JDK" 28649 has_colon=`$ECHO $path | $GREP ^.:` 28650 new_path="$path" 28651 if test "x$has_colon" = x; then 28652 # Not in mixed or Windows style, start by that. 28653 new_path=`cmd //c echo $path` 28654 fi 28655 28656 28657 input_path="$new_path" 28658 # Check if we need to convert this using DOS-style short mode. If the path 28659 # contains just simple characters, use it. Otherwise (spaces, weird characters), 28660 # take no chances and rewrite it. 28661 # Note: m4 eats our [], so we need to use [ and ] instead. 28662 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 28663 if test "x$has_forbidden_chars" != x; then 28664 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 28665 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 28666 fi 28667 28668 28669 windows_path="$new_path" 28670 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 28671 unix_path=`$CYGPATH -u "$windows_path"` 28672 new_path="$unix_path" 28673 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 28674 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 28675 new_path="$unix_path" 28676 fi 28677 28678 if test "x$path" != "x$new_path"; then 28679 BOOT_JDK="$new_path" 28680 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5 28681 $as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;} 28682 fi 28683 28684 # Save the first 10 bytes of this path to the storage, so fixpath can work. 28685 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 28686 28687 else 28688 # We're on a unix platform. Hooray! :) 28689 path="$BOOT_JDK" 28690 has_space=`$ECHO "$path" | $GREP " "` 28691 if test "x$has_space" != x; then 28692 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5 28693 $as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;} 28694 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 28695 fi 28696 28697 # Use eval to expand a potential ~ 28698 eval path="$path" 28699 if test ! -f "$path" && test ! -d "$path"; then 28700 as_fn_error $? "The path of BOOT_JDK, which resolves as \"$path\", is not found." "$LINENO" 5 28701 fi 28702 28703 if test -d "$path"; then 28704 BOOT_JDK="`cd "$path"; $THEPWDCMD -L`" 28705 else 28706 dir="`$DIRNAME "$path"`" 28707 base="`$BASENAME "$path"`" 28708 BOOT_JDK="`cd "$dir"; $THEPWDCMD -L`/$base" 28709 fi 28710 fi 28711 fi 28712 28713 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for Boot JDK" >&5 28714 $as_echo_n "checking for Boot JDK... " >&6; } 28715 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK" >&5 28716 $as_echo "$BOOT_JDK" >&6; } 28717 { $as_echo "$as_me:${as_lineno-$LINENO}: checking Boot JDK version" >&5 28718 $as_echo_n "checking Boot JDK version... " >&6; } 28719 BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | $TR '\n\r' ' '` 28720 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK_VERSION" >&5 28721 $as_echo "$BOOT_JDK_VERSION" >&6; } 28722 fi # end check jdk version 28723 fi # end check javac 28724 fi # end check java 28725 fi # end check boot jdk found 28726 fi 28727 28728 done 28729 fi 28730 28731 28732 # If previous step claimed to have found a JDK, check it to see if it seems to be valid. 28733 if test "x$BOOT_JDK_FOUND" = xmaybe; then 28734 # Do we have a bin/java? 28735 if test ! -x "$BOOT_JDK/bin/java"; then 28736 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&5 28737 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&6;} 28738 BOOT_JDK_FOUND=no 28739 else 28740 # Do we have a bin/javac? 28741 if test ! -x "$BOOT_JDK/bin/javac"; then 28742 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&5 28743 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&6;} 28744 { $as_echo "$as_me:${as_lineno-$LINENO}: (This might be an JRE instead of an JDK)" >&5 28745 $as_echo "$as_me: (This might be an JRE instead of an JDK)" >&6;} 28746 BOOT_JDK_FOUND=no 28747 else 28748 # Oh, this is looking good! We probably have found a proper JDK. Is it the correct version? 28749 BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | $HEAD -n 1` 28750 28751 # Extra M4 quote needed to protect [] in grep expression. 28752 FOUND_CORRECT_VERSION=`$ECHO $BOOT_JDK_VERSION | $EGREP '\"9([\.+-].*)?\"|(1\.[89]\.)'` 28753 if test "x$FOUND_CORRECT_VERSION" = x; then 28754 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&5 28755 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&6;} 28756 { $as_echo "$as_me:${as_lineno-$LINENO}: (Your Boot JDK must be version 8 or 9)" >&5 28757 $as_echo "$as_me: (Your Boot JDK must be version 8 or 9)" >&6;} 28758 BOOT_JDK_FOUND=no 28759 else 28760 # We're done! :-) 28761 BOOT_JDK_FOUND=yes 28762 28763 # Only process if variable expands to non-empty 28764 28765 if test "x$BOOT_JDK" != x; then 28766 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 28767 28768 # Input might be given as Windows format, start by converting to 28769 # unix format. 28770 path="$BOOT_JDK" 28771 new_path=`$CYGPATH -u "$path"` 28772 28773 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 28774 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 28775 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 28776 # "foo.exe" is OK but "foo" is an error. 28777 # 28778 # This test is therefore slightly more accurate than "test -f" to check for file precense. 28779 # It is also a way to make sure we got the proper file name for the real test later on. 28780 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 28781 if test "x$test_shortpath" = x; then 28782 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5 28783 $as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;} 28784 as_fn_error $? "Cannot locate the the path of BOOT_JDK" "$LINENO" 5 28785 fi 28786 28787 # Call helper function which possibly converts this using DOS-style short mode. 28788 # If so, the updated path is stored in $new_path. 28789 28790 input_path="$new_path" 28791 # Check if we need to convert this using DOS-style short mode. If the path 28792 # contains just simple characters, use it. Otherwise (spaces, weird characters), 28793 # take no chances and rewrite it. 28794 # Note: m4 eats our [], so we need to use [ and ] instead. 28795 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 28796 if test "x$has_forbidden_chars" != x; then 28797 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 28798 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 28799 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 28800 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 28801 # Going to short mode and back again did indeed matter. Since short mode is 28802 # case insensitive, let's make it lowercase to improve readability. 28803 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 28804 # Now convert it back to Unix-style (cygpath) 28805 input_path=`$CYGPATH -u "$shortmode_path"` 28806 new_path="$input_path" 28807 fi 28808 fi 28809 28810 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 28811 if test "x$test_cygdrive_prefix" = x; then 28812 # As a simple fix, exclude /usr/bin since it's not a real path. 28813 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 28814 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 28815 # a path prefixed by /cygdrive for fixpath to work. 28816 new_path="$CYGWIN_ROOT_PATH$input_path" 28817 fi 28818 fi 28819 28820 28821 if test "x$path" != "x$new_path"; then 28822 BOOT_JDK="$new_path" 28823 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5 28824 $as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;} 28825 fi 28826 28827 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 28828 28829 path="$BOOT_JDK" 28830 has_colon=`$ECHO $path | $GREP ^.:` 28831 new_path="$path" 28832 if test "x$has_colon" = x; then 28833 # Not in mixed or Windows style, start by that. 28834 new_path=`cmd //c echo $path` 28835 fi 28836 28837 28838 input_path="$new_path" 28839 # Check if we need to convert this using DOS-style short mode. If the path 28840 # contains just simple characters, use it. Otherwise (spaces, weird characters), 28841 # take no chances and rewrite it. 28842 # Note: m4 eats our [], so we need to use [ and ] instead. 28843 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 28844 if test "x$has_forbidden_chars" != x; then 28845 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 28846 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 28847 fi 28848 28849 28850 windows_path="$new_path" 28851 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 28852 unix_path=`$CYGPATH -u "$windows_path"` 28853 new_path="$unix_path" 28854 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 28855 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 28856 new_path="$unix_path" 28857 fi 28858 28859 if test "x$path" != "x$new_path"; then 28860 BOOT_JDK="$new_path" 28861 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5 28862 $as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;} 28863 fi 28864 28865 # Save the first 10 bytes of this path to the storage, so fixpath can work. 28866 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 28867 28868 else 28869 # We're on a unix platform. Hooray! :) 28870 path="$BOOT_JDK" 28871 has_space=`$ECHO "$path" | $GREP " "` 28872 if test "x$has_space" != x; then 28873 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5 28874 $as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;} 28875 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 28876 fi 28877 28878 # Use eval to expand a potential ~ 28879 eval path="$path" 28880 if test ! -f "$path" && test ! -d "$path"; then 28881 as_fn_error $? "The path of BOOT_JDK, which resolves as \"$path\", is not found." "$LINENO" 5 28882 fi 28883 28884 if test -d "$path"; then 28885 BOOT_JDK="`cd "$path"; $THEPWDCMD -L`" 28886 else 28887 dir="`$DIRNAME "$path"`" 28888 base="`$BASENAME "$path"`" 28889 BOOT_JDK="`cd "$dir"; $THEPWDCMD -L`/$base" 28890 fi 28891 fi 28892 fi 28893 28894 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for Boot JDK" >&5 28895 $as_echo_n "checking for Boot JDK... " >&6; } 28896 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK" >&5 28897 $as_echo "$BOOT_JDK" >&6; } 28898 { $as_echo "$as_me:${as_lineno-$LINENO}: checking Boot JDK version" >&5 28899 $as_echo_n "checking Boot JDK version... " >&6; } 28900 BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | $TR '\n\r' ' '` 28901 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK_VERSION" >&5 28902 $as_echo "$BOOT_JDK_VERSION" >&6; } 28903 fi # end check jdk version 28904 fi # end check javac 28905 fi # end check java 28906 fi # end check boot jdk found 28907 fi 28908 28909 28910 if test "x$BOOT_JDK_FOUND" = xno; then 28911 # Now execute the test 28912 28913 BOOT_JDK_PREFIX="/System/Library/Java/JavaVirtualMachines" 28914 BOOT_JDK_SUFFIX="/Contents/Home" 28915 ALL_JDKS_FOUND=`$LS "$BOOT_JDK_PREFIX" 2> /dev/null | $SORT -r` 28916 if test "x$ALL_JDKS_FOUND" != x; then 28917 for JDK_TO_TRY in $ALL_JDKS_FOUND ; do 28918 28919 if test "x$BOOT_JDK_FOUND" = xno; then 28920 # Now execute the test 28921 28922 BOOT_JDK="${BOOT_JDK_PREFIX}/${JDK_TO_TRY}${BOOT_JDK_SUFFIX}" 28923 if test -d "$BOOT_JDK"; then 28924 BOOT_JDK_FOUND=maybe 28925 { $as_echo "$as_me:${as_lineno-$LINENO}: Found potential Boot JDK using well-known locations (in $BOOT_JDK_PREFIX/$JDK_TO_TRY)" >&5 28926 $as_echo "$as_me: Found potential Boot JDK using well-known locations (in $BOOT_JDK_PREFIX/$JDK_TO_TRY)" >&6;} 28927 fi 28928 28929 28930 # If previous step claimed to have found a JDK, check it to see if it seems to be valid. 28931 if test "x$BOOT_JDK_FOUND" = xmaybe; then 28932 # Do we have a bin/java? 28933 if test ! -x "$BOOT_JDK/bin/java"; then 28934 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&5 28935 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&6;} 28936 BOOT_JDK_FOUND=no 28937 else 28938 # Do we have a bin/javac? 28939 if test ! -x "$BOOT_JDK/bin/javac"; then 28940 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&5 28941 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&6;} 28942 { $as_echo "$as_me:${as_lineno-$LINENO}: (This might be an JRE instead of an JDK)" >&5 28943 $as_echo "$as_me: (This might be an JRE instead of an JDK)" >&6;} 28944 BOOT_JDK_FOUND=no 28945 else 28946 # Oh, this is looking good! We probably have found a proper JDK. Is it the correct version? 28947 BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | $HEAD -n 1` 28948 28949 # Extra M4 quote needed to protect [] in grep expression. 28950 FOUND_CORRECT_VERSION=`$ECHO $BOOT_JDK_VERSION | $EGREP '\"9([\.+-].*)?\"|(1\.[89]\.)'` 28951 if test "x$FOUND_CORRECT_VERSION" = x; then 28952 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&5 28953 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&6;} 28954 { $as_echo "$as_me:${as_lineno-$LINENO}: (Your Boot JDK must be version 8 or 9)" >&5 28955 $as_echo "$as_me: (Your Boot JDK must be version 8 or 9)" >&6;} 28956 BOOT_JDK_FOUND=no 28957 else 28958 # We're done! :-) 28959 BOOT_JDK_FOUND=yes 28960 28961 # Only process if variable expands to non-empty 28962 28963 if test "x$BOOT_JDK" != x; then 28964 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 28965 28966 # Input might be given as Windows format, start by converting to 28967 # unix format. 28968 path="$BOOT_JDK" 28969 new_path=`$CYGPATH -u "$path"` 28970 28971 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 28972 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 28973 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 28974 # "foo.exe" is OK but "foo" is an error. 28975 # 28976 # This test is therefore slightly more accurate than "test -f" to check for file precense. 28977 # It is also a way to make sure we got the proper file name for the real test later on. 28978 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 28979 if test "x$test_shortpath" = x; then 28980 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5 28981 $as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;} 28982 as_fn_error $? "Cannot locate the the path of BOOT_JDK" "$LINENO" 5 28983 fi 28984 28985 # Call helper function which possibly converts this using DOS-style short mode. 28986 # If so, the updated path is stored in $new_path. 28987 28988 input_path="$new_path" 28989 # Check if we need to convert this using DOS-style short mode. If the path 28990 # contains just simple characters, use it. Otherwise (spaces, weird characters), 28991 # take no chances and rewrite it. 28992 # Note: m4 eats our [], so we need to use [ and ] instead. 28993 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 28994 if test "x$has_forbidden_chars" != x; then 28995 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 28996 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 28997 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 28998 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 28999 # Going to short mode and back again did indeed matter. Since short mode is 29000 # case insensitive, let's make it lowercase to improve readability. 29001 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 29002 # Now convert it back to Unix-style (cygpath) 29003 input_path=`$CYGPATH -u "$shortmode_path"` 29004 new_path="$input_path" 29005 fi 29006 fi 29007 29008 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 29009 if test "x$test_cygdrive_prefix" = x; then 29010 # As a simple fix, exclude /usr/bin since it's not a real path. 29011 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 29012 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 29013 # a path prefixed by /cygdrive for fixpath to work. 29014 new_path="$CYGWIN_ROOT_PATH$input_path" 29015 fi 29016 fi 29017 29018 29019 if test "x$path" != "x$new_path"; then 29020 BOOT_JDK="$new_path" 29021 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5 29022 $as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;} 29023 fi 29024 29025 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 29026 29027 path="$BOOT_JDK" 29028 has_colon=`$ECHO $path | $GREP ^.:` 29029 new_path="$path" 29030 if test "x$has_colon" = x; then 29031 # Not in mixed or Windows style, start by that. 29032 new_path=`cmd //c echo $path` 29033 fi 29034 29035 29036 input_path="$new_path" 29037 # Check if we need to convert this using DOS-style short mode. If the path 29038 # contains just simple characters, use it. Otherwise (spaces, weird characters), 29039 # take no chances and rewrite it. 29040 # Note: m4 eats our [], so we need to use [ and ] instead. 29041 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 29042 if test "x$has_forbidden_chars" != x; then 29043 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 29044 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 29045 fi 29046 29047 29048 windows_path="$new_path" 29049 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 29050 unix_path=`$CYGPATH -u "$windows_path"` 29051 new_path="$unix_path" 29052 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 29053 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 29054 new_path="$unix_path" 29055 fi 29056 29057 if test "x$path" != "x$new_path"; then 29058 BOOT_JDK="$new_path" 29059 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5 29060 $as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;} 29061 fi 29062 29063 # Save the first 10 bytes of this path to the storage, so fixpath can work. 29064 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 29065 29066 else 29067 # We're on a unix platform. Hooray! :) 29068 path="$BOOT_JDK" 29069 has_space=`$ECHO "$path" | $GREP " "` 29070 if test "x$has_space" != x; then 29071 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5 29072 $as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;} 29073 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 29074 fi 29075 29076 # Use eval to expand a potential ~ 29077 eval path="$path" 29078 if test ! -f "$path" && test ! -d "$path"; then 29079 as_fn_error $? "The path of BOOT_JDK, which resolves as \"$path\", is not found." "$LINENO" 5 29080 fi 29081 29082 if test -d "$path"; then 29083 BOOT_JDK="`cd "$path"; $THEPWDCMD -L`" 29084 else 29085 dir="`$DIRNAME "$path"`" 29086 base="`$BASENAME "$path"`" 29087 BOOT_JDK="`cd "$dir"; $THEPWDCMD -L`/$base" 29088 fi 29089 fi 29090 fi 29091 29092 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for Boot JDK" >&5 29093 $as_echo_n "checking for Boot JDK... " >&6; } 29094 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK" >&5 29095 $as_echo "$BOOT_JDK" >&6; } 29096 { $as_echo "$as_me:${as_lineno-$LINENO}: checking Boot JDK version" >&5 29097 $as_echo_n "checking Boot JDK version... " >&6; } 29098 BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | $TR '\n\r' ' '` 29099 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK_VERSION" >&5 29100 $as_echo "$BOOT_JDK_VERSION" >&6; } 29101 fi # end check jdk version 29102 fi # end check javac 29103 fi # end check java 29104 fi # end check boot jdk found 29105 fi 29106 29107 done 29108 fi 29109 29110 29111 # If previous step claimed to have found a JDK, check it to see if it seems to be valid. 29112 if test "x$BOOT_JDK_FOUND" = xmaybe; then 29113 # Do we have a bin/java? 29114 if test ! -x "$BOOT_JDK/bin/java"; then 29115 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&5 29116 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&6;} 29117 BOOT_JDK_FOUND=no 29118 else 29119 # Do we have a bin/javac? 29120 if test ! -x "$BOOT_JDK/bin/javac"; then 29121 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&5 29122 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&6;} 29123 { $as_echo "$as_me:${as_lineno-$LINENO}: (This might be an JRE instead of an JDK)" >&5 29124 $as_echo "$as_me: (This might be an JRE instead of an JDK)" >&6;} 29125 BOOT_JDK_FOUND=no 29126 else 29127 # Oh, this is looking good! We probably have found a proper JDK. Is it the correct version? 29128 BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | $HEAD -n 1` 29129 29130 # Extra M4 quote needed to protect [] in grep expression. 29131 FOUND_CORRECT_VERSION=`$ECHO $BOOT_JDK_VERSION | $EGREP '\"9([\.+-].*)?\"|(1\.[89]\.)'` 29132 if test "x$FOUND_CORRECT_VERSION" = x; then 29133 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&5 29134 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&6;} 29135 { $as_echo "$as_me:${as_lineno-$LINENO}: (Your Boot JDK must be version 8 or 9)" >&5 29136 $as_echo "$as_me: (Your Boot JDK must be version 8 or 9)" >&6;} 29137 BOOT_JDK_FOUND=no 29138 else 29139 # We're done! :-) 29140 BOOT_JDK_FOUND=yes 29141 29142 # Only process if variable expands to non-empty 29143 29144 if test "x$BOOT_JDK" != x; then 29145 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 29146 29147 # Input might be given as Windows format, start by converting to 29148 # unix format. 29149 path="$BOOT_JDK" 29150 new_path=`$CYGPATH -u "$path"` 29151 29152 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 29153 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 29154 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 29155 # "foo.exe" is OK but "foo" is an error. 29156 # 29157 # This test is therefore slightly more accurate than "test -f" to check for file precense. 29158 # It is also a way to make sure we got the proper file name for the real test later on. 29159 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 29160 if test "x$test_shortpath" = x; then 29161 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5 29162 $as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;} 29163 as_fn_error $? "Cannot locate the the path of BOOT_JDK" "$LINENO" 5 29164 fi 29165 29166 # Call helper function which possibly converts this using DOS-style short mode. 29167 # If so, the updated path is stored in $new_path. 29168 29169 input_path="$new_path" 29170 # Check if we need to convert this using DOS-style short mode. If the path 29171 # contains just simple characters, use it. Otherwise (spaces, weird characters), 29172 # take no chances and rewrite it. 29173 # Note: m4 eats our [], so we need to use [ and ] instead. 29174 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 29175 if test "x$has_forbidden_chars" != x; then 29176 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 29177 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 29178 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 29179 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 29180 # Going to short mode and back again did indeed matter. Since short mode is 29181 # case insensitive, let's make it lowercase to improve readability. 29182 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 29183 # Now convert it back to Unix-style (cygpath) 29184 input_path=`$CYGPATH -u "$shortmode_path"` 29185 new_path="$input_path" 29186 fi 29187 fi 29188 29189 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 29190 if test "x$test_cygdrive_prefix" = x; then 29191 # As a simple fix, exclude /usr/bin since it's not a real path. 29192 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 29193 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 29194 # a path prefixed by /cygdrive for fixpath to work. 29195 new_path="$CYGWIN_ROOT_PATH$input_path" 29196 fi 29197 fi 29198 29199 29200 if test "x$path" != "x$new_path"; then 29201 BOOT_JDK="$new_path" 29202 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5 29203 $as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;} 29204 fi 29205 29206 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 29207 29208 path="$BOOT_JDK" 29209 has_colon=`$ECHO $path | $GREP ^.:` 29210 new_path="$path" 29211 if test "x$has_colon" = x; then 29212 # Not in mixed or Windows style, start by that. 29213 new_path=`cmd //c echo $path` 29214 fi 29215 29216 29217 input_path="$new_path" 29218 # Check if we need to convert this using DOS-style short mode. If the path 29219 # contains just simple characters, use it. Otherwise (spaces, weird characters), 29220 # take no chances and rewrite it. 29221 # Note: m4 eats our [], so we need to use [ and ] instead. 29222 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 29223 if test "x$has_forbidden_chars" != x; then 29224 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 29225 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 29226 fi 29227 29228 29229 windows_path="$new_path" 29230 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 29231 unix_path=`$CYGPATH -u "$windows_path"` 29232 new_path="$unix_path" 29233 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 29234 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 29235 new_path="$unix_path" 29236 fi 29237 29238 if test "x$path" != "x$new_path"; then 29239 BOOT_JDK="$new_path" 29240 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5 29241 $as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;} 29242 fi 29243 29244 # Save the first 10 bytes of this path to the storage, so fixpath can work. 29245 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 29246 29247 else 29248 # We're on a unix platform. Hooray! :) 29249 path="$BOOT_JDK" 29250 has_space=`$ECHO "$path" | $GREP " "` 29251 if test "x$has_space" != x; then 29252 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5 29253 $as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;} 29254 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 29255 fi 29256 29257 # Use eval to expand a potential ~ 29258 eval path="$path" 29259 if test ! -f "$path" && test ! -d "$path"; then 29260 as_fn_error $? "The path of BOOT_JDK, which resolves as \"$path\", is not found." "$LINENO" 5 29261 fi 29262 29263 if test -d "$path"; then 29264 BOOT_JDK="`cd "$path"; $THEPWDCMD -L`" 29265 else 29266 dir="`$DIRNAME "$path"`" 29267 base="`$BASENAME "$path"`" 29268 BOOT_JDK="`cd "$dir"; $THEPWDCMD -L`/$base" 29269 fi 29270 fi 29271 fi 29272 29273 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for Boot JDK" >&5 29274 $as_echo_n "checking for Boot JDK... " >&6; } 29275 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK" >&5 29276 $as_echo "$BOOT_JDK" >&6; } 29277 { $as_echo "$as_me:${as_lineno-$LINENO}: checking Boot JDK version" >&5 29278 $as_echo_n "checking Boot JDK version... " >&6; } 29279 BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | $TR '\n\r' ' '` 29280 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK_VERSION" >&5 29281 $as_echo "$BOOT_JDK_VERSION" >&6; } 29282 fi # end check jdk version 29283 fi # end check javac 29284 fi # end check java 29285 fi # end check boot jdk found 29286 fi 29287 29288 elif test "x$OPENJDK_TARGET_OS" = xlinux; then 29289 29290 if test "x$BOOT_JDK_FOUND" = xno; then 29291 # Now execute the test 29292 29293 BOOT_JDK_PREFIX="/usr/lib/jvm" 29294 BOOT_JDK_SUFFIX="" 29295 ALL_JDKS_FOUND=`$LS "$BOOT_JDK_PREFIX" 2> /dev/null | $SORT -r` 29296 if test "x$ALL_JDKS_FOUND" != x; then 29297 for JDK_TO_TRY in $ALL_JDKS_FOUND ; do 29298 29299 if test "x$BOOT_JDK_FOUND" = xno; then 29300 # Now execute the test 29301 29302 BOOT_JDK="${BOOT_JDK_PREFIX}/${JDK_TO_TRY}${BOOT_JDK_SUFFIX}" 29303 if test -d "$BOOT_JDK"; then 29304 BOOT_JDK_FOUND=maybe 29305 { $as_echo "$as_me:${as_lineno-$LINENO}: Found potential Boot JDK using well-known locations (in $BOOT_JDK_PREFIX/$JDK_TO_TRY)" >&5 29306 $as_echo "$as_me: Found potential Boot JDK using well-known locations (in $BOOT_JDK_PREFIX/$JDK_TO_TRY)" >&6;} 29307 fi 29308 29309 29310 # If previous step claimed to have found a JDK, check it to see if it seems to be valid. 29311 if test "x$BOOT_JDK_FOUND" = xmaybe; then 29312 # Do we have a bin/java? 29313 if test ! -x "$BOOT_JDK/bin/java"; then 29314 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&5 29315 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&6;} 29316 BOOT_JDK_FOUND=no 29317 else 29318 # Do we have a bin/javac? 29319 if test ! -x "$BOOT_JDK/bin/javac"; then 29320 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&5 29321 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&6;} 29322 { $as_echo "$as_me:${as_lineno-$LINENO}: (This might be an JRE instead of an JDK)" >&5 29323 $as_echo "$as_me: (This might be an JRE instead of an JDK)" >&6;} 29324 BOOT_JDK_FOUND=no 29325 else 29326 # Oh, this is looking good! We probably have found a proper JDK. Is it the correct version? 29327 BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | $HEAD -n 1` 29328 29329 # Extra M4 quote needed to protect [] in grep expression. 29330 FOUND_CORRECT_VERSION=`$ECHO $BOOT_JDK_VERSION | $EGREP '\"9([\.+-].*)?\"|(1\.[89]\.)'` 29331 if test "x$FOUND_CORRECT_VERSION" = x; then 29332 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&5 29333 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&6;} 29334 { $as_echo "$as_me:${as_lineno-$LINENO}: (Your Boot JDK must be version 8 or 9)" >&5 29335 $as_echo "$as_me: (Your Boot JDK must be version 8 or 9)" >&6;} 29336 BOOT_JDK_FOUND=no 29337 else 29338 # We're done! :-) 29339 BOOT_JDK_FOUND=yes 29340 29341 # Only process if variable expands to non-empty 29342 29343 if test "x$BOOT_JDK" != x; then 29344 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 29345 29346 # Input might be given as Windows format, start by converting to 29347 # unix format. 29348 path="$BOOT_JDK" 29349 new_path=`$CYGPATH -u "$path"` 29350 29351 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 29352 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 29353 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 29354 # "foo.exe" is OK but "foo" is an error. 29355 # 29356 # This test is therefore slightly more accurate than "test -f" to check for file precense. 29357 # It is also a way to make sure we got the proper file name for the real test later on. 29358 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 29359 if test "x$test_shortpath" = x; then 29360 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5 29361 $as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;} 29362 as_fn_error $? "Cannot locate the the path of BOOT_JDK" "$LINENO" 5 29363 fi 29364 29365 # Call helper function which possibly converts this using DOS-style short mode. 29366 # If so, the updated path is stored in $new_path. 29367 29368 input_path="$new_path" 29369 # Check if we need to convert this using DOS-style short mode. If the path 29370 # contains just simple characters, use it. Otherwise (spaces, weird characters), 29371 # take no chances and rewrite it. 29372 # Note: m4 eats our [], so we need to use [ and ] instead. 29373 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 29374 if test "x$has_forbidden_chars" != x; then 29375 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 29376 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 29377 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 29378 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 29379 # Going to short mode and back again did indeed matter. Since short mode is 29380 # case insensitive, let's make it lowercase to improve readability. 29381 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 29382 # Now convert it back to Unix-style (cygpath) 29383 input_path=`$CYGPATH -u "$shortmode_path"` 29384 new_path="$input_path" 29385 fi 29386 fi 29387 29388 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 29389 if test "x$test_cygdrive_prefix" = x; then 29390 # As a simple fix, exclude /usr/bin since it's not a real path. 29391 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 29392 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 29393 # a path prefixed by /cygdrive for fixpath to work. 29394 new_path="$CYGWIN_ROOT_PATH$input_path" 29395 fi 29396 fi 29397 29398 29399 if test "x$path" != "x$new_path"; then 29400 BOOT_JDK="$new_path" 29401 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5 29402 $as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;} 29403 fi 29404 29405 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 29406 29407 path="$BOOT_JDK" 29408 has_colon=`$ECHO $path | $GREP ^.:` 29409 new_path="$path" 29410 if test "x$has_colon" = x; then 29411 # Not in mixed or Windows style, start by that. 29412 new_path=`cmd //c echo $path` 29413 fi 29414 29415 29416 input_path="$new_path" 29417 # Check if we need to convert this using DOS-style short mode. If the path 29418 # contains just simple characters, use it. Otherwise (spaces, weird characters), 29419 # take no chances and rewrite it. 29420 # Note: m4 eats our [], so we need to use [ and ] instead. 29421 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 29422 if test "x$has_forbidden_chars" != x; then 29423 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 29424 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 29425 fi 29426 29427 29428 windows_path="$new_path" 29429 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 29430 unix_path=`$CYGPATH -u "$windows_path"` 29431 new_path="$unix_path" 29432 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 29433 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 29434 new_path="$unix_path" 29435 fi 29436 29437 if test "x$path" != "x$new_path"; then 29438 BOOT_JDK="$new_path" 29439 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5 29440 $as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;} 29441 fi 29442 29443 # Save the first 10 bytes of this path to the storage, so fixpath can work. 29444 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 29445 29446 else 29447 # We're on a unix platform. Hooray! :) 29448 path="$BOOT_JDK" 29449 has_space=`$ECHO "$path" | $GREP " "` 29450 if test "x$has_space" != x; then 29451 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5 29452 $as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;} 29453 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 29454 fi 29455 29456 # Use eval to expand a potential ~ 29457 eval path="$path" 29458 if test ! -f "$path" && test ! -d "$path"; then 29459 as_fn_error $? "The path of BOOT_JDK, which resolves as \"$path\", is not found." "$LINENO" 5 29460 fi 29461 29462 if test -d "$path"; then 29463 BOOT_JDK="`cd "$path"; $THEPWDCMD -L`" 29464 else 29465 dir="`$DIRNAME "$path"`" 29466 base="`$BASENAME "$path"`" 29467 BOOT_JDK="`cd "$dir"; $THEPWDCMD -L`/$base" 29468 fi 29469 fi 29470 fi 29471 29472 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for Boot JDK" >&5 29473 $as_echo_n "checking for Boot JDK... " >&6; } 29474 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK" >&5 29475 $as_echo "$BOOT_JDK" >&6; } 29476 { $as_echo "$as_me:${as_lineno-$LINENO}: checking Boot JDK version" >&5 29477 $as_echo_n "checking Boot JDK version... " >&6; } 29478 BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | $TR '\n\r' ' '` 29479 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK_VERSION" >&5 29480 $as_echo "$BOOT_JDK_VERSION" >&6; } 29481 fi # end check jdk version 29482 fi # end check javac 29483 fi # end check java 29484 fi # end check boot jdk found 29485 fi 29486 29487 done 29488 fi 29489 29490 29491 # If previous step claimed to have found a JDK, check it to see if it seems to be valid. 29492 if test "x$BOOT_JDK_FOUND" = xmaybe; then 29493 # Do we have a bin/java? 29494 if test ! -x "$BOOT_JDK/bin/java"; then 29495 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&5 29496 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&6;} 29497 BOOT_JDK_FOUND=no 29498 else 29499 # Do we have a bin/javac? 29500 if test ! -x "$BOOT_JDK/bin/javac"; then 29501 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&5 29502 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&6;} 29503 { $as_echo "$as_me:${as_lineno-$LINENO}: (This might be an JRE instead of an JDK)" >&5 29504 $as_echo "$as_me: (This might be an JRE instead of an JDK)" >&6;} 29505 BOOT_JDK_FOUND=no 29506 else 29507 # Oh, this is looking good! We probably have found a proper JDK. Is it the correct version? 29508 BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | $HEAD -n 1` 29509 29510 # Extra M4 quote needed to protect [] in grep expression. 29511 FOUND_CORRECT_VERSION=`$ECHO $BOOT_JDK_VERSION | $EGREP '\"9([\.+-].*)?\"|(1\.[89]\.)'` 29512 if test "x$FOUND_CORRECT_VERSION" = x; then 29513 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&5 29514 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&6;} 29515 { $as_echo "$as_me:${as_lineno-$LINENO}: (Your Boot JDK must be version 8 or 9)" >&5 29516 $as_echo "$as_me: (Your Boot JDK must be version 8 or 9)" >&6;} 29517 BOOT_JDK_FOUND=no 29518 else 29519 # We're done! :-) 29520 BOOT_JDK_FOUND=yes 29521 29522 # Only process if variable expands to non-empty 29523 29524 if test "x$BOOT_JDK" != x; then 29525 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 29526 29527 # Input might be given as Windows format, start by converting to 29528 # unix format. 29529 path="$BOOT_JDK" 29530 new_path=`$CYGPATH -u "$path"` 29531 29532 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 29533 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 29534 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 29535 # "foo.exe" is OK but "foo" is an error. 29536 # 29537 # This test is therefore slightly more accurate than "test -f" to check for file precense. 29538 # It is also a way to make sure we got the proper file name for the real test later on. 29539 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 29540 if test "x$test_shortpath" = x; then 29541 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5 29542 $as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;} 29543 as_fn_error $? "Cannot locate the the path of BOOT_JDK" "$LINENO" 5 29544 fi 29545 29546 # Call helper function which possibly converts this using DOS-style short mode. 29547 # If so, the updated path is stored in $new_path. 29548 29549 input_path="$new_path" 29550 # Check if we need to convert this using DOS-style short mode. If the path 29551 # contains just simple characters, use it. Otherwise (spaces, weird characters), 29552 # take no chances and rewrite it. 29553 # Note: m4 eats our [], so we need to use [ and ] instead. 29554 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 29555 if test "x$has_forbidden_chars" != x; then 29556 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 29557 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 29558 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 29559 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 29560 # Going to short mode and back again did indeed matter. Since short mode is 29561 # case insensitive, let's make it lowercase to improve readability. 29562 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 29563 # Now convert it back to Unix-style (cygpath) 29564 input_path=`$CYGPATH -u "$shortmode_path"` 29565 new_path="$input_path" 29566 fi 29567 fi 29568 29569 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 29570 if test "x$test_cygdrive_prefix" = x; then 29571 # As a simple fix, exclude /usr/bin since it's not a real path. 29572 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 29573 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 29574 # a path prefixed by /cygdrive for fixpath to work. 29575 new_path="$CYGWIN_ROOT_PATH$input_path" 29576 fi 29577 fi 29578 29579 29580 if test "x$path" != "x$new_path"; then 29581 BOOT_JDK="$new_path" 29582 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5 29583 $as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;} 29584 fi 29585 29586 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 29587 29588 path="$BOOT_JDK" 29589 has_colon=`$ECHO $path | $GREP ^.:` 29590 new_path="$path" 29591 if test "x$has_colon" = x; then 29592 # Not in mixed or Windows style, start by that. 29593 new_path=`cmd //c echo $path` 29594 fi 29595 29596 29597 input_path="$new_path" 29598 # Check if we need to convert this using DOS-style short mode. If the path 29599 # contains just simple characters, use it. Otherwise (spaces, weird characters), 29600 # take no chances and rewrite it. 29601 # Note: m4 eats our [], so we need to use [ and ] instead. 29602 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 29603 if test "x$has_forbidden_chars" != x; then 29604 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 29605 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 29606 fi 29607 29608 29609 windows_path="$new_path" 29610 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 29611 unix_path=`$CYGPATH -u "$windows_path"` 29612 new_path="$unix_path" 29613 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 29614 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 29615 new_path="$unix_path" 29616 fi 29617 29618 if test "x$path" != "x$new_path"; then 29619 BOOT_JDK="$new_path" 29620 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5 29621 $as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;} 29622 fi 29623 29624 # Save the first 10 bytes of this path to the storage, so fixpath can work. 29625 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 29626 29627 else 29628 # We're on a unix platform. Hooray! :) 29629 path="$BOOT_JDK" 29630 has_space=`$ECHO "$path" | $GREP " "` 29631 if test "x$has_space" != x; then 29632 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5 29633 $as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;} 29634 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 29635 fi 29636 29637 # Use eval to expand a potential ~ 29638 eval path="$path" 29639 if test ! -f "$path" && test ! -d "$path"; then 29640 as_fn_error $? "The path of BOOT_JDK, which resolves as \"$path\", is not found." "$LINENO" 5 29641 fi 29642 29643 if test -d "$path"; then 29644 BOOT_JDK="`cd "$path"; $THEPWDCMD -L`" 29645 else 29646 dir="`$DIRNAME "$path"`" 29647 base="`$BASENAME "$path"`" 29648 BOOT_JDK="`cd "$dir"; $THEPWDCMD -L`/$base" 29649 fi 29650 fi 29651 fi 29652 29653 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for Boot JDK" >&5 29654 $as_echo_n "checking for Boot JDK... " >&6; } 29655 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK" >&5 29656 $as_echo "$BOOT_JDK" >&6; } 29657 { $as_echo "$as_me:${as_lineno-$LINENO}: checking Boot JDK version" >&5 29658 $as_echo_n "checking Boot JDK version... " >&6; } 29659 BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | $TR '\n\r' ' '` 29660 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK_VERSION" >&5 29661 $as_echo "$BOOT_JDK_VERSION" >&6; } 29662 fi # end check jdk version 29663 fi # end check javac 29664 fi # end check java 29665 fi # end check boot jdk found 29666 fi 29667 29668 fi 29669 29670 29671 # If previous step claimed to have found a JDK, check it to see if it seems to be valid. 29672 if test "x$BOOT_JDK_FOUND" = xmaybe; then 29673 # Do we have a bin/java? 29674 if test ! -x "$BOOT_JDK/bin/java"; then 29675 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&5 29676 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&6;} 29677 BOOT_JDK_FOUND=no 29678 else 29679 # Do we have a bin/javac? 29680 if test ! -x "$BOOT_JDK/bin/javac"; then 29681 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&5 29682 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&6;} 29683 { $as_echo "$as_me:${as_lineno-$LINENO}: (This might be an JRE instead of an JDK)" >&5 29684 $as_echo "$as_me: (This might be an JRE instead of an JDK)" >&6;} 29685 BOOT_JDK_FOUND=no 29686 else 29687 # Oh, this is looking good! We probably have found a proper JDK. Is it the correct version? 29688 BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | $HEAD -n 1` 29689 29690 # Extra M4 quote needed to protect [] in grep expression. 29691 FOUND_CORRECT_VERSION=`$ECHO $BOOT_JDK_VERSION | $EGREP '\"9([\.+-].*)?\"|(1\.[89]\.)'` 29692 if test "x$FOUND_CORRECT_VERSION" = x; then 29693 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&5 29694 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&6;} 29695 { $as_echo "$as_me:${as_lineno-$LINENO}: (Your Boot JDK must be version 8 or 9)" >&5 29696 $as_echo "$as_me: (Your Boot JDK must be version 8 or 9)" >&6;} 29697 BOOT_JDK_FOUND=no 29698 else 29699 # We're done! :-) 29700 BOOT_JDK_FOUND=yes 29701 29702 # Only process if variable expands to non-empty 29703 29704 if test "x$BOOT_JDK" != x; then 29705 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 29706 29707 # Input might be given as Windows format, start by converting to 29708 # unix format. 29709 path="$BOOT_JDK" 29710 new_path=`$CYGPATH -u "$path"` 29711 29712 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 29713 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 29714 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 29715 # "foo.exe" is OK but "foo" is an error. 29716 # 29717 # This test is therefore slightly more accurate than "test -f" to check for file precense. 29718 # It is also a way to make sure we got the proper file name for the real test later on. 29719 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 29720 if test "x$test_shortpath" = x; then 29721 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5 29722 $as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;} 29723 as_fn_error $? "Cannot locate the the path of BOOT_JDK" "$LINENO" 5 29724 fi 29725 29726 # Call helper function which possibly converts this using DOS-style short mode. 29727 # If so, the updated path is stored in $new_path. 29728 29729 input_path="$new_path" 29730 # Check if we need to convert this using DOS-style short mode. If the path 29731 # contains just simple characters, use it. Otherwise (spaces, weird characters), 29732 # take no chances and rewrite it. 29733 # Note: m4 eats our [], so we need to use [ and ] instead. 29734 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 29735 if test "x$has_forbidden_chars" != x; then 29736 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 29737 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 29738 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 29739 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 29740 # Going to short mode and back again did indeed matter. Since short mode is 29741 # case insensitive, let's make it lowercase to improve readability. 29742 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 29743 # Now convert it back to Unix-style (cygpath) 29744 input_path=`$CYGPATH -u "$shortmode_path"` 29745 new_path="$input_path" 29746 fi 29747 fi 29748 29749 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 29750 if test "x$test_cygdrive_prefix" = x; then 29751 # As a simple fix, exclude /usr/bin since it's not a real path. 29752 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 29753 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 29754 # a path prefixed by /cygdrive for fixpath to work. 29755 new_path="$CYGWIN_ROOT_PATH$input_path" 29756 fi 29757 fi 29758 29759 29760 if test "x$path" != "x$new_path"; then 29761 BOOT_JDK="$new_path" 29762 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5 29763 $as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;} 29764 fi 29765 29766 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 29767 29768 path="$BOOT_JDK" 29769 has_colon=`$ECHO $path | $GREP ^.:` 29770 new_path="$path" 29771 if test "x$has_colon" = x; then 29772 # Not in mixed or Windows style, start by that. 29773 new_path=`cmd //c echo $path` 29774 fi 29775 29776 29777 input_path="$new_path" 29778 # Check if we need to convert this using DOS-style short mode. If the path 29779 # contains just simple characters, use it. Otherwise (spaces, weird characters), 29780 # take no chances and rewrite it. 29781 # Note: m4 eats our [], so we need to use [ and ] instead. 29782 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 29783 if test "x$has_forbidden_chars" != x; then 29784 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 29785 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 29786 fi 29787 29788 29789 windows_path="$new_path" 29790 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 29791 unix_path=`$CYGPATH -u "$windows_path"` 29792 new_path="$unix_path" 29793 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 29794 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 29795 new_path="$unix_path" 29796 fi 29797 29798 if test "x$path" != "x$new_path"; then 29799 BOOT_JDK="$new_path" 29800 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5 29801 $as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;} 29802 fi 29803 29804 # Save the first 10 bytes of this path to the storage, so fixpath can work. 29805 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 29806 29807 else 29808 # We're on a unix platform. Hooray! :) 29809 path="$BOOT_JDK" 29810 has_space=`$ECHO "$path" | $GREP " "` 29811 if test "x$has_space" != x; then 29812 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5 29813 $as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;} 29814 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 29815 fi 29816 29817 # Use eval to expand a potential ~ 29818 eval path="$path" 29819 if test ! -f "$path" && test ! -d "$path"; then 29820 as_fn_error $? "The path of BOOT_JDK, which resolves as \"$path\", is not found." "$LINENO" 5 29821 fi 29822 29823 if test -d "$path"; then 29824 BOOT_JDK="`cd "$path"; $THEPWDCMD -L`" 29825 else 29826 dir="`$DIRNAME "$path"`" 29827 base="`$BASENAME "$path"`" 29828 BOOT_JDK="`cd "$dir"; $THEPWDCMD -L`/$base" 29829 fi 29830 fi 29831 fi 29832 29833 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for Boot JDK" >&5 29834 $as_echo_n "checking for Boot JDK... " >&6; } 29835 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK" >&5 29836 $as_echo "$BOOT_JDK" >&6; } 29837 { $as_echo "$as_me:${as_lineno-$LINENO}: checking Boot JDK version" >&5 29838 $as_echo_n "checking Boot JDK version... " >&6; } 29839 BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | $TR '\n\r' ' '` 29840 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK_VERSION" >&5 29841 $as_echo "$BOOT_JDK_VERSION" >&6; } 29842 fi # end check jdk version 29843 fi # end check javac 29844 fi # end check java 29845 fi # end check boot jdk found 29846 fi 29847 29848 29849 # If we haven't found anything yet, we've truly lost. Give up. 29850 if test "x$BOOT_JDK_FOUND" = xno; then 29851 29852 # Print a helpful message on how to acquire the necessary build dependency. 29853 # openjdk is the help tag: freetype, cups, alsa etc 29854 MISSING_DEPENDENCY=openjdk 29855 29856 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 29857 cygwin_help $MISSING_DEPENDENCY 29858 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 29859 msys_help $MISSING_DEPENDENCY 29860 else 29861 PKGHANDLER_COMMAND= 29862 29863 case $PKGHANDLER in 29864 apt-get) 29865 apt_help $MISSING_DEPENDENCY ;; 29866 yum) 29867 yum_help $MISSING_DEPENDENCY ;; 29868 port) 29869 port_help $MISSING_DEPENDENCY ;; 29870 pkgutil) 29871 pkgutil_help $MISSING_DEPENDENCY ;; 29872 pkgadd) 29873 pkgadd_help $MISSING_DEPENDENCY ;; 29874 esac 29875 29876 if test "x$PKGHANDLER_COMMAND" != x; then 29877 HELP_MSG="You might be able to fix this by running '$PKGHANDLER_COMMAND'." 29878 fi 29879 fi 29880 29881 { $as_echo "$as_me:${as_lineno-$LINENO}: Could not find a valid Boot JDK. $HELP_MSG" >&5 29882 $as_echo "$as_me: Could not find a valid Boot JDK. $HELP_MSG" >&6;} 29883 { $as_echo "$as_me:${as_lineno-$LINENO}: This might be fixed by explicitely setting --with-boot-jdk" >&5 29884 $as_echo "$as_me: This might be fixed by explicitely setting --with-boot-jdk" >&6;} 29885 as_fn_error $? "Cannot continue" "$LINENO" 5 29886 fi 29887 29888 29889 29890 # Setup tools from the Boot JDK. 29891 29892 # Use user overridden value if available, otherwise locate tool in the Boot JDK. 29893 29894 # Publish this variable in the help. 29895 29896 29897 if [ -z "${JAVA+x}" ]; then 29898 # The variable is not set by user, try to locate tool using the code snippet 29899 29900 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for java in Boot JDK" >&5 29901 $as_echo_n "checking for java in Boot JDK... " >&6; } 29902 JAVA=$BOOT_JDK/bin/java 29903 if test ! -x $JAVA; then 29904 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 29905 $as_echo "not found" >&6; } 29906 { $as_echo "$as_me:${as_lineno-$LINENO}: Your Boot JDK seems broken. This might be fixed by explicitely setting --with-boot-jdk" >&5 29907 $as_echo "$as_me: Your Boot JDK seems broken. This might be fixed by explicitely setting --with-boot-jdk" >&6;} 29908 as_fn_error $? "Could not find java in the Boot JDK" "$LINENO" 5 29909 fi 29910 { $as_echo "$as_me:${as_lineno-$LINENO}: result: ok" >&5 29911 $as_echo "ok" >&6; } 29912 29913 29914 else 29915 # The variable is set, but is it from the command line or the environment? 29916 29917 # Try to remove the string !JAVA! from our list. 29918 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!JAVA!/} 29919 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 29920 # If it failed, the variable was not from the command line. Ignore it, 29921 # but warn the user (except for BASH, which is always set by the calling BASH). 29922 if test "xJAVA" != xBASH; then 29923 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of JAVA from the environment. Use command line variables instead." >&5 29924 $as_echo "$as_me: WARNING: Ignoring value of JAVA from the environment. Use command line variables instead." >&2;} 29925 fi 29926 # Try to locate tool using the code snippet 29927 29928 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for java in Boot JDK" >&5 29929 $as_echo_n "checking for java in Boot JDK... " >&6; } 29930 JAVA=$BOOT_JDK/bin/java 29931 if test ! -x $JAVA; then 29932 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 29933 $as_echo "not found" >&6; } 29934 { $as_echo "$as_me:${as_lineno-$LINENO}: Your Boot JDK seems broken. This might be fixed by explicitely setting --with-boot-jdk" >&5 29935 $as_echo "$as_me: Your Boot JDK seems broken. This might be fixed by explicitely setting --with-boot-jdk" >&6;} 29936 as_fn_error $? "Could not find java in the Boot JDK" "$LINENO" 5 29937 fi 29938 { $as_echo "$as_me:${as_lineno-$LINENO}: result: ok" >&5 29939 $as_echo "ok" >&6; } 29940 29941 29942 else 29943 # If it succeeded, then it was overridden by the user. We will use it 29944 # for the tool. 29945 29946 # First remove it from the list of overridden variables, so we can test 29947 # for unknown variables in the end. 29948 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 29949 29950 # Check if we try to supply an empty value 29951 if test "x$JAVA" = x; then 29952 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool JAVA= (no value)" >&5 29953 $as_echo "$as_me: Setting user supplied tool JAVA= (no value)" >&6;} 29954 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for JAVA" >&5 29955 $as_echo_n "checking for JAVA... " >&6; } 29956 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 29957 $as_echo "disabled" >&6; } 29958 else 29959 # Check if the provided tool contains a complete path. 29960 tool_specified="$JAVA" 29961 tool_basename="${tool_specified##*/}" 29962 if test "x$tool_basename" = "x$tool_specified"; then 29963 # A command without a complete path is provided, search $PATH. 29964 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool JAVA=$tool_basename" >&5 29965 $as_echo "$as_me: Will search for user supplied tool JAVA=$tool_basename" >&6;} 29966 # Extract the first word of "$tool_basename", so it can be a program name with args. 29967 set dummy $tool_basename; ac_word=$2 29968 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 29969 $as_echo_n "checking for $ac_word... " >&6; } 29970 if ${ac_cv_path_JAVA+:} false; then : 29971 $as_echo_n "(cached) " >&6 29972 else 29973 case $JAVA in 29974 [\\/]* | ?:[\\/]*) 29975 ac_cv_path_JAVA="$JAVA" # Let the user override the test with a path. 29976 ;; 29977 *) 29978 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 29979 for as_dir in $PATH 29980 do 29981 IFS=$as_save_IFS 29982 test -z "$as_dir" && as_dir=. 29983 for ac_exec_ext in '' $ac_executable_extensions; do 29984 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 29985 ac_cv_path_JAVA="$as_dir/$ac_word$ac_exec_ext" 29986 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 29987 break 2 29988 fi 29989 done 29990 done 29991 IFS=$as_save_IFS 29992 29993 ;; 29994 esac 29995 fi 29996 JAVA=$ac_cv_path_JAVA 29997 if test -n "$JAVA"; then 29998 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $JAVA" >&5 29999 $as_echo "$JAVA" >&6; } 30000 else 30001 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 30002 $as_echo "no" >&6; } 30003 fi 30004 30005 30006 if test "x$JAVA" = x; then 30007 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 30008 fi 30009 else 30010 # Otherwise we believe it is a complete path. Use it as it is. 30011 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool JAVA=$tool_specified" >&5 30012 $as_echo "$as_me: Will use user supplied tool JAVA=$tool_specified" >&6;} 30013 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for JAVA" >&5 30014 $as_echo_n "checking for JAVA... " >&6; } 30015 if test ! -x "$tool_specified"; then 30016 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 30017 $as_echo "not found" >&6; } 30018 as_fn_error $? "User supplied tool JAVA=$tool_specified does not exist or is not executable" "$LINENO" 5 30019 fi 30020 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 30021 $as_echo "$tool_specified" >&6; } 30022 fi 30023 fi 30024 fi 30025 30026 fi 30027 30028 30029 30030 # Use user overridden value if available, otherwise locate tool in the Boot JDK. 30031 30032 # Publish this variable in the help. 30033 30034 30035 if [ -z "${JAVAC+x}" ]; then 30036 # The variable is not set by user, try to locate tool using the code snippet 30037 30038 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for javac in Boot JDK" >&5 30039 $as_echo_n "checking for javac in Boot JDK... " >&6; } 30040 JAVAC=$BOOT_JDK/bin/javac 30041 if test ! -x $JAVAC; then 30042 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 30043 $as_echo "not found" >&6; } 30044 { $as_echo "$as_me:${as_lineno-$LINENO}: Your Boot JDK seems broken. This might be fixed by explicitely setting --with-boot-jdk" >&5 30045 $as_echo "$as_me: Your Boot JDK seems broken. This might be fixed by explicitely setting --with-boot-jdk" >&6;} 30046 as_fn_error $? "Could not find javac in the Boot JDK" "$LINENO" 5 30047 fi 30048 { $as_echo "$as_me:${as_lineno-$LINENO}: result: ok" >&5 30049 $as_echo "ok" >&6; } 30050 30051 30052 else 30053 # The variable is set, but is it from the command line or the environment? 30054 30055 # Try to remove the string !JAVAC! from our list. 30056 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!JAVAC!/} 30057 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 30058 # If it failed, the variable was not from the command line. Ignore it, 30059 # but warn the user (except for BASH, which is always set by the calling BASH). 30060 if test "xJAVAC" != xBASH; then 30061 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of JAVAC from the environment. Use command line variables instead." >&5 30062 $as_echo "$as_me: WARNING: Ignoring value of JAVAC from the environment. Use command line variables instead." >&2;} 30063 fi 30064 # Try to locate tool using the code snippet 30065 30066 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for javac in Boot JDK" >&5 30067 $as_echo_n "checking for javac in Boot JDK... " >&6; } 30068 JAVAC=$BOOT_JDK/bin/javac 30069 if test ! -x $JAVAC; then 30070 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 30071 $as_echo "not found" >&6; } 30072 { $as_echo "$as_me:${as_lineno-$LINENO}: Your Boot JDK seems broken. This might be fixed by explicitely setting --with-boot-jdk" >&5 30073 $as_echo "$as_me: Your Boot JDK seems broken. This might be fixed by explicitely setting --with-boot-jdk" >&6;} 30074 as_fn_error $? "Could not find javac in the Boot JDK" "$LINENO" 5 30075 fi 30076 { $as_echo "$as_me:${as_lineno-$LINENO}: result: ok" >&5 30077 $as_echo "ok" >&6; } 30078 30079 30080 else 30081 # If it succeeded, then it was overridden by the user. We will use it 30082 # for the tool. 30083 30084 # First remove it from the list of overridden variables, so we can test 30085 # for unknown variables in the end. 30086 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 30087 30088 # Check if we try to supply an empty value 30089 if test "x$JAVAC" = x; then 30090 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool JAVAC= (no value)" >&5 30091 $as_echo "$as_me: Setting user supplied tool JAVAC= (no value)" >&6;} 30092 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for JAVAC" >&5 30093 $as_echo_n "checking for JAVAC... " >&6; } 30094 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 30095 $as_echo "disabled" >&6; } 30096 else 30097 # Check if the provided tool contains a complete path. 30098 tool_specified="$JAVAC" 30099 tool_basename="${tool_specified##*/}" 30100 if test "x$tool_basename" = "x$tool_specified"; then 30101 # A command without a complete path is provided, search $PATH. 30102 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool JAVAC=$tool_basename" >&5 30103 $as_echo "$as_me: Will search for user supplied tool JAVAC=$tool_basename" >&6;} 30104 # Extract the first word of "$tool_basename", so it can be a program name with args. 30105 set dummy $tool_basename; ac_word=$2 30106 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 30107 $as_echo_n "checking for $ac_word... " >&6; } 30108 if ${ac_cv_path_JAVAC+:} false; then : 30109 $as_echo_n "(cached) " >&6 30110 else 30111 case $JAVAC in 30112 [\\/]* | ?:[\\/]*) 30113 ac_cv_path_JAVAC="$JAVAC" # Let the user override the test with a path. 30114 ;; 30115 *) 30116 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 30117 for as_dir in $PATH 30118 do 30119 IFS=$as_save_IFS 30120 test -z "$as_dir" && as_dir=. 30121 for ac_exec_ext in '' $ac_executable_extensions; do 30122 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 30123 ac_cv_path_JAVAC="$as_dir/$ac_word$ac_exec_ext" 30124 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 30125 break 2 30126 fi 30127 done 30128 done 30129 IFS=$as_save_IFS 30130 30131 ;; 30132 esac 30133 fi 30134 JAVAC=$ac_cv_path_JAVAC 30135 if test -n "$JAVAC"; then 30136 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $JAVAC" >&5 30137 $as_echo "$JAVAC" >&6; } 30138 else 30139 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 30140 $as_echo "no" >&6; } 30141 fi 30142 30143 30144 if test "x$JAVAC" = x; then 30145 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 30146 fi 30147 else 30148 # Otherwise we believe it is a complete path. Use it as it is. 30149 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool JAVAC=$tool_specified" >&5 30150 $as_echo "$as_me: Will use user supplied tool JAVAC=$tool_specified" >&6;} 30151 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for JAVAC" >&5 30152 $as_echo_n "checking for JAVAC... " >&6; } 30153 if test ! -x "$tool_specified"; then 30154 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 30155 $as_echo "not found" >&6; } 30156 as_fn_error $? "User supplied tool JAVAC=$tool_specified does not exist or is not executable" "$LINENO" 5 30157 fi 30158 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 30159 $as_echo "$tool_specified" >&6; } 30160 fi 30161 fi 30162 fi 30163 30164 fi 30165 30166 30167 30168 # Use user overridden value if available, otherwise locate tool in the Boot JDK. 30169 30170 # Publish this variable in the help. 30171 30172 30173 if [ -z "${JAVAH+x}" ]; then 30174 # The variable is not set by user, try to locate tool using the code snippet 30175 30176 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for javah in Boot JDK" >&5 30177 $as_echo_n "checking for javah in Boot JDK... " >&6; } 30178 JAVAH=$BOOT_JDK/bin/javah 30179 if test ! -x $JAVAH; then 30180 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 30181 $as_echo "not found" >&6; } 30182 { $as_echo "$as_me:${as_lineno-$LINENO}: Your Boot JDK seems broken. This might be fixed by explicitely setting --with-boot-jdk" >&5 30183 $as_echo "$as_me: Your Boot JDK seems broken. This might be fixed by explicitely setting --with-boot-jdk" >&6;} 30184 as_fn_error $? "Could not find javah in the Boot JDK" "$LINENO" 5 30185 fi 30186 { $as_echo "$as_me:${as_lineno-$LINENO}: result: ok" >&5 30187 $as_echo "ok" >&6; } 30188 30189 30190 else 30191 # The variable is set, but is it from the command line or the environment? 30192 30193 # Try to remove the string !JAVAH! from our list. 30194 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!JAVAH!/} 30195 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 30196 # If it failed, the variable was not from the command line. Ignore it, 30197 # but warn the user (except for BASH, which is always set by the calling BASH). 30198 if test "xJAVAH" != xBASH; then 30199 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of JAVAH from the environment. Use command line variables instead." >&5 30200 $as_echo "$as_me: WARNING: Ignoring value of JAVAH from the environment. Use command line variables instead." >&2;} 30201 fi 30202 # Try to locate tool using the code snippet 30203 30204 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for javah in Boot JDK" >&5 30205 $as_echo_n "checking for javah in Boot JDK... " >&6; } 30206 JAVAH=$BOOT_JDK/bin/javah 30207 if test ! -x $JAVAH; then 30208 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 30209 $as_echo "not found" >&6; } 30210 { $as_echo "$as_me:${as_lineno-$LINENO}: Your Boot JDK seems broken. This might be fixed by explicitely setting --with-boot-jdk" >&5 30211 $as_echo "$as_me: Your Boot JDK seems broken. This might be fixed by explicitely setting --with-boot-jdk" >&6;} 30212 as_fn_error $? "Could not find javah in the Boot JDK" "$LINENO" 5 30213 fi 30214 { $as_echo "$as_me:${as_lineno-$LINENO}: result: ok" >&5 30215 $as_echo "ok" >&6; } 30216 30217 30218 else 30219 # If it succeeded, then it was overridden by the user. We will use it 30220 # for the tool. 30221 30222 # First remove it from the list of overridden variables, so we can test 30223 # for unknown variables in the end. 30224 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 30225 30226 # Check if we try to supply an empty value 30227 if test "x$JAVAH" = x; then 30228 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool JAVAH= (no value)" >&5 30229 $as_echo "$as_me: Setting user supplied tool JAVAH= (no value)" >&6;} 30230 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for JAVAH" >&5 30231 $as_echo_n "checking for JAVAH... " >&6; } 30232 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 30233 $as_echo "disabled" >&6; } 30234 else 30235 # Check if the provided tool contains a complete path. 30236 tool_specified="$JAVAH" 30237 tool_basename="${tool_specified##*/}" 30238 if test "x$tool_basename" = "x$tool_specified"; then 30239 # A command without a complete path is provided, search $PATH. 30240 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool JAVAH=$tool_basename" >&5 30241 $as_echo "$as_me: Will search for user supplied tool JAVAH=$tool_basename" >&6;} 30242 # Extract the first word of "$tool_basename", so it can be a program name with args. 30243 set dummy $tool_basename; ac_word=$2 30244 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 30245 $as_echo_n "checking for $ac_word... " >&6; } 30246 if ${ac_cv_path_JAVAH+:} false; then : 30247 $as_echo_n "(cached) " >&6 30248 else 30249 case $JAVAH in 30250 [\\/]* | ?:[\\/]*) 30251 ac_cv_path_JAVAH="$JAVAH" # Let the user override the test with a path. 30252 ;; 30253 *) 30254 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 30255 for as_dir in $PATH 30256 do 30257 IFS=$as_save_IFS 30258 test -z "$as_dir" && as_dir=. 30259 for ac_exec_ext in '' $ac_executable_extensions; do 30260 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 30261 ac_cv_path_JAVAH="$as_dir/$ac_word$ac_exec_ext" 30262 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 30263 break 2 30264 fi 30265 done 30266 done 30267 IFS=$as_save_IFS 30268 30269 ;; 30270 esac 30271 fi 30272 JAVAH=$ac_cv_path_JAVAH 30273 if test -n "$JAVAH"; then 30274 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $JAVAH" >&5 30275 $as_echo "$JAVAH" >&6; } 30276 else 30277 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 30278 $as_echo "no" >&6; } 30279 fi 30280 30281 30282 if test "x$JAVAH" = x; then 30283 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 30284 fi 30285 else 30286 # Otherwise we believe it is a complete path. Use it as it is. 30287 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool JAVAH=$tool_specified" >&5 30288 $as_echo "$as_me: Will use user supplied tool JAVAH=$tool_specified" >&6;} 30289 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for JAVAH" >&5 30290 $as_echo_n "checking for JAVAH... " >&6; } 30291 if test ! -x "$tool_specified"; then 30292 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 30293 $as_echo "not found" >&6; } 30294 as_fn_error $? "User supplied tool JAVAH=$tool_specified does not exist or is not executable" "$LINENO" 5 30295 fi 30296 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 30297 $as_echo "$tool_specified" >&6; } 30298 fi 30299 fi 30300 fi 30301 30302 fi 30303 30304 30305 30306 # Use user overridden value if available, otherwise locate tool in the Boot JDK. 30307 30308 # Publish this variable in the help. 30309 30310 30311 if [ -z "${JAR+x}" ]; then 30312 # The variable is not set by user, try to locate tool using the code snippet 30313 30314 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for jar in Boot JDK" >&5 30315 $as_echo_n "checking for jar in Boot JDK... " >&6; } 30316 JAR=$BOOT_JDK/bin/jar 30317 if test ! -x $JAR; then 30318 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 30319 $as_echo "not found" >&6; } 30320 { $as_echo "$as_me:${as_lineno-$LINENO}: Your Boot JDK seems broken. This might be fixed by explicitely setting --with-boot-jdk" >&5 30321 $as_echo "$as_me: Your Boot JDK seems broken. This might be fixed by explicitely setting --with-boot-jdk" >&6;} 30322 as_fn_error $? "Could not find jar in the Boot JDK" "$LINENO" 5 30323 fi 30324 { $as_echo "$as_me:${as_lineno-$LINENO}: result: ok" >&5 30325 $as_echo "ok" >&6; } 30326 30327 30328 else 30329 # The variable is set, but is it from the command line or the environment? 30330 30331 # Try to remove the string !JAR! from our list. 30332 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!JAR!/} 30333 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 30334 # If it failed, the variable was not from the command line. Ignore it, 30335 # but warn the user (except for BASH, which is always set by the calling BASH). 30336 if test "xJAR" != xBASH; then 30337 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of JAR from the environment. Use command line variables instead." >&5 30338 $as_echo "$as_me: WARNING: Ignoring value of JAR from the environment. Use command line variables instead." >&2;} 30339 fi 30340 # Try to locate tool using the code snippet 30341 30342 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for jar in Boot JDK" >&5 30343 $as_echo_n "checking for jar in Boot JDK... " >&6; } 30344 JAR=$BOOT_JDK/bin/jar 30345 if test ! -x $JAR; then 30346 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 30347 $as_echo "not found" >&6; } 30348 { $as_echo "$as_me:${as_lineno-$LINENO}: Your Boot JDK seems broken. This might be fixed by explicitely setting --with-boot-jdk" >&5 30349 $as_echo "$as_me: Your Boot JDK seems broken. This might be fixed by explicitely setting --with-boot-jdk" >&6;} 30350 as_fn_error $? "Could not find jar in the Boot JDK" "$LINENO" 5 30351 fi 30352 { $as_echo "$as_me:${as_lineno-$LINENO}: result: ok" >&5 30353 $as_echo "ok" >&6; } 30354 30355 30356 else 30357 # If it succeeded, then it was overridden by the user. We will use it 30358 # for the tool. 30359 30360 # First remove it from the list of overridden variables, so we can test 30361 # for unknown variables in the end. 30362 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 30363 30364 # Check if we try to supply an empty value 30365 if test "x$JAR" = x; then 30366 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool JAR= (no value)" >&5 30367 $as_echo "$as_me: Setting user supplied tool JAR= (no value)" >&6;} 30368 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for JAR" >&5 30369 $as_echo_n "checking for JAR... " >&6; } 30370 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 30371 $as_echo "disabled" >&6; } 30372 else 30373 # Check if the provided tool contains a complete path. 30374 tool_specified="$JAR" 30375 tool_basename="${tool_specified##*/}" 30376 if test "x$tool_basename" = "x$tool_specified"; then 30377 # A command without a complete path is provided, search $PATH. 30378 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool JAR=$tool_basename" >&5 30379 $as_echo "$as_me: Will search for user supplied tool JAR=$tool_basename" >&6;} 30380 # Extract the first word of "$tool_basename", so it can be a program name with args. 30381 set dummy $tool_basename; ac_word=$2 30382 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 30383 $as_echo_n "checking for $ac_word... " >&6; } 30384 if ${ac_cv_path_JAR+:} false; then : 30385 $as_echo_n "(cached) " >&6 30386 else 30387 case $JAR in 30388 [\\/]* | ?:[\\/]*) 30389 ac_cv_path_JAR="$JAR" # Let the user override the test with a path. 30390 ;; 30391 *) 30392 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 30393 for as_dir in $PATH 30394 do 30395 IFS=$as_save_IFS 30396 test -z "$as_dir" && as_dir=. 30397 for ac_exec_ext in '' $ac_executable_extensions; do 30398 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 30399 ac_cv_path_JAR="$as_dir/$ac_word$ac_exec_ext" 30400 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 30401 break 2 30402 fi 30403 done 30404 done 30405 IFS=$as_save_IFS 30406 30407 ;; 30408 esac 30409 fi 30410 JAR=$ac_cv_path_JAR 30411 if test -n "$JAR"; then 30412 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $JAR" >&5 30413 $as_echo "$JAR" >&6; } 30414 else 30415 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 30416 $as_echo "no" >&6; } 30417 fi 30418 30419 30420 if test "x$JAR" = x; then 30421 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 30422 fi 30423 else 30424 # Otherwise we believe it is a complete path. Use it as it is. 30425 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool JAR=$tool_specified" >&5 30426 $as_echo "$as_me: Will use user supplied tool JAR=$tool_specified" >&6;} 30427 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for JAR" >&5 30428 $as_echo_n "checking for JAR... " >&6; } 30429 if test ! -x "$tool_specified"; then 30430 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 30431 $as_echo "not found" >&6; } 30432 as_fn_error $? "User supplied tool JAR=$tool_specified does not exist or is not executable" "$LINENO" 5 30433 fi 30434 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 30435 $as_echo "$tool_specified" >&6; } 30436 fi 30437 fi 30438 fi 30439 30440 fi 30441 30442 30443 30444 # Use user overridden value if available, otherwise locate tool in the Boot JDK. 30445 30446 # Publish this variable in the help. 30447 30448 30449 if [ -z "${JARSIGNER+x}" ]; then 30450 # The variable is not set by user, try to locate tool using the code snippet 30451 30452 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for jarsigner in Boot JDK" >&5 30453 $as_echo_n "checking for jarsigner in Boot JDK... " >&6; } 30454 JARSIGNER=$BOOT_JDK/bin/jarsigner 30455 if test ! -x $JARSIGNER; then 30456 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 30457 $as_echo "not found" >&6; } 30458 { $as_echo "$as_me:${as_lineno-$LINENO}: Your Boot JDK seems broken. This might be fixed by explicitely setting --with-boot-jdk" >&5 30459 $as_echo "$as_me: Your Boot JDK seems broken. This might be fixed by explicitely setting --with-boot-jdk" >&6;} 30460 as_fn_error $? "Could not find jarsigner in the Boot JDK" "$LINENO" 5 30461 fi 30462 { $as_echo "$as_me:${as_lineno-$LINENO}: result: ok" >&5 30463 $as_echo "ok" >&6; } 30464 30465 30466 else 30467 # The variable is set, but is it from the command line or the environment? 30468 30469 # Try to remove the string !JARSIGNER! from our list. 30470 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!JARSIGNER!/} 30471 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 30472 # If it failed, the variable was not from the command line. Ignore it, 30473 # but warn the user (except for BASH, which is always set by the calling BASH). 30474 if test "xJARSIGNER" != xBASH; then 30475 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of JARSIGNER from the environment. Use command line variables instead." >&5 30476 $as_echo "$as_me: WARNING: Ignoring value of JARSIGNER from the environment. Use command line variables instead." >&2;} 30477 fi 30478 # Try to locate tool using the code snippet 30479 30480 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for jarsigner in Boot JDK" >&5 30481 $as_echo_n "checking for jarsigner in Boot JDK... " >&6; } 30482 JARSIGNER=$BOOT_JDK/bin/jarsigner 30483 if test ! -x $JARSIGNER; then 30484 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 30485 $as_echo "not found" >&6; } 30486 { $as_echo "$as_me:${as_lineno-$LINENO}: Your Boot JDK seems broken. This might be fixed by explicitely setting --with-boot-jdk" >&5 30487 $as_echo "$as_me: Your Boot JDK seems broken. This might be fixed by explicitely setting --with-boot-jdk" >&6;} 30488 as_fn_error $? "Could not find jarsigner in the Boot JDK" "$LINENO" 5 30489 fi 30490 { $as_echo "$as_me:${as_lineno-$LINENO}: result: ok" >&5 30491 $as_echo "ok" >&6; } 30492 30493 30494 else 30495 # If it succeeded, then it was overridden by the user. We will use it 30496 # for the tool. 30497 30498 # First remove it from the list of overridden variables, so we can test 30499 # for unknown variables in the end. 30500 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 30501 30502 # Check if we try to supply an empty value 30503 if test "x$JARSIGNER" = x; then 30504 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool JARSIGNER= (no value)" >&5 30505 $as_echo "$as_me: Setting user supplied tool JARSIGNER= (no value)" >&6;} 30506 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for JARSIGNER" >&5 30507 $as_echo_n "checking for JARSIGNER... " >&6; } 30508 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 30509 $as_echo "disabled" >&6; } 30510 else 30511 # Check if the provided tool contains a complete path. 30512 tool_specified="$JARSIGNER" 30513 tool_basename="${tool_specified##*/}" 30514 if test "x$tool_basename" = "x$tool_specified"; then 30515 # A command without a complete path is provided, search $PATH. 30516 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool JARSIGNER=$tool_basename" >&5 30517 $as_echo "$as_me: Will search for user supplied tool JARSIGNER=$tool_basename" >&6;} 30518 # Extract the first word of "$tool_basename", so it can be a program name with args. 30519 set dummy $tool_basename; ac_word=$2 30520 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 30521 $as_echo_n "checking for $ac_word... " >&6; } 30522 if ${ac_cv_path_JARSIGNER+:} false; then : 30523 $as_echo_n "(cached) " >&6 30524 else 30525 case $JARSIGNER in 30526 [\\/]* | ?:[\\/]*) 30527 ac_cv_path_JARSIGNER="$JARSIGNER" # Let the user override the test with a path. 30528 ;; 30529 *) 30530 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 30531 for as_dir in $PATH 30532 do 30533 IFS=$as_save_IFS 30534 test -z "$as_dir" && as_dir=. 30535 for ac_exec_ext in '' $ac_executable_extensions; do 30536 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 30537 ac_cv_path_JARSIGNER="$as_dir/$ac_word$ac_exec_ext" 30538 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 30539 break 2 30540 fi 30541 done 30542 done 30543 IFS=$as_save_IFS 30544 30545 ;; 30546 esac 30547 fi 30548 JARSIGNER=$ac_cv_path_JARSIGNER 30549 if test -n "$JARSIGNER"; then 30550 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $JARSIGNER" >&5 30551 $as_echo "$JARSIGNER" >&6; } 30552 else 30553 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 30554 $as_echo "no" >&6; } 30555 fi 30556 30557 30558 if test "x$JARSIGNER" = x; then 30559 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 30560 fi 30561 else 30562 # Otherwise we believe it is a complete path. Use it as it is. 30563 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool JARSIGNER=$tool_specified" >&5 30564 $as_echo "$as_me: Will use user supplied tool JARSIGNER=$tool_specified" >&6;} 30565 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for JARSIGNER" >&5 30566 $as_echo_n "checking for JARSIGNER... " >&6; } 30567 if test ! -x "$tool_specified"; then 30568 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 30569 $as_echo "not found" >&6; } 30570 as_fn_error $? "User supplied tool JARSIGNER=$tool_specified does not exist or is not executable" "$LINENO" 5 30571 fi 30572 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 30573 $as_echo "$tool_specified" >&6; } 30574 fi 30575 fi 30576 fi 30577 30578 fi 30579 30580 30581 30582 # Finally, set some other options... 30583 30584 # When compiling code to be executed by the Boot JDK, force jdk8 compatibility. 30585 BOOT_JDK_SOURCETARGET="-source 8 -target 8" 30586 30587 30588 30589 $ECHO "Check if jvm arg is ok: --patch-module foo=bar" >&5 30590 $ECHO "Command: $JAVA --patch-module foo=bar -version" >&5 30591 OUTPUT=`$JAVA --patch-module foo=bar -version 2>&1` 30592 FOUND_WARN=`$ECHO "$OUTPUT" | $GREP -i warn` 30593 FOUND_VERSION=`$ECHO $OUTPUT | $GREP " version \""` 30594 if test "x$FOUND_VERSION" != x && test "x$FOUND_WARN" = x; then 30595 dummy="$dummy --patch-module foo=bar" 30596 JVM_ARG_OK=true 30597 else 30598 $ECHO "Arg failed:" >&5 30599 $ECHO "$OUTPUT" >&5 30600 JVM_ARG_OK=false 30601 fi 30602 30603 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if Boot JDK supports modules" >&5 30604 $as_echo_n "checking if Boot JDK supports modules... " >&6; } 30605 if test "x$JVM_ARG_OK" = "xtrue"; then 30606 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 30607 $as_echo "yes" >&6; } 30608 BOOT_JDK_MODULAR="true" 30609 else 30610 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 30611 $as_echo "no" >&6; } 30612 BOOT_JDK_MODULAR="false" 30613 fi 30614 30615 30616 30617 30618 # Check if the boot jdk is 32 or 64 bit 30619 if "$JAVA" -d64 -version > /dev/null 2>&1; then 30620 BOOT_JDK_BITS="64" 30621 else 30622 BOOT_JDK_BITS="32" 30623 fi 30624 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if Boot JDK is 32 or 64 bits" >&5 30625 $as_echo_n "checking if Boot JDK is 32 or 64 bits... " >&6; } 30626 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK_BITS" >&5 30627 $as_echo "$BOOT_JDK_BITS" >&6; } 30628 30629 30630 30631 30632 # Check whether --with-build-jdk was given. 30633 if test "${with_build_jdk+set}" = set; then : 30634 withval=$with_build_jdk; 30635 fi 30636 30637 30638 CREATE_BUILDJDK=false 30639 EXTERNAL_BUILDJDK=false 30640 BUILD_JDK_FOUND="no" 30641 if test "x$with_build_jdk" != "x"; then 30642 30643 if test "x$BUILD_JDK_FOUND" = xno; then 30644 # Execute the test 30645 30646 if test "x$with_build_jdk" != x; then 30647 BUILD_JDK=$with_build_jdk 30648 BUILD_JDK_FOUND=maybe 30649 { $as_echo "$as_me:${as_lineno-$LINENO}: Found potential Build JDK using configure arguments" >&5 30650 $as_echo "$as_me: Found potential Build JDK using configure arguments" >&6;} 30651 fi 30652 30653 # If previous step claimed to have found a JDK, check it to see if it seems to be valid. 30654 if test "x$BUILD_JDK_FOUND" = xmaybe; then 30655 # Do we have a bin/java? 30656 if test ! -x "$BUILD_JDK/bin/java"; then 30657 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Build JDK found at $BUILD_JDK did not contain bin/java; ignoring" >&5 30658 $as_echo "$as_me: Potential Build JDK found at $BUILD_JDK did not contain bin/java; ignoring" >&6;} 30659 BUILD_JDK_FOUND=no 30660 elif test ! -x "$BUILD_JDK/bin/jlink"; then 30661 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Build JDK found at $BUILD_JDK did not contain bin/jlink; ignoring" >&5 30662 $as_echo "$as_me: Potential Build JDK found at $BUILD_JDK did not contain bin/jlink; ignoring" >&6;} 30663 BUILD_JDK_FOUND=no 30664 elif test ! -x "$BUILD_JDK/bin/jmod"; then 30665 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Build JDK found at $BUILD_JDK did not contain bin/jmod; ignoring" >&5 30666 $as_echo "$as_me: Potential Build JDK found at $BUILD_JDK did not contain bin/jmod; ignoring" >&6;} 30667 BUILD_JDK_FOUND=no 30668 elif test ! -x "$BUILD_JDK/bin/javac"; then 30669 # Do we have a bin/javac? 30670 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Build JDK found at $BUILD_JDK did not contain bin/javac; ignoring" >&5 30671 $as_echo "$as_me: Potential Build JDK found at $BUILD_JDK did not contain bin/javac; ignoring" >&6;} 30672 { $as_echo "$as_me:${as_lineno-$LINENO}: (This might be a JRE instead of an JDK)" >&5 30673 $as_echo "$as_me: (This might be a JRE instead of an JDK)" >&6;} 30674 BUILD_JDK_FOUND=no 30675 else 30676 # Oh, this is looking good! We probably have found a proper JDK. Is it the correct version? 30677 BUILD_JDK_VERSION=`"$BUILD_JDK/bin/java" -version 2>&1 | $HEAD -n 1` 30678 30679 # Extra M4 quote needed to protect [] in grep expression. 30680 FOUND_CORRECT_VERSION=`echo $BUILD_JDK_VERSION | $EGREP '\"9([\.+-].*)?\"'` 30681 if test "x$FOUND_CORRECT_VERSION" = x; then 30682 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Build JDK found at $BUILD_JDK is incorrect JDK version ($BUILD_JDK_VERSION); ignoring" >&5 30683 $as_echo "$as_me: Potential Build JDK found at $BUILD_JDK is incorrect JDK version ($BUILD_JDK_VERSION); ignoring" >&6;} 30684 { $as_echo "$as_me:${as_lineno-$LINENO}: (Your Build JDK must be version 9)" >&5 30685 $as_echo "$as_me: (Your Build JDK must be version 9)" >&6;} 30686 BUILD_JDK_FOUND=no 30687 else 30688 # We're done! 30689 BUILD_JDK_FOUND=yes 30690 30691 # Only process if variable expands to non-empty 30692 30693 if test "x$BUILD_JDK" != x; then 30694 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 30695 30696 # Input might be given as Windows format, start by converting to 30697 # unix format. 30698 path="$BUILD_JDK" 30699 new_path=`$CYGPATH -u "$path"` 30700 30701 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 30702 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 30703 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 30704 # "foo.exe" is OK but "foo" is an error. 30705 # 30706 # This test is therefore slightly more accurate than "test -f" to check for file precense. 30707 # It is also a way to make sure we got the proper file name for the real test later on. 30708 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 30709 if test "x$test_shortpath" = x; then 30710 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BUILD_JDK, which resolves as \"$path\", is invalid." >&5 30711 $as_echo "$as_me: The path of BUILD_JDK, which resolves as \"$path\", is invalid." >&6;} 30712 as_fn_error $? "Cannot locate the the path of BUILD_JDK" "$LINENO" 5 30713 fi 30714 30715 # Call helper function which possibly converts this using DOS-style short mode. 30716 # If so, the updated path is stored in $new_path. 30717 30718 input_path="$new_path" 30719 # Check if we need to convert this using DOS-style short mode. If the path 30720 # contains just simple characters, use it. Otherwise (spaces, weird characters), 30721 # take no chances and rewrite it. 30722 # Note: m4 eats our [], so we need to use [ and ] instead. 30723 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 30724 if test "x$has_forbidden_chars" != x; then 30725 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 30726 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 30727 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 30728 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 30729 # Going to short mode and back again did indeed matter. Since short mode is 30730 # case insensitive, let's make it lowercase to improve readability. 30731 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 30732 # Now convert it back to Unix-style (cygpath) 30733 input_path=`$CYGPATH -u "$shortmode_path"` 30734 new_path="$input_path" 30735 fi 30736 fi 30737 30738 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 30739 if test "x$test_cygdrive_prefix" = x; then 30740 # As a simple fix, exclude /usr/bin since it's not a real path. 30741 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 30742 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 30743 # a path prefixed by /cygdrive for fixpath to work. 30744 new_path="$CYGWIN_ROOT_PATH$input_path" 30745 fi 30746 fi 30747 30748 30749 if test "x$path" != "x$new_path"; then 30750 BUILD_JDK="$new_path" 30751 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BUILD_JDK to \"$new_path\"" >&5 30752 $as_echo "$as_me: Rewriting BUILD_JDK to \"$new_path\"" >&6;} 30753 fi 30754 30755 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 30756 30757 path="$BUILD_JDK" 30758 has_colon=`$ECHO $path | $GREP ^.:` 30759 new_path="$path" 30760 if test "x$has_colon" = x; then 30761 # Not in mixed or Windows style, start by that. 30762 new_path=`cmd //c echo $path` 30763 fi 30764 30765 30766 input_path="$new_path" 30767 # Check if we need to convert this using DOS-style short mode. If the path 30768 # contains just simple characters, use it. Otherwise (spaces, weird characters), 30769 # take no chances and rewrite it. 30770 # Note: m4 eats our [], so we need to use [ and ] instead. 30771 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 30772 if test "x$has_forbidden_chars" != x; then 30773 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 30774 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 30775 fi 30776 30777 30778 windows_path="$new_path" 30779 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 30780 unix_path=`$CYGPATH -u "$windows_path"` 30781 new_path="$unix_path" 30782 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 30783 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 30784 new_path="$unix_path" 30785 fi 30786 30787 if test "x$path" != "x$new_path"; then 30788 BUILD_JDK="$new_path" 30789 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BUILD_JDK to \"$new_path\"" >&5 30790 $as_echo "$as_me: Rewriting BUILD_JDK to \"$new_path\"" >&6;} 30791 fi 30792 30793 # Save the first 10 bytes of this path to the storage, so fixpath can work. 30794 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 30795 30796 else 30797 # We're on a unix platform. Hooray! :) 30798 path="$BUILD_JDK" 30799 has_space=`$ECHO "$path" | $GREP " "` 30800 if test "x$has_space" != x; then 30801 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BUILD_JDK, which resolves as \"$path\", is invalid." >&5 30802 $as_echo "$as_me: The path of BUILD_JDK, which resolves as \"$path\", is invalid." >&6;} 30803 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 30804 fi 30805 30806 # Use eval to expand a potential ~ 30807 eval path="$path" 30808 if test ! -f "$path" && test ! -d "$path"; then 30809 as_fn_error $? "The path of BUILD_JDK, which resolves as \"$path\", is not found." "$LINENO" 5 30810 fi 30811 30812 if test -d "$path"; then 30813 BUILD_JDK="`cd "$path"; $THEPWDCMD -L`" 30814 else 30815 dir="`$DIRNAME "$path"`" 30816 base="`$BASENAME "$path"`" 30817 BUILD_JDK="`cd "$dir"; $THEPWDCMD -L`/$base" 30818 fi 30819 fi 30820 fi 30821 30822 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for Build JDK" >&5 30823 $as_echo_n "checking for Build JDK... " >&6; } 30824 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BUILD_JDK" >&5 30825 $as_echo "$BUILD_JDK" >&6; } 30826 { $as_echo "$as_me:${as_lineno-$LINENO}: checking Build JDK version" >&5 30827 $as_echo_n "checking Build JDK version... " >&6; } 30828 BUILD_JDK_VERSION=`"$BUILD_JDK/bin/java" -version 2>&1 | $TR '\n\r' ' '` 30829 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BUILD_JDK_VERSION" >&5 30830 $as_echo "$BUILD_JDK_VERSION" >&6; } 30831 fi # end check jdk version 30832 fi # end check java 30833 fi # end check build jdk found 30834 fi 30835 30836 EXTERNAL_BUILDJDK=true 30837 else 30838 if test "x$COMPILE_TYPE" = "xcross"; then 30839 BUILD_JDK="\$(BUILDJDK_OUTPUTDIR)/jdk" 30840 BUILD_JDK_FOUND=yes 30841 CREATE_BUILDJDK=true 30842 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for Build JDK" >&5 30843 $as_echo_n "checking for Build JDK... " >&6; } 30844 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes, will build it for the host platform" >&5 30845 $as_echo "yes, will build it for the host platform" >&6; } 30846 else 30847 BUILD_JDK="\$(JDK_OUTPUTDIR)" 30848 BUILD_JDK_FOUND=yes 30849 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for Build JDK" >&5 30850 $as_echo_n "checking for Build JDK... " >&6; } 30851 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes, will use output dir" >&5 30852 $as_echo "yes, will use output dir" >&6; } 30853 fi 30854 fi 30855 30856 JMOD="$BUILD_JDK/bin/jmod" 30857 JLINK="$BUILD_JDK/bin/jlink" 30858 30859 30860 30861 if test "x$BUILD_JDK_FOUND" != "xyes"; then 30862 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for Build JDK" >&5 30863 $as_echo_n "checking for Build JDK... " >&6; } 30864 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 30865 $as_echo "no" >&6; } 30866 as_fn_error $? "Could not find a suitable Build JDK" "$LINENO" 5 30867 fi 30868 30869 30870 30871 30872 30873 30874 ############################################################################### 30875 # 30876 # Configure the sources to use. We can add or override individual directories. 30877 # 30878 ############################################################################### 30879 30880 30881 # Where are the sources. 30882 LANGTOOLS_TOPDIR="$SRC_ROOT/langtools" 30883 CORBA_TOPDIR="$SRC_ROOT/corba" 30884 JAXP_TOPDIR="$SRC_ROOT/jaxp" 30885 JAXWS_TOPDIR="$SRC_ROOT/jaxws" 30886 HOTSPOT_TOPDIR="$SRC_ROOT/hotspot" 30887 NASHORN_TOPDIR="$SRC_ROOT/nashorn" 30888 JDK_TOPDIR="$SRC_ROOT/jdk" 30889 30890 30891 30892 30893 30894 30895 30896 30897 30898 # This feature is no longer supported. 30899 30900 30901 30902 # Check whether --with-add-source-root was given. 30903 if test "${with_add_source_root+set}" = set; then : 30904 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 30905 $as_echo "$as_me: WARNING: Option --with-add-source-root is deprecated and will be ignored." >&2;} 30906 fi 30907 30908 30909 30910 30911 # Check whether --with-override-source-root was given. 30912 if test "${with_override_source_root+set}" = set; then : 30913 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 30914 $as_echo "$as_me: WARNING: Option --with-override-source-root is deprecated and will be ignored." >&2;} 30915 fi 30916 30917 30918 30919 30920 # Check whether --with-adds-and-overrides was given. 30921 if test "${with_adds_and_overrides+set}" = set; then : 30922 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 30923 $as_echo "$as_me: WARNING: Option --with-adds-and-overrides is deprecated and will be ignored." >&2;} 30924 fi 30925 30926 30927 30928 30929 # Check whether --with-override-langtools was given. 30930 if test "${with_override_langtools+set}" = set; then : 30931 withval=$with_override_langtools; { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Option --with-override-langtools is deprecated and will be ignored." >&5 30932 $as_echo "$as_me: WARNING: Option --with-override-langtools is deprecated and will be ignored." >&2;} 30933 fi 30934 30935 30936 30937 30938 # Check whether --with-override-corba was given. 30939 if test "${with_override_corba+set}" = set; then : 30940 withval=$with_override_corba; { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Option --with-override-corba is deprecated and will be ignored." >&5 30941 $as_echo "$as_me: WARNING: Option --with-override-corba is deprecated and will be ignored." >&2;} 30942 fi 30943 30944 30945 30946 30947 # Check whether --with-override-jaxp was given. 30948 if test "${with_override_jaxp+set}" = set; then : 30949 withval=$with_override_jaxp; { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Option --with-override-jaxp is deprecated and will be ignored." >&5 30950 $as_echo "$as_me: WARNING: Option --with-override-jaxp is deprecated and will be ignored." >&2;} 30951 fi 30952 30953 30954 30955 30956 # Check whether --with-override-jaxws was given. 30957 if test "${with_override_jaxws+set}" = set; then : 30958 withval=$with_override_jaxws; { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Option --with-override-jaxws is deprecated and will be ignored." >&5 30959 $as_echo "$as_me: WARNING: Option --with-override-jaxws is deprecated and will be ignored." >&2;} 30960 fi 30961 30962 30963 30964 30965 # Check whether --with-override-hotspot was given. 30966 if test "${with_override_hotspot+set}" = set; then : 30967 withval=$with_override_hotspot; { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Option --with-override-hotspot is deprecated and will be ignored." >&5 30968 $as_echo "$as_me: WARNING: Option --with-override-hotspot is deprecated and will be ignored." >&2;} 30969 fi 30970 30971 30972 30973 30974 # Check whether --with-override-nashorn was given. 30975 if test "${with_override_nashorn+set}" = set; then : 30976 withval=$with_override_nashorn; { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Option --with-override-nashorn is deprecated and will be ignored." >&5 30977 $as_echo "$as_me: WARNING: Option --with-override-nashorn is deprecated and will be ignored." >&2;} 30978 fi 30979 30980 30981 30982 30983 # Check whether --with-override-jdk was given. 30984 if test "${with_override_jdk+set}" = set; then : 30985 withval=$with_override_jdk; { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Option --with-override-jdk is deprecated and will be ignored." >&5 30986 $as_echo "$as_me: WARNING: Option --with-override-jdk is deprecated and will be ignored." >&2;} 30987 fi 30988 30989 30990 30991 30992 BUILD_OUTPUT="$OUTPUT_ROOT" 30993 30994 30995 HOTSPOT_DIST="$OUTPUT_ROOT/hotspot/dist" 30996 BUILD_HOTSPOT=true 30997 30998 30999 31000 # Check whether --with-import-hotspot was given. 31001 if test "${with_import_hotspot+set}" = set; then : 31002 withval=$with_import_hotspot; 31003 fi 31004 31005 if test "x$with_import_hotspot" != x; then 31006 CURDIR="$PWD" 31007 cd "$with_import_hotspot" 31008 HOTSPOT_DIST="`pwd`" 31009 cd "$CURDIR" 31010 if ! (test -d $HOTSPOT_DIST/lib && test -d $HOTSPOT_DIST/jre/lib); then 31011 as_fn_error $? "You have to import hotspot from a full jdk image or hotspot build dist dir!" "$LINENO" 5 31012 fi 31013 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if hotspot should be imported" >&5 31014 $as_echo_n "checking if hotspot should be imported... " >&6; } 31015 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes from $HOTSPOT_DIST" >&5 31016 $as_echo "yes from $HOTSPOT_DIST" >&6; } 31017 BUILD_HOTSPOT=false 31018 fi 31019 31020 JDK_OUTPUTDIR="$OUTPUT_ROOT/jdk" 31021 31022 31023 31024 31025 # Check whether --with-import-modules was given. 31026 if test "${with_import_modules+set}" = set; then : 31027 withval=$with_import_modules; 31028 fi 31029 31030 31031 if test "x$with_import_modules" != x \ 31032 && test "x$with_import_modules" != "xno"; then 31033 if test -d "$with_import_modules"; then 31034 IMPORT_MODULES_TOPDIR="$with_import_modules" 31035 31036 # Only process if variable expands to non-empty 31037 31038 if test "x$IMPORT_MODULES_TOPDIR" != x; then 31039 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 31040 31041 # Input might be given as Windows format, start by converting to 31042 # unix format. 31043 path="$IMPORT_MODULES_TOPDIR" 31044 new_path=`$CYGPATH -u "$path"` 31045 31046 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 31047 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 31048 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 31049 # "foo.exe" is OK but "foo" is an error. 31050 # 31051 # This test is therefore slightly more accurate than "test -f" to check for file precense. 31052 # It is also a way to make sure we got the proper file name for the real test later on. 31053 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 31054 if test "x$test_shortpath" = x; then 31055 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of IMPORT_MODULES_TOPDIR, which resolves as \"$path\", is invalid." >&5 31056 $as_echo "$as_me: The path of IMPORT_MODULES_TOPDIR, which resolves as \"$path\", is invalid." >&6;} 31057 as_fn_error $? "Cannot locate the the path of IMPORT_MODULES_TOPDIR" "$LINENO" 5 31058 fi 31059 31060 # Call helper function which possibly converts this using DOS-style short mode. 31061 # If so, the updated path is stored in $new_path. 31062 31063 input_path="$new_path" 31064 # Check if we need to convert this using DOS-style short mode. If the path 31065 # contains just simple characters, use it. Otherwise (spaces, weird characters), 31066 # take no chances and rewrite it. 31067 # Note: m4 eats our [], so we need to use [ and ] instead. 31068 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 31069 if test "x$has_forbidden_chars" != x; then 31070 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 31071 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 31072 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 31073 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 31074 # Going to short mode and back again did indeed matter. Since short mode is 31075 # case insensitive, let's make it lowercase to improve readability. 31076 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 31077 # Now convert it back to Unix-style (cygpath) 31078 input_path=`$CYGPATH -u "$shortmode_path"` 31079 new_path="$input_path" 31080 fi 31081 fi 31082 31083 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 31084 if test "x$test_cygdrive_prefix" = x; then 31085 # As a simple fix, exclude /usr/bin since it's not a real path. 31086 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 31087 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 31088 # a path prefixed by /cygdrive for fixpath to work. 31089 new_path="$CYGWIN_ROOT_PATH$input_path" 31090 fi 31091 fi 31092 31093 31094 if test "x$path" != "x$new_path"; then 31095 IMPORT_MODULES_TOPDIR="$new_path" 31096 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting IMPORT_MODULES_TOPDIR to \"$new_path\"" >&5 31097 $as_echo "$as_me: Rewriting IMPORT_MODULES_TOPDIR to \"$new_path\"" >&6;} 31098 fi 31099 31100 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 31101 31102 path="$IMPORT_MODULES_TOPDIR" 31103 has_colon=`$ECHO $path | $GREP ^.:` 31104 new_path="$path" 31105 if test "x$has_colon" = x; then 31106 # Not in mixed or Windows style, start by that. 31107 new_path=`cmd //c echo $path` 31108 fi 31109 31110 31111 input_path="$new_path" 31112 # Check if we need to convert this using DOS-style short mode. If the path 31113 # contains just simple characters, use it. Otherwise (spaces, weird characters), 31114 # take no chances and rewrite it. 31115 # Note: m4 eats our [], so we need to use [ and ] instead. 31116 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 31117 if test "x$has_forbidden_chars" != x; then 31118 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 31119 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 31120 fi 31121 31122 31123 windows_path="$new_path" 31124 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 31125 unix_path=`$CYGPATH -u "$windows_path"` 31126 new_path="$unix_path" 31127 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 31128 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 31129 new_path="$unix_path" 31130 fi 31131 31132 if test "x$path" != "x$new_path"; then 31133 IMPORT_MODULES_TOPDIR="$new_path" 31134 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting IMPORT_MODULES_TOPDIR to \"$new_path\"" >&5 31135 $as_echo "$as_me: Rewriting IMPORT_MODULES_TOPDIR to \"$new_path\"" >&6;} 31136 fi 31137 31138 # Save the first 10 bytes of this path to the storage, so fixpath can work. 31139 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 31140 31141 else 31142 # We're on a unix platform. Hooray! :) 31143 path="$IMPORT_MODULES_TOPDIR" 31144 has_space=`$ECHO "$path" | $GREP " "` 31145 if test "x$has_space" != x; then 31146 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of IMPORT_MODULES_TOPDIR, which resolves as \"$path\", is invalid." >&5 31147 $as_echo "$as_me: The path of IMPORT_MODULES_TOPDIR, which resolves as \"$path\", is invalid." >&6;} 31148 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 31149 fi 31150 31151 # Use eval to expand a potential ~ 31152 eval path="$path" 31153 if test ! -f "$path" && test ! -d "$path"; then 31154 as_fn_error $? "The path of IMPORT_MODULES_TOPDIR, which resolves as \"$path\", is not found." "$LINENO" 5 31155 fi 31156 31157 if test -d "$path"; then 31158 IMPORT_MODULES_TOPDIR="`cd "$path"; $THEPWDCMD -L`" 31159 else 31160 dir="`$DIRNAME "$path"`" 31161 base="`$BASENAME "$path"`" 31162 IMPORT_MODULES_TOPDIR="`cd "$dir"; $THEPWDCMD -L`/$base" 31163 fi 31164 fi 31165 fi 31166 31167 elif test -e "$with_import_modules"; then 31168 IMPORT_MODULES_TOPDIR="$CONFIGURESUPPORT_OUTPUTDIR/import-modules" 31169 $RM -rf "$IMPORT_MODULES_TOPDIR" 31170 $MKDIR -p "$IMPORT_MODULES_TOPDIR" 31171 if ! $UNZIP -q "$with_import_modules" -d "$IMPORT_MODULES_TOPDIR"; then 31172 as_fn_error $? "--with-import-modules=\"$with_import_modules\" must point to a dir or a zip file" "$LINENO" 5 31173 fi 31174 else 31175 as_fn_error $? "--with-import-modules=\"$with_import_modules\" must point to a dir or a zip file" "$LINENO" 5 31176 fi 31177 fi 31178 31179 if test -d "$IMPORT_MODULES_TOPDIR/modules"; then 31180 IMPORT_MODULES_CLASSES="$IMPORT_MODULES_TOPDIR/modules" 31181 fi 31182 if test -d "$IMPORT_MODULES_TOPDIR/modules_cmds"; then 31183 IMPORT_MODULES_CMDS="$IMPORT_MODULES_TOPDIR/modules_cmds" 31184 fi 31185 if test -d "$IMPORT_MODULES_TOPDIR/modules_libs"; then 31186 IMPORT_MODULES_LIBS="$IMPORT_MODULES_TOPDIR/modules_libs" 31187 fi 31188 if test -d "$IMPORT_MODULES_TOPDIR/modules_conf"; then 31189 IMPORT_MODULES_CONF="$IMPORT_MODULES_TOPDIR/modules_conf" 31190 fi 31191 if test -d "$IMPORT_MODULES_TOPDIR/modules_src"; then 31192 IMPORT_MODULES_SRC="$IMPORT_MODULES_TOPDIR/modules_src" 31193 fi 31194 if test -d "$IMPORT_MODULES_TOPDIR/make"; then 31195 IMPORT_MODULES_MAKE="$IMPORT_MODULES_TOPDIR/make" 31196 fi 31197 31198 31199 31200 31201 31202 31203 31204 31205 31206 ############################################################################### 31207 # 31208 # Setup the toolchain (compilers etc), i.e. tools used to compile and process 31209 # native code. 31210 # 31211 ############################################################################### 31212 31213 # See if we are doing a complete static build or not 31214 31215 # Check whether --enable-static-build was given. 31216 if test "${enable_static_build+set}" = set; then : 31217 enableval=$enable_static_build; 31218 fi 31219 31220 STATIC_BUILD=false 31221 if test "x$enable_static_build" = "xyes"; then 31222 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if static build is enabled" >&5 31223 $as_echo_n "checking if static build is enabled... " >&6; } 31224 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 31225 $as_echo "yes" >&6; } 31226 if test "x$OPENJDK_TARGET_OS" != "xmacosx"; then 31227 as_fn_error $? "--enable-static-build is only supported for macosx builds" "$LINENO" 5 31228 fi 31229 STATIC_BUILD_CFLAGS="-DSTATIC_BUILD=1" 31230 LEGACY_EXTRA_CFLAGS="$LEGACY_EXTRA_CFLAGS $STATIC_BUILD_CFLAGS" 31231 LEGACY_EXTRA_CXXFLAGS="$LEGACY_EXTRA_CXXFLAGS $STATIC_BUILD_CFLAGS" 31232 CFLAGS_JDKLIB_EXTRA="$CFLAGS_JDKLIB_EXTRA $STATIC_BUILD_CFLAGS" 31233 CXXFLAGS_JDKLIB_EXTRA="$CXXFLAGS_JDKLIB_EXTRA $STATIC_BUILD_CFLAGS" 31234 STATIC_BUILD=true 31235 elif test "x$enable_static_build" = "xno"; 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: no" >&5 31239 $as_echo "no" >&6; } 31240 elif test "x$enable_static_build" != "x"; then 31241 as_fn_error $? "--enable-static-build can only be assigned \"yes\" or \"no\"" "$LINENO" 5 31242 fi 31243 31244 31245 31246 31247 # First determine the toolchain type (compiler family) 31248 31249 31250 # Check whether --with-toolchain-type was given. 31251 if test "${with_toolchain_type+set}" = set; then : 31252 withval=$with_toolchain_type; 31253 fi 31254 31255 31256 # Use indirect variable referencing 31257 toolchain_var_name=VALID_TOOLCHAINS_$OPENJDK_BUILD_OS 31258 VALID_TOOLCHAINS=${!toolchain_var_name} 31259 31260 if test "x$OPENJDK_TARGET_OS" = xmacosx; then 31261 if test -n "$XCODEBUILD"; then 31262 # On Mac OS X, default toolchain to clang after Xcode 5 31263 XCODE_VERSION_OUTPUT=`"$XCODEBUILD" -version 2>&1 | $HEAD -n 1` 31264 $ECHO "$XCODE_VERSION_OUTPUT" | $GREP "Xcode " > /dev/null 31265 if test $? -ne 0; then 31266 as_fn_error $? "Failed to determine Xcode version." "$LINENO" 5 31267 fi 31268 XCODE_MAJOR_VERSION=`$ECHO $XCODE_VERSION_OUTPUT | \ 31269 $SED -e 's/^Xcode \([1-9][0-9.]*\)/\1/' | \ 31270 $CUT -f 1 -d .` 31271 { $as_echo "$as_me:${as_lineno-$LINENO}: Xcode major version: $XCODE_MAJOR_VERSION" >&5 31272 $as_echo "$as_me: Xcode major version: $XCODE_MAJOR_VERSION" >&6;} 31273 if test $XCODE_MAJOR_VERSION -ge 5; then 31274 DEFAULT_TOOLCHAIN="clang" 31275 else 31276 DEFAULT_TOOLCHAIN="gcc" 31277 fi 31278 else 31279 # If Xcode is not installed, but the command line tools are 31280 # then we can't run xcodebuild. On these systems we should 31281 # default to clang 31282 DEFAULT_TOOLCHAIN="clang" 31283 fi 31284 else 31285 # First toolchain type in the list is the default 31286 DEFAULT_TOOLCHAIN=${VALID_TOOLCHAINS%% *} 31287 fi 31288 31289 if test "x$with_toolchain_type" = xlist; then 31290 # List all toolchains 31291 { $as_echo "$as_me:${as_lineno-$LINENO}: The following toolchains are valid on this platform:" >&5 31292 $as_echo "$as_me: The following toolchains are valid on this platform:" >&6;} 31293 for toolchain in $VALID_TOOLCHAINS; do 31294 toolchain_var_name=TOOLCHAIN_DESCRIPTION_$toolchain 31295 TOOLCHAIN_DESCRIPTION=${!toolchain_var_name} 31296 $PRINTF " %-10s %s\n" $toolchain "$TOOLCHAIN_DESCRIPTION" 31297 done 31298 31299 exit 0 31300 elif test "x$with_toolchain_type" != x; then 31301 # User override; check that it is valid 31302 if test "x${VALID_TOOLCHAINS/$with_toolchain_type/}" = "x${VALID_TOOLCHAINS}"; then 31303 { $as_echo "$as_me:${as_lineno-$LINENO}: Toolchain type $with_toolchain_type is not valid on this platform." >&5 31304 $as_echo "$as_me: Toolchain type $with_toolchain_type is not valid on this platform." >&6;} 31305 { $as_echo "$as_me:${as_lineno-$LINENO}: Valid toolchains: $VALID_TOOLCHAINS." >&5 31306 $as_echo "$as_me: Valid toolchains: $VALID_TOOLCHAINS." >&6;} 31307 as_fn_error $? "Cannot continue." "$LINENO" 5 31308 fi 31309 TOOLCHAIN_TYPE=$with_toolchain_type 31310 else 31311 # No flag given, use default 31312 TOOLCHAIN_TYPE=$DEFAULT_TOOLCHAIN 31313 fi 31314 31315 31316 TOOLCHAIN_CC_BINARY_clang="clang" 31317 TOOLCHAIN_CC_BINARY_gcc="gcc" 31318 TOOLCHAIN_CC_BINARY_microsoft="cl" 31319 TOOLCHAIN_CC_BINARY_solstudio="cc" 31320 TOOLCHAIN_CC_BINARY_xlc="xlc_r" 31321 31322 TOOLCHAIN_CXX_BINARY_clang="clang++" 31323 TOOLCHAIN_CXX_BINARY_gcc="g++" 31324 TOOLCHAIN_CXX_BINARY_microsoft="cl" 31325 TOOLCHAIN_CXX_BINARY_solstudio="CC" 31326 TOOLCHAIN_CXX_BINARY_xlc="xlC_r" 31327 31328 # Use indirect variable referencing 31329 toolchain_var_name=TOOLCHAIN_DESCRIPTION_$TOOLCHAIN_TYPE 31330 TOOLCHAIN_DESCRIPTION=${!toolchain_var_name} 31331 toolchain_var_name=TOOLCHAIN_MINIMUM_VERSION_$TOOLCHAIN_TYPE 31332 TOOLCHAIN_MINIMUM_VERSION=${!toolchain_var_name} 31333 toolchain_var_name=TOOLCHAIN_CC_BINARY_$TOOLCHAIN_TYPE 31334 TOOLCHAIN_CC_BINARY=${!toolchain_var_name} 31335 toolchain_var_name=TOOLCHAIN_CXX_BINARY_$TOOLCHAIN_TYPE 31336 TOOLCHAIN_CXX_BINARY=${!toolchain_var_name} 31337 31338 31339 # Define filename patterns 31340 if test "x$OPENJDK_TARGET_OS" = xwindows; then 31341 LIBRARY_PREFIX= 31342 SHARED_LIBRARY_SUFFIX='.dll' 31343 STATIC_LIBRARY_SUFFIX='.lib' 31344 SHARED_LIBRARY='$1.dll' 31345 STATIC_LIBRARY='$1.lib' 31346 OBJ_SUFFIX='.obj' 31347 EXE_SUFFIX='.exe' 31348 else 31349 LIBRARY_PREFIX=lib 31350 SHARED_LIBRARY_SUFFIX='.so' 31351 STATIC_LIBRARY_SUFFIX='.a' 31352 SHARED_LIBRARY='lib$1.so' 31353 STATIC_LIBRARY='lib$1.a' 31354 OBJ_SUFFIX='.o' 31355 EXE_SUFFIX='' 31356 if test "x$OPENJDK_TARGET_OS" = xmacosx; then 31357 # For full static builds, we're overloading the SHARED_LIBRARY 31358 # variables in order to limit the amount of changes required. 31359 # It would be better to remove SHARED and just use LIBRARY and 31360 # LIBRARY_SUFFIX for libraries that can be built either 31361 # shared or static and use STATIC_* for libraries that are 31362 # always built statically. 31363 if test "x$STATIC_BUILD" = xtrue; then 31364 SHARED_LIBRARY='lib$1.a' 31365 SHARED_LIBRARY_SUFFIX='.a' 31366 else 31367 SHARED_LIBRARY='lib$1.dylib' 31368 SHARED_LIBRARY_SUFFIX='.dylib' 31369 fi 31370 fi 31371 fi 31372 31373 31374 31375 31376 31377 31378 31379 31380 31381 31382 if test "x$TOOLCHAIN_TYPE" = "x$DEFAULT_TOOLCHAIN"; then 31383 { $as_echo "$as_me:${as_lineno-$LINENO}: Using default toolchain $TOOLCHAIN_TYPE ($TOOLCHAIN_DESCRIPTION)" >&5 31384 $as_echo "$as_me: Using default toolchain $TOOLCHAIN_TYPE ($TOOLCHAIN_DESCRIPTION)" >&6;} 31385 else 31386 { $as_echo "$as_me:${as_lineno-$LINENO}: Using user selected toolchain $TOOLCHAIN_TYPE ($TOOLCHAIN_DESCRIPTION). Default toolchain is $DEFAULT_TOOLCHAIN." >&5 31387 $as_echo "$as_me: Using user selected toolchain $TOOLCHAIN_TYPE ($TOOLCHAIN_DESCRIPTION). Default toolchain is $DEFAULT_TOOLCHAIN." >&6;} 31388 fi 31389 31390 31391 # User supplied flags should be used when configure detects compilers 31392 31393 if test "x$CFLAGS" != "x${ADDED_CFLAGS}"; then 31394 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring CFLAGS($CFLAGS) found in environment. Use --with-extra-cflags" >&5 31395 $as_echo "$as_me: WARNING: Ignoring CFLAGS($CFLAGS) found in environment. Use --with-extra-cflags" >&2;} 31396 fi 31397 31398 if test "x$CXXFLAGS" != "x${ADDED_CXXFLAGS}"; then 31399 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring CXXFLAGS($CXXFLAGS) found in environment. Use --with-extra-cxxflags" >&5 31400 $as_echo "$as_me: WARNING: Ignoring CXXFLAGS($CXXFLAGS) found in environment. Use --with-extra-cxxflags" >&2;} 31401 fi 31402 31403 if test "x$LDFLAGS" != "x${ADDED_LDFLAGS}"; then 31404 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring LDFLAGS($LDFLAGS) found in environment. Use --with-extra-ldflags" >&5 31405 $as_echo "$as_me: WARNING: Ignoring LDFLAGS($LDFLAGS) found in environment. Use --with-extra-ldflags" >&2;} 31406 fi 31407 31408 31409 # Check whether --with-extra-cflags was given. 31410 if test "${with_extra_cflags+set}" = set; then : 31411 withval=$with_extra_cflags; 31412 fi 31413 31414 31415 31416 # Check whether --with-extra-cxxflags was given. 31417 if test "${with_extra_cxxflags+set}" = set; then : 31418 withval=$with_extra_cxxflags; 31419 fi 31420 31421 31422 31423 # Check whether --with-extra-ldflags was given. 31424 if test "${with_extra_ldflags+set}" = set; then : 31425 withval=$with_extra_ldflags; 31426 fi 31427 31428 31429 EXTRA_CFLAGS="$with_extra_cflags" 31430 EXTRA_CXXFLAGS="$with_extra_cxxflags" 31431 EXTRA_LDFLAGS="$with_extra_ldflags" 31432 31433 # Hotspot needs these set in their legacy form 31434 LEGACY_EXTRA_CFLAGS="$LEGACY_EXTRA_CFLAGS $EXTRA_CFLAGS" 31435 LEGACY_EXTRA_CXXFLAGS="$LEGACY_EXTRA_CXXFLAGS $EXTRA_CXXFLAGS" 31436 LEGACY_EXTRA_LDFLAGS="$LEGACY_EXTRA_LDFLAGS $EXTRA_LDFLAGS" 31437 31438 31439 31440 31441 31442 31443 31444 31445 31446 # The global CFLAGS and LDLAGS variables are used by configure tests and 31447 # should include the extra parameters 31448 CFLAGS="$EXTRA_CFLAGS" 31449 CXXFLAGS="$EXTRA_CXXFLAGS" 31450 LDFLAGS="$EXTRA_LDFLAGS" 31451 CPPFLAGS="" 31452 31453 # The sysroot cflags are needed for configure to be able to run the compilers 31454 31455 if test "x$SYSROOT" != "x"; then 31456 if test "x$TOOLCHAIN_TYPE" = xsolstudio; then 31457 if test "x$OPENJDK_TARGET_OS" = xsolaris; then 31458 # Solaris Studio does not have a concept of sysroot. Instead we must 31459 # make sure the default include and lib dirs are appended to each 31460 # compile and link command line. Must also add -I-xbuiltin to enable 31461 # inlining of system functions and intrinsics. 31462 SYSROOT_CFLAGS="-I-xbuiltin -I$SYSROOT/usr/include" 31463 SYSROOT_LDFLAGS="-L$SYSROOT/usr/lib$OPENJDK_TARGET_CPU_ISADIR \ 31464 -L$SYSROOT/lib$OPENJDK_TARGET_CPU_ISADIR" 31465 fi 31466 elif test "x$TOOLCHAIN_TYPE" = xgcc; then 31467 SYSROOT_CFLAGS="--sysroot=$SYSROOT" 31468 SYSROOT_LDFLAGS="--sysroot=$SYSROOT" 31469 elif test "x$TOOLCHAIN_TYPE" = xclang; then 31470 SYSROOT_CFLAGS="-isysroot $SYSROOT" 31471 SYSROOT_LDFLAGS="-isysroot $SYSROOT" 31472 fi 31473 # Propagate the sysroot args to hotspot 31474 LEGACY_EXTRA_CFLAGS="$LEGACY_EXTRA_CFLAGS $SYSROOT_CFLAGS" 31475 LEGACY_EXTRA_CXXFLAGS="$LEGACY_EXTRA_CXXFLAGS $SYSROOT_CFLAGS" 31476 LEGACY_EXTRA_LDFLAGS="$LEGACY_EXTRA_LDFLAGS $SYSROOT_LDFLAGS" 31477 # The global CFLAGS and LDFLAGS variables need these for configure to function 31478 CFLAGS="$CFLAGS $SYSROOT_CFLAGS" 31479 CPPFLAGS="$CPPFLAGS $SYSROOT_CFLAGS" 31480 CXXFLAGS="$CXXFLAGS $SYSROOT_CFLAGS" 31481 LDFLAGS="$LDFLAGS $SYSROOT_LDFLAGS" 31482 fi 31483 31484 if test "x$OPENJDK_TARGET_OS" = xmacosx; then 31485 # We also need -iframework<path>/System/Library/Frameworks 31486 SYSROOT_CFLAGS="$SYSROOT_CFLAGS -iframework $SYSROOT/System/Library/Frameworks" 31487 SYSROOT_LDFLAGS="$SYSROOT_LDFLAGS -iframework $SYSROOT/System/Library/Frameworks" 31488 # These always need to be set, or we can't find the frameworks embedded in JavaVM.framework 31489 # set this here so it doesn't have to be peppered throughout the forest 31490 SYSROOT_CFLAGS="$SYSROOT_CFLAGS -F $SYSROOT/System/Library/Frameworks/JavaVM.framework/Frameworks" 31491 SYSROOT_LDFLAGS="$SYSROOT_LDFLAGS -F $SYSROOT/System/Library/Frameworks/JavaVM.framework/Frameworks" 31492 fi 31493 31494 31495 31496 31497 31498 # Then detect the actual binaries needed 31499 31500 # FIXME: Is this needed? 31501 ac_ext=cpp 31502 ac_cpp='$CXXCPP $CPPFLAGS' 31503 ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5' 31504 ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' 31505 ac_compiler_gnu=$ac_cv_cxx_compiler_gnu 31506 31507 31508 # Store the CFLAGS etc passed to the configure script. 31509 ORG_CFLAGS="$CFLAGS" 31510 ORG_CXXFLAGS="$CXXFLAGS" 31511 31512 # autoconf magic only relies on PATH, so update it if tools dir is specified 31513 OLD_PATH="$PATH" 31514 31515 # On Windows, we need to detect the visual studio installation first. 31516 # This will change the PATH, but we need to keep that new PATH even 31517 # after toolchain detection is done, since the compiler (on x86) uses 31518 # it for DLL resolution in runtime. 31519 if test "x$OPENJDK_BUILD_OS" = "xwindows" \ 31520 && test "x$TOOLCHAIN_TYPE" = "xmicrosoft"; then 31521 31522 # Store path to cygwin link.exe to help excluding it when searching for 31523 # VS linker. This must be done before changing the PATH when looking for VS. 31524 # Extract the first word of "link", so it can be a program name with args. 31525 set dummy link; ac_word=$2 31526 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 31527 $as_echo_n "checking for $ac_word... " >&6; } 31528 if ${ac_cv_path_CYGWIN_LINK+:} false; then : 31529 $as_echo_n "(cached) " >&6 31530 else 31531 case $CYGWIN_LINK in 31532 [\\/]* | ?:[\\/]*) 31533 ac_cv_path_CYGWIN_LINK="$CYGWIN_LINK" # Let the user override the test with a path. 31534 ;; 31535 *) 31536 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 31537 for as_dir in $PATH 31538 do 31539 IFS=$as_save_IFS 31540 test -z "$as_dir" && as_dir=. 31541 for ac_exec_ext in '' $ac_executable_extensions; do 31542 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 31543 ac_cv_path_CYGWIN_LINK="$as_dir/$ac_word$ac_exec_ext" 31544 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 31545 break 2 31546 fi 31547 done 31548 done 31549 IFS=$as_save_IFS 31550 31551 ;; 31552 esac 31553 fi 31554 CYGWIN_LINK=$ac_cv_path_CYGWIN_LINK 31555 if test -n "$CYGWIN_LINK"; then 31556 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CYGWIN_LINK" >&5 31557 $as_echo "$CYGWIN_LINK" >&6; } 31558 else 31559 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 31560 $as_echo "no" >&6; } 31561 fi 31562 31563 31564 if test "x$CYGWIN_LINK" != x; then 31565 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if the first found link.exe is actually the Cygwin link tool" >&5 31566 $as_echo_n "checking if the first found link.exe is actually the Cygwin link tool... " >&6; } 31567 "$CYGWIN_LINK" --version > /dev/null 31568 if test $? -eq 0 ; then 31569 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 31570 $as_echo "yes" >&6; } 31571 else 31572 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 31573 $as_echo "no" >&6; } 31574 # This might be the VS linker. Don't exclude it later on. 31575 CYGWIN_LINK="" 31576 fi 31577 fi 31578 31579 # First-hand choice is to locate and run the vsvars bat file. 31580 31581 31582 # Check whether --with-toolchain-version was given. 31583 if test "${with_toolchain_version+set}" = set; then : 31584 withval=$with_toolchain_version; 31585 fi 31586 31587 31588 if test "x$with_toolchain_version" = xlist; then 31589 # List all toolchains 31590 { $as_echo "$as_me:${as_lineno-$LINENO}: The following toolchain versions are valid on this platform:" >&5 31591 $as_echo "$as_me: The following toolchain versions are valid on this platform:" >&6;} 31592 for version in $VALID_VS_VERSIONS; do 31593 eval VS_DESCRIPTION=\${VS_DESCRIPTION_$version} 31594 $PRINTF " %-10s %s\n" $version "$VS_DESCRIPTION" 31595 done 31596 31597 exit 0 31598 elif test "x$DEVKIT_VS_VERSION" != x; then 31599 VS_VERSION=$DEVKIT_VS_VERSION 31600 TOOLCHAIN_VERSION=$VS_VERSION 31601 eval VS_DESCRIPTION="\${VS_DESCRIPTION_${VS_VERSION}}" 31602 eval VS_VERSION_INTERNAL="\${VS_VERSION_INTERNAL_${VS_VERSION}}" 31603 eval MSVCR_NAME="\${VS_MSVCR_${VS_VERSION}}" 31604 eval MSVCP_NAME="\${VS_MSVCP_${VS_VERSION}}" 31605 eval PLATFORM_TOOLSET="\${VS_VS_PLATFORM_NAME_${VS_VERSION}}" 31606 VS_PATH="$TOOLCHAIN_PATH:$PATH" 31607 31608 # Convert DEVKIT_VS_INCLUDE into windows style VS_INCLUDE so that it 31609 # can still be exported as INCLUDE for compiler invocations without 31610 # SYSROOT_CFLAGS 31611 OLDIFS="$IFS" 31612 IFS=";" 31613 for i in $DEVKIT_VS_INCLUDE; do 31614 ipath=$i 31615 31616 unix_path="$ipath" 31617 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 31618 windows_path=`$CYGPATH -m "$unix_path"` 31619 ipath="$windows_path" 31620 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 31621 windows_path=`cmd //c echo $unix_path` 31622 ipath="$windows_path" 31623 fi 31624 31625 VS_INCLUDE="$VS_INCLUDE;$ipath" 31626 done 31627 # Convert DEVKIT_VS_LIB into VS_LIB so that it can still be exported 31628 # as LIB for compiler invocations without SYSROOT_LDFLAGS 31629 for i in $DEVKIT_VS_LIB; do 31630 libpath=$i 31631 31632 unix_path="$libpath" 31633 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 31634 windows_path=`$CYGPATH -m "$unix_path"` 31635 libpath="$windows_path" 31636 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 31637 windows_path=`cmd //c echo $unix_path` 31638 libpath="$windows_path" 31639 fi 31640 31641 VS_LIB="$VS_LIB;$libpath" 31642 done 31643 IFS="$OLDIFS" 31644 31645 { $as_echo "$as_me:${as_lineno-$LINENO}: Found devkit $VS_DESCRIPTION" >&5 31646 $as_echo "$as_me: Found devkit $VS_DESCRIPTION" >&6;} 31647 31648 elif test "x$with_toolchain_version" != x; then 31649 # User override; check that it is valid 31650 if test "x${VALID_VS_VERSIONS/$with_toolchain_version/}" = "x${VALID_VS_VERSIONS}"; then 31651 { $as_echo "$as_me:${as_lineno-$LINENO}: Visual Studio version $with_toolchain_version is not valid." >&5 31652 $as_echo "$as_me: Visual Studio version $with_toolchain_version is not valid." >&6;} 31653 { $as_echo "$as_me:${as_lineno-$LINENO}: Valid Visual Studio versions: $VALID_VS_VERSIONS." >&5 31654 $as_echo "$as_me: Valid Visual Studio versions: $VALID_VS_VERSIONS." >&6;} 31655 as_fn_error $? "Cannot continue." "$LINENO" 5 31656 fi 31657 VS_VERSIONS_PROBE_LIST="$with_toolchain_version" 31658 else 31659 # No flag given, use default 31660 VS_VERSIONS_PROBE_LIST="$VALID_VS_VERSIONS" 31661 fi 31662 31663 for VS_VERSION in $VS_VERSIONS_PROBE_LIST; do 31664 31665 VS_VERSION="$VS_VERSION" 31666 eval VS_COMNTOOLS_VAR="\${VS_ENVVAR_${VS_VERSION}}" 31667 eval VS_COMNTOOLS="\$${VS_COMNTOOLS_VAR}" 31668 eval VS_INSTALL_DIR="\${VS_VS_INSTALLDIR_${VS_VERSION}}" 31669 eval SDK_INSTALL_DIR="\${VS_SDK_INSTALLDIR_${VS_VERSION}}" 31670 31671 # When using --with-tools-dir, assume it points to the correct and default 31672 # version of Visual Studio or that --with-toolchain-version was also set. 31673 if test "x$with_tools_dir" != x; then 31674 31675 if test "x$VS_ENV_CMD" = x; then 31676 VS_VERSION="${VS_VERSION}" 31677 VS_BASE="$with_tools_dir/../.." 31678 METHOD="--with-tools-dir" 31679 31680 if test "x$OPENJDK_TARGET_CPU_BITS" = x32; then 31681 VCVARSFILE="vc/bin/vcvars32.bat" 31682 else 31683 VCVARSFILE="vc/bin/amd64/vcvars64.bat" 31684 fi 31685 31686 31687 windows_path="$VS_BASE" 31688 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 31689 unix_path=`$CYGPATH -u "$windows_path"` 31690 VS_BASE="$unix_path" 31691 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 31692 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 31693 VS_BASE="$unix_path" 31694 fi 31695 31696 if test -d "$VS_BASE"; then 31697 if test -f "$VS_BASE/$VCVARSFILE"; then 31698 { $as_echo "$as_me:${as_lineno-$LINENO}: Found Visual Studio installation at $VS_BASE using $METHOD" >&5 31699 $as_echo "$as_me: Found Visual Studio installation at $VS_BASE using $METHOD" >&6;} 31700 VS_ENV_CMD="$VS_BASE/$VCVARSFILE" 31701 # PLATFORM_TOOLSET is used during the compilation of the freetype sources (see 31702 # 'LIB_BUILD_FREETYPE' in libraries.m4) and must be one of 'v100', 'v110' or 'v120' for VS 2010, 2012 or VS2013 31703 eval PLATFORM_TOOLSET="\${VS_VS_PLATFORM_NAME_${VS_VERSION}}" 31704 else 31705 { $as_echo "$as_me:${as_lineno-$LINENO}: Found Visual Studio installation at $VS_BASE using $METHOD" >&5 31706 $as_echo "$as_me: Found Visual Studio installation at $VS_BASE using $METHOD" >&6;} 31707 { $as_echo "$as_me:${as_lineno-$LINENO}: Warning: $VCVARSFILE is missing, this is probably Visual Studio Express. Ignoring" >&5 31708 $as_echo "$as_me: Warning: $VCVARSFILE is missing, this is probably Visual Studio Express. Ignoring" >&6;} 31709 fi 31710 fi 31711 fi 31712 31713 31714 if test "x$VS_ENV_CMD" = x; then 31715 VS_VERSION="${VS_VERSION}" 31716 VS_BASE="$with_tools_dir/../../.." 31717 METHOD="--with-tools-dir" 31718 31719 if test "x$OPENJDK_TARGET_CPU_BITS" = x32; then 31720 VCVARSFILE="vc/bin/vcvars32.bat" 31721 else 31722 VCVARSFILE="vc/bin/amd64/vcvars64.bat" 31723 fi 31724 31725 31726 windows_path="$VS_BASE" 31727 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 31728 unix_path=`$CYGPATH -u "$windows_path"` 31729 VS_BASE="$unix_path" 31730 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 31731 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 31732 VS_BASE="$unix_path" 31733 fi 31734 31735 if test -d "$VS_BASE"; then 31736 if test -f "$VS_BASE/$VCVARSFILE"; then 31737 { $as_echo "$as_me:${as_lineno-$LINENO}: Found Visual Studio installation at $VS_BASE using $METHOD" >&5 31738 $as_echo "$as_me: Found Visual Studio installation at $VS_BASE using $METHOD" >&6;} 31739 VS_ENV_CMD="$VS_BASE/$VCVARSFILE" 31740 # PLATFORM_TOOLSET is used during the compilation of the freetype sources (see 31741 # 'LIB_BUILD_FREETYPE' in libraries.m4) and must be one of 'v100', 'v110' or 'v120' for VS 2010, 2012 or VS2013 31742 eval PLATFORM_TOOLSET="\${VS_VS_PLATFORM_NAME_${VS_VERSION}}" 31743 else 31744 { $as_echo "$as_me:${as_lineno-$LINENO}: Found Visual Studio installation at $VS_BASE using $METHOD" >&5 31745 $as_echo "$as_me: Found Visual Studio installation at $VS_BASE using $METHOD" >&6;} 31746 { $as_echo "$as_me:${as_lineno-$LINENO}: Warning: $VCVARSFILE is missing, this is probably Visual Studio Express. Ignoring" >&5 31747 $as_echo "$as_me: Warning: $VCVARSFILE is missing, this is probably Visual Studio Express. Ignoring" >&6;} 31748 fi 31749 fi 31750 fi 31751 31752 if test "x$VS_ENV_CMD" = x; then 31753 # Having specified an argument which is incorrect will produce an instant failure; 31754 # we should not go on looking 31755 { $as_echo "$as_me:${as_lineno-$LINENO}: The path given by --with-tools-dir does not contain a valid" >&5 31756 $as_echo "$as_me: The path given by --with-tools-dir does not contain a valid" >&6;} 31757 { $as_echo "$as_me:${as_lineno-$LINENO}: Visual Studio installation. Please point to the VC/bin or VC/bin/amd64" >&5 31758 $as_echo "$as_me: Visual Studio installation. Please point to the VC/bin or VC/bin/amd64" >&6;} 31759 { $as_echo "$as_me:${as_lineno-$LINENO}: directory within the Visual Studio installation" >&5 31760 $as_echo "$as_me: directory within the Visual Studio installation" >&6;} 31761 as_fn_error $? "Cannot locate a valid Visual Studio installation" "$LINENO" 5 31762 fi 31763 fi 31764 31765 VS_ENV_CMD="" 31766 VS_ENV_ARGS="" 31767 31768 if test "x$VS_COMNTOOLS" != x; then 31769 31770 if test "x$VS_ENV_CMD" = x; then 31771 VS_VERSION="${VS_VERSION}" 31772 VS_BASE="$VS_COMNTOOLS/../.." 31773 METHOD="$VS_COMNTOOLS_VAR variable" 31774 31775 if test "x$OPENJDK_TARGET_CPU_BITS" = x32; then 31776 VCVARSFILE="vc/bin/vcvars32.bat" 31777 else 31778 VCVARSFILE="vc/bin/amd64/vcvars64.bat" 31779 fi 31780 31781 31782 windows_path="$VS_BASE" 31783 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 31784 unix_path=`$CYGPATH -u "$windows_path"` 31785 VS_BASE="$unix_path" 31786 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 31787 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 31788 VS_BASE="$unix_path" 31789 fi 31790 31791 if test -d "$VS_BASE"; then 31792 if test -f "$VS_BASE/$VCVARSFILE"; then 31793 { $as_echo "$as_me:${as_lineno-$LINENO}: Found Visual Studio installation at $VS_BASE using $METHOD" >&5 31794 $as_echo "$as_me: Found Visual Studio installation at $VS_BASE using $METHOD" >&6;} 31795 VS_ENV_CMD="$VS_BASE/$VCVARSFILE" 31796 # PLATFORM_TOOLSET is used during the compilation of the freetype sources (see 31797 # 'LIB_BUILD_FREETYPE' in libraries.m4) and must be one of 'v100', 'v110' or 'v120' for VS 2010, 2012 or VS2013 31798 eval PLATFORM_TOOLSET="\${VS_VS_PLATFORM_NAME_${VS_VERSION}}" 31799 else 31800 { $as_echo "$as_me:${as_lineno-$LINENO}: Found Visual Studio installation at $VS_BASE using $METHOD" >&5 31801 $as_echo "$as_me: Found Visual Studio installation at $VS_BASE using $METHOD" >&6;} 31802 { $as_echo "$as_me:${as_lineno-$LINENO}: Warning: $VCVARSFILE is missing, this is probably Visual Studio Express. Ignoring" >&5 31803 $as_echo "$as_me: Warning: $VCVARSFILE is missing, this is probably Visual Studio Express. Ignoring" >&6;} 31804 fi 31805 fi 31806 fi 31807 31808 fi 31809 if test "x$PROGRAMFILES" != x; then 31810 31811 if test "x$VS_ENV_CMD" = x; then 31812 VS_VERSION="${VS_VERSION}" 31813 VS_BASE="$PROGRAMFILES/$VS_INSTALL_DIR" 31814 METHOD="well-known name" 31815 31816 if test "x$OPENJDK_TARGET_CPU_BITS" = x32; then 31817 VCVARSFILE="vc/bin/vcvars32.bat" 31818 else 31819 VCVARSFILE="vc/bin/amd64/vcvars64.bat" 31820 fi 31821 31822 31823 windows_path="$VS_BASE" 31824 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 31825 unix_path=`$CYGPATH -u "$windows_path"` 31826 VS_BASE="$unix_path" 31827 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 31828 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 31829 VS_BASE="$unix_path" 31830 fi 31831 31832 if test -d "$VS_BASE"; then 31833 if test -f "$VS_BASE/$VCVARSFILE"; then 31834 { $as_echo "$as_me:${as_lineno-$LINENO}: Found Visual Studio installation at $VS_BASE using $METHOD" >&5 31835 $as_echo "$as_me: Found Visual Studio installation at $VS_BASE using $METHOD" >&6;} 31836 VS_ENV_CMD="$VS_BASE/$VCVARSFILE" 31837 # PLATFORM_TOOLSET is used during the compilation of the freetype sources (see 31838 # 'LIB_BUILD_FREETYPE' in libraries.m4) and must be one of 'v100', 'v110' or 'v120' for VS 2010, 2012 or VS2013 31839 eval PLATFORM_TOOLSET="\${VS_VS_PLATFORM_NAME_${VS_VERSION}}" 31840 else 31841 { $as_echo "$as_me:${as_lineno-$LINENO}: Found Visual Studio installation at $VS_BASE using $METHOD" >&5 31842 $as_echo "$as_me: Found Visual Studio installation at $VS_BASE using $METHOD" >&6;} 31843 { $as_echo "$as_me:${as_lineno-$LINENO}: Warning: $VCVARSFILE is missing, this is probably Visual Studio Express. Ignoring" >&5 31844 $as_echo "$as_me: Warning: $VCVARSFILE is missing, this is probably Visual Studio Express. Ignoring" >&6;} 31845 fi 31846 fi 31847 fi 31848 31849 fi 31850 # Work around the insanely named ProgramFiles(x86) env variable 31851 PROGRAMFILES_X86="`env | $SED -n 's/^ProgramFiles(x86)=//p'`" 31852 if test "x$PROGRAMFILES_X86" != x; then 31853 31854 if test "x$VS_ENV_CMD" = x; then 31855 VS_VERSION="${VS_VERSION}" 31856 VS_BASE="$PROGRAMFILES_X86/$VS_INSTALL_DIR" 31857 METHOD="well-known name" 31858 31859 if test "x$OPENJDK_TARGET_CPU_BITS" = x32; then 31860 VCVARSFILE="vc/bin/vcvars32.bat" 31861 else 31862 VCVARSFILE="vc/bin/amd64/vcvars64.bat" 31863 fi 31864 31865 31866 windows_path="$VS_BASE" 31867 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 31868 unix_path=`$CYGPATH -u "$windows_path"` 31869 VS_BASE="$unix_path" 31870 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 31871 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 31872 VS_BASE="$unix_path" 31873 fi 31874 31875 if test -d "$VS_BASE"; then 31876 if test -f "$VS_BASE/$VCVARSFILE"; then 31877 { $as_echo "$as_me:${as_lineno-$LINENO}: Found Visual Studio installation at $VS_BASE using $METHOD" >&5 31878 $as_echo "$as_me: Found Visual Studio installation at $VS_BASE using $METHOD" >&6;} 31879 VS_ENV_CMD="$VS_BASE/$VCVARSFILE" 31880 # PLATFORM_TOOLSET is used during the compilation of the freetype sources (see 31881 # 'LIB_BUILD_FREETYPE' in libraries.m4) and must be one of 'v100', 'v110' or 'v120' for VS 2010, 2012 or VS2013 31882 eval PLATFORM_TOOLSET="\${VS_VS_PLATFORM_NAME_${VS_VERSION}}" 31883 else 31884 { $as_echo "$as_me:${as_lineno-$LINENO}: Found Visual Studio installation at $VS_BASE using $METHOD" >&5 31885 $as_echo "$as_me: Found Visual Studio installation at $VS_BASE using $METHOD" >&6;} 31886 { $as_echo "$as_me:${as_lineno-$LINENO}: Warning: $VCVARSFILE is missing, this is probably Visual Studio Express. Ignoring" >&5 31887 $as_echo "$as_me: Warning: $VCVARSFILE is missing, this is probably Visual Studio Express. Ignoring" >&6;} 31888 fi 31889 fi 31890 fi 31891 31892 fi 31893 31894 if test "x$VS_ENV_CMD" = x; then 31895 VS_VERSION="${VS_VERSION}" 31896 VS_BASE="C:/Program Files/$VS_INSTALL_DIR" 31897 METHOD="well-known name" 31898 31899 if test "x$OPENJDK_TARGET_CPU_BITS" = x32; then 31900 VCVARSFILE="vc/bin/vcvars32.bat" 31901 else 31902 VCVARSFILE="vc/bin/amd64/vcvars64.bat" 31903 fi 31904 31905 31906 windows_path="$VS_BASE" 31907 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 31908 unix_path=`$CYGPATH -u "$windows_path"` 31909 VS_BASE="$unix_path" 31910 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 31911 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 31912 VS_BASE="$unix_path" 31913 fi 31914 31915 if test -d "$VS_BASE"; then 31916 if test -f "$VS_BASE/$VCVARSFILE"; then 31917 { $as_echo "$as_me:${as_lineno-$LINENO}: Found Visual Studio installation at $VS_BASE using $METHOD" >&5 31918 $as_echo "$as_me: Found Visual Studio installation at $VS_BASE using $METHOD" >&6;} 31919 VS_ENV_CMD="$VS_BASE/$VCVARSFILE" 31920 # PLATFORM_TOOLSET is used during the compilation of the freetype sources (see 31921 # 'LIB_BUILD_FREETYPE' in libraries.m4) and must be one of 'v100', 'v110' or 'v120' for VS 2010, 2012 or VS2013 31922 eval PLATFORM_TOOLSET="\${VS_VS_PLATFORM_NAME_${VS_VERSION}}" 31923 else 31924 { $as_echo "$as_me:${as_lineno-$LINENO}: Found Visual Studio installation at $VS_BASE using $METHOD" >&5 31925 $as_echo "$as_me: Found Visual Studio installation at $VS_BASE using $METHOD" >&6;} 31926 { $as_echo "$as_me:${as_lineno-$LINENO}: Warning: $VCVARSFILE is missing, this is probably Visual Studio Express. Ignoring" >&5 31927 $as_echo "$as_me: Warning: $VCVARSFILE is missing, this is probably Visual Studio Express. Ignoring" >&6;} 31928 fi 31929 fi 31930 fi 31931 31932 31933 if test "x$VS_ENV_CMD" = x; then 31934 VS_VERSION="${VS_VERSION}" 31935 VS_BASE="C:/Program Files (x86)/$VS_INSTALL_DIR" 31936 METHOD="well-known name" 31937 31938 if test "x$OPENJDK_TARGET_CPU_BITS" = x32; then 31939 VCVARSFILE="vc/bin/vcvars32.bat" 31940 else 31941 VCVARSFILE="vc/bin/amd64/vcvars64.bat" 31942 fi 31943 31944 31945 windows_path="$VS_BASE" 31946 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 31947 unix_path=`$CYGPATH -u "$windows_path"` 31948 VS_BASE="$unix_path" 31949 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 31950 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 31951 VS_BASE="$unix_path" 31952 fi 31953 31954 if test -d "$VS_BASE"; then 31955 if test -f "$VS_BASE/$VCVARSFILE"; then 31956 { $as_echo "$as_me:${as_lineno-$LINENO}: Found Visual Studio installation at $VS_BASE using $METHOD" >&5 31957 $as_echo "$as_me: Found Visual Studio installation at $VS_BASE using $METHOD" >&6;} 31958 VS_ENV_CMD="$VS_BASE/$VCVARSFILE" 31959 # PLATFORM_TOOLSET is used during the compilation of the freetype sources (see 31960 # 'LIB_BUILD_FREETYPE' in libraries.m4) and must be one of 'v100', 'v110' or 'v120' for VS 2010, 2012 or VS2013 31961 eval PLATFORM_TOOLSET="\${VS_VS_PLATFORM_NAME_${VS_VERSION}}" 31962 else 31963 { $as_echo "$as_me:${as_lineno-$LINENO}: Found Visual Studio installation at $VS_BASE using $METHOD" >&5 31964 $as_echo "$as_me: Found Visual Studio installation at $VS_BASE using $METHOD" >&6;} 31965 { $as_echo "$as_me:${as_lineno-$LINENO}: Warning: $VCVARSFILE is missing, this is probably Visual Studio Express. Ignoring" >&5 31966 $as_echo "$as_me: Warning: $VCVARSFILE is missing, this is probably Visual Studio Express. Ignoring" >&6;} 31967 fi 31968 fi 31969 fi 31970 31971 31972 if test "x$SDK_INSTALL_DIR" != x; then 31973 if test "x$ProgramW6432" != x; then 31974 31975 if test "x$VS_ENV_CMD" = x; then 31976 VS_VERSION="${VS_VERSION}" 31977 WIN_SDK_BASE="$ProgramW6432/$SDK_INSTALL_DIR" 31978 METHOD="well-known name" 31979 31980 windows_path="$WIN_SDK_BASE" 31981 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 31982 unix_path=`$CYGPATH -u "$windows_path"` 31983 WIN_SDK_BASE="$unix_path" 31984 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 31985 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 31986 WIN_SDK_BASE="$unix_path" 31987 fi 31988 31989 if test -d "$WIN_SDK_BASE"; then 31990 # There have been cases of partial or broken SDK installations. A missing 31991 # lib dir is not going to work. 31992 if test ! -d "$WIN_SDK_BASE/lib"; then 31993 { $as_echo "$as_me:${as_lineno-$LINENO}: Found Windows SDK installation at $WIN_SDK_BASE using $METHOD" >&5 31994 $as_echo "$as_me: Found Windows SDK installation at $WIN_SDK_BASE using $METHOD" >&6;} 31995 { $as_echo "$as_me:${as_lineno-$LINENO}: Warning: Installation is broken, lib dir is missing. Ignoring" >&5 31996 $as_echo "$as_me: Warning: Installation is broken, lib dir is missing. Ignoring" >&6;} 31997 elif test -f "$WIN_SDK_BASE/Bin/SetEnv.Cmd"; then 31998 { $as_echo "$as_me:${as_lineno-$LINENO}: Found Windows SDK installation at $WIN_SDK_BASE using $METHOD" >&5 31999 $as_echo "$as_me: Found Windows SDK installation at $WIN_SDK_BASE using $METHOD" >&6;} 32000 VS_ENV_CMD="$WIN_SDK_BASE/Bin/SetEnv.Cmd" 32001 if test "x$OPENJDK_TARGET_CPU_BITS" = x32; then 32002 VS_ENV_ARGS="/x86" 32003 else 32004 VS_ENV_ARGS="/x64" 32005 fi 32006 # PLATFORM_TOOLSET is used during the compilation of the freetype sources (see 32007 # 'LIB_BUILD_FREETYPE' in libraries.m4) and must be 'Windows7.1SDK' for Windows7.1SDK 32008 # TODO: improve detection for other versions of SDK 32009 eval PLATFORM_TOOLSET="\${VS_SDK_PLATFORM_NAME_${VS_VERSION}}" 32010 else 32011 { $as_echo "$as_me:${as_lineno-$LINENO}: Found Windows SDK installation at $WIN_SDK_BASE using $METHOD" >&5 32012 $as_echo "$as_me: Found Windows SDK installation at $WIN_SDK_BASE using $METHOD" >&6;} 32013 { $as_echo "$as_me:${as_lineno-$LINENO}: Warning: Installation is broken, SetEnv.Cmd is missing. Ignoring" >&5 32014 $as_echo "$as_me: Warning: Installation is broken, SetEnv.Cmd is missing. Ignoring" >&6;} 32015 fi 32016 fi 32017 fi 32018 32019 fi 32020 if test "x$PROGRAMW6432" != x; then 32021 32022 if test "x$VS_ENV_CMD" = x; then 32023 VS_VERSION="${VS_VERSION}" 32024 WIN_SDK_BASE="$PROGRAMW6432/$SDK_INSTALL_DIR" 32025 METHOD="well-known name" 32026 32027 windows_path="$WIN_SDK_BASE" 32028 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 32029 unix_path=`$CYGPATH -u "$windows_path"` 32030 WIN_SDK_BASE="$unix_path" 32031 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 32032 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 32033 WIN_SDK_BASE="$unix_path" 32034 fi 32035 32036 if test -d "$WIN_SDK_BASE"; then 32037 # There have been cases of partial or broken SDK installations. A missing 32038 # lib dir is not going to work. 32039 if test ! -d "$WIN_SDK_BASE/lib"; then 32040 { $as_echo "$as_me:${as_lineno-$LINENO}: Found Windows SDK installation at $WIN_SDK_BASE using $METHOD" >&5 32041 $as_echo "$as_me: Found Windows SDK installation at $WIN_SDK_BASE using $METHOD" >&6;} 32042 { $as_echo "$as_me:${as_lineno-$LINENO}: Warning: Installation is broken, lib dir is missing. Ignoring" >&5 32043 $as_echo "$as_me: Warning: Installation is broken, lib dir is missing. Ignoring" >&6;} 32044 elif test -f "$WIN_SDK_BASE/Bin/SetEnv.Cmd"; then 32045 { $as_echo "$as_me:${as_lineno-$LINENO}: Found Windows SDK installation at $WIN_SDK_BASE using $METHOD" >&5 32046 $as_echo "$as_me: Found Windows SDK installation at $WIN_SDK_BASE using $METHOD" >&6;} 32047 VS_ENV_CMD="$WIN_SDK_BASE/Bin/SetEnv.Cmd" 32048 if test "x$OPENJDK_TARGET_CPU_BITS" = x32; then 32049 VS_ENV_ARGS="/x86" 32050 else 32051 VS_ENV_ARGS="/x64" 32052 fi 32053 # PLATFORM_TOOLSET is used during the compilation of the freetype sources (see 32054 # 'LIB_BUILD_FREETYPE' in libraries.m4) and must be 'Windows7.1SDK' for Windows7.1SDK 32055 # TODO: improve detection for other versions of SDK 32056 eval PLATFORM_TOOLSET="\${VS_SDK_PLATFORM_NAME_${VS_VERSION}}" 32057 else 32058 { $as_echo "$as_me:${as_lineno-$LINENO}: Found Windows SDK installation at $WIN_SDK_BASE using $METHOD" >&5 32059 $as_echo "$as_me: Found Windows SDK installation at $WIN_SDK_BASE using $METHOD" >&6;} 32060 { $as_echo "$as_me:${as_lineno-$LINENO}: Warning: Installation is broken, SetEnv.Cmd is missing. Ignoring" >&5 32061 $as_echo "$as_me: Warning: Installation is broken, SetEnv.Cmd is missing. Ignoring" >&6;} 32062 fi 32063 fi 32064 fi 32065 32066 fi 32067 if test "x$PROGRAMFILES" != x; then 32068 32069 if test "x$VS_ENV_CMD" = x; then 32070 VS_VERSION="${VS_VERSION}" 32071 WIN_SDK_BASE="$PROGRAMFILES/$SDK_INSTALL_DIR" 32072 METHOD="well-known name" 32073 32074 windows_path="$WIN_SDK_BASE" 32075 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 32076 unix_path=`$CYGPATH -u "$windows_path"` 32077 WIN_SDK_BASE="$unix_path" 32078 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 32079 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 32080 WIN_SDK_BASE="$unix_path" 32081 fi 32082 32083 if test -d "$WIN_SDK_BASE"; then 32084 # There have been cases of partial or broken SDK installations. A missing 32085 # lib dir is not going to work. 32086 if test ! -d "$WIN_SDK_BASE/lib"; then 32087 { $as_echo "$as_me:${as_lineno-$LINENO}: Found Windows SDK installation at $WIN_SDK_BASE using $METHOD" >&5 32088 $as_echo "$as_me: Found Windows SDK installation at $WIN_SDK_BASE using $METHOD" >&6;} 32089 { $as_echo "$as_me:${as_lineno-$LINENO}: Warning: Installation is broken, lib dir is missing. Ignoring" >&5 32090 $as_echo "$as_me: Warning: Installation is broken, lib dir is missing. Ignoring" >&6;} 32091 elif test -f "$WIN_SDK_BASE/Bin/SetEnv.Cmd"; then 32092 { $as_echo "$as_me:${as_lineno-$LINENO}: Found Windows SDK installation at $WIN_SDK_BASE using $METHOD" >&5 32093 $as_echo "$as_me: Found Windows SDK installation at $WIN_SDK_BASE using $METHOD" >&6;} 32094 VS_ENV_CMD="$WIN_SDK_BASE/Bin/SetEnv.Cmd" 32095 if test "x$OPENJDK_TARGET_CPU_BITS" = x32; then 32096 VS_ENV_ARGS="/x86" 32097 else 32098 VS_ENV_ARGS="/x64" 32099 fi 32100 # PLATFORM_TOOLSET is used during the compilation of the freetype sources (see 32101 # 'LIB_BUILD_FREETYPE' in libraries.m4) and must be 'Windows7.1SDK' for Windows7.1SDK 32102 # TODO: improve detection for other versions of SDK 32103 eval PLATFORM_TOOLSET="\${VS_SDK_PLATFORM_NAME_${VS_VERSION}}" 32104 else 32105 { $as_echo "$as_me:${as_lineno-$LINENO}: Found Windows SDK installation at $WIN_SDK_BASE using $METHOD" >&5 32106 $as_echo "$as_me: Found Windows SDK installation at $WIN_SDK_BASE using $METHOD" >&6;} 32107 { $as_echo "$as_me:${as_lineno-$LINENO}: Warning: Installation is broken, SetEnv.Cmd is missing. Ignoring" >&5 32108 $as_echo "$as_me: Warning: Installation is broken, SetEnv.Cmd is missing. Ignoring" >&6;} 32109 fi 32110 fi 32111 fi 32112 32113 fi 32114 32115 if test "x$VS_ENV_CMD" = x; then 32116 VS_VERSION="${VS_VERSION}" 32117 WIN_SDK_BASE="C:/Program Files/$SDK_INSTALL_DIR" 32118 METHOD="well-known name" 32119 32120 windows_path="$WIN_SDK_BASE" 32121 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 32122 unix_path=`$CYGPATH -u "$windows_path"` 32123 WIN_SDK_BASE="$unix_path" 32124 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 32125 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 32126 WIN_SDK_BASE="$unix_path" 32127 fi 32128 32129 if test -d "$WIN_SDK_BASE"; then 32130 # There have been cases of partial or broken SDK installations. A missing 32131 # lib dir is not going to work. 32132 if test ! -d "$WIN_SDK_BASE/lib"; then 32133 { $as_echo "$as_me:${as_lineno-$LINENO}: Found Windows SDK installation at $WIN_SDK_BASE using $METHOD" >&5 32134 $as_echo "$as_me: Found Windows SDK installation at $WIN_SDK_BASE using $METHOD" >&6;} 32135 { $as_echo "$as_me:${as_lineno-$LINENO}: Warning: Installation is broken, lib dir is missing. Ignoring" >&5 32136 $as_echo "$as_me: Warning: Installation is broken, lib dir is missing. Ignoring" >&6;} 32137 elif test -f "$WIN_SDK_BASE/Bin/SetEnv.Cmd"; then 32138 { $as_echo "$as_me:${as_lineno-$LINENO}: Found Windows SDK installation at $WIN_SDK_BASE using $METHOD" >&5 32139 $as_echo "$as_me: Found Windows SDK installation at $WIN_SDK_BASE using $METHOD" >&6;} 32140 VS_ENV_CMD="$WIN_SDK_BASE/Bin/SetEnv.Cmd" 32141 if test "x$OPENJDK_TARGET_CPU_BITS" = x32; then 32142 VS_ENV_ARGS="/x86" 32143 else 32144 VS_ENV_ARGS="/x64" 32145 fi 32146 # PLATFORM_TOOLSET is used during the compilation of the freetype sources (see 32147 # 'LIB_BUILD_FREETYPE' in libraries.m4) and must be 'Windows7.1SDK' for Windows7.1SDK 32148 # TODO: improve detection for other versions of SDK 32149 eval PLATFORM_TOOLSET="\${VS_SDK_PLATFORM_NAME_${VS_VERSION}}" 32150 else 32151 { $as_echo "$as_me:${as_lineno-$LINENO}: Found Windows SDK installation at $WIN_SDK_BASE using $METHOD" >&5 32152 $as_echo "$as_me: Found Windows SDK installation at $WIN_SDK_BASE using $METHOD" >&6;} 32153 { $as_echo "$as_me:${as_lineno-$LINENO}: Warning: Installation is broken, SetEnv.Cmd is missing. Ignoring" >&5 32154 $as_echo "$as_me: Warning: Installation is broken, SetEnv.Cmd is missing. Ignoring" >&6;} 32155 fi 32156 fi 32157 fi 32158 32159 32160 if test "x$VS_ENV_CMD" = x; then 32161 VS_VERSION="${VS_VERSION}" 32162 WIN_SDK_BASE="C:/Program Files (x86)/$SDK_INSTALL_DIR" 32163 METHOD="well-known name" 32164 32165 windows_path="$WIN_SDK_BASE" 32166 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 32167 unix_path=`$CYGPATH -u "$windows_path"` 32168 WIN_SDK_BASE="$unix_path" 32169 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 32170 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 32171 WIN_SDK_BASE="$unix_path" 32172 fi 32173 32174 if test -d "$WIN_SDK_BASE"; then 32175 # There have been cases of partial or broken SDK installations. A missing 32176 # lib dir is not going to work. 32177 if test ! -d "$WIN_SDK_BASE/lib"; then 32178 { $as_echo "$as_me:${as_lineno-$LINENO}: Found Windows SDK installation at $WIN_SDK_BASE using $METHOD" >&5 32179 $as_echo "$as_me: Found Windows SDK installation at $WIN_SDK_BASE using $METHOD" >&6;} 32180 { $as_echo "$as_me:${as_lineno-$LINENO}: Warning: Installation is broken, lib dir is missing. Ignoring" >&5 32181 $as_echo "$as_me: Warning: Installation is broken, lib dir is missing. Ignoring" >&6;} 32182 elif test -f "$WIN_SDK_BASE/Bin/SetEnv.Cmd"; then 32183 { $as_echo "$as_me:${as_lineno-$LINENO}: Found Windows SDK installation at $WIN_SDK_BASE using $METHOD" >&5 32184 $as_echo "$as_me: Found Windows SDK installation at $WIN_SDK_BASE using $METHOD" >&6;} 32185 VS_ENV_CMD="$WIN_SDK_BASE/Bin/SetEnv.Cmd" 32186 if test "x$OPENJDK_TARGET_CPU_BITS" = x32; then 32187 VS_ENV_ARGS="/x86" 32188 else 32189 VS_ENV_ARGS="/x64" 32190 fi 32191 # PLATFORM_TOOLSET is used during the compilation of the freetype sources (see 32192 # 'LIB_BUILD_FREETYPE' in libraries.m4) and must be 'Windows7.1SDK' for Windows7.1SDK 32193 # TODO: improve detection for other versions of SDK 32194 eval PLATFORM_TOOLSET="\${VS_SDK_PLATFORM_NAME_${VS_VERSION}}" 32195 else 32196 { $as_echo "$as_me:${as_lineno-$LINENO}: Found Windows SDK installation at $WIN_SDK_BASE using $METHOD" >&5 32197 $as_echo "$as_me: Found Windows SDK installation at $WIN_SDK_BASE using $METHOD" >&6;} 32198 { $as_echo "$as_me:${as_lineno-$LINENO}: Warning: Installation is broken, SetEnv.Cmd is missing. Ignoring" >&5 32199 $as_echo "$as_me: Warning: Installation is broken, SetEnv.Cmd is missing. Ignoring" >&6;} 32200 fi 32201 fi 32202 fi 32203 32204 fi 32205 32206 if test "x$VS_ENV_CMD" != x; then 32207 TOOLCHAIN_VERSION=$VS_VERSION 32208 eval VS_DESCRIPTION="\${VS_DESCRIPTION_${VS_VERSION}}" 32209 eval VS_VERSION_INTERNAL="\${VS_VERSION_INTERNAL_${VS_VERSION}}" 32210 eval MSVCR_NAME="\${VS_MSVCR_${VS_VERSION}}" 32211 eval MSVCP_NAME="\${VS_MSVCP_${VS_VERSION}}" 32212 # The rest of the variables are already evaled while probing 32213 { $as_echo "$as_me:${as_lineno-$LINENO}: Found $VS_DESCRIPTION" >&5 32214 $as_echo "$as_me: Found $VS_DESCRIPTION" >&6;} 32215 break 32216 fi 32217 done 32218 32219 32220 # If we have a devkit, skip all of the below. 32221 if test "x$DEVKIT_VS_VERSION" = x; then 32222 if test "x$VS_ENV_CMD" != x; then 32223 # We have found a Visual Studio environment on disk, let's extract variables from the vsvars bat file. 32224 32225 # Only process if variable expands to non-empty 32226 32227 if test "x$VS_ENV_CMD" != x; then 32228 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 32229 32230 # First separate the path from the arguments. This will split at the first 32231 # space. 32232 complete="$VS_ENV_CMD" 32233 path="${complete%% *}" 32234 tmp="$complete EOL" 32235 arguments="${tmp#* }" 32236 32237 # Input might be given as Windows format, start by converting to 32238 # unix format. 32239 new_path=`$CYGPATH -u "$path"` 32240 32241 # Now try to locate executable using which 32242 new_path=`$WHICH "$new_path" 2> /dev/null` 32243 # bat and cmd files are not always considered executable in cygwin causing which 32244 # to not find them 32245 if test "x$new_path" = x \ 32246 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 32247 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 32248 new_path=`$CYGPATH -u "$path"` 32249 fi 32250 if test "x$new_path" = x; then 32251 # Oops. Which didn't find the executable. 32252 # The splitting of arguments from the executable at a space might have been incorrect, 32253 # since paths with space are more likely in Windows. Give it another try with the whole 32254 # argument. 32255 path="$complete" 32256 arguments="EOL" 32257 new_path=`$CYGPATH -u "$path"` 32258 new_path=`$WHICH "$new_path" 2> /dev/null` 32259 # bat and cmd files are not always considered executable in cygwin causing which 32260 # to not find them 32261 if test "x$new_path" = x \ 32262 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 32263 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 32264 new_path=`$CYGPATH -u "$path"` 32265 fi 32266 if test "x$new_path" = x; then 32267 # It's still not found. Now this is an unrecoverable error. 32268 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of VS_ENV_CMD, which resolves as \"$complete\", is not found." >&5 32269 $as_echo "$as_me: The path of VS_ENV_CMD, which resolves as \"$complete\", is not found." >&6;} 32270 has_space=`$ECHO "$complete" | $GREP " "` 32271 if test "x$has_space" != x; then 32272 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 32273 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 32274 fi 32275 as_fn_error $? "Cannot locate the the path of VS_ENV_CMD" "$LINENO" 5 32276 fi 32277 fi 32278 32279 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 32280 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 32281 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 32282 # "foo.exe" is OK but "foo" is an error. 32283 # 32284 # This test is therefore slightly more accurate than "test -f" to check for file presence. 32285 # It is also a way to make sure we got the proper file name for the real test later on. 32286 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 32287 if test "x$test_shortpath" = x; then 32288 # Short path failed, file does not exist as specified. 32289 # Try adding .exe or .cmd 32290 if test -f "${new_path}.exe"; then 32291 input_to_shortpath="${new_path}.exe" 32292 elif test -f "${new_path}.cmd"; then 32293 input_to_shortpath="${new_path}.cmd" 32294 else 32295 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of VS_ENV_CMD, which resolves as \"$new_path\", is invalid." >&5 32296 $as_echo "$as_me: The path of VS_ENV_CMD, which resolves as \"$new_path\", is invalid." >&6;} 32297 { $as_echo "$as_me:${as_lineno-$LINENO}: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&5 32298 $as_echo "$as_me: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&6;} 32299 as_fn_error $? "Cannot locate the the path of VS_ENV_CMD" "$LINENO" 5 32300 fi 32301 else 32302 input_to_shortpath="$new_path" 32303 fi 32304 32305 # Call helper function which possibly converts this using DOS-style short mode. 32306 # If so, the updated path is stored in $new_path. 32307 new_path="$input_to_shortpath" 32308 32309 input_path="$input_to_shortpath" 32310 # Check if we need to convert this using DOS-style short mode. If the path 32311 # contains just simple characters, use it. Otherwise (spaces, weird characters), 32312 # take no chances and rewrite it. 32313 # Note: m4 eats our [], so we need to use [ and ] instead. 32314 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 32315 if test "x$has_forbidden_chars" != x; then 32316 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 32317 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 32318 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 32319 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 32320 # Going to short mode and back again did indeed matter. Since short mode is 32321 # case insensitive, let's make it lowercase to improve readability. 32322 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 32323 # Now convert it back to Unix-style (cygpath) 32324 input_path=`$CYGPATH -u "$shortmode_path"` 32325 new_path="$input_path" 32326 fi 32327 fi 32328 32329 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 32330 if test "x$test_cygdrive_prefix" = x; then 32331 # As a simple fix, exclude /usr/bin since it's not a real path. 32332 if test "x`$ECHO $input_to_shortpath | $GREP ^/usr/bin/`" = x; then 32333 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 32334 # a path prefixed by /cygdrive for fixpath to work. 32335 new_path="$CYGWIN_ROOT_PATH$input_path" 32336 fi 32337 fi 32338 32339 # remove trailing .exe if any 32340 new_path="${new_path/%.exe/}" 32341 32342 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 32343 32344 # First separate the path from the arguments. This will split at the first 32345 # space. 32346 complete="$VS_ENV_CMD" 32347 path="${complete%% *}" 32348 tmp="$complete EOL" 32349 arguments="${tmp#* }" 32350 32351 # Input might be given as Windows format, start by converting to 32352 # unix format. 32353 new_path="$path" 32354 32355 windows_path="$new_path" 32356 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 32357 unix_path=`$CYGPATH -u "$windows_path"` 32358 new_path="$unix_path" 32359 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 32360 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 32361 new_path="$unix_path" 32362 fi 32363 32364 32365 # Now try to locate executable using which 32366 new_path=`$WHICH "$new_path" 2> /dev/null` 32367 32368 if test "x$new_path" = x; then 32369 # Oops. Which didn't find the executable. 32370 # The splitting of arguments from the executable at a space might have been incorrect, 32371 # since paths with space are more likely in Windows. Give it another try with the whole 32372 # argument. 32373 path="$complete" 32374 arguments="EOL" 32375 new_path="$path" 32376 32377 windows_path="$new_path" 32378 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 32379 unix_path=`$CYGPATH -u "$windows_path"` 32380 new_path="$unix_path" 32381 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 32382 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 32383 new_path="$unix_path" 32384 fi 32385 32386 32387 new_path=`$WHICH "$new_path" 2> /dev/null` 32388 # bat and cmd files are not always considered executable in MSYS causing which 32389 # to not find them 32390 if test "x$new_path" = x \ 32391 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 32392 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 32393 new_path="$path" 32394 32395 windows_path="$new_path" 32396 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 32397 unix_path=`$CYGPATH -u "$windows_path"` 32398 new_path="$unix_path" 32399 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 32400 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 32401 new_path="$unix_path" 32402 fi 32403 32404 fi 32405 32406 if test "x$new_path" = x; then 32407 # It's still not found. Now this is an unrecoverable error. 32408 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of VS_ENV_CMD, which resolves as \"$complete\", is not found." >&5 32409 $as_echo "$as_me: The path of VS_ENV_CMD, which resolves as \"$complete\", is not found." >&6;} 32410 has_space=`$ECHO "$complete" | $GREP " "` 32411 if test "x$has_space" != x; then 32412 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 32413 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 32414 fi 32415 as_fn_error $? "Cannot locate the the path of VS_ENV_CMD" "$LINENO" 5 32416 fi 32417 fi 32418 32419 # Now new_path has a complete unix path to the binary 32420 if test "x`$ECHO $new_path | $GREP ^/bin/`" != x; then 32421 # Keep paths in /bin as-is, but remove trailing .exe if any 32422 new_path="${new_path/%.exe/}" 32423 # Do not save /bin paths to all_fixpath_prefixes! 32424 else 32425 # Not in mixed or Windows style, start by that. 32426 new_path=`cmd //c echo $new_path` 32427 32428 input_path="$new_path" 32429 # Check if we need to convert this using DOS-style short mode. If the path 32430 # contains just simple characters, use it. Otherwise (spaces, weird characters), 32431 # take no chances and rewrite it. 32432 # Note: m4 eats our [], so we need to use [ and ] instead. 32433 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 32434 if test "x$has_forbidden_chars" != x; then 32435 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 32436 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 32437 fi 32438 32439 # Output is in $new_path 32440 32441 windows_path="$new_path" 32442 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 32443 unix_path=`$CYGPATH -u "$windows_path"` 32444 new_path="$unix_path" 32445 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 32446 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 32447 new_path="$unix_path" 32448 fi 32449 32450 # remove trailing .exe if any 32451 new_path="${new_path/%.exe/}" 32452 32453 # Save the first 10 bytes of this path to the storage, so fixpath can work. 32454 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 32455 fi 32456 32457 else 32458 # We're on a unix platform. Hooray! :) 32459 # First separate the path from the arguments. This will split at the first 32460 # space. 32461 complete="$VS_ENV_CMD" 32462 path="${complete%% *}" 32463 tmp="$complete EOL" 32464 arguments="${tmp#* }" 32465 32466 # Cannot rely on the command "which" here since it doesn't always work. 32467 is_absolute_path=`$ECHO "$path" | $GREP ^/` 32468 if test -z "$is_absolute_path"; then 32469 # Path to executable is not absolute. Find it. 32470 IFS_save="$IFS" 32471 IFS=: 32472 for p in $PATH; do 32473 if test -f "$p/$path" && test -x "$p/$path"; then 32474 new_path="$p/$path" 32475 break 32476 fi 32477 done 32478 IFS="$IFS_save" 32479 else 32480 # This is an absolute path, we can use it without further modifications. 32481 new_path="$path" 32482 fi 32483 32484 if test "x$new_path" = x; then 32485 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of VS_ENV_CMD, which resolves as \"$complete\", is not found." >&5 32486 $as_echo "$as_me: The path of VS_ENV_CMD, which resolves as \"$complete\", is not found." >&6;} 32487 has_space=`$ECHO "$complete" | $GREP " "` 32488 if test "x$has_space" != x; then 32489 { $as_echo "$as_me:${as_lineno-$LINENO}: This might be caused by spaces in the path, which is not allowed." >&5 32490 $as_echo "$as_me: This might be caused by spaces in the path, which is not allowed." >&6;} 32491 fi 32492 as_fn_error $? "Cannot locate the the path of VS_ENV_CMD" "$LINENO" 5 32493 fi 32494 fi 32495 32496 # Now join together the path and the arguments once again 32497 if test "x$arguments" != xEOL; then 32498 new_complete="$new_path ${arguments% *}" 32499 else 32500 new_complete="$new_path" 32501 fi 32502 32503 if test "x$complete" != "x$new_complete"; then 32504 VS_ENV_CMD="$new_complete" 32505 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting VS_ENV_CMD to \"$new_complete\"" >&5 32506 $as_echo "$as_me: Rewriting VS_ENV_CMD to \"$new_complete\"" >&6;} 32507 fi 32508 fi 32509 32510 32511 # Lets extract the variables that are set by vcvarsall.bat/vsvars32.bat/vsvars64.bat 32512 { $as_echo "$as_me:${as_lineno-$LINENO}: Trying to extract Visual Studio environment variables" >&5 32513 $as_echo "$as_me: Trying to extract Visual Studio environment variables" >&6;} 32514 32515 # We need to create a couple of temporary files. 32516 VS_ENV_TMP_DIR="$CONFIGURESUPPORT_OUTPUTDIR/vs-env" 32517 $MKDIR -p $VS_ENV_TMP_DIR 32518 32519 # Cannot use the VS10 setup script directly (since it only updates the DOS subshell environment). 32520 # Instead create a shell script which will set the relevant variables when run. 32521 WINPATH_VS_ENV_CMD="$VS_ENV_CMD" 32522 32523 unix_path="$WINPATH_VS_ENV_CMD" 32524 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 32525 windows_path=`$CYGPATH -m "$unix_path"` 32526 WINPATH_VS_ENV_CMD="$windows_path" 32527 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 32528 windows_path=`cmd //c echo $unix_path` 32529 WINPATH_VS_ENV_CMD="$windows_path" 32530 fi 32531 32532 WINPATH_BASH="$BASH" 32533 32534 unix_path="$WINPATH_BASH" 32535 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 32536 windows_path=`$CYGPATH -m "$unix_path"` 32537 WINPATH_BASH="$windows_path" 32538 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 32539 windows_path=`cmd //c echo $unix_path` 32540 WINPATH_BASH="$windows_path" 32541 fi 32542 32543 32544 # Generate a DOS batch file which runs $VS_ENV_CMD, and then creates a shell 32545 # script (executable by bash) that will setup the important variables. 32546 EXTRACT_VC_ENV_BAT_FILE="$VS_ENV_TMP_DIR/extract-vs-env.bat" 32547 $ECHO "@echo off" > $EXTRACT_VC_ENV_BAT_FILE 32548 # This will end up something like: 32549 # call C:/progra~2/micros~2.0/vc/bin/amd64/vcvars64.bat 32550 $ECHO "call $WINPATH_VS_ENV_CMD $VS_ENV_ARGS" >> $EXTRACT_VC_ENV_BAT_FILE 32551 # These will end up something like: 32552 # C:/CygWin/bin/bash -c 'echo VS_PATH=\"$PATH\" > localdevenv.sh 32553 # The trailing space for everyone except PATH is no typo, but is needed due 32554 # to trailing \ in the Windows paths. These will be stripped later. 32555 $ECHO "$WINPATH_BASH -c 'echo VS_PATH="'\"$PATH\" > set-vs-env.sh' \ 32556 >> $EXTRACT_VC_ENV_BAT_FILE 32557 $ECHO "$WINPATH_BASH -c 'echo VS_INCLUDE="'\"$INCLUDE\;$include \" >> set-vs-env.sh' \ 32558 >> $EXTRACT_VC_ENV_BAT_FILE 32559 $ECHO "$WINPATH_BASH -c 'echo VS_LIB="'\"$LIB\;$lib \" >> set-vs-env.sh' \ 32560 >> $EXTRACT_VC_ENV_BAT_FILE 32561 $ECHO "$WINPATH_BASH -c 'echo VCINSTALLDIR="'\"$VCINSTALLDIR \" >> set-vs-env.sh' \ 32562 >> $EXTRACT_VC_ENV_BAT_FILE 32563 $ECHO "$WINPATH_BASH -c 'echo WindowsSdkDir="'\"$WindowsSdkDir \" >> set-vs-env.sh' \ 32564 >> $EXTRACT_VC_ENV_BAT_FILE 32565 $ECHO "$WINPATH_BASH -c 'echo WINDOWSSDKDIR="'\"$WINDOWSSDKDIR \" >> set-vs-env.sh' \ 32566 >> $EXTRACT_VC_ENV_BAT_FILE 32567 32568 # Now execute the newly created bat file. 32569 # The | cat is to stop SetEnv.Cmd to mess with system colors on msys. 32570 # Change directory so we don't need to mess with Windows paths in redirects. 32571 cd $VS_ENV_TMP_DIR 32572 cmd /c extract-vs-env.bat | $CAT 32573 cd $CURDIR 32574 32575 if test ! -s $VS_ENV_TMP_DIR/set-vs-env.sh; then 32576 { $as_echo "$as_me:${as_lineno-$LINENO}: Could not succesfully extract the envionment variables needed for the VS setup." >&5 32577 $as_echo "$as_me: Could not succesfully extract the envionment variables needed for the VS setup." >&6;} 32578 { $as_echo "$as_me:${as_lineno-$LINENO}: Try setting --with-tools-dir to the VC/bin directory within the VS installation" >&5 32579 $as_echo "$as_me: Try setting --with-tools-dir to the VC/bin directory within the VS installation" >&6;} 32580 { $as_echo "$as_me:${as_lineno-$LINENO}: or run \"bash.exe -l\" from a VS command prompt and then run configure from there." >&5 32581 $as_echo "$as_me: or run \"bash.exe -l\" from a VS command prompt and then run configure from there." >&6;} 32582 as_fn_error $? "Cannot continue" "$LINENO" 5 32583 fi 32584 32585 # Now set all paths and other env variables. This will allow the rest of 32586 # the configure script to find and run the compiler in the proper way. 32587 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting extracted environment variables" >&5 32588 $as_echo "$as_me: Setting extracted environment variables" >&6;} 32589 . $VS_ENV_TMP_DIR/set-vs-env.sh 32590 # Now we have VS_PATH, VS_INCLUDE, VS_LIB. For further checking, we 32591 # also define VCINSTALLDIR, WindowsSdkDir and WINDOWSSDKDIR. 32592 else 32593 # We did not find a vsvars bat file, let's hope we are run from a VS command prompt. 32594 { $as_echo "$as_me:${as_lineno-$LINENO}: Cannot locate a valid Visual Studio installation, checking current environment" >&5 32595 $as_echo "$as_me: Cannot locate a valid Visual Studio installation, checking current environment" >&6;} 32596 fi 32597 fi 32598 32599 # At this point, we should have correct variables in the environment, or we can't continue. 32600 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for Visual Studio variables" >&5 32601 $as_echo_n "checking for Visual Studio variables... " >&6; } 32602 32603 if test "x$VCINSTALLDIR" != x || test "x$WindowsSDKDir" != x \ 32604 || test "x$WINDOWSSDKDIR" != x || test "x$DEVKIT_NAME" != x; then 32605 if test "x$VS_INCLUDE" = x || test "x$VS_LIB" = x; then 32606 { $as_echo "$as_me:${as_lineno-$LINENO}: result: present but broken" >&5 32607 $as_echo "present but broken" >&6; } 32608 as_fn_error $? "Your VC command prompt seems broken, INCLUDE and/or LIB is missing." "$LINENO" 5 32609 else 32610 { $as_echo "$as_me:${as_lineno-$LINENO}: result: ok" >&5 32611 $as_echo "ok" >&6; } 32612 # Remove any trailing "\" ";" and " " from the variables. 32613 VS_INCLUDE=`$ECHO "$VS_INCLUDE" | $SED -e 's/\\\\*;* *$//'` 32614 VS_LIB=`$ECHO "$VS_LIB" | $SED 's/\\\\*;* *$//'` 32615 VCINSTALLDIR=`$ECHO "$VCINSTALLDIR" | $SED 's/\\\\* *$//'` 32616 WindowsSDKDir=`$ECHO "$WindowsSDKDir" | $SED 's/\\\\* *$//'` 32617 WINDOWSSDKDIR=`$ECHO "$WINDOWSSDKDIR" | $SED 's/\\\\* *$//'` 32618 # Remove any paths containing # (typically F#) as that messes up make. This 32619 # is needed if visual studio was installed with F# support. 32620 VS_PATH=`$ECHO "$VS_PATH" | $SED 's/[^:#]*#[^:]*://g'` 32621 32622 32623 32624 32625 32626 # Convert VS_INCLUDE into SYSROOT_CFLAGS 32627 OLDIFS="$IFS" 32628 IFS=";" 32629 for i in $VS_INCLUDE; do 32630 ipath=$i 32631 # Only process non-empty elements 32632 if test "x$ipath" != x; then 32633 IFS="$OLDIFS" 32634 # Check that directory exists before calling fixup_path 32635 testpath=$ipath 32636 32637 windows_path="$testpath" 32638 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 32639 unix_path=`$CYGPATH -u "$windows_path"` 32640 testpath="$unix_path" 32641 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 32642 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 32643 testpath="$unix_path" 32644 fi 32645 32646 if test -d "$testpath"; then 32647 32648 # Only process if variable expands to non-empty 32649 32650 if test "x$ipath" != x; then 32651 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 32652 32653 # Input might be given as Windows format, start by converting to 32654 # unix format. 32655 path="$ipath" 32656 new_path=`$CYGPATH -u "$path"` 32657 32658 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 32659 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 32660 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 32661 # "foo.exe" is OK but "foo" is an error. 32662 # 32663 # This test is therefore slightly more accurate than "test -f" to check for file precense. 32664 # It is also a way to make sure we got the proper file name for the real test later on. 32665 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 32666 if test "x$test_shortpath" = x; then 32667 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of ipath, which resolves as \"$path\", is invalid." >&5 32668 $as_echo "$as_me: The path of ipath, which resolves as \"$path\", is invalid." >&6;} 32669 as_fn_error $? "Cannot locate the the path of ipath" "$LINENO" 5 32670 fi 32671 32672 # Call helper function which possibly converts this using DOS-style short mode. 32673 # If so, the updated path is stored in $new_path. 32674 32675 input_path="$new_path" 32676 # Check if we need to convert this using DOS-style short mode. If the path 32677 # contains just simple characters, use it. Otherwise (spaces, weird characters), 32678 # take no chances and rewrite it. 32679 # Note: m4 eats our [], so we need to use [ and ] instead. 32680 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 32681 if test "x$has_forbidden_chars" != x; then 32682 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 32683 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 32684 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 32685 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 32686 # Going to short mode and back again did indeed matter. Since short mode is 32687 # case insensitive, let's make it lowercase to improve readability. 32688 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 32689 # Now convert it back to Unix-style (cygpath) 32690 input_path=`$CYGPATH -u "$shortmode_path"` 32691 new_path="$input_path" 32692 fi 32693 fi 32694 32695 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 32696 if test "x$test_cygdrive_prefix" = x; then 32697 # As a simple fix, exclude /usr/bin since it's not a real path. 32698 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 32699 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 32700 # a path prefixed by /cygdrive for fixpath to work. 32701 new_path="$CYGWIN_ROOT_PATH$input_path" 32702 fi 32703 fi 32704 32705 32706 if test "x$path" != "x$new_path"; then 32707 ipath="$new_path" 32708 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting ipath to \"$new_path\"" >&5 32709 $as_echo "$as_me: Rewriting ipath to \"$new_path\"" >&6;} 32710 fi 32711 32712 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 32713 32714 path="$ipath" 32715 has_colon=`$ECHO $path | $GREP ^.:` 32716 new_path="$path" 32717 if test "x$has_colon" = x; then 32718 # Not in mixed or Windows style, start by that. 32719 new_path=`cmd //c echo $path` 32720 fi 32721 32722 32723 input_path="$new_path" 32724 # Check if we need to convert this using DOS-style short mode. If the path 32725 # contains just simple characters, use it. Otherwise (spaces, weird characters), 32726 # take no chances and rewrite it. 32727 # Note: m4 eats our [], so we need to use [ and ] instead. 32728 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 32729 if test "x$has_forbidden_chars" != x; then 32730 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 32731 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 32732 fi 32733 32734 32735 windows_path="$new_path" 32736 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 32737 unix_path=`$CYGPATH -u "$windows_path"` 32738 new_path="$unix_path" 32739 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 32740 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 32741 new_path="$unix_path" 32742 fi 32743 32744 if test "x$path" != "x$new_path"; then 32745 ipath="$new_path" 32746 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting ipath to \"$new_path\"" >&5 32747 $as_echo "$as_me: Rewriting ipath to \"$new_path\"" >&6;} 32748 fi 32749 32750 # Save the first 10 bytes of this path to the storage, so fixpath can work. 32751 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 32752 32753 else 32754 # We're on a unix platform. Hooray! :) 32755 path="$ipath" 32756 has_space=`$ECHO "$path" | $GREP " "` 32757 if test "x$has_space" != x; then 32758 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of ipath, which resolves as \"$path\", is invalid." >&5 32759 $as_echo "$as_me: The path of ipath, which resolves as \"$path\", is invalid." >&6;} 32760 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 32761 fi 32762 32763 # Use eval to expand a potential ~ 32764 eval path="$path" 32765 if test ! -f "$path" && test ! -d "$path"; then 32766 as_fn_error $? "The path of ipath, which resolves as \"$path\", is not found." "$LINENO" 5 32767 fi 32768 32769 if test -d "$path"; then 32770 ipath="`cd "$path"; $THEPWDCMD -L`" 32771 else 32772 dir="`$DIRNAME "$path"`" 32773 base="`$BASENAME "$path"`" 32774 ipath="`cd "$dir"; $THEPWDCMD -L`/$base" 32775 fi 32776 fi 32777 fi 32778 32779 SYSROOT_CFLAGS="$SYSROOT_CFLAGS -I$ipath" 32780 fi 32781 IFS=";" 32782 fi 32783 done 32784 # Convert VS_LIB into SYSROOT_LDFLAGS 32785 for i in $VS_LIB; do 32786 libpath=$i 32787 # Only process non-empty elements 32788 if test "x$libpath" != x; then 32789 IFS="$OLDIFS" 32790 # Check that directory exists before calling fixup_path 32791 testpath=$libpath 32792 32793 windows_path="$testpath" 32794 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 32795 unix_path=`$CYGPATH -u "$windows_path"` 32796 testpath="$unix_path" 32797 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 32798 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 32799 testpath="$unix_path" 32800 fi 32801 32802 if test -d "$testpath"; then 32803 32804 # Only process if variable expands to non-empty 32805 32806 if test "x$libpath" != x; then 32807 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 32808 32809 # Input might be given as Windows format, start by converting to 32810 # unix format. 32811 path="$libpath" 32812 new_path=`$CYGPATH -u "$path"` 32813 32814 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 32815 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 32816 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 32817 # "foo.exe" is OK but "foo" is an error. 32818 # 32819 # This test is therefore slightly more accurate than "test -f" to check for file precense. 32820 # It is also a way to make sure we got the proper file name for the real test later on. 32821 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 32822 if test "x$test_shortpath" = x; then 32823 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of libpath, which resolves as \"$path\", is invalid." >&5 32824 $as_echo "$as_me: The path of libpath, which resolves as \"$path\", is invalid." >&6;} 32825 as_fn_error $? "Cannot locate the the path of libpath" "$LINENO" 5 32826 fi 32827 32828 # Call helper function which possibly converts this using DOS-style short mode. 32829 # If so, the updated path is stored in $new_path. 32830 32831 input_path="$new_path" 32832 # Check if we need to convert this using DOS-style short mode. If the path 32833 # contains just simple characters, use it. Otherwise (spaces, weird characters), 32834 # take no chances and rewrite it. 32835 # Note: m4 eats our [], so we need to use [ and ] instead. 32836 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 32837 if test "x$has_forbidden_chars" != x; then 32838 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 32839 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 32840 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 32841 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 32842 # Going to short mode and back again did indeed matter. Since short mode is 32843 # case insensitive, let's make it lowercase to improve readability. 32844 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 32845 # Now convert it back to Unix-style (cygpath) 32846 input_path=`$CYGPATH -u "$shortmode_path"` 32847 new_path="$input_path" 32848 fi 32849 fi 32850 32851 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 32852 if test "x$test_cygdrive_prefix" = x; then 32853 # As a simple fix, exclude /usr/bin since it's not a real path. 32854 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 32855 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 32856 # a path prefixed by /cygdrive for fixpath to work. 32857 new_path="$CYGWIN_ROOT_PATH$input_path" 32858 fi 32859 fi 32860 32861 32862 if test "x$path" != "x$new_path"; then 32863 libpath="$new_path" 32864 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting libpath to \"$new_path\"" >&5 32865 $as_echo "$as_me: Rewriting libpath to \"$new_path\"" >&6;} 32866 fi 32867 32868 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 32869 32870 path="$libpath" 32871 has_colon=`$ECHO $path | $GREP ^.:` 32872 new_path="$path" 32873 if test "x$has_colon" = x; then 32874 # Not in mixed or Windows style, start by that. 32875 new_path=`cmd //c echo $path` 32876 fi 32877 32878 32879 input_path="$new_path" 32880 # Check if we need to convert this using DOS-style short mode. If the path 32881 # contains just simple characters, use it. Otherwise (spaces, weird characters), 32882 # take no chances and rewrite it. 32883 # Note: m4 eats our [], so we need to use [ and ] instead. 32884 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 32885 if test "x$has_forbidden_chars" != x; then 32886 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 32887 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 32888 fi 32889 32890 32891 windows_path="$new_path" 32892 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 32893 unix_path=`$CYGPATH -u "$windows_path"` 32894 new_path="$unix_path" 32895 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 32896 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 32897 new_path="$unix_path" 32898 fi 32899 32900 if test "x$path" != "x$new_path"; then 32901 libpath="$new_path" 32902 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting libpath to \"$new_path\"" >&5 32903 $as_echo "$as_me: Rewriting libpath to \"$new_path\"" >&6;} 32904 fi 32905 32906 # Save the first 10 bytes of this path to the storage, so fixpath can work. 32907 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 32908 32909 else 32910 # We're on a unix platform. Hooray! :) 32911 path="$libpath" 32912 has_space=`$ECHO "$path" | $GREP " "` 32913 if test "x$has_space" != x; then 32914 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of libpath, which resolves as \"$path\", is invalid." >&5 32915 $as_echo "$as_me: The path of libpath, which resolves as \"$path\", is invalid." >&6;} 32916 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 32917 fi 32918 32919 # Use eval to expand a potential ~ 32920 eval path="$path" 32921 if test ! -f "$path" && test ! -d "$path"; then 32922 as_fn_error $? "The path of libpath, which resolves as \"$path\", is not found." "$LINENO" 5 32923 fi 32924 32925 if test -d "$path"; then 32926 libpath="`cd "$path"; $THEPWDCMD -L`" 32927 else 32928 dir="`$DIRNAME "$path"`" 32929 base="`$BASENAME "$path"`" 32930 libpath="`cd "$dir"; $THEPWDCMD -L`/$base" 32931 fi 32932 fi 32933 fi 32934 32935 SYSROOT_LDFLAGS="$SYSROOT_LDFLAGS -libpath:$libpath" 32936 fi 32937 IFS=";" 32938 fi 32939 done 32940 IFS="$OLDIFS" 32941 fi 32942 else 32943 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 32944 $as_echo "not found" >&6; } 32945 32946 if test "x$VS_ENV_CMD" = x; then 32947 { $as_echo "$as_me:${as_lineno-$LINENO}: Cannot locate a valid Visual Studio or Windows SDK installation on disk," >&5 32948 $as_echo "$as_me: Cannot locate a valid Visual Studio or Windows SDK installation on disk," >&6;} 32949 { $as_echo "$as_me:${as_lineno-$LINENO}: nor is this script run from a Visual Studio command prompt." >&5 32950 $as_echo "$as_me: nor is this script run from a Visual Studio command prompt." >&6;} 32951 else 32952 { $as_echo "$as_me:${as_lineno-$LINENO}: Running the extraction script failed." >&5 32953 $as_echo "$as_me: Running the extraction script failed." >&6;} 32954 fi 32955 { $as_echo "$as_me:${as_lineno-$LINENO}: Try setting --with-tools-dir to the VC/bin directory within the VS installation" >&5 32956 $as_echo "$as_me: Try setting --with-tools-dir to the VC/bin directory within the VS installation" >&6;} 32957 { $as_echo "$as_me:${as_lineno-$LINENO}: or run \"bash.exe -l\" from a VS command prompt and then run configure from there." >&5 32958 $as_echo "$as_me: or run \"bash.exe -l\" from a VS command prompt and then run configure from there." >&6;} 32959 as_fn_error $? "Cannot continue" "$LINENO" 5 32960 fi 32961 32962 # Reset path to VS_PATH. It will include everything that was on PATH at the time we 32963 # ran TOOLCHAIN_SETUP_VISUAL_STUDIO_ENV. 32964 PATH="$VS_PATH" 32965 # The microsoft toolchain also requires INCLUDE and LIB to be set. 32966 export INCLUDE="$VS_INCLUDE" 32967 export LIB="$VS_LIB" 32968 else 32969 if test "x$XCODE_VERSION_OUTPUT" != x; then 32970 # For Xcode, we set the Xcode version as TOOLCHAIN_VERSION 32971 TOOLCHAIN_VERSION=`$ECHO $XCODE_VERSION_OUTPUT | $CUT -f 2 -d ' '` 32972 TOOLCHAIN_DESCRIPTION="$TOOLCHAIN_DESCRIPTION from Xcode" 32973 else 32974 # Currently we do not define this for other toolchains. This might change as the need arise. 32975 TOOLCHAIN_VERSION= 32976 fi 32977 fi 32978 32979 32980 # Finally add TOOLCHAIN_PATH at the beginning, to allow --with-tools-dir to 32981 # override all other locations. 32982 if test "x$TOOLCHAIN_PATH" != x; then 32983 PATH=$TOOLCHAIN_PATH:$PATH 32984 fi 32985 32986 32987 # 32988 # Setup the compilers (CC and CXX) 32989 # 32990 32991 COMPILER_NAME=C 32992 SEARCH_LIST="$TOOLCHAIN_CC_BINARY" 32993 32994 if test "x$CC" != x; then 32995 # User has supplied compiler name already, always let that override. 32996 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied compiler CC=$CC" >&5 32997 $as_echo "$as_me: Will use user supplied compiler CC=$CC" >&6;} 32998 if test "x`basename $CC`" = "x$CC"; then 32999 # A command without a complete path is provided, search $PATH. 33000 33001 for ac_prog in $CC 33002 do 33003 # Extract the first word of "$ac_prog", so it can be a program name with args. 33004 set dummy $ac_prog; ac_word=$2 33005 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 33006 $as_echo_n "checking for $ac_word... " >&6; } 33007 if ${ac_cv_path_POTENTIAL_CC+:} false; then : 33008 $as_echo_n "(cached) " >&6 33009 else 33010 case $POTENTIAL_CC in 33011 [\\/]* | ?:[\\/]*) 33012 ac_cv_path_POTENTIAL_CC="$POTENTIAL_CC" # Let the user override the test with a path. 33013 ;; 33014 *) 33015 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 33016 for as_dir in $PATH 33017 do 33018 IFS=$as_save_IFS 33019 test -z "$as_dir" && as_dir=. 33020 for ac_exec_ext in '' $ac_executable_extensions; do 33021 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 33022 ac_cv_path_POTENTIAL_CC="$as_dir/$ac_word$ac_exec_ext" 33023 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 33024 break 2 33025 fi 33026 done 33027 done 33028 IFS=$as_save_IFS 33029 33030 ;; 33031 esac 33032 fi 33033 POTENTIAL_CC=$ac_cv_path_POTENTIAL_CC 33034 if test -n "$POTENTIAL_CC"; then 33035 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $POTENTIAL_CC" >&5 33036 $as_echo "$POTENTIAL_CC" >&6; } 33037 else 33038 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 33039 $as_echo "no" >&6; } 33040 fi 33041 33042 33043 test -n "$POTENTIAL_CC" && break 33044 done 33045 33046 if test "x$POTENTIAL_CC" != x; then 33047 CC=$POTENTIAL_CC 33048 else 33049 as_fn_error $? "User supplied compiler CC=$CC could not be found" "$LINENO" 5 33050 fi 33051 else 33052 # Otherwise it might already be a complete path 33053 if test ! -x "$CC"; then 33054 as_fn_error $? "User supplied compiler CC=$CC does not exist" "$LINENO" 5 33055 fi 33056 fi 33057 else 33058 # No user supplied value. Locate compiler ourselves. 33059 33060 # If we are cross compiling, assume cross compilation tools follows the 33061 # cross compilation standard where they are prefixed with the autoconf 33062 # standard name for the target. For example the binary 33063 # i686-sun-solaris2.10-gcc will cross compile for i686-sun-solaris2.10. 33064 # If we are not cross compiling, then the default compiler name will be 33065 # used. 33066 33067 CC= 33068 # If TOOLCHAIN_PATH is set, check for all compiler names in there first 33069 # before checking the rest of the PATH. 33070 # FIXME: Now that we prefix the TOOLS_DIR to the PATH in the PRE_DETECTION 33071 # step, this should not be necessary. 33072 if test -n "$TOOLCHAIN_PATH"; then 33073 PATH_save="$PATH" 33074 PATH="$TOOLCHAIN_PATH" 33075 for ac_prog in $SEARCH_LIST 33076 do 33077 # Extract the first word of "$ac_prog", so it can be a program name with args. 33078 set dummy $ac_prog; ac_word=$2 33079 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 33080 $as_echo_n "checking for $ac_word... " >&6; } 33081 if ${ac_cv_path_TOOLCHAIN_PATH_CC+:} false; then : 33082 $as_echo_n "(cached) " >&6 33083 else 33084 case $TOOLCHAIN_PATH_CC in 33085 [\\/]* | ?:[\\/]*) 33086 ac_cv_path_TOOLCHAIN_PATH_CC="$TOOLCHAIN_PATH_CC" # Let the user override the test with a path. 33087 ;; 33088 *) 33089 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 33090 for as_dir in $PATH 33091 do 33092 IFS=$as_save_IFS 33093 test -z "$as_dir" && as_dir=. 33094 for ac_exec_ext in '' $ac_executable_extensions; do 33095 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 33096 ac_cv_path_TOOLCHAIN_PATH_CC="$as_dir/$ac_word$ac_exec_ext" 33097 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 33098 break 2 33099 fi 33100 done 33101 done 33102 IFS=$as_save_IFS 33103 33104 ;; 33105 esac 33106 fi 33107 TOOLCHAIN_PATH_CC=$ac_cv_path_TOOLCHAIN_PATH_CC 33108 if test -n "$TOOLCHAIN_PATH_CC"; then 33109 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $TOOLCHAIN_PATH_CC" >&5 33110 $as_echo "$TOOLCHAIN_PATH_CC" >&6; } 33111 else 33112 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 33113 $as_echo "no" >&6; } 33114 fi 33115 33116 33117 test -n "$TOOLCHAIN_PATH_CC" && break 33118 done 33119 33120 CC=$TOOLCHAIN_PATH_CC 33121 PATH="$PATH_save" 33122 fi 33123 33124 # AC_PATH_PROGS can't be run multiple times with the same variable, 33125 # so create a new name for this run. 33126 if test "x$CC" = x; then 33127 for ac_prog in $SEARCH_LIST 33128 do 33129 # Extract the first word of "$ac_prog", so it can be a program name with args. 33130 set dummy $ac_prog; ac_word=$2 33131 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 33132 $as_echo_n "checking for $ac_word... " >&6; } 33133 if ${ac_cv_path_POTENTIAL_CC+:} false; then : 33134 $as_echo_n "(cached) " >&6 33135 else 33136 case $POTENTIAL_CC in 33137 [\\/]* | ?:[\\/]*) 33138 ac_cv_path_POTENTIAL_CC="$POTENTIAL_CC" # Let the user override the test with a path. 33139 ;; 33140 *) 33141 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 33142 for as_dir in $PATH 33143 do 33144 IFS=$as_save_IFS 33145 test -z "$as_dir" && as_dir=. 33146 for ac_exec_ext in '' $ac_executable_extensions; do 33147 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 33148 ac_cv_path_POTENTIAL_CC="$as_dir/$ac_word$ac_exec_ext" 33149 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 33150 break 2 33151 fi 33152 done 33153 done 33154 IFS=$as_save_IFS 33155 33156 ;; 33157 esac 33158 fi 33159 POTENTIAL_CC=$ac_cv_path_POTENTIAL_CC 33160 if test -n "$POTENTIAL_CC"; then 33161 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $POTENTIAL_CC" >&5 33162 $as_echo "$POTENTIAL_CC" >&6; } 33163 else 33164 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 33165 $as_echo "no" >&6; } 33166 fi 33167 33168 33169 test -n "$POTENTIAL_CC" && break 33170 done 33171 33172 CC=$POTENTIAL_CC 33173 fi 33174 33175 if test "x$CC" = x; then 33176 33177 # Print a helpful message on how to acquire the necessary build dependency. 33178 # devkit is the help tag: freetype, cups, alsa etc 33179 MISSING_DEPENDENCY=devkit 33180 33181 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 33182 cygwin_help $MISSING_DEPENDENCY 33183 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 33184 msys_help $MISSING_DEPENDENCY 33185 else 33186 PKGHANDLER_COMMAND= 33187 33188 case $PKGHANDLER in 33189 apt-get) 33190 apt_help $MISSING_DEPENDENCY ;; 33191 yum) 33192 yum_help $MISSING_DEPENDENCY ;; 33193 port) 33194 port_help $MISSING_DEPENDENCY ;; 33195 pkgutil) 33196 pkgutil_help $MISSING_DEPENDENCY ;; 33197 pkgadd) 33198 pkgadd_help $MISSING_DEPENDENCY ;; 33199 esac 33200 33201 if test "x$PKGHANDLER_COMMAND" != x; then 33202 HELP_MSG="You might be able to fix this by running '$PKGHANDLER_COMMAND'." 33203 fi 33204 fi 33205 33206 as_fn_error $? "Could not find a $COMPILER_NAME compiler. $HELP_MSG" "$LINENO" 5 33207 fi 33208 fi 33209 33210 # Now we have a compiler binary in CC. Make sure it's okay. 33211 33212 # Only process if variable expands to non-empty 33213 33214 if test "x$CC" != x; then 33215 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 33216 33217 # First separate the path from the arguments. This will split at the first 33218 # space. 33219 complete="$CC" 33220 path="${complete%% *}" 33221 tmp="$complete EOL" 33222 arguments="${tmp#* }" 33223 33224 # Input might be given as Windows format, start by converting to 33225 # unix format. 33226 new_path=`$CYGPATH -u "$path"` 33227 33228 # Now try to locate executable using which 33229 new_path=`$WHICH "$new_path" 2> /dev/null` 33230 # bat and cmd files are not always considered executable in cygwin causing which 33231 # to not find them 33232 if test "x$new_path" = x \ 33233 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 33234 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 33235 new_path=`$CYGPATH -u "$path"` 33236 fi 33237 if test "x$new_path" = x; then 33238 # Oops. Which didn't find the executable. 33239 # The splitting of arguments from the executable at a space might have been incorrect, 33240 # since paths with space are more likely in Windows. Give it another try with the whole 33241 # argument. 33242 path="$complete" 33243 arguments="EOL" 33244 new_path=`$CYGPATH -u "$path"` 33245 new_path=`$WHICH "$new_path" 2> /dev/null` 33246 # bat and cmd files are not always considered executable in cygwin causing which 33247 # to not find them 33248 if test "x$new_path" = x \ 33249 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 33250 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 33251 new_path=`$CYGPATH -u "$path"` 33252 fi 33253 if test "x$new_path" = x; then 33254 # It's still not found. Now this is an unrecoverable error. 33255 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of CC, which resolves as \"$complete\", is not found." >&5 33256 $as_echo "$as_me: The path of CC, which resolves as \"$complete\", is not found." >&6;} 33257 has_space=`$ECHO "$complete" | $GREP " "` 33258 if test "x$has_space" != x; then 33259 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 33260 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 33261 fi 33262 as_fn_error $? "Cannot locate the the path of CC" "$LINENO" 5 33263 fi 33264 fi 33265 33266 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 33267 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 33268 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 33269 # "foo.exe" is OK but "foo" is an error. 33270 # 33271 # This test is therefore slightly more accurate than "test -f" to check for file presence. 33272 # It is also a way to make sure we got the proper file name for the real test later on. 33273 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 33274 if test "x$test_shortpath" = x; then 33275 # Short path failed, file does not exist as specified. 33276 # Try adding .exe or .cmd 33277 if test -f "${new_path}.exe"; then 33278 input_to_shortpath="${new_path}.exe" 33279 elif test -f "${new_path}.cmd"; then 33280 input_to_shortpath="${new_path}.cmd" 33281 else 33282 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of CC, which resolves as \"$new_path\", is invalid." >&5 33283 $as_echo "$as_me: The path of CC, which resolves as \"$new_path\", is invalid." >&6;} 33284 { $as_echo "$as_me:${as_lineno-$LINENO}: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&5 33285 $as_echo "$as_me: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&6;} 33286 as_fn_error $? "Cannot locate the the path of CC" "$LINENO" 5 33287 fi 33288 else 33289 input_to_shortpath="$new_path" 33290 fi 33291 33292 # Call helper function which possibly converts this using DOS-style short mode. 33293 # If so, the updated path is stored in $new_path. 33294 new_path="$input_to_shortpath" 33295 33296 input_path="$input_to_shortpath" 33297 # Check if we need to convert this using DOS-style short mode. If the path 33298 # contains just simple characters, use it. Otherwise (spaces, weird characters), 33299 # take no chances and rewrite it. 33300 # Note: m4 eats our [], so we need to use [ and ] instead. 33301 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 33302 if test "x$has_forbidden_chars" != x; then 33303 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 33304 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 33305 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 33306 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 33307 # Going to short mode and back again did indeed matter. Since short mode is 33308 # case insensitive, let's make it lowercase to improve readability. 33309 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 33310 # Now convert it back to Unix-style (cygpath) 33311 input_path=`$CYGPATH -u "$shortmode_path"` 33312 new_path="$input_path" 33313 fi 33314 fi 33315 33316 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 33317 if test "x$test_cygdrive_prefix" = x; then 33318 # As a simple fix, exclude /usr/bin since it's not a real path. 33319 if test "x`$ECHO $input_to_shortpath | $GREP ^/usr/bin/`" = x; then 33320 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 33321 # a path prefixed by /cygdrive for fixpath to work. 33322 new_path="$CYGWIN_ROOT_PATH$input_path" 33323 fi 33324 fi 33325 33326 # remove trailing .exe if any 33327 new_path="${new_path/%.exe/}" 33328 33329 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 33330 33331 # First separate the path from the arguments. This will split at the first 33332 # space. 33333 complete="$CC" 33334 path="${complete%% *}" 33335 tmp="$complete EOL" 33336 arguments="${tmp#* }" 33337 33338 # Input might be given as Windows format, start by converting to 33339 # unix format. 33340 new_path="$path" 33341 33342 windows_path="$new_path" 33343 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 33344 unix_path=`$CYGPATH -u "$windows_path"` 33345 new_path="$unix_path" 33346 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 33347 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 33348 new_path="$unix_path" 33349 fi 33350 33351 33352 # Now try to locate executable using which 33353 new_path=`$WHICH "$new_path" 2> /dev/null` 33354 33355 if test "x$new_path" = x; then 33356 # Oops. Which didn't find the executable. 33357 # The splitting of arguments from the executable at a space might have been incorrect, 33358 # since paths with space are more likely in Windows. Give it another try with the whole 33359 # argument. 33360 path="$complete" 33361 arguments="EOL" 33362 new_path="$path" 33363 33364 windows_path="$new_path" 33365 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 33366 unix_path=`$CYGPATH -u "$windows_path"` 33367 new_path="$unix_path" 33368 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 33369 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 33370 new_path="$unix_path" 33371 fi 33372 33373 33374 new_path=`$WHICH "$new_path" 2> /dev/null` 33375 # bat and cmd files are not always considered executable in MSYS causing which 33376 # to not find them 33377 if test "x$new_path" = x \ 33378 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 33379 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 33380 new_path="$path" 33381 33382 windows_path="$new_path" 33383 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 33384 unix_path=`$CYGPATH -u "$windows_path"` 33385 new_path="$unix_path" 33386 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 33387 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 33388 new_path="$unix_path" 33389 fi 33390 33391 fi 33392 33393 if test "x$new_path" = x; then 33394 # It's still not found. Now this is an unrecoverable error. 33395 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of CC, which resolves as \"$complete\", is not found." >&5 33396 $as_echo "$as_me: The path of CC, which resolves as \"$complete\", is not found." >&6;} 33397 has_space=`$ECHO "$complete" | $GREP " "` 33398 if test "x$has_space" != x; then 33399 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 33400 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 33401 fi 33402 as_fn_error $? "Cannot locate the the path of CC" "$LINENO" 5 33403 fi 33404 fi 33405 33406 # Now new_path has a complete unix path to the binary 33407 if test "x`$ECHO $new_path | $GREP ^/bin/`" != x; then 33408 # Keep paths in /bin as-is, but remove trailing .exe if any 33409 new_path="${new_path/%.exe/}" 33410 # Do not save /bin paths to all_fixpath_prefixes! 33411 else 33412 # Not in mixed or Windows style, start by that. 33413 new_path=`cmd //c echo $new_path` 33414 33415 input_path="$new_path" 33416 # Check if we need to convert this using DOS-style short mode. If the path 33417 # contains just simple characters, use it. Otherwise (spaces, weird characters), 33418 # take no chances and rewrite it. 33419 # Note: m4 eats our [], so we need to use [ and ] instead. 33420 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 33421 if test "x$has_forbidden_chars" != x; then 33422 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 33423 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 33424 fi 33425 33426 # Output is in $new_path 33427 33428 windows_path="$new_path" 33429 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 33430 unix_path=`$CYGPATH -u "$windows_path"` 33431 new_path="$unix_path" 33432 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 33433 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 33434 new_path="$unix_path" 33435 fi 33436 33437 # remove trailing .exe if any 33438 new_path="${new_path/%.exe/}" 33439 33440 # Save the first 10 bytes of this path to the storage, so fixpath can work. 33441 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 33442 fi 33443 33444 else 33445 # We're on a unix platform. Hooray! :) 33446 # First separate the path from the arguments. This will split at the first 33447 # space. 33448 complete="$CC" 33449 path="${complete%% *}" 33450 tmp="$complete EOL" 33451 arguments="${tmp#* }" 33452 33453 # Cannot rely on the command "which" here since it doesn't always work. 33454 is_absolute_path=`$ECHO "$path" | $GREP ^/` 33455 if test -z "$is_absolute_path"; then 33456 # Path to executable is not absolute. Find it. 33457 IFS_save="$IFS" 33458 IFS=: 33459 for p in $PATH; do 33460 if test -f "$p/$path" && test -x "$p/$path"; then 33461 new_path="$p/$path" 33462 break 33463 fi 33464 done 33465 IFS="$IFS_save" 33466 else 33467 # This is an absolute path, we can use it without further modifications. 33468 new_path="$path" 33469 fi 33470 33471 if test "x$new_path" = x; then 33472 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of CC, which resolves as \"$complete\", is not found." >&5 33473 $as_echo "$as_me: The path of CC, which resolves as \"$complete\", is not found." >&6;} 33474 has_space=`$ECHO "$complete" | $GREP " "` 33475 if test "x$has_space" != x; then 33476 { $as_echo "$as_me:${as_lineno-$LINENO}: This might be caused by spaces in the path, which is not allowed." >&5 33477 $as_echo "$as_me: This might be caused by spaces in the path, which is not allowed." >&6;} 33478 fi 33479 as_fn_error $? "Cannot locate the the path of CC" "$LINENO" 5 33480 fi 33481 fi 33482 33483 # Now join together the path and the arguments once again 33484 if test "x$arguments" != xEOL; then 33485 new_complete="$new_path ${arguments% *}" 33486 else 33487 new_complete="$new_path" 33488 fi 33489 33490 if test "x$complete" != "x$new_complete"; then 33491 CC="$new_complete" 33492 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting CC to \"$new_complete\"" >&5 33493 $as_echo "$as_me: Rewriting CC to \"$new_complete\"" >&6;} 33494 fi 33495 fi 33496 33497 TEST_COMPILER="$CC" 33498 33499 { $as_echo "$as_me:${as_lineno-$LINENO}: checking resolved symbolic links for CC" >&5 33500 $as_echo_n "checking resolved symbolic links for CC... " >&6; } 33501 SYMLINK_ORIGINAL="$TEST_COMPILER" 33502 33503 if test "x$OPENJDK_BUILD_OS" != xwindows; then 33504 # Follow a chain of symbolic links. Use readlink 33505 # where it exists, else fall back to horribly 33506 # complicated shell code. 33507 if test "x$READLINK_TESTED" != yes; then 33508 # On MacOSX there is a readlink tool with a different 33509 # purpose than the GNU readlink tool. Check the found readlink. 33510 ISGNU=`$READLINK --version 2>&1 | $GREP GNU` 33511 if test "x$ISGNU" = x; then 33512 # A readlink that we do not know how to use. 33513 # Are there other non-GNU readlinks out there? 33514 READLINK_TESTED=yes 33515 READLINK= 33516 fi 33517 fi 33518 33519 if test "x$READLINK" != x; then 33520 SYMLINK_ORIGINAL=`$READLINK -f $SYMLINK_ORIGINAL` 33521 else 33522 # Save the current directory for restoring afterwards 33523 STARTDIR=$PWD 33524 COUNTER=0 33525 sym_link_dir=`$DIRNAME $SYMLINK_ORIGINAL` 33526 sym_link_file=`$BASENAME $SYMLINK_ORIGINAL` 33527 cd $sym_link_dir 33528 # Use -P flag to resolve symlinks in directories. 33529 cd `$THEPWDCMD -P` 33530 sym_link_dir=`$THEPWDCMD -P` 33531 # Resolve file symlinks 33532 while test $COUNTER -lt 20; do 33533 ISLINK=`$LS -l $sym_link_dir/$sym_link_file | $GREP '\->' | $SED -e 's/.*-> \(.*\)/\1/'` 33534 if test "x$ISLINK" == x; then 33535 # This is not a symbolic link! We are done! 33536 break 33537 fi 33538 # Again resolve directory symlinks since the target of the just found 33539 # link could be in a different directory 33540 cd `$DIRNAME $ISLINK` 33541 sym_link_dir=`$THEPWDCMD -P` 33542 sym_link_file=`$BASENAME $ISLINK` 33543 let COUNTER=COUNTER+1 33544 done 33545 cd $STARTDIR 33546 SYMLINK_ORIGINAL=$sym_link_dir/$sym_link_file 33547 fi 33548 fi 33549 33550 if test "x$TEST_COMPILER" = "x$SYMLINK_ORIGINAL"; then 33551 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no symlink" >&5 33552 $as_echo "no symlink" >&6; } 33553 else 33554 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $SYMLINK_ORIGINAL" >&5 33555 $as_echo "$SYMLINK_ORIGINAL" >&6; } 33556 33557 # We can't handle ccache by gcc wrappers, since we need to know if we're 33558 # using ccache. Instead ccache usage must be controlled by a configure option. 33559 COMPILER_BASENAME=`$BASENAME "$SYMLINK_ORIGINAL"` 33560 if test "x$COMPILER_BASENAME" = "xccache"; then 33561 { $as_echo "$as_me:${as_lineno-$LINENO}: Please use --enable-ccache instead of providing a wrapped compiler." >&5 33562 $as_echo "$as_me: Please use --enable-ccache instead of providing a wrapped compiler." >&6;} 33563 as_fn_error $? "$TEST_COMPILER is a symbolic link to ccache. This is not supported." "$LINENO" 5 33564 fi 33565 fi 33566 33567 33568 COMPILER=$CC 33569 COMPILER_NAME=$COMPILER_NAME 33570 33571 if test "x$TOOLCHAIN_TYPE" = xsolstudio; then 33572 # cc -V output typically looks like 33573 # cc: Sun C 5.12 Linux_i386 2011/11/16 33574 COMPILER_VERSION_OUTPUT=`$COMPILER -V 2>&1` 33575 # Check that this is likely to be the Solaris Studio cc. 33576 $ECHO "$COMPILER_VERSION_OUTPUT" | $GREP "^.*: Sun $COMPILER_NAME" > /dev/null 33577 if test $? -ne 0; then 33578 ALT_VERSION_OUTPUT=`$COMPILER --version 2>&1` 33579 { $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 33580 $as_echo "$as_me: The $COMPILER_NAME compiler (located as $COMPILER) does not seem to be the required $TOOLCHAIN_TYPE compiler." >&6;} 33581 { $as_echo "$as_me:${as_lineno-$LINENO}: The result from running with -V was: \"$COMPILER_VERSION_OUTPUT\"" >&5 33582 $as_echo "$as_me: The result from running with -V was: \"$COMPILER_VERSION_OUTPUT\"" >&6;} 33583 { $as_echo "$as_me:${as_lineno-$LINENO}: The result from running with --version was: \"$ALT_VERSION_OUTPUT\"" >&5 33584 $as_echo "$as_me: The result from running with --version was: \"$ALT_VERSION_OUTPUT\"" >&6;} 33585 as_fn_error $? "A $TOOLCHAIN_TYPE compiler is required. Try setting --with-tools-dir." "$LINENO" 5 33586 fi 33587 # Remove usage instructions (if present), and 33588 # collapse compiler output into a single line 33589 COMPILER_VERSION_STRING=`$ECHO $COMPILER_VERSION_OUTPUT | \ 33590 $SED -e 's/ *[Uu]sage:.*//'` 33591 COMPILER_VERSION_NUMBER=`$ECHO $COMPILER_VERSION_OUTPUT | \ 33592 $SED -e "s/^.*[ ,\t]$COMPILER_NAME[ ,\t]\([1-9]\.[0-9][0-9]*\).*/\1/"` 33593 elif test "x$TOOLCHAIN_TYPE" = xxlc; then 33594 # xlc -qversion output typically looks like 33595 # IBM XL C/C++ for AIX, V11.1 (5724-X13) 33596 # Version: 11.01.0000.0015 33597 COMPILER_VERSION_OUTPUT=`$COMPILER -qversion 2>&1` 33598 # Check that this is likely to be the IBM XL C compiler. 33599 $ECHO "$COMPILER_VERSION_OUTPUT" | $GREP "IBM XL C" > /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 -qversion was: \"$COMPILER_VERSION_OUTPUT\"" >&5 33605 $as_echo "$as_me: The result from running with -qversion 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 # Collapse compiler output into a single line 33611 COMPILER_VERSION_STRING=`$ECHO $COMPILER_VERSION_OUTPUT` 33612 COMPILER_VERSION_NUMBER=`$ECHO $COMPILER_VERSION_OUTPUT | \ 33613 $SED -e 's/^.*, V\([1-9][0-9.]*\).*$/\1/'` 33614 elif test "x$TOOLCHAIN_TYPE" = xmicrosoft; then 33615 # There is no specific version flag, but all output starts with a version string. 33616 # First line typically looks something like: 33617 # Microsoft (R) 32-bit C/C++ Optimizing Compiler Version 16.00.40219.01 for 80x86 33618 COMPILER_VERSION_OUTPUT=`$COMPILER 2>&1 | $HEAD -n 1 | $TR -d '\r'` 33619 # Check that this is likely to be Microsoft CL.EXE. 33620 $ECHO "$COMPILER_VERSION_OUTPUT" | $GREP "Microsoft.*Compiler" > /dev/null 33621 if test $? -ne 0; then 33622 { $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 33623 $as_echo "$as_me: The $COMPILER_NAME compiler (located as $COMPILER) does not seem to be the required $TOOLCHAIN_TYPE compiler." >&6;} 33624 { $as_echo "$as_me:${as_lineno-$LINENO}: The result from running it was: \"$COMPILER_VERSION_OUTPUT\"" >&5 33625 $as_echo "$as_me: The result from running it was: \"$COMPILER_VERSION_OUTPUT\"" >&6;} 33626 as_fn_error $? "A $TOOLCHAIN_TYPE compiler is required. Try setting --with-tools-dir." "$LINENO" 5 33627 fi 33628 # Collapse compiler output into a single line 33629 COMPILER_VERSION_STRING=`$ECHO $COMPILER_VERSION_OUTPUT` 33630 COMPILER_VERSION_NUMBER=`$ECHO $COMPILER_VERSION_OUTPUT | \ 33631 $SED -e 's/^.*ersion.\([1-9][0-9.]*\) .*$/\1/'` 33632 elif test "x$TOOLCHAIN_TYPE" = xgcc; then 33633 # gcc --version output typically looks like 33634 # gcc (Ubuntu/Linaro 4.8.1-10ubuntu9) 4.8.1 33635 # Copyright (C) 2013 Free Software Foundation, Inc. 33636 # This is free software; see the source for copying conditions. There is NO 33637 # warranty; not even for MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. 33638 COMPILER_VERSION_OUTPUT=`$COMPILER --version 2>&1` 33639 # Check that this is likely to be GCC. 33640 $ECHO "$COMPILER_VERSION_OUTPUT" | $GREP "Free Software Foundation" > /dev/null 33641 if test $? -ne 0; then 33642 { $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 33643 $as_echo "$as_me: The $COMPILER_NAME compiler (located as $COMPILER) does not seem to be the required $TOOLCHAIN_TYPE compiler." >&6;} 33644 { $as_echo "$as_me:${as_lineno-$LINENO}: The result from running with --version was: \"$COMPILER_VERSION\"" >&5 33645 $as_echo "$as_me: The result from running with --version was: \"$COMPILER_VERSION\"" >&6;} 33646 as_fn_error $? "A $TOOLCHAIN_TYPE compiler is required. Try setting --with-tools-dir." "$LINENO" 5 33647 fi 33648 # Remove Copyright and legalese from version string, and 33649 # collapse into a single line 33650 COMPILER_VERSION_STRING=`$ECHO $COMPILER_VERSION_OUTPUT | \ 33651 $SED -e 's/ *Copyright .*//'` 33652 COMPILER_VERSION_NUMBER=`$ECHO $COMPILER_VERSION_OUTPUT | \ 33653 $SED -e 's/^.* \([1-9]\.[0-9.]*\)[^0-9.].*$/\1/'` 33654 elif test "x$TOOLCHAIN_TYPE" = xclang; then 33655 # clang --version output typically looks like 33656 # Apple LLVM version 5.0 (clang-500.2.79) (based on LLVM 3.3svn) 33657 # clang version 3.3 (tags/RELEASE_33/final) 33658 # or 33659 # Debian clang version 3.2-7ubuntu1 (tags/RELEASE_32/final) (based on LLVM 3.2) 33660 # Target: x86_64-pc-linux-gnu 33661 # Thread model: posix 33662 COMPILER_VERSION_OUTPUT=`$COMPILER --version 2>&1` 33663 # Check that this is likely to be clang 33664 $ECHO "$COMPILER_VERSION_OUTPUT" | $GREP "clang" > /dev/null 33665 if test $? -ne 0; then 33666 { $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 33667 $as_echo "$as_me: The $COMPILER_NAME compiler (located as $COMPILER) does not seem to be the required $TOOLCHAIN_TYPE compiler." >&6;} 33668 { $as_echo "$as_me:${as_lineno-$LINENO}: The result from running with --version was: \"$COMPILER_VERSION_OUTPUT\"" >&5 33669 $as_echo "$as_me: The result from running with --version was: \"$COMPILER_VERSION_OUTPUT\"" >&6;} 33670 as_fn_error $? "A $TOOLCHAIN_TYPE compiler is required. Try setting --with-tools-dir." "$LINENO" 5 33671 fi 33672 # Collapse compiler output into a single line 33673 COMPILER_VERSION_STRING=`$ECHO $COMPILER_VERSION_OUTPUT` 33674 COMPILER_VERSION_NUMBER=`$ECHO $COMPILER_VERSION_OUTPUT | \ 33675 $SED -e 's/^.* version \([1-9][0-9.]*\).*$/\1/'` 33676 else 33677 as_fn_error $? "Unknown toolchain type $TOOLCHAIN_TYPE." "$LINENO" 5 33678 fi 33679 # This sets CC_VERSION_NUMBER or CXX_VERSION_NUMBER. (This comment is a grep marker) 33680 CC_VERSION_NUMBER="$COMPILER_VERSION_NUMBER" 33681 # This sets CC_VERSION_STRING or CXX_VERSION_STRING. (This comment is a grep marker) 33682 CC_VERSION_STRING="$COMPILER_VERSION_STRING" 33683 33684 { $as_echo "$as_me:${as_lineno-$LINENO}: Using $TOOLCHAIN_TYPE $COMPILER_NAME compiler version $COMPILER_VERSION_NUMBER [$COMPILER_VERSION_STRING]" >&5 33685 $as_echo "$as_me: Using $TOOLCHAIN_TYPE $COMPILER_NAME compiler version $COMPILER_VERSION_NUMBER [$COMPILER_VERSION_STRING]" >&6;} 33686 33687 33688 # Now that we have resolved CC ourself, let autoconf have its go at it 33689 ac_ext=c 33690 ac_cpp='$CPP $CPPFLAGS' 33691 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5' 33692 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' 33693 ac_compiler_gnu=$ac_cv_c_compiler_gnu 33694 if test -n "$ac_tool_prefix"; then 33695 for ac_prog in $CC 33696 do 33697 # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args. 33698 set dummy $ac_tool_prefix$ac_prog; ac_word=$2 33699 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 33700 $as_echo_n "checking for $ac_word... " >&6; } 33701 if ${ac_cv_prog_CC+:} false; then : 33702 $as_echo_n "(cached) " >&6 33703 else 33704 if test -n "$CC"; then 33705 ac_cv_prog_CC="$CC" # Let the user override the test. 33706 else 33707 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 33708 for as_dir in $PATH 33709 do 33710 IFS=$as_save_IFS 33711 test -z "$as_dir" && as_dir=. 33712 for ac_exec_ext in '' $ac_executable_extensions; do 33713 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 33714 ac_cv_prog_CC="$ac_tool_prefix$ac_prog" 33715 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 33716 break 2 33717 fi 33718 done 33719 done 33720 IFS=$as_save_IFS 33721 33722 fi 33723 fi 33724 CC=$ac_cv_prog_CC 33725 if test -n "$CC"; then 33726 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CC" >&5 33727 $as_echo "$CC" >&6; } 33728 else 33729 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 33730 $as_echo "no" >&6; } 33731 fi 33732 33733 33734 test -n "$CC" && break 33735 done 33736 fi 33737 if test -z "$CC"; then 33738 ac_ct_CC=$CC 33739 for ac_prog in $CC 33740 do 33741 # Extract the first word of "$ac_prog", so it can be a program name with args. 33742 set dummy $ac_prog; ac_word=$2 33743 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 33744 $as_echo_n "checking for $ac_word... " >&6; } 33745 if ${ac_cv_prog_ac_ct_CC+:} false; then : 33746 $as_echo_n "(cached) " >&6 33747 else 33748 if test -n "$ac_ct_CC"; then 33749 ac_cv_prog_ac_ct_CC="$ac_ct_CC" # Let the user override the test. 33750 else 33751 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 33752 for as_dir in $PATH 33753 do 33754 IFS=$as_save_IFS 33755 test -z "$as_dir" && as_dir=. 33756 for ac_exec_ext in '' $ac_executable_extensions; do 33757 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 33758 ac_cv_prog_ac_ct_CC="$ac_prog" 33759 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 33760 break 2 33761 fi 33762 done 33763 done 33764 IFS=$as_save_IFS 33765 33766 fi 33767 fi 33768 ac_ct_CC=$ac_cv_prog_ac_ct_CC 33769 if test -n "$ac_ct_CC"; then 33770 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_CC" >&5 33771 $as_echo "$ac_ct_CC" >&6; } 33772 else 33773 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 33774 $as_echo "no" >&6; } 33775 fi 33776 33777 33778 test -n "$ac_ct_CC" && break 33779 done 33780 33781 if test "x$ac_ct_CC" = x; then 33782 CC="" 33783 else 33784 case $cross_compiling:$ac_tool_warned in 33785 yes:) 33786 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5 33787 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;} 33788 ac_tool_warned=yes ;; 33789 esac 33790 CC=$ac_ct_CC 33791 fi 33792 fi 33793 33794 33795 test -z "$CC" && { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 33796 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;} 33797 as_fn_error $? "no acceptable C compiler found in \$PATH 33798 See \`config.log' for more details" "$LINENO" 5; } 33799 33800 # Provide some information about the compiler. 33801 $as_echo "$as_me:${as_lineno-$LINENO}: checking for C compiler version" >&5 33802 set X $ac_compile 33803 ac_compiler=$2 33804 for ac_option in --version -v -V -qversion; do 33805 { { ac_try="$ac_compiler $ac_option >&5" 33806 case "(($ac_try" in 33807 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; 33808 *) ac_try_echo=$ac_try;; 33809 esac 33810 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\"" 33811 $as_echo "$ac_try_echo"; } >&5 33812 (eval "$ac_compiler $ac_option >&5") 2>conftest.err 33813 ac_status=$? 33814 if test -s conftest.err; then 33815 sed '10a\ 33816 ... rest of stderr output deleted ... 33817 10q' conftest.err >conftest.er1 33818 cat conftest.er1 >&5 33819 fi 33820 rm -f conftest.er1 conftest.err 33821 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 33822 test $ac_status = 0; } 33823 done 33824 33825 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 33826 /* end confdefs.h. */ 33827 33828 int 33829 main () 33830 { 33831 33832 ; 33833 return 0; 33834 } 33835 _ACEOF 33836 ac_clean_files_save=$ac_clean_files 33837 ac_clean_files="$ac_clean_files a.out a.out.dSYM a.exe b.out" 33838 # Try to create an executable without -o first, disregard a.out. 33839 # It will help us diagnose broken compilers, and finding out an intuition 33840 # of exeext. 33841 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether the C compiler works" >&5 33842 $as_echo_n "checking whether the C compiler works... " >&6; } 33843 ac_link_default=`$as_echo "$ac_link" | sed 's/ -o *conftest[^ ]*//'` 33844 33845 # The possible output files: 33846 ac_files="a.out conftest.exe conftest a.exe a_out.exe b.out conftest.*" 33847 33848 ac_rmfiles= 33849 for ac_file in $ac_files 33850 do 33851 case $ac_file in 33852 *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.dSYM | *.o | *.obj ) ;; 33853 * ) ac_rmfiles="$ac_rmfiles $ac_file";; 33854 esac 33855 done 33856 rm -f $ac_rmfiles 33857 33858 if { { ac_try="$ac_link_default" 33859 case "(($ac_try" in 33860 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; 33861 *) ac_try_echo=$ac_try;; 33862 esac 33863 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\"" 33864 $as_echo "$ac_try_echo"; } >&5 33865 (eval "$ac_link_default") 2>&5 33866 ac_status=$? 33867 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 33868 test $ac_status = 0; }; then : 33869 # Autoconf-2.13 could set the ac_cv_exeext variable to `no'. 33870 # So ignore a value of `no', otherwise this would lead to `EXEEXT = no' 33871 # in a Makefile. We should not override ac_cv_exeext if it was cached, 33872 # so that the user can short-circuit this test for compilers unknown to 33873 # Autoconf. 33874 for ac_file in $ac_files '' 33875 do 33876 test -f "$ac_file" || continue 33877 case $ac_file in 33878 *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.dSYM | *.o | *.obj ) 33879 ;; 33880 [ab].out ) 33881 # We found the default executable, but exeext='' is most 33882 # certainly right. 33883 break;; 33884 *.* ) 33885 if test "${ac_cv_exeext+set}" = set && test "$ac_cv_exeext" != no; 33886 then :; else 33887 ac_cv_exeext=`expr "$ac_file" : '[^.]*\(\..*\)'` 33888 fi 33889 # We set ac_cv_exeext here because the later test for it is not 33890 # safe: cross compilers may not add the suffix if given an `-o' 33891 # argument, so we may need to know it at that point already. 33892 # Even if this section looks crufty: it has the advantage of 33893 # actually working. 33894 break;; 33895 * ) 33896 break;; 33897 esac 33898 done 33899 test "$ac_cv_exeext" = no && ac_cv_exeext= 33900 33901 else 33902 ac_file='' 33903 fi 33904 if test -z "$ac_file"; then : 33905 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 33906 $as_echo "no" >&6; } 33907 $as_echo "$as_me: failed program was:" >&5 33908 sed 's/^/| /' conftest.$ac_ext >&5 33909 33910 { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 33911 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;} 33912 as_fn_error 77 "C compiler cannot create executables 33913 See \`config.log' for more details" "$LINENO" 5; } 33914 else 33915 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 33916 $as_echo "yes" >&6; } 33917 fi 33918 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for C compiler default output file name" >&5 33919 $as_echo_n "checking for C compiler default output file name... " >&6; } 33920 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_file" >&5 33921 $as_echo "$ac_file" >&6; } 33922 ac_exeext=$ac_cv_exeext 33923 33924 rm -f -r a.out a.out.dSYM a.exe conftest$ac_cv_exeext b.out 33925 ac_clean_files=$ac_clean_files_save 33926 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for suffix of executables" >&5 33927 $as_echo_n "checking for suffix of executables... " >&6; } 33928 if { { ac_try="$ac_link" 33929 case "(($ac_try" in 33930 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; 33931 *) ac_try_echo=$ac_try;; 33932 esac 33933 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\"" 33934 $as_echo "$ac_try_echo"; } >&5 33935 (eval "$ac_link") 2>&5 33936 ac_status=$? 33937 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 33938 test $ac_status = 0; }; then : 33939 # If both `conftest.exe' and `conftest' are `present' (well, observable) 33940 # catch `conftest.exe'. For instance with Cygwin, `ls conftest' will 33941 # work properly (i.e., refer to `conftest.exe'), while it won't with 33942 # `rm'. 33943 for ac_file in conftest.exe conftest conftest.*; do 33944 test -f "$ac_file" || continue 33945 case $ac_file in 33946 *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.dSYM | *.o | *.obj ) ;; 33947 *.* ) ac_cv_exeext=`expr "$ac_file" : '[^.]*\(\..*\)'` 33948 break;; 33949 * ) break;; 33950 esac 33951 done 33952 else 33953 { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 33954 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;} 33955 as_fn_error $? "cannot compute suffix of executables: cannot compile and link 33956 See \`config.log' for more details" "$LINENO" 5; } 33957 fi 33958 rm -f conftest conftest$ac_cv_exeext 33959 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_exeext" >&5 33960 $as_echo "$ac_cv_exeext" >&6; } 33961 33962 rm -f conftest.$ac_ext 33963 EXEEXT=$ac_cv_exeext 33964 ac_exeext=$EXEEXT 33965 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 33966 /* end confdefs.h. */ 33967 #include <stdio.h> 33968 int 33969 main () 33970 { 33971 FILE *f = fopen ("conftest.out", "w"); 33972 return ferror (f) || fclose (f) != 0; 33973 33974 ; 33975 return 0; 33976 } 33977 _ACEOF 33978 ac_clean_files="$ac_clean_files conftest.out" 33979 # Check that the compiler produces executables we can run. If not, either 33980 # the compiler is broken, or we cross compile. 33981 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether we are cross compiling" >&5 33982 $as_echo_n "checking whether we are cross compiling... " >&6; } 33983 if test "$cross_compiling" != yes; then 33984 { { ac_try="$ac_link" 33985 case "(($ac_try" in 33986 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; 33987 *) ac_try_echo=$ac_try;; 33988 esac 33989 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\"" 33990 $as_echo "$ac_try_echo"; } >&5 33991 (eval "$ac_link") 2>&5 33992 ac_status=$? 33993 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 33994 test $ac_status = 0; } 33995 if { ac_try='./conftest$ac_cv_exeext' 33996 { { case "(($ac_try" in 33997 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; 33998 *) ac_try_echo=$ac_try;; 33999 esac 34000 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\"" 34001 $as_echo "$ac_try_echo"; } >&5 34002 (eval "$ac_try") 2>&5 34003 ac_status=$? 34004 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 34005 test $ac_status = 0; }; }; then 34006 cross_compiling=no 34007 else 34008 if test "$cross_compiling" = maybe; then 34009 cross_compiling=yes 34010 else 34011 { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 34012 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;} 34013 as_fn_error $? "cannot run C compiled programs. 34014 If you meant to cross compile, use \`--host'. 34015 See \`config.log' for more details" "$LINENO" 5; } 34016 fi 34017 fi 34018 fi 34019 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $cross_compiling" >&5 34020 $as_echo "$cross_compiling" >&6; } 34021 34022 rm -f conftest.$ac_ext conftest$ac_cv_exeext conftest.out 34023 ac_clean_files=$ac_clean_files_save 34024 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for suffix of object files" >&5 34025 $as_echo_n "checking for suffix of object files... " >&6; } 34026 if ${ac_cv_objext+:} false; then : 34027 $as_echo_n "(cached) " >&6 34028 else 34029 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 34030 /* end confdefs.h. */ 34031 34032 int 34033 main () 34034 { 34035 34036 ; 34037 return 0; 34038 } 34039 _ACEOF 34040 rm -f conftest.o conftest.obj 34041 if { { ac_try="$ac_compile" 34042 case "(($ac_try" in 34043 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; 34044 *) ac_try_echo=$ac_try;; 34045 esac 34046 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\"" 34047 $as_echo "$ac_try_echo"; } >&5 34048 (eval "$ac_compile") 2>&5 34049 ac_status=$? 34050 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 34051 test $ac_status = 0; }; then : 34052 for ac_file in conftest.o conftest.obj conftest.*; do 34053 test -f "$ac_file" || continue; 34054 case $ac_file in 34055 *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.dSYM ) ;; 34056 *) ac_cv_objext=`expr "$ac_file" : '.*\.\(.*\)'` 34057 break;; 34058 esac 34059 done 34060 else 34061 $as_echo "$as_me: failed program was:" >&5 34062 sed 's/^/| /' conftest.$ac_ext >&5 34063 34064 { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 34065 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;} 34066 as_fn_error $? "cannot compute suffix of object files: cannot compile 34067 See \`config.log' for more details" "$LINENO" 5; } 34068 fi 34069 rm -f conftest.$ac_cv_objext conftest.$ac_ext 34070 fi 34071 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_objext" >&5 34072 $as_echo "$ac_cv_objext" >&6; } 34073 OBJEXT=$ac_cv_objext 34074 ac_objext=$OBJEXT 34075 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether we are using the GNU C compiler" >&5 34076 $as_echo_n "checking whether we are using the GNU C compiler... " >&6; } 34077 if ${ac_cv_c_compiler_gnu+:} false; then : 34078 $as_echo_n "(cached) " >&6 34079 else 34080 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 34081 /* end confdefs.h. */ 34082 34083 int 34084 main () 34085 { 34086 #ifndef __GNUC__ 34087 choke me 34088 #endif 34089 34090 ; 34091 return 0; 34092 } 34093 _ACEOF 34094 if ac_fn_c_try_compile "$LINENO"; then : 34095 ac_compiler_gnu=yes 34096 else 34097 ac_compiler_gnu=no 34098 fi 34099 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext 34100 ac_cv_c_compiler_gnu=$ac_compiler_gnu 34101 34102 fi 34103 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_c_compiler_gnu" >&5 34104 $as_echo "$ac_cv_c_compiler_gnu" >&6; } 34105 if test $ac_compiler_gnu = yes; then 34106 GCC=yes 34107 else 34108 GCC= 34109 fi 34110 ac_test_CFLAGS=${CFLAGS+set} 34111 ac_save_CFLAGS=$CFLAGS 34112 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $CC accepts -g" >&5 34113 $as_echo_n "checking whether $CC accepts -g... " >&6; } 34114 if ${ac_cv_prog_cc_g+:} false; then : 34115 $as_echo_n "(cached) " >&6 34116 else 34117 ac_save_c_werror_flag=$ac_c_werror_flag 34118 ac_c_werror_flag=yes 34119 ac_cv_prog_cc_g=no 34120 CFLAGS="-g" 34121 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 34122 /* end confdefs.h. */ 34123 34124 int 34125 main () 34126 { 34127 34128 ; 34129 return 0; 34130 } 34131 _ACEOF 34132 if ac_fn_c_try_compile "$LINENO"; then : 34133 ac_cv_prog_cc_g=yes 34134 else 34135 CFLAGS="" 34136 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 34137 /* end confdefs.h. */ 34138 34139 int 34140 main () 34141 { 34142 34143 ; 34144 return 0; 34145 } 34146 _ACEOF 34147 if ac_fn_c_try_compile "$LINENO"; then : 34148 34149 else 34150 ac_c_werror_flag=$ac_save_c_werror_flag 34151 CFLAGS="-g" 34152 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 34153 /* end confdefs.h. */ 34154 34155 int 34156 main () 34157 { 34158 34159 ; 34160 return 0; 34161 } 34162 _ACEOF 34163 if ac_fn_c_try_compile "$LINENO"; then : 34164 ac_cv_prog_cc_g=yes 34165 fi 34166 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext 34167 fi 34168 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext 34169 fi 34170 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext 34171 ac_c_werror_flag=$ac_save_c_werror_flag 34172 fi 34173 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_prog_cc_g" >&5 34174 $as_echo "$ac_cv_prog_cc_g" >&6; } 34175 if test "$ac_test_CFLAGS" = set; then 34176 CFLAGS=$ac_save_CFLAGS 34177 elif test $ac_cv_prog_cc_g = yes; then 34178 if test "$GCC" = yes; then 34179 CFLAGS="-g -O2" 34180 else 34181 CFLAGS="-g" 34182 fi 34183 else 34184 if test "$GCC" = yes; then 34185 CFLAGS="-O2" 34186 else 34187 CFLAGS= 34188 fi 34189 fi 34190 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $CC option to accept ISO C89" >&5 34191 $as_echo_n "checking for $CC option to accept ISO C89... " >&6; } 34192 if ${ac_cv_prog_cc_c89+:} false; then : 34193 $as_echo_n "(cached) " >&6 34194 else 34195 ac_cv_prog_cc_c89=no 34196 ac_save_CC=$CC 34197 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 34198 /* end confdefs.h. */ 34199 #include <stdarg.h> 34200 #include <stdio.h> 34201 struct stat; 34202 /* Most of the following tests are stolen from RCS 5.7's src/conf.sh. */ 34203 struct buf { int x; }; 34204 FILE * (*rcsopen) (struct buf *, struct stat *, int); 34205 static char *e (p, i) 34206 char **p; 34207 int i; 34208 { 34209 return p[i]; 34210 } 34211 static char *f (char * (*g) (char **, int), char **p, ...) 34212 { 34213 char *s; 34214 va_list v; 34215 va_start (v,p); 34216 s = g (p, va_arg (v,int)); 34217 va_end (v); 34218 return s; 34219 } 34220 34221 /* OSF 4.0 Compaq cc is some sort of almost-ANSI by default. It has 34222 function prototypes and stuff, but not '\xHH' hex character constants. 34223 These don't provoke an error unfortunately, instead are silently treated 34224 as 'x'. The following induces an error, until -std is added to get 34225 proper ANSI mode. Curiously '\x00'!='x' always comes out true, for an 34226 array size at least. It's necessary to write '\x00'==0 to get something 34227 that's true only with -std. */ 34228 int osf4_cc_array ['\x00' == 0 ? 1 : -1]; 34229 34230 /* IBM C 6 for AIX is almost-ANSI by default, but it replaces macro parameters 34231 inside strings and character constants. */ 34232 #define FOO(x) 'x' 34233 int xlc6_cc_array[FOO(a) == 'x' ? 1 : -1]; 34234 34235 int test (int i, double x); 34236 struct s1 {int (*f) (int a);}; 34237 struct s2 {int (*f) (double a);}; 34238 int pairnames (int, char **, FILE *(*)(struct buf *, struct stat *, int), int, int); 34239 int argc; 34240 char **argv; 34241 int 34242 main () 34243 { 34244 return f (e, argv, 0) != argv[0] || f (e, argv, 1) != argv[1]; 34245 ; 34246 return 0; 34247 } 34248 _ACEOF 34249 for ac_arg in '' -qlanglvl=extc89 -qlanglvl=ansi -std \ 34250 -Ae "-Aa -D_HPUX_SOURCE" "-Xc -D__EXTENSIONS__" 34251 do 34252 CC="$ac_save_CC $ac_arg" 34253 if ac_fn_c_try_compile "$LINENO"; then : 34254 ac_cv_prog_cc_c89=$ac_arg 34255 fi 34256 rm -f core conftest.err conftest.$ac_objext 34257 test "x$ac_cv_prog_cc_c89" != "xno" && break 34258 done 34259 rm -f conftest.$ac_ext 34260 CC=$ac_save_CC 34261 34262 fi 34263 # AC_CACHE_VAL 34264 case "x$ac_cv_prog_cc_c89" in 34265 x) 34266 { $as_echo "$as_me:${as_lineno-$LINENO}: result: none needed" >&5 34267 $as_echo "none needed" >&6; } ;; 34268 xno) 34269 { $as_echo "$as_me:${as_lineno-$LINENO}: result: unsupported" >&5 34270 $as_echo "unsupported" >&6; } ;; 34271 *) 34272 CC="$CC $ac_cv_prog_cc_c89" 34273 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_prog_cc_c89" >&5 34274 $as_echo "$ac_cv_prog_cc_c89" >&6; } ;; 34275 esac 34276 if test "x$ac_cv_prog_cc_c89" != xno; then : 34277 34278 fi 34279 34280 ac_ext=cpp 34281 ac_cpp='$CXXCPP $CPPFLAGS' 34282 ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5' 34283 ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' 34284 ac_compiler_gnu=$ac_cv_cxx_compiler_gnu 34285 34286 34287 34288 COMPILER_NAME=C++ 34289 SEARCH_LIST="$TOOLCHAIN_CXX_BINARY" 34290 34291 if test "x$CXX" != x; then 34292 # User has supplied compiler name already, always let that override. 34293 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied compiler CXX=$CXX" >&5 34294 $as_echo "$as_me: Will use user supplied compiler CXX=$CXX" >&6;} 34295 if test "x`basename $CXX`" = "x$CXX"; then 34296 # A command without a complete path is provided, search $PATH. 34297 34298 for ac_prog in $CXX 34299 do 34300 # Extract the first word of "$ac_prog", so it can be a program name with args. 34301 set dummy $ac_prog; ac_word=$2 34302 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 34303 $as_echo_n "checking for $ac_word... " >&6; } 34304 if ${ac_cv_path_POTENTIAL_CXX+:} false; then : 34305 $as_echo_n "(cached) " >&6 34306 else 34307 case $POTENTIAL_CXX in 34308 [\\/]* | ?:[\\/]*) 34309 ac_cv_path_POTENTIAL_CXX="$POTENTIAL_CXX" # Let the user override the test with a path. 34310 ;; 34311 *) 34312 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 34313 for as_dir in $PATH 34314 do 34315 IFS=$as_save_IFS 34316 test -z "$as_dir" && as_dir=. 34317 for ac_exec_ext in '' $ac_executable_extensions; do 34318 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 34319 ac_cv_path_POTENTIAL_CXX="$as_dir/$ac_word$ac_exec_ext" 34320 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 34321 break 2 34322 fi 34323 done 34324 done 34325 IFS=$as_save_IFS 34326 34327 ;; 34328 esac 34329 fi 34330 POTENTIAL_CXX=$ac_cv_path_POTENTIAL_CXX 34331 if test -n "$POTENTIAL_CXX"; then 34332 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $POTENTIAL_CXX" >&5 34333 $as_echo "$POTENTIAL_CXX" >&6; } 34334 else 34335 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 34336 $as_echo "no" >&6; } 34337 fi 34338 34339 34340 test -n "$POTENTIAL_CXX" && break 34341 done 34342 34343 if test "x$POTENTIAL_CXX" != x; then 34344 CXX=$POTENTIAL_CXX 34345 else 34346 as_fn_error $? "User supplied compiler CXX=$CXX could not be found" "$LINENO" 5 34347 fi 34348 else 34349 # Otherwise it might already be a complete path 34350 if test ! -x "$CXX"; then 34351 as_fn_error $? "User supplied compiler CXX=$CXX does not exist" "$LINENO" 5 34352 fi 34353 fi 34354 else 34355 # No user supplied value. Locate compiler ourselves. 34356 34357 # If we are cross compiling, assume cross compilation tools follows the 34358 # cross compilation standard where they are prefixed with the autoconf 34359 # standard name for the target. For example the binary 34360 # i686-sun-solaris2.10-gcc will cross compile for i686-sun-solaris2.10. 34361 # If we are not cross compiling, then the default compiler name will be 34362 # used. 34363 34364 CXX= 34365 # If TOOLCHAIN_PATH is set, check for all compiler names in there first 34366 # before checking the rest of the PATH. 34367 # FIXME: Now that we prefix the TOOLS_DIR to the PATH in the PRE_DETECTION 34368 # step, this should not be necessary. 34369 if test -n "$TOOLCHAIN_PATH"; then 34370 PATH_save="$PATH" 34371 PATH="$TOOLCHAIN_PATH" 34372 for ac_prog in $SEARCH_LIST 34373 do 34374 # Extract the first word of "$ac_prog", so it can be a program name with args. 34375 set dummy $ac_prog; ac_word=$2 34376 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 34377 $as_echo_n "checking for $ac_word... " >&6; } 34378 if ${ac_cv_path_TOOLCHAIN_PATH_CXX+:} false; then : 34379 $as_echo_n "(cached) " >&6 34380 else 34381 case $TOOLCHAIN_PATH_CXX in 34382 [\\/]* | ?:[\\/]*) 34383 ac_cv_path_TOOLCHAIN_PATH_CXX="$TOOLCHAIN_PATH_CXX" # Let the user override the test with a path. 34384 ;; 34385 *) 34386 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 34387 for as_dir in $PATH 34388 do 34389 IFS=$as_save_IFS 34390 test -z "$as_dir" && as_dir=. 34391 for ac_exec_ext in '' $ac_executable_extensions; do 34392 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 34393 ac_cv_path_TOOLCHAIN_PATH_CXX="$as_dir/$ac_word$ac_exec_ext" 34394 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 34395 break 2 34396 fi 34397 done 34398 done 34399 IFS=$as_save_IFS 34400 34401 ;; 34402 esac 34403 fi 34404 TOOLCHAIN_PATH_CXX=$ac_cv_path_TOOLCHAIN_PATH_CXX 34405 if test -n "$TOOLCHAIN_PATH_CXX"; then 34406 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $TOOLCHAIN_PATH_CXX" >&5 34407 $as_echo "$TOOLCHAIN_PATH_CXX" >&6; } 34408 else 34409 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 34410 $as_echo "no" >&6; } 34411 fi 34412 34413 34414 test -n "$TOOLCHAIN_PATH_CXX" && break 34415 done 34416 34417 CXX=$TOOLCHAIN_PATH_CXX 34418 PATH="$PATH_save" 34419 fi 34420 34421 # AC_PATH_PROGS can't be run multiple times with the same variable, 34422 # so create a new name for this run. 34423 if test "x$CXX" = x; then 34424 for ac_prog in $SEARCH_LIST 34425 do 34426 # Extract the first word of "$ac_prog", so it can be a program name with args. 34427 set dummy $ac_prog; ac_word=$2 34428 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 34429 $as_echo_n "checking for $ac_word... " >&6; } 34430 if ${ac_cv_path_POTENTIAL_CXX+:} false; then : 34431 $as_echo_n "(cached) " >&6 34432 else 34433 case $POTENTIAL_CXX in 34434 [\\/]* | ?:[\\/]*) 34435 ac_cv_path_POTENTIAL_CXX="$POTENTIAL_CXX" # Let the user override the test with a path. 34436 ;; 34437 *) 34438 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 34439 for as_dir in $PATH 34440 do 34441 IFS=$as_save_IFS 34442 test -z "$as_dir" && as_dir=. 34443 for ac_exec_ext in '' $ac_executable_extensions; do 34444 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 34445 ac_cv_path_POTENTIAL_CXX="$as_dir/$ac_word$ac_exec_ext" 34446 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 34447 break 2 34448 fi 34449 done 34450 done 34451 IFS=$as_save_IFS 34452 34453 ;; 34454 esac 34455 fi 34456 POTENTIAL_CXX=$ac_cv_path_POTENTIAL_CXX 34457 if test -n "$POTENTIAL_CXX"; then 34458 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $POTENTIAL_CXX" >&5 34459 $as_echo "$POTENTIAL_CXX" >&6; } 34460 else 34461 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 34462 $as_echo "no" >&6; } 34463 fi 34464 34465 34466 test -n "$POTENTIAL_CXX" && break 34467 done 34468 34469 CXX=$POTENTIAL_CXX 34470 fi 34471 34472 if test "x$CXX" = x; then 34473 34474 # Print a helpful message on how to acquire the necessary build dependency. 34475 # devkit is the help tag: freetype, cups, alsa etc 34476 MISSING_DEPENDENCY=devkit 34477 34478 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 34479 cygwin_help $MISSING_DEPENDENCY 34480 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 34481 msys_help $MISSING_DEPENDENCY 34482 else 34483 PKGHANDLER_COMMAND= 34484 34485 case $PKGHANDLER in 34486 apt-get) 34487 apt_help $MISSING_DEPENDENCY ;; 34488 yum) 34489 yum_help $MISSING_DEPENDENCY ;; 34490 port) 34491 port_help $MISSING_DEPENDENCY ;; 34492 pkgutil) 34493 pkgutil_help $MISSING_DEPENDENCY ;; 34494 pkgadd) 34495 pkgadd_help $MISSING_DEPENDENCY ;; 34496 esac 34497 34498 if test "x$PKGHANDLER_COMMAND" != x; then 34499 HELP_MSG="You might be able to fix this by running '$PKGHANDLER_COMMAND'." 34500 fi 34501 fi 34502 34503 as_fn_error $? "Could not find a $COMPILER_NAME compiler. $HELP_MSG" "$LINENO" 5 34504 fi 34505 fi 34506 34507 # Now we have a compiler binary in CXX. Make sure it's okay. 34508 34509 # Only process if variable expands to non-empty 34510 34511 if test "x$CXX" != x; then 34512 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 34513 34514 # First separate the path from the arguments. This will split at the first 34515 # space. 34516 complete="$CXX" 34517 path="${complete%% *}" 34518 tmp="$complete EOL" 34519 arguments="${tmp#* }" 34520 34521 # Input might be given as Windows format, start by converting to 34522 # unix format. 34523 new_path=`$CYGPATH -u "$path"` 34524 34525 # Now try to locate executable using which 34526 new_path=`$WHICH "$new_path" 2> /dev/null` 34527 # bat and cmd files are not always considered executable in cygwin causing which 34528 # to not find them 34529 if test "x$new_path" = x \ 34530 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 34531 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 34532 new_path=`$CYGPATH -u "$path"` 34533 fi 34534 if test "x$new_path" = x; then 34535 # Oops. Which didn't find the executable. 34536 # The splitting of arguments from the executable at a space might have been incorrect, 34537 # since paths with space are more likely in Windows. Give it another try with the whole 34538 # argument. 34539 path="$complete" 34540 arguments="EOL" 34541 new_path=`$CYGPATH -u "$path"` 34542 new_path=`$WHICH "$new_path" 2> /dev/null` 34543 # bat and cmd files are not always considered executable in cygwin causing which 34544 # to not find them 34545 if test "x$new_path" = x \ 34546 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 34547 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 34548 new_path=`$CYGPATH -u "$path"` 34549 fi 34550 if test "x$new_path" = x; then 34551 # It's still not found. Now this is an unrecoverable error. 34552 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of CXX, which resolves as \"$complete\", is not found." >&5 34553 $as_echo "$as_me: The path of CXX, which resolves as \"$complete\", is not found." >&6;} 34554 has_space=`$ECHO "$complete" | $GREP " "` 34555 if test "x$has_space" != x; then 34556 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 34557 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 34558 fi 34559 as_fn_error $? "Cannot locate the the path of CXX" "$LINENO" 5 34560 fi 34561 fi 34562 34563 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 34564 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 34565 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 34566 # "foo.exe" is OK but "foo" is an error. 34567 # 34568 # This test is therefore slightly more accurate than "test -f" to check for file presence. 34569 # It is also a way to make sure we got the proper file name for the real test later on. 34570 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 34571 if test "x$test_shortpath" = x; then 34572 # Short path failed, file does not exist as specified. 34573 # Try adding .exe or .cmd 34574 if test -f "${new_path}.exe"; then 34575 input_to_shortpath="${new_path}.exe" 34576 elif test -f "${new_path}.cmd"; then 34577 input_to_shortpath="${new_path}.cmd" 34578 else 34579 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of CXX, which resolves as \"$new_path\", is invalid." >&5 34580 $as_echo "$as_me: The path of CXX, which resolves as \"$new_path\", is invalid." >&6;} 34581 { $as_echo "$as_me:${as_lineno-$LINENO}: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&5 34582 $as_echo "$as_me: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&6;} 34583 as_fn_error $? "Cannot locate the the path of CXX" "$LINENO" 5 34584 fi 34585 else 34586 input_to_shortpath="$new_path" 34587 fi 34588 34589 # Call helper function which possibly converts this using DOS-style short mode. 34590 # If so, the updated path is stored in $new_path. 34591 new_path="$input_to_shortpath" 34592 34593 input_path="$input_to_shortpath" 34594 # Check if we need to convert this using DOS-style short mode. If the path 34595 # contains just simple characters, use it. Otherwise (spaces, weird characters), 34596 # take no chances and rewrite it. 34597 # Note: m4 eats our [], so we need to use [ and ] instead. 34598 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 34599 if test "x$has_forbidden_chars" != x; then 34600 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 34601 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 34602 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 34603 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 34604 # Going to short mode and back again did indeed matter. Since short mode is 34605 # case insensitive, let's make it lowercase to improve readability. 34606 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 34607 # Now convert it back to Unix-style (cygpath) 34608 input_path=`$CYGPATH -u "$shortmode_path"` 34609 new_path="$input_path" 34610 fi 34611 fi 34612 34613 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 34614 if test "x$test_cygdrive_prefix" = x; then 34615 # As a simple fix, exclude /usr/bin since it's not a real path. 34616 if test "x`$ECHO $input_to_shortpath | $GREP ^/usr/bin/`" = x; then 34617 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 34618 # a path prefixed by /cygdrive for fixpath to work. 34619 new_path="$CYGWIN_ROOT_PATH$input_path" 34620 fi 34621 fi 34622 34623 # remove trailing .exe if any 34624 new_path="${new_path/%.exe/}" 34625 34626 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 34627 34628 # First separate the path from the arguments. This will split at the first 34629 # space. 34630 complete="$CXX" 34631 path="${complete%% *}" 34632 tmp="$complete EOL" 34633 arguments="${tmp#* }" 34634 34635 # Input might be given as Windows format, start by converting to 34636 # unix format. 34637 new_path="$path" 34638 34639 windows_path="$new_path" 34640 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 34641 unix_path=`$CYGPATH -u "$windows_path"` 34642 new_path="$unix_path" 34643 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 34644 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 34645 new_path="$unix_path" 34646 fi 34647 34648 34649 # Now try to locate executable using which 34650 new_path=`$WHICH "$new_path" 2> /dev/null` 34651 34652 if test "x$new_path" = x; then 34653 # Oops. Which didn't find the executable. 34654 # The splitting of arguments from the executable at a space might have been incorrect, 34655 # since paths with space are more likely in Windows. Give it another try with the whole 34656 # argument. 34657 path="$complete" 34658 arguments="EOL" 34659 new_path="$path" 34660 34661 windows_path="$new_path" 34662 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 34663 unix_path=`$CYGPATH -u "$windows_path"` 34664 new_path="$unix_path" 34665 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 34666 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 34667 new_path="$unix_path" 34668 fi 34669 34670 34671 new_path=`$WHICH "$new_path" 2> /dev/null` 34672 # bat and cmd files are not always considered executable in MSYS causing which 34673 # to not find them 34674 if test "x$new_path" = x \ 34675 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 34676 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 34677 new_path="$path" 34678 34679 windows_path="$new_path" 34680 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 34681 unix_path=`$CYGPATH -u "$windows_path"` 34682 new_path="$unix_path" 34683 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 34684 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 34685 new_path="$unix_path" 34686 fi 34687 34688 fi 34689 34690 if test "x$new_path" = x; then 34691 # It's still not found. Now this is an unrecoverable error. 34692 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of CXX, which resolves as \"$complete\", is not found." >&5 34693 $as_echo "$as_me: The path of CXX, which resolves as \"$complete\", is not found." >&6;} 34694 has_space=`$ECHO "$complete" | $GREP " "` 34695 if test "x$has_space" != x; then 34696 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 34697 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 34698 fi 34699 as_fn_error $? "Cannot locate the the path of CXX" "$LINENO" 5 34700 fi 34701 fi 34702 34703 # Now new_path has a complete unix path to the binary 34704 if test "x`$ECHO $new_path | $GREP ^/bin/`" != x; then 34705 # Keep paths in /bin as-is, but remove trailing .exe if any 34706 new_path="${new_path/%.exe/}" 34707 # Do not save /bin paths to all_fixpath_prefixes! 34708 else 34709 # Not in mixed or Windows style, start by that. 34710 new_path=`cmd //c echo $new_path` 34711 34712 input_path="$new_path" 34713 # Check if we need to convert this using DOS-style short mode. If the path 34714 # contains just simple characters, use it. Otherwise (spaces, weird characters), 34715 # take no chances and rewrite it. 34716 # Note: m4 eats our [], so we need to use [ and ] instead. 34717 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 34718 if test "x$has_forbidden_chars" != x; then 34719 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 34720 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 34721 fi 34722 34723 # Output is in $new_path 34724 34725 windows_path="$new_path" 34726 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 34727 unix_path=`$CYGPATH -u "$windows_path"` 34728 new_path="$unix_path" 34729 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 34730 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 34731 new_path="$unix_path" 34732 fi 34733 34734 # remove trailing .exe if any 34735 new_path="${new_path/%.exe/}" 34736 34737 # Save the first 10 bytes of this path to the storage, so fixpath can work. 34738 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 34739 fi 34740 34741 else 34742 # We're on a unix platform. Hooray! :) 34743 # First separate the path from the arguments. This will split at the first 34744 # space. 34745 complete="$CXX" 34746 path="${complete%% *}" 34747 tmp="$complete EOL" 34748 arguments="${tmp#* }" 34749 34750 # Cannot rely on the command "which" here since it doesn't always work. 34751 is_absolute_path=`$ECHO "$path" | $GREP ^/` 34752 if test -z "$is_absolute_path"; then 34753 # Path to executable is not absolute. Find it. 34754 IFS_save="$IFS" 34755 IFS=: 34756 for p in $PATH; do 34757 if test -f "$p/$path" && test -x "$p/$path"; then 34758 new_path="$p/$path" 34759 break 34760 fi 34761 done 34762 IFS="$IFS_save" 34763 else 34764 # This is an absolute path, we can use it without further modifications. 34765 new_path="$path" 34766 fi 34767 34768 if test "x$new_path" = x; then 34769 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of CXX, which resolves as \"$complete\", is not found." >&5 34770 $as_echo "$as_me: The path of CXX, which resolves as \"$complete\", is not found." >&6;} 34771 has_space=`$ECHO "$complete" | $GREP " "` 34772 if test "x$has_space" != x; then 34773 { $as_echo "$as_me:${as_lineno-$LINENO}: This might be caused by spaces in the path, which is not allowed." >&5 34774 $as_echo "$as_me: This might be caused by spaces in the path, which is not allowed." >&6;} 34775 fi 34776 as_fn_error $? "Cannot locate the the path of CXX" "$LINENO" 5 34777 fi 34778 fi 34779 34780 # Now join together the path and the arguments once again 34781 if test "x$arguments" != xEOL; then 34782 new_complete="$new_path ${arguments% *}" 34783 else 34784 new_complete="$new_path" 34785 fi 34786 34787 if test "x$complete" != "x$new_complete"; then 34788 CXX="$new_complete" 34789 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting CXX to \"$new_complete\"" >&5 34790 $as_echo "$as_me: Rewriting CXX to \"$new_complete\"" >&6;} 34791 fi 34792 fi 34793 34794 TEST_COMPILER="$CXX" 34795 34796 { $as_echo "$as_me:${as_lineno-$LINENO}: checking resolved symbolic links for CXX" >&5 34797 $as_echo_n "checking resolved symbolic links for CXX... " >&6; } 34798 SYMLINK_ORIGINAL="$TEST_COMPILER" 34799 34800 if test "x$OPENJDK_BUILD_OS" != xwindows; then 34801 # Follow a chain of symbolic links. Use readlink 34802 # where it exists, else fall back to horribly 34803 # complicated shell code. 34804 if test "x$READLINK_TESTED" != yes; then 34805 # On MacOSX there is a readlink tool with a different 34806 # purpose than the GNU readlink tool. Check the found readlink. 34807 ISGNU=`$READLINK --version 2>&1 | $GREP GNU` 34808 if test "x$ISGNU" = x; then 34809 # A readlink that we do not know how to use. 34810 # Are there other non-GNU readlinks out there? 34811 READLINK_TESTED=yes 34812 READLINK= 34813 fi 34814 fi 34815 34816 if test "x$READLINK" != x; then 34817 SYMLINK_ORIGINAL=`$READLINK -f $SYMLINK_ORIGINAL` 34818 else 34819 # Save the current directory for restoring afterwards 34820 STARTDIR=$PWD 34821 COUNTER=0 34822 sym_link_dir=`$DIRNAME $SYMLINK_ORIGINAL` 34823 sym_link_file=`$BASENAME $SYMLINK_ORIGINAL` 34824 cd $sym_link_dir 34825 # Use -P flag to resolve symlinks in directories. 34826 cd `$THEPWDCMD -P` 34827 sym_link_dir=`$THEPWDCMD -P` 34828 # Resolve file symlinks 34829 while test $COUNTER -lt 20; do 34830 ISLINK=`$LS -l $sym_link_dir/$sym_link_file | $GREP '\->' | $SED -e 's/.*-> \(.*\)/\1/'` 34831 if test "x$ISLINK" == x; then 34832 # This is not a symbolic link! We are done! 34833 break 34834 fi 34835 # Again resolve directory symlinks since the target of the just found 34836 # link could be in a different directory 34837 cd `$DIRNAME $ISLINK` 34838 sym_link_dir=`$THEPWDCMD -P` 34839 sym_link_file=`$BASENAME $ISLINK` 34840 let COUNTER=COUNTER+1 34841 done 34842 cd $STARTDIR 34843 SYMLINK_ORIGINAL=$sym_link_dir/$sym_link_file 34844 fi 34845 fi 34846 34847 if test "x$TEST_COMPILER" = "x$SYMLINK_ORIGINAL"; then 34848 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no symlink" >&5 34849 $as_echo "no symlink" >&6; } 34850 else 34851 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $SYMLINK_ORIGINAL" >&5 34852 $as_echo "$SYMLINK_ORIGINAL" >&6; } 34853 34854 # We can't handle ccache by gcc wrappers, since we need to know if we're 34855 # using ccache. Instead ccache usage must be controlled by a configure option. 34856 COMPILER_BASENAME=`$BASENAME "$SYMLINK_ORIGINAL"` 34857 if test "x$COMPILER_BASENAME" = "xccache"; then 34858 { $as_echo "$as_me:${as_lineno-$LINENO}: Please use --enable-ccache instead of providing a wrapped compiler." >&5 34859 $as_echo "$as_me: Please use --enable-ccache instead of providing a wrapped compiler." >&6;} 34860 as_fn_error $? "$TEST_COMPILER is a symbolic link to ccache. This is not supported." "$LINENO" 5 34861 fi 34862 fi 34863 34864 34865 COMPILER=$CXX 34866 COMPILER_NAME=$COMPILER_NAME 34867 34868 if test "x$TOOLCHAIN_TYPE" = xsolstudio; then 34869 # cc -V output typically looks like 34870 # cc: Sun C 5.12 Linux_i386 2011/11/16 34871 COMPILER_VERSION_OUTPUT=`$COMPILER -V 2>&1` 34872 # Check that this is likely to be the Solaris Studio cc. 34873 $ECHO "$COMPILER_VERSION_OUTPUT" | $GREP "^.*: Sun $COMPILER_NAME" > /dev/null 34874 if test $? -ne 0; then 34875 ALT_VERSION_OUTPUT=`$COMPILER --version 2>&1` 34876 { $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 34877 $as_echo "$as_me: The $COMPILER_NAME compiler (located as $COMPILER) does not seem to be the required $TOOLCHAIN_TYPE compiler." >&6;} 34878 { $as_echo "$as_me:${as_lineno-$LINENO}: The result from running with -V was: \"$COMPILER_VERSION_OUTPUT\"" >&5 34879 $as_echo "$as_me: The result from running with -V was: \"$COMPILER_VERSION_OUTPUT\"" >&6;} 34880 { $as_echo "$as_me:${as_lineno-$LINENO}: The result from running with --version was: \"$ALT_VERSION_OUTPUT\"" >&5 34881 $as_echo "$as_me: The result from running with --version was: \"$ALT_VERSION_OUTPUT\"" >&6;} 34882 as_fn_error $? "A $TOOLCHAIN_TYPE compiler is required. Try setting --with-tools-dir." "$LINENO" 5 34883 fi 34884 # Remove usage instructions (if present), and 34885 # collapse compiler output into a single line 34886 COMPILER_VERSION_STRING=`$ECHO $COMPILER_VERSION_OUTPUT | \ 34887 $SED -e 's/ *[Uu]sage:.*//'` 34888 COMPILER_VERSION_NUMBER=`$ECHO $COMPILER_VERSION_OUTPUT | \ 34889 $SED -e "s/^.*[ ,\t]$COMPILER_NAME[ ,\t]\([1-9]\.[0-9][0-9]*\).*/\1/"` 34890 elif test "x$TOOLCHAIN_TYPE" = xxlc; then 34891 # xlc -qversion output typically looks like 34892 # IBM XL C/C++ for AIX, V11.1 (5724-X13) 34893 # Version: 11.01.0000.0015 34894 COMPILER_VERSION_OUTPUT=`$COMPILER -qversion 2>&1` 34895 # Check that this is likely to be the IBM XL C compiler. 34896 $ECHO "$COMPILER_VERSION_OUTPUT" | $GREP "IBM XL C" > /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 -qversion was: \"$COMPILER_VERSION_OUTPUT\"" >&5 34902 $as_echo "$as_me: The result from running with -qversion 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 # Collapse compiler output into a single line 34908 COMPILER_VERSION_STRING=`$ECHO $COMPILER_VERSION_OUTPUT` 34909 COMPILER_VERSION_NUMBER=`$ECHO $COMPILER_VERSION_OUTPUT | \ 34910 $SED -e 's/^.*, V\([1-9][0-9.]*\).*$/\1/'` 34911 elif test "x$TOOLCHAIN_TYPE" = xmicrosoft; then 34912 # There is no specific version flag, but all output starts with a version string. 34913 # First line typically looks something like: 34914 # Microsoft (R) 32-bit C/C++ Optimizing Compiler Version 16.00.40219.01 for 80x86 34915 COMPILER_VERSION_OUTPUT=`$COMPILER 2>&1 | $HEAD -n 1 | $TR -d '\r'` 34916 # Check that this is likely to be Microsoft CL.EXE. 34917 $ECHO "$COMPILER_VERSION_OUTPUT" | $GREP "Microsoft.*Compiler" > /dev/null 34918 if test $? -ne 0; then 34919 { $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 34920 $as_echo "$as_me: The $COMPILER_NAME compiler (located as $COMPILER) does not seem to be the required $TOOLCHAIN_TYPE compiler." >&6;} 34921 { $as_echo "$as_me:${as_lineno-$LINENO}: The result from running it was: \"$COMPILER_VERSION_OUTPUT\"" >&5 34922 $as_echo "$as_me: The result from running it was: \"$COMPILER_VERSION_OUTPUT\"" >&6;} 34923 as_fn_error $? "A $TOOLCHAIN_TYPE compiler is required. Try setting --with-tools-dir." "$LINENO" 5 34924 fi 34925 # Collapse compiler output into a single line 34926 COMPILER_VERSION_STRING=`$ECHO $COMPILER_VERSION_OUTPUT` 34927 COMPILER_VERSION_NUMBER=`$ECHO $COMPILER_VERSION_OUTPUT | \ 34928 $SED -e 's/^.*ersion.\([1-9][0-9.]*\) .*$/\1/'` 34929 elif test "x$TOOLCHAIN_TYPE" = xgcc; then 34930 # gcc --version output typically looks like 34931 # gcc (Ubuntu/Linaro 4.8.1-10ubuntu9) 4.8.1 34932 # Copyright (C) 2013 Free Software Foundation, Inc. 34933 # This is free software; see the source for copying conditions. There is NO 34934 # warranty; not even for MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. 34935 COMPILER_VERSION_OUTPUT=`$COMPILER --version 2>&1` 34936 # Check that this is likely to be GCC. 34937 $ECHO "$COMPILER_VERSION_OUTPUT" | $GREP "Free Software Foundation" > /dev/null 34938 if test $? -ne 0; then 34939 { $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 34940 $as_echo "$as_me: The $COMPILER_NAME compiler (located as $COMPILER) does not seem to be the required $TOOLCHAIN_TYPE compiler." >&6;} 34941 { $as_echo "$as_me:${as_lineno-$LINENO}: The result from running with --version was: \"$COMPILER_VERSION\"" >&5 34942 $as_echo "$as_me: The result from running with --version was: \"$COMPILER_VERSION\"" >&6;} 34943 as_fn_error $? "A $TOOLCHAIN_TYPE compiler is required. Try setting --with-tools-dir." "$LINENO" 5 34944 fi 34945 # Remove Copyright and legalese from version string, and 34946 # collapse into a single line 34947 COMPILER_VERSION_STRING=`$ECHO $COMPILER_VERSION_OUTPUT | \ 34948 $SED -e 's/ *Copyright .*//'` 34949 COMPILER_VERSION_NUMBER=`$ECHO $COMPILER_VERSION_OUTPUT | \ 34950 $SED -e 's/^.* \([1-9]\.[0-9.]*\)[^0-9.].*$/\1/'` 34951 elif test "x$TOOLCHAIN_TYPE" = xclang; then 34952 # clang --version output typically looks like 34953 # Apple LLVM version 5.0 (clang-500.2.79) (based on LLVM 3.3svn) 34954 # clang version 3.3 (tags/RELEASE_33/final) 34955 # or 34956 # Debian clang version 3.2-7ubuntu1 (tags/RELEASE_32/final) (based on LLVM 3.2) 34957 # Target: x86_64-pc-linux-gnu 34958 # Thread model: posix 34959 COMPILER_VERSION_OUTPUT=`$COMPILER --version 2>&1` 34960 # Check that this is likely to be clang 34961 $ECHO "$COMPILER_VERSION_OUTPUT" | $GREP "clang" > /dev/null 34962 if test $? -ne 0; then 34963 { $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 34964 $as_echo "$as_me: The $COMPILER_NAME compiler (located as $COMPILER) does not seem to be the required $TOOLCHAIN_TYPE compiler." >&6;} 34965 { $as_echo "$as_me:${as_lineno-$LINENO}: The result from running with --version was: \"$COMPILER_VERSION_OUTPUT\"" >&5 34966 $as_echo "$as_me: The result from running with --version was: \"$COMPILER_VERSION_OUTPUT\"" >&6;} 34967 as_fn_error $? "A $TOOLCHAIN_TYPE compiler is required. Try setting --with-tools-dir." "$LINENO" 5 34968 fi 34969 # Collapse compiler output into a single line 34970 COMPILER_VERSION_STRING=`$ECHO $COMPILER_VERSION_OUTPUT` 34971 COMPILER_VERSION_NUMBER=`$ECHO $COMPILER_VERSION_OUTPUT | \ 34972 $SED -e 's/^.* version \([1-9][0-9.]*\).*$/\1/'` 34973 else 34974 as_fn_error $? "Unknown toolchain type $TOOLCHAIN_TYPE." "$LINENO" 5 34975 fi 34976 # This sets CC_VERSION_NUMBER or CXX_VERSION_NUMBER. (This comment is a grep marker) 34977 CXX_VERSION_NUMBER="$COMPILER_VERSION_NUMBER" 34978 # This sets CC_VERSION_STRING or CXX_VERSION_STRING. (This comment is a grep marker) 34979 CXX_VERSION_STRING="$COMPILER_VERSION_STRING" 34980 34981 { $as_echo "$as_me:${as_lineno-$LINENO}: Using $TOOLCHAIN_TYPE $COMPILER_NAME compiler version $COMPILER_VERSION_NUMBER [$COMPILER_VERSION_STRING]" >&5 34982 $as_echo "$as_me: Using $TOOLCHAIN_TYPE $COMPILER_NAME compiler version $COMPILER_VERSION_NUMBER [$COMPILER_VERSION_STRING]" >&6;} 34983 34984 34985 # Now that we have resolved CXX ourself, let autoconf have its go at it 34986 ac_ext=cpp 34987 ac_cpp='$CXXCPP $CPPFLAGS' 34988 ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5' 34989 ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' 34990 ac_compiler_gnu=$ac_cv_cxx_compiler_gnu 34991 if test -z "$CXX"; then 34992 if test -n "$CCC"; then 34993 CXX=$CCC 34994 else 34995 if test -n "$ac_tool_prefix"; then 34996 for ac_prog in $CXX 34997 do 34998 # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args. 34999 set dummy $ac_tool_prefix$ac_prog; ac_word=$2 35000 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 35001 $as_echo_n "checking for $ac_word... " >&6; } 35002 if ${ac_cv_prog_CXX+:} false; then : 35003 $as_echo_n "(cached) " >&6 35004 else 35005 if test -n "$CXX"; then 35006 ac_cv_prog_CXX="$CXX" # Let the user override the test. 35007 else 35008 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 35009 for as_dir in $PATH 35010 do 35011 IFS=$as_save_IFS 35012 test -z "$as_dir" && as_dir=. 35013 for ac_exec_ext in '' $ac_executable_extensions; do 35014 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 35015 ac_cv_prog_CXX="$ac_tool_prefix$ac_prog" 35016 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 35017 break 2 35018 fi 35019 done 35020 done 35021 IFS=$as_save_IFS 35022 35023 fi 35024 fi 35025 CXX=$ac_cv_prog_CXX 35026 if test -n "$CXX"; then 35027 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CXX" >&5 35028 $as_echo "$CXX" >&6; } 35029 else 35030 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 35031 $as_echo "no" >&6; } 35032 fi 35033 35034 35035 test -n "$CXX" && break 35036 done 35037 fi 35038 if test -z "$CXX"; then 35039 ac_ct_CXX=$CXX 35040 for ac_prog in $CXX 35041 do 35042 # Extract the first word of "$ac_prog", so it can be a program name with args. 35043 set dummy $ac_prog; ac_word=$2 35044 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 35045 $as_echo_n "checking for $ac_word... " >&6; } 35046 if ${ac_cv_prog_ac_ct_CXX+:} false; then : 35047 $as_echo_n "(cached) " >&6 35048 else 35049 if test -n "$ac_ct_CXX"; then 35050 ac_cv_prog_ac_ct_CXX="$ac_ct_CXX" # Let the user override the test. 35051 else 35052 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 35053 for as_dir in $PATH 35054 do 35055 IFS=$as_save_IFS 35056 test -z "$as_dir" && as_dir=. 35057 for ac_exec_ext in '' $ac_executable_extensions; do 35058 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 35059 ac_cv_prog_ac_ct_CXX="$ac_prog" 35060 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 35061 break 2 35062 fi 35063 done 35064 done 35065 IFS=$as_save_IFS 35066 35067 fi 35068 fi 35069 ac_ct_CXX=$ac_cv_prog_ac_ct_CXX 35070 if test -n "$ac_ct_CXX"; then 35071 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_CXX" >&5 35072 $as_echo "$ac_ct_CXX" >&6; } 35073 else 35074 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 35075 $as_echo "no" >&6; } 35076 fi 35077 35078 35079 test -n "$ac_ct_CXX" && break 35080 done 35081 35082 if test "x$ac_ct_CXX" = x; then 35083 CXX="g++" 35084 else 35085 case $cross_compiling:$ac_tool_warned in 35086 yes:) 35087 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5 35088 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;} 35089 ac_tool_warned=yes ;; 35090 esac 35091 CXX=$ac_ct_CXX 35092 fi 35093 fi 35094 35095 fi 35096 fi 35097 # Provide some information about the compiler. 35098 $as_echo "$as_me:${as_lineno-$LINENO}: checking for C++ compiler version" >&5 35099 set X $ac_compile 35100 ac_compiler=$2 35101 for ac_option in --version -v -V -qversion; do 35102 { { ac_try="$ac_compiler $ac_option >&5" 35103 case "(($ac_try" in 35104 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; 35105 *) ac_try_echo=$ac_try;; 35106 esac 35107 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\"" 35108 $as_echo "$ac_try_echo"; } >&5 35109 (eval "$ac_compiler $ac_option >&5") 2>conftest.err 35110 ac_status=$? 35111 if test -s conftest.err; then 35112 sed '10a\ 35113 ... rest of stderr output deleted ... 35114 10q' conftest.err >conftest.er1 35115 cat conftest.er1 >&5 35116 fi 35117 rm -f conftest.er1 conftest.err 35118 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 35119 test $ac_status = 0; } 35120 done 35121 35122 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether we are using the GNU C++ compiler" >&5 35123 $as_echo_n "checking whether we are using the GNU C++ compiler... " >&6; } 35124 if ${ac_cv_cxx_compiler_gnu+:} false; then : 35125 $as_echo_n "(cached) " >&6 35126 else 35127 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 35128 /* end confdefs.h. */ 35129 35130 int 35131 main () 35132 { 35133 #ifndef __GNUC__ 35134 choke me 35135 #endif 35136 35137 ; 35138 return 0; 35139 } 35140 _ACEOF 35141 if ac_fn_cxx_try_compile "$LINENO"; then : 35142 ac_compiler_gnu=yes 35143 else 35144 ac_compiler_gnu=no 35145 fi 35146 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext 35147 ac_cv_cxx_compiler_gnu=$ac_compiler_gnu 35148 35149 fi 35150 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_cxx_compiler_gnu" >&5 35151 $as_echo "$ac_cv_cxx_compiler_gnu" >&6; } 35152 if test $ac_compiler_gnu = yes; then 35153 GXX=yes 35154 else 35155 GXX= 35156 fi 35157 ac_test_CXXFLAGS=${CXXFLAGS+set} 35158 ac_save_CXXFLAGS=$CXXFLAGS 35159 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $CXX accepts -g" >&5 35160 $as_echo_n "checking whether $CXX accepts -g... " >&6; } 35161 if ${ac_cv_prog_cxx_g+:} false; then : 35162 $as_echo_n "(cached) " >&6 35163 else 35164 ac_save_cxx_werror_flag=$ac_cxx_werror_flag 35165 ac_cxx_werror_flag=yes 35166 ac_cv_prog_cxx_g=no 35167 CXXFLAGS="-g" 35168 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 35169 /* end confdefs.h. */ 35170 35171 int 35172 main () 35173 { 35174 35175 ; 35176 return 0; 35177 } 35178 _ACEOF 35179 if ac_fn_cxx_try_compile "$LINENO"; then : 35180 ac_cv_prog_cxx_g=yes 35181 else 35182 CXXFLAGS="" 35183 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 35184 /* end confdefs.h. */ 35185 35186 int 35187 main () 35188 { 35189 35190 ; 35191 return 0; 35192 } 35193 _ACEOF 35194 if ac_fn_cxx_try_compile "$LINENO"; then : 35195 35196 else 35197 ac_cxx_werror_flag=$ac_save_cxx_werror_flag 35198 CXXFLAGS="-g" 35199 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 35200 /* end confdefs.h. */ 35201 35202 int 35203 main () 35204 { 35205 35206 ; 35207 return 0; 35208 } 35209 _ACEOF 35210 if ac_fn_cxx_try_compile "$LINENO"; then : 35211 ac_cv_prog_cxx_g=yes 35212 fi 35213 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext 35214 fi 35215 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext 35216 fi 35217 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext 35218 ac_cxx_werror_flag=$ac_save_cxx_werror_flag 35219 fi 35220 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_prog_cxx_g" >&5 35221 $as_echo "$ac_cv_prog_cxx_g" >&6; } 35222 if test "$ac_test_CXXFLAGS" = set; then 35223 CXXFLAGS=$ac_save_CXXFLAGS 35224 elif test $ac_cv_prog_cxx_g = yes; then 35225 if test "$GXX" = yes; then 35226 CXXFLAGS="-g -O2" 35227 else 35228 CXXFLAGS="-g" 35229 fi 35230 else 35231 if test "$GXX" = yes; then 35232 CXXFLAGS="-O2" 35233 else 35234 CXXFLAGS= 35235 fi 35236 fi 35237 ac_ext=cpp 35238 ac_cpp='$CXXCPP $CPPFLAGS' 35239 ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5' 35240 ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' 35241 ac_compiler_gnu=$ac_cv_cxx_compiler_gnu 35242 35243 35244 # This is the compiler version number on the form X.Y[.Z] 35245 35246 35247 35248 35249 if test "x$CC_VERSION_NUMBER" != "x$CXX_VERSION_NUMBER"; then 35250 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: C and C++ compiler have different version numbers, $CC_VERSION_NUMBER vs $CXX_VERSION_NUMBER." >&5 35251 $as_echo "$as_me: WARNING: C and C++ compiler have different version numbers, $CC_VERSION_NUMBER vs $CXX_VERSION_NUMBER." >&2;} 35252 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: This typically indicates a broken setup, and is not supported" >&5 35253 $as_echo "$as_me: WARNING: This typically indicates a broken setup, and is not supported" >&2;} 35254 fi 35255 35256 # We only check CC_VERSION_NUMBER since we assume CXX_VERSION_NUMBER is equal. 35257 if [[ "[$]CC_VERSION_NUMBER" =~ (.*\.){3} ]] ; then 35258 { $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 35259 $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;} 35260 fi 35261 35262 if [[ "[$]CC_VERSION_NUMBER" =~ [0-9]{6} ]] ; then 35263 { $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 35264 $as_echo "$as_me: WARNING: C compiler version number has a part larger than 99999: $CC_VERSION_NUMBER. Comparisons might be wrong." >&2;} 35265 fi 35266 35267 COMPARABLE_ACTUAL_VERSION=`$AWK -F. '{ printf("%05d%05d%05d\n", $1, $2, $3) }' <<< "$CC_VERSION_NUMBER"` 35268 35269 35270 if test "x$TOOLCHAIN_MINIMUM_VERSION" != x; then 35271 35272 35273 35274 35275 35276 35277 35278 35279 35280 35281 35282 35283 35284 35285 35286 35287 35288 35289 35290 35291 35292 35293 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 # Execute function body 35321 35322 # Need to assign to a variable since m4 is blocked from modifying parts in []. 35323 REFERENCE_VERSION=$TOOLCHAIN_MINIMUM_VERSION 35324 35325 if [[ "$REFERENCE_VERSION" =~ (.*\.){3} ]] ; then 35326 as_fn_error $? "Internal error: Cannot compare to $TOOLCHAIN_MINIMUM_VERSION, only three parts (X.Y.Z) is supported" "$LINENO" 5 35327 fi 35328 35329 if [[ "$REFERENCE_VERSION" =~ [0-9]{6} ]] ; then 35330 as_fn_error $? "Internal error: Cannot compare to $TOOLCHAIN_MINIMUM_VERSION, only parts < 99999 is supported" "$LINENO" 5 35331 fi 35332 35333 # Version comparison method inspired by http://stackoverflow.com/a/24067243 35334 COMPARABLE_REFERENCE_VERSION=`$AWK -F. '{ printf("%05d%05d%05d\n", $1, $2, $3) }' <<< "$REFERENCE_VERSION"` 35335 35336 if test $COMPARABLE_ACTUAL_VERSION -ge $COMPARABLE_REFERENCE_VERSION ; then 35337 : 35338 35339 else 35340 : 35341 35342 { $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 35343 $as_echo "$as_me: WARNING: You are using $TOOLCHAIN_TYPE older than $TOOLCHAIN_MINIMUM_VERSION. This is not a supported configuration." >&2;} 35344 35345 35346 fi 35347 35348 35349 35350 35351 35352 35353 35354 35355 35356 35357 35358 35359 35360 35361 fi 35362 35363 # 35364 # Setup the preprocessor (CPP and CXXCPP) 35365 # 35366 ac_ext=c 35367 ac_cpp='$CPP $CPPFLAGS' 35368 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5' 35369 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' 35370 ac_compiler_gnu=$ac_cv_c_compiler_gnu 35371 { $as_echo "$as_me:${as_lineno-$LINENO}: checking how to run the C preprocessor" >&5 35372 $as_echo_n "checking how to run the C preprocessor... " >&6; } 35373 # On Suns, sometimes $CPP names a directory. 35374 if test -n "$CPP" && test -d "$CPP"; then 35375 CPP= 35376 fi 35377 if test -z "$CPP"; then 35378 if ${ac_cv_prog_CPP+:} false; then : 35379 $as_echo_n "(cached) " >&6 35380 else 35381 # Double quotes because CPP needs to be expanded 35382 for CPP in "$CC -E" "$CC -E -traditional-cpp" "/lib/cpp" 35383 do 35384 ac_preproc_ok=false 35385 for ac_c_preproc_warn_flag in '' yes 35386 do 35387 # Use a header file that comes with gcc, so configuring glibc 35388 # with a fresh cross-compiler works. 35389 # Prefer <limits.h> to <assert.h> if __STDC__ is defined, since 35390 # <limits.h> exists even on freestanding compilers. 35391 # On the NeXT, cc -E runs the code through the compiler's parser, 35392 # not just through cpp. "Syntax error" is here to catch this case. 35393 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 35394 /* end confdefs.h. */ 35395 #ifdef __STDC__ 35396 # include <limits.h> 35397 #else 35398 # include <assert.h> 35399 #endif 35400 Syntax error 35401 _ACEOF 35402 if ac_fn_c_try_cpp "$LINENO"; then : 35403 35404 else 35405 # Broken: fails on valid input. 35406 continue 35407 fi 35408 rm -f conftest.err conftest.i conftest.$ac_ext 35409 35410 # OK, works on sane cases. Now check whether nonexistent headers 35411 # can be detected and how. 35412 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 35413 /* end confdefs.h. */ 35414 #include <ac_nonexistent.h> 35415 _ACEOF 35416 if ac_fn_c_try_cpp "$LINENO"; then : 35417 # Broken: success on invalid input. 35418 continue 35419 else 35420 # Passes both tests. 35421 ac_preproc_ok=: 35422 break 35423 fi 35424 rm -f conftest.err conftest.i conftest.$ac_ext 35425 35426 done 35427 # Because of `break', _AC_PREPROC_IFELSE's cleaning code was skipped. 35428 rm -f conftest.i conftest.err conftest.$ac_ext 35429 if $ac_preproc_ok; then : 35430 break 35431 fi 35432 35433 done 35434 ac_cv_prog_CPP=$CPP 35435 35436 fi 35437 CPP=$ac_cv_prog_CPP 35438 else 35439 ac_cv_prog_CPP=$CPP 35440 fi 35441 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CPP" >&5 35442 $as_echo "$CPP" >&6; } 35443 ac_preproc_ok=false 35444 for ac_c_preproc_warn_flag in '' yes 35445 do 35446 # Use a header file that comes with gcc, so configuring glibc 35447 # with a fresh cross-compiler works. 35448 # Prefer <limits.h> to <assert.h> if __STDC__ is defined, since 35449 # <limits.h> exists even on freestanding compilers. 35450 # On the NeXT, cc -E runs the code through the compiler's parser, 35451 # not just through cpp. "Syntax error" is here to catch this case. 35452 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 35453 /* end confdefs.h. */ 35454 #ifdef __STDC__ 35455 # include <limits.h> 35456 #else 35457 # include <assert.h> 35458 #endif 35459 Syntax error 35460 _ACEOF 35461 if ac_fn_c_try_cpp "$LINENO"; then : 35462 35463 else 35464 # Broken: fails on valid input. 35465 continue 35466 fi 35467 rm -f conftest.err conftest.i conftest.$ac_ext 35468 35469 # OK, works on sane cases. Now check whether nonexistent headers 35470 # can be detected and how. 35471 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 35472 /* end confdefs.h. */ 35473 #include <ac_nonexistent.h> 35474 _ACEOF 35475 if ac_fn_c_try_cpp "$LINENO"; then : 35476 # Broken: success on invalid input. 35477 continue 35478 else 35479 # Passes both tests. 35480 ac_preproc_ok=: 35481 break 35482 fi 35483 rm -f conftest.err conftest.i conftest.$ac_ext 35484 35485 done 35486 # Because of `break', _AC_PREPROC_IFELSE's cleaning code was skipped. 35487 rm -f conftest.i conftest.err conftest.$ac_ext 35488 if $ac_preproc_ok; then : 35489 35490 else 35491 { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 35492 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;} 35493 as_fn_error $? "C preprocessor \"$CPP\" fails sanity check 35494 See \`config.log' for more details" "$LINENO" 5; } 35495 fi 35496 35497 ac_ext=cpp 35498 ac_cpp='$CXXCPP $CPPFLAGS' 35499 ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5' 35500 ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' 35501 ac_compiler_gnu=$ac_cv_cxx_compiler_gnu 35502 35503 35504 # Only process if variable expands to non-empty 35505 35506 if test "x$CPP" != x; then 35507 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 35508 35509 # First separate the path from the arguments. This will split at the first 35510 # space. 35511 complete="$CPP" 35512 path="${complete%% *}" 35513 tmp="$complete EOL" 35514 arguments="${tmp#* }" 35515 35516 # Input might be given as Windows format, start by converting to 35517 # unix format. 35518 new_path=`$CYGPATH -u "$path"` 35519 35520 # Now try to locate executable using which 35521 new_path=`$WHICH "$new_path" 2> /dev/null` 35522 # bat and cmd files are not always considered executable in cygwin causing which 35523 # to not find them 35524 if test "x$new_path" = x \ 35525 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 35526 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 35527 new_path=`$CYGPATH -u "$path"` 35528 fi 35529 if test "x$new_path" = x; then 35530 # Oops. Which didn't find the executable. 35531 # The splitting of arguments from the executable at a space might have been incorrect, 35532 # since paths with space are more likely in Windows. Give it another try with the whole 35533 # argument. 35534 path="$complete" 35535 arguments="EOL" 35536 new_path=`$CYGPATH -u "$path"` 35537 new_path=`$WHICH "$new_path" 2> /dev/null` 35538 # bat and cmd files are not always considered executable in cygwin causing which 35539 # to not find them 35540 if test "x$new_path" = x \ 35541 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 35542 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 35543 new_path=`$CYGPATH -u "$path"` 35544 fi 35545 if test "x$new_path" = x; then 35546 # It's still not found. Now this is an unrecoverable error. 35547 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of CPP, which resolves as \"$complete\", is not found." >&5 35548 $as_echo "$as_me: The path of CPP, which resolves as \"$complete\", is not found." >&6;} 35549 has_space=`$ECHO "$complete" | $GREP " "` 35550 if test "x$has_space" != x; then 35551 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 35552 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 35553 fi 35554 as_fn_error $? "Cannot locate the the path of CPP" "$LINENO" 5 35555 fi 35556 fi 35557 35558 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 35559 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 35560 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 35561 # "foo.exe" is OK but "foo" is an error. 35562 # 35563 # This test is therefore slightly more accurate than "test -f" to check for file presence. 35564 # It is also a way to make sure we got the proper file name for the real test later on. 35565 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 35566 if test "x$test_shortpath" = x; then 35567 # Short path failed, file does not exist as specified. 35568 # Try adding .exe or .cmd 35569 if test -f "${new_path}.exe"; then 35570 input_to_shortpath="${new_path}.exe" 35571 elif test -f "${new_path}.cmd"; then 35572 input_to_shortpath="${new_path}.cmd" 35573 else 35574 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of CPP, which resolves as \"$new_path\", is invalid." >&5 35575 $as_echo "$as_me: The path of CPP, which resolves as \"$new_path\", is invalid." >&6;} 35576 { $as_echo "$as_me:${as_lineno-$LINENO}: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&5 35577 $as_echo "$as_me: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&6;} 35578 as_fn_error $? "Cannot locate the the path of CPP" "$LINENO" 5 35579 fi 35580 else 35581 input_to_shortpath="$new_path" 35582 fi 35583 35584 # Call helper function which possibly converts this using DOS-style short mode. 35585 # If so, the updated path is stored in $new_path. 35586 new_path="$input_to_shortpath" 35587 35588 input_path="$input_to_shortpath" 35589 # Check if we need to convert this using DOS-style short mode. If the path 35590 # contains just simple characters, use it. Otherwise (spaces, weird characters), 35591 # take no chances and rewrite it. 35592 # Note: m4 eats our [], so we need to use [ and ] instead. 35593 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 35594 if test "x$has_forbidden_chars" != x; then 35595 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 35596 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 35597 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 35598 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 35599 # Going to short mode and back again did indeed matter. Since short mode is 35600 # case insensitive, let's make it lowercase to improve readability. 35601 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 35602 # Now convert it back to Unix-style (cygpath) 35603 input_path=`$CYGPATH -u "$shortmode_path"` 35604 new_path="$input_path" 35605 fi 35606 fi 35607 35608 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 35609 if test "x$test_cygdrive_prefix" = x; then 35610 # As a simple fix, exclude /usr/bin since it's not a real path. 35611 if test "x`$ECHO $input_to_shortpath | $GREP ^/usr/bin/`" = x; then 35612 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 35613 # a path prefixed by /cygdrive for fixpath to work. 35614 new_path="$CYGWIN_ROOT_PATH$input_path" 35615 fi 35616 fi 35617 35618 # remove trailing .exe if any 35619 new_path="${new_path/%.exe/}" 35620 35621 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 35622 35623 # First separate the path from the arguments. This will split at the first 35624 # space. 35625 complete="$CPP" 35626 path="${complete%% *}" 35627 tmp="$complete EOL" 35628 arguments="${tmp#* }" 35629 35630 # Input might be given as Windows format, start by converting to 35631 # unix format. 35632 new_path="$path" 35633 35634 windows_path="$new_path" 35635 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 35636 unix_path=`$CYGPATH -u "$windows_path"` 35637 new_path="$unix_path" 35638 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 35639 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 35640 new_path="$unix_path" 35641 fi 35642 35643 35644 # Now try to locate executable using which 35645 new_path=`$WHICH "$new_path" 2> /dev/null` 35646 35647 if test "x$new_path" = x; then 35648 # Oops. Which didn't find the executable. 35649 # The splitting of arguments from the executable at a space might have been incorrect, 35650 # since paths with space are more likely in Windows. Give it another try with the whole 35651 # argument. 35652 path="$complete" 35653 arguments="EOL" 35654 new_path="$path" 35655 35656 windows_path="$new_path" 35657 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 35658 unix_path=`$CYGPATH -u "$windows_path"` 35659 new_path="$unix_path" 35660 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 35661 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 35662 new_path="$unix_path" 35663 fi 35664 35665 35666 new_path=`$WHICH "$new_path" 2> /dev/null` 35667 # bat and cmd files are not always considered executable in MSYS causing which 35668 # to not find them 35669 if test "x$new_path" = x \ 35670 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 35671 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 35672 new_path="$path" 35673 35674 windows_path="$new_path" 35675 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 35676 unix_path=`$CYGPATH -u "$windows_path"` 35677 new_path="$unix_path" 35678 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 35679 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 35680 new_path="$unix_path" 35681 fi 35682 35683 fi 35684 35685 if test "x$new_path" = x; then 35686 # It's still not found. Now this is an unrecoverable error. 35687 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of CPP, which resolves as \"$complete\", is not found." >&5 35688 $as_echo "$as_me: The path of CPP, which resolves as \"$complete\", is not found." >&6;} 35689 has_space=`$ECHO "$complete" | $GREP " "` 35690 if test "x$has_space" != x; then 35691 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 35692 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 35693 fi 35694 as_fn_error $? "Cannot locate the the path of CPP" "$LINENO" 5 35695 fi 35696 fi 35697 35698 # Now new_path has a complete unix path to the binary 35699 if test "x`$ECHO $new_path | $GREP ^/bin/`" != x; then 35700 # Keep paths in /bin as-is, but remove trailing .exe if any 35701 new_path="${new_path/%.exe/}" 35702 # Do not save /bin paths to all_fixpath_prefixes! 35703 else 35704 # Not in mixed or Windows style, start by that. 35705 new_path=`cmd //c echo $new_path` 35706 35707 input_path="$new_path" 35708 # Check if we need to convert this using DOS-style short mode. If the path 35709 # contains just simple characters, use it. Otherwise (spaces, weird characters), 35710 # take no chances and rewrite it. 35711 # Note: m4 eats our [], so we need to use [ and ] instead. 35712 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 35713 if test "x$has_forbidden_chars" != x; then 35714 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 35715 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 35716 fi 35717 35718 # Output is in $new_path 35719 35720 windows_path="$new_path" 35721 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 35722 unix_path=`$CYGPATH -u "$windows_path"` 35723 new_path="$unix_path" 35724 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 35725 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 35726 new_path="$unix_path" 35727 fi 35728 35729 # remove trailing .exe if any 35730 new_path="${new_path/%.exe/}" 35731 35732 # Save the first 10 bytes of this path to the storage, so fixpath can work. 35733 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 35734 fi 35735 35736 else 35737 # We're on a unix platform. Hooray! :) 35738 # First separate the path from the arguments. This will split at the first 35739 # space. 35740 complete="$CPP" 35741 path="${complete%% *}" 35742 tmp="$complete EOL" 35743 arguments="${tmp#* }" 35744 35745 # Cannot rely on the command "which" here since it doesn't always work. 35746 is_absolute_path=`$ECHO "$path" | $GREP ^/` 35747 if test -z "$is_absolute_path"; then 35748 # Path to executable is not absolute. Find it. 35749 IFS_save="$IFS" 35750 IFS=: 35751 for p in $PATH; do 35752 if test -f "$p/$path" && test -x "$p/$path"; then 35753 new_path="$p/$path" 35754 break 35755 fi 35756 done 35757 IFS="$IFS_save" 35758 else 35759 # This is an absolute path, we can use it without further modifications. 35760 new_path="$path" 35761 fi 35762 35763 if test "x$new_path" = x; then 35764 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of CPP, which resolves as \"$complete\", is not found." >&5 35765 $as_echo "$as_me: The path of CPP, which resolves as \"$complete\", is not found." >&6;} 35766 has_space=`$ECHO "$complete" | $GREP " "` 35767 if test "x$has_space" != x; then 35768 { $as_echo "$as_me:${as_lineno-$LINENO}: This might be caused by spaces in the path, which is not allowed." >&5 35769 $as_echo "$as_me: This might be caused by spaces in the path, which is not allowed." >&6;} 35770 fi 35771 as_fn_error $? "Cannot locate the the path of CPP" "$LINENO" 5 35772 fi 35773 fi 35774 35775 # Now join together the path and the arguments once again 35776 if test "x$arguments" != xEOL; then 35777 new_complete="$new_path ${arguments% *}" 35778 else 35779 new_complete="$new_path" 35780 fi 35781 35782 if test "x$complete" != "x$new_complete"; then 35783 CPP="$new_complete" 35784 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting CPP to \"$new_complete\"" >&5 35785 $as_echo "$as_me: Rewriting CPP to \"$new_complete\"" >&6;} 35786 fi 35787 fi 35788 35789 ac_ext=cpp 35790 ac_cpp='$CXXCPP $CPPFLAGS' 35791 ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5' 35792 ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' 35793 ac_compiler_gnu=$ac_cv_cxx_compiler_gnu 35794 { $as_echo "$as_me:${as_lineno-$LINENO}: checking how to run the C++ preprocessor" >&5 35795 $as_echo_n "checking how to run the C++ preprocessor... " >&6; } 35796 if test -z "$CXXCPP"; then 35797 if ${ac_cv_prog_CXXCPP+:} false; then : 35798 $as_echo_n "(cached) " >&6 35799 else 35800 # Double quotes because CXXCPP needs to be expanded 35801 for CXXCPP in "$CXX -E" "/lib/cpp" 35802 do 35803 ac_preproc_ok=false 35804 for ac_cxx_preproc_warn_flag in '' yes 35805 do 35806 # Use a header file that comes with gcc, so configuring glibc 35807 # with a fresh cross-compiler works. 35808 # Prefer <limits.h> to <assert.h> if __STDC__ is defined, since 35809 # <limits.h> exists even on freestanding compilers. 35810 # On the NeXT, cc -E runs the code through the compiler's parser, 35811 # not just through cpp. "Syntax error" is here to catch this case. 35812 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 35813 /* end confdefs.h. */ 35814 #ifdef __STDC__ 35815 # include <limits.h> 35816 #else 35817 # include <assert.h> 35818 #endif 35819 Syntax error 35820 _ACEOF 35821 if ac_fn_cxx_try_cpp "$LINENO"; then : 35822 35823 else 35824 # Broken: fails on valid input. 35825 continue 35826 fi 35827 rm -f conftest.err conftest.i conftest.$ac_ext 35828 35829 # OK, works on sane cases. Now check whether nonexistent headers 35830 # can be detected and how. 35831 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 35832 /* end confdefs.h. */ 35833 #include <ac_nonexistent.h> 35834 _ACEOF 35835 if ac_fn_cxx_try_cpp "$LINENO"; then : 35836 # Broken: success on invalid input. 35837 continue 35838 else 35839 # Passes both tests. 35840 ac_preproc_ok=: 35841 break 35842 fi 35843 rm -f conftest.err conftest.i conftest.$ac_ext 35844 35845 done 35846 # Because of `break', _AC_PREPROC_IFELSE's cleaning code was skipped. 35847 rm -f conftest.i conftest.err conftest.$ac_ext 35848 if $ac_preproc_ok; then : 35849 break 35850 fi 35851 35852 done 35853 ac_cv_prog_CXXCPP=$CXXCPP 35854 35855 fi 35856 CXXCPP=$ac_cv_prog_CXXCPP 35857 else 35858 ac_cv_prog_CXXCPP=$CXXCPP 35859 fi 35860 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CXXCPP" >&5 35861 $as_echo "$CXXCPP" >&6; } 35862 ac_preproc_ok=false 35863 for ac_cxx_preproc_warn_flag in '' yes 35864 do 35865 # Use a header file that comes with gcc, so configuring glibc 35866 # with a fresh cross-compiler works. 35867 # Prefer <limits.h> to <assert.h> if __STDC__ is defined, since 35868 # <limits.h> exists even on freestanding compilers. 35869 # On the NeXT, cc -E runs the code through the compiler's parser, 35870 # not just through cpp. "Syntax error" is here to catch this case. 35871 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 35872 /* end confdefs.h. */ 35873 #ifdef __STDC__ 35874 # include <limits.h> 35875 #else 35876 # include <assert.h> 35877 #endif 35878 Syntax error 35879 _ACEOF 35880 if ac_fn_cxx_try_cpp "$LINENO"; then : 35881 35882 else 35883 # Broken: fails on valid input. 35884 continue 35885 fi 35886 rm -f conftest.err conftest.i conftest.$ac_ext 35887 35888 # OK, works on sane cases. Now check whether nonexistent headers 35889 # can be detected and how. 35890 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 35891 /* end confdefs.h. */ 35892 #include <ac_nonexistent.h> 35893 _ACEOF 35894 if ac_fn_cxx_try_cpp "$LINENO"; then : 35895 # Broken: success on invalid input. 35896 continue 35897 else 35898 # Passes both tests. 35899 ac_preproc_ok=: 35900 break 35901 fi 35902 rm -f conftest.err conftest.i conftest.$ac_ext 35903 35904 done 35905 # Because of `break', _AC_PREPROC_IFELSE's cleaning code was skipped. 35906 rm -f conftest.i conftest.err conftest.$ac_ext 35907 if $ac_preproc_ok; then : 35908 35909 else 35910 { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 35911 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;} 35912 as_fn_error $? "C++ preprocessor \"$CXXCPP\" fails sanity check 35913 See \`config.log' for more details" "$LINENO" 5; } 35914 fi 35915 35916 ac_ext=cpp 35917 ac_cpp='$CXXCPP $CPPFLAGS' 35918 ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5' 35919 ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' 35920 ac_compiler_gnu=$ac_cv_cxx_compiler_gnu 35921 35922 35923 # Only process if variable expands to non-empty 35924 35925 if test "x$CXXCPP" != x; then 35926 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 35927 35928 # First separate the path from the arguments. This will split at the first 35929 # space. 35930 complete="$CXXCPP" 35931 path="${complete%% *}" 35932 tmp="$complete EOL" 35933 arguments="${tmp#* }" 35934 35935 # Input might be given as Windows format, start by converting to 35936 # unix format. 35937 new_path=`$CYGPATH -u "$path"` 35938 35939 # Now try to locate executable using which 35940 new_path=`$WHICH "$new_path" 2> /dev/null` 35941 # bat and cmd files are not always considered executable in cygwin causing which 35942 # to not find them 35943 if test "x$new_path" = x \ 35944 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 35945 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 35946 new_path=`$CYGPATH -u "$path"` 35947 fi 35948 if test "x$new_path" = x; then 35949 # Oops. Which didn't find the executable. 35950 # The splitting of arguments from the executable at a space might have been incorrect, 35951 # since paths with space are more likely in Windows. Give it another try with the whole 35952 # argument. 35953 path="$complete" 35954 arguments="EOL" 35955 new_path=`$CYGPATH -u "$path"` 35956 new_path=`$WHICH "$new_path" 2> /dev/null` 35957 # bat and cmd files are not always considered executable in cygwin causing which 35958 # to not find them 35959 if test "x$new_path" = x \ 35960 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 35961 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 35962 new_path=`$CYGPATH -u "$path"` 35963 fi 35964 if test "x$new_path" = x; then 35965 # It's still not found. Now this is an unrecoverable error. 35966 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of CXXCPP, which resolves as \"$complete\", is not found." >&5 35967 $as_echo "$as_me: The path of CXXCPP, which resolves as \"$complete\", is not found." >&6;} 35968 has_space=`$ECHO "$complete" | $GREP " "` 35969 if test "x$has_space" != x; then 35970 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 35971 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 35972 fi 35973 as_fn_error $? "Cannot locate the the path of CXXCPP" "$LINENO" 5 35974 fi 35975 fi 35976 35977 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 35978 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 35979 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 35980 # "foo.exe" is OK but "foo" is an error. 35981 # 35982 # This test is therefore slightly more accurate than "test -f" to check for file presence. 35983 # It is also a way to make sure we got the proper file name for the real test later on. 35984 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 35985 if test "x$test_shortpath" = x; then 35986 # Short path failed, file does not exist as specified. 35987 # Try adding .exe or .cmd 35988 if test -f "${new_path}.exe"; then 35989 input_to_shortpath="${new_path}.exe" 35990 elif test -f "${new_path}.cmd"; then 35991 input_to_shortpath="${new_path}.cmd" 35992 else 35993 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of CXXCPP, which resolves as \"$new_path\", is invalid." >&5 35994 $as_echo "$as_me: The path of CXXCPP, which resolves as \"$new_path\", is invalid." >&6;} 35995 { $as_echo "$as_me:${as_lineno-$LINENO}: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&5 35996 $as_echo "$as_me: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&6;} 35997 as_fn_error $? "Cannot locate the the path of CXXCPP" "$LINENO" 5 35998 fi 35999 else 36000 input_to_shortpath="$new_path" 36001 fi 36002 36003 # Call helper function which possibly converts this using DOS-style short mode. 36004 # If so, the updated path is stored in $new_path. 36005 new_path="$input_to_shortpath" 36006 36007 input_path="$input_to_shortpath" 36008 # Check if we need to convert this using DOS-style short mode. If the path 36009 # contains just simple characters, use it. Otherwise (spaces, weird characters), 36010 # take no chances and rewrite it. 36011 # Note: m4 eats our [], so we need to use [ and ] instead. 36012 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 36013 if test "x$has_forbidden_chars" != x; then 36014 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 36015 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 36016 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 36017 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 36018 # Going to short mode and back again did indeed matter. Since short mode is 36019 # case insensitive, let's make it lowercase to improve readability. 36020 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 36021 # Now convert it back to Unix-style (cygpath) 36022 input_path=`$CYGPATH -u "$shortmode_path"` 36023 new_path="$input_path" 36024 fi 36025 fi 36026 36027 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 36028 if test "x$test_cygdrive_prefix" = x; then 36029 # As a simple fix, exclude /usr/bin since it's not a real path. 36030 if test "x`$ECHO $input_to_shortpath | $GREP ^/usr/bin/`" = x; then 36031 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 36032 # a path prefixed by /cygdrive for fixpath to work. 36033 new_path="$CYGWIN_ROOT_PATH$input_path" 36034 fi 36035 fi 36036 36037 # remove trailing .exe if any 36038 new_path="${new_path/%.exe/}" 36039 36040 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 36041 36042 # First separate the path from the arguments. This will split at the first 36043 # space. 36044 complete="$CXXCPP" 36045 path="${complete%% *}" 36046 tmp="$complete EOL" 36047 arguments="${tmp#* }" 36048 36049 # Input might be given as Windows format, start by converting to 36050 # unix format. 36051 new_path="$path" 36052 36053 windows_path="$new_path" 36054 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 36055 unix_path=`$CYGPATH -u "$windows_path"` 36056 new_path="$unix_path" 36057 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 36058 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 36059 new_path="$unix_path" 36060 fi 36061 36062 36063 # Now try to locate executable using which 36064 new_path=`$WHICH "$new_path" 2> /dev/null` 36065 36066 if test "x$new_path" = x; then 36067 # Oops. Which didn't find the executable. 36068 # The splitting of arguments from the executable at a space might have been incorrect, 36069 # since paths with space are more likely in Windows. Give it another try with the whole 36070 # argument. 36071 path="$complete" 36072 arguments="EOL" 36073 new_path="$path" 36074 36075 windows_path="$new_path" 36076 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 36077 unix_path=`$CYGPATH -u "$windows_path"` 36078 new_path="$unix_path" 36079 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 36080 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 36081 new_path="$unix_path" 36082 fi 36083 36084 36085 new_path=`$WHICH "$new_path" 2> /dev/null` 36086 # bat and cmd files are not always considered executable in MSYS causing which 36087 # to not find them 36088 if test "x$new_path" = x \ 36089 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 36090 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 36091 new_path="$path" 36092 36093 windows_path="$new_path" 36094 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 36095 unix_path=`$CYGPATH -u "$windows_path"` 36096 new_path="$unix_path" 36097 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 36098 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 36099 new_path="$unix_path" 36100 fi 36101 36102 fi 36103 36104 if test "x$new_path" = x; then 36105 # It's still not found. Now this is an unrecoverable error. 36106 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of CXXCPP, which resolves as \"$complete\", is not found." >&5 36107 $as_echo "$as_me: The path of CXXCPP, which resolves as \"$complete\", is not found." >&6;} 36108 has_space=`$ECHO "$complete" | $GREP " "` 36109 if test "x$has_space" != x; then 36110 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 36111 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 36112 fi 36113 as_fn_error $? "Cannot locate the the path of CXXCPP" "$LINENO" 5 36114 fi 36115 fi 36116 36117 # Now new_path has a complete unix path to the binary 36118 if test "x`$ECHO $new_path | $GREP ^/bin/`" != x; then 36119 # Keep paths in /bin as-is, but remove trailing .exe if any 36120 new_path="${new_path/%.exe/}" 36121 # Do not save /bin paths to all_fixpath_prefixes! 36122 else 36123 # Not in mixed or Windows style, start by that. 36124 new_path=`cmd //c echo $new_path` 36125 36126 input_path="$new_path" 36127 # Check if we need to convert this using DOS-style short mode. If the path 36128 # contains just simple characters, use it. Otherwise (spaces, weird characters), 36129 # take no chances and rewrite it. 36130 # Note: m4 eats our [], so we need to use [ and ] instead. 36131 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 36132 if test "x$has_forbidden_chars" != x; then 36133 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 36134 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 36135 fi 36136 36137 # Output is in $new_path 36138 36139 windows_path="$new_path" 36140 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 36141 unix_path=`$CYGPATH -u "$windows_path"` 36142 new_path="$unix_path" 36143 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 36144 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 36145 new_path="$unix_path" 36146 fi 36147 36148 # remove trailing .exe if any 36149 new_path="${new_path/%.exe/}" 36150 36151 # Save the first 10 bytes of this path to the storage, so fixpath can work. 36152 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 36153 fi 36154 36155 else 36156 # We're on a unix platform. Hooray! :) 36157 # First separate the path from the arguments. This will split at the first 36158 # space. 36159 complete="$CXXCPP" 36160 path="${complete%% *}" 36161 tmp="$complete EOL" 36162 arguments="${tmp#* }" 36163 36164 # Cannot rely on the command "which" here since it doesn't always work. 36165 is_absolute_path=`$ECHO "$path" | $GREP ^/` 36166 if test -z "$is_absolute_path"; then 36167 # Path to executable is not absolute. Find it. 36168 IFS_save="$IFS" 36169 IFS=: 36170 for p in $PATH; do 36171 if test -f "$p/$path" && test -x "$p/$path"; then 36172 new_path="$p/$path" 36173 break 36174 fi 36175 done 36176 IFS="$IFS_save" 36177 else 36178 # This is an absolute path, we can use it without further modifications. 36179 new_path="$path" 36180 fi 36181 36182 if test "x$new_path" = x; then 36183 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of CXXCPP, which resolves as \"$complete\", is not found." >&5 36184 $as_echo "$as_me: The path of CXXCPP, which resolves as \"$complete\", is not found." >&6;} 36185 has_space=`$ECHO "$complete" | $GREP " "` 36186 if test "x$has_space" != x; then 36187 { $as_echo "$as_me:${as_lineno-$LINENO}: This might be caused by spaces in the path, which is not allowed." >&5 36188 $as_echo "$as_me: This might be caused by spaces in the path, which is not allowed." >&6;} 36189 fi 36190 as_fn_error $? "Cannot locate the the path of CXXCPP" "$LINENO" 5 36191 fi 36192 fi 36193 36194 # Now join together the path and the arguments once again 36195 if test "x$arguments" != xEOL; then 36196 new_complete="$new_path ${arguments% *}" 36197 else 36198 new_complete="$new_path" 36199 fi 36200 36201 if test "x$complete" != "x$new_complete"; then 36202 CXXCPP="$new_complete" 36203 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting CXXCPP to \"$new_complete\"" >&5 36204 $as_echo "$as_me: Rewriting CXXCPP to \"$new_complete\"" >&6;} 36205 fi 36206 fi 36207 36208 36209 # 36210 # Setup the linker (LD) 36211 # 36212 if test "x$TOOLCHAIN_TYPE" = xmicrosoft; then 36213 # In the Microsoft toolchain we have a separate LD command "link". 36214 # Make sure we reject /usr/bin/link (as determined in CYGWIN_LINK), which is 36215 # a cygwin program for something completely different. 36216 # Extract the first word of "link", so it can be a program name with args. 36217 set dummy link; ac_word=$2 36218 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 36219 $as_echo_n "checking for $ac_word... " >&6; } 36220 if ${ac_cv_prog_LD+:} false; then : 36221 $as_echo_n "(cached) " >&6 36222 else 36223 if test -n "$LD"; then 36224 ac_cv_prog_LD="$LD" # Let the user override the test. 36225 else 36226 ac_prog_rejected=no 36227 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 36228 for as_dir in $PATH 36229 do 36230 IFS=$as_save_IFS 36231 test -z "$as_dir" && as_dir=. 36232 for ac_exec_ext in '' $ac_executable_extensions; do 36233 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 36234 if test "$as_dir/$ac_word$ac_exec_ext" = "$CYGWIN_LINK"; then 36235 ac_prog_rejected=yes 36236 continue 36237 fi 36238 ac_cv_prog_LD="link" 36239 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 36240 break 2 36241 fi 36242 done 36243 done 36244 IFS=$as_save_IFS 36245 36246 if test $ac_prog_rejected = yes; then 36247 # We found a bogon in the path, so make sure we never use it. 36248 set dummy $ac_cv_prog_LD 36249 shift 36250 if test $# != 0; then 36251 # We chose a different compiler from the bogus one. 36252 # However, it has the same basename, so the bogon will be chosen 36253 # first if we set LD to just the basename; use the full file name. 36254 shift 36255 ac_cv_prog_LD="$as_dir/$ac_word${1+' '}$@" 36256 fi 36257 fi 36258 fi 36259 fi 36260 LD=$ac_cv_prog_LD 36261 if test -n "$LD"; then 36262 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $LD" >&5 36263 $as_echo "$LD" >&6; } 36264 else 36265 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 36266 $as_echo "no" >&6; } 36267 fi 36268 36269 36270 36271 # Only process if variable expands to non-empty 36272 36273 if test "x$LD" != x; then 36274 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 36275 36276 # First separate the path from the arguments. This will split at the first 36277 # space. 36278 complete="$LD" 36279 path="${complete%% *}" 36280 tmp="$complete EOL" 36281 arguments="${tmp#* }" 36282 36283 # Input might be given as Windows format, start by converting to 36284 # unix format. 36285 new_path=`$CYGPATH -u "$path"` 36286 36287 # Now try to locate executable using which 36288 new_path=`$WHICH "$new_path" 2> /dev/null` 36289 # bat and cmd files are not always considered executable in cygwin causing which 36290 # to not find them 36291 if test "x$new_path" = x \ 36292 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 36293 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 36294 new_path=`$CYGPATH -u "$path"` 36295 fi 36296 if test "x$new_path" = x; then 36297 # Oops. Which didn't find the executable. 36298 # The splitting of arguments from the executable at a space might have been incorrect, 36299 # since paths with space are more likely in Windows. Give it another try with the whole 36300 # argument. 36301 path="$complete" 36302 arguments="EOL" 36303 new_path=`$CYGPATH -u "$path"` 36304 new_path=`$WHICH "$new_path" 2> /dev/null` 36305 # bat and cmd files are not always considered executable in cygwin causing which 36306 # to not find them 36307 if test "x$new_path" = x \ 36308 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 36309 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 36310 new_path=`$CYGPATH -u "$path"` 36311 fi 36312 if test "x$new_path" = x; then 36313 # It's still not found. Now this is an unrecoverable error. 36314 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of LD, which resolves as \"$complete\", is not found." >&5 36315 $as_echo "$as_me: The path of LD, which resolves as \"$complete\", is not found." >&6;} 36316 has_space=`$ECHO "$complete" | $GREP " "` 36317 if test "x$has_space" != x; then 36318 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 36319 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 36320 fi 36321 as_fn_error $? "Cannot locate the the path of LD" "$LINENO" 5 36322 fi 36323 fi 36324 36325 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 36326 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 36327 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 36328 # "foo.exe" is OK but "foo" is an error. 36329 # 36330 # This test is therefore slightly more accurate than "test -f" to check for file presence. 36331 # It is also a way to make sure we got the proper file name for the real test later on. 36332 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 36333 if test "x$test_shortpath" = x; then 36334 # Short path failed, file does not exist as specified. 36335 # Try adding .exe or .cmd 36336 if test -f "${new_path}.exe"; then 36337 input_to_shortpath="${new_path}.exe" 36338 elif test -f "${new_path}.cmd"; then 36339 input_to_shortpath="${new_path}.cmd" 36340 else 36341 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of LD, which resolves as \"$new_path\", is invalid." >&5 36342 $as_echo "$as_me: The path of LD, which resolves as \"$new_path\", is invalid." >&6;} 36343 { $as_echo "$as_me:${as_lineno-$LINENO}: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&5 36344 $as_echo "$as_me: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&6;} 36345 as_fn_error $? "Cannot locate the the path of LD" "$LINENO" 5 36346 fi 36347 else 36348 input_to_shortpath="$new_path" 36349 fi 36350 36351 # Call helper function which possibly converts this using DOS-style short mode. 36352 # If so, the updated path is stored in $new_path. 36353 new_path="$input_to_shortpath" 36354 36355 input_path="$input_to_shortpath" 36356 # Check if we need to convert this using DOS-style short mode. If the path 36357 # contains just simple characters, use it. Otherwise (spaces, weird characters), 36358 # take no chances and rewrite it. 36359 # Note: m4 eats our [], so we need to use [ and ] instead. 36360 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 36361 if test "x$has_forbidden_chars" != x; then 36362 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 36363 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 36364 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 36365 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 36366 # Going to short mode and back again did indeed matter. Since short mode is 36367 # case insensitive, let's make it lowercase to improve readability. 36368 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 36369 # Now convert it back to Unix-style (cygpath) 36370 input_path=`$CYGPATH -u "$shortmode_path"` 36371 new_path="$input_path" 36372 fi 36373 fi 36374 36375 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 36376 if test "x$test_cygdrive_prefix" = x; then 36377 # As a simple fix, exclude /usr/bin since it's not a real path. 36378 if test "x`$ECHO $input_to_shortpath | $GREP ^/usr/bin/`" = x; then 36379 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 36380 # a path prefixed by /cygdrive for fixpath to work. 36381 new_path="$CYGWIN_ROOT_PATH$input_path" 36382 fi 36383 fi 36384 36385 # remove trailing .exe if any 36386 new_path="${new_path/%.exe/}" 36387 36388 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 36389 36390 # First separate the path from the arguments. This will split at the first 36391 # space. 36392 complete="$LD" 36393 path="${complete%% *}" 36394 tmp="$complete EOL" 36395 arguments="${tmp#* }" 36396 36397 # Input might be given as Windows format, start by converting to 36398 # unix format. 36399 new_path="$path" 36400 36401 windows_path="$new_path" 36402 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 36403 unix_path=`$CYGPATH -u "$windows_path"` 36404 new_path="$unix_path" 36405 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 36406 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 36407 new_path="$unix_path" 36408 fi 36409 36410 36411 # Now try to locate executable using which 36412 new_path=`$WHICH "$new_path" 2> /dev/null` 36413 36414 if test "x$new_path" = x; then 36415 # Oops. Which didn't find the executable. 36416 # The splitting of arguments from the executable at a space might have been incorrect, 36417 # since paths with space are more likely in Windows. Give it another try with the whole 36418 # argument. 36419 path="$complete" 36420 arguments="EOL" 36421 new_path="$path" 36422 36423 windows_path="$new_path" 36424 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 36425 unix_path=`$CYGPATH -u "$windows_path"` 36426 new_path="$unix_path" 36427 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 36428 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 36429 new_path="$unix_path" 36430 fi 36431 36432 36433 new_path=`$WHICH "$new_path" 2> /dev/null` 36434 # bat and cmd files are not always considered executable in MSYS causing which 36435 # to not find them 36436 if test "x$new_path" = x \ 36437 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 36438 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 36439 new_path="$path" 36440 36441 windows_path="$new_path" 36442 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 36443 unix_path=`$CYGPATH -u "$windows_path"` 36444 new_path="$unix_path" 36445 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 36446 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 36447 new_path="$unix_path" 36448 fi 36449 36450 fi 36451 36452 if test "x$new_path" = x; then 36453 # It's still not found. Now this is an unrecoverable error. 36454 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of LD, which resolves as \"$complete\", is not found." >&5 36455 $as_echo "$as_me: The path of LD, which resolves as \"$complete\", is not found." >&6;} 36456 has_space=`$ECHO "$complete" | $GREP " "` 36457 if test "x$has_space" != x; then 36458 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 36459 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 36460 fi 36461 as_fn_error $? "Cannot locate the the path of LD" "$LINENO" 5 36462 fi 36463 fi 36464 36465 # Now new_path has a complete unix path to the binary 36466 if test "x`$ECHO $new_path | $GREP ^/bin/`" != x; then 36467 # Keep paths in /bin as-is, but remove trailing .exe if any 36468 new_path="${new_path/%.exe/}" 36469 # Do not save /bin paths to all_fixpath_prefixes! 36470 else 36471 # Not in mixed or Windows style, start by that. 36472 new_path=`cmd //c echo $new_path` 36473 36474 input_path="$new_path" 36475 # Check if we need to convert this using DOS-style short mode. If the path 36476 # contains just simple characters, use it. Otherwise (spaces, weird characters), 36477 # take no chances and rewrite it. 36478 # Note: m4 eats our [], so we need to use [ and ] instead. 36479 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 36480 if test "x$has_forbidden_chars" != x; then 36481 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 36482 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 36483 fi 36484 36485 # Output is in $new_path 36486 36487 windows_path="$new_path" 36488 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 36489 unix_path=`$CYGPATH -u "$windows_path"` 36490 new_path="$unix_path" 36491 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 36492 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 36493 new_path="$unix_path" 36494 fi 36495 36496 # remove trailing .exe if any 36497 new_path="${new_path/%.exe/}" 36498 36499 # Save the first 10 bytes of this path to the storage, so fixpath can work. 36500 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 36501 fi 36502 36503 else 36504 # We're on a unix platform. Hooray! :) 36505 # First separate the path from the arguments. This will split at the first 36506 # space. 36507 complete="$LD" 36508 path="${complete%% *}" 36509 tmp="$complete EOL" 36510 arguments="${tmp#* }" 36511 36512 # Cannot rely on the command "which" here since it doesn't always work. 36513 is_absolute_path=`$ECHO "$path" | $GREP ^/` 36514 if test -z "$is_absolute_path"; then 36515 # Path to executable is not absolute. Find it. 36516 IFS_save="$IFS" 36517 IFS=: 36518 for p in $PATH; do 36519 if test -f "$p/$path" && test -x "$p/$path"; then 36520 new_path="$p/$path" 36521 break 36522 fi 36523 done 36524 IFS="$IFS_save" 36525 else 36526 # This is an absolute path, we can use it without further modifications. 36527 new_path="$path" 36528 fi 36529 36530 if test "x$new_path" = x; then 36531 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of LD, which resolves as \"$complete\", is not found." >&5 36532 $as_echo "$as_me: The path of LD, which resolves as \"$complete\", is not found." >&6;} 36533 has_space=`$ECHO "$complete" | $GREP " "` 36534 if test "x$has_space" != x; then 36535 { $as_echo "$as_me:${as_lineno-$LINENO}: This might be caused by spaces in the path, which is not allowed." >&5 36536 $as_echo "$as_me: This might be caused by spaces in the path, which is not allowed." >&6;} 36537 fi 36538 as_fn_error $? "Cannot locate the the path of LD" "$LINENO" 5 36539 fi 36540 fi 36541 36542 # Now join together the path and the arguments once again 36543 if test "x$arguments" != xEOL; then 36544 new_complete="$new_path ${arguments% *}" 36545 else 36546 new_complete="$new_path" 36547 fi 36548 36549 if test "x$complete" != "x$new_complete"; then 36550 LD="$new_complete" 36551 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting LD to \"$new_complete\"" >&5 36552 $as_echo "$as_me: Rewriting LD to \"$new_complete\"" >&6;} 36553 fi 36554 fi 36555 36556 # Verify that we indeed succeeded with this trick. 36557 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if the found link.exe is actually the Visual Studio linker" >&5 36558 $as_echo_n "checking if the found link.exe is actually the Visual Studio linker... " >&6; } 36559 "$LD" --version > /dev/null 36560 if test $? -eq 0 ; then 36561 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 36562 $as_echo "no" >&6; } 36563 as_fn_error $? "This is the Cygwin link tool. Please check your PATH and rerun configure." "$LINENO" 5 36564 else 36565 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 36566 $as_echo "yes" >&6; } 36567 fi 36568 LDCXX="$LD" 36569 else 36570 # All other toolchains use the compiler to link. 36571 LD="$CC" 36572 LDCXX="$CXX" 36573 fi 36574 36575 # FIXME: it should be CXXLD, according to standard (cf CXXCPP) 36576 36577 36578 # 36579 # Setup the assembler (AS) 36580 # 36581 if test "x$OPENJDK_TARGET_OS" = xsolaris; then 36582 36583 36584 # Publish this variable in the help. 36585 36586 36587 if [ -z "${AS+x}" ]; then 36588 # The variable is not set by user, try to locate tool using the code snippet 36589 for ac_prog in as 36590 do 36591 # Extract the first word of "$ac_prog", so it can be a program name with args. 36592 set dummy $ac_prog; ac_word=$2 36593 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 36594 $as_echo_n "checking for $ac_word... " >&6; } 36595 if ${ac_cv_path_AS+:} false; then : 36596 $as_echo_n "(cached) " >&6 36597 else 36598 case $AS in 36599 [\\/]* | ?:[\\/]*) 36600 ac_cv_path_AS="$AS" # Let the user override the test with a path. 36601 ;; 36602 *) 36603 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 36604 for as_dir in $PATH 36605 do 36606 IFS=$as_save_IFS 36607 test -z "$as_dir" && as_dir=. 36608 for ac_exec_ext in '' $ac_executable_extensions; do 36609 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 36610 ac_cv_path_AS="$as_dir/$ac_word$ac_exec_ext" 36611 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 36612 break 2 36613 fi 36614 done 36615 done 36616 IFS=$as_save_IFS 36617 36618 ;; 36619 esac 36620 fi 36621 AS=$ac_cv_path_AS 36622 if test -n "$AS"; then 36623 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $AS" >&5 36624 $as_echo "$AS" >&6; } 36625 else 36626 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 36627 $as_echo "no" >&6; } 36628 fi 36629 36630 36631 test -n "$AS" && break 36632 done 36633 36634 else 36635 # The variable is set, but is it from the command line or the environment? 36636 36637 # Try to remove the string !AS! from our list. 36638 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!AS!/} 36639 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 36640 # If it failed, the variable was not from the command line. Ignore it, 36641 # but warn the user (except for BASH, which is always set by the calling BASH). 36642 if test "xAS" != xBASH; then 36643 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of AS from the environment. Use command line variables instead." >&5 36644 $as_echo "$as_me: WARNING: Ignoring value of AS from the environment. Use command line variables instead." >&2;} 36645 fi 36646 # Try to locate tool using the code snippet 36647 for ac_prog in as 36648 do 36649 # Extract the first word of "$ac_prog", so it can be a program name with args. 36650 set dummy $ac_prog; ac_word=$2 36651 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 36652 $as_echo_n "checking for $ac_word... " >&6; } 36653 if ${ac_cv_path_AS+:} false; then : 36654 $as_echo_n "(cached) " >&6 36655 else 36656 case $AS in 36657 [\\/]* | ?:[\\/]*) 36658 ac_cv_path_AS="$AS" # Let the user override the test with a path. 36659 ;; 36660 *) 36661 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 36662 for as_dir in $PATH 36663 do 36664 IFS=$as_save_IFS 36665 test -z "$as_dir" && as_dir=. 36666 for ac_exec_ext in '' $ac_executable_extensions; do 36667 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 36668 ac_cv_path_AS="$as_dir/$ac_word$ac_exec_ext" 36669 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 36670 break 2 36671 fi 36672 done 36673 done 36674 IFS=$as_save_IFS 36675 36676 ;; 36677 esac 36678 fi 36679 AS=$ac_cv_path_AS 36680 if test -n "$AS"; then 36681 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $AS" >&5 36682 $as_echo "$AS" >&6; } 36683 else 36684 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 36685 $as_echo "no" >&6; } 36686 fi 36687 36688 36689 test -n "$AS" && break 36690 done 36691 36692 else 36693 # If it succeeded, then it was overridden by the user. We will use it 36694 # for the tool. 36695 36696 # First remove it from the list of overridden variables, so we can test 36697 # for unknown variables in the end. 36698 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 36699 36700 # Check if we try to supply an empty value 36701 if test "x$AS" = x; then 36702 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool AS= (no value)" >&5 36703 $as_echo "$as_me: Setting user supplied tool AS= (no value)" >&6;} 36704 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for AS" >&5 36705 $as_echo_n "checking for AS... " >&6; } 36706 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 36707 $as_echo "disabled" >&6; } 36708 else 36709 # Check if the provided tool contains a complete path. 36710 tool_specified="$AS" 36711 tool_basename="${tool_specified##*/}" 36712 if test "x$tool_basename" = "x$tool_specified"; then 36713 # A command without a complete path is provided, search $PATH. 36714 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool AS=$tool_basename" >&5 36715 $as_echo "$as_me: Will search for user supplied tool AS=$tool_basename" >&6;} 36716 # Extract the first word of "$tool_basename", so it can be a program name with args. 36717 set dummy $tool_basename; ac_word=$2 36718 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 36719 $as_echo_n "checking for $ac_word... " >&6; } 36720 if ${ac_cv_path_AS+:} false; then : 36721 $as_echo_n "(cached) " >&6 36722 else 36723 case $AS in 36724 [\\/]* | ?:[\\/]*) 36725 ac_cv_path_AS="$AS" # Let the user override the test with a path. 36726 ;; 36727 *) 36728 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 36729 for as_dir in $PATH 36730 do 36731 IFS=$as_save_IFS 36732 test -z "$as_dir" && as_dir=. 36733 for ac_exec_ext in '' $ac_executable_extensions; do 36734 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 36735 ac_cv_path_AS="$as_dir/$ac_word$ac_exec_ext" 36736 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 36737 break 2 36738 fi 36739 done 36740 done 36741 IFS=$as_save_IFS 36742 36743 ;; 36744 esac 36745 fi 36746 AS=$ac_cv_path_AS 36747 if test -n "$AS"; then 36748 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $AS" >&5 36749 $as_echo "$AS" >&6; } 36750 else 36751 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 36752 $as_echo "no" >&6; } 36753 fi 36754 36755 36756 if test "x$AS" = x; then 36757 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 36758 fi 36759 else 36760 # Otherwise we believe it is a complete path. Use it as it is. 36761 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool AS=$tool_specified" >&5 36762 $as_echo "$as_me: Will use user supplied tool AS=$tool_specified" >&6;} 36763 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for AS" >&5 36764 $as_echo_n "checking for AS... " >&6; } 36765 if test ! -x "$tool_specified"; then 36766 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 36767 $as_echo "not found" >&6; } 36768 as_fn_error $? "User supplied tool AS=$tool_specified does not exist or is not executable" "$LINENO" 5 36769 fi 36770 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 36771 $as_echo "$tool_specified" >&6; } 36772 fi 36773 fi 36774 fi 36775 36776 fi 36777 36778 36779 36780 # Only process if variable expands to non-empty 36781 36782 if test "x$AS" != x; then 36783 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 36784 36785 # First separate the path from the arguments. This will split at the first 36786 # space. 36787 complete="$AS" 36788 path="${complete%% *}" 36789 tmp="$complete EOL" 36790 arguments="${tmp#* }" 36791 36792 # Input might be given as Windows format, start by converting to 36793 # unix format. 36794 new_path=`$CYGPATH -u "$path"` 36795 36796 # Now try to locate executable using which 36797 new_path=`$WHICH "$new_path" 2> /dev/null` 36798 # bat and cmd files are not always considered executable in cygwin causing which 36799 # to not find them 36800 if test "x$new_path" = x \ 36801 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 36802 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 36803 new_path=`$CYGPATH -u "$path"` 36804 fi 36805 if test "x$new_path" = x; then 36806 # Oops. Which didn't find the executable. 36807 # The splitting of arguments from the executable at a space might have been incorrect, 36808 # since paths with space are more likely in Windows. Give it another try with the whole 36809 # argument. 36810 path="$complete" 36811 arguments="EOL" 36812 new_path=`$CYGPATH -u "$path"` 36813 new_path=`$WHICH "$new_path" 2> /dev/null` 36814 # bat and cmd files are not always considered executable in cygwin causing which 36815 # to not find them 36816 if test "x$new_path" = x \ 36817 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 36818 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 36819 new_path=`$CYGPATH -u "$path"` 36820 fi 36821 if test "x$new_path" = x; then 36822 # It's still not found. Now this is an unrecoverable error. 36823 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of AS, which resolves as \"$complete\", is not found." >&5 36824 $as_echo "$as_me: The path of AS, which resolves as \"$complete\", is not found." >&6;} 36825 has_space=`$ECHO "$complete" | $GREP " "` 36826 if test "x$has_space" != x; then 36827 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 36828 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 36829 fi 36830 as_fn_error $? "Cannot locate the the path of AS" "$LINENO" 5 36831 fi 36832 fi 36833 36834 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 36835 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 36836 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 36837 # "foo.exe" is OK but "foo" is an error. 36838 # 36839 # This test is therefore slightly more accurate than "test -f" to check for file presence. 36840 # It is also a way to make sure we got the proper file name for the real test later on. 36841 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 36842 if test "x$test_shortpath" = x; then 36843 # Short path failed, file does not exist as specified. 36844 # Try adding .exe or .cmd 36845 if test -f "${new_path}.exe"; then 36846 input_to_shortpath="${new_path}.exe" 36847 elif test -f "${new_path}.cmd"; then 36848 input_to_shortpath="${new_path}.cmd" 36849 else 36850 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of AS, which resolves as \"$new_path\", is invalid." >&5 36851 $as_echo "$as_me: The path of AS, which resolves as \"$new_path\", is invalid." >&6;} 36852 { $as_echo "$as_me:${as_lineno-$LINENO}: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&5 36853 $as_echo "$as_me: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&6;} 36854 as_fn_error $? "Cannot locate the the path of AS" "$LINENO" 5 36855 fi 36856 else 36857 input_to_shortpath="$new_path" 36858 fi 36859 36860 # Call helper function which possibly converts this using DOS-style short mode. 36861 # If so, the updated path is stored in $new_path. 36862 new_path="$input_to_shortpath" 36863 36864 input_path="$input_to_shortpath" 36865 # Check if we need to convert this using DOS-style short mode. If the path 36866 # contains just simple characters, use it. Otherwise (spaces, weird characters), 36867 # take no chances and rewrite it. 36868 # Note: m4 eats our [], so we need to use [ and ] instead. 36869 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 36870 if test "x$has_forbidden_chars" != x; then 36871 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 36872 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 36873 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 36874 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 36875 # Going to short mode and back again did indeed matter. Since short mode is 36876 # case insensitive, let's make it lowercase to improve readability. 36877 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 36878 # Now convert it back to Unix-style (cygpath) 36879 input_path=`$CYGPATH -u "$shortmode_path"` 36880 new_path="$input_path" 36881 fi 36882 fi 36883 36884 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 36885 if test "x$test_cygdrive_prefix" = x; then 36886 # As a simple fix, exclude /usr/bin since it's not a real path. 36887 if test "x`$ECHO $input_to_shortpath | $GREP ^/usr/bin/`" = x; then 36888 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 36889 # a path prefixed by /cygdrive for fixpath to work. 36890 new_path="$CYGWIN_ROOT_PATH$input_path" 36891 fi 36892 fi 36893 36894 # remove trailing .exe if any 36895 new_path="${new_path/%.exe/}" 36896 36897 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 36898 36899 # First separate the path from the arguments. This will split at the first 36900 # space. 36901 complete="$AS" 36902 path="${complete%% *}" 36903 tmp="$complete EOL" 36904 arguments="${tmp#* }" 36905 36906 # Input might be given as Windows format, start by converting to 36907 # unix format. 36908 new_path="$path" 36909 36910 windows_path="$new_path" 36911 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 36912 unix_path=`$CYGPATH -u "$windows_path"` 36913 new_path="$unix_path" 36914 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 36915 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 36916 new_path="$unix_path" 36917 fi 36918 36919 36920 # Now try to locate executable using which 36921 new_path=`$WHICH "$new_path" 2> /dev/null` 36922 36923 if test "x$new_path" = x; then 36924 # Oops. Which didn't find the executable. 36925 # The splitting of arguments from the executable at a space might have been incorrect, 36926 # since paths with space are more likely in Windows. Give it another try with the whole 36927 # argument. 36928 path="$complete" 36929 arguments="EOL" 36930 new_path="$path" 36931 36932 windows_path="$new_path" 36933 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 36934 unix_path=`$CYGPATH -u "$windows_path"` 36935 new_path="$unix_path" 36936 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 36937 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 36938 new_path="$unix_path" 36939 fi 36940 36941 36942 new_path=`$WHICH "$new_path" 2> /dev/null` 36943 # bat and cmd files are not always considered executable in MSYS causing which 36944 # to not find them 36945 if test "x$new_path" = x \ 36946 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 36947 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 36948 new_path="$path" 36949 36950 windows_path="$new_path" 36951 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 36952 unix_path=`$CYGPATH -u "$windows_path"` 36953 new_path="$unix_path" 36954 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 36955 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 36956 new_path="$unix_path" 36957 fi 36958 36959 fi 36960 36961 if test "x$new_path" = x; then 36962 # It's still not found. Now this is an unrecoverable error. 36963 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of AS, which resolves as \"$complete\", is not found." >&5 36964 $as_echo "$as_me: The path of AS, which resolves as \"$complete\", is not found." >&6;} 36965 has_space=`$ECHO "$complete" | $GREP " "` 36966 if test "x$has_space" != x; then 36967 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 36968 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 36969 fi 36970 as_fn_error $? "Cannot locate the the path of AS" "$LINENO" 5 36971 fi 36972 fi 36973 36974 # Now new_path has a complete unix path to the binary 36975 if test "x`$ECHO $new_path | $GREP ^/bin/`" != x; then 36976 # Keep paths in /bin as-is, but remove trailing .exe if any 36977 new_path="${new_path/%.exe/}" 36978 # Do not save /bin paths to all_fixpath_prefixes! 36979 else 36980 # Not in mixed or Windows style, start by that. 36981 new_path=`cmd //c echo $new_path` 36982 36983 input_path="$new_path" 36984 # Check if we need to convert this using DOS-style short mode. If the path 36985 # contains just simple characters, use it. Otherwise (spaces, weird characters), 36986 # take no chances and rewrite it. 36987 # Note: m4 eats our [], so we need to use [ and ] instead. 36988 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 36989 if test "x$has_forbidden_chars" != x; then 36990 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 36991 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 36992 fi 36993 36994 # Output is in $new_path 36995 36996 windows_path="$new_path" 36997 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 36998 unix_path=`$CYGPATH -u "$windows_path"` 36999 new_path="$unix_path" 37000 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 37001 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 37002 new_path="$unix_path" 37003 fi 37004 37005 # remove trailing .exe if any 37006 new_path="${new_path/%.exe/}" 37007 37008 # Save the first 10 bytes of this path to the storage, so fixpath can work. 37009 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 37010 fi 37011 37012 else 37013 # We're on a unix platform. Hooray! :) 37014 # First separate the path from the arguments. This will split at the first 37015 # space. 37016 complete="$AS" 37017 path="${complete%% *}" 37018 tmp="$complete EOL" 37019 arguments="${tmp#* }" 37020 37021 # Cannot rely on the command "which" here since it doesn't always work. 37022 is_absolute_path=`$ECHO "$path" | $GREP ^/` 37023 if test -z "$is_absolute_path"; then 37024 # Path to executable is not absolute. Find it. 37025 IFS_save="$IFS" 37026 IFS=: 37027 for p in $PATH; do 37028 if test -f "$p/$path" && test -x "$p/$path"; then 37029 new_path="$p/$path" 37030 break 37031 fi 37032 done 37033 IFS="$IFS_save" 37034 else 37035 # This is an absolute path, we can use it without further modifications. 37036 new_path="$path" 37037 fi 37038 37039 if test "x$new_path" = x; then 37040 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of AS, which resolves as \"$complete\", is not found." >&5 37041 $as_echo "$as_me: The path of AS, which resolves as \"$complete\", is not found." >&6;} 37042 has_space=`$ECHO "$complete" | $GREP " "` 37043 if test "x$has_space" != x; then 37044 { $as_echo "$as_me:${as_lineno-$LINENO}: This might be caused by spaces in the path, which is not allowed." >&5 37045 $as_echo "$as_me: This might be caused by spaces in the path, which is not allowed." >&6;} 37046 fi 37047 as_fn_error $? "Cannot locate the the path of AS" "$LINENO" 5 37048 fi 37049 fi 37050 37051 # Now join together the path and the arguments once again 37052 if test "x$arguments" != xEOL; then 37053 new_complete="$new_path ${arguments% *}" 37054 else 37055 new_complete="$new_path" 37056 fi 37057 37058 if test "x$complete" != "x$new_complete"; then 37059 AS="$new_complete" 37060 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting AS to \"$new_complete\"" >&5 37061 $as_echo "$as_me: Rewriting AS to \"$new_complete\"" >&6;} 37062 fi 37063 fi 37064 37065 if test "x$AS" = x; then 37066 as_fn_error $? "Solaris assembler (as) is required. Please install via \"pkg install pkg:/developer/assembler\"." "$LINENO" 5 37067 fi 37068 else 37069 # FIXME: is this correct for microsoft? 37070 AS="$CC -c" 37071 fi 37072 37073 37074 # 37075 # Setup the archiver (AR) 37076 # 37077 if test "x$TOOLCHAIN_TYPE" = xmicrosoft; then 37078 # The corresponding ar tool is lib.exe (used to create static libraries) 37079 # Extract the first word of "lib", so it can be a program name with args. 37080 set dummy lib; ac_word=$2 37081 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 37082 $as_echo_n "checking for $ac_word... " >&6; } 37083 if ${ac_cv_prog_AR+:} false; then : 37084 $as_echo_n "(cached) " >&6 37085 else 37086 if test -n "$AR"; then 37087 ac_cv_prog_AR="$AR" # Let the user override the test. 37088 else 37089 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 37090 for as_dir in $PATH 37091 do 37092 IFS=$as_save_IFS 37093 test -z "$as_dir" && as_dir=. 37094 for ac_exec_ext in '' $ac_executable_extensions; do 37095 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 37096 ac_cv_prog_AR="lib" 37097 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 37098 break 2 37099 fi 37100 done 37101 done 37102 IFS=$as_save_IFS 37103 37104 fi 37105 fi 37106 AR=$ac_cv_prog_AR 37107 if test -n "$AR"; then 37108 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $AR" >&5 37109 $as_echo "$AR" >&6; } 37110 else 37111 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 37112 $as_echo "no" >&6; } 37113 fi 37114 37115 37116 elif test "x$TOOLCHAIN_TYPE" = xgcc; then 37117 37118 37119 # Publish this variable in the help. 37120 37121 37122 if [ -z "${AR+x}" ]; then 37123 # The variable is not set by user, try to locate tool using the code snippet 37124 if test -n "$ac_tool_prefix"; then 37125 for ac_prog in ar gcc-ar 37126 do 37127 # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args. 37128 set dummy $ac_tool_prefix$ac_prog; ac_word=$2 37129 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 37130 $as_echo_n "checking for $ac_word... " >&6; } 37131 if ${ac_cv_prog_AR+:} false; then : 37132 $as_echo_n "(cached) " >&6 37133 else 37134 if test -n "$AR"; then 37135 ac_cv_prog_AR="$AR" # Let the user override the test. 37136 else 37137 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 37138 for as_dir in $PATH 37139 do 37140 IFS=$as_save_IFS 37141 test -z "$as_dir" && as_dir=. 37142 for ac_exec_ext in '' $ac_executable_extensions; do 37143 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 37144 ac_cv_prog_AR="$ac_tool_prefix$ac_prog" 37145 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 37146 break 2 37147 fi 37148 done 37149 done 37150 IFS=$as_save_IFS 37151 37152 fi 37153 fi 37154 AR=$ac_cv_prog_AR 37155 if test -n "$AR"; then 37156 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $AR" >&5 37157 $as_echo "$AR" >&6; } 37158 else 37159 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 37160 $as_echo "no" >&6; } 37161 fi 37162 37163 37164 test -n "$AR" && break 37165 done 37166 fi 37167 if test -z "$AR"; then 37168 ac_ct_AR=$AR 37169 for ac_prog in ar gcc-ar 37170 do 37171 # Extract the first word of "$ac_prog", so it can be a program name with args. 37172 set dummy $ac_prog; ac_word=$2 37173 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 37174 $as_echo_n "checking for $ac_word... " >&6; } 37175 if ${ac_cv_prog_ac_ct_AR+:} false; then : 37176 $as_echo_n "(cached) " >&6 37177 else 37178 if test -n "$ac_ct_AR"; then 37179 ac_cv_prog_ac_ct_AR="$ac_ct_AR" # Let the user override the test. 37180 else 37181 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 37182 for as_dir in $PATH 37183 do 37184 IFS=$as_save_IFS 37185 test -z "$as_dir" && as_dir=. 37186 for ac_exec_ext in '' $ac_executable_extensions; do 37187 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 37188 ac_cv_prog_ac_ct_AR="$ac_prog" 37189 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 37190 break 2 37191 fi 37192 done 37193 done 37194 IFS=$as_save_IFS 37195 37196 fi 37197 fi 37198 ac_ct_AR=$ac_cv_prog_ac_ct_AR 37199 if test -n "$ac_ct_AR"; then 37200 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_AR" >&5 37201 $as_echo "$ac_ct_AR" >&6; } 37202 else 37203 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 37204 $as_echo "no" >&6; } 37205 fi 37206 37207 37208 test -n "$ac_ct_AR" && break 37209 done 37210 37211 if test "x$ac_ct_AR" = x; then 37212 AR="" 37213 else 37214 case $cross_compiling:$ac_tool_warned in 37215 yes:) 37216 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5 37217 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;} 37218 ac_tool_warned=yes ;; 37219 esac 37220 AR=$ac_ct_AR 37221 fi 37222 fi 37223 37224 else 37225 # The variable is set, but is it from the command line or the environment? 37226 37227 # Try to remove the string !AR! from our list. 37228 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!AR!/} 37229 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 37230 # If it failed, the variable was not from the command line. Ignore it, 37231 # but warn the user (except for BASH, which is always set by the calling BASH). 37232 if test "xAR" != xBASH; then 37233 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of AR from the environment. Use command line variables instead." >&5 37234 $as_echo "$as_me: WARNING: Ignoring value of AR from the environment. Use command line variables instead." >&2;} 37235 fi 37236 # Try to locate tool using the code snippet 37237 if test -n "$ac_tool_prefix"; then 37238 for ac_prog in ar gcc-ar 37239 do 37240 # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args. 37241 set dummy $ac_tool_prefix$ac_prog; ac_word=$2 37242 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 37243 $as_echo_n "checking for $ac_word... " >&6; } 37244 if ${ac_cv_prog_AR+:} false; then : 37245 $as_echo_n "(cached) " >&6 37246 else 37247 if test -n "$AR"; then 37248 ac_cv_prog_AR="$AR" # Let the user override the test. 37249 else 37250 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 37251 for as_dir in $PATH 37252 do 37253 IFS=$as_save_IFS 37254 test -z "$as_dir" && as_dir=. 37255 for ac_exec_ext in '' $ac_executable_extensions; do 37256 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 37257 ac_cv_prog_AR="$ac_tool_prefix$ac_prog" 37258 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 37259 break 2 37260 fi 37261 done 37262 done 37263 IFS=$as_save_IFS 37264 37265 fi 37266 fi 37267 AR=$ac_cv_prog_AR 37268 if test -n "$AR"; then 37269 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $AR" >&5 37270 $as_echo "$AR" >&6; } 37271 else 37272 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 37273 $as_echo "no" >&6; } 37274 fi 37275 37276 37277 test -n "$AR" && break 37278 done 37279 fi 37280 if test -z "$AR"; then 37281 ac_ct_AR=$AR 37282 for ac_prog in ar gcc-ar 37283 do 37284 # Extract the first word of "$ac_prog", so it can be a program name with args. 37285 set dummy $ac_prog; ac_word=$2 37286 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 37287 $as_echo_n "checking for $ac_word... " >&6; } 37288 if ${ac_cv_prog_ac_ct_AR+:} false; then : 37289 $as_echo_n "(cached) " >&6 37290 else 37291 if test -n "$ac_ct_AR"; then 37292 ac_cv_prog_ac_ct_AR="$ac_ct_AR" # Let the user override the test. 37293 else 37294 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 37295 for as_dir in $PATH 37296 do 37297 IFS=$as_save_IFS 37298 test -z "$as_dir" && as_dir=. 37299 for ac_exec_ext in '' $ac_executable_extensions; do 37300 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 37301 ac_cv_prog_ac_ct_AR="$ac_prog" 37302 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 37303 break 2 37304 fi 37305 done 37306 done 37307 IFS=$as_save_IFS 37308 37309 fi 37310 fi 37311 ac_ct_AR=$ac_cv_prog_ac_ct_AR 37312 if test -n "$ac_ct_AR"; then 37313 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_AR" >&5 37314 $as_echo "$ac_ct_AR" >&6; } 37315 else 37316 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 37317 $as_echo "no" >&6; } 37318 fi 37319 37320 37321 test -n "$ac_ct_AR" && break 37322 done 37323 37324 if test "x$ac_ct_AR" = x; then 37325 AR="" 37326 else 37327 case $cross_compiling:$ac_tool_warned in 37328 yes:) 37329 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5 37330 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;} 37331 ac_tool_warned=yes ;; 37332 esac 37333 AR=$ac_ct_AR 37334 fi 37335 fi 37336 37337 else 37338 # If it succeeded, then it was overridden by the user. We will use it 37339 # for the tool. 37340 37341 # First remove it from the list of overridden variables, so we can test 37342 # for unknown variables in the end. 37343 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 37344 37345 # Check if we try to supply an empty value 37346 if test "x$AR" = x; then 37347 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool AR= (no value)" >&5 37348 $as_echo "$as_me: Setting user supplied tool AR= (no value)" >&6;} 37349 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for AR" >&5 37350 $as_echo_n "checking for AR... " >&6; } 37351 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 37352 $as_echo "disabled" >&6; } 37353 else 37354 # Check if the provided tool contains a complete path. 37355 tool_specified="$AR" 37356 tool_basename="${tool_specified##*/}" 37357 if test "x$tool_basename" = "x$tool_specified"; then 37358 # A command without a complete path is provided, search $PATH. 37359 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool AR=$tool_basename" >&5 37360 $as_echo "$as_me: Will search for user supplied tool AR=$tool_basename" >&6;} 37361 # Extract the first word of "$tool_basename", so it can be a program name with args. 37362 set dummy $tool_basename; ac_word=$2 37363 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 37364 $as_echo_n "checking for $ac_word... " >&6; } 37365 if ${ac_cv_path_AR+:} false; then : 37366 $as_echo_n "(cached) " >&6 37367 else 37368 case $AR in 37369 [\\/]* | ?:[\\/]*) 37370 ac_cv_path_AR="$AR" # Let the user override the test with a path. 37371 ;; 37372 *) 37373 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 37374 for as_dir in $PATH 37375 do 37376 IFS=$as_save_IFS 37377 test -z "$as_dir" && as_dir=. 37378 for ac_exec_ext in '' $ac_executable_extensions; do 37379 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 37380 ac_cv_path_AR="$as_dir/$ac_word$ac_exec_ext" 37381 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 37382 break 2 37383 fi 37384 done 37385 done 37386 IFS=$as_save_IFS 37387 37388 ;; 37389 esac 37390 fi 37391 AR=$ac_cv_path_AR 37392 if test -n "$AR"; then 37393 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $AR" >&5 37394 $as_echo "$AR" >&6; } 37395 else 37396 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 37397 $as_echo "no" >&6; } 37398 fi 37399 37400 37401 if test "x$AR" = x; then 37402 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 37403 fi 37404 else 37405 # Otherwise we believe it is a complete path. Use it as it is. 37406 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool AR=$tool_specified" >&5 37407 $as_echo "$as_me: Will use user supplied tool AR=$tool_specified" >&6;} 37408 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for AR" >&5 37409 $as_echo_n "checking for AR... " >&6; } 37410 if test ! -x "$tool_specified"; then 37411 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 37412 $as_echo "not found" >&6; } 37413 as_fn_error $? "User supplied tool AR=$tool_specified does not exist or is not executable" "$LINENO" 5 37414 fi 37415 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 37416 $as_echo "$tool_specified" >&6; } 37417 fi 37418 fi 37419 fi 37420 37421 fi 37422 37423 37424 else 37425 37426 37427 # Publish this variable in the help. 37428 37429 37430 if [ -z "${AR+x}" ]; then 37431 # The variable is not set by user, try to locate tool using the code snippet 37432 if test -n "$ac_tool_prefix"; then 37433 for ac_prog in ar 37434 do 37435 # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args. 37436 set dummy $ac_tool_prefix$ac_prog; ac_word=$2 37437 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 37438 $as_echo_n "checking for $ac_word... " >&6; } 37439 if ${ac_cv_prog_AR+:} false; then : 37440 $as_echo_n "(cached) " >&6 37441 else 37442 if test -n "$AR"; then 37443 ac_cv_prog_AR="$AR" # Let the user override the test. 37444 else 37445 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 37446 for as_dir in $PATH 37447 do 37448 IFS=$as_save_IFS 37449 test -z "$as_dir" && as_dir=. 37450 for ac_exec_ext in '' $ac_executable_extensions; do 37451 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 37452 ac_cv_prog_AR="$ac_tool_prefix$ac_prog" 37453 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 37454 break 2 37455 fi 37456 done 37457 done 37458 IFS=$as_save_IFS 37459 37460 fi 37461 fi 37462 AR=$ac_cv_prog_AR 37463 if test -n "$AR"; then 37464 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $AR" >&5 37465 $as_echo "$AR" >&6; } 37466 else 37467 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 37468 $as_echo "no" >&6; } 37469 fi 37470 37471 37472 test -n "$AR" && break 37473 done 37474 fi 37475 if test -z "$AR"; then 37476 ac_ct_AR=$AR 37477 for ac_prog in ar 37478 do 37479 # Extract the first word of "$ac_prog", so it can be a program name with args. 37480 set dummy $ac_prog; ac_word=$2 37481 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 37482 $as_echo_n "checking for $ac_word... " >&6; } 37483 if ${ac_cv_prog_ac_ct_AR+:} false; then : 37484 $as_echo_n "(cached) " >&6 37485 else 37486 if test -n "$ac_ct_AR"; then 37487 ac_cv_prog_ac_ct_AR="$ac_ct_AR" # Let the user override the test. 37488 else 37489 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 37490 for as_dir in $PATH 37491 do 37492 IFS=$as_save_IFS 37493 test -z "$as_dir" && as_dir=. 37494 for ac_exec_ext in '' $ac_executable_extensions; do 37495 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 37496 ac_cv_prog_ac_ct_AR="$ac_prog" 37497 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 37498 break 2 37499 fi 37500 done 37501 done 37502 IFS=$as_save_IFS 37503 37504 fi 37505 fi 37506 ac_ct_AR=$ac_cv_prog_ac_ct_AR 37507 if test -n "$ac_ct_AR"; then 37508 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_AR" >&5 37509 $as_echo "$ac_ct_AR" >&6; } 37510 else 37511 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 37512 $as_echo "no" >&6; } 37513 fi 37514 37515 37516 test -n "$ac_ct_AR" && break 37517 done 37518 37519 if test "x$ac_ct_AR" = x; then 37520 AR="" 37521 else 37522 case $cross_compiling:$ac_tool_warned in 37523 yes:) 37524 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5 37525 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;} 37526 ac_tool_warned=yes ;; 37527 esac 37528 AR=$ac_ct_AR 37529 fi 37530 fi 37531 37532 else 37533 # The variable is set, but is it from the command line or the environment? 37534 37535 # Try to remove the string !AR! from our list. 37536 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!AR!/} 37537 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 37538 # If it failed, the variable was not from the command line. Ignore it, 37539 # but warn the user (except for BASH, which is always set by the calling BASH). 37540 if test "xAR" != xBASH; then 37541 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of AR from the environment. Use command line variables instead." >&5 37542 $as_echo "$as_me: WARNING: Ignoring value of AR from the environment. Use command line variables instead." >&2;} 37543 fi 37544 # Try to locate tool using the code snippet 37545 if test -n "$ac_tool_prefix"; then 37546 for ac_prog in ar 37547 do 37548 # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args. 37549 set dummy $ac_tool_prefix$ac_prog; ac_word=$2 37550 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 37551 $as_echo_n "checking for $ac_word... " >&6; } 37552 if ${ac_cv_prog_AR+:} false; then : 37553 $as_echo_n "(cached) " >&6 37554 else 37555 if test -n "$AR"; then 37556 ac_cv_prog_AR="$AR" # Let the user override the test. 37557 else 37558 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 37559 for as_dir in $PATH 37560 do 37561 IFS=$as_save_IFS 37562 test -z "$as_dir" && as_dir=. 37563 for ac_exec_ext in '' $ac_executable_extensions; do 37564 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 37565 ac_cv_prog_AR="$ac_tool_prefix$ac_prog" 37566 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 37567 break 2 37568 fi 37569 done 37570 done 37571 IFS=$as_save_IFS 37572 37573 fi 37574 fi 37575 AR=$ac_cv_prog_AR 37576 if test -n "$AR"; then 37577 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $AR" >&5 37578 $as_echo "$AR" >&6; } 37579 else 37580 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 37581 $as_echo "no" >&6; } 37582 fi 37583 37584 37585 test -n "$AR" && break 37586 done 37587 fi 37588 if test -z "$AR"; then 37589 ac_ct_AR=$AR 37590 for ac_prog in ar 37591 do 37592 # Extract the first word of "$ac_prog", so it can be a program name with args. 37593 set dummy $ac_prog; ac_word=$2 37594 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 37595 $as_echo_n "checking for $ac_word... " >&6; } 37596 if ${ac_cv_prog_ac_ct_AR+:} false; then : 37597 $as_echo_n "(cached) " >&6 37598 else 37599 if test -n "$ac_ct_AR"; then 37600 ac_cv_prog_ac_ct_AR="$ac_ct_AR" # Let the user override the test. 37601 else 37602 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 37603 for as_dir in $PATH 37604 do 37605 IFS=$as_save_IFS 37606 test -z "$as_dir" && as_dir=. 37607 for ac_exec_ext in '' $ac_executable_extensions; do 37608 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 37609 ac_cv_prog_ac_ct_AR="$ac_prog" 37610 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 37611 break 2 37612 fi 37613 done 37614 done 37615 IFS=$as_save_IFS 37616 37617 fi 37618 fi 37619 ac_ct_AR=$ac_cv_prog_ac_ct_AR 37620 if test -n "$ac_ct_AR"; then 37621 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_AR" >&5 37622 $as_echo "$ac_ct_AR" >&6; } 37623 else 37624 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 37625 $as_echo "no" >&6; } 37626 fi 37627 37628 37629 test -n "$ac_ct_AR" && break 37630 done 37631 37632 if test "x$ac_ct_AR" = x; then 37633 AR="" 37634 else 37635 case $cross_compiling:$ac_tool_warned in 37636 yes:) 37637 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5 37638 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;} 37639 ac_tool_warned=yes ;; 37640 esac 37641 AR=$ac_ct_AR 37642 fi 37643 fi 37644 37645 else 37646 # If it succeeded, then it was overridden by the user. We will use it 37647 # for the tool. 37648 37649 # First remove it from the list of overridden variables, so we can test 37650 # for unknown variables in the end. 37651 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 37652 37653 # Check if we try to supply an empty value 37654 if test "x$AR" = x; then 37655 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool AR= (no value)" >&5 37656 $as_echo "$as_me: Setting user supplied tool AR= (no value)" >&6;} 37657 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for AR" >&5 37658 $as_echo_n "checking for AR... " >&6; } 37659 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 37660 $as_echo "disabled" >&6; } 37661 else 37662 # Check if the provided tool contains a complete path. 37663 tool_specified="$AR" 37664 tool_basename="${tool_specified##*/}" 37665 if test "x$tool_basename" = "x$tool_specified"; then 37666 # A command without a complete path is provided, search $PATH. 37667 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool AR=$tool_basename" >&5 37668 $as_echo "$as_me: Will search for user supplied tool AR=$tool_basename" >&6;} 37669 # Extract the first word of "$tool_basename", so it can be a program name with args. 37670 set dummy $tool_basename; ac_word=$2 37671 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 37672 $as_echo_n "checking for $ac_word... " >&6; } 37673 if ${ac_cv_path_AR+:} false; then : 37674 $as_echo_n "(cached) " >&6 37675 else 37676 case $AR in 37677 [\\/]* | ?:[\\/]*) 37678 ac_cv_path_AR="$AR" # Let the user override the test with a path. 37679 ;; 37680 *) 37681 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 37682 for as_dir in $PATH 37683 do 37684 IFS=$as_save_IFS 37685 test -z "$as_dir" && as_dir=. 37686 for ac_exec_ext in '' $ac_executable_extensions; do 37687 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 37688 ac_cv_path_AR="$as_dir/$ac_word$ac_exec_ext" 37689 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 37690 break 2 37691 fi 37692 done 37693 done 37694 IFS=$as_save_IFS 37695 37696 ;; 37697 esac 37698 fi 37699 AR=$ac_cv_path_AR 37700 if test -n "$AR"; then 37701 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $AR" >&5 37702 $as_echo "$AR" >&6; } 37703 else 37704 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 37705 $as_echo "no" >&6; } 37706 fi 37707 37708 37709 if test "x$AR" = x; then 37710 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 37711 fi 37712 else 37713 # Otherwise we believe it is a complete path. Use it as it is. 37714 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool AR=$tool_specified" >&5 37715 $as_echo "$as_me: Will use user supplied tool AR=$tool_specified" >&6;} 37716 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for AR" >&5 37717 $as_echo_n "checking for AR... " >&6; } 37718 if test ! -x "$tool_specified"; then 37719 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 37720 $as_echo "not found" >&6; } 37721 as_fn_error $? "User supplied tool AR=$tool_specified does not exist or is not executable" "$LINENO" 5 37722 fi 37723 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 37724 $as_echo "$tool_specified" >&6; } 37725 fi 37726 fi 37727 fi 37728 37729 fi 37730 37731 37732 fi 37733 37734 # Only process if variable expands to non-empty 37735 37736 if test "x$AR" != x; then 37737 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 37738 37739 # First separate the path from the arguments. This will split at the first 37740 # space. 37741 complete="$AR" 37742 path="${complete%% *}" 37743 tmp="$complete EOL" 37744 arguments="${tmp#* }" 37745 37746 # Input might be given as Windows format, start by converting to 37747 # unix format. 37748 new_path=`$CYGPATH -u "$path"` 37749 37750 # Now try to locate executable using which 37751 new_path=`$WHICH "$new_path" 2> /dev/null` 37752 # bat and cmd files are not always considered executable in cygwin causing which 37753 # to not find them 37754 if test "x$new_path" = x \ 37755 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 37756 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 37757 new_path=`$CYGPATH -u "$path"` 37758 fi 37759 if test "x$new_path" = x; then 37760 # Oops. Which didn't find the executable. 37761 # The splitting of arguments from the executable at a space might have been incorrect, 37762 # since paths with space are more likely in Windows. Give it another try with the whole 37763 # argument. 37764 path="$complete" 37765 arguments="EOL" 37766 new_path=`$CYGPATH -u "$path"` 37767 new_path=`$WHICH "$new_path" 2> /dev/null` 37768 # bat and cmd files are not always considered executable in cygwin causing which 37769 # to not find them 37770 if test "x$new_path" = x \ 37771 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 37772 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 37773 new_path=`$CYGPATH -u "$path"` 37774 fi 37775 if test "x$new_path" = x; then 37776 # It's still not found. Now this is an unrecoverable error. 37777 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of AR, which resolves as \"$complete\", is not found." >&5 37778 $as_echo "$as_me: The path of AR, which resolves as \"$complete\", is not found." >&6;} 37779 has_space=`$ECHO "$complete" | $GREP " "` 37780 if test "x$has_space" != x; then 37781 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 37782 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 37783 fi 37784 as_fn_error $? "Cannot locate the the path of AR" "$LINENO" 5 37785 fi 37786 fi 37787 37788 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 37789 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 37790 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 37791 # "foo.exe" is OK but "foo" is an error. 37792 # 37793 # This test is therefore slightly more accurate than "test -f" to check for file presence. 37794 # It is also a way to make sure we got the proper file name for the real test later on. 37795 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 37796 if test "x$test_shortpath" = x; then 37797 # Short path failed, file does not exist as specified. 37798 # Try adding .exe or .cmd 37799 if test -f "${new_path}.exe"; then 37800 input_to_shortpath="${new_path}.exe" 37801 elif test -f "${new_path}.cmd"; then 37802 input_to_shortpath="${new_path}.cmd" 37803 else 37804 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of AR, which resolves as \"$new_path\", is invalid." >&5 37805 $as_echo "$as_me: The path of AR, which resolves as \"$new_path\", is invalid." >&6;} 37806 { $as_echo "$as_me:${as_lineno-$LINENO}: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&5 37807 $as_echo "$as_me: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&6;} 37808 as_fn_error $? "Cannot locate the the path of AR" "$LINENO" 5 37809 fi 37810 else 37811 input_to_shortpath="$new_path" 37812 fi 37813 37814 # Call helper function which possibly converts this using DOS-style short mode. 37815 # If so, the updated path is stored in $new_path. 37816 new_path="$input_to_shortpath" 37817 37818 input_path="$input_to_shortpath" 37819 # Check if we need to convert this using DOS-style short mode. If the path 37820 # contains just simple characters, use it. Otherwise (spaces, weird characters), 37821 # take no chances and rewrite it. 37822 # Note: m4 eats our [], so we need to use [ and ] instead. 37823 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 37824 if test "x$has_forbidden_chars" != x; then 37825 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 37826 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 37827 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 37828 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 37829 # Going to short mode and back again did indeed matter. Since short mode is 37830 # case insensitive, let's make it lowercase to improve readability. 37831 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 37832 # Now convert it back to Unix-style (cygpath) 37833 input_path=`$CYGPATH -u "$shortmode_path"` 37834 new_path="$input_path" 37835 fi 37836 fi 37837 37838 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 37839 if test "x$test_cygdrive_prefix" = x; then 37840 # As a simple fix, exclude /usr/bin since it's not a real path. 37841 if test "x`$ECHO $input_to_shortpath | $GREP ^/usr/bin/`" = x; then 37842 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 37843 # a path prefixed by /cygdrive for fixpath to work. 37844 new_path="$CYGWIN_ROOT_PATH$input_path" 37845 fi 37846 fi 37847 37848 # remove trailing .exe if any 37849 new_path="${new_path/%.exe/}" 37850 37851 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 37852 37853 # First separate the path from the arguments. This will split at the first 37854 # space. 37855 complete="$AR" 37856 path="${complete%% *}" 37857 tmp="$complete EOL" 37858 arguments="${tmp#* }" 37859 37860 # Input might be given as Windows format, start by converting to 37861 # unix format. 37862 new_path="$path" 37863 37864 windows_path="$new_path" 37865 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 37866 unix_path=`$CYGPATH -u "$windows_path"` 37867 new_path="$unix_path" 37868 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 37869 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 37870 new_path="$unix_path" 37871 fi 37872 37873 37874 # Now try to locate executable using which 37875 new_path=`$WHICH "$new_path" 2> /dev/null` 37876 37877 if test "x$new_path" = x; then 37878 # Oops. Which didn't find the executable. 37879 # The splitting of arguments from the executable at a space might have been incorrect, 37880 # since paths with space are more likely in Windows. Give it another try with the whole 37881 # argument. 37882 path="$complete" 37883 arguments="EOL" 37884 new_path="$path" 37885 37886 windows_path="$new_path" 37887 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 37888 unix_path=`$CYGPATH -u "$windows_path"` 37889 new_path="$unix_path" 37890 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 37891 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 37892 new_path="$unix_path" 37893 fi 37894 37895 37896 new_path=`$WHICH "$new_path" 2> /dev/null` 37897 # bat and cmd files are not always considered executable in MSYS causing which 37898 # to not find them 37899 if test "x$new_path" = x \ 37900 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 37901 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 37902 new_path="$path" 37903 37904 windows_path="$new_path" 37905 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 37906 unix_path=`$CYGPATH -u "$windows_path"` 37907 new_path="$unix_path" 37908 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 37909 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 37910 new_path="$unix_path" 37911 fi 37912 37913 fi 37914 37915 if test "x$new_path" = x; then 37916 # It's still not found. Now this is an unrecoverable error. 37917 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of AR, which resolves as \"$complete\", is not found." >&5 37918 $as_echo "$as_me: The path of AR, which resolves as \"$complete\", is not found." >&6;} 37919 has_space=`$ECHO "$complete" | $GREP " "` 37920 if test "x$has_space" != x; then 37921 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 37922 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 37923 fi 37924 as_fn_error $? "Cannot locate the the path of AR" "$LINENO" 5 37925 fi 37926 fi 37927 37928 # Now new_path has a complete unix path to the binary 37929 if test "x`$ECHO $new_path | $GREP ^/bin/`" != x; then 37930 # Keep paths in /bin as-is, but remove trailing .exe if any 37931 new_path="${new_path/%.exe/}" 37932 # Do not save /bin paths to all_fixpath_prefixes! 37933 else 37934 # Not in mixed or Windows style, start by that. 37935 new_path=`cmd //c echo $new_path` 37936 37937 input_path="$new_path" 37938 # Check if we need to convert this using DOS-style short mode. If the path 37939 # contains just simple characters, use it. Otherwise (spaces, weird characters), 37940 # take no chances and rewrite it. 37941 # Note: m4 eats our [], so we need to use [ and ] instead. 37942 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 37943 if test "x$has_forbidden_chars" != x; then 37944 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 37945 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 37946 fi 37947 37948 # Output is in $new_path 37949 37950 windows_path="$new_path" 37951 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 37952 unix_path=`$CYGPATH -u "$windows_path"` 37953 new_path="$unix_path" 37954 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 37955 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 37956 new_path="$unix_path" 37957 fi 37958 37959 # remove trailing .exe if any 37960 new_path="${new_path/%.exe/}" 37961 37962 # Save the first 10 bytes of this path to the storage, so fixpath can work. 37963 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 37964 fi 37965 37966 else 37967 # We're on a unix platform. Hooray! :) 37968 # First separate the path from the arguments. This will split at the first 37969 # space. 37970 complete="$AR" 37971 path="${complete%% *}" 37972 tmp="$complete EOL" 37973 arguments="${tmp#* }" 37974 37975 # Cannot rely on the command "which" here since it doesn't always work. 37976 is_absolute_path=`$ECHO "$path" | $GREP ^/` 37977 if test -z "$is_absolute_path"; then 37978 # Path to executable is not absolute. Find it. 37979 IFS_save="$IFS" 37980 IFS=: 37981 for p in $PATH; do 37982 if test -f "$p/$path" && test -x "$p/$path"; then 37983 new_path="$p/$path" 37984 break 37985 fi 37986 done 37987 IFS="$IFS_save" 37988 else 37989 # This is an absolute path, we can use it without further modifications. 37990 new_path="$path" 37991 fi 37992 37993 if test "x$new_path" = x; then 37994 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of AR, which resolves as \"$complete\", is not found." >&5 37995 $as_echo "$as_me: The path of AR, which resolves as \"$complete\", is not found." >&6;} 37996 has_space=`$ECHO "$complete" | $GREP " "` 37997 if test "x$has_space" != x; then 37998 { $as_echo "$as_me:${as_lineno-$LINENO}: This might be caused by spaces in the path, which is not allowed." >&5 37999 $as_echo "$as_me: This might be caused by spaces in the path, which is not allowed." >&6;} 38000 fi 38001 as_fn_error $? "Cannot locate the the path of AR" "$LINENO" 5 38002 fi 38003 fi 38004 38005 # Now join together the path and the arguments once again 38006 if test "x$arguments" != xEOL; then 38007 new_complete="$new_path ${arguments% *}" 38008 else 38009 new_complete="$new_path" 38010 fi 38011 38012 if test "x$complete" != "x$new_complete"; then 38013 AR="$new_complete" 38014 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting AR to \"$new_complete\"" >&5 38015 $as_echo "$as_me: Rewriting AR to \"$new_complete\"" >&6;} 38016 fi 38017 fi 38018 38019 38020 38021 if test "x$OPENJDK_TARGET_OS" = "xmacosx"; then 38022 38023 38024 # Publish this variable in the help. 38025 38026 38027 if [ -z "${LIPO+x}" ]; then 38028 # The variable is not set by user, try to locate tool using the code snippet 38029 for ac_prog in lipo 38030 do 38031 # Extract the first word of "$ac_prog", so it can be a program name with args. 38032 set dummy $ac_prog; ac_word=$2 38033 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 38034 $as_echo_n "checking for $ac_word... " >&6; } 38035 if ${ac_cv_path_LIPO+:} false; then : 38036 $as_echo_n "(cached) " >&6 38037 else 38038 case $LIPO in 38039 [\\/]* | ?:[\\/]*) 38040 ac_cv_path_LIPO="$LIPO" # Let the user override the test with a path. 38041 ;; 38042 *) 38043 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 38044 for as_dir in $PATH 38045 do 38046 IFS=$as_save_IFS 38047 test -z "$as_dir" && as_dir=. 38048 for ac_exec_ext in '' $ac_executable_extensions; do 38049 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 38050 ac_cv_path_LIPO="$as_dir/$ac_word$ac_exec_ext" 38051 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 38052 break 2 38053 fi 38054 done 38055 done 38056 IFS=$as_save_IFS 38057 38058 ;; 38059 esac 38060 fi 38061 LIPO=$ac_cv_path_LIPO 38062 if test -n "$LIPO"; then 38063 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $LIPO" >&5 38064 $as_echo "$LIPO" >&6; } 38065 else 38066 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 38067 $as_echo "no" >&6; } 38068 fi 38069 38070 38071 test -n "$LIPO" && break 38072 done 38073 38074 else 38075 # The variable is set, but is it from the command line or the environment? 38076 38077 # Try to remove the string !LIPO! from our list. 38078 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!LIPO!/} 38079 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 38080 # If it failed, the variable was not from the command line. Ignore it, 38081 # but warn the user (except for BASH, which is always set by the calling BASH). 38082 if test "xLIPO" != xBASH; then 38083 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of LIPO from the environment. Use command line variables instead." >&5 38084 $as_echo "$as_me: WARNING: Ignoring value of LIPO from the environment. Use command line variables instead." >&2;} 38085 fi 38086 # Try to locate tool using the code snippet 38087 for ac_prog in lipo 38088 do 38089 # Extract the first word of "$ac_prog", so it can be a program name with args. 38090 set dummy $ac_prog; ac_word=$2 38091 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 38092 $as_echo_n "checking for $ac_word... " >&6; } 38093 if ${ac_cv_path_LIPO+:} false; then : 38094 $as_echo_n "(cached) " >&6 38095 else 38096 case $LIPO in 38097 [\\/]* | ?:[\\/]*) 38098 ac_cv_path_LIPO="$LIPO" # Let the user override the test with a path. 38099 ;; 38100 *) 38101 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 38102 for as_dir in $PATH 38103 do 38104 IFS=$as_save_IFS 38105 test -z "$as_dir" && as_dir=. 38106 for ac_exec_ext in '' $ac_executable_extensions; do 38107 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 38108 ac_cv_path_LIPO="$as_dir/$ac_word$ac_exec_ext" 38109 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 38110 break 2 38111 fi 38112 done 38113 done 38114 IFS=$as_save_IFS 38115 38116 ;; 38117 esac 38118 fi 38119 LIPO=$ac_cv_path_LIPO 38120 if test -n "$LIPO"; then 38121 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $LIPO" >&5 38122 $as_echo "$LIPO" >&6; } 38123 else 38124 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 38125 $as_echo "no" >&6; } 38126 fi 38127 38128 38129 test -n "$LIPO" && break 38130 done 38131 38132 else 38133 # If it succeeded, then it was overridden by the user. We will use it 38134 # for the tool. 38135 38136 # First remove it from the list of overridden variables, so we can test 38137 # for unknown variables in the end. 38138 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 38139 38140 # Check if we try to supply an empty value 38141 if test "x$LIPO" = x; then 38142 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool LIPO= (no value)" >&5 38143 $as_echo "$as_me: Setting user supplied tool LIPO= (no value)" >&6;} 38144 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for LIPO" >&5 38145 $as_echo_n "checking for LIPO... " >&6; } 38146 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 38147 $as_echo "disabled" >&6; } 38148 else 38149 # Check if the provided tool contains a complete path. 38150 tool_specified="$LIPO" 38151 tool_basename="${tool_specified##*/}" 38152 if test "x$tool_basename" = "x$tool_specified"; then 38153 # A command without a complete path is provided, search $PATH. 38154 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool LIPO=$tool_basename" >&5 38155 $as_echo "$as_me: Will search for user supplied tool LIPO=$tool_basename" >&6;} 38156 # Extract the first word of "$tool_basename", so it can be a program name with args. 38157 set dummy $tool_basename; ac_word=$2 38158 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 38159 $as_echo_n "checking for $ac_word... " >&6; } 38160 if ${ac_cv_path_LIPO+:} false; then : 38161 $as_echo_n "(cached) " >&6 38162 else 38163 case $LIPO in 38164 [\\/]* | ?:[\\/]*) 38165 ac_cv_path_LIPO="$LIPO" # Let the user override the test with a path. 38166 ;; 38167 *) 38168 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 38169 for as_dir in $PATH 38170 do 38171 IFS=$as_save_IFS 38172 test -z "$as_dir" && as_dir=. 38173 for ac_exec_ext in '' $ac_executable_extensions; do 38174 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 38175 ac_cv_path_LIPO="$as_dir/$ac_word$ac_exec_ext" 38176 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 38177 break 2 38178 fi 38179 done 38180 done 38181 IFS=$as_save_IFS 38182 38183 ;; 38184 esac 38185 fi 38186 LIPO=$ac_cv_path_LIPO 38187 if test -n "$LIPO"; then 38188 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $LIPO" >&5 38189 $as_echo "$LIPO" >&6; } 38190 else 38191 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 38192 $as_echo "no" >&6; } 38193 fi 38194 38195 38196 if test "x$LIPO" = x; then 38197 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 38198 fi 38199 else 38200 # Otherwise we believe it is a complete path. Use it as it is. 38201 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool LIPO=$tool_specified" >&5 38202 $as_echo "$as_me: Will use user supplied tool LIPO=$tool_specified" >&6;} 38203 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for LIPO" >&5 38204 $as_echo_n "checking for LIPO... " >&6; } 38205 if test ! -x "$tool_specified"; then 38206 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 38207 $as_echo "not found" >&6; } 38208 as_fn_error $? "User supplied tool LIPO=$tool_specified does not exist or is not executable" "$LINENO" 5 38209 fi 38210 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 38211 $as_echo "$tool_specified" >&6; } 38212 fi 38213 fi 38214 fi 38215 38216 fi 38217 38218 38219 38220 # Only process if variable expands to non-empty 38221 38222 if test "x$LIPO" != x; then 38223 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 38224 38225 # First separate the path from the arguments. This will split at the first 38226 # space. 38227 complete="$LIPO" 38228 path="${complete%% *}" 38229 tmp="$complete EOL" 38230 arguments="${tmp#* }" 38231 38232 # Input might be given as Windows format, start by converting to 38233 # unix format. 38234 new_path=`$CYGPATH -u "$path"` 38235 38236 # Now try to locate executable using which 38237 new_path=`$WHICH "$new_path" 2> /dev/null` 38238 # bat and cmd files are not always considered executable in cygwin causing which 38239 # to not find them 38240 if test "x$new_path" = x \ 38241 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 38242 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 38243 new_path=`$CYGPATH -u "$path"` 38244 fi 38245 if test "x$new_path" = x; then 38246 # Oops. Which didn't find the executable. 38247 # The splitting of arguments from the executable at a space might have been incorrect, 38248 # since paths with space are more likely in Windows. Give it another try with the whole 38249 # argument. 38250 path="$complete" 38251 arguments="EOL" 38252 new_path=`$CYGPATH -u "$path"` 38253 new_path=`$WHICH "$new_path" 2> /dev/null` 38254 # bat and cmd files are not always considered executable in cygwin causing which 38255 # to not find them 38256 if test "x$new_path" = x \ 38257 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 38258 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 38259 new_path=`$CYGPATH -u "$path"` 38260 fi 38261 if test "x$new_path" = x; then 38262 # It's still not found. Now this is an unrecoverable error. 38263 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of LIPO, which resolves as \"$complete\", is not found." >&5 38264 $as_echo "$as_me: The path of LIPO, which resolves as \"$complete\", is not found." >&6;} 38265 has_space=`$ECHO "$complete" | $GREP " "` 38266 if test "x$has_space" != x; then 38267 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 38268 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 38269 fi 38270 as_fn_error $? "Cannot locate the the path of LIPO" "$LINENO" 5 38271 fi 38272 fi 38273 38274 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 38275 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 38276 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 38277 # "foo.exe" is OK but "foo" is an error. 38278 # 38279 # This test is therefore slightly more accurate than "test -f" to check for file presence. 38280 # It is also a way to make sure we got the proper file name for the real test later on. 38281 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 38282 if test "x$test_shortpath" = x; then 38283 # Short path failed, file does not exist as specified. 38284 # Try adding .exe or .cmd 38285 if test -f "${new_path}.exe"; then 38286 input_to_shortpath="${new_path}.exe" 38287 elif test -f "${new_path}.cmd"; then 38288 input_to_shortpath="${new_path}.cmd" 38289 else 38290 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of LIPO, which resolves as \"$new_path\", is invalid." >&5 38291 $as_echo "$as_me: The path of LIPO, which resolves as \"$new_path\", is invalid." >&6;} 38292 { $as_echo "$as_me:${as_lineno-$LINENO}: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&5 38293 $as_echo "$as_me: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&6;} 38294 as_fn_error $? "Cannot locate the the path of LIPO" "$LINENO" 5 38295 fi 38296 else 38297 input_to_shortpath="$new_path" 38298 fi 38299 38300 # Call helper function which possibly converts this using DOS-style short mode. 38301 # If so, the updated path is stored in $new_path. 38302 new_path="$input_to_shortpath" 38303 38304 input_path="$input_to_shortpath" 38305 # Check if we need to convert this using DOS-style short mode. If the path 38306 # contains just simple characters, use it. Otherwise (spaces, weird characters), 38307 # take no chances and rewrite it. 38308 # Note: m4 eats our [], so we need to use [ and ] instead. 38309 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 38310 if test "x$has_forbidden_chars" != x; then 38311 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 38312 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 38313 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 38314 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 38315 # Going to short mode and back again did indeed matter. Since short mode is 38316 # case insensitive, let's make it lowercase to improve readability. 38317 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 38318 # Now convert it back to Unix-style (cygpath) 38319 input_path=`$CYGPATH -u "$shortmode_path"` 38320 new_path="$input_path" 38321 fi 38322 fi 38323 38324 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 38325 if test "x$test_cygdrive_prefix" = x; then 38326 # As a simple fix, exclude /usr/bin since it's not a real path. 38327 if test "x`$ECHO $input_to_shortpath | $GREP ^/usr/bin/`" = x; then 38328 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 38329 # a path prefixed by /cygdrive for fixpath to work. 38330 new_path="$CYGWIN_ROOT_PATH$input_path" 38331 fi 38332 fi 38333 38334 # remove trailing .exe if any 38335 new_path="${new_path/%.exe/}" 38336 38337 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 38338 38339 # First separate the path from the arguments. This will split at the first 38340 # space. 38341 complete="$LIPO" 38342 path="${complete%% *}" 38343 tmp="$complete EOL" 38344 arguments="${tmp#* }" 38345 38346 # Input might be given as Windows format, start by converting to 38347 # unix format. 38348 new_path="$path" 38349 38350 windows_path="$new_path" 38351 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 38352 unix_path=`$CYGPATH -u "$windows_path"` 38353 new_path="$unix_path" 38354 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 38355 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 38356 new_path="$unix_path" 38357 fi 38358 38359 38360 # Now try to locate executable using which 38361 new_path=`$WHICH "$new_path" 2> /dev/null` 38362 38363 if test "x$new_path" = x; then 38364 # Oops. Which didn't find the executable. 38365 # The splitting of arguments from the executable at a space might have been incorrect, 38366 # since paths with space are more likely in Windows. Give it another try with the whole 38367 # argument. 38368 path="$complete" 38369 arguments="EOL" 38370 new_path="$path" 38371 38372 windows_path="$new_path" 38373 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 38374 unix_path=`$CYGPATH -u "$windows_path"` 38375 new_path="$unix_path" 38376 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 38377 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 38378 new_path="$unix_path" 38379 fi 38380 38381 38382 new_path=`$WHICH "$new_path" 2> /dev/null` 38383 # bat and cmd files are not always considered executable in MSYS causing which 38384 # to not find them 38385 if test "x$new_path" = x \ 38386 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 38387 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 38388 new_path="$path" 38389 38390 windows_path="$new_path" 38391 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 38392 unix_path=`$CYGPATH -u "$windows_path"` 38393 new_path="$unix_path" 38394 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 38395 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 38396 new_path="$unix_path" 38397 fi 38398 38399 fi 38400 38401 if test "x$new_path" = x; then 38402 # It's still not found. Now this is an unrecoverable error. 38403 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of LIPO, which resolves as \"$complete\", is not found." >&5 38404 $as_echo "$as_me: The path of LIPO, which resolves as \"$complete\", is not found." >&6;} 38405 has_space=`$ECHO "$complete" | $GREP " "` 38406 if test "x$has_space" != x; then 38407 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 38408 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 38409 fi 38410 as_fn_error $? "Cannot locate the the path of LIPO" "$LINENO" 5 38411 fi 38412 fi 38413 38414 # Now new_path has a complete unix path to the binary 38415 if test "x`$ECHO $new_path | $GREP ^/bin/`" != x; then 38416 # Keep paths in /bin as-is, but remove trailing .exe if any 38417 new_path="${new_path/%.exe/}" 38418 # Do not save /bin paths to all_fixpath_prefixes! 38419 else 38420 # Not in mixed or Windows style, start by that. 38421 new_path=`cmd //c echo $new_path` 38422 38423 input_path="$new_path" 38424 # Check if we need to convert this using DOS-style short mode. If the path 38425 # contains just simple characters, use it. Otherwise (spaces, weird characters), 38426 # take no chances and rewrite it. 38427 # Note: m4 eats our [], so we need to use [ and ] instead. 38428 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 38429 if test "x$has_forbidden_chars" != x; then 38430 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 38431 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 38432 fi 38433 38434 # Output is in $new_path 38435 38436 windows_path="$new_path" 38437 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 38438 unix_path=`$CYGPATH -u "$windows_path"` 38439 new_path="$unix_path" 38440 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 38441 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 38442 new_path="$unix_path" 38443 fi 38444 38445 # remove trailing .exe if any 38446 new_path="${new_path/%.exe/}" 38447 38448 # Save the first 10 bytes of this path to the storage, so fixpath can work. 38449 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 38450 fi 38451 38452 else 38453 # We're on a unix platform. Hooray! :) 38454 # First separate the path from the arguments. This will split at the first 38455 # space. 38456 complete="$LIPO" 38457 path="${complete%% *}" 38458 tmp="$complete EOL" 38459 arguments="${tmp#* }" 38460 38461 # Cannot rely on the command "which" here since it doesn't always work. 38462 is_absolute_path=`$ECHO "$path" | $GREP ^/` 38463 if test -z "$is_absolute_path"; then 38464 # Path to executable is not absolute. Find it. 38465 IFS_save="$IFS" 38466 IFS=: 38467 for p in $PATH; do 38468 if test -f "$p/$path" && test -x "$p/$path"; then 38469 new_path="$p/$path" 38470 break 38471 fi 38472 done 38473 IFS="$IFS_save" 38474 else 38475 # This is an absolute path, we can use it without further modifications. 38476 new_path="$path" 38477 fi 38478 38479 if test "x$new_path" = x; then 38480 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of LIPO, which resolves as \"$complete\", is not found." >&5 38481 $as_echo "$as_me: The path of LIPO, which resolves as \"$complete\", is not found." >&6;} 38482 has_space=`$ECHO "$complete" | $GREP " "` 38483 if test "x$has_space" != x; then 38484 { $as_echo "$as_me:${as_lineno-$LINENO}: This might be caused by spaces in the path, which is not allowed." >&5 38485 $as_echo "$as_me: This might be caused by spaces in the path, which is not allowed." >&6;} 38486 fi 38487 as_fn_error $? "Cannot locate the the path of LIPO" "$LINENO" 5 38488 fi 38489 fi 38490 38491 # Now join together the path and the arguments once again 38492 if test "x$arguments" != xEOL; then 38493 new_complete="$new_path ${arguments% *}" 38494 else 38495 new_complete="$new_path" 38496 fi 38497 38498 if test "x$complete" != "x$new_complete"; then 38499 LIPO="$new_complete" 38500 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting LIPO to \"$new_complete\"" >&5 38501 $as_echo "$as_me: Rewriting LIPO to \"$new_complete\"" >&6;} 38502 fi 38503 fi 38504 38505 fi 38506 38507 if test "x$TOOLCHAIN_TYPE" = xmicrosoft; then 38508 # Extract the first word of "mt", so it can be a program name with args. 38509 set dummy mt; ac_word=$2 38510 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 38511 $as_echo_n "checking for $ac_word... " >&6; } 38512 if ${ac_cv_prog_MT+:} false; then : 38513 $as_echo_n "(cached) " >&6 38514 else 38515 if test -n "$MT"; then 38516 ac_cv_prog_MT="$MT" # Let the user override the test. 38517 else 38518 ac_prog_rejected=no 38519 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 38520 for as_dir in $PATH 38521 do 38522 IFS=$as_save_IFS 38523 test -z "$as_dir" && as_dir=. 38524 for ac_exec_ext in '' $ac_executable_extensions; do 38525 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 38526 if test "$as_dir/$ac_word$ac_exec_ext" = "/usr/bin/mt"; then 38527 ac_prog_rejected=yes 38528 continue 38529 fi 38530 ac_cv_prog_MT="mt" 38531 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 38532 break 2 38533 fi 38534 done 38535 done 38536 IFS=$as_save_IFS 38537 38538 if test $ac_prog_rejected = yes; then 38539 # We found a bogon in the path, so make sure we never use it. 38540 set dummy $ac_cv_prog_MT 38541 shift 38542 if test $# != 0; then 38543 # We chose a different compiler from the bogus one. 38544 # However, it has the same basename, so the bogon will be chosen 38545 # first if we set MT to just the basename; use the full file name. 38546 shift 38547 ac_cv_prog_MT="$as_dir/$ac_word${1+' '}$@" 38548 fi 38549 fi 38550 fi 38551 fi 38552 MT=$ac_cv_prog_MT 38553 if test -n "$MT"; then 38554 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MT" >&5 38555 $as_echo "$MT" >&6; } 38556 else 38557 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 38558 $as_echo "no" >&6; } 38559 fi 38560 38561 38562 38563 # Only process if variable expands to non-empty 38564 38565 if test "x$MT" != x; then 38566 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 38567 38568 # First separate the path from the arguments. This will split at the first 38569 # space. 38570 complete="$MT" 38571 path="${complete%% *}" 38572 tmp="$complete EOL" 38573 arguments="${tmp#* }" 38574 38575 # Input might be given as Windows format, start by converting to 38576 # unix format. 38577 new_path=`$CYGPATH -u "$path"` 38578 38579 # Now try to locate executable using which 38580 new_path=`$WHICH "$new_path" 2> /dev/null` 38581 # bat and cmd files are not always considered executable in cygwin causing which 38582 # to not find them 38583 if test "x$new_path" = x \ 38584 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 38585 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 38586 new_path=`$CYGPATH -u "$path"` 38587 fi 38588 if test "x$new_path" = x; then 38589 # Oops. Which didn't find the executable. 38590 # The splitting of arguments from the executable at a space might have been incorrect, 38591 # since paths with space are more likely in Windows. Give it another try with the whole 38592 # argument. 38593 path="$complete" 38594 arguments="EOL" 38595 new_path=`$CYGPATH -u "$path"` 38596 new_path=`$WHICH "$new_path" 2> /dev/null` 38597 # bat and cmd files are not always considered executable in cygwin causing which 38598 # to not find them 38599 if test "x$new_path" = x \ 38600 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 38601 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 38602 new_path=`$CYGPATH -u "$path"` 38603 fi 38604 if test "x$new_path" = x; then 38605 # It's still not found. Now this is an unrecoverable error. 38606 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of MT, which resolves as \"$complete\", is not found." >&5 38607 $as_echo "$as_me: The path of MT, which resolves as \"$complete\", is not found." >&6;} 38608 has_space=`$ECHO "$complete" | $GREP " "` 38609 if test "x$has_space" != x; then 38610 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 38611 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 38612 fi 38613 as_fn_error $? "Cannot locate the the path of MT" "$LINENO" 5 38614 fi 38615 fi 38616 38617 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 38618 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 38619 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 38620 # "foo.exe" is OK but "foo" is an error. 38621 # 38622 # This test is therefore slightly more accurate than "test -f" to check for file presence. 38623 # It is also a way to make sure we got the proper file name for the real test later on. 38624 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 38625 if test "x$test_shortpath" = x; then 38626 # Short path failed, file does not exist as specified. 38627 # Try adding .exe or .cmd 38628 if test -f "${new_path}.exe"; then 38629 input_to_shortpath="${new_path}.exe" 38630 elif test -f "${new_path}.cmd"; then 38631 input_to_shortpath="${new_path}.cmd" 38632 else 38633 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of MT, which resolves as \"$new_path\", is invalid." >&5 38634 $as_echo "$as_me: The path of MT, which resolves as \"$new_path\", is invalid." >&6;} 38635 { $as_echo "$as_me:${as_lineno-$LINENO}: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&5 38636 $as_echo "$as_me: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&6;} 38637 as_fn_error $? "Cannot locate the the path of MT" "$LINENO" 5 38638 fi 38639 else 38640 input_to_shortpath="$new_path" 38641 fi 38642 38643 # Call helper function which possibly converts this using DOS-style short mode. 38644 # If so, the updated path is stored in $new_path. 38645 new_path="$input_to_shortpath" 38646 38647 input_path="$input_to_shortpath" 38648 # Check if we need to convert this using DOS-style short mode. If the path 38649 # contains just simple characters, use it. Otherwise (spaces, weird characters), 38650 # take no chances and rewrite it. 38651 # Note: m4 eats our [], so we need to use [ and ] instead. 38652 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 38653 if test "x$has_forbidden_chars" != x; then 38654 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 38655 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 38656 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 38657 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 38658 # Going to short mode and back again did indeed matter. Since short mode is 38659 # case insensitive, let's make it lowercase to improve readability. 38660 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 38661 # Now convert it back to Unix-style (cygpath) 38662 input_path=`$CYGPATH -u "$shortmode_path"` 38663 new_path="$input_path" 38664 fi 38665 fi 38666 38667 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 38668 if test "x$test_cygdrive_prefix" = x; then 38669 # As a simple fix, exclude /usr/bin since it's not a real path. 38670 if test "x`$ECHO $input_to_shortpath | $GREP ^/usr/bin/`" = x; then 38671 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 38672 # a path prefixed by /cygdrive for fixpath to work. 38673 new_path="$CYGWIN_ROOT_PATH$input_path" 38674 fi 38675 fi 38676 38677 # remove trailing .exe if any 38678 new_path="${new_path/%.exe/}" 38679 38680 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 38681 38682 # First separate the path from the arguments. This will split at the first 38683 # space. 38684 complete="$MT" 38685 path="${complete%% *}" 38686 tmp="$complete EOL" 38687 arguments="${tmp#* }" 38688 38689 # Input might be given as Windows format, start by converting to 38690 # unix format. 38691 new_path="$path" 38692 38693 windows_path="$new_path" 38694 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 38695 unix_path=`$CYGPATH -u "$windows_path"` 38696 new_path="$unix_path" 38697 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 38698 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 38699 new_path="$unix_path" 38700 fi 38701 38702 38703 # Now try to locate executable using which 38704 new_path=`$WHICH "$new_path" 2> /dev/null` 38705 38706 if test "x$new_path" = x; then 38707 # Oops. Which didn't find the executable. 38708 # The splitting of arguments from the executable at a space might have been incorrect, 38709 # since paths with space are more likely in Windows. Give it another try with the whole 38710 # argument. 38711 path="$complete" 38712 arguments="EOL" 38713 new_path="$path" 38714 38715 windows_path="$new_path" 38716 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 38717 unix_path=`$CYGPATH -u "$windows_path"` 38718 new_path="$unix_path" 38719 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 38720 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 38721 new_path="$unix_path" 38722 fi 38723 38724 38725 new_path=`$WHICH "$new_path" 2> /dev/null` 38726 # bat and cmd files are not always considered executable in MSYS causing which 38727 # to not find them 38728 if test "x$new_path" = x \ 38729 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 38730 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 38731 new_path="$path" 38732 38733 windows_path="$new_path" 38734 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 38735 unix_path=`$CYGPATH -u "$windows_path"` 38736 new_path="$unix_path" 38737 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 38738 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 38739 new_path="$unix_path" 38740 fi 38741 38742 fi 38743 38744 if test "x$new_path" = x; then 38745 # It's still not found. Now this is an unrecoverable error. 38746 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of MT, which resolves as \"$complete\", is not found." >&5 38747 $as_echo "$as_me: The path of MT, which resolves as \"$complete\", is not found." >&6;} 38748 has_space=`$ECHO "$complete" | $GREP " "` 38749 if test "x$has_space" != x; then 38750 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 38751 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 38752 fi 38753 as_fn_error $? "Cannot locate the the path of MT" "$LINENO" 5 38754 fi 38755 fi 38756 38757 # Now new_path has a complete unix path to the binary 38758 if test "x`$ECHO $new_path | $GREP ^/bin/`" != x; then 38759 # Keep paths in /bin as-is, but remove trailing .exe if any 38760 new_path="${new_path/%.exe/}" 38761 # Do not save /bin paths to all_fixpath_prefixes! 38762 else 38763 # Not in mixed or Windows style, start by that. 38764 new_path=`cmd //c echo $new_path` 38765 38766 input_path="$new_path" 38767 # Check if we need to convert this using DOS-style short mode. If the path 38768 # contains just simple characters, use it. Otherwise (spaces, weird characters), 38769 # take no chances and rewrite it. 38770 # Note: m4 eats our [], so we need to use [ and ] instead. 38771 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 38772 if test "x$has_forbidden_chars" != x; then 38773 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 38774 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 38775 fi 38776 38777 # Output is in $new_path 38778 38779 windows_path="$new_path" 38780 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 38781 unix_path=`$CYGPATH -u "$windows_path"` 38782 new_path="$unix_path" 38783 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 38784 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 38785 new_path="$unix_path" 38786 fi 38787 38788 # remove trailing .exe if any 38789 new_path="${new_path/%.exe/}" 38790 38791 # Save the first 10 bytes of this path to the storage, so fixpath can work. 38792 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 38793 fi 38794 38795 else 38796 # We're on a unix platform. Hooray! :) 38797 # First separate the path from the arguments. This will split at the first 38798 # space. 38799 complete="$MT" 38800 path="${complete%% *}" 38801 tmp="$complete EOL" 38802 arguments="${tmp#* }" 38803 38804 # Cannot rely on the command "which" here since it doesn't always work. 38805 is_absolute_path=`$ECHO "$path" | $GREP ^/` 38806 if test -z "$is_absolute_path"; then 38807 # Path to executable is not absolute. Find it. 38808 IFS_save="$IFS" 38809 IFS=: 38810 for p in $PATH; do 38811 if test -f "$p/$path" && test -x "$p/$path"; then 38812 new_path="$p/$path" 38813 break 38814 fi 38815 done 38816 IFS="$IFS_save" 38817 else 38818 # This is an absolute path, we can use it without further modifications. 38819 new_path="$path" 38820 fi 38821 38822 if test "x$new_path" = x; then 38823 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of MT, which resolves as \"$complete\", is not found." >&5 38824 $as_echo "$as_me: The path of MT, which resolves as \"$complete\", is not found." >&6;} 38825 has_space=`$ECHO "$complete" | $GREP " "` 38826 if test "x$has_space" != x; then 38827 { $as_echo "$as_me:${as_lineno-$LINENO}: This might be caused by spaces in the path, which is not allowed." >&5 38828 $as_echo "$as_me: This might be caused by spaces in the path, which is not allowed." >&6;} 38829 fi 38830 as_fn_error $? "Cannot locate the the path of MT" "$LINENO" 5 38831 fi 38832 fi 38833 38834 # Now join together the path and the arguments once again 38835 if test "x$arguments" != xEOL; then 38836 new_complete="$new_path ${arguments% *}" 38837 else 38838 new_complete="$new_path" 38839 fi 38840 38841 if test "x$complete" != "x$new_complete"; then 38842 MT="$new_complete" 38843 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting MT to \"$new_complete\"" >&5 38844 $as_echo "$as_me: Rewriting MT to \"$new_complete\"" >&6;} 38845 fi 38846 fi 38847 38848 # Setup the resource compiler (RC) 38849 # Extract the first word of "rc", so it can be a program name with args. 38850 set dummy rc; ac_word=$2 38851 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 38852 $as_echo_n "checking for $ac_word... " >&6; } 38853 if ${ac_cv_prog_RC+:} false; then : 38854 $as_echo_n "(cached) " >&6 38855 else 38856 if test -n "$RC"; then 38857 ac_cv_prog_RC="$RC" # Let the user override the test. 38858 else 38859 ac_prog_rejected=no 38860 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 38861 for as_dir in $PATH 38862 do 38863 IFS=$as_save_IFS 38864 test -z "$as_dir" && as_dir=. 38865 for ac_exec_ext in '' $ac_executable_extensions; do 38866 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 38867 if test "$as_dir/$ac_word$ac_exec_ext" = "/usr/bin/rc"; then 38868 ac_prog_rejected=yes 38869 continue 38870 fi 38871 ac_cv_prog_RC="rc" 38872 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 38873 break 2 38874 fi 38875 done 38876 done 38877 IFS=$as_save_IFS 38878 38879 if test $ac_prog_rejected = yes; then 38880 # We found a bogon in the path, so make sure we never use it. 38881 set dummy $ac_cv_prog_RC 38882 shift 38883 if test $# != 0; then 38884 # We chose a different compiler from the bogus one. 38885 # However, it has the same basename, so the bogon will be chosen 38886 # first if we set RC to just the basename; use the full file name. 38887 shift 38888 ac_cv_prog_RC="$as_dir/$ac_word${1+' '}$@" 38889 fi 38890 fi 38891 fi 38892 fi 38893 RC=$ac_cv_prog_RC 38894 if test -n "$RC"; then 38895 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $RC" >&5 38896 $as_echo "$RC" >&6; } 38897 else 38898 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 38899 $as_echo "no" >&6; } 38900 fi 38901 38902 38903 38904 # Only process if variable expands to non-empty 38905 38906 if test "x$RC" != x; then 38907 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 38908 38909 # First separate the path from the arguments. This will split at the first 38910 # space. 38911 complete="$RC" 38912 path="${complete%% *}" 38913 tmp="$complete EOL" 38914 arguments="${tmp#* }" 38915 38916 # Input might be given as Windows format, start by converting to 38917 # unix format. 38918 new_path=`$CYGPATH -u "$path"` 38919 38920 # Now try to locate executable using which 38921 new_path=`$WHICH "$new_path" 2> /dev/null` 38922 # bat and cmd files are not always considered executable in cygwin causing which 38923 # to not find them 38924 if test "x$new_path" = x \ 38925 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 38926 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 38927 new_path=`$CYGPATH -u "$path"` 38928 fi 38929 if test "x$new_path" = x; then 38930 # Oops. Which didn't find the executable. 38931 # The splitting of arguments from the executable at a space might have been incorrect, 38932 # since paths with space are more likely in Windows. Give it another try with the whole 38933 # argument. 38934 path="$complete" 38935 arguments="EOL" 38936 new_path=`$CYGPATH -u "$path"` 38937 new_path=`$WHICH "$new_path" 2> /dev/null` 38938 # bat and cmd files are not always considered executable in cygwin causing which 38939 # to not find them 38940 if test "x$new_path" = x \ 38941 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 38942 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 38943 new_path=`$CYGPATH -u "$path"` 38944 fi 38945 if test "x$new_path" = x; then 38946 # It's still not found. Now this is an unrecoverable error. 38947 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of RC, which resolves as \"$complete\", is not found." >&5 38948 $as_echo "$as_me: The path of RC, which resolves as \"$complete\", is not found." >&6;} 38949 has_space=`$ECHO "$complete" | $GREP " "` 38950 if test "x$has_space" != x; then 38951 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 38952 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 38953 fi 38954 as_fn_error $? "Cannot locate the the path of RC" "$LINENO" 5 38955 fi 38956 fi 38957 38958 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 38959 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 38960 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 38961 # "foo.exe" is OK but "foo" is an error. 38962 # 38963 # This test is therefore slightly more accurate than "test -f" to check for file presence. 38964 # It is also a way to make sure we got the proper file name for the real test later on. 38965 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 38966 if test "x$test_shortpath" = x; then 38967 # Short path failed, file does not exist as specified. 38968 # Try adding .exe or .cmd 38969 if test -f "${new_path}.exe"; then 38970 input_to_shortpath="${new_path}.exe" 38971 elif test -f "${new_path}.cmd"; then 38972 input_to_shortpath="${new_path}.cmd" 38973 else 38974 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of RC, which resolves as \"$new_path\", is invalid." >&5 38975 $as_echo "$as_me: The path of RC, which resolves as \"$new_path\", is invalid." >&6;} 38976 { $as_echo "$as_me:${as_lineno-$LINENO}: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&5 38977 $as_echo "$as_me: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&6;} 38978 as_fn_error $? "Cannot locate the the path of RC" "$LINENO" 5 38979 fi 38980 else 38981 input_to_shortpath="$new_path" 38982 fi 38983 38984 # Call helper function which possibly converts this using DOS-style short mode. 38985 # If so, the updated path is stored in $new_path. 38986 new_path="$input_to_shortpath" 38987 38988 input_path="$input_to_shortpath" 38989 # Check if we need to convert this using DOS-style short mode. If the path 38990 # contains just simple characters, use it. Otherwise (spaces, weird characters), 38991 # take no chances and rewrite it. 38992 # Note: m4 eats our [], so we need to use [ and ] instead. 38993 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 38994 if test "x$has_forbidden_chars" != x; then 38995 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 38996 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 38997 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 38998 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 38999 # Going to short mode and back again did indeed matter. Since short mode is 39000 # case insensitive, let's make it lowercase to improve readability. 39001 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 39002 # Now convert it back to Unix-style (cygpath) 39003 input_path=`$CYGPATH -u "$shortmode_path"` 39004 new_path="$input_path" 39005 fi 39006 fi 39007 39008 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 39009 if test "x$test_cygdrive_prefix" = x; then 39010 # As a simple fix, exclude /usr/bin since it's not a real path. 39011 if test "x`$ECHO $input_to_shortpath | $GREP ^/usr/bin/`" = x; then 39012 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 39013 # a path prefixed by /cygdrive for fixpath to work. 39014 new_path="$CYGWIN_ROOT_PATH$input_path" 39015 fi 39016 fi 39017 39018 # remove trailing .exe if any 39019 new_path="${new_path/%.exe/}" 39020 39021 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 39022 39023 # First separate the path from the arguments. This will split at the first 39024 # space. 39025 complete="$RC" 39026 path="${complete%% *}" 39027 tmp="$complete EOL" 39028 arguments="${tmp#* }" 39029 39030 # Input might be given as Windows format, start by converting to 39031 # unix format. 39032 new_path="$path" 39033 39034 windows_path="$new_path" 39035 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 39036 unix_path=`$CYGPATH -u "$windows_path"` 39037 new_path="$unix_path" 39038 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 39039 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 39040 new_path="$unix_path" 39041 fi 39042 39043 39044 # Now try to locate executable using which 39045 new_path=`$WHICH "$new_path" 2> /dev/null` 39046 39047 if test "x$new_path" = x; then 39048 # Oops. Which didn't find the executable. 39049 # The splitting of arguments from the executable at a space might have been incorrect, 39050 # since paths with space are more likely in Windows. Give it another try with the whole 39051 # argument. 39052 path="$complete" 39053 arguments="EOL" 39054 new_path="$path" 39055 39056 windows_path="$new_path" 39057 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 39058 unix_path=`$CYGPATH -u "$windows_path"` 39059 new_path="$unix_path" 39060 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 39061 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 39062 new_path="$unix_path" 39063 fi 39064 39065 39066 new_path=`$WHICH "$new_path" 2> /dev/null` 39067 # bat and cmd files are not always considered executable in MSYS causing which 39068 # to not find them 39069 if test "x$new_path" = x \ 39070 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 39071 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 39072 new_path="$path" 39073 39074 windows_path="$new_path" 39075 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 39076 unix_path=`$CYGPATH -u "$windows_path"` 39077 new_path="$unix_path" 39078 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 39079 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 39080 new_path="$unix_path" 39081 fi 39082 39083 fi 39084 39085 if test "x$new_path" = x; then 39086 # It's still not found. Now this is an unrecoverable error. 39087 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of RC, which resolves as \"$complete\", is not found." >&5 39088 $as_echo "$as_me: The path of RC, which resolves as \"$complete\", is not found." >&6;} 39089 has_space=`$ECHO "$complete" | $GREP " "` 39090 if test "x$has_space" != x; then 39091 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 39092 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 39093 fi 39094 as_fn_error $? "Cannot locate the the path of RC" "$LINENO" 5 39095 fi 39096 fi 39097 39098 # Now new_path has a complete unix path to the binary 39099 if test "x`$ECHO $new_path | $GREP ^/bin/`" != x; then 39100 # Keep paths in /bin as-is, but remove trailing .exe if any 39101 new_path="${new_path/%.exe/}" 39102 # Do not save /bin paths to all_fixpath_prefixes! 39103 else 39104 # Not in mixed or Windows style, start by that. 39105 new_path=`cmd //c echo $new_path` 39106 39107 input_path="$new_path" 39108 # Check if we need to convert this using DOS-style short mode. If the path 39109 # contains just simple characters, use it. Otherwise (spaces, weird characters), 39110 # take no chances and rewrite it. 39111 # Note: m4 eats our [], so we need to use [ and ] instead. 39112 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 39113 if test "x$has_forbidden_chars" != x; then 39114 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 39115 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 39116 fi 39117 39118 # Output is in $new_path 39119 39120 windows_path="$new_path" 39121 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 39122 unix_path=`$CYGPATH -u "$windows_path"` 39123 new_path="$unix_path" 39124 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 39125 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 39126 new_path="$unix_path" 39127 fi 39128 39129 # remove trailing .exe if any 39130 new_path="${new_path/%.exe/}" 39131 39132 # Save the first 10 bytes of this path to the storage, so fixpath can work. 39133 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 39134 fi 39135 39136 else 39137 # We're on a unix platform. Hooray! :) 39138 # First separate the path from the arguments. This will split at the first 39139 # space. 39140 complete="$RC" 39141 path="${complete%% *}" 39142 tmp="$complete EOL" 39143 arguments="${tmp#* }" 39144 39145 # Cannot rely on the command "which" here since it doesn't always work. 39146 is_absolute_path=`$ECHO "$path" | $GREP ^/` 39147 if test -z "$is_absolute_path"; then 39148 # Path to executable is not absolute. Find it. 39149 IFS_save="$IFS" 39150 IFS=: 39151 for p in $PATH; do 39152 if test -f "$p/$path" && test -x "$p/$path"; then 39153 new_path="$p/$path" 39154 break 39155 fi 39156 done 39157 IFS="$IFS_save" 39158 else 39159 # This is an absolute path, we can use it without further modifications. 39160 new_path="$path" 39161 fi 39162 39163 if test "x$new_path" = x; then 39164 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of RC, which resolves as \"$complete\", is not found." >&5 39165 $as_echo "$as_me: The path of RC, which resolves as \"$complete\", is not found." >&6;} 39166 has_space=`$ECHO "$complete" | $GREP " "` 39167 if test "x$has_space" != x; then 39168 { $as_echo "$as_me:${as_lineno-$LINENO}: This might be caused by spaces in the path, which is not allowed." >&5 39169 $as_echo "$as_me: This might be caused by spaces in the path, which is not allowed." >&6;} 39170 fi 39171 as_fn_error $? "Cannot locate the the path of RC" "$LINENO" 5 39172 fi 39173 fi 39174 39175 # Now join together the path and the arguments once again 39176 if test "x$arguments" != xEOL; then 39177 new_complete="$new_path ${arguments% *}" 39178 else 39179 new_complete="$new_path" 39180 fi 39181 39182 if test "x$complete" != "x$new_complete"; then 39183 RC="$new_complete" 39184 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting RC to \"$new_complete\"" >&5 39185 $as_echo "$as_me: Rewriting RC to \"$new_complete\"" >&6;} 39186 fi 39187 fi 39188 39189 # Extract the first word of "dumpbin", so it can be a program name with args. 39190 set dummy dumpbin; ac_word=$2 39191 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 39192 $as_echo_n "checking for $ac_word... " >&6; } 39193 if ${ac_cv_prog_DUMPBIN+:} false; then : 39194 $as_echo_n "(cached) " >&6 39195 else 39196 if test -n "$DUMPBIN"; then 39197 ac_cv_prog_DUMPBIN="$DUMPBIN" # Let the user override the test. 39198 else 39199 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 39200 for as_dir in $PATH 39201 do 39202 IFS=$as_save_IFS 39203 test -z "$as_dir" && as_dir=. 39204 for ac_exec_ext in '' $ac_executable_extensions; do 39205 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 39206 ac_cv_prog_DUMPBIN="dumpbin" 39207 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 39208 break 2 39209 fi 39210 done 39211 done 39212 IFS=$as_save_IFS 39213 39214 fi 39215 fi 39216 DUMPBIN=$ac_cv_prog_DUMPBIN 39217 if test -n "$DUMPBIN"; then 39218 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $DUMPBIN" >&5 39219 $as_echo "$DUMPBIN" >&6; } 39220 else 39221 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 39222 $as_echo "no" >&6; } 39223 fi 39224 39225 39226 39227 # Only process if variable expands to non-empty 39228 39229 if test "x$DUMPBIN" != x; then 39230 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 39231 39232 # First separate the path from the arguments. This will split at the first 39233 # space. 39234 complete="$DUMPBIN" 39235 path="${complete%% *}" 39236 tmp="$complete EOL" 39237 arguments="${tmp#* }" 39238 39239 # Input might be given as Windows format, start by converting to 39240 # unix format. 39241 new_path=`$CYGPATH -u "$path"` 39242 39243 # Now try to locate executable using which 39244 new_path=`$WHICH "$new_path" 2> /dev/null` 39245 # bat and cmd files are not always considered executable in cygwin causing which 39246 # to not find them 39247 if test "x$new_path" = x \ 39248 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 39249 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 39250 new_path=`$CYGPATH -u "$path"` 39251 fi 39252 if test "x$new_path" = x; then 39253 # Oops. Which didn't find the executable. 39254 # The splitting of arguments from the executable at a space might have been incorrect, 39255 # since paths with space are more likely in Windows. Give it another try with the whole 39256 # argument. 39257 path="$complete" 39258 arguments="EOL" 39259 new_path=`$CYGPATH -u "$path"` 39260 new_path=`$WHICH "$new_path" 2> /dev/null` 39261 # bat and cmd files are not always considered executable in cygwin causing which 39262 # to not find them 39263 if test "x$new_path" = x \ 39264 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 39265 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 39266 new_path=`$CYGPATH -u "$path"` 39267 fi 39268 if test "x$new_path" = x; then 39269 # It's still not found. Now this is an unrecoverable error. 39270 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of DUMPBIN, which resolves as \"$complete\", is not found." >&5 39271 $as_echo "$as_me: The path of DUMPBIN, which resolves as \"$complete\", is not found." >&6;} 39272 has_space=`$ECHO "$complete" | $GREP " "` 39273 if test "x$has_space" != x; then 39274 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 39275 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 39276 fi 39277 as_fn_error $? "Cannot locate the the path of DUMPBIN" "$LINENO" 5 39278 fi 39279 fi 39280 39281 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 39282 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 39283 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 39284 # "foo.exe" is OK but "foo" is an error. 39285 # 39286 # This test is therefore slightly more accurate than "test -f" to check for file presence. 39287 # It is also a way to make sure we got the proper file name for the real test later on. 39288 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 39289 if test "x$test_shortpath" = x; then 39290 # Short path failed, file does not exist as specified. 39291 # Try adding .exe or .cmd 39292 if test -f "${new_path}.exe"; then 39293 input_to_shortpath="${new_path}.exe" 39294 elif test -f "${new_path}.cmd"; then 39295 input_to_shortpath="${new_path}.cmd" 39296 else 39297 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of DUMPBIN, which resolves as \"$new_path\", is invalid." >&5 39298 $as_echo "$as_me: The path of DUMPBIN, which resolves as \"$new_path\", is invalid." >&6;} 39299 { $as_echo "$as_me:${as_lineno-$LINENO}: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&5 39300 $as_echo "$as_me: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&6;} 39301 as_fn_error $? "Cannot locate the the path of DUMPBIN" "$LINENO" 5 39302 fi 39303 else 39304 input_to_shortpath="$new_path" 39305 fi 39306 39307 # Call helper function which possibly converts this using DOS-style short mode. 39308 # If so, the updated path is stored in $new_path. 39309 new_path="$input_to_shortpath" 39310 39311 input_path="$input_to_shortpath" 39312 # Check if we need to convert this using DOS-style short mode. If the path 39313 # contains just simple characters, use it. Otherwise (spaces, weird characters), 39314 # take no chances and rewrite it. 39315 # Note: m4 eats our [], so we need to use [ and ] instead. 39316 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 39317 if test "x$has_forbidden_chars" != x; then 39318 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 39319 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 39320 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 39321 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 39322 # Going to short mode and back again did indeed matter. Since short mode is 39323 # case insensitive, let's make it lowercase to improve readability. 39324 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 39325 # Now convert it back to Unix-style (cygpath) 39326 input_path=`$CYGPATH -u "$shortmode_path"` 39327 new_path="$input_path" 39328 fi 39329 fi 39330 39331 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 39332 if test "x$test_cygdrive_prefix" = x; then 39333 # As a simple fix, exclude /usr/bin since it's not a real path. 39334 if test "x`$ECHO $input_to_shortpath | $GREP ^/usr/bin/`" = x; then 39335 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 39336 # a path prefixed by /cygdrive for fixpath to work. 39337 new_path="$CYGWIN_ROOT_PATH$input_path" 39338 fi 39339 fi 39340 39341 # remove trailing .exe if any 39342 new_path="${new_path/%.exe/}" 39343 39344 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 39345 39346 # First separate the path from the arguments. This will split at the first 39347 # space. 39348 complete="$DUMPBIN" 39349 path="${complete%% *}" 39350 tmp="$complete EOL" 39351 arguments="${tmp#* }" 39352 39353 # Input might be given as Windows format, start by converting to 39354 # unix format. 39355 new_path="$path" 39356 39357 windows_path="$new_path" 39358 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 39359 unix_path=`$CYGPATH -u "$windows_path"` 39360 new_path="$unix_path" 39361 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 39362 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 39363 new_path="$unix_path" 39364 fi 39365 39366 39367 # Now try to locate executable using which 39368 new_path=`$WHICH "$new_path" 2> /dev/null` 39369 39370 if test "x$new_path" = x; then 39371 # Oops. Which didn't find the executable. 39372 # The splitting of arguments from the executable at a space might have been incorrect, 39373 # since paths with space are more likely in Windows. Give it another try with the whole 39374 # argument. 39375 path="$complete" 39376 arguments="EOL" 39377 new_path="$path" 39378 39379 windows_path="$new_path" 39380 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 39381 unix_path=`$CYGPATH -u "$windows_path"` 39382 new_path="$unix_path" 39383 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 39384 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 39385 new_path="$unix_path" 39386 fi 39387 39388 39389 new_path=`$WHICH "$new_path" 2> /dev/null` 39390 # bat and cmd files are not always considered executable in MSYS causing which 39391 # to not find them 39392 if test "x$new_path" = x \ 39393 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 39394 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 39395 new_path="$path" 39396 39397 windows_path="$new_path" 39398 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 39399 unix_path=`$CYGPATH -u "$windows_path"` 39400 new_path="$unix_path" 39401 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 39402 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 39403 new_path="$unix_path" 39404 fi 39405 39406 fi 39407 39408 if test "x$new_path" = x; then 39409 # It's still not found. Now this is an unrecoverable error. 39410 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of DUMPBIN, which resolves as \"$complete\", is not found." >&5 39411 $as_echo "$as_me: The path of DUMPBIN, which resolves as \"$complete\", is not found." >&6;} 39412 has_space=`$ECHO "$complete" | $GREP " "` 39413 if test "x$has_space" != x; then 39414 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 39415 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 39416 fi 39417 as_fn_error $? "Cannot locate the the path of DUMPBIN" "$LINENO" 5 39418 fi 39419 fi 39420 39421 # Now new_path has a complete unix path to the binary 39422 if test "x`$ECHO $new_path | $GREP ^/bin/`" != x; then 39423 # Keep paths in /bin as-is, but remove trailing .exe if any 39424 new_path="${new_path/%.exe/}" 39425 # Do not save /bin paths to all_fixpath_prefixes! 39426 else 39427 # Not in mixed or Windows style, start by that. 39428 new_path=`cmd //c echo $new_path` 39429 39430 input_path="$new_path" 39431 # Check if we need to convert this using DOS-style short mode. If the path 39432 # contains just simple characters, use it. Otherwise (spaces, weird characters), 39433 # take no chances and rewrite it. 39434 # Note: m4 eats our [], so we need to use [ and ] instead. 39435 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 39436 if test "x$has_forbidden_chars" != x; then 39437 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 39438 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 39439 fi 39440 39441 # Output is in $new_path 39442 39443 windows_path="$new_path" 39444 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 39445 unix_path=`$CYGPATH -u "$windows_path"` 39446 new_path="$unix_path" 39447 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 39448 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 39449 new_path="$unix_path" 39450 fi 39451 39452 # remove trailing .exe if any 39453 new_path="${new_path/%.exe/}" 39454 39455 # Save the first 10 bytes of this path to the storage, so fixpath can work. 39456 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 39457 fi 39458 39459 else 39460 # We're on a unix platform. Hooray! :) 39461 # First separate the path from the arguments. This will split at the first 39462 # space. 39463 complete="$DUMPBIN" 39464 path="${complete%% *}" 39465 tmp="$complete EOL" 39466 arguments="${tmp#* }" 39467 39468 # Cannot rely on the command "which" here since it doesn't always work. 39469 is_absolute_path=`$ECHO "$path" | $GREP ^/` 39470 if test -z "$is_absolute_path"; then 39471 # Path to executable is not absolute. Find it. 39472 IFS_save="$IFS" 39473 IFS=: 39474 for p in $PATH; do 39475 if test -f "$p/$path" && test -x "$p/$path"; then 39476 new_path="$p/$path" 39477 break 39478 fi 39479 done 39480 IFS="$IFS_save" 39481 else 39482 # This is an absolute path, we can use it without further modifications. 39483 new_path="$path" 39484 fi 39485 39486 if test "x$new_path" = x; then 39487 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of DUMPBIN, which resolves as \"$complete\", is not found." >&5 39488 $as_echo "$as_me: The path of DUMPBIN, which resolves as \"$complete\", is not found." >&6;} 39489 has_space=`$ECHO "$complete" | $GREP " "` 39490 if test "x$has_space" != x; then 39491 { $as_echo "$as_me:${as_lineno-$LINENO}: This might be caused by spaces in the path, which is not allowed." >&5 39492 $as_echo "$as_me: This might be caused by spaces in the path, which is not allowed." >&6;} 39493 fi 39494 as_fn_error $? "Cannot locate the the path of DUMPBIN" "$LINENO" 5 39495 fi 39496 fi 39497 39498 # Now join together the path and the arguments once again 39499 if test "x$arguments" != xEOL; then 39500 new_complete="$new_path ${arguments% *}" 39501 else 39502 new_complete="$new_path" 39503 fi 39504 39505 if test "x$complete" != "x$new_complete"; then 39506 DUMPBIN="$new_complete" 39507 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting DUMPBIN to \"$new_complete\"" >&5 39508 $as_echo "$as_me: Rewriting DUMPBIN to \"$new_complete\"" >&6;} 39509 fi 39510 fi 39511 39512 # We need to check for 'msbuild.exe' because at the place where we expect to 39513 # find 'msbuild.exe' there's also a directory called 'msbuild' and configure 39514 # won't find the 'msbuild.exe' executable in that case (and the 39515 # 'ac_executable_extensions' is unusable due to performance reasons). 39516 # Notice that we intentionally don't fix up the path to MSBUILD because we 39517 # will call it in a DOS shell during freetype detection on Windows (see 39518 # 'LIB_SETUP_FREETYPE' in "libraries.m4" 39519 # Extract the first word of "msbuild.exe", so it can be a program name with args. 39520 set dummy msbuild.exe; ac_word=$2 39521 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 39522 $as_echo_n "checking for $ac_word... " >&6; } 39523 if ${ac_cv_prog_MSBUILD+:} false; then : 39524 $as_echo_n "(cached) " >&6 39525 else 39526 if test -n "$MSBUILD"; then 39527 ac_cv_prog_MSBUILD="$MSBUILD" # Let the user override the test. 39528 else 39529 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 39530 for as_dir in $PATH 39531 do 39532 IFS=$as_save_IFS 39533 test -z "$as_dir" && as_dir=. 39534 for ac_exec_ext in '' $ac_executable_extensions; do 39535 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 39536 ac_cv_prog_MSBUILD="msbuild.exe" 39537 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 39538 break 2 39539 fi 39540 done 39541 done 39542 IFS=$as_save_IFS 39543 39544 fi 39545 fi 39546 MSBUILD=$ac_cv_prog_MSBUILD 39547 if test -n "$MSBUILD"; then 39548 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MSBUILD" >&5 39549 $as_echo "$MSBUILD" >&6; } 39550 else 39551 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 39552 $as_echo "no" >&6; } 39553 fi 39554 39555 39556 fi 39557 39558 if test "x$OPENJDK_TARGET_OS" = xsolaris; then 39559 39560 39561 # Publish this variable in the help. 39562 39563 39564 if [ -z "${STRIP+x}" ]; then 39565 # The variable is not set by user, try to locate tool using the code snippet 39566 for ac_prog in strip 39567 do 39568 # Extract the first word of "$ac_prog", so it can be a program name with args. 39569 set dummy $ac_prog; ac_word=$2 39570 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 39571 $as_echo_n "checking for $ac_word... " >&6; } 39572 if ${ac_cv_path_STRIP+:} false; then : 39573 $as_echo_n "(cached) " >&6 39574 else 39575 case $STRIP in 39576 [\\/]* | ?:[\\/]*) 39577 ac_cv_path_STRIP="$STRIP" # Let the user override the test with a path. 39578 ;; 39579 *) 39580 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 39581 for as_dir in $PATH 39582 do 39583 IFS=$as_save_IFS 39584 test -z "$as_dir" && as_dir=. 39585 for ac_exec_ext in '' $ac_executable_extensions; do 39586 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 39587 ac_cv_path_STRIP="$as_dir/$ac_word$ac_exec_ext" 39588 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 39589 break 2 39590 fi 39591 done 39592 done 39593 IFS=$as_save_IFS 39594 39595 ;; 39596 esac 39597 fi 39598 STRIP=$ac_cv_path_STRIP 39599 if test -n "$STRIP"; then 39600 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $STRIP" >&5 39601 $as_echo "$STRIP" >&6; } 39602 else 39603 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 39604 $as_echo "no" >&6; } 39605 fi 39606 39607 39608 test -n "$STRIP" && break 39609 done 39610 39611 else 39612 # The variable is set, but is it from the command line or the environment? 39613 39614 # Try to remove the string !STRIP! from our list. 39615 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!STRIP!/} 39616 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 39617 # If it failed, the variable was not from the command line. Ignore it, 39618 # but warn the user (except for BASH, which is always set by the calling BASH). 39619 if test "xSTRIP" != xBASH; then 39620 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of STRIP from the environment. Use command line variables instead." >&5 39621 $as_echo "$as_me: WARNING: Ignoring value of STRIP from the environment. Use command line variables instead." >&2;} 39622 fi 39623 # Try to locate tool using the code snippet 39624 for ac_prog in strip 39625 do 39626 # Extract the first word of "$ac_prog", so it can be a program name with args. 39627 set dummy $ac_prog; ac_word=$2 39628 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 39629 $as_echo_n "checking for $ac_word... " >&6; } 39630 if ${ac_cv_path_STRIP+:} false; then : 39631 $as_echo_n "(cached) " >&6 39632 else 39633 case $STRIP in 39634 [\\/]* | ?:[\\/]*) 39635 ac_cv_path_STRIP="$STRIP" # Let the user override the test with a path. 39636 ;; 39637 *) 39638 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 39639 for as_dir in $PATH 39640 do 39641 IFS=$as_save_IFS 39642 test -z "$as_dir" && as_dir=. 39643 for ac_exec_ext in '' $ac_executable_extensions; do 39644 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 39645 ac_cv_path_STRIP="$as_dir/$ac_word$ac_exec_ext" 39646 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 39647 break 2 39648 fi 39649 done 39650 done 39651 IFS=$as_save_IFS 39652 39653 ;; 39654 esac 39655 fi 39656 STRIP=$ac_cv_path_STRIP 39657 if test -n "$STRIP"; then 39658 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $STRIP" >&5 39659 $as_echo "$STRIP" >&6; } 39660 else 39661 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 39662 $as_echo "no" >&6; } 39663 fi 39664 39665 39666 test -n "$STRIP" && break 39667 done 39668 39669 else 39670 # If it succeeded, then it was overridden by the user. We will use it 39671 # for the tool. 39672 39673 # First remove it from the list of overridden variables, so we can test 39674 # for unknown variables in the end. 39675 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 39676 39677 # Check if we try to supply an empty value 39678 if test "x$STRIP" = x; then 39679 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool STRIP= (no value)" >&5 39680 $as_echo "$as_me: Setting user supplied tool STRIP= (no value)" >&6;} 39681 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for STRIP" >&5 39682 $as_echo_n "checking for STRIP... " >&6; } 39683 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 39684 $as_echo "disabled" >&6; } 39685 else 39686 # Check if the provided tool contains a complete path. 39687 tool_specified="$STRIP" 39688 tool_basename="${tool_specified##*/}" 39689 if test "x$tool_basename" = "x$tool_specified"; then 39690 # A command without a complete path is provided, search $PATH. 39691 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool STRIP=$tool_basename" >&5 39692 $as_echo "$as_me: Will search for user supplied tool STRIP=$tool_basename" >&6;} 39693 # Extract the first word of "$tool_basename", so it can be a program name with args. 39694 set dummy $tool_basename; ac_word=$2 39695 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 39696 $as_echo_n "checking for $ac_word... " >&6; } 39697 if ${ac_cv_path_STRIP+:} false; then : 39698 $as_echo_n "(cached) " >&6 39699 else 39700 case $STRIP in 39701 [\\/]* | ?:[\\/]*) 39702 ac_cv_path_STRIP="$STRIP" # Let the user override the test with a path. 39703 ;; 39704 *) 39705 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 39706 for as_dir in $PATH 39707 do 39708 IFS=$as_save_IFS 39709 test -z "$as_dir" && as_dir=. 39710 for ac_exec_ext in '' $ac_executable_extensions; do 39711 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 39712 ac_cv_path_STRIP="$as_dir/$ac_word$ac_exec_ext" 39713 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 39714 break 2 39715 fi 39716 done 39717 done 39718 IFS=$as_save_IFS 39719 39720 ;; 39721 esac 39722 fi 39723 STRIP=$ac_cv_path_STRIP 39724 if test -n "$STRIP"; then 39725 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $STRIP" >&5 39726 $as_echo "$STRIP" >&6; } 39727 else 39728 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 39729 $as_echo "no" >&6; } 39730 fi 39731 39732 39733 if test "x$STRIP" = x; then 39734 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 39735 fi 39736 else 39737 # Otherwise we believe it is a complete path. Use it as it is. 39738 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool STRIP=$tool_specified" >&5 39739 $as_echo "$as_me: Will use user supplied tool STRIP=$tool_specified" >&6;} 39740 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for STRIP" >&5 39741 $as_echo_n "checking for STRIP... " >&6; } 39742 if test ! -x "$tool_specified"; then 39743 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 39744 $as_echo "not found" >&6; } 39745 as_fn_error $? "User supplied tool STRIP=$tool_specified does not exist or is not executable" "$LINENO" 5 39746 fi 39747 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 39748 $as_echo "$tool_specified" >&6; } 39749 fi 39750 fi 39751 fi 39752 39753 fi 39754 39755 39756 39757 # Only process if variable expands to non-empty 39758 39759 if test "x$STRIP" != x; then 39760 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 39761 39762 # First separate the path from the arguments. This will split at the first 39763 # space. 39764 complete="$STRIP" 39765 path="${complete%% *}" 39766 tmp="$complete EOL" 39767 arguments="${tmp#* }" 39768 39769 # Input might be given as Windows format, start by converting to 39770 # unix format. 39771 new_path=`$CYGPATH -u "$path"` 39772 39773 # Now try to locate executable using which 39774 new_path=`$WHICH "$new_path" 2> /dev/null` 39775 # bat and cmd files are not always considered executable in cygwin causing which 39776 # to not find them 39777 if test "x$new_path" = x \ 39778 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 39779 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 39780 new_path=`$CYGPATH -u "$path"` 39781 fi 39782 if test "x$new_path" = x; then 39783 # Oops. Which didn't find the executable. 39784 # The splitting of arguments from the executable at a space might have been incorrect, 39785 # since paths with space are more likely in Windows. Give it another try with the whole 39786 # argument. 39787 path="$complete" 39788 arguments="EOL" 39789 new_path=`$CYGPATH -u "$path"` 39790 new_path=`$WHICH "$new_path" 2> /dev/null` 39791 # bat and cmd files are not always considered executable in cygwin causing which 39792 # to not find them 39793 if test "x$new_path" = x \ 39794 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 39795 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 39796 new_path=`$CYGPATH -u "$path"` 39797 fi 39798 if test "x$new_path" = x; then 39799 # It's still not found. Now this is an unrecoverable error. 39800 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of STRIP, which resolves as \"$complete\", is not found." >&5 39801 $as_echo "$as_me: The path of STRIP, which resolves as \"$complete\", is not found." >&6;} 39802 has_space=`$ECHO "$complete" | $GREP " "` 39803 if test "x$has_space" != x; then 39804 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 39805 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 39806 fi 39807 as_fn_error $? "Cannot locate the the path of STRIP" "$LINENO" 5 39808 fi 39809 fi 39810 39811 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 39812 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 39813 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 39814 # "foo.exe" is OK but "foo" is an error. 39815 # 39816 # This test is therefore slightly more accurate than "test -f" to check for file presence. 39817 # It is also a way to make sure we got the proper file name for the real test later on. 39818 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 39819 if test "x$test_shortpath" = x; then 39820 # Short path failed, file does not exist as specified. 39821 # Try adding .exe or .cmd 39822 if test -f "${new_path}.exe"; then 39823 input_to_shortpath="${new_path}.exe" 39824 elif test -f "${new_path}.cmd"; then 39825 input_to_shortpath="${new_path}.cmd" 39826 else 39827 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of STRIP, which resolves as \"$new_path\", is invalid." >&5 39828 $as_echo "$as_me: The path of STRIP, which resolves as \"$new_path\", is invalid." >&6;} 39829 { $as_echo "$as_me:${as_lineno-$LINENO}: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&5 39830 $as_echo "$as_me: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&6;} 39831 as_fn_error $? "Cannot locate the the path of STRIP" "$LINENO" 5 39832 fi 39833 else 39834 input_to_shortpath="$new_path" 39835 fi 39836 39837 # Call helper function which possibly converts this using DOS-style short mode. 39838 # If so, the updated path is stored in $new_path. 39839 new_path="$input_to_shortpath" 39840 39841 input_path="$input_to_shortpath" 39842 # Check if we need to convert this using DOS-style short mode. If the path 39843 # contains just simple characters, use it. Otherwise (spaces, weird characters), 39844 # take no chances and rewrite it. 39845 # Note: m4 eats our [], so we need to use [ and ] instead. 39846 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 39847 if test "x$has_forbidden_chars" != x; then 39848 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 39849 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 39850 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 39851 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 39852 # Going to short mode and back again did indeed matter. Since short mode is 39853 # case insensitive, let's make it lowercase to improve readability. 39854 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 39855 # Now convert it back to Unix-style (cygpath) 39856 input_path=`$CYGPATH -u "$shortmode_path"` 39857 new_path="$input_path" 39858 fi 39859 fi 39860 39861 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 39862 if test "x$test_cygdrive_prefix" = x; then 39863 # As a simple fix, exclude /usr/bin since it's not a real path. 39864 if test "x`$ECHO $input_to_shortpath | $GREP ^/usr/bin/`" = x; then 39865 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 39866 # a path prefixed by /cygdrive for fixpath to work. 39867 new_path="$CYGWIN_ROOT_PATH$input_path" 39868 fi 39869 fi 39870 39871 # remove trailing .exe if any 39872 new_path="${new_path/%.exe/}" 39873 39874 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 39875 39876 # First separate the path from the arguments. This will split at the first 39877 # space. 39878 complete="$STRIP" 39879 path="${complete%% *}" 39880 tmp="$complete EOL" 39881 arguments="${tmp#* }" 39882 39883 # Input might be given as Windows format, start by converting to 39884 # unix format. 39885 new_path="$path" 39886 39887 windows_path="$new_path" 39888 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 39889 unix_path=`$CYGPATH -u "$windows_path"` 39890 new_path="$unix_path" 39891 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 39892 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 39893 new_path="$unix_path" 39894 fi 39895 39896 39897 # Now try to locate executable using which 39898 new_path=`$WHICH "$new_path" 2> /dev/null` 39899 39900 if test "x$new_path" = x; then 39901 # Oops. Which didn't find the executable. 39902 # The splitting of arguments from the executable at a space might have been incorrect, 39903 # since paths with space are more likely in Windows. Give it another try with the whole 39904 # argument. 39905 path="$complete" 39906 arguments="EOL" 39907 new_path="$path" 39908 39909 windows_path="$new_path" 39910 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 39911 unix_path=`$CYGPATH -u "$windows_path"` 39912 new_path="$unix_path" 39913 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 39914 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 39915 new_path="$unix_path" 39916 fi 39917 39918 39919 new_path=`$WHICH "$new_path" 2> /dev/null` 39920 # bat and cmd files are not always considered executable in MSYS causing which 39921 # to not find them 39922 if test "x$new_path" = x \ 39923 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 39924 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 39925 new_path="$path" 39926 39927 windows_path="$new_path" 39928 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 39929 unix_path=`$CYGPATH -u "$windows_path"` 39930 new_path="$unix_path" 39931 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 39932 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 39933 new_path="$unix_path" 39934 fi 39935 39936 fi 39937 39938 if test "x$new_path" = x; then 39939 # It's still not found. Now this is an unrecoverable error. 39940 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of STRIP, which resolves as \"$complete\", is not found." >&5 39941 $as_echo "$as_me: The path of STRIP, which resolves as \"$complete\", is not found." >&6;} 39942 has_space=`$ECHO "$complete" | $GREP " "` 39943 if test "x$has_space" != x; then 39944 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 39945 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 39946 fi 39947 as_fn_error $? "Cannot locate the the path of STRIP" "$LINENO" 5 39948 fi 39949 fi 39950 39951 # Now new_path has a complete unix path to the binary 39952 if test "x`$ECHO $new_path | $GREP ^/bin/`" != x; then 39953 # Keep paths in /bin as-is, but remove trailing .exe if any 39954 new_path="${new_path/%.exe/}" 39955 # Do not save /bin paths to all_fixpath_prefixes! 39956 else 39957 # Not in mixed or Windows style, start by that. 39958 new_path=`cmd //c echo $new_path` 39959 39960 input_path="$new_path" 39961 # Check if we need to convert this using DOS-style short mode. If the path 39962 # contains just simple characters, use it. Otherwise (spaces, weird characters), 39963 # take no chances and rewrite it. 39964 # Note: m4 eats our [], so we need to use [ and ] instead. 39965 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 39966 if test "x$has_forbidden_chars" != x; then 39967 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 39968 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 39969 fi 39970 39971 # Output is in $new_path 39972 39973 windows_path="$new_path" 39974 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 39975 unix_path=`$CYGPATH -u "$windows_path"` 39976 new_path="$unix_path" 39977 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 39978 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 39979 new_path="$unix_path" 39980 fi 39981 39982 # remove trailing .exe if any 39983 new_path="${new_path/%.exe/}" 39984 39985 # Save the first 10 bytes of this path to the storage, so fixpath can work. 39986 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 39987 fi 39988 39989 else 39990 # We're on a unix platform. Hooray! :) 39991 # First separate the path from the arguments. This will split at the first 39992 # space. 39993 complete="$STRIP" 39994 path="${complete%% *}" 39995 tmp="$complete EOL" 39996 arguments="${tmp#* }" 39997 39998 # Cannot rely on the command "which" here since it doesn't always work. 39999 is_absolute_path=`$ECHO "$path" | $GREP ^/` 40000 if test -z "$is_absolute_path"; then 40001 # Path to executable is not absolute. Find it. 40002 IFS_save="$IFS" 40003 IFS=: 40004 for p in $PATH; do 40005 if test -f "$p/$path" && test -x "$p/$path"; then 40006 new_path="$p/$path" 40007 break 40008 fi 40009 done 40010 IFS="$IFS_save" 40011 else 40012 # This is an absolute path, we can use it without further modifications. 40013 new_path="$path" 40014 fi 40015 40016 if test "x$new_path" = x; then 40017 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of STRIP, which resolves as \"$complete\", is not found." >&5 40018 $as_echo "$as_me: The path of STRIP, which resolves as \"$complete\", is not found." >&6;} 40019 has_space=`$ECHO "$complete" | $GREP " "` 40020 if test "x$has_space" != x; then 40021 { $as_echo "$as_me:${as_lineno-$LINENO}: This might be caused by spaces in the path, which is not allowed." >&5 40022 $as_echo "$as_me: This might be caused by spaces in the path, which is not allowed." >&6;} 40023 fi 40024 as_fn_error $? "Cannot locate the the path of STRIP" "$LINENO" 5 40025 fi 40026 fi 40027 40028 # Now join together the path and the arguments once again 40029 if test "x$arguments" != xEOL; then 40030 new_complete="$new_path ${arguments% *}" 40031 else 40032 new_complete="$new_path" 40033 fi 40034 40035 if test "x$complete" != "x$new_complete"; then 40036 STRIP="$new_complete" 40037 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting STRIP to \"$new_complete\"" >&5 40038 $as_echo "$as_me: Rewriting STRIP to \"$new_complete\"" >&6;} 40039 fi 40040 fi 40041 40042 40043 40044 # Publish this variable in the help. 40045 40046 40047 if [ -z "${NM+x}" ]; then 40048 # The variable is not set by user, try to locate tool using the code snippet 40049 for ac_prog in nm 40050 do 40051 # Extract the first word of "$ac_prog", so it can be a program name with args. 40052 set dummy $ac_prog; ac_word=$2 40053 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 40054 $as_echo_n "checking for $ac_word... " >&6; } 40055 if ${ac_cv_path_NM+:} false; then : 40056 $as_echo_n "(cached) " >&6 40057 else 40058 case $NM in 40059 [\\/]* | ?:[\\/]*) 40060 ac_cv_path_NM="$NM" # Let the user override the test with a path. 40061 ;; 40062 *) 40063 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 40064 for as_dir in $PATH 40065 do 40066 IFS=$as_save_IFS 40067 test -z "$as_dir" && as_dir=. 40068 for ac_exec_ext in '' $ac_executable_extensions; do 40069 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 40070 ac_cv_path_NM="$as_dir/$ac_word$ac_exec_ext" 40071 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 40072 break 2 40073 fi 40074 done 40075 done 40076 IFS=$as_save_IFS 40077 40078 ;; 40079 esac 40080 fi 40081 NM=$ac_cv_path_NM 40082 if test -n "$NM"; then 40083 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $NM" >&5 40084 $as_echo "$NM" >&6; } 40085 else 40086 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 40087 $as_echo "no" >&6; } 40088 fi 40089 40090 40091 test -n "$NM" && break 40092 done 40093 40094 else 40095 # The variable is set, but is it from the command line or the environment? 40096 40097 # Try to remove the string !NM! from our list. 40098 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!NM!/} 40099 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 40100 # If it failed, the variable was not from the command line. Ignore it, 40101 # but warn the user (except for BASH, which is always set by the calling BASH). 40102 if test "xNM" != xBASH; then 40103 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of NM from the environment. Use command line variables instead." >&5 40104 $as_echo "$as_me: WARNING: Ignoring value of NM from the environment. Use command line variables instead." >&2;} 40105 fi 40106 # Try to locate tool using the code snippet 40107 for ac_prog in nm 40108 do 40109 # Extract the first word of "$ac_prog", so it can be a program name with args. 40110 set dummy $ac_prog; ac_word=$2 40111 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 40112 $as_echo_n "checking for $ac_word... " >&6; } 40113 if ${ac_cv_path_NM+:} false; then : 40114 $as_echo_n "(cached) " >&6 40115 else 40116 case $NM in 40117 [\\/]* | ?:[\\/]*) 40118 ac_cv_path_NM="$NM" # Let the user override the test with a path. 40119 ;; 40120 *) 40121 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 40122 for as_dir in $PATH 40123 do 40124 IFS=$as_save_IFS 40125 test -z "$as_dir" && as_dir=. 40126 for ac_exec_ext in '' $ac_executable_extensions; do 40127 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 40128 ac_cv_path_NM="$as_dir/$ac_word$ac_exec_ext" 40129 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 40130 break 2 40131 fi 40132 done 40133 done 40134 IFS=$as_save_IFS 40135 40136 ;; 40137 esac 40138 fi 40139 NM=$ac_cv_path_NM 40140 if test -n "$NM"; then 40141 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $NM" >&5 40142 $as_echo "$NM" >&6; } 40143 else 40144 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 40145 $as_echo "no" >&6; } 40146 fi 40147 40148 40149 test -n "$NM" && break 40150 done 40151 40152 else 40153 # If it succeeded, then it was overridden by the user. We will use it 40154 # for the tool. 40155 40156 # First remove it from the list of overridden variables, so we can test 40157 # for unknown variables in the end. 40158 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 40159 40160 # Check if we try to supply an empty value 40161 if test "x$NM" = x; then 40162 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool NM= (no value)" >&5 40163 $as_echo "$as_me: Setting user supplied tool NM= (no value)" >&6;} 40164 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for NM" >&5 40165 $as_echo_n "checking for NM... " >&6; } 40166 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 40167 $as_echo "disabled" >&6; } 40168 else 40169 # Check if the provided tool contains a complete path. 40170 tool_specified="$NM" 40171 tool_basename="${tool_specified##*/}" 40172 if test "x$tool_basename" = "x$tool_specified"; then 40173 # A command without a complete path is provided, search $PATH. 40174 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool NM=$tool_basename" >&5 40175 $as_echo "$as_me: Will search for user supplied tool NM=$tool_basename" >&6;} 40176 # Extract the first word of "$tool_basename", so it can be a program name with args. 40177 set dummy $tool_basename; ac_word=$2 40178 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 40179 $as_echo_n "checking for $ac_word... " >&6; } 40180 if ${ac_cv_path_NM+:} false; then : 40181 $as_echo_n "(cached) " >&6 40182 else 40183 case $NM in 40184 [\\/]* | ?:[\\/]*) 40185 ac_cv_path_NM="$NM" # Let the user override the test with a path. 40186 ;; 40187 *) 40188 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 40189 for as_dir in $PATH 40190 do 40191 IFS=$as_save_IFS 40192 test -z "$as_dir" && as_dir=. 40193 for ac_exec_ext in '' $ac_executable_extensions; do 40194 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 40195 ac_cv_path_NM="$as_dir/$ac_word$ac_exec_ext" 40196 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 40197 break 2 40198 fi 40199 done 40200 done 40201 IFS=$as_save_IFS 40202 40203 ;; 40204 esac 40205 fi 40206 NM=$ac_cv_path_NM 40207 if test -n "$NM"; then 40208 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $NM" >&5 40209 $as_echo "$NM" >&6; } 40210 else 40211 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 40212 $as_echo "no" >&6; } 40213 fi 40214 40215 40216 if test "x$NM" = x; then 40217 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 40218 fi 40219 else 40220 # Otherwise we believe it is a complete path. Use it as it is. 40221 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool NM=$tool_specified" >&5 40222 $as_echo "$as_me: Will use user supplied tool NM=$tool_specified" >&6;} 40223 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for NM" >&5 40224 $as_echo_n "checking for NM... " >&6; } 40225 if test ! -x "$tool_specified"; then 40226 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 40227 $as_echo "not found" >&6; } 40228 as_fn_error $? "User supplied tool NM=$tool_specified does not exist or is not executable" "$LINENO" 5 40229 fi 40230 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 40231 $as_echo "$tool_specified" >&6; } 40232 fi 40233 fi 40234 fi 40235 40236 fi 40237 40238 40239 40240 # Only process if variable expands to non-empty 40241 40242 if test "x$NM" != x; then 40243 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 40244 40245 # First separate the path from the arguments. This will split at the first 40246 # space. 40247 complete="$NM" 40248 path="${complete%% *}" 40249 tmp="$complete EOL" 40250 arguments="${tmp#* }" 40251 40252 # Input might be given as Windows format, start by converting to 40253 # unix format. 40254 new_path=`$CYGPATH -u "$path"` 40255 40256 # Now try to locate executable using which 40257 new_path=`$WHICH "$new_path" 2> /dev/null` 40258 # bat and cmd files are not always considered executable in cygwin causing which 40259 # to not find them 40260 if test "x$new_path" = x \ 40261 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 40262 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 40263 new_path=`$CYGPATH -u "$path"` 40264 fi 40265 if test "x$new_path" = x; then 40266 # Oops. Which didn't find the executable. 40267 # The splitting of arguments from the executable at a space might have been incorrect, 40268 # since paths with space are more likely in Windows. Give it another try with the whole 40269 # argument. 40270 path="$complete" 40271 arguments="EOL" 40272 new_path=`$CYGPATH -u "$path"` 40273 new_path=`$WHICH "$new_path" 2> /dev/null` 40274 # bat and cmd files are not always considered executable in cygwin causing which 40275 # to not find them 40276 if test "x$new_path" = x \ 40277 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 40278 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 40279 new_path=`$CYGPATH -u "$path"` 40280 fi 40281 if test "x$new_path" = x; then 40282 # It's still not found. Now this is an unrecoverable error. 40283 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of NM, which resolves as \"$complete\", is not found." >&5 40284 $as_echo "$as_me: The path of NM, which resolves as \"$complete\", is not found." >&6;} 40285 has_space=`$ECHO "$complete" | $GREP " "` 40286 if test "x$has_space" != x; then 40287 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 40288 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 40289 fi 40290 as_fn_error $? "Cannot locate the the path of NM" "$LINENO" 5 40291 fi 40292 fi 40293 40294 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 40295 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 40296 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 40297 # "foo.exe" is OK but "foo" is an error. 40298 # 40299 # This test is therefore slightly more accurate than "test -f" to check for file presence. 40300 # It is also a way to make sure we got the proper file name for the real test later on. 40301 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 40302 if test "x$test_shortpath" = x; then 40303 # Short path failed, file does not exist as specified. 40304 # Try adding .exe or .cmd 40305 if test -f "${new_path}.exe"; then 40306 input_to_shortpath="${new_path}.exe" 40307 elif test -f "${new_path}.cmd"; then 40308 input_to_shortpath="${new_path}.cmd" 40309 else 40310 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of NM, which resolves as \"$new_path\", is invalid." >&5 40311 $as_echo "$as_me: The path of NM, which resolves as \"$new_path\", is invalid." >&6;} 40312 { $as_echo "$as_me:${as_lineno-$LINENO}: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&5 40313 $as_echo "$as_me: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&6;} 40314 as_fn_error $? "Cannot locate the the path of NM" "$LINENO" 5 40315 fi 40316 else 40317 input_to_shortpath="$new_path" 40318 fi 40319 40320 # Call helper function which possibly converts this using DOS-style short mode. 40321 # If so, the updated path is stored in $new_path. 40322 new_path="$input_to_shortpath" 40323 40324 input_path="$input_to_shortpath" 40325 # Check if we need to convert this using DOS-style short mode. If the path 40326 # contains just simple characters, use it. Otherwise (spaces, weird characters), 40327 # take no chances and rewrite it. 40328 # Note: m4 eats our [], so we need to use [ and ] instead. 40329 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 40330 if test "x$has_forbidden_chars" != x; then 40331 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 40332 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 40333 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 40334 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 40335 # Going to short mode and back again did indeed matter. Since short mode is 40336 # case insensitive, let's make it lowercase to improve readability. 40337 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 40338 # Now convert it back to Unix-style (cygpath) 40339 input_path=`$CYGPATH -u "$shortmode_path"` 40340 new_path="$input_path" 40341 fi 40342 fi 40343 40344 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 40345 if test "x$test_cygdrive_prefix" = x; then 40346 # As a simple fix, exclude /usr/bin since it's not a real path. 40347 if test "x`$ECHO $input_to_shortpath | $GREP ^/usr/bin/`" = x; then 40348 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 40349 # a path prefixed by /cygdrive for fixpath to work. 40350 new_path="$CYGWIN_ROOT_PATH$input_path" 40351 fi 40352 fi 40353 40354 # remove trailing .exe if any 40355 new_path="${new_path/%.exe/}" 40356 40357 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 40358 40359 # First separate the path from the arguments. This will split at the first 40360 # space. 40361 complete="$NM" 40362 path="${complete%% *}" 40363 tmp="$complete EOL" 40364 arguments="${tmp#* }" 40365 40366 # Input might be given as Windows format, start by converting to 40367 # unix format. 40368 new_path="$path" 40369 40370 windows_path="$new_path" 40371 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 40372 unix_path=`$CYGPATH -u "$windows_path"` 40373 new_path="$unix_path" 40374 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 40375 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 40376 new_path="$unix_path" 40377 fi 40378 40379 40380 # Now try to locate executable using which 40381 new_path=`$WHICH "$new_path" 2> /dev/null` 40382 40383 if test "x$new_path" = x; then 40384 # Oops. Which didn't find the executable. 40385 # The splitting of arguments from the executable at a space might have been incorrect, 40386 # since paths with space are more likely in Windows. Give it another try with the whole 40387 # argument. 40388 path="$complete" 40389 arguments="EOL" 40390 new_path="$path" 40391 40392 windows_path="$new_path" 40393 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 40394 unix_path=`$CYGPATH -u "$windows_path"` 40395 new_path="$unix_path" 40396 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 40397 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 40398 new_path="$unix_path" 40399 fi 40400 40401 40402 new_path=`$WHICH "$new_path" 2> /dev/null` 40403 # bat and cmd files are not always considered executable in MSYS causing which 40404 # to not find them 40405 if test "x$new_path" = x \ 40406 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 40407 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 40408 new_path="$path" 40409 40410 windows_path="$new_path" 40411 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 40412 unix_path=`$CYGPATH -u "$windows_path"` 40413 new_path="$unix_path" 40414 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 40415 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 40416 new_path="$unix_path" 40417 fi 40418 40419 fi 40420 40421 if test "x$new_path" = x; then 40422 # It's still not found. Now this is an unrecoverable error. 40423 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of NM, which resolves as \"$complete\", is not found." >&5 40424 $as_echo "$as_me: The path of NM, which resolves as \"$complete\", is not found." >&6;} 40425 has_space=`$ECHO "$complete" | $GREP " "` 40426 if test "x$has_space" != x; then 40427 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 40428 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 40429 fi 40430 as_fn_error $? "Cannot locate the the path of NM" "$LINENO" 5 40431 fi 40432 fi 40433 40434 # Now new_path has a complete unix path to the binary 40435 if test "x`$ECHO $new_path | $GREP ^/bin/`" != x; then 40436 # Keep paths in /bin as-is, but remove trailing .exe if any 40437 new_path="${new_path/%.exe/}" 40438 # Do not save /bin paths to all_fixpath_prefixes! 40439 else 40440 # Not in mixed or Windows style, start by that. 40441 new_path=`cmd //c echo $new_path` 40442 40443 input_path="$new_path" 40444 # Check if we need to convert this using DOS-style short mode. If the path 40445 # contains just simple characters, use it. Otherwise (spaces, weird characters), 40446 # take no chances and rewrite it. 40447 # Note: m4 eats our [], so we need to use [ and ] instead. 40448 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 40449 if test "x$has_forbidden_chars" != x; then 40450 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 40451 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 40452 fi 40453 40454 # Output is in $new_path 40455 40456 windows_path="$new_path" 40457 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 40458 unix_path=`$CYGPATH -u "$windows_path"` 40459 new_path="$unix_path" 40460 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 40461 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 40462 new_path="$unix_path" 40463 fi 40464 40465 # remove trailing .exe if any 40466 new_path="${new_path/%.exe/}" 40467 40468 # Save the first 10 bytes of this path to the storage, so fixpath can work. 40469 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 40470 fi 40471 40472 else 40473 # We're on a unix platform. Hooray! :) 40474 # First separate the path from the arguments. This will split at the first 40475 # space. 40476 complete="$NM" 40477 path="${complete%% *}" 40478 tmp="$complete EOL" 40479 arguments="${tmp#* }" 40480 40481 # Cannot rely on the command "which" here since it doesn't always work. 40482 is_absolute_path=`$ECHO "$path" | $GREP ^/` 40483 if test -z "$is_absolute_path"; then 40484 # Path to executable is not absolute. Find it. 40485 IFS_save="$IFS" 40486 IFS=: 40487 for p in $PATH; do 40488 if test -f "$p/$path" && test -x "$p/$path"; then 40489 new_path="$p/$path" 40490 break 40491 fi 40492 done 40493 IFS="$IFS_save" 40494 else 40495 # This is an absolute path, we can use it without further modifications. 40496 new_path="$path" 40497 fi 40498 40499 if test "x$new_path" = x; then 40500 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of NM, which resolves as \"$complete\", is not found." >&5 40501 $as_echo "$as_me: The path of NM, which resolves as \"$complete\", is not found." >&6;} 40502 has_space=`$ECHO "$complete" | $GREP " "` 40503 if test "x$has_space" != x; then 40504 { $as_echo "$as_me:${as_lineno-$LINENO}: This might be caused by spaces in the path, which is not allowed." >&5 40505 $as_echo "$as_me: This might be caused by spaces in the path, which is not allowed." >&6;} 40506 fi 40507 as_fn_error $? "Cannot locate the the path of NM" "$LINENO" 5 40508 fi 40509 fi 40510 40511 # Now join together the path and the arguments once again 40512 if test "x$arguments" != xEOL; then 40513 new_complete="$new_path ${arguments% *}" 40514 else 40515 new_complete="$new_path" 40516 fi 40517 40518 if test "x$complete" != "x$new_complete"; then 40519 NM="$new_complete" 40520 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting NM to \"$new_complete\"" >&5 40521 $as_echo "$as_me: Rewriting NM to \"$new_complete\"" >&6;} 40522 fi 40523 fi 40524 40525 40526 40527 # Publish this variable in the help. 40528 40529 40530 if [ -z "${GNM+x}" ]; then 40531 # The variable is not set by user, try to locate tool using the code snippet 40532 for ac_prog in gnm 40533 do 40534 # Extract the first word of "$ac_prog", so it can be a program name with args. 40535 set dummy $ac_prog; ac_word=$2 40536 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 40537 $as_echo_n "checking for $ac_word... " >&6; } 40538 if ${ac_cv_path_GNM+:} false; then : 40539 $as_echo_n "(cached) " >&6 40540 else 40541 case $GNM in 40542 [\\/]* | ?:[\\/]*) 40543 ac_cv_path_GNM="$GNM" # Let the user override the test with a path. 40544 ;; 40545 *) 40546 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 40547 for as_dir in $PATH 40548 do 40549 IFS=$as_save_IFS 40550 test -z "$as_dir" && as_dir=. 40551 for ac_exec_ext in '' $ac_executable_extensions; do 40552 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 40553 ac_cv_path_GNM="$as_dir/$ac_word$ac_exec_ext" 40554 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 40555 break 2 40556 fi 40557 done 40558 done 40559 IFS=$as_save_IFS 40560 40561 ;; 40562 esac 40563 fi 40564 GNM=$ac_cv_path_GNM 40565 if test -n "$GNM"; then 40566 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $GNM" >&5 40567 $as_echo "$GNM" >&6; } 40568 else 40569 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 40570 $as_echo "no" >&6; } 40571 fi 40572 40573 40574 test -n "$GNM" && break 40575 done 40576 40577 else 40578 # The variable is set, but is it from the command line or the environment? 40579 40580 # Try to remove the string !GNM! from our list. 40581 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!GNM!/} 40582 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 40583 # If it failed, the variable was not from the command line. Ignore it, 40584 # but warn the user (except for BASH, which is always set by the calling BASH). 40585 if test "xGNM" != xBASH; then 40586 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of GNM from the environment. Use command line variables instead." >&5 40587 $as_echo "$as_me: WARNING: Ignoring value of GNM from the environment. Use command line variables instead." >&2;} 40588 fi 40589 # Try to locate tool using the code snippet 40590 for ac_prog in gnm 40591 do 40592 # Extract the first word of "$ac_prog", so it can be a program name with args. 40593 set dummy $ac_prog; ac_word=$2 40594 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 40595 $as_echo_n "checking for $ac_word... " >&6; } 40596 if ${ac_cv_path_GNM+:} false; then : 40597 $as_echo_n "(cached) " >&6 40598 else 40599 case $GNM in 40600 [\\/]* | ?:[\\/]*) 40601 ac_cv_path_GNM="$GNM" # Let the user override the test with a path. 40602 ;; 40603 *) 40604 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 40605 for as_dir in $PATH 40606 do 40607 IFS=$as_save_IFS 40608 test -z "$as_dir" && as_dir=. 40609 for ac_exec_ext in '' $ac_executable_extensions; do 40610 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 40611 ac_cv_path_GNM="$as_dir/$ac_word$ac_exec_ext" 40612 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 40613 break 2 40614 fi 40615 done 40616 done 40617 IFS=$as_save_IFS 40618 40619 ;; 40620 esac 40621 fi 40622 GNM=$ac_cv_path_GNM 40623 if test -n "$GNM"; then 40624 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $GNM" >&5 40625 $as_echo "$GNM" >&6; } 40626 else 40627 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 40628 $as_echo "no" >&6; } 40629 fi 40630 40631 40632 test -n "$GNM" && break 40633 done 40634 40635 else 40636 # If it succeeded, then it was overridden by the user. We will use it 40637 # for the tool. 40638 40639 # First remove it from the list of overridden variables, so we can test 40640 # for unknown variables in the end. 40641 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 40642 40643 # Check if we try to supply an empty value 40644 if test "x$GNM" = x; then 40645 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool GNM= (no value)" >&5 40646 $as_echo "$as_me: Setting user supplied tool GNM= (no value)" >&6;} 40647 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for GNM" >&5 40648 $as_echo_n "checking for GNM... " >&6; } 40649 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 40650 $as_echo "disabled" >&6; } 40651 else 40652 # Check if the provided tool contains a complete path. 40653 tool_specified="$GNM" 40654 tool_basename="${tool_specified##*/}" 40655 if test "x$tool_basename" = "x$tool_specified"; then 40656 # A command without a complete path is provided, search $PATH. 40657 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool GNM=$tool_basename" >&5 40658 $as_echo "$as_me: Will search for user supplied tool GNM=$tool_basename" >&6;} 40659 # Extract the first word of "$tool_basename", so it can be a program name with args. 40660 set dummy $tool_basename; ac_word=$2 40661 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 40662 $as_echo_n "checking for $ac_word... " >&6; } 40663 if ${ac_cv_path_GNM+:} false; then : 40664 $as_echo_n "(cached) " >&6 40665 else 40666 case $GNM in 40667 [\\/]* | ?:[\\/]*) 40668 ac_cv_path_GNM="$GNM" # Let the user override the test with a path. 40669 ;; 40670 *) 40671 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 40672 for as_dir in $PATH 40673 do 40674 IFS=$as_save_IFS 40675 test -z "$as_dir" && as_dir=. 40676 for ac_exec_ext in '' $ac_executable_extensions; do 40677 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 40678 ac_cv_path_GNM="$as_dir/$ac_word$ac_exec_ext" 40679 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 40680 break 2 40681 fi 40682 done 40683 done 40684 IFS=$as_save_IFS 40685 40686 ;; 40687 esac 40688 fi 40689 GNM=$ac_cv_path_GNM 40690 if test -n "$GNM"; then 40691 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $GNM" >&5 40692 $as_echo "$GNM" >&6; } 40693 else 40694 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 40695 $as_echo "no" >&6; } 40696 fi 40697 40698 40699 if test "x$GNM" = x; then 40700 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 40701 fi 40702 else 40703 # Otherwise we believe it is a complete path. Use it as it is. 40704 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool GNM=$tool_specified" >&5 40705 $as_echo "$as_me: Will use user supplied tool GNM=$tool_specified" >&6;} 40706 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for GNM" >&5 40707 $as_echo_n "checking for GNM... " >&6; } 40708 if test ! -x "$tool_specified"; then 40709 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 40710 $as_echo "not found" >&6; } 40711 as_fn_error $? "User supplied tool GNM=$tool_specified does not exist or is not executable" "$LINENO" 5 40712 fi 40713 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 40714 $as_echo "$tool_specified" >&6; } 40715 fi 40716 fi 40717 fi 40718 40719 fi 40720 40721 40722 40723 # Only process if variable expands to non-empty 40724 40725 if test "x$GNM" != x; then 40726 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 40727 40728 # First separate the path from the arguments. This will split at the first 40729 # space. 40730 complete="$GNM" 40731 path="${complete%% *}" 40732 tmp="$complete EOL" 40733 arguments="${tmp#* }" 40734 40735 # Input might be given as Windows format, start by converting to 40736 # unix format. 40737 new_path=`$CYGPATH -u "$path"` 40738 40739 # Now try to locate executable using which 40740 new_path=`$WHICH "$new_path" 2> /dev/null` 40741 # bat and cmd files are not always considered executable in cygwin causing which 40742 # to not find them 40743 if test "x$new_path" = x \ 40744 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 40745 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 40746 new_path=`$CYGPATH -u "$path"` 40747 fi 40748 if test "x$new_path" = x; then 40749 # Oops. Which didn't find the executable. 40750 # The splitting of arguments from the executable at a space might have been incorrect, 40751 # since paths with space are more likely in Windows. Give it another try with the whole 40752 # argument. 40753 path="$complete" 40754 arguments="EOL" 40755 new_path=`$CYGPATH -u "$path"` 40756 new_path=`$WHICH "$new_path" 2> /dev/null` 40757 # bat and cmd files are not always considered executable in cygwin causing which 40758 # to not find them 40759 if test "x$new_path" = x \ 40760 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 40761 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 40762 new_path=`$CYGPATH -u "$path"` 40763 fi 40764 if test "x$new_path" = x; then 40765 # It's still not found. Now this is an unrecoverable error. 40766 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of GNM, which resolves as \"$complete\", is not found." >&5 40767 $as_echo "$as_me: The path of GNM, which resolves as \"$complete\", is not found." >&6;} 40768 has_space=`$ECHO "$complete" | $GREP " "` 40769 if test "x$has_space" != x; then 40770 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 40771 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 40772 fi 40773 as_fn_error $? "Cannot locate the the path of GNM" "$LINENO" 5 40774 fi 40775 fi 40776 40777 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 40778 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 40779 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 40780 # "foo.exe" is OK but "foo" is an error. 40781 # 40782 # This test is therefore slightly more accurate than "test -f" to check for file presence. 40783 # It is also a way to make sure we got the proper file name for the real test later on. 40784 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 40785 if test "x$test_shortpath" = x; then 40786 # Short path failed, file does not exist as specified. 40787 # Try adding .exe or .cmd 40788 if test -f "${new_path}.exe"; then 40789 input_to_shortpath="${new_path}.exe" 40790 elif test -f "${new_path}.cmd"; then 40791 input_to_shortpath="${new_path}.cmd" 40792 else 40793 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of GNM, which resolves as \"$new_path\", is invalid." >&5 40794 $as_echo "$as_me: The path of GNM, which resolves as \"$new_path\", is invalid." >&6;} 40795 { $as_echo "$as_me:${as_lineno-$LINENO}: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&5 40796 $as_echo "$as_me: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&6;} 40797 as_fn_error $? "Cannot locate the the path of GNM" "$LINENO" 5 40798 fi 40799 else 40800 input_to_shortpath="$new_path" 40801 fi 40802 40803 # Call helper function which possibly converts this using DOS-style short mode. 40804 # If so, the updated path is stored in $new_path. 40805 new_path="$input_to_shortpath" 40806 40807 input_path="$input_to_shortpath" 40808 # Check if we need to convert this using DOS-style short mode. If the path 40809 # contains just simple characters, use it. Otherwise (spaces, weird characters), 40810 # take no chances and rewrite it. 40811 # Note: m4 eats our [], so we need to use [ and ] instead. 40812 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 40813 if test "x$has_forbidden_chars" != x; then 40814 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 40815 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 40816 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 40817 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 40818 # Going to short mode and back again did indeed matter. Since short mode is 40819 # case insensitive, let's make it lowercase to improve readability. 40820 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 40821 # Now convert it back to Unix-style (cygpath) 40822 input_path=`$CYGPATH -u "$shortmode_path"` 40823 new_path="$input_path" 40824 fi 40825 fi 40826 40827 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 40828 if test "x$test_cygdrive_prefix" = x; then 40829 # As a simple fix, exclude /usr/bin since it's not a real path. 40830 if test "x`$ECHO $input_to_shortpath | $GREP ^/usr/bin/`" = x; then 40831 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 40832 # a path prefixed by /cygdrive for fixpath to work. 40833 new_path="$CYGWIN_ROOT_PATH$input_path" 40834 fi 40835 fi 40836 40837 # remove trailing .exe if any 40838 new_path="${new_path/%.exe/}" 40839 40840 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 40841 40842 # First separate the path from the arguments. This will split at the first 40843 # space. 40844 complete="$GNM" 40845 path="${complete%% *}" 40846 tmp="$complete EOL" 40847 arguments="${tmp#* }" 40848 40849 # Input might be given as Windows format, start by converting to 40850 # unix format. 40851 new_path="$path" 40852 40853 windows_path="$new_path" 40854 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 40855 unix_path=`$CYGPATH -u "$windows_path"` 40856 new_path="$unix_path" 40857 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 40858 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 40859 new_path="$unix_path" 40860 fi 40861 40862 40863 # Now try to locate executable using which 40864 new_path=`$WHICH "$new_path" 2> /dev/null` 40865 40866 if test "x$new_path" = x; then 40867 # Oops. Which didn't find the executable. 40868 # The splitting of arguments from the executable at a space might have been incorrect, 40869 # since paths with space are more likely in Windows. Give it another try with the whole 40870 # argument. 40871 path="$complete" 40872 arguments="EOL" 40873 new_path="$path" 40874 40875 windows_path="$new_path" 40876 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 40877 unix_path=`$CYGPATH -u "$windows_path"` 40878 new_path="$unix_path" 40879 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 40880 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 40881 new_path="$unix_path" 40882 fi 40883 40884 40885 new_path=`$WHICH "$new_path" 2> /dev/null` 40886 # bat and cmd files are not always considered executable in MSYS causing which 40887 # to not find them 40888 if test "x$new_path" = x \ 40889 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 40890 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 40891 new_path="$path" 40892 40893 windows_path="$new_path" 40894 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 40895 unix_path=`$CYGPATH -u "$windows_path"` 40896 new_path="$unix_path" 40897 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 40898 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 40899 new_path="$unix_path" 40900 fi 40901 40902 fi 40903 40904 if test "x$new_path" = x; then 40905 # It's still not found. Now this is an unrecoverable error. 40906 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of GNM, which resolves as \"$complete\", is not found." >&5 40907 $as_echo "$as_me: The path of GNM, which resolves as \"$complete\", is not found." >&6;} 40908 has_space=`$ECHO "$complete" | $GREP " "` 40909 if test "x$has_space" != x; then 40910 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 40911 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 40912 fi 40913 as_fn_error $? "Cannot locate the the path of GNM" "$LINENO" 5 40914 fi 40915 fi 40916 40917 # Now new_path has a complete unix path to the binary 40918 if test "x`$ECHO $new_path | $GREP ^/bin/`" != x; then 40919 # Keep paths in /bin as-is, but remove trailing .exe if any 40920 new_path="${new_path/%.exe/}" 40921 # Do not save /bin paths to all_fixpath_prefixes! 40922 else 40923 # Not in mixed or Windows style, start by that. 40924 new_path=`cmd //c echo $new_path` 40925 40926 input_path="$new_path" 40927 # Check if we need to convert this using DOS-style short mode. If the path 40928 # contains just simple characters, use it. Otherwise (spaces, weird characters), 40929 # take no chances and rewrite it. 40930 # Note: m4 eats our [], so we need to use [ and ] instead. 40931 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 40932 if test "x$has_forbidden_chars" != x; then 40933 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 40934 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 40935 fi 40936 40937 # Output is in $new_path 40938 40939 windows_path="$new_path" 40940 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 40941 unix_path=`$CYGPATH -u "$windows_path"` 40942 new_path="$unix_path" 40943 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 40944 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 40945 new_path="$unix_path" 40946 fi 40947 40948 # remove trailing .exe if any 40949 new_path="${new_path/%.exe/}" 40950 40951 # Save the first 10 bytes of this path to the storage, so fixpath can work. 40952 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 40953 fi 40954 40955 else 40956 # We're on a unix platform. Hooray! :) 40957 # First separate the path from the arguments. This will split at the first 40958 # space. 40959 complete="$GNM" 40960 path="${complete%% *}" 40961 tmp="$complete EOL" 40962 arguments="${tmp#* }" 40963 40964 # Cannot rely on the command "which" here since it doesn't always work. 40965 is_absolute_path=`$ECHO "$path" | $GREP ^/` 40966 if test -z "$is_absolute_path"; then 40967 # Path to executable is not absolute. Find it. 40968 IFS_save="$IFS" 40969 IFS=: 40970 for p in $PATH; do 40971 if test -f "$p/$path" && test -x "$p/$path"; then 40972 new_path="$p/$path" 40973 break 40974 fi 40975 done 40976 IFS="$IFS_save" 40977 else 40978 # This is an absolute path, we can use it without further modifications. 40979 new_path="$path" 40980 fi 40981 40982 if test "x$new_path" = x; then 40983 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of GNM, which resolves as \"$complete\", is not found." >&5 40984 $as_echo "$as_me: The path of GNM, which resolves as \"$complete\", is not found." >&6;} 40985 has_space=`$ECHO "$complete" | $GREP " "` 40986 if test "x$has_space" != x; then 40987 { $as_echo "$as_me:${as_lineno-$LINENO}: This might be caused by spaces in the path, which is not allowed." >&5 40988 $as_echo "$as_me: This might be caused by spaces in the path, which is not allowed." >&6;} 40989 fi 40990 as_fn_error $? "Cannot locate the the path of GNM" "$LINENO" 5 40991 fi 40992 fi 40993 40994 # Now join together the path and the arguments once again 40995 if test "x$arguments" != xEOL; then 40996 new_complete="$new_path ${arguments% *}" 40997 else 40998 new_complete="$new_path" 40999 fi 41000 41001 if test "x$complete" != "x$new_complete"; then 41002 GNM="$new_complete" 41003 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting GNM to \"$new_complete\"" >&5 41004 $as_echo "$as_me: Rewriting GNM to \"$new_complete\"" >&6;} 41005 fi 41006 fi 41007 41008 elif test "x$OPENJDK_TARGET_OS" != xwindows; then 41009 # FIXME: we should unify this with the solaris case above. 41010 41011 41012 # Publish this variable in the help. 41013 41014 41015 if [ -z "${STRIP+x}" ]; then 41016 # The variable is not set by user, try to locate tool using the code snippet 41017 if test -n "$ac_tool_prefix"; then 41018 for ac_prog in strip 41019 do 41020 # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args. 41021 set dummy $ac_tool_prefix$ac_prog; ac_word=$2 41022 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 41023 $as_echo_n "checking for $ac_word... " >&6; } 41024 if ${ac_cv_prog_STRIP+:} false; then : 41025 $as_echo_n "(cached) " >&6 41026 else 41027 if test -n "$STRIP"; then 41028 ac_cv_prog_STRIP="$STRIP" # Let the user override the test. 41029 else 41030 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 41031 for as_dir in $PATH 41032 do 41033 IFS=$as_save_IFS 41034 test -z "$as_dir" && as_dir=. 41035 for ac_exec_ext in '' $ac_executable_extensions; do 41036 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 41037 ac_cv_prog_STRIP="$ac_tool_prefix$ac_prog" 41038 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 41039 break 2 41040 fi 41041 done 41042 done 41043 IFS=$as_save_IFS 41044 41045 fi 41046 fi 41047 STRIP=$ac_cv_prog_STRIP 41048 if test -n "$STRIP"; then 41049 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $STRIP" >&5 41050 $as_echo "$STRIP" >&6; } 41051 else 41052 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 41053 $as_echo "no" >&6; } 41054 fi 41055 41056 41057 test -n "$STRIP" && break 41058 done 41059 fi 41060 if test -z "$STRIP"; then 41061 ac_ct_STRIP=$STRIP 41062 for ac_prog in strip 41063 do 41064 # Extract the first word of "$ac_prog", so it can be a program name with args. 41065 set dummy $ac_prog; ac_word=$2 41066 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 41067 $as_echo_n "checking for $ac_word... " >&6; } 41068 if ${ac_cv_prog_ac_ct_STRIP+:} false; then : 41069 $as_echo_n "(cached) " >&6 41070 else 41071 if test -n "$ac_ct_STRIP"; then 41072 ac_cv_prog_ac_ct_STRIP="$ac_ct_STRIP" # Let the user override the test. 41073 else 41074 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 41075 for as_dir in $PATH 41076 do 41077 IFS=$as_save_IFS 41078 test -z "$as_dir" && as_dir=. 41079 for ac_exec_ext in '' $ac_executable_extensions; do 41080 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 41081 ac_cv_prog_ac_ct_STRIP="$ac_prog" 41082 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 41083 break 2 41084 fi 41085 done 41086 done 41087 IFS=$as_save_IFS 41088 41089 fi 41090 fi 41091 ac_ct_STRIP=$ac_cv_prog_ac_ct_STRIP 41092 if test -n "$ac_ct_STRIP"; then 41093 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_STRIP" >&5 41094 $as_echo "$ac_ct_STRIP" >&6; } 41095 else 41096 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 41097 $as_echo "no" >&6; } 41098 fi 41099 41100 41101 test -n "$ac_ct_STRIP" && break 41102 done 41103 41104 if test "x$ac_ct_STRIP" = x; then 41105 STRIP="" 41106 else 41107 case $cross_compiling:$ac_tool_warned in 41108 yes:) 41109 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5 41110 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;} 41111 ac_tool_warned=yes ;; 41112 esac 41113 STRIP=$ac_ct_STRIP 41114 fi 41115 fi 41116 41117 else 41118 # The variable is set, but is it from the command line or the environment? 41119 41120 # Try to remove the string !STRIP! from our list. 41121 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!STRIP!/} 41122 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 41123 # If it failed, the variable was not from the command line. Ignore it, 41124 # but warn the user (except for BASH, which is always set by the calling BASH). 41125 if test "xSTRIP" != xBASH; then 41126 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of STRIP from the environment. Use command line variables instead." >&5 41127 $as_echo "$as_me: WARNING: Ignoring value of STRIP from the environment. Use command line variables instead." >&2;} 41128 fi 41129 # Try to locate tool using the code snippet 41130 if test -n "$ac_tool_prefix"; then 41131 for ac_prog in strip 41132 do 41133 # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args. 41134 set dummy $ac_tool_prefix$ac_prog; ac_word=$2 41135 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 41136 $as_echo_n "checking for $ac_word... " >&6; } 41137 if ${ac_cv_prog_STRIP+:} false; then : 41138 $as_echo_n "(cached) " >&6 41139 else 41140 if test -n "$STRIP"; then 41141 ac_cv_prog_STRIP="$STRIP" # Let the user override the test. 41142 else 41143 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 41144 for as_dir in $PATH 41145 do 41146 IFS=$as_save_IFS 41147 test -z "$as_dir" && as_dir=. 41148 for ac_exec_ext in '' $ac_executable_extensions; do 41149 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 41150 ac_cv_prog_STRIP="$ac_tool_prefix$ac_prog" 41151 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 41152 break 2 41153 fi 41154 done 41155 done 41156 IFS=$as_save_IFS 41157 41158 fi 41159 fi 41160 STRIP=$ac_cv_prog_STRIP 41161 if test -n "$STRIP"; then 41162 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $STRIP" >&5 41163 $as_echo "$STRIP" >&6; } 41164 else 41165 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 41166 $as_echo "no" >&6; } 41167 fi 41168 41169 41170 test -n "$STRIP" && break 41171 done 41172 fi 41173 if test -z "$STRIP"; then 41174 ac_ct_STRIP=$STRIP 41175 for ac_prog in strip 41176 do 41177 # Extract the first word of "$ac_prog", so it can be a program name with args. 41178 set dummy $ac_prog; ac_word=$2 41179 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 41180 $as_echo_n "checking for $ac_word... " >&6; } 41181 if ${ac_cv_prog_ac_ct_STRIP+:} false; then : 41182 $as_echo_n "(cached) " >&6 41183 else 41184 if test -n "$ac_ct_STRIP"; then 41185 ac_cv_prog_ac_ct_STRIP="$ac_ct_STRIP" # Let the user override the test. 41186 else 41187 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 41188 for as_dir in $PATH 41189 do 41190 IFS=$as_save_IFS 41191 test -z "$as_dir" && as_dir=. 41192 for ac_exec_ext in '' $ac_executable_extensions; do 41193 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 41194 ac_cv_prog_ac_ct_STRIP="$ac_prog" 41195 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 41196 break 2 41197 fi 41198 done 41199 done 41200 IFS=$as_save_IFS 41201 41202 fi 41203 fi 41204 ac_ct_STRIP=$ac_cv_prog_ac_ct_STRIP 41205 if test -n "$ac_ct_STRIP"; then 41206 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_STRIP" >&5 41207 $as_echo "$ac_ct_STRIP" >&6; } 41208 else 41209 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 41210 $as_echo "no" >&6; } 41211 fi 41212 41213 41214 test -n "$ac_ct_STRIP" && break 41215 done 41216 41217 if test "x$ac_ct_STRIP" = x; then 41218 STRIP="" 41219 else 41220 case $cross_compiling:$ac_tool_warned in 41221 yes:) 41222 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5 41223 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;} 41224 ac_tool_warned=yes ;; 41225 esac 41226 STRIP=$ac_ct_STRIP 41227 fi 41228 fi 41229 41230 else 41231 # If it succeeded, then it was overridden by the user. We will use it 41232 # for the tool. 41233 41234 # First remove it from the list of overridden variables, so we can test 41235 # for unknown variables in the end. 41236 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 41237 41238 # Check if we try to supply an empty value 41239 if test "x$STRIP" = x; then 41240 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool STRIP= (no value)" >&5 41241 $as_echo "$as_me: Setting user supplied tool STRIP= (no value)" >&6;} 41242 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for STRIP" >&5 41243 $as_echo_n "checking for STRIP... " >&6; } 41244 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 41245 $as_echo "disabled" >&6; } 41246 else 41247 # Check if the provided tool contains a complete path. 41248 tool_specified="$STRIP" 41249 tool_basename="${tool_specified##*/}" 41250 if test "x$tool_basename" = "x$tool_specified"; then 41251 # A command without a complete path is provided, search $PATH. 41252 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool STRIP=$tool_basename" >&5 41253 $as_echo "$as_me: Will search for user supplied tool STRIP=$tool_basename" >&6;} 41254 # Extract the first word of "$tool_basename", so it can be a program name with args. 41255 set dummy $tool_basename; ac_word=$2 41256 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 41257 $as_echo_n "checking for $ac_word... " >&6; } 41258 if ${ac_cv_path_STRIP+:} false; then : 41259 $as_echo_n "(cached) " >&6 41260 else 41261 case $STRIP in 41262 [\\/]* | ?:[\\/]*) 41263 ac_cv_path_STRIP="$STRIP" # Let the user override the test with a path. 41264 ;; 41265 *) 41266 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 41267 for as_dir in $PATH 41268 do 41269 IFS=$as_save_IFS 41270 test -z "$as_dir" && as_dir=. 41271 for ac_exec_ext in '' $ac_executable_extensions; do 41272 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 41273 ac_cv_path_STRIP="$as_dir/$ac_word$ac_exec_ext" 41274 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 41275 break 2 41276 fi 41277 done 41278 done 41279 IFS=$as_save_IFS 41280 41281 ;; 41282 esac 41283 fi 41284 STRIP=$ac_cv_path_STRIP 41285 if test -n "$STRIP"; then 41286 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $STRIP" >&5 41287 $as_echo "$STRIP" >&6; } 41288 else 41289 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 41290 $as_echo "no" >&6; } 41291 fi 41292 41293 41294 if test "x$STRIP" = x; then 41295 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 41296 fi 41297 else 41298 # Otherwise we believe it is a complete path. Use it as it is. 41299 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool STRIP=$tool_specified" >&5 41300 $as_echo "$as_me: Will use user supplied tool STRIP=$tool_specified" >&6;} 41301 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for STRIP" >&5 41302 $as_echo_n "checking for STRIP... " >&6; } 41303 if test ! -x "$tool_specified"; then 41304 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 41305 $as_echo "not found" >&6; } 41306 as_fn_error $? "User supplied tool STRIP=$tool_specified does not exist or is not executable" "$LINENO" 5 41307 fi 41308 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 41309 $as_echo "$tool_specified" >&6; } 41310 fi 41311 fi 41312 fi 41313 41314 fi 41315 41316 41317 41318 # Only process if variable expands to non-empty 41319 41320 if test "x$STRIP" != x; then 41321 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 41322 41323 # First separate the path from the arguments. This will split at the first 41324 # space. 41325 complete="$STRIP" 41326 path="${complete%% *}" 41327 tmp="$complete EOL" 41328 arguments="${tmp#* }" 41329 41330 # Input might be given as Windows format, start by converting to 41331 # unix format. 41332 new_path=`$CYGPATH -u "$path"` 41333 41334 # Now try to locate executable using which 41335 new_path=`$WHICH "$new_path" 2> /dev/null` 41336 # bat and cmd files are not always considered executable in cygwin causing which 41337 # to not find them 41338 if test "x$new_path" = x \ 41339 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 41340 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 41341 new_path=`$CYGPATH -u "$path"` 41342 fi 41343 if test "x$new_path" = x; then 41344 # Oops. Which didn't find the executable. 41345 # The splitting of arguments from the executable at a space might have been incorrect, 41346 # since paths with space are more likely in Windows. Give it another try with the whole 41347 # argument. 41348 path="$complete" 41349 arguments="EOL" 41350 new_path=`$CYGPATH -u "$path"` 41351 new_path=`$WHICH "$new_path" 2> /dev/null` 41352 # bat and cmd files are not always considered executable in cygwin causing which 41353 # to not find them 41354 if test "x$new_path" = x \ 41355 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 41356 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 41357 new_path=`$CYGPATH -u "$path"` 41358 fi 41359 if test "x$new_path" = x; then 41360 # It's still not found. Now this is an unrecoverable error. 41361 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of STRIP, which resolves as \"$complete\", is not found." >&5 41362 $as_echo "$as_me: The path of STRIP, which resolves as \"$complete\", is not found." >&6;} 41363 has_space=`$ECHO "$complete" | $GREP " "` 41364 if test "x$has_space" != x; then 41365 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 41366 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 41367 fi 41368 as_fn_error $? "Cannot locate the the path of STRIP" "$LINENO" 5 41369 fi 41370 fi 41371 41372 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 41373 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 41374 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 41375 # "foo.exe" is OK but "foo" is an error. 41376 # 41377 # This test is therefore slightly more accurate than "test -f" to check for file presence. 41378 # It is also a way to make sure we got the proper file name for the real test later on. 41379 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 41380 if test "x$test_shortpath" = x; then 41381 # Short path failed, file does not exist as specified. 41382 # Try adding .exe or .cmd 41383 if test -f "${new_path}.exe"; then 41384 input_to_shortpath="${new_path}.exe" 41385 elif test -f "${new_path}.cmd"; then 41386 input_to_shortpath="${new_path}.cmd" 41387 else 41388 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of STRIP, which resolves as \"$new_path\", is invalid." >&5 41389 $as_echo "$as_me: The path of STRIP, which resolves as \"$new_path\", is invalid." >&6;} 41390 { $as_echo "$as_me:${as_lineno-$LINENO}: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&5 41391 $as_echo "$as_me: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&6;} 41392 as_fn_error $? "Cannot locate the the path of STRIP" "$LINENO" 5 41393 fi 41394 else 41395 input_to_shortpath="$new_path" 41396 fi 41397 41398 # Call helper function which possibly converts this using DOS-style short mode. 41399 # If so, the updated path is stored in $new_path. 41400 new_path="$input_to_shortpath" 41401 41402 input_path="$input_to_shortpath" 41403 # Check if we need to convert this using DOS-style short mode. If the path 41404 # contains just simple characters, use it. Otherwise (spaces, weird characters), 41405 # take no chances and rewrite it. 41406 # Note: m4 eats our [], so we need to use [ and ] instead. 41407 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 41408 if test "x$has_forbidden_chars" != x; then 41409 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 41410 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 41411 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 41412 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 41413 # Going to short mode and back again did indeed matter. Since short mode is 41414 # case insensitive, let's make it lowercase to improve readability. 41415 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 41416 # Now convert it back to Unix-style (cygpath) 41417 input_path=`$CYGPATH -u "$shortmode_path"` 41418 new_path="$input_path" 41419 fi 41420 fi 41421 41422 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 41423 if test "x$test_cygdrive_prefix" = x; then 41424 # As a simple fix, exclude /usr/bin since it's not a real path. 41425 if test "x`$ECHO $input_to_shortpath | $GREP ^/usr/bin/`" = x; then 41426 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 41427 # a path prefixed by /cygdrive for fixpath to work. 41428 new_path="$CYGWIN_ROOT_PATH$input_path" 41429 fi 41430 fi 41431 41432 # remove trailing .exe if any 41433 new_path="${new_path/%.exe/}" 41434 41435 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 41436 41437 # First separate the path from the arguments. This will split at the first 41438 # space. 41439 complete="$STRIP" 41440 path="${complete%% *}" 41441 tmp="$complete EOL" 41442 arguments="${tmp#* }" 41443 41444 # Input might be given as Windows format, start by converting to 41445 # unix format. 41446 new_path="$path" 41447 41448 windows_path="$new_path" 41449 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 41450 unix_path=`$CYGPATH -u "$windows_path"` 41451 new_path="$unix_path" 41452 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 41453 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 41454 new_path="$unix_path" 41455 fi 41456 41457 41458 # Now try to locate executable using which 41459 new_path=`$WHICH "$new_path" 2> /dev/null` 41460 41461 if test "x$new_path" = x; then 41462 # Oops. Which didn't find the executable. 41463 # The splitting of arguments from the executable at a space might have been incorrect, 41464 # since paths with space are more likely in Windows. Give it another try with the whole 41465 # argument. 41466 path="$complete" 41467 arguments="EOL" 41468 new_path="$path" 41469 41470 windows_path="$new_path" 41471 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 41472 unix_path=`$CYGPATH -u "$windows_path"` 41473 new_path="$unix_path" 41474 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 41475 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 41476 new_path="$unix_path" 41477 fi 41478 41479 41480 new_path=`$WHICH "$new_path" 2> /dev/null` 41481 # bat and cmd files are not always considered executable in MSYS causing which 41482 # to not find them 41483 if test "x$new_path" = x \ 41484 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 41485 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 41486 new_path="$path" 41487 41488 windows_path="$new_path" 41489 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 41490 unix_path=`$CYGPATH -u "$windows_path"` 41491 new_path="$unix_path" 41492 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 41493 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 41494 new_path="$unix_path" 41495 fi 41496 41497 fi 41498 41499 if test "x$new_path" = x; then 41500 # It's still not found. Now this is an unrecoverable error. 41501 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of STRIP, which resolves as \"$complete\", is not found." >&5 41502 $as_echo "$as_me: The path of STRIP, which resolves as \"$complete\", is not found." >&6;} 41503 has_space=`$ECHO "$complete" | $GREP " "` 41504 if test "x$has_space" != x; then 41505 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 41506 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 41507 fi 41508 as_fn_error $? "Cannot locate the the path of STRIP" "$LINENO" 5 41509 fi 41510 fi 41511 41512 # Now new_path has a complete unix path to the binary 41513 if test "x`$ECHO $new_path | $GREP ^/bin/`" != x; then 41514 # Keep paths in /bin as-is, but remove trailing .exe if any 41515 new_path="${new_path/%.exe/}" 41516 # Do not save /bin paths to all_fixpath_prefixes! 41517 else 41518 # Not in mixed or Windows style, start by that. 41519 new_path=`cmd //c echo $new_path` 41520 41521 input_path="$new_path" 41522 # Check if we need to convert this using DOS-style short mode. If the path 41523 # contains just simple characters, use it. Otherwise (spaces, weird characters), 41524 # take no chances and rewrite it. 41525 # Note: m4 eats our [], so we need to use [ and ] instead. 41526 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 41527 if test "x$has_forbidden_chars" != x; then 41528 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 41529 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 41530 fi 41531 41532 # Output is in $new_path 41533 41534 windows_path="$new_path" 41535 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 41536 unix_path=`$CYGPATH -u "$windows_path"` 41537 new_path="$unix_path" 41538 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 41539 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 41540 new_path="$unix_path" 41541 fi 41542 41543 # remove trailing .exe if any 41544 new_path="${new_path/%.exe/}" 41545 41546 # Save the first 10 bytes of this path to the storage, so fixpath can work. 41547 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 41548 fi 41549 41550 else 41551 # We're on a unix platform. Hooray! :) 41552 # First separate the path from the arguments. This will split at the first 41553 # space. 41554 complete="$STRIP" 41555 path="${complete%% *}" 41556 tmp="$complete EOL" 41557 arguments="${tmp#* }" 41558 41559 # Cannot rely on the command "which" here since it doesn't always work. 41560 is_absolute_path=`$ECHO "$path" | $GREP ^/` 41561 if test -z "$is_absolute_path"; then 41562 # Path to executable is not absolute. Find it. 41563 IFS_save="$IFS" 41564 IFS=: 41565 for p in $PATH; do 41566 if test -f "$p/$path" && test -x "$p/$path"; then 41567 new_path="$p/$path" 41568 break 41569 fi 41570 done 41571 IFS="$IFS_save" 41572 else 41573 # This is an absolute path, we can use it without further modifications. 41574 new_path="$path" 41575 fi 41576 41577 if test "x$new_path" = x; then 41578 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of STRIP, which resolves as \"$complete\", is not found." >&5 41579 $as_echo "$as_me: The path of STRIP, which resolves as \"$complete\", is not found." >&6;} 41580 has_space=`$ECHO "$complete" | $GREP " "` 41581 if test "x$has_space" != x; then 41582 { $as_echo "$as_me:${as_lineno-$LINENO}: This might be caused by spaces in the path, which is not allowed." >&5 41583 $as_echo "$as_me: This might be caused by spaces in the path, which is not allowed." >&6;} 41584 fi 41585 as_fn_error $? "Cannot locate the the path of STRIP" "$LINENO" 5 41586 fi 41587 fi 41588 41589 # Now join together the path and the arguments once again 41590 if test "x$arguments" != xEOL; then 41591 new_complete="$new_path ${arguments% *}" 41592 else 41593 new_complete="$new_path" 41594 fi 41595 41596 if test "x$complete" != "x$new_complete"; then 41597 STRIP="$new_complete" 41598 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting STRIP to \"$new_complete\"" >&5 41599 $as_echo "$as_me: Rewriting STRIP to \"$new_complete\"" >&6;} 41600 fi 41601 fi 41602 41603 if test "x$TOOLCHAIN_TYPE" = xgcc; then 41604 41605 41606 # Publish this variable in the help. 41607 41608 41609 if [ -z "${NM+x}" ]; then 41610 # The variable is not set by user, try to locate tool using the code snippet 41611 if test -n "$ac_tool_prefix"; then 41612 for ac_prog in nm gcc-nm 41613 do 41614 # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args. 41615 set dummy $ac_tool_prefix$ac_prog; ac_word=$2 41616 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 41617 $as_echo_n "checking for $ac_word... " >&6; } 41618 if ${ac_cv_prog_NM+:} false; then : 41619 $as_echo_n "(cached) " >&6 41620 else 41621 if test -n "$NM"; then 41622 ac_cv_prog_NM="$NM" # Let the user override the test. 41623 else 41624 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 41625 for as_dir in $PATH 41626 do 41627 IFS=$as_save_IFS 41628 test -z "$as_dir" && as_dir=. 41629 for ac_exec_ext in '' $ac_executable_extensions; do 41630 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 41631 ac_cv_prog_NM="$ac_tool_prefix$ac_prog" 41632 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 41633 break 2 41634 fi 41635 done 41636 done 41637 IFS=$as_save_IFS 41638 41639 fi 41640 fi 41641 NM=$ac_cv_prog_NM 41642 if test -n "$NM"; then 41643 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $NM" >&5 41644 $as_echo "$NM" >&6; } 41645 else 41646 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 41647 $as_echo "no" >&6; } 41648 fi 41649 41650 41651 test -n "$NM" && break 41652 done 41653 fi 41654 if test -z "$NM"; then 41655 ac_ct_NM=$NM 41656 for ac_prog in nm gcc-nm 41657 do 41658 # Extract the first word of "$ac_prog", so it can be a program name with args. 41659 set dummy $ac_prog; ac_word=$2 41660 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 41661 $as_echo_n "checking for $ac_word... " >&6; } 41662 if ${ac_cv_prog_ac_ct_NM+:} false; then : 41663 $as_echo_n "(cached) " >&6 41664 else 41665 if test -n "$ac_ct_NM"; then 41666 ac_cv_prog_ac_ct_NM="$ac_ct_NM" # Let the user override the test. 41667 else 41668 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 41669 for as_dir in $PATH 41670 do 41671 IFS=$as_save_IFS 41672 test -z "$as_dir" && as_dir=. 41673 for ac_exec_ext in '' $ac_executable_extensions; do 41674 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 41675 ac_cv_prog_ac_ct_NM="$ac_prog" 41676 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 41677 break 2 41678 fi 41679 done 41680 done 41681 IFS=$as_save_IFS 41682 41683 fi 41684 fi 41685 ac_ct_NM=$ac_cv_prog_ac_ct_NM 41686 if test -n "$ac_ct_NM"; then 41687 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_NM" >&5 41688 $as_echo "$ac_ct_NM" >&6; } 41689 else 41690 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 41691 $as_echo "no" >&6; } 41692 fi 41693 41694 41695 test -n "$ac_ct_NM" && break 41696 done 41697 41698 if test "x$ac_ct_NM" = x; then 41699 NM="" 41700 else 41701 case $cross_compiling:$ac_tool_warned in 41702 yes:) 41703 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5 41704 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;} 41705 ac_tool_warned=yes ;; 41706 esac 41707 NM=$ac_ct_NM 41708 fi 41709 fi 41710 41711 else 41712 # The variable is set, but is it from the command line or the environment? 41713 41714 # Try to remove the string !NM! from our list. 41715 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!NM!/} 41716 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 41717 # If it failed, the variable was not from the command line. Ignore it, 41718 # but warn the user (except for BASH, which is always set by the calling BASH). 41719 if test "xNM" != xBASH; then 41720 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of NM from the environment. Use command line variables instead." >&5 41721 $as_echo "$as_me: WARNING: Ignoring value of NM from the environment. Use command line variables instead." >&2;} 41722 fi 41723 # Try to locate tool using the code snippet 41724 if test -n "$ac_tool_prefix"; then 41725 for ac_prog in nm gcc-nm 41726 do 41727 # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args. 41728 set dummy $ac_tool_prefix$ac_prog; ac_word=$2 41729 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 41730 $as_echo_n "checking for $ac_word... " >&6; } 41731 if ${ac_cv_prog_NM+:} false; then : 41732 $as_echo_n "(cached) " >&6 41733 else 41734 if test -n "$NM"; then 41735 ac_cv_prog_NM="$NM" # Let the user override the test. 41736 else 41737 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 41738 for as_dir in $PATH 41739 do 41740 IFS=$as_save_IFS 41741 test -z "$as_dir" && as_dir=. 41742 for ac_exec_ext in '' $ac_executable_extensions; do 41743 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 41744 ac_cv_prog_NM="$ac_tool_prefix$ac_prog" 41745 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 41746 break 2 41747 fi 41748 done 41749 done 41750 IFS=$as_save_IFS 41751 41752 fi 41753 fi 41754 NM=$ac_cv_prog_NM 41755 if test -n "$NM"; then 41756 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $NM" >&5 41757 $as_echo "$NM" >&6; } 41758 else 41759 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 41760 $as_echo "no" >&6; } 41761 fi 41762 41763 41764 test -n "$NM" && break 41765 done 41766 fi 41767 if test -z "$NM"; then 41768 ac_ct_NM=$NM 41769 for ac_prog in nm gcc-nm 41770 do 41771 # Extract the first word of "$ac_prog", so it can be a program name with args. 41772 set dummy $ac_prog; ac_word=$2 41773 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 41774 $as_echo_n "checking for $ac_word... " >&6; } 41775 if ${ac_cv_prog_ac_ct_NM+:} false; then : 41776 $as_echo_n "(cached) " >&6 41777 else 41778 if test -n "$ac_ct_NM"; then 41779 ac_cv_prog_ac_ct_NM="$ac_ct_NM" # Let the user override the test. 41780 else 41781 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 41782 for as_dir in $PATH 41783 do 41784 IFS=$as_save_IFS 41785 test -z "$as_dir" && as_dir=. 41786 for ac_exec_ext in '' $ac_executable_extensions; do 41787 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 41788 ac_cv_prog_ac_ct_NM="$ac_prog" 41789 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 41790 break 2 41791 fi 41792 done 41793 done 41794 IFS=$as_save_IFS 41795 41796 fi 41797 fi 41798 ac_ct_NM=$ac_cv_prog_ac_ct_NM 41799 if test -n "$ac_ct_NM"; then 41800 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_NM" >&5 41801 $as_echo "$ac_ct_NM" >&6; } 41802 else 41803 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 41804 $as_echo "no" >&6; } 41805 fi 41806 41807 41808 test -n "$ac_ct_NM" && break 41809 done 41810 41811 if test "x$ac_ct_NM" = x; then 41812 NM="" 41813 else 41814 case $cross_compiling:$ac_tool_warned in 41815 yes:) 41816 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5 41817 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;} 41818 ac_tool_warned=yes ;; 41819 esac 41820 NM=$ac_ct_NM 41821 fi 41822 fi 41823 41824 else 41825 # If it succeeded, then it was overridden by the user. We will use it 41826 # for the tool. 41827 41828 # First remove it from the list of overridden variables, so we can test 41829 # for unknown variables in the end. 41830 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 41831 41832 # Check if we try to supply an empty value 41833 if test "x$NM" = x; then 41834 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool NM= (no value)" >&5 41835 $as_echo "$as_me: Setting user supplied tool NM= (no value)" >&6;} 41836 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for NM" >&5 41837 $as_echo_n "checking for NM... " >&6; } 41838 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 41839 $as_echo "disabled" >&6; } 41840 else 41841 # Check if the provided tool contains a complete path. 41842 tool_specified="$NM" 41843 tool_basename="${tool_specified##*/}" 41844 if test "x$tool_basename" = "x$tool_specified"; then 41845 # A command without a complete path is provided, search $PATH. 41846 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool NM=$tool_basename" >&5 41847 $as_echo "$as_me: Will search for user supplied tool NM=$tool_basename" >&6;} 41848 # Extract the first word of "$tool_basename", so it can be a program name with args. 41849 set dummy $tool_basename; ac_word=$2 41850 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 41851 $as_echo_n "checking for $ac_word... " >&6; } 41852 if ${ac_cv_path_NM+:} false; then : 41853 $as_echo_n "(cached) " >&6 41854 else 41855 case $NM in 41856 [\\/]* | ?:[\\/]*) 41857 ac_cv_path_NM="$NM" # Let the user override the test with a path. 41858 ;; 41859 *) 41860 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 41861 for as_dir in $PATH 41862 do 41863 IFS=$as_save_IFS 41864 test -z "$as_dir" && as_dir=. 41865 for ac_exec_ext in '' $ac_executable_extensions; do 41866 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 41867 ac_cv_path_NM="$as_dir/$ac_word$ac_exec_ext" 41868 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 41869 break 2 41870 fi 41871 done 41872 done 41873 IFS=$as_save_IFS 41874 41875 ;; 41876 esac 41877 fi 41878 NM=$ac_cv_path_NM 41879 if test -n "$NM"; then 41880 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $NM" >&5 41881 $as_echo "$NM" >&6; } 41882 else 41883 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 41884 $as_echo "no" >&6; } 41885 fi 41886 41887 41888 if test "x$NM" = x; then 41889 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 41890 fi 41891 else 41892 # Otherwise we believe it is a complete path. Use it as it is. 41893 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool NM=$tool_specified" >&5 41894 $as_echo "$as_me: Will use user supplied tool NM=$tool_specified" >&6;} 41895 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for NM" >&5 41896 $as_echo_n "checking for NM... " >&6; } 41897 if test ! -x "$tool_specified"; then 41898 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 41899 $as_echo "not found" >&6; } 41900 as_fn_error $? "User supplied tool NM=$tool_specified does not exist or is not executable" "$LINENO" 5 41901 fi 41902 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 41903 $as_echo "$tool_specified" >&6; } 41904 fi 41905 fi 41906 fi 41907 41908 fi 41909 41910 41911 else 41912 41913 41914 # Publish this variable in the help. 41915 41916 41917 if [ -z "${NM+x}" ]; then 41918 # The variable is not set by user, try to locate tool using the code snippet 41919 if test -n "$ac_tool_prefix"; then 41920 for ac_prog in nm 41921 do 41922 # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args. 41923 set dummy $ac_tool_prefix$ac_prog; ac_word=$2 41924 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 41925 $as_echo_n "checking for $ac_word... " >&6; } 41926 if ${ac_cv_prog_NM+:} false; then : 41927 $as_echo_n "(cached) " >&6 41928 else 41929 if test -n "$NM"; then 41930 ac_cv_prog_NM="$NM" # Let the user override the test. 41931 else 41932 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 41933 for as_dir in $PATH 41934 do 41935 IFS=$as_save_IFS 41936 test -z "$as_dir" && as_dir=. 41937 for ac_exec_ext in '' $ac_executable_extensions; do 41938 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 41939 ac_cv_prog_NM="$ac_tool_prefix$ac_prog" 41940 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 41941 break 2 41942 fi 41943 done 41944 done 41945 IFS=$as_save_IFS 41946 41947 fi 41948 fi 41949 NM=$ac_cv_prog_NM 41950 if test -n "$NM"; then 41951 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $NM" >&5 41952 $as_echo "$NM" >&6; } 41953 else 41954 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 41955 $as_echo "no" >&6; } 41956 fi 41957 41958 41959 test -n "$NM" && break 41960 done 41961 fi 41962 if test -z "$NM"; then 41963 ac_ct_NM=$NM 41964 for ac_prog in nm 41965 do 41966 # Extract the first word of "$ac_prog", so it can be a program name with args. 41967 set dummy $ac_prog; ac_word=$2 41968 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 41969 $as_echo_n "checking for $ac_word... " >&6; } 41970 if ${ac_cv_prog_ac_ct_NM+:} false; then : 41971 $as_echo_n "(cached) " >&6 41972 else 41973 if test -n "$ac_ct_NM"; then 41974 ac_cv_prog_ac_ct_NM="$ac_ct_NM" # Let the user override the test. 41975 else 41976 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 41977 for as_dir in $PATH 41978 do 41979 IFS=$as_save_IFS 41980 test -z "$as_dir" && as_dir=. 41981 for ac_exec_ext in '' $ac_executable_extensions; do 41982 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 41983 ac_cv_prog_ac_ct_NM="$ac_prog" 41984 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 41985 break 2 41986 fi 41987 done 41988 done 41989 IFS=$as_save_IFS 41990 41991 fi 41992 fi 41993 ac_ct_NM=$ac_cv_prog_ac_ct_NM 41994 if test -n "$ac_ct_NM"; then 41995 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_NM" >&5 41996 $as_echo "$ac_ct_NM" >&6; } 41997 else 41998 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 41999 $as_echo "no" >&6; } 42000 fi 42001 42002 42003 test -n "$ac_ct_NM" && break 42004 done 42005 42006 if test "x$ac_ct_NM" = x; then 42007 NM="" 42008 else 42009 case $cross_compiling:$ac_tool_warned in 42010 yes:) 42011 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5 42012 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;} 42013 ac_tool_warned=yes ;; 42014 esac 42015 NM=$ac_ct_NM 42016 fi 42017 fi 42018 42019 else 42020 # The variable is set, but is it from the command line or the environment? 42021 42022 # Try to remove the string !NM! from our list. 42023 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!NM!/} 42024 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 42025 # If it failed, the variable was not from the command line. Ignore it, 42026 # but warn the user (except for BASH, which is always set by the calling BASH). 42027 if test "xNM" != xBASH; then 42028 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of NM from the environment. Use command line variables instead." >&5 42029 $as_echo "$as_me: WARNING: Ignoring value of NM from the environment. Use command line variables instead." >&2;} 42030 fi 42031 # Try to locate tool using the code snippet 42032 if test -n "$ac_tool_prefix"; then 42033 for ac_prog in nm 42034 do 42035 # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args. 42036 set dummy $ac_tool_prefix$ac_prog; ac_word=$2 42037 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 42038 $as_echo_n "checking for $ac_word... " >&6; } 42039 if ${ac_cv_prog_NM+:} false; then : 42040 $as_echo_n "(cached) " >&6 42041 else 42042 if test -n "$NM"; then 42043 ac_cv_prog_NM="$NM" # Let the user override the test. 42044 else 42045 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 42046 for as_dir in $PATH 42047 do 42048 IFS=$as_save_IFS 42049 test -z "$as_dir" && as_dir=. 42050 for ac_exec_ext in '' $ac_executable_extensions; do 42051 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 42052 ac_cv_prog_NM="$ac_tool_prefix$ac_prog" 42053 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 42054 break 2 42055 fi 42056 done 42057 done 42058 IFS=$as_save_IFS 42059 42060 fi 42061 fi 42062 NM=$ac_cv_prog_NM 42063 if test -n "$NM"; then 42064 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $NM" >&5 42065 $as_echo "$NM" >&6; } 42066 else 42067 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 42068 $as_echo "no" >&6; } 42069 fi 42070 42071 42072 test -n "$NM" && break 42073 done 42074 fi 42075 if test -z "$NM"; then 42076 ac_ct_NM=$NM 42077 for ac_prog in nm 42078 do 42079 # Extract the first word of "$ac_prog", so it can be a program name with args. 42080 set dummy $ac_prog; ac_word=$2 42081 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 42082 $as_echo_n "checking for $ac_word... " >&6; } 42083 if ${ac_cv_prog_ac_ct_NM+:} false; then : 42084 $as_echo_n "(cached) " >&6 42085 else 42086 if test -n "$ac_ct_NM"; then 42087 ac_cv_prog_ac_ct_NM="$ac_ct_NM" # Let the user override the test. 42088 else 42089 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 42090 for as_dir in $PATH 42091 do 42092 IFS=$as_save_IFS 42093 test -z "$as_dir" && as_dir=. 42094 for ac_exec_ext in '' $ac_executable_extensions; do 42095 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 42096 ac_cv_prog_ac_ct_NM="$ac_prog" 42097 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 42098 break 2 42099 fi 42100 done 42101 done 42102 IFS=$as_save_IFS 42103 42104 fi 42105 fi 42106 ac_ct_NM=$ac_cv_prog_ac_ct_NM 42107 if test -n "$ac_ct_NM"; then 42108 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_NM" >&5 42109 $as_echo "$ac_ct_NM" >&6; } 42110 else 42111 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 42112 $as_echo "no" >&6; } 42113 fi 42114 42115 42116 test -n "$ac_ct_NM" && break 42117 done 42118 42119 if test "x$ac_ct_NM" = x; then 42120 NM="" 42121 else 42122 case $cross_compiling:$ac_tool_warned in 42123 yes:) 42124 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5 42125 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;} 42126 ac_tool_warned=yes ;; 42127 esac 42128 NM=$ac_ct_NM 42129 fi 42130 fi 42131 42132 else 42133 # If it succeeded, then it was overridden by the user. We will use it 42134 # for the tool. 42135 42136 # First remove it from the list of overridden variables, so we can test 42137 # for unknown variables in the end. 42138 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 42139 42140 # Check if we try to supply an empty value 42141 if test "x$NM" = x; then 42142 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool NM= (no value)" >&5 42143 $as_echo "$as_me: Setting user supplied tool NM= (no value)" >&6;} 42144 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for NM" >&5 42145 $as_echo_n "checking for NM... " >&6; } 42146 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 42147 $as_echo "disabled" >&6; } 42148 else 42149 # Check if the provided tool contains a complete path. 42150 tool_specified="$NM" 42151 tool_basename="${tool_specified##*/}" 42152 if test "x$tool_basename" = "x$tool_specified"; then 42153 # A command without a complete path is provided, search $PATH. 42154 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool NM=$tool_basename" >&5 42155 $as_echo "$as_me: Will search for user supplied tool NM=$tool_basename" >&6;} 42156 # Extract the first word of "$tool_basename", so it can be a program name with args. 42157 set dummy $tool_basename; ac_word=$2 42158 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 42159 $as_echo_n "checking for $ac_word... " >&6; } 42160 if ${ac_cv_path_NM+:} false; then : 42161 $as_echo_n "(cached) " >&6 42162 else 42163 case $NM in 42164 [\\/]* | ?:[\\/]*) 42165 ac_cv_path_NM="$NM" # Let the user override the test with a path. 42166 ;; 42167 *) 42168 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 42169 for as_dir in $PATH 42170 do 42171 IFS=$as_save_IFS 42172 test -z "$as_dir" && as_dir=. 42173 for ac_exec_ext in '' $ac_executable_extensions; do 42174 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 42175 ac_cv_path_NM="$as_dir/$ac_word$ac_exec_ext" 42176 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 42177 break 2 42178 fi 42179 done 42180 done 42181 IFS=$as_save_IFS 42182 42183 ;; 42184 esac 42185 fi 42186 NM=$ac_cv_path_NM 42187 if test -n "$NM"; then 42188 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $NM" >&5 42189 $as_echo "$NM" >&6; } 42190 else 42191 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 42192 $as_echo "no" >&6; } 42193 fi 42194 42195 42196 if test "x$NM" = x; then 42197 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 42198 fi 42199 else 42200 # Otherwise we believe it is a complete path. Use it as it is. 42201 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool NM=$tool_specified" >&5 42202 $as_echo "$as_me: Will use user supplied tool NM=$tool_specified" >&6;} 42203 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for NM" >&5 42204 $as_echo_n "checking for NM... " >&6; } 42205 if test ! -x "$tool_specified"; then 42206 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 42207 $as_echo "not found" >&6; } 42208 as_fn_error $? "User supplied tool NM=$tool_specified does not exist or is not executable" "$LINENO" 5 42209 fi 42210 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 42211 $as_echo "$tool_specified" >&6; } 42212 fi 42213 fi 42214 fi 42215 42216 fi 42217 42218 42219 fi 42220 42221 # Only process if variable expands to non-empty 42222 42223 if test "x$NM" != x; then 42224 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 42225 42226 # First separate the path from the arguments. This will split at the first 42227 # space. 42228 complete="$NM" 42229 path="${complete%% *}" 42230 tmp="$complete EOL" 42231 arguments="${tmp#* }" 42232 42233 # Input might be given as Windows format, start by converting to 42234 # unix format. 42235 new_path=`$CYGPATH -u "$path"` 42236 42237 # Now try to locate executable using which 42238 new_path=`$WHICH "$new_path" 2> /dev/null` 42239 # bat and cmd files are not always considered executable in cygwin causing which 42240 # to not find them 42241 if test "x$new_path" = x \ 42242 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 42243 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 42244 new_path=`$CYGPATH -u "$path"` 42245 fi 42246 if test "x$new_path" = x; then 42247 # Oops. Which didn't find the executable. 42248 # The splitting of arguments from the executable at a space might have been incorrect, 42249 # since paths with space are more likely in Windows. Give it another try with the whole 42250 # argument. 42251 path="$complete" 42252 arguments="EOL" 42253 new_path=`$CYGPATH -u "$path"` 42254 new_path=`$WHICH "$new_path" 2> /dev/null` 42255 # bat and cmd files are not always considered executable in cygwin causing which 42256 # to not find them 42257 if test "x$new_path" = x \ 42258 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 42259 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 42260 new_path=`$CYGPATH -u "$path"` 42261 fi 42262 if test "x$new_path" = x; then 42263 # It's still not found. Now this is an unrecoverable error. 42264 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of NM, which resolves as \"$complete\", is not found." >&5 42265 $as_echo "$as_me: The path of NM, which resolves as \"$complete\", is not found." >&6;} 42266 has_space=`$ECHO "$complete" | $GREP " "` 42267 if test "x$has_space" != x; then 42268 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 42269 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 42270 fi 42271 as_fn_error $? "Cannot locate the the path of NM" "$LINENO" 5 42272 fi 42273 fi 42274 42275 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 42276 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 42277 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 42278 # "foo.exe" is OK but "foo" is an error. 42279 # 42280 # This test is therefore slightly more accurate than "test -f" to check for file presence. 42281 # It is also a way to make sure we got the proper file name for the real test later on. 42282 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 42283 if test "x$test_shortpath" = x; then 42284 # Short path failed, file does not exist as specified. 42285 # Try adding .exe or .cmd 42286 if test -f "${new_path}.exe"; then 42287 input_to_shortpath="${new_path}.exe" 42288 elif test -f "${new_path}.cmd"; then 42289 input_to_shortpath="${new_path}.cmd" 42290 else 42291 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of NM, which resolves as \"$new_path\", is invalid." >&5 42292 $as_echo "$as_me: The path of NM, which resolves as \"$new_path\", is invalid." >&6;} 42293 { $as_echo "$as_me:${as_lineno-$LINENO}: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&5 42294 $as_echo "$as_me: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&6;} 42295 as_fn_error $? "Cannot locate the the path of NM" "$LINENO" 5 42296 fi 42297 else 42298 input_to_shortpath="$new_path" 42299 fi 42300 42301 # Call helper function which possibly converts this using DOS-style short mode. 42302 # If so, the updated path is stored in $new_path. 42303 new_path="$input_to_shortpath" 42304 42305 input_path="$input_to_shortpath" 42306 # Check if we need to convert this using DOS-style short mode. If the path 42307 # contains just simple characters, use it. Otherwise (spaces, weird characters), 42308 # take no chances and rewrite it. 42309 # Note: m4 eats our [], so we need to use [ and ] instead. 42310 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 42311 if test "x$has_forbidden_chars" != x; then 42312 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 42313 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 42314 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 42315 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 42316 # Going to short mode and back again did indeed matter. Since short mode is 42317 # case insensitive, let's make it lowercase to improve readability. 42318 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 42319 # Now convert it back to Unix-style (cygpath) 42320 input_path=`$CYGPATH -u "$shortmode_path"` 42321 new_path="$input_path" 42322 fi 42323 fi 42324 42325 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 42326 if test "x$test_cygdrive_prefix" = x; then 42327 # As a simple fix, exclude /usr/bin since it's not a real path. 42328 if test "x`$ECHO $input_to_shortpath | $GREP ^/usr/bin/`" = x; then 42329 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 42330 # a path prefixed by /cygdrive for fixpath to work. 42331 new_path="$CYGWIN_ROOT_PATH$input_path" 42332 fi 42333 fi 42334 42335 # remove trailing .exe if any 42336 new_path="${new_path/%.exe/}" 42337 42338 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 42339 42340 # First separate the path from the arguments. This will split at the first 42341 # space. 42342 complete="$NM" 42343 path="${complete%% *}" 42344 tmp="$complete EOL" 42345 arguments="${tmp#* }" 42346 42347 # Input might be given as Windows format, start by converting to 42348 # unix format. 42349 new_path="$path" 42350 42351 windows_path="$new_path" 42352 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 42353 unix_path=`$CYGPATH -u "$windows_path"` 42354 new_path="$unix_path" 42355 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 42356 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 42357 new_path="$unix_path" 42358 fi 42359 42360 42361 # Now try to locate executable using which 42362 new_path=`$WHICH "$new_path" 2> /dev/null` 42363 42364 if test "x$new_path" = x; then 42365 # Oops. Which didn't find the executable. 42366 # The splitting of arguments from the executable at a space might have been incorrect, 42367 # since paths with space are more likely in Windows. Give it another try with the whole 42368 # argument. 42369 path="$complete" 42370 arguments="EOL" 42371 new_path="$path" 42372 42373 windows_path="$new_path" 42374 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 42375 unix_path=`$CYGPATH -u "$windows_path"` 42376 new_path="$unix_path" 42377 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 42378 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 42379 new_path="$unix_path" 42380 fi 42381 42382 42383 new_path=`$WHICH "$new_path" 2> /dev/null` 42384 # bat and cmd files are not always considered executable in MSYS causing which 42385 # to not find them 42386 if test "x$new_path" = x \ 42387 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 42388 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 42389 new_path="$path" 42390 42391 windows_path="$new_path" 42392 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 42393 unix_path=`$CYGPATH -u "$windows_path"` 42394 new_path="$unix_path" 42395 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 42396 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 42397 new_path="$unix_path" 42398 fi 42399 42400 fi 42401 42402 if test "x$new_path" = x; then 42403 # It's still not found. Now this is an unrecoverable error. 42404 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of NM, which resolves as \"$complete\", is not found." >&5 42405 $as_echo "$as_me: The path of NM, which resolves as \"$complete\", is not found." >&6;} 42406 has_space=`$ECHO "$complete" | $GREP " "` 42407 if test "x$has_space" != x; then 42408 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 42409 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 42410 fi 42411 as_fn_error $? "Cannot locate the the path of NM" "$LINENO" 5 42412 fi 42413 fi 42414 42415 # Now new_path has a complete unix path to the binary 42416 if test "x`$ECHO $new_path | $GREP ^/bin/`" != x; then 42417 # Keep paths in /bin as-is, but remove trailing .exe if any 42418 new_path="${new_path/%.exe/}" 42419 # Do not save /bin paths to all_fixpath_prefixes! 42420 else 42421 # Not in mixed or Windows style, start by that. 42422 new_path=`cmd //c echo $new_path` 42423 42424 input_path="$new_path" 42425 # Check if we need to convert this using DOS-style short mode. If the path 42426 # contains just simple characters, use it. Otherwise (spaces, weird characters), 42427 # take no chances and rewrite it. 42428 # Note: m4 eats our [], so we need to use [ and ] instead. 42429 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 42430 if test "x$has_forbidden_chars" != x; then 42431 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 42432 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 42433 fi 42434 42435 # Output is in $new_path 42436 42437 windows_path="$new_path" 42438 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 42439 unix_path=`$CYGPATH -u "$windows_path"` 42440 new_path="$unix_path" 42441 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 42442 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 42443 new_path="$unix_path" 42444 fi 42445 42446 # remove trailing .exe if any 42447 new_path="${new_path/%.exe/}" 42448 42449 # Save the first 10 bytes of this path to the storage, so fixpath can work. 42450 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 42451 fi 42452 42453 else 42454 # We're on a unix platform. Hooray! :) 42455 # First separate the path from the arguments. This will split at the first 42456 # space. 42457 complete="$NM" 42458 path="${complete%% *}" 42459 tmp="$complete EOL" 42460 arguments="${tmp#* }" 42461 42462 # Cannot rely on the command "which" here since it doesn't always work. 42463 is_absolute_path=`$ECHO "$path" | $GREP ^/` 42464 if test -z "$is_absolute_path"; then 42465 # Path to executable is not absolute. Find it. 42466 IFS_save="$IFS" 42467 IFS=: 42468 for p in $PATH; do 42469 if test -f "$p/$path" && test -x "$p/$path"; then 42470 new_path="$p/$path" 42471 break 42472 fi 42473 done 42474 IFS="$IFS_save" 42475 else 42476 # This is an absolute path, we can use it without further modifications. 42477 new_path="$path" 42478 fi 42479 42480 if test "x$new_path" = x; then 42481 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of NM, which resolves as \"$complete\", is not found." >&5 42482 $as_echo "$as_me: The path of NM, which resolves as \"$complete\", is not found." >&6;} 42483 has_space=`$ECHO "$complete" | $GREP " "` 42484 if test "x$has_space" != x; then 42485 { $as_echo "$as_me:${as_lineno-$LINENO}: This might be caused by spaces in the path, which is not allowed." >&5 42486 $as_echo "$as_me: This might be caused by spaces in the path, which is not allowed." >&6;} 42487 fi 42488 as_fn_error $? "Cannot locate the the path of NM" "$LINENO" 5 42489 fi 42490 fi 42491 42492 # Now join together the path and the arguments once again 42493 if test "x$arguments" != xEOL; then 42494 new_complete="$new_path ${arguments% *}" 42495 else 42496 new_complete="$new_path" 42497 fi 42498 42499 if test "x$complete" != "x$new_complete"; then 42500 NM="$new_complete" 42501 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting NM to \"$new_complete\"" >&5 42502 $as_echo "$as_me: Rewriting NM to \"$new_complete\"" >&6;} 42503 fi 42504 fi 42505 42506 GNM="$NM" 42507 42508 fi 42509 42510 # objcopy is used for moving debug symbols to separate files when 42511 # full debug symbols are enabled. 42512 if test "x$OPENJDK_TARGET_OS" = xsolaris || test "x$OPENJDK_TARGET_OS" = xlinux; then 42513 42514 42515 # Publish this variable in the help. 42516 42517 42518 if [ -z "${OBJCOPY+x}" ]; then 42519 # The variable is not set by user, try to locate tool using the code snippet 42520 if test -n "$ac_tool_prefix"; then 42521 for ac_prog in gobjcopy objcopy 42522 do 42523 # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args. 42524 set dummy $ac_tool_prefix$ac_prog; ac_word=$2 42525 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 42526 $as_echo_n "checking for $ac_word... " >&6; } 42527 if ${ac_cv_prog_OBJCOPY+:} false; then : 42528 $as_echo_n "(cached) " >&6 42529 else 42530 if test -n "$OBJCOPY"; then 42531 ac_cv_prog_OBJCOPY="$OBJCOPY" # Let the user override the test. 42532 else 42533 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 42534 for as_dir in $PATH 42535 do 42536 IFS=$as_save_IFS 42537 test -z "$as_dir" && as_dir=. 42538 for ac_exec_ext in '' $ac_executable_extensions; do 42539 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 42540 ac_cv_prog_OBJCOPY="$ac_tool_prefix$ac_prog" 42541 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 42542 break 2 42543 fi 42544 done 42545 done 42546 IFS=$as_save_IFS 42547 42548 fi 42549 fi 42550 OBJCOPY=$ac_cv_prog_OBJCOPY 42551 if test -n "$OBJCOPY"; then 42552 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $OBJCOPY" >&5 42553 $as_echo "$OBJCOPY" >&6; } 42554 else 42555 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 42556 $as_echo "no" >&6; } 42557 fi 42558 42559 42560 test -n "$OBJCOPY" && break 42561 done 42562 fi 42563 if test -z "$OBJCOPY"; then 42564 ac_ct_OBJCOPY=$OBJCOPY 42565 for ac_prog in gobjcopy objcopy 42566 do 42567 # Extract the first word of "$ac_prog", so it can be a program name with args. 42568 set dummy $ac_prog; ac_word=$2 42569 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 42570 $as_echo_n "checking for $ac_word... " >&6; } 42571 if ${ac_cv_prog_ac_ct_OBJCOPY+:} false; then : 42572 $as_echo_n "(cached) " >&6 42573 else 42574 if test -n "$ac_ct_OBJCOPY"; then 42575 ac_cv_prog_ac_ct_OBJCOPY="$ac_ct_OBJCOPY" # Let the user override the test. 42576 else 42577 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 42578 for as_dir in $PATH 42579 do 42580 IFS=$as_save_IFS 42581 test -z "$as_dir" && as_dir=. 42582 for ac_exec_ext in '' $ac_executable_extensions; do 42583 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 42584 ac_cv_prog_ac_ct_OBJCOPY="$ac_prog" 42585 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 42586 break 2 42587 fi 42588 done 42589 done 42590 IFS=$as_save_IFS 42591 42592 fi 42593 fi 42594 ac_ct_OBJCOPY=$ac_cv_prog_ac_ct_OBJCOPY 42595 if test -n "$ac_ct_OBJCOPY"; then 42596 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_OBJCOPY" >&5 42597 $as_echo "$ac_ct_OBJCOPY" >&6; } 42598 else 42599 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 42600 $as_echo "no" >&6; } 42601 fi 42602 42603 42604 test -n "$ac_ct_OBJCOPY" && break 42605 done 42606 42607 if test "x$ac_ct_OBJCOPY" = x; then 42608 OBJCOPY="" 42609 else 42610 case $cross_compiling:$ac_tool_warned in 42611 yes:) 42612 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5 42613 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;} 42614 ac_tool_warned=yes ;; 42615 esac 42616 OBJCOPY=$ac_ct_OBJCOPY 42617 fi 42618 fi 42619 42620 else 42621 # The variable is set, but is it from the command line or the environment? 42622 42623 # Try to remove the string !OBJCOPY! from our list. 42624 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!OBJCOPY!/} 42625 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 42626 # If it failed, the variable was not from the command line. Ignore it, 42627 # but warn the user (except for BASH, which is always set by the calling BASH). 42628 if test "xOBJCOPY" != xBASH; then 42629 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of OBJCOPY from the environment. Use command line variables instead." >&5 42630 $as_echo "$as_me: WARNING: Ignoring value of OBJCOPY from the environment. Use command line variables instead." >&2;} 42631 fi 42632 # Try to locate tool using the code snippet 42633 if test -n "$ac_tool_prefix"; then 42634 for ac_prog in gobjcopy objcopy 42635 do 42636 # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args. 42637 set dummy $ac_tool_prefix$ac_prog; ac_word=$2 42638 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 42639 $as_echo_n "checking for $ac_word... " >&6; } 42640 if ${ac_cv_prog_OBJCOPY+:} false; then : 42641 $as_echo_n "(cached) " >&6 42642 else 42643 if test -n "$OBJCOPY"; then 42644 ac_cv_prog_OBJCOPY="$OBJCOPY" # Let the user override the test. 42645 else 42646 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 42647 for as_dir in $PATH 42648 do 42649 IFS=$as_save_IFS 42650 test -z "$as_dir" && as_dir=. 42651 for ac_exec_ext in '' $ac_executable_extensions; do 42652 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 42653 ac_cv_prog_OBJCOPY="$ac_tool_prefix$ac_prog" 42654 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 42655 break 2 42656 fi 42657 done 42658 done 42659 IFS=$as_save_IFS 42660 42661 fi 42662 fi 42663 OBJCOPY=$ac_cv_prog_OBJCOPY 42664 if test -n "$OBJCOPY"; then 42665 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $OBJCOPY" >&5 42666 $as_echo "$OBJCOPY" >&6; } 42667 else 42668 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 42669 $as_echo "no" >&6; } 42670 fi 42671 42672 42673 test -n "$OBJCOPY" && break 42674 done 42675 fi 42676 if test -z "$OBJCOPY"; then 42677 ac_ct_OBJCOPY=$OBJCOPY 42678 for ac_prog in gobjcopy objcopy 42679 do 42680 # Extract the first word of "$ac_prog", so it can be a program name with args. 42681 set dummy $ac_prog; ac_word=$2 42682 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 42683 $as_echo_n "checking for $ac_word... " >&6; } 42684 if ${ac_cv_prog_ac_ct_OBJCOPY+:} false; then : 42685 $as_echo_n "(cached) " >&6 42686 else 42687 if test -n "$ac_ct_OBJCOPY"; then 42688 ac_cv_prog_ac_ct_OBJCOPY="$ac_ct_OBJCOPY" # Let the user override the test. 42689 else 42690 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 42691 for as_dir in $PATH 42692 do 42693 IFS=$as_save_IFS 42694 test -z "$as_dir" && as_dir=. 42695 for ac_exec_ext in '' $ac_executable_extensions; do 42696 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 42697 ac_cv_prog_ac_ct_OBJCOPY="$ac_prog" 42698 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 42699 break 2 42700 fi 42701 done 42702 done 42703 IFS=$as_save_IFS 42704 42705 fi 42706 fi 42707 ac_ct_OBJCOPY=$ac_cv_prog_ac_ct_OBJCOPY 42708 if test -n "$ac_ct_OBJCOPY"; then 42709 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_OBJCOPY" >&5 42710 $as_echo "$ac_ct_OBJCOPY" >&6; } 42711 else 42712 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 42713 $as_echo "no" >&6; } 42714 fi 42715 42716 42717 test -n "$ac_ct_OBJCOPY" && break 42718 done 42719 42720 if test "x$ac_ct_OBJCOPY" = x; then 42721 OBJCOPY="" 42722 else 42723 case $cross_compiling:$ac_tool_warned in 42724 yes:) 42725 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5 42726 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;} 42727 ac_tool_warned=yes ;; 42728 esac 42729 OBJCOPY=$ac_ct_OBJCOPY 42730 fi 42731 fi 42732 42733 else 42734 # If it succeeded, then it was overridden by the user. We will use it 42735 # for the tool. 42736 42737 # First remove it from the list of overridden variables, so we can test 42738 # for unknown variables in the end. 42739 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 42740 42741 # Check if we try to supply an empty value 42742 if test "x$OBJCOPY" = x; then 42743 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool OBJCOPY= (no value)" >&5 42744 $as_echo "$as_me: Setting user supplied tool OBJCOPY= (no value)" >&6;} 42745 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for OBJCOPY" >&5 42746 $as_echo_n "checking for OBJCOPY... " >&6; } 42747 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 42748 $as_echo "disabled" >&6; } 42749 else 42750 # Check if the provided tool contains a complete path. 42751 tool_specified="$OBJCOPY" 42752 tool_basename="${tool_specified##*/}" 42753 if test "x$tool_basename" = "x$tool_specified"; then 42754 # A command without a complete path is provided, search $PATH. 42755 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool OBJCOPY=$tool_basename" >&5 42756 $as_echo "$as_me: Will search for user supplied tool OBJCOPY=$tool_basename" >&6;} 42757 # Extract the first word of "$tool_basename", so it can be a program name with args. 42758 set dummy $tool_basename; ac_word=$2 42759 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 42760 $as_echo_n "checking for $ac_word... " >&6; } 42761 if ${ac_cv_path_OBJCOPY+:} false; then : 42762 $as_echo_n "(cached) " >&6 42763 else 42764 case $OBJCOPY in 42765 [\\/]* | ?:[\\/]*) 42766 ac_cv_path_OBJCOPY="$OBJCOPY" # Let the user override the test with a path. 42767 ;; 42768 *) 42769 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 42770 for as_dir in $PATH 42771 do 42772 IFS=$as_save_IFS 42773 test -z "$as_dir" && as_dir=. 42774 for ac_exec_ext in '' $ac_executable_extensions; do 42775 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 42776 ac_cv_path_OBJCOPY="$as_dir/$ac_word$ac_exec_ext" 42777 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 42778 break 2 42779 fi 42780 done 42781 done 42782 IFS=$as_save_IFS 42783 42784 ;; 42785 esac 42786 fi 42787 OBJCOPY=$ac_cv_path_OBJCOPY 42788 if test -n "$OBJCOPY"; then 42789 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $OBJCOPY" >&5 42790 $as_echo "$OBJCOPY" >&6; } 42791 else 42792 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 42793 $as_echo "no" >&6; } 42794 fi 42795 42796 42797 if test "x$OBJCOPY" = x; then 42798 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 42799 fi 42800 else 42801 # Otherwise we believe it is a complete path. Use it as it is. 42802 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool OBJCOPY=$tool_specified" >&5 42803 $as_echo "$as_me: Will use user supplied tool OBJCOPY=$tool_specified" >&6;} 42804 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for OBJCOPY" >&5 42805 $as_echo_n "checking for OBJCOPY... " >&6; } 42806 if test ! -x "$tool_specified"; then 42807 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 42808 $as_echo "not found" >&6; } 42809 as_fn_error $? "User supplied tool OBJCOPY=$tool_specified does not exist or is not executable" "$LINENO" 5 42810 fi 42811 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 42812 $as_echo "$tool_specified" >&6; } 42813 fi 42814 fi 42815 fi 42816 42817 fi 42818 42819 42820 # Only call fixup if objcopy was found. 42821 if test -n "$OBJCOPY"; then 42822 42823 # Only process if variable expands to non-empty 42824 42825 if test "x$OBJCOPY" != x; then 42826 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 42827 42828 # First separate the path from the arguments. This will split at the first 42829 # space. 42830 complete="$OBJCOPY" 42831 path="${complete%% *}" 42832 tmp="$complete EOL" 42833 arguments="${tmp#* }" 42834 42835 # Input might be given as Windows format, start by converting to 42836 # unix format. 42837 new_path=`$CYGPATH -u "$path"` 42838 42839 # Now try to locate executable using which 42840 new_path=`$WHICH "$new_path" 2> /dev/null` 42841 # bat and cmd files are not always considered executable in cygwin causing which 42842 # to not find them 42843 if test "x$new_path" = x \ 42844 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 42845 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 42846 new_path=`$CYGPATH -u "$path"` 42847 fi 42848 if test "x$new_path" = x; then 42849 # Oops. Which didn't find the executable. 42850 # The splitting of arguments from the executable at a space might have been incorrect, 42851 # since paths with space are more likely in Windows. Give it another try with the whole 42852 # argument. 42853 path="$complete" 42854 arguments="EOL" 42855 new_path=`$CYGPATH -u "$path"` 42856 new_path=`$WHICH "$new_path" 2> /dev/null` 42857 # bat and cmd files are not always considered executable in cygwin causing which 42858 # to not find them 42859 if test "x$new_path" = x \ 42860 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 42861 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 42862 new_path=`$CYGPATH -u "$path"` 42863 fi 42864 if test "x$new_path" = x; then 42865 # It's still not found. Now this is an unrecoverable error. 42866 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of OBJCOPY, which resolves as \"$complete\", is not found." >&5 42867 $as_echo "$as_me: The path of OBJCOPY, which resolves as \"$complete\", is not found." >&6;} 42868 has_space=`$ECHO "$complete" | $GREP " "` 42869 if test "x$has_space" != x; then 42870 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 42871 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 42872 fi 42873 as_fn_error $? "Cannot locate the the path of OBJCOPY" "$LINENO" 5 42874 fi 42875 fi 42876 42877 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 42878 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 42879 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 42880 # "foo.exe" is OK but "foo" is an error. 42881 # 42882 # This test is therefore slightly more accurate than "test -f" to check for file presence. 42883 # It is also a way to make sure we got the proper file name for the real test later on. 42884 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 42885 if test "x$test_shortpath" = x; then 42886 # Short path failed, file does not exist as specified. 42887 # Try adding .exe or .cmd 42888 if test -f "${new_path}.exe"; then 42889 input_to_shortpath="${new_path}.exe" 42890 elif test -f "${new_path}.cmd"; then 42891 input_to_shortpath="${new_path}.cmd" 42892 else 42893 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of OBJCOPY, which resolves as \"$new_path\", is invalid." >&5 42894 $as_echo "$as_me: The path of OBJCOPY, which resolves as \"$new_path\", is invalid." >&6;} 42895 { $as_echo "$as_me:${as_lineno-$LINENO}: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&5 42896 $as_echo "$as_me: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&6;} 42897 as_fn_error $? "Cannot locate the the path of OBJCOPY" "$LINENO" 5 42898 fi 42899 else 42900 input_to_shortpath="$new_path" 42901 fi 42902 42903 # Call helper function which possibly converts this using DOS-style short mode. 42904 # If so, the updated path is stored in $new_path. 42905 new_path="$input_to_shortpath" 42906 42907 input_path="$input_to_shortpath" 42908 # Check if we need to convert this using DOS-style short mode. If the path 42909 # contains just simple characters, use it. Otherwise (spaces, weird characters), 42910 # take no chances and rewrite it. 42911 # Note: m4 eats our [], so we need to use [ and ] instead. 42912 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 42913 if test "x$has_forbidden_chars" != x; then 42914 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 42915 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 42916 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 42917 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 42918 # Going to short mode and back again did indeed matter. Since short mode is 42919 # case insensitive, let's make it lowercase to improve readability. 42920 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 42921 # Now convert it back to Unix-style (cygpath) 42922 input_path=`$CYGPATH -u "$shortmode_path"` 42923 new_path="$input_path" 42924 fi 42925 fi 42926 42927 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 42928 if test "x$test_cygdrive_prefix" = x; then 42929 # As a simple fix, exclude /usr/bin since it's not a real path. 42930 if test "x`$ECHO $input_to_shortpath | $GREP ^/usr/bin/`" = x; then 42931 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 42932 # a path prefixed by /cygdrive for fixpath to work. 42933 new_path="$CYGWIN_ROOT_PATH$input_path" 42934 fi 42935 fi 42936 42937 # remove trailing .exe if any 42938 new_path="${new_path/%.exe/}" 42939 42940 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 42941 42942 # First separate the path from the arguments. This will split at the first 42943 # space. 42944 complete="$OBJCOPY" 42945 path="${complete%% *}" 42946 tmp="$complete EOL" 42947 arguments="${tmp#* }" 42948 42949 # Input might be given as Windows format, start by converting to 42950 # unix format. 42951 new_path="$path" 42952 42953 windows_path="$new_path" 42954 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 42955 unix_path=`$CYGPATH -u "$windows_path"` 42956 new_path="$unix_path" 42957 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 42958 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 42959 new_path="$unix_path" 42960 fi 42961 42962 42963 # Now try to locate executable using which 42964 new_path=`$WHICH "$new_path" 2> /dev/null` 42965 42966 if test "x$new_path" = x; then 42967 # Oops. Which didn't find the executable. 42968 # The splitting of arguments from the executable at a space might have been incorrect, 42969 # since paths with space are more likely in Windows. Give it another try with the whole 42970 # argument. 42971 path="$complete" 42972 arguments="EOL" 42973 new_path="$path" 42974 42975 windows_path="$new_path" 42976 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 42977 unix_path=`$CYGPATH -u "$windows_path"` 42978 new_path="$unix_path" 42979 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 42980 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 42981 new_path="$unix_path" 42982 fi 42983 42984 42985 new_path=`$WHICH "$new_path" 2> /dev/null` 42986 # bat and cmd files are not always considered executable in MSYS causing which 42987 # to not find them 42988 if test "x$new_path" = x \ 42989 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 42990 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 42991 new_path="$path" 42992 42993 windows_path="$new_path" 42994 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 42995 unix_path=`$CYGPATH -u "$windows_path"` 42996 new_path="$unix_path" 42997 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 42998 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 42999 new_path="$unix_path" 43000 fi 43001 43002 fi 43003 43004 if test "x$new_path" = x; then 43005 # It's still not found. Now this is an unrecoverable error. 43006 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of OBJCOPY, which resolves as \"$complete\", is not found." >&5 43007 $as_echo "$as_me: The path of OBJCOPY, which resolves as \"$complete\", is not found." >&6;} 43008 has_space=`$ECHO "$complete" | $GREP " "` 43009 if test "x$has_space" != x; then 43010 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 43011 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 43012 fi 43013 as_fn_error $? "Cannot locate the the path of OBJCOPY" "$LINENO" 5 43014 fi 43015 fi 43016 43017 # Now new_path has a complete unix path to the binary 43018 if test "x`$ECHO $new_path | $GREP ^/bin/`" != x; then 43019 # Keep paths in /bin as-is, but remove trailing .exe if any 43020 new_path="${new_path/%.exe/}" 43021 # Do not save /bin paths to all_fixpath_prefixes! 43022 else 43023 # Not in mixed or Windows style, start by that. 43024 new_path=`cmd //c echo $new_path` 43025 43026 input_path="$new_path" 43027 # Check if we need to convert this using DOS-style short mode. If the path 43028 # contains just simple characters, use it. Otherwise (spaces, weird characters), 43029 # take no chances and rewrite it. 43030 # Note: m4 eats our [], so we need to use [ and ] instead. 43031 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 43032 if test "x$has_forbidden_chars" != x; then 43033 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 43034 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 43035 fi 43036 43037 # Output is in $new_path 43038 43039 windows_path="$new_path" 43040 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 43041 unix_path=`$CYGPATH -u "$windows_path"` 43042 new_path="$unix_path" 43043 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 43044 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 43045 new_path="$unix_path" 43046 fi 43047 43048 # remove trailing .exe if any 43049 new_path="${new_path/%.exe/}" 43050 43051 # Save the first 10 bytes of this path to the storage, so fixpath can work. 43052 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 43053 fi 43054 43055 else 43056 # We're on a unix platform. Hooray! :) 43057 # First separate the path from the arguments. This will split at the first 43058 # space. 43059 complete="$OBJCOPY" 43060 path="${complete%% *}" 43061 tmp="$complete EOL" 43062 arguments="${tmp#* }" 43063 43064 # Cannot rely on the command "which" here since it doesn't always work. 43065 is_absolute_path=`$ECHO "$path" | $GREP ^/` 43066 if test -z "$is_absolute_path"; then 43067 # Path to executable is not absolute. Find it. 43068 IFS_save="$IFS" 43069 IFS=: 43070 for p in $PATH; do 43071 if test -f "$p/$path" && test -x "$p/$path"; then 43072 new_path="$p/$path" 43073 break 43074 fi 43075 done 43076 IFS="$IFS_save" 43077 else 43078 # This is an absolute path, we can use it without further modifications. 43079 new_path="$path" 43080 fi 43081 43082 if test "x$new_path" = x; then 43083 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of OBJCOPY, which resolves as \"$complete\", is not found." >&5 43084 $as_echo "$as_me: The path of OBJCOPY, which resolves as \"$complete\", is not found." >&6;} 43085 has_space=`$ECHO "$complete" | $GREP " "` 43086 if test "x$has_space" != x; then 43087 { $as_echo "$as_me:${as_lineno-$LINENO}: This might be caused by spaces in the path, which is not allowed." >&5 43088 $as_echo "$as_me: This might be caused by spaces in the path, which is not allowed." >&6;} 43089 fi 43090 as_fn_error $? "Cannot locate the the path of OBJCOPY" "$LINENO" 5 43091 fi 43092 fi 43093 43094 # Now join together the path and the arguments once again 43095 if test "x$arguments" != xEOL; then 43096 new_complete="$new_path ${arguments% *}" 43097 else 43098 new_complete="$new_path" 43099 fi 43100 43101 if test "x$complete" != "x$new_complete"; then 43102 OBJCOPY="$new_complete" 43103 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting OBJCOPY to \"$new_complete\"" >&5 43104 $as_echo "$as_me: Rewriting OBJCOPY to \"$new_complete\"" >&6;} 43105 fi 43106 fi 43107 43108 if test "x$OPENJDK_BUILD_OS" = xsolaris; then 43109 # objcopy prior to 2.21.1 on solaris is broken and is not usable. 43110 # Rewrite objcopy version output to VALID_VERSION or BAD_VERSION. 43111 # - version number is last blank separate word on first line 43112 # - version number formats that have been seen: 43113 # - <major>.<minor> 43114 # - <major>.<minor>.<micro> 43115 OBJCOPY_VERSION=`$OBJCOPY --version | $HEAD -n 1` 43116 # The outer [ ] is to prevent m4 from eating the [] in the sed expression. 43117 OBJCOPY_VERSION_CHECK=`$ECHO $OBJCOPY_VERSION | $SED -n \ 43118 -e 's/.* //' \ 43119 -e '/^[01]\./b bad' \ 43120 -e '/^2\./{' \ 43121 -e ' s/^2\.//' \ 43122 -e ' /^[0-9]$/b bad' \ 43123 -e ' /^[0-9]\./b bad' \ 43124 -e ' /^1[0-9]$/b bad' \ 43125 -e ' /^1[0-9]\./b bad' \ 43126 -e ' /^20\./b bad' \ 43127 -e ' /^21\.0$/b bad' \ 43128 -e ' /^21\.0\./b bad' \ 43129 -e '}' \ 43130 -e ':good' \ 43131 -e 's/.*/VALID_VERSION/p' \ 43132 -e 'q' \ 43133 -e ':bad' \ 43134 -e 's/.*/BAD_VERSION/p' \ 43135 -e 'q'` 43136 if test "x$OBJCOPY_VERSION_CHECK" = xBAD_VERSION; then 43137 OBJCOPY= 43138 { $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 43139 $as_echo "$as_me: WARNING: Ignoring found objcopy since it is broken (prior to 2.21.1). No debug symbols will be generated." >&2;} 43140 { $as_echo "$as_me:${as_lineno-$LINENO}: objcopy reports version $OBJCOPY_VERSION" >&5 43141 $as_echo "$as_me: objcopy reports version $OBJCOPY_VERSION" >&6;} 43142 { $as_echo "$as_me:${as_lineno-$LINENO}: Note: patch 149063-01 or newer contains the correct Solaris 10 SPARC version" >&5 43143 $as_echo "$as_me: Note: patch 149063-01 or newer contains the correct Solaris 10 SPARC version" >&6;} 43144 { $as_echo "$as_me:${as_lineno-$LINENO}: Note: patch 149064-01 or newer contains the correct Solaris 10 X86 version" >&5 43145 $as_echo "$as_me: Note: patch 149064-01 or newer contains the correct Solaris 10 X86 version" >&6;} 43146 { $as_echo "$as_me:${as_lineno-$LINENO}: Note: Solaris 11 Update 1 contains the correct version" >&5 43147 $as_echo "$as_me: Note: Solaris 11 Update 1 contains the correct version" >&6;} 43148 fi 43149 fi 43150 fi 43151 fi 43152 43153 43154 43155 # Publish this variable in the help. 43156 43157 43158 if [ -z "${OBJDUMP+x}" ]; then 43159 # The variable is not set by user, try to locate tool using the code snippet 43160 if test -n "$ac_tool_prefix"; then 43161 for ac_prog in gobjdump objdump 43162 do 43163 # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args. 43164 set dummy $ac_tool_prefix$ac_prog; ac_word=$2 43165 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 43166 $as_echo_n "checking for $ac_word... " >&6; } 43167 if ${ac_cv_prog_OBJDUMP+:} false; then : 43168 $as_echo_n "(cached) " >&6 43169 else 43170 if test -n "$OBJDUMP"; then 43171 ac_cv_prog_OBJDUMP="$OBJDUMP" # Let the user override the test. 43172 else 43173 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 43174 for as_dir in $PATH 43175 do 43176 IFS=$as_save_IFS 43177 test -z "$as_dir" && as_dir=. 43178 for ac_exec_ext in '' $ac_executable_extensions; do 43179 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 43180 ac_cv_prog_OBJDUMP="$ac_tool_prefix$ac_prog" 43181 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 43182 break 2 43183 fi 43184 done 43185 done 43186 IFS=$as_save_IFS 43187 43188 fi 43189 fi 43190 OBJDUMP=$ac_cv_prog_OBJDUMP 43191 if test -n "$OBJDUMP"; then 43192 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $OBJDUMP" >&5 43193 $as_echo "$OBJDUMP" >&6; } 43194 else 43195 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 43196 $as_echo "no" >&6; } 43197 fi 43198 43199 43200 test -n "$OBJDUMP" && break 43201 done 43202 fi 43203 if test -z "$OBJDUMP"; then 43204 ac_ct_OBJDUMP=$OBJDUMP 43205 for ac_prog in gobjdump objdump 43206 do 43207 # Extract the first word of "$ac_prog", so it can be a program name with args. 43208 set dummy $ac_prog; ac_word=$2 43209 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 43210 $as_echo_n "checking for $ac_word... " >&6; } 43211 if ${ac_cv_prog_ac_ct_OBJDUMP+:} false; then : 43212 $as_echo_n "(cached) " >&6 43213 else 43214 if test -n "$ac_ct_OBJDUMP"; then 43215 ac_cv_prog_ac_ct_OBJDUMP="$ac_ct_OBJDUMP" # Let the user override the test. 43216 else 43217 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 43218 for as_dir in $PATH 43219 do 43220 IFS=$as_save_IFS 43221 test -z "$as_dir" && as_dir=. 43222 for ac_exec_ext in '' $ac_executable_extensions; do 43223 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 43224 ac_cv_prog_ac_ct_OBJDUMP="$ac_prog" 43225 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 43226 break 2 43227 fi 43228 done 43229 done 43230 IFS=$as_save_IFS 43231 43232 fi 43233 fi 43234 ac_ct_OBJDUMP=$ac_cv_prog_ac_ct_OBJDUMP 43235 if test -n "$ac_ct_OBJDUMP"; then 43236 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_OBJDUMP" >&5 43237 $as_echo "$ac_ct_OBJDUMP" >&6; } 43238 else 43239 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 43240 $as_echo "no" >&6; } 43241 fi 43242 43243 43244 test -n "$ac_ct_OBJDUMP" && break 43245 done 43246 43247 if test "x$ac_ct_OBJDUMP" = x; then 43248 OBJDUMP="" 43249 else 43250 case $cross_compiling:$ac_tool_warned in 43251 yes:) 43252 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5 43253 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;} 43254 ac_tool_warned=yes ;; 43255 esac 43256 OBJDUMP=$ac_ct_OBJDUMP 43257 fi 43258 fi 43259 43260 else 43261 # The variable is set, but is it from the command line or the environment? 43262 43263 # Try to remove the string !OBJDUMP! from our list. 43264 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!OBJDUMP!/} 43265 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 43266 # If it failed, the variable was not from the command line. Ignore it, 43267 # but warn the user (except for BASH, which is always set by the calling BASH). 43268 if test "xOBJDUMP" != xBASH; then 43269 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of OBJDUMP from the environment. Use command line variables instead." >&5 43270 $as_echo "$as_me: WARNING: Ignoring value of OBJDUMP from the environment. Use command line variables instead." >&2;} 43271 fi 43272 # Try to locate tool using the code snippet 43273 if test -n "$ac_tool_prefix"; then 43274 for ac_prog in gobjdump objdump 43275 do 43276 # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args. 43277 set dummy $ac_tool_prefix$ac_prog; ac_word=$2 43278 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 43279 $as_echo_n "checking for $ac_word... " >&6; } 43280 if ${ac_cv_prog_OBJDUMP+:} false; then : 43281 $as_echo_n "(cached) " >&6 43282 else 43283 if test -n "$OBJDUMP"; then 43284 ac_cv_prog_OBJDUMP="$OBJDUMP" # Let the user override the test. 43285 else 43286 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 43287 for as_dir in $PATH 43288 do 43289 IFS=$as_save_IFS 43290 test -z "$as_dir" && as_dir=. 43291 for ac_exec_ext in '' $ac_executable_extensions; do 43292 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 43293 ac_cv_prog_OBJDUMP="$ac_tool_prefix$ac_prog" 43294 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 43295 break 2 43296 fi 43297 done 43298 done 43299 IFS=$as_save_IFS 43300 43301 fi 43302 fi 43303 OBJDUMP=$ac_cv_prog_OBJDUMP 43304 if test -n "$OBJDUMP"; then 43305 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $OBJDUMP" >&5 43306 $as_echo "$OBJDUMP" >&6; } 43307 else 43308 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 43309 $as_echo "no" >&6; } 43310 fi 43311 43312 43313 test -n "$OBJDUMP" && break 43314 done 43315 fi 43316 if test -z "$OBJDUMP"; then 43317 ac_ct_OBJDUMP=$OBJDUMP 43318 for ac_prog in gobjdump objdump 43319 do 43320 # Extract the first word of "$ac_prog", so it can be a program name with args. 43321 set dummy $ac_prog; ac_word=$2 43322 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 43323 $as_echo_n "checking for $ac_word... " >&6; } 43324 if ${ac_cv_prog_ac_ct_OBJDUMP+:} false; then : 43325 $as_echo_n "(cached) " >&6 43326 else 43327 if test -n "$ac_ct_OBJDUMP"; then 43328 ac_cv_prog_ac_ct_OBJDUMP="$ac_ct_OBJDUMP" # Let the user override the test. 43329 else 43330 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 43331 for as_dir in $PATH 43332 do 43333 IFS=$as_save_IFS 43334 test -z "$as_dir" && as_dir=. 43335 for ac_exec_ext in '' $ac_executable_extensions; do 43336 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 43337 ac_cv_prog_ac_ct_OBJDUMP="$ac_prog" 43338 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 43339 break 2 43340 fi 43341 done 43342 done 43343 IFS=$as_save_IFS 43344 43345 fi 43346 fi 43347 ac_ct_OBJDUMP=$ac_cv_prog_ac_ct_OBJDUMP 43348 if test -n "$ac_ct_OBJDUMP"; then 43349 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_OBJDUMP" >&5 43350 $as_echo "$ac_ct_OBJDUMP" >&6; } 43351 else 43352 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 43353 $as_echo "no" >&6; } 43354 fi 43355 43356 43357 test -n "$ac_ct_OBJDUMP" && break 43358 done 43359 43360 if test "x$ac_ct_OBJDUMP" = x; then 43361 OBJDUMP="" 43362 else 43363 case $cross_compiling:$ac_tool_warned in 43364 yes:) 43365 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5 43366 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;} 43367 ac_tool_warned=yes ;; 43368 esac 43369 OBJDUMP=$ac_ct_OBJDUMP 43370 fi 43371 fi 43372 43373 else 43374 # If it succeeded, then it was overridden by the user. We will use it 43375 # for the tool. 43376 43377 # First remove it from the list of overridden variables, so we can test 43378 # for unknown variables in the end. 43379 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 43380 43381 # Check if we try to supply an empty value 43382 if test "x$OBJDUMP" = x; then 43383 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool OBJDUMP= (no value)" >&5 43384 $as_echo "$as_me: Setting user supplied tool OBJDUMP= (no value)" >&6;} 43385 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for OBJDUMP" >&5 43386 $as_echo_n "checking for OBJDUMP... " >&6; } 43387 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 43388 $as_echo "disabled" >&6; } 43389 else 43390 # Check if the provided tool contains a complete path. 43391 tool_specified="$OBJDUMP" 43392 tool_basename="${tool_specified##*/}" 43393 if test "x$tool_basename" = "x$tool_specified"; then 43394 # A command without a complete path is provided, search $PATH. 43395 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool OBJDUMP=$tool_basename" >&5 43396 $as_echo "$as_me: Will search for user supplied tool OBJDUMP=$tool_basename" >&6;} 43397 # Extract the first word of "$tool_basename", so it can be a program name with args. 43398 set dummy $tool_basename; ac_word=$2 43399 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 43400 $as_echo_n "checking for $ac_word... " >&6; } 43401 if ${ac_cv_path_OBJDUMP+:} false; then : 43402 $as_echo_n "(cached) " >&6 43403 else 43404 case $OBJDUMP in 43405 [\\/]* | ?:[\\/]*) 43406 ac_cv_path_OBJDUMP="$OBJDUMP" # Let the user override the test with a path. 43407 ;; 43408 *) 43409 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 43410 for as_dir in $PATH 43411 do 43412 IFS=$as_save_IFS 43413 test -z "$as_dir" && as_dir=. 43414 for ac_exec_ext in '' $ac_executable_extensions; do 43415 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 43416 ac_cv_path_OBJDUMP="$as_dir/$ac_word$ac_exec_ext" 43417 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 43418 break 2 43419 fi 43420 done 43421 done 43422 IFS=$as_save_IFS 43423 43424 ;; 43425 esac 43426 fi 43427 OBJDUMP=$ac_cv_path_OBJDUMP 43428 if test -n "$OBJDUMP"; then 43429 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $OBJDUMP" >&5 43430 $as_echo "$OBJDUMP" >&6; } 43431 else 43432 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 43433 $as_echo "no" >&6; } 43434 fi 43435 43436 43437 if test "x$OBJDUMP" = x; then 43438 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 43439 fi 43440 else 43441 # Otherwise we believe it is a complete path. Use it as it is. 43442 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool OBJDUMP=$tool_specified" >&5 43443 $as_echo "$as_me: Will use user supplied tool OBJDUMP=$tool_specified" >&6;} 43444 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for OBJDUMP" >&5 43445 $as_echo_n "checking for OBJDUMP... " >&6; } 43446 if test ! -x "$tool_specified"; then 43447 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 43448 $as_echo "not found" >&6; } 43449 as_fn_error $? "User supplied tool OBJDUMP=$tool_specified does not exist or is not executable" "$LINENO" 5 43450 fi 43451 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 43452 $as_echo "$tool_specified" >&6; } 43453 fi 43454 fi 43455 fi 43456 43457 fi 43458 43459 43460 if test "x$OBJDUMP" != x; then 43461 # Only used for compare.sh; we can live without it. BASIC_FIXUP_EXECUTABLE 43462 # bails if argument is missing. 43463 43464 # Only process if variable expands to non-empty 43465 43466 if test "x$OBJDUMP" != x; then 43467 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 43468 43469 # First separate the path from the arguments. This will split at the first 43470 # space. 43471 complete="$OBJDUMP" 43472 path="${complete%% *}" 43473 tmp="$complete EOL" 43474 arguments="${tmp#* }" 43475 43476 # Input might be given as Windows format, start by converting to 43477 # unix format. 43478 new_path=`$CYGPATH -u "$path"` 43479 43480 # Now try to locate executable using which 43481 new_path=`$WHICH "$new_path" 2> /dev/null` 43482 # bat and cmd files are not always considered executable in cygwin causing which 43483 # to not find them 43484 if test "x$new_path" = x \ 43485 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 43486 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 43487 new_path=`$CYGPATH -u "$path"` 43488 fi 43489 if test "x$new_path" = x; then 43490 # Oops. Which didn't find the executable. 43491 # The splitting of arguments from the executable at a space might have been incorrect, 43492 # since paths with space are more likely in Windows. Give it another try with the whole 43493 # argument. 43494 path="$complete" 43495 arguments="EOL" 43496 new_path=`$CYGPATH -u "$path"` 43497 new_path=`$WHICH "$new_path" 2> /dev/null` 43498 # bat and cmd files are not always considered executable in cygwin causing which 43499 # to not find them 43500 if test "x$new_path" = x \ 43501 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 43502 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 43503 new_path=`$CYGPATH -u "$path"` 43504 fi 43505 if test "x$new_path" = x; then 43506 # It's still not found. Now this is an unrecoverable error. 43507 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of OBJDUMP, which resolves as \"$complete\", is not found." >&5 43508 $as_echo "$as_me: The path of OBJDUMP, which resolves as \"$complete\", is not found." >&6;} 43509 has_space=`$ECHO "$complete" | $GREP " "` 43510 if test "x$has_space" != x; then 43511 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 43512 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 43513 fi 43514 as_fn_error $? "Cannot locate the the path of OBJDUMP" "$LINENO" 5 43515 fi 43516 fi 43517 43518 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 43519 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 43520 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 43521 # "foo.exe" is OK but "foo" is an error. 43522 # 43523 # This test is therefore slightly more accurate than "test -f" to check for file presence. 43524 # It is also a way to make sure we got the proper file name for the real test later on. 43525 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 43526 if test "x$test_shortpath" = x; then 43527 # Short path failed, file does not exist as specified. 43528 # Try adding .exe or .cmd 43529 if test -f "${new_path}.exe"; then 43530 input_to_shortpath="${new_path}.exe" 43531 elif test -f "${new_path}.cmd"; then 43532 input_to_shortpath="${new_path}.cmd" 43533 else 43534 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of OBJDUMP, which resolves as \"$new_path\", is invalid." >&5 43535 $as_echo "$as_me: The path of OBJDUMP, which resolves as \"$new_path\", is invalid." >&6;} 43536 { $as_echo "$as_me:${as_lineno-$LINENO}: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&5 43537 $as_echo "$as_me: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&6;} 43538 as_fn_error $? "Cannot locate the the path of OBJDUMP" "$LINENO" 5 43539 fi 43540 else 43541 input_to_shortpath="$new_path" 43542 fi 43543 43544 # Call helper function which possibly converts this using DOS-style short mode. 43545 # If so, the updated path is stored in $new_path. 43546 new_path="$input_to_shortpath" 43547 43548 input_path="$input_to_shortpath" 43549 # Check if we need to convert this using DOS-style short mode. If the path 43550 # contains just simple characters, use it. Otherwise (spaces, weird characters), 43551 # take no chances and rewrite it. 43552 # Note: m4 eats our [], so we need to use [ and ] instead. 43553 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 43554 if test "x$has_forbidden_chars" != x; then 43555 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 43556 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 43557 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 43558 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 43559 # Going to short mode and back again did indeed matter. Since short mode is 43560 # case insensitive, let's make it lowercase to improve readability. 43561 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 43562 # Now convert it back to Unix-style (cygpath) 43563 input_path=`$CYGPATH -u "$shortmode_path"` 43564 new_path="$input_path" 43565 fi 43566 fi 43567 43568 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 43569 if test "x$test_cygdrive_prefix" = x; then 43570 # As a simple fix, exclude /usr/bin since it's not a real path. 43571 if test "x`$ECHO $input_to_shortpath | $GREP ^/usr/bin/`" = x; then 43572 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 43573 # a path prefixed by /cygdrive for fixpath to work. 43574 new_path="$CYGWIN_ROOT_PATH$input_path" 43575 fi 43576 fi 43577 43578 # remove trailing .exe if any 43579 new_path="${new_path/%.exe/}" 43580 43581 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 43582 43583 # First separate the path from the arguments. This will split at the first 43584 # space. 43585 complete="$OBJDUMP" 43586 path="${complete%% *}" 43587 tmp="$complete EOL" 43588 arguments="${tmp#* }" 43589 43590 # Input might be given as Windows format, start by converting to 43591 # unix format. 43592 new_path="$path" 43593 43594 windows_path="$new_path" 43595 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 43596 unix_path=`$CYGPATH -u "$windows_path"` 43597 new_path="$unix_path" 43598 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 43599 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 43600 new_path="$unix_path" 43601 fi 43602 43603 43604 # Now try to locate executable using which 43605 new_path=`$WHICH "$new_path" 2> /dev/null` 43606 43607 if test "x$new_path" = x; then 43608 # Oops. Which didn't find the executable. 43609 # The splitting of arguments from the executable at a space might have been incorrect, 43610 # since paths with space are more likely in Windows. Give it another try with the whole 43611 # argument. 43612 path="$complete" 43613 arguments="EOL" 43614 new_path="$path" 43615 43616 windows_path="$new_path" 43617 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 43618 unix_path=`$CYGPATH -u "$windows_path"` 43619 new_path="$unix_path" 43620 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 43621 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 43622 new_path="$unix_path" 43623 fi 43624 43625 43626 new_path=`$WHICH "$new_path" 2> /dev/null` 43627 # bat and cmd files are not always considered executable in MSYS causing which 43628 # to not find them 43629 if test "x$new_path" = x \ 43630 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 43631 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 43632 new_path="$path" 43633 43634 windows_path="$new_path" 43635 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 43636 unix_path=`$CYGPATH -u "$windows_path"` 43637 new_path="$unix_path" 43638 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 43639 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 43640 new_path="$unix_path" 43641 fi 43642 43643 fi 43644 43645 if test "x$new_path" = x; then 43646 # It's still not found. Now this is an unrecoverable error. 43647 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of OBJDUMP, which resolves as \"$complete\", is not found." >&5 43648 $as_echo "$as_me: The path of OBJDUMP, which resolves as \"$complete\", is not found." >&6;} 43649 has_space=`$ECHO "$complete" | $GREP " "` 43650 if test "x$has_space" != x; then 43651 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 43652 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 43653 fi 43654 as_fn_error $? "Cannot locate the the path of OBJDUMP" "$LINENO" 5 43655 fi 43656 fi 43657 43658 # Now new_path has a complete unix path to the binary 43659 if test "x`$ECHO $new_path | $GREP ^/bin/`" != x; then 43660 # Keep paths in /bin as-is, but remove trailing .exe if any 43661 new_path="${new_path/%.exe/}" 43662 # Do not save /bin paths to all_fixpath_prefixes! 43663 else 43664 # Not in mixed or Windows style, start by that. 43665 new_path=`cmd //c echo $new_path` 43666 43667 input_path="$new_path" 43668 # Check if we need to convert this using DOS-style short mode. If the path 43669 # contains just simple characters, use it. Otherwise (spaces, weird characters), 43670 # take no chances and rewrite it. 43671 # Note: m4 eats our [], so we need to use [ and ] instead. 43672 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 43673 if test "x$has_forbidden_chars" != x; then 43674 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 43675 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 43676 fi 43677 43678 # Output is in $new_path 43679 43680 windows_path="$new_path" 43681 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 43682 unix_path=`$CYGPATH -u "$windows_path"` 43683 new_path="$unix_path" 43684 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 43685 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 43686 new_path="$unix_path" 43687 fi 43688 43689 # remove trailing .exe if any 43690 new_path="${new_path/%.exe/}" 43691 43692 # Save the first 10 bytes of this path to the storage, so fixpath can work. 43693 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 43694 fi 43695 43696 else 43697 # We're on a unix platform. Hooray! :) 43698 # First separate the path from the arguments. This will split at the first 43699 # space. 43700 complete="$OBJDUMP" 43701 path="${complete%% *}" 43702 tmp="$complete EOL" 43703 arguments="${tmp#* }" 43704 43705 # Cannot rely on the command "which" here since it doesn't always work. 43706 is_absolute_path=`$ECHO "$path" | $GREP ^/` 43707 if test -z "$is_absolute_path"; then 43708 # Path to executable is not absolute. Find it. 43709 IFS_save="$IFS" 43710 IFS=: 43711 for p in $PATH; do 43712 if test -f "$p/$path" && test -x "$p/$path"; then 43713 new_path="$p/$path" 43714 break 43715 fi 43716 done 43717 IFS="$IFS_save" 43718 else 43719 # This is an absolute path, we can use it without further modifications. 43720 new_path="$path" 43721 fi 43722 43723 if test "x$new_path" = x; then 43724 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of OBJDUMP, which resolves as \"$complete\", is not found." >&5 43725 $as_echo "$as_me: The path of OBJDUMP, which resolves as \"$complete\", is not found." >&6;} 43726 has_space=`$ECHO "$complete" | $GREP " "` 43727 if test "x$has_space" != x; then 43728 { $as_echo "$as_me:${as_lineno-$LINENO}: This might be caused by spaces in the path, which is not allowed." >&5 43729 $as_echo "$as_me: This might be caused by spaces in the path, which is not allowed." >&6;} 43730 fi 43731 as_fn_error $? "Cannot locate the the path of OBJDUMP" "$LINENO" 5 43732 fi 43733 fi 43734 43735 # Now join together the path and the arguments once again 43736 if test "x$arguments" != xEOL; then 43737 new_complete="$new_path ${arguments% *}" 43738 else 43739 new_complete="$new_path" 43740 fi 43741 43742 if test "x$complete" != "x$new_complete"; then 43743 OBJDUMP="$new_complete" 43744 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting OBJDUMP to \"$new_complete\"" >&5 43745 $as_echo "$as_me: Rewriting OBJDUMP to \"$new_complete\"" >&6;} 43746 fi 43747 fi 43748 43749 fi 43750 43751 43752 # Restore old path, except for the microsoft toolchain, which requires VS_PATH 43753 # to remain in place. Otherwise the compiler will not work in some siutations 43754 # in later configure checks. 43755 if test "x$TOOLCHAIN_TYPE" != "xmicrosoft"; then 43756 PATH="$OLD_PATH" 43757 fi 43758 43759 # Restore the flags to the user specified values. 43760 # This is necessary since AC_PROG_CC defaults CFLAGS to "-g -O2" 43761 CFLAGS="$ORG_CFLAGS" 43762 CXXFLAGS="$ORG_CXXFLAGS" 43763 43764 43765 # Finally do some processing after the detection phase 43766 43767 if test "x$COMPILE_TYPE" = "xcross"; then 43768 # Now we need to find a C/C++ compiler that can build executables for the 43769 # build platform. We can't use the AC_PROG_CC macro, since it can only be 43770 # used once. Also, we need to do this without adding a tools dir to the 43771 # path, otherwise we might pick up cross-compilers which don't use standard 43772 # naming. 43773 43774 OLDPATH="$PATH" 43775 43776 43777 # Check whether --with-build-devkit was given. 43778 if test "${with_build_devkit+set}" = set; then : 43779 withval=$with_build_devkit; 43780 fi 43781 43782 if test "x$with_build_devkit" = "xyes"; then 43783 as_fn_error $? "--with-build-devkit must have a value" "$LINENO" 5 43784 elif test -n "$with_build_devkit"; then 43785 if test ! -d "$with_build_devkit"; then 43786 as_fn_error $? "--with-build-devkit points to non existing dir: $with_build_devkit" "$LINENO" 5 43787 else 43788 43789 # Only process if variable expands to non-empty 43790 43791 if test "x$with_build_devkit" != x; then 43792 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 43793 43794 # Input might be given as Windows format, start by converting to 43795 # unix format. 43796 path="$with_build_devkit" 43797 new_path=`$CYGPATH -u "$path"` 43798 43799 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 43800 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 43801 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 43802 # "foo.exe" is OK but "foo" is an error. 43803 # 43804 # This test is therefore slightly more accurate than "test -f" to check for file precense. 43805 # It is also a way to make sure we got the proper file name for the real test later on. 43806 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 43807 if test "x$test_shortpath" = x; then 43808 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of with_build_devkit, which resolves as \"$path\", is invalid." >&5 43809 $as_echo "$as_me: The path of with_build_devkit, which resolves as \"$path\", is invalid." >&6;} 43810 as_fn_error $? "Cannot locate the the path of with_build_devkit" "$LINENO" 5 43811 fi 43812 43813 # Call helper function which possibly converts this using DOS-style short mode. 43814 # If so, the updated path is stored in $new_path. 43815 43816 input_path="$new_path" 43817 # Check if we need to convert this using DOS-style short mode. If the path 43818 # contains just simple characters, use it. Otherwise (spaces, weird characters), 43819 # take no chances and rewrite it. 43820 # Note: m4 eats our [], so we need to use [ and ] instead. 43821 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 43822 if test "x$has_forbidden_chars" != x; then 43823 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 43824 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 43825 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 43826 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 43827 # Going to short mode and back again did indeed matter. Since short mode is 43828 # case insensitive, let's make it lowercase to improve readability. 43829 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 43830 # Now convert it back to Unix-style (cygpath) 43831 input_path=`$CYGPATH -u "$shortmode_path"` 43832 new_path="$input_path" 43833 fi 43834 fi 43835 43836 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 43837 if test "x$test_cygdrive_prefix" = x; then 43838 # As a simple fix, exclude /usr/bin since it's not a real path. 43839 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 43840 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 43841 # a path prefixed by /cygdrive for fixpath to work. 43842 new_path="$CYGWIN_ROOT_PATH$input_path" 43843 fi 43844 fi 43845 43846 43847 if test "x$path" != "x$new_path"; then 43848 with_build_devkit="$new_path" 43849 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting with_build_devkit to \"$new_path\"" >&5 43850 $as_echo "$as_me: Rewriting with_build_devkit to \"$new_path\"" >&6;} 43851 fi 43852 43853 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 43854 43855 path="$with_build_devkit" 43856 has_colon=`$ECHO $path | $GREP ^.:` 43857 new_path="$path" 43858 if test "x$has_colon" = x; then 43859 # Not in mixed or Windows style, start by that. 43860 new_path=`cmd //c echo $path` 43861 fi 43862 43863 43864 input_path="$new_path" 43865 # Check if we need to convert this using DOS-style short mode. If the path 43866 # contains just simple characters, use it. Otherwise (spaces, weird characters), 43867 # take no chances and rewrite it. 43868 # Note: m4 eats our [], so we need to use [ and ] instead. 43869 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 43870 if test "x$has_forbidden_chars" != x; then 43871 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 43872 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 43873 fi 43874 43875 43876 windows_path="$new_path" 43877 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 43878 unix_path=`$CYGPATH -u "$windows_path"` 43879 new_path="$unix_path" 43880 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 43881 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 43882 new_path="$unix_path" 43883 fi 43884 43885 if test "x$path" != "x$new_path"; then 43886 with_build_devkit="$new_path" 43887 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting with_build_devkit to \"$new_path\"" >&5 43888 $as_echo "$as_me: Rewriting with_build_devkit to \"$new_path\"" >&6;} 43889 fi 43890 43891 # Save the first 10 bytes of this path to the storage, so fixpath can work. 43892 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 43893 43894 else 43895 # We're on a unix platform. Hooray! :) 43896 path="$with_build_devkit" 43897 has_space=`$ECHO "$path" | $GREP " "` 43898 if test "x$has_space" != x; then 43899 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of with_build_devkit, which resolves as \"$path\", is invalid." >&5 43900 $as_echo "$as_me: The path of with_build_devkit, which resolves as \"$path\", is invalid." >&6;} 43901 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 43902 fi 43903 43904 # Use eval to expand a potential ~ 43905 eval path="$path" 43906 if test ! -f "$path" && test ! -d "$path"; then 43907 as_fn_error $? "The path of with_build_devkit, which resolves as \"$path\", is not found." "$LINENO" 5 43908 fi 43909 43910 if test -d "$path"; then 43911 with_build_devkit="`cd "$path"; $THEPWDCMD -L`" 43912 else 43913 dir="`$DIRNAME "$path"`" 43914 base="`$BASENAME "$path"`" 43915 with_build_devkit="`cd "$dir"; $THEPWDCMD -L`/$base" 43916 fi 43917 fi 43918 fi 43919 43920 BUILD_DEVKIT_ROOT="$with_build_devkit" 43921 # Check for a meta data info file in the root of the devkit 43922 if test -f "$BUILD_DEVKIT_ROOT/devkit.info"; then 43923 # Process devkit.info so that existing devkit variables are not 43924 # modified by this 43925 $SED -e "s/^DEVKIT_/BUILD_DEVKIT_/g" \ 43926 -e "s/\$DEVKIT_ROOT/\$BUILD_DEVKIT_ROOT/g" \ 43927 -e "s/\$host/\$build/g" \ 43928 $BUILD_DEVKIT_ROOT/devkit.info \ 43929 > $CONFIGURESUPPORT_OUTPUTDIR/build-devkit.info 43930 . $CONFIGURESUPPORT_OUTPUTDIR/build-devkit.info 43931 # This potentially sets the following: 43932 # A descriptive name of the devkit 43933 43934 if test "x$BUILD_DEVKIT_NAME" = x; then 43935 eval BUILD_DEVKIT_NAME="\${BUILD_DEVKIT_NAME_${OPENJDK_TARGET_CPU}}" 43936 fi 43937 43938 # Corresponds to --with-extra-path 43939 43940 if test "x$BUILD_DEVKIT_EXTRA_PATH" = x; then 43941 eval BUILD_DEVKIT_EXTRA_PATH="\${BUILD_DEVKIT_EXTRA_PATH_${OPENJDK_TARGET_CPU}}" 43942 fi 43943 43944 # Corresponds to --with-toolchain-path 43945 43946 if test "x$BUILD_DEVKIT_TOOLCHAIN_PATH" = x; then 43947 eval BUILD_DEVKIT_TOOLCHAIN_PATH="\${BUILD_DEVKIT_TOOLCHAIN_PATH_${OPENJDK_TARGET_CPU}}" 43948 fi 43949 43950 # Corresponds to --with-sysroot 43951 43952 if test "x$BUILD_DEVKIT_SYSROOT" = x; then 43953 eval BUILD_DEVKIT_SYSROOT="\${BUILD_DEVKIT_SYSROOT_${OPENJDK_TARGET_CPU}}" 43954 fi 43955 43956 # Skip the Window specific parts 43957 fi 43958 43959 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for build platform devkit" >&5 43960 $as_echo_n "checking for build platform devkit... " >&6; } 43961 if test "x$BUILD_DEVKIT_NAME" != x; then 43962 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BUILD_DEVKIT_NAME in $BUILD_DEVKIT_ROOT" >&5 43963 $as_echo "$BUILD_DEVKIT_NAME in $BUILD_DEVKIT_ROOT" >&6; } 43964 else 43965 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BUILD_DEVKIT_ROOT" >&5 43966 $as_echo "$BUILD_DEVKIT_ROOT" >&6; } 43967 fi 43968 43969 BUILD_SYSROOT="$BUILD_DEVKIT_SYSROOT" 43970 43971 if test "x$BUILD_SYSROOT" != "x"; then 43972 if test "x$TOOLCHAIN_TYPE" = xsolstudio; then 43973 if test "x$OPENJDK_TARGET_OS" = xsolaris; then 43974 # Solaris Studio does not have a concept of sysroot. Instead we must 43975 # make sure the default include and lib dirs are appended to each 43976 # compile and link command line. Must also add -I-xbuiltin to enable 43977 # inlining of system functions and intrinsics. 43978 BUILD_SYSROOT_CFLAGS="-I-xbuiltin -I$BUILD_SYSROOT/usr/include" 43979 BUILD_SYSROOT_LDFLAGS="-L$BUILD_SYSROOT/usr/lib$OPENJDK_TARGET_CPU_ISADIR \ 43980 -L$BUILD_SYSROOT/lib$OPENJDK_TARGET_CPU_ISADIR" 43981 fi 43982 elif test "x$TOOLCHAIN_TYPE" = xgcc; then 43983 BUILD_SYSROOT_CFLAGS="--sysroot=$BUILD_SYSROOT" 43984 BUILD_SYSROOT_LDFLAGS="--sysroot=$BUILD_SYSROOT" 43985 elif test "x$TOOLCHAIN_TYPE" = xclang; then 43986 BUILD_SYSROOT_CFLAGS="-isysroot $BUILD_SYSROOT" 43987 BUILD_SYSROOT_LDFLAGS="-isysroot $BUILD_SYSROOT" 43988 fi 43989 # Propagate the sysroot args to hotspot 43990 BUILD_LEGACY_EXTRA_CFLAGS="$BUILD_LEGACY_EXTRA_CFLAGS $BUILD_SYSROOT_CFLAGS" 43991 BUILD_LEGACY_EXTRA_CXXFLAGS="$BUILD_LEGACY_EXTRA_CXXFLAGS $BUILD_SYSROOT_CFLAGS" 43992 BUILD_LEGACY_EXTRA_LDFLAGS="$BUILD_LEGACY_EXTRA_LDFLAGS $BUILD_SYSROOT_LDFLAGS" 43993 # The global CFLAGS and LDFLAGS variables need these for configure to function 43994 BUILD_CFLAGS="$BUILD_CFLAGS $BUILD_SYSROOT_CFLAGS" 43995 BUILD_CPPFLAGS="$BUILD_CPPFLAGS $BUILD_SYSROOT_CFLAGS" 43996 BUILD_CXXFLAGS="$BUILD_CXXFLAGS $BUILD_SYSROOT_CFLAGS" 43997 BUILD_LDFLAGS="$BUILD_LDFLAGS $BUILD_SYSROOT_LDFLAGS" 43998 fi 43999 44000 if test "x$OPENJDK_TARGET_OS" = xmacosx; then 44001 # We also need -iframework<path>/System/Library/Frameworks 44002 BUILD_SYSROOT_CFLAGS="$BUILD_SYSROOT_CFLAGS -iframework $BUILD_SYSROOT/System/Library/Frameworks" 44003 BUILD_SYSROOT_LDFLAGS="$BUILD_SYSROOT_LDFLAGS -iframework $BUILD_SYSROOT/System/Library/Frameworks" 44004 # These always need to be set, or we can't find the frameworks embedded in JavaVM.framework 44005 # set this here so it doesn't have to be peppered throughout the forest 44006 BUILD_SYSROOT_CFLAGS="$BUILD_SYSROOT_CFLAGS -F $BUILD_SYSROOT/System/Library/Frameworks/JavaVM.framework/Frameworks" 44007 BUILD_SYSROOT_LDFLAGS="$BUILD_SYSROOT_LDFLAGS -F $BUILD_SYSROOT/System/Library/Frameworks/JavaVM.framework/Frameworks" 44008 fi 44009 44010 44011 44012 44013 44014 # Fallback default of just /bin if DEVKIT_PATH is not defined 44015 if test "x$BUILD_DEVKIT_TOOLCHAIN_PATH" = x; then 44016 BUILD_DEVKIT_TOOLCHAIN_PATH="$BUILD_DEVKIT_ROOT/bin" 44017 fi 44018 PATH="$BUILD_DEVKIT_TOOLCHAIN_PATH:$BUILD_DEVKIT_EXTRA_PATH" 44019 fi 44020 fi 44021 44022 # FIXME: we should list the discovered compilers as an exclude pattern! 44023 # If we do that, we can do this detection before POST_DETECTION, and still 44024 # find the build compilers in the tools dir, if needed. 44025 44026 44027 44028 # Publish this variable in the help. 44029 44030 44031 if [ -z "${BUILD_CC+x}" ]; then 44032 # The variable is not set by user, try to locate tool using the code snippet 44033 for ac_prog in cl cc gcc 44034 do 44035 # Extract the first word of "$ac_prog", so it can be a program name with args. 44036 set dummy $ac_prog; ac_word=$2 44037 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 44038 $as_echo_n "checking for $ac_word... " >&6; } 44039 if ${ac_cv_path_BUILD_CC+:} false; then : 44040 $as_echo_n "(cached) " >&6 44041 else 44042 case $BUILD_CC in 44043 [\\/]* | ?:[\\/]*) 44044 ac_cv_path_BUILD_CC="$BUILD_CC" # Let the user override the test with a path. 44045 ;; 44046 *) 44047 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 44048 for as_dir in $PATH 44049 do 44050 IFS=$as_save_IFS 44051 test -z "$as_dir" && as_dir=. 44052 for ac_exec_ext in '' $ac_executable_extensions; do 44053 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 44054 ac_cv_path_BUILD_CC="$as_dir/$ac_word$ac_exec_ext" 44055 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 44056 break 2 44057 fi 44058 done 44059 done 44060 IFS=$as_save_IFS 44061 44062 ;; 44063 esac 44064 fi 44065 BUILD_CC=$ac_cv_path_BUILD_CC 44066 if test -n "$BUILD_CC"; then 44067 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BUILD_CC" >&5 44068 $as_echo "$BUILD_CC" >&6; } 44069 else 44070 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 44071 $as_echo "no" >&6; } 44072 fi 44073 44074 44075 test -n "$BUILD_CC" && break 44076 done 44077 44078 else 44079 # The variable is set, but is it from the command line or the environment? 44080 44081 # Try to remove the string !BUILD_CC! from our list. 44082 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!BUILD_CC!/} 44083 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 44084 # If it failed, the variable was not from the command line. Ignore it, 44085 # but warn the user (except for BASH, which is always set by the calling BASH). 44086 if test "xBUILD_CC" != xBASH; then 44087 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of BUILD_CC from the environment. Use command line variables instead." >&5 44088 $as_echo "$as_me: WARNING: Ignoring value of BUILD_CC from the environment. Use command line variables instead." >&2;} 44089 fi 44090 # Try to locate tool using the code snippet 44091 for ac_prog in cl cc gcc 44092 do 44093 # Extract the first word of "$ac_prog", so it can be a program name with args. 44094 set dummy $ac_prog; ac_word=$2 44095 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 44096 $as_echo_n "checking for $ac_word... " >&6; } 44097 if ${ac_cv_path_BUILD_CC+:} false; then : 44098 $as_echo_n "(cached) " >&6 44099 else 44100 case $BUILD_CC in 44101 [\\/]* | ?:[\\/]*) 44102 ac_cv_path_BUILD_CC="$BUILD_CC" # Let the user override the test with a path. 44103 ;; 44104 *) 44105 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 44106 for as_dir in $PATH 44107 do 44108 IFS=$as_save_IFS 44109 test -z "$as_dir" && as_dir=. 44110 for ac_exec_ext in '' $ac_executable_extensions; do 44111 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 44112 ac_cv_path_BUILD_CC="$as_dir/$ac_word$ac_exec_ext" 44113 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 44114 break 2 44115 fi 44116 done 44117 done 44118 IFS=$as_save_IFS 44119 44120 ;; 44121 esac 44122 fi 44123 BUILD_CC=$ac_cv_path_BUILD_CC 44124 if test -n "$BUILD_CC"; then 44125 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BUILD_CC" >&5 44126 $as_echo "$BUILD_CC" >&6; } 44127 else 44128 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 44129 $as_echo "no" >&6; } 44130 fi 44131 44132 44133 test -n "$BUILD_CC" && break 44134 done 44135 44136 else 44137 # If it succeeded, then it was overridden by the user. We will use it 44138 # for the tool. 44139 44140 # First remove it from the list of overridden variables, so we can test 44141 # for unknown variables in the end. 44142 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 44143 44144 # Check if we try to supply an empty value 44145 if test "x$BUILD_CC" = x; then 44146 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool BUILD_CC= (no value)" >&5 44147 $as_echo "$as_me: Setting user supplied tool BUILD_CC= (no value)" >&6;} 44148 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for BUILD_CC" >&5 44149 $as_echo_n "checking for BUILD_CC... " >&6; } 44150 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 44151 $as_echo "disabled" >&6; } 44152 else 44153 # Check if the provided tool contains a complete path. 44154 tool_specified="$BUILD_CC" 44155 tool_basename="${tool_specified##*/}" 44156 if test "x$tool_basename" = "x$tool_specified"; then 44157 # A command without a complete path is provided, search $PATH. 44158 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool BUILD_CC=$tool_basename" >&5 44159 $as_echo "$as_me: Will search for user supplied tool BUILD_CC=$tool_basename" >&6;} 44160 # Extract the first word of "$tool_basename", so it can be a program name with args. 44161 set dummy $tool_basename; ac_word=$2 44162 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 44163 $as_echo_n "checking for $ac_word... " >&6; } 44164 if ${ac_cv_path_BUILD_CC+:} false; then : 44165 $as_echo_n "(cached) " >&6 44166 else 44167 case $BUILD_CC in 44168 [\\/]* | ?:[\\/]*) 44169 ac_cv_path_BUILD_CC="$BUILD_CC" # Let the user override the test with a path. 44170 ;; 44171 *) 44172 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 44173 for as_dir in $PATH 44174 do 44175 IFS=$as_save_IFS 44176 test -z "$as_dir" && as_dir=. 44177 for ac_exec_ext in '' $ac_executable_extensions; do 44178 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 44179 ac_cv_path_BUILD_CC="$as_dir/$ac_word$ac_exec_ext" 44180 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 44181 break 2 44182 fi 44183 done 44184 done 44185 IFS=$as_save_IFS 44186 44187 ;; 44188 esac 44189 fi 44190 BUILD_CC=$ac_cv_path_BUILD_CC 44191 if test -n "$BUILD_CC"; then 44192 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BUILD_CC" >&5 44193 $as_echo "$BUILD_CC" >&6; } 44194 else 44195 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 44196 $as_echo "no" >&6; } 44197 fi 44198 44199 44200 if test "x$BUILD_CC" = x; then 44201 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 44202 fi 44203 else 44204 # Otherwise we believe it is a complete path. Use it as it is. 44205 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool BUILD_CC=$tool_specified" >&5 44206 $as_echo "$as_me: Will use user supplied tool BUILD_CC=$tool_specified" >&6;} 44207 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for BUILD_CC" >&5 44208 $as_echo_n "checking for BUILD_CC... " >&6; } 44209 if test ! -x "$tool_specified"; then 44210 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 44211 $as_echo "not found" >&6; } 44212 as_fn_error $? "User supplied tool BUILD_CC=$tool_specified does not exist or is not executable" "$LINENO" 5 44213 fi 44214 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 44215 $as_echo "$tool_specified" >&6; } 44216 fi 44217 fi 44218 fi 44219 44220 fi 44221 44222 44223 44224 if test "x$BUILD_CC" = x; then 44225 as_fn_error $? "Could not find required tool for BUILD_CC" "$LINENO" 5 44226 fi 44227 44228 44229 44230 # Only process if variable expands to non-empty 44231 44232 if test "x$BUILD_CC" != x; then 44233 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 44234 44235 # First separate the path from the arguments. This will split at the first 44236 # space. 44237 complete="$BUILD_CC" 44238 path="${complete%% *}" 44239 tmp="$complete EOL" 44240 arguments="${tmp#* }" 44241 44242 # Input might be given as Windows format, start by converting to 44243 # unix format. 44244 new_path=`$CYGPATH -u "$path"` 44245 44246 # Now try to locate executable using which 44247 new_path=`$WHICH "$new_path" 2> /dev/null` 44248 # bat and cmd files are not always considered executable in cygwin causing which 44249 # to not find them 44250 if test "x$new_path" = x \ 44251 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 44252 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 44253 new_path=`$CYGPATH -u "$path"` 44254 fi 44255 if test "x$new_path" = x; then 44256 # Oops. Which didn't find the executable. 44257 # The splitting of arguments from the executable at a space might have been incorrect, 44258 # since paths with space are more likely in Windows. Give it another try with the whole 44259 # argument. 44260 path="$complete" 44261 arguments="EOL" 44262 new_path=`$CYGPATH -u "$path"` 44263 new_path=`$WHICH "$new_path" 2> /dev/null` 44264 # bat and cmd files are not always considered executable in cygwin causing which 44265 # to not find them 44266 if test "x$new_path" = x \ 44267 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 44268 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 44269 new_path=`$CYGPATH -u "$path"` 44270 fi 44271 if test "x$new_path" = x; then 44272 # It's still not found. Now this is an unrecoverable error. 44273 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BUILD_CC, which resolves as \"$complete\", is not found." >&5 44274 $as_echo "$as_me: The path of BUILD_CC, which resolves as \"$complete\", is not found." >&6;} 44275 has_space=`$ECHO "$complete" | $GREP " "` 44276 if test "x$has_space" != x; then 44277 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 44278 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 44279 fi 44280 as_fn_error $? "Cannot locate the the path of BUILD_CC" "$LINENO" 5 44281 fi 44282 fi 44283 44284 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 44285 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 44286 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 44287 # "foo.exe" is OK but "foo" is an error. 44288 # 44289 # This test is therefore slightly more accurate than "test -f" to check for file presence. 44290 # It is also a way to make sure we got the proper file name for the real test later on. 44291 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 44292 if test "x$test_shortpath" = x; then 44293 # Short path failed, file does not exist as specified. 44294 # Try adding .exe or .cmd 44295 if test -f "${new_path}.exe"; then 44296 input_to_shortpath="${new_path}.exe" 44297 elif test -f "${new_path}.cmd"; then 44298 input_to_shortpath="${new_path}.cmd" 44299 else 44300 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BUILD_CC, which resolves as \"$new_path\", is invalid." >&5 44301 $as_echo "$as_me: The path of BUILD_CC, which resolves as \"$new_path\", is invalid." >&6;} 44302 { $as_echo "$as_me:${as_lineno-$LINENO}: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&5 44303 $as_echo "$as_me: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&6;} 44304 as_fn_error $? "Cannot locate the the path of BUILD_CC" "$LINENO" 5 44305 fi 44306 else 44307 input_to_shortpath="$new_path" 44308 fi 44309 44310 # Call helper function which possibly converts this using DOS-style short mode. 44311 # If so, the updated path is stored in $new_path. 44312 new_path="$input_to_shortpath" 44313 44314 input_path="$input_to_shortpath" 44315 # Check if we need to convert this using DOS-style short mode. If the path 44316 # contains just simple characters, use it. Otherwise (spaces, weird characters), 44317 # take no chances and rewrite it. 44318 # Note: m4 eats our [], so we need to use [ and ] instead. 44319 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 44320 if test "x$has_forbidden_chars" != x; then 44321 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 44322 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 44323 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 44324 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 44325 # Going to short mode and back again did indeed matter. Since short mode is 44326 # case insensitive, let's make it lowercase to improve readability. 44327 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 44328 # Now convert it back to Unix-style (cygpath) 44329 input_path=`$CYGPATH -u "$shortmode_path"` 44330 new_path="$input_path" 44331 fi 44332 fi 44333 44334 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 44335 if test "x$test_cygdrive_prefix" = x; then 44336 # As a simple fix, exclude /usr/bin since it's not a real path. 44337 if test "x`$ECHO $input_to_shortpath | $GREP ^/usr/bin/`" = x; then 44338 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 44339 # a path prefixed by /cygdrive for fixpath to work. 44340 new_path="$CYGWIN_ROOT_PATH$input_path" 44341 fi 44342 fi 44343 44344 # remove trailing .exe if any 44345 new_path="${new_path/%.exe/}" 44346 44347 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 44348 44349 # First separate the path from the arguments. This will split at the first 44350 # space. 44351 complete="$BUILD_CC" 44352 path="${complete%% *}" 44353 tmp="$complete EOL" 44354 arguments="${tmp#* }" 44355 44356 # Input might be given as Windows format, start by converting to 44357 # unix format. 44358 new_path="$path" 44359 44360 windows_path="$new_path" 44361 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 44362 unix_path=`$CYGPATH -u "$windows_path"` 44363 new_path="$unix_path" 44364 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 44365 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 44366 new_path="$unix_path" 44367 fi 44368 44369 44370 # Now try to locate executable using which 44371 new_path=`$WHICH "$new_path" 2> /dev/null` 44372 44373 if test "x$new_path" = x; then 44374 # Oops. Which didn't find the executable. 44375 # The splitting of arguments from the executable at a space might have been incorrect, 44376 # since paths with space are more likely in Windows. Give it another try with the whole 44377 # argument. 44378 path="$complete" 44379 arguments="EOL" 44380 new_path="$path" 44381 44382 windows_path="$new_path" 44383 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 44384 unix_path=`$CYGPATH -u "$windows_path"` 44385 new_path="$unix_path" 44386 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 44387 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 44388 new_path="$unix_path" 44389 fi 44390 44391 44392 new_path=`$WHICH "$new_path" 2> /dev/null` 44393 # bat and cmd files are not always considered executable in MSYS causing which 44394 # to not find them 44395 if test "x$new_path" = x \ 44396 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 44397 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 44398 new_path="$path" 44399 44400 windows_path="$new_path" 44401 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 44402 unix_path=`$CYGPATH -u "$windows_path"` 44403 new_path="$unix_path" 44404 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 44405 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 44406 new_path="$unix_path" 44407 fi 44408 44409 fi 44410 44411 if test "x$new_path" = x; then 44412 # It's still not found. Now this is an unrecoverable error. 44413 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BUILD_CC, which resolves as \"$complete\", is not found." >&5 44414 $as_echo "$as_me: The path of BUILD_CC, which resolves as \"$complete\", is not found." >&6;} 44415 has_space=`$ECHO "$complete" | $GREP " "` 44416 if test "x$has_space" != x; then 44417 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 44418 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 44419 fi 44420 as_fn_error $? "Cannot locate the the path of BUILD_CC" "$LINENO" 5 44421 fi 44422 fi 44423 44424 # Now new_path has a complete unix path to the binary 44425 if test "x`$ECHO $new_path | $GREP ^/bin/`" != x; then 44426 # Keep paths in /bin as-is, but remove trailing .exe if any 44427 new_path="${new_path/%.exe/}" 44428 # Do not save /bin paths to all_fixpath_prefixes! 44429 else 44430 # Not in mixed or Windows style, start by that. 44431 new_path=`cmd //c echo $new_path` 44432 44433 input_path="$new_path" 44434 # Check if we need to convert this using DOS-style short mode. If the path 44435 # contains just simple characters, use it. Otherwise (spaces, weird characters), 44436 # take no chances and rewrite it. 44437 # Note: m4 eats our [], so we need to use [ and ] instead. 44438 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 44439 if test "x$has_forbidden_chars" != x; then 44440 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 44441 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 44442 fi 44443 44444 # Output is in $new_path 44445 44446 windows_path="$new_path" 44447 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 44448 unix_path=`$CYGPATH -u "$windows_path"` 44449 new_path="$unix_path" 44450 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 44451 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 44452 new_path="$unix_path" 44453 fi 44454 44455 # remove trailing .exe if any 44456 new_path="${new_path/%.exe/}" 44457 44458 # Save the first 10 bytes of this path to the storage, so fixpath can work. 44459 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 44460 fi 44461 44462 else 44463 # We're on a unix platform. Hooray! :) 44464 # First separate the path from the arguments. This will split at the first 44465 # space. 44466 complete="$BUILD_CC" 44467 path="${complete%% *}" 44468 tmp="$complete EOL" 44469 arguments="${tmp#* }" 44470 44471 # Cannot rely on the command "which" here since it doesn't always work. 44472 is_absolute_path=`$ECHO "$path" | $GREP ^/` 44473 if test -z "$is_absolute_path"; then 44474 # Path to executable is not absolute. Find it. 44475 IFS_save="$IFS" 44476 IFS=: 44477 for p in $PATH; do 44478 if test -f "$p/$path" && test -x "$p/$path"; then 44479 new_path="$p/$path" 44480 break 44481 fi 44482 done 44483 IFS="$IFS_save" 44484 else 44485 # This is an absolute path, we can use it without further modifications. 44486 new_path="$path" 44487 fi 44488 44489 if test "x$new_path" = x; then 44490 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BUILD_CC, which resolves as \"$complete\", is not found." >&5 44491 $as_echo "$as_me: The path of BUILD_CC, which resolves as \"$complete\", is not found." >&6;} 44492 has_space=`$ECHO "$complete" | $GREP " "` 44493 if test "x$has_space" != x; then 44494 { $as_echo "$as_me:${as_lineno-$LINENO}: This might be caused by spaces in the path, which is not allowed." >&5 44495 $as_echo "$as_me: This might be caused by spaces in the path, which is not allowed." >&6;} 44496 fi 44497 as_fn_error $? "Cannot locate the the path of BUILD_CC" "$LINENO" 5 44498 fi 44499 fi 44500 44501 # Now join together the path and the arguments once again 44502 if test "x$arguments" != xEOL; then 44503 new_complete="$new_path ${arguments% *}" 44504 else 44505 new_complete="$new_path" 44506 fi 44507 44508 if test "x$complete" != "x$new_complete"; then 44509 BUILD_CC="$new_complete" 44510 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BUILD_CC to \"$new_complete\"" >&5 44511 $as_echo "$as_me: Rewriting BUILD_CC to \"$new_complete\"" >&6;} 44512 fi 44513 fi 44514 44515 44516 44517 44518 # Publish this variable in the help. 44519 44520 44521 if [ -z "${BUILD_CXX+x}" ]; then 44522 # The variable is not set by user, try to locate tool using the code snippet 44523 for ac_prog in cl CC g++ 44524 do 44525 # Extract the first word of "$ac_prog", so it can be a program name with args. 44526 set dummy $ac_prog; ac_word=$2 44527 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 44528 $as_echo_n "checking for $ac_word... " >&6; } 44529 if ${ac_cv_path_BUILD_CXX+:} false; then : 44530 $as_echo_n "(cached) " >&6 44531 else 44532 case $BUILD_CXX in 44533 [\\/]* | ?:[\\/]*) 44534 ac_cv_path_BUILD_CXX="$BUILD_CXX" # Let the user override the test with a path. 44535 ;; 44536 *) 44537 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 44538 for as_dir in $PATH 44539 do 44540 IFS=$as_save_IFS 44541 test -z "$as_dir" && as_dir=. 44542 for ac_exec_ext in '' $ac_executable_extensions; do 44543 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 44544 ac_cv_path_BUILD_CXX="$as_dir/$ac_word$ac_exec_ext" 44545 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 44546 break 2 44547 fi 44548 done 44549 done 44550 IFS=$as_save_IFS 44551 44552 ;; 44553 esac 44554 fi 44555 BUILD_CXX=$ac_cv_path_BUILD_CXX 44556 if test -n "$BUILD_CXX"; then 44557 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BUILD_CXX" >&5 44558 $as_echo "$BUILD_CXX" >&6; } 44559 else 44560 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 44561 $as_echo "no" >&6; } 44562 fi 44563 44564 44565 test -n "$BUILD_CXX" && break 44566 done 44567 44568 else 44569 # The variable is set, but is it from the command line or the environment? 44570 44571 # Try to remove the string !BUILD_CXX! from our list. 44572 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!BUILD_CXX!/} 44573 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 44574 # If it failed, the variable was not from the command line. Ignore it, 44575 # but warn the user (except for BASH, which is always set by the calling BASH). 44576 if test "xBUILD_CXX" != xBASH; then 44577 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of BUILD_CXX from the environment. Use command line variables instead." >&5 44578 $as_echo "$as_me: WARNING: Ignoring value of BUILD_CXX from the environment. Use command line variables instead." >&2;} 44579 fi 44580 # Try to locate tool using the code snippet 44581 for ac_prog in cl CC g++ 44582 do 44583 # Extract the first word of "$ac_prog", so it can be a program name with args. 44584 set dummy $ac_prog; ac_word=$2 44585 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 44586 $as_echo_n "checking for $ac_word... " >&6; } 44587 if ${ac_cv_path_BUILD_CXX+:} false; then : 44588 $as_echo_n "(cached) " >&6 44589 else 44590 case $BUILD_CXX in 44591 [\\/]* | ?:[\\/]*) 44592 ac_cv_path_BUILD_CXX="$BUILD_CXX" # Let the user override the test with a path. 44593 ;; 44594 *) 44595 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 44596 for as_dir in $PATH 44597 do 44598 IFS=$as_save_IFS 44599 test -z "$as_dir" && as_dir=. 44600 for ac_exec_ext in '' $ac_executable_extensions; do 44601 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 44602 ac_cv_path_BUILD_CXX="$as_dir/$ac_word$ac_exec_ext" 44603 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 44604 break 2 44605 fi 44606 done 44607 done 44608 IFS=$as_save_IFS 44609 44610 ;; 44611 esac 44612 fi 44613 BUILD_CXX=$ac_cv_path_BUILD_CXX 44614 if test -n "$BUILD_CXX"; then 44615 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BUILD_CXX" >&5 44616 $as_echo "$BUILD_CXX" >&6; } 44617 else 44618 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 44619 $as_echo "no" >&6; } 44620 fi 44621 44622 44623 test -n "$BUILD_CXX" && break 44624 done 44625 44626 else 44627 # If it succeeded, then it was overridden by the user. We will use it 44628 # for the tool. 44629 44630 # First remove it from the list of overridden variables, so we can test 44631 # for unknown variables in the end. 44632 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 44633 44634 # Check if we try to supply an empty value 44635 if test "x$BUILD_CXX" = x; then 44636 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool BUILD_CXX= (no value)" >&5 44637 $as_echo "$as_me: Setting user supplied tool BUILD_CXX= (no value)" >&6;} 44638 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for BUILD_CXX" >&5 44639 $as_echo_n "checking for BUILD_CXX... " >&6; } 44640 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 44641 $as_echo "disabled" >&6; } 44642 else 44643 # Check if the provided tool contains a complete path. 44644 tool_specified="$BUILD_CXX" 44645 tool_basename="${tool_specified##*/}" 44646 if test "x$tool_basename" = "x$tool_specified"; then 44647 # A command without a complete path is provided, search $PATH. 44648 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool BUILD_CXX=$tool_basename" >&5 44649 $as_echo "$as_me: Will search for user supplied tool BUILD_CXX=$tool_basename" >&6;} 44650 # Extract the first word of "$tool_basename", so it can be a program name with args. 44651 set dummy $tool_basename; ac_word=$2 44652 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 44653 $as_echo_n "checking for $ac_word... " >&6; } 44654 if ${ac_cv_path_BUILD_CXX+:} false; then : 44655 $as_echo_n "(cached) " >&6 44656 else 44657 case $BUILD_CXX in 44658 [\\/]* | ?:[\\/]*) 44659 ac_cv_path_BUILD_CXX="$BUILD_CXX" # Let the user override the test with a path. 44660 ;; 44661 *) 44662 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 44663 for as_dir in $PATH 44664 do 44665 IFS=$as_save_IFS 44666 test -z "$as_dir" && as_dir=. 44667 for ac_exec_ext in '' $ac_executable_extensions; do 44668 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 44669 ac_cv_path_BUILD_CXX="$as_dir/$ac_word$ac_exec_ext" 44670 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 44671 break 2 44672 fi 44673 done 44674 done 44675 IFS=$as_save_IFS 44676 44677 ;; 44678 esac 44679 fi 44680 BUILD_CXX=$ac_cv_path_BUILD_CXX 44681 if test -n "$BUILD_CXX"; then 44682 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BUILD_CXX" >&5 44683 $as_echo "$BUILD_CXX" >&6; } 44684 else 44685 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 44686 $as_echo "no" >&6; } 44687 fi 44688 44689 44690 if test "x$BUILD_CXX" = x; then 44691 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 44692 fi 44693 else 44694 # Otherwise we believe it is a complete path. Use it as it is. 44695 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool BUILD_CXX=$tool_specified" >&5 44696 $as_echo "$as_me: Will use user supplied tool BUILD_CXX=$tool_specified" >&6;} 44697 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for BUILD_CXX" >&5 44698 $as_echo_n "checking for BUILD_CXX... " >&6; } 44699 if test ! -x "$tool_specified"; then 44700 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 44701 $as_echo "not found" >&6; } 44702 as_fn_error $? "User supplied tool BUILD_CXX=$tool_specified does not exist or is not executable" "$LINENO" 5 44703 fi 44704 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 44705 $as_echo "$tool_specified" >&6; } 44706 fi 44707 fi 44708 fi 44709 44710 fi 44711 44712 44713 44714 if test "x$BUILD_CXX" = x; then 44715 as_fn_error $? "Could not find required tool for BUILD_CXX" "$LINENO" 5 44716 fi 44717 44718 44719 44720 # Only process if variable expands to non-empty 44721 44722 if test "x$BUILD_CXX" != x; then 44723 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 44724 44725 # First separate the path from the arguments. This will split at the first 44726 # space. 44727 complete="$BUILD_CXX" 44728 path="${complete%% *}" 44729 tmp="$complete EOL" 44730 arguments="${tmp#* }" 44731 44732 # Input might be given as Windows format, start by converting to 44733 # unix format. 44734 new_path=`$CYGPATH -u "$path"` 44735 44736 # Now try to locate executable using which 44737 new_path=`$WHICH "$new_path" 2> /dev/null` 44738 # bat and cmd files are not always considered executable in cygwin causing which 44739 # to not find them 44740 if test "x$new_path" = x \ 44741 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 44742 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 44743 new_path=`$CYGPATH -u "$path"` 44744 fi 44745 if test "x$new_path" = x; then 44746 # Oops. Which didn't find the executable. 44747 # The splitting of arguments from the executable at a space might have been incorrect, 44748 # since paths with space are more likely in Windows. Give it another try with the whole 44749 # argument. 44750 path="$complete" 44751 arguments="EOL" 44752 new_path=`$CYGPATH -u "$path"` 44753 new_path=`$WHICH "$new_path" 2> /dev/null` 44754 # bat and cmd files are not always considered executable in cygwin causing which 44755 # to not find them 44756 if test "x$new_path" = x \ 44757 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 44758 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 44759 new_path=`$CYGPATH -u "$path"` 44760 fi 44761 if test "x$new_path" = x; then 44762 # It's still not found. Now this is an unrecoverable error. 44763 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BUILD_CXX, which resolves as \"$complete\", is not found." >&5 44764 $as_echo "$as_me: The path of BUILD_CXX, which resolves as \"$complete\", is not found." >&6;} 44765 has_space=`$ECHO "$complete" | $GREP " "` 44766 if test "x$has_space" != x; then 44767 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 44768 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 44769 fi 44770 as_fn_error $? "Cannot locate the the path of BUILD_CXX" "$LINENO" 5 44771 fi 44772 fi 44773 44774 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 44775 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 44776 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 44777 # "foo.exe" is OK but "foo" is an error. 44778 # 44779 # This test is therefore slightly more accurate than "test -f" to check for file presence. 44780 # It is also a way to make sure we got the proper file name for the real test later on. 44781 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 44782 if test "x$test_shortpath" = x; then 44783 # Short path failed, file does not exist as specified. 44784 # Try adding .exe or .cmd 44785 if test -f "${new_path}.exe"; then 44786 input_to_shortpath="${new_path}.exe" 44787 elif test -f "${new_path}.cmd"; then 44788 input_to_shortpath="${new_path}.cmd" 44789 else 44790 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BUILD_CXX, which resolves as \"$new_path\", is invalid." >&5 44791 $as_echo "$as_me: The path of BUILD_CXX, which resolves as \"$new_path\", is invalid." >&6;} 44792 { $as_echo "$as_me:${as_lineno-$LINENO}: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&5 44793 $as_echo "$as_me: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&6;} 44794 as_fn_error $? "Cannot locate the the path of BUILD_CXX" "$LINENO" 5 44795 fi 44796 else 44797 input_to_shortpath="$new_path" 44798 fi 44799 44800 # Call helper function which possibly converts this using DOS-style short mode. 44801 # If so, the updated path is stored in $new_path. 44802 new_path="$input_to_shortpath" 44803 44804 input_path="$input_to_shortpath" 44805 # Check if we need to convert this using DOS-style short mode. If the path 44806 # contains just simple characters, use it. Otherwise (spaces, weird characters), 44807 # take no chances and rewrite it. 44808 # Note: m4 eats our [], so we need to use [ and ] instead. 44809 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 44810 if test "x$has_forbidden_chars" != x; then 44811 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 44812 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 44813 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 44814 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 44815 # Going to short mode and back again did indeed matter. Since short mode is 44816 # case insensitive, let's make it lowercase to improve readability. 44817 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 44818 # Now convert it back to Unix-style (cygpath) 44819 input_path=`$CYGPATH -u "$shortmode_path"` 44820 new_path="$input_path" 44821 fi 44822 fi 44823 44824 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 44825 if test "x$test_cygdrive_prefix" = x; then 44826 # As a simple fix, exclude /usr/bin since it's not a real path. 44827 if test "x`$ECHO $input_to_shortpath | $GREP ^/usr/bin/`" = x; then 44828 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 44829 # a path prefixed by /cygdrive for fixpath to work. 44830 new_path="$CYGWIN_ROOT_PATH$input_path" 44831 fi 44832 fi 44833 44834 # remove trailing .exe if any 44835 new_path="${new_path/%.exe/}" 44836 44837 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 44838 44839 # First separate the path from the arguments. This will split at the first 44840 # space. 44841 complete="$BUILD_CXX" 44842 path="${complete%% *}" 44843 tmp="$complete EOL" 44844 arguments="${tmp#* }" 44845 44846 # Input might be given as Windows format, start by converting to 44847 # unix format. 44848 new_path="$path" 44849 44850 windows_path="$new_path" 44851 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 44852 unix_path=`$CYGPATH -u "$windows_path"` 44853 new_path="$unix_path" 44854 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 44855 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 44856 new_path="$unix_path" 44857 fi 44858 44859 44860 # Now try to locate executable using which 44861 new_path=`$WHICH "$new_path" 2> /dev/null` 44862 44863 if test "x$new_path" = x; then 44864 # Oops. Which didn't find the executable. 44865 # The splitting of arguments from the executable at a space might have been incorrect, 44866 # since paths with space are more likely in Windows. Give it another try with the whole 44867 # argument. 44868 path="$complete" 44869 arguments="EOL" 44870 new_path="$path" 44871 44872 windows_path="$new_path" 44873 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 44874 unix_path=`$CYGPATH -u "$windows_path"` 44875 new_path="$unix_path" 44876 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 44877 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 44878 new_path="$unix_path" 44879 fi 44880 44881 44882 new_path=`$WHICH "$new_path" 2> /dev/null` 44883 # bat and cmd files are not always considered executable in MSYS causing which 44884 # to not find them 44885 if test "x$new_path" = x \ 44886 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 44887 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 44888 new_path="$path" 44889 44890 windows_path="$new_path" 44891 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 44892 unix_path=`$CYGPATH -u "$windows_path"` 44893 new_path="$unix_path" 44894 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 44895 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 44896 new_path="$unix_path" 44897 fi 44898 44899 fi 44900 44901 if test "x$new_path" = x; then 44902 # It's still not found. Now this is an unrecoverable error. 44903 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BUILD_CXX, which resolves as \"$complete\", is not found." >&5 44904 $as_echo "$as_me: The path of BUILD_CXX, which resolves as \"$complete\", is not found." >&6;} 44905 has_space=`$ECHO "$complete" | $GREP " "` 44906 if test "x$has_space" != x; then 44907 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 44908 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 44909 fi 44910 as_fn_error $? "Cannot locate the the path of BUILD_CXX" "$LINENO" 5 44911 fi 44912 fi 44913 44914 # Now new_path has a complete unix path to the binary 44915 if test "x`$ECHO $new_path | $GREP ^/bin/`" != x; then 44916 # Keep paths in /bin as-is, but remove trailing .exe if any 44917 new_path="${new_path/%.exe/}" 44918 # Do not save /bin paths to all_fixpath_prefixes! 44919 else 44920 # Not in mixed or Windows style, start by that. 44921 new_path=`cmd //c echo $new_path` 44922 44923 input_path="$new_path" 44924 # Check if we need to convert this using DOS-style short mode. If the path 44925 # contains just simple characters, use it. Otherwise (spaces, weird characters), 44926 # take no chances and rewrite it. 44927 # Note: m4 eats our [], so we need to use [ and ] instead. 44928 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 44929 if test "x$has_forbidden_chars" != x; then 44930 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 44931 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 44932 fi 44933 44934 # Output is in $new_path 44935 44936 windows_path="$new_path" 44937 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 44938 unix_path=`$CYGPATH -u "$windows_path"` 44939 new_path="$unix_path" 44940 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 44941 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 44942 new_path="$unix_path" 44943 fi 44944 44945 # remove trailing .exe if any 44946 new_path="${new_path/%.exe/}" 44947 44948 # Save the first 10 bytes of this path to the storage, so fixpath can work. 44949 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 44950 fi 44951 44952 else 44953 # We're on a unix platform. Hooray! :) 44954 # First separate the path from the arguments. This will split at the first 44955 # space. 44956 complete="$BUILD_CXX" 44957 path="${complete%% *}" 44958 tmp="$complete EOL" 44959 arguments="${tmp#* }" 44960 44961 # Cannot rely on the command "which" here since it doesn't always work. 44962 is_absolute_path=`$ECHO "$path" | $GREP ^/` 44963 if test -z "$is_absolute_path"; then 44964 # Path to executable is not absolute. Find it. 44965 IFS_save="$IFS" 44966 IFS=: 44967 for p in $PATH; do 44968 if test -f "$p/$path" && test -x "$p/$path"; then 44969 new_path="$p/$path" 44970 break 44971 fi 44972 done 44973 IFS="$IFS_save" 44974 else 44975 # This is an absolute path, we can use it without further modifications. 44976 new_path="$path" 44977 fi 44978 44979 if test "x$new_path" = x; then 44980 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BUILD_CXX, which resolves as \"$complete\", is not found." >&5 44981 $as_echo "$as_me: The path of BUILD_CXX, which resolves as \"$complete\", is not found." >&6;} 44982 has_space=`$ECHO "$complete" | $GREP " "` 44983 if test "x$has_space" != x; then 44984 { $as_echo "$as_me:${as_lineno-$LINENO}: This might be caused by spaces in the path, which is not allowed." >&5 44985 $as_echo "$as_me: This might be caused by spaces in the path, which is not allowed." >&6;} 44986 fi 44987 as_fn_error $? "Cannot locate the the path of BUILD_CXX" "$LINENO" 5 44988 fi 44989 fi 44990 44991 # Now join together the path and the arguments once again 44992 if test "x$arguments" != xEOL; then 44993 new_complete="$new_path ${arguments% *}" 44994 else 44995 new_complete="$new_path" 44996 fi 44997 44998 if test "x$complete" != "x$new_complete"; then 44999 BUILD_CXX="$new_complete" 45000 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BUILD_CXX to \"$new_complete\"" >&5 45001 $as_echo "$as_me: Rewriting BUILD_CXX to \"$new_complete\"" >&6;} 45002 fi 45003 fi 45004 45005 45006 45007 # Publish this variable in the help. 45008 45009 45010 if [ -z "${BUILD_NM+x}" ]; then 45011 # The variable is not set by user, try to locate tool using the code snippet 45012 for ac_prog in nm gcc-nm 45013 do 45014 # Extract the first word of "$ac_prog", so it can be a program name with args. 45015 set dummy $ac_prog; ac_word=$2 45016 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 45017 $as_echo_n "checking for $ac_word... " >&6; } 45018 if ${ac_cv_path_BUILD_NM+:} false; then : 45019 $as_echo_n "(cached) " >&6 45020 else 45021 case $BUILD_NM in 45022 [\\/]* | ?:[\\/]*) 45023 ac_cv_path_BUILD_NM="$BUILD_NM" # Let the user override the test with a path. 45024 ;; 45025 *) 45026 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 45027 for as_dir in $PATH 45028 do 45029 IFS=$as_save_IFS 45030 test -z "$as_dir" && as_dir=. 45031 for ac_exec_ext in '' $ac_executable_extensions; do 45032 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 45033 ac_cv_path_BUILD_NM="$as_dir/$ac_word$ac_exec_ext" 45034 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 45035 break 2 45036 fi 45037 done 45038 done 45039 IFS=$as_save_IFS 45040 45041 ;; 45042 esac 45043 fi 45044 BUILD_NM=$ac_cv_path_BUILD_NM 45045 if test -n "$BUILD_NM"; then 45046 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BUILD_NM" >&5 45047 $as_echo "$BUILD_NM" >&6; } 45048 else 45049 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 45050 $as_echo "no" >&6; } 45051 fi 45052 45053 45054 test -n "$BUILD_NM" && break 45055 done 45056 45057 else 45058 # The variable is set, but is it from the command line or the environment? 45059 45060 # Try to remove the string !BUILD_NM! from our list. 45061 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!BUILD_NM!/} 45062 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 45063 # If it failed, the variable was not from the command line. Ignore it, 45064 # but warn the user (except for BASH, which is always set by the calling BASH). 45065 if test "xBUILD_NM" != xBASH; then 45066 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of BUILD_NM from the environment. Use command line variables instead." >&5 45067 $as_echo "$as_me: WARNING: Ignoring value of BUILD_NM from the environment. Use command line variables instead." >&2;} 45068 fi 45069 # Try to locate tool using the code snippet 45070 for ac_prog in nm gcc-nm 45071 do 45072 # Extract the first word of "$ac_prog", so it can be a program name with args. 45073 set dummy $ac_prog; ac_word=$2 45074 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 45075 $as_echo_n "checking for $ac_word... " >&6; } 45076 if ${ac_cv_path_BUILD_NM+:} false; then : 45077 $as_echo_n "(cached) " >&6 45078 else 45079 case $BUILD_NM in 45080 [\\/]* | ?:[\\/]*) 45081 ac_cv_path_BUILD_NM="$BUILD_NM" # Let the user override the test with a path. 45082 ;; 45083 *) 45084 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 45085 for as_dir in $PATH 45086 do 45087 IFS=$as_save_IFS 45088 test -z "$as_dir" && as_dir=. 45089 for ac_exec_ext in '' $ac_executable_extensions; do 45090 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 45091 ac_cv_path_BUILD_NM="$as_dir/$ac_word$ac_exec_ext" 45092 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 45093 break 2 45094 fi 45095 done 45096 done 45097 IFS=$as_save_IFS 45098 45099 ;; 45100 esac 45101 fi 45102 BUILD_NM=$ac_cv_path_BUILD_NM 45103 if test -n "$BUILD_NM"; then 45104 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BUILD_NM" >&5 45105 $as_echo "$BUILD_NM" >&6; } 45106 else 45107 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 45108 $as_echo "no" >&6; } 45109 fi 45110 45111 45112 test -n "$BUILD_NM" && break 45113 done 45114 45115 else 45116 # If it succeeded, then it was overridden by the user. We will use it 45117 # for the tool. 45118 45119 # First remove it from the list of overridden variables, so we can test 45120 # for unknown variables in the end. 45121 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 45122 45123 # Check if we try to supply an empty value 45124 if test "x$BUILD_NM" = x; then 45125 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool BUILD_NM= (no value)" >&5 45126 $as_echo "$as_me: Setting user supplied tool BUILD_NM= (no value)" >&6;} 45127 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for BUILD_NM" >&5 45128 $as_echo_n "checking for BUILD_NM... " >&6; } 45129 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 45130 $as_echo "disabled" >&6; } 45131 else 45132 # Check if the provided tool contains a complete path. 45133 tool_specified="$BUILD_NM" 45134 tool_basename="${tool_specified##*/}" 45135 if test "x$tool_basename" = "x$tool_specified"; then 45136 # A command without a complete path is provided, search $PATH. 45137 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool BUILD_NM=$tool_basename" >&5 45138 $as_echo "$as_me: Will search for user supplied tool BUILD_NM=$tool_basename" >&6;} 45139 # Extract the first word of "$tool_basename", so it can be a program name with args. 45140 set dummy $tool_basename; ac_word=$2 45141 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 45142 $as_echo_n "checking for $ac_word... " >&6; } 45143 if ${ac_cv_path_BUILD_NM+:} false; then : 45144 $as_echo_n "(cached) " >&6 45145 else 45146 case $BUILD_NM in 45147 [\\/]* | ?:[\\/]*) 45148 ac_cv_path_BUILD_NM="$BUILD_NM" # Let the user override the test with a path. 45149 ;; 45150 *) 45151 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 45152 for as_dir in $PATH 45153 do 45154 IFS=$as_save_IFS 45155 test -z "$as_dir" && as_dir=. 45156 for ac_exec_ext in '' $ac_executable_extensions; do 45157 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 45158 ac_cv_path_BUILD_NM="$as_dir/$ac_word$ac_exec_ext" 45159 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 45160 break 2 45161 fi 45162 done 45163 done 45164 IFS=$as_save_IFS 45165 45166 ;; 45167 esac 45168 fi 45169 BUILD_NM=$ac_cv_path_BUILD_NM 45170 if test -n "$BUILD_NM"; then 45171 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BUILD_NM" >&5 45172 $as_echo "$BUILD_NM" >&6; } 45173 else 45174 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 45175 $as_echo "no" >&6; } 45176 fi 45177 45178 45179 if test "x$BUILD_NM" = x; then 45180 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 45181 fi 45182 else 45183 # Otherwise we believe it is a complete path. Use it as it is. 45184 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool BUILD_NM=$tool_specified" >&5 45185 $as_echo "$as_me: Will use user supplied tool BUILD_NM=$tool_specified" >&6;} 45186 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for BUILD_NM" >&5 45187 $as_echo_n "checking for BUILD_NM... " >&6; } 45188 if test ! -x "$tool_specified"; then 45189 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 45190 $as_echo "not found" >&6; } 45191 as_fn_error $? "User supplied tool BUILD_NM=$tool_specified does not exist or is not executable" "$LINENO" 5 45192 fi 45193 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 45194 $as_echo "$tool_specified" >&6; } 45195 fi 45196 fi 45197 fi 45198 45199 fi 45200 45201 45202 45203 # Only process if variable expands to non-empty 45204 45205 if test "x$BUILD_NM" != x; then 45206 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 45207 45208 # First separate the path from the arguments. This will split at the first 45209 # space. 45210 complete="$BUILD_NM" 45211 path="${complete%% *}" 45212 tmp="$complete EOL" 45213 arguments="${tmp#* }" 45214 45215 # Input might be given as Windows format, start by converting to 45216 # unix format. 45217 new_path=`$CYGPATH -u "$path"` 45218 45219 # Now try to locate executable using which 45220 new_path=`$WHICH "$new_path" 2> /dev/null` 45221 # bat and cmd files are not always considered executable in cygwin causing which 45222 # to not find them 45223 if test "x$new_path" = x \ 45224 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 45225 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 45226 new_path=`$CYGPATH -u "$path"` 45227 fi 45228 if test "x$new_path" = x; then 45229 # Oops. Which didn't find the executable. 45230 # The splitting of arguments from the executable at a space might have been incorrect, 45231 # since paths with space are more likely in Windows. Give it another try with the whole 45232 # argument. 45233 path="$complete" 45234 arguments="EOL" 45235 new_path=`$CYGPATH -u "$path"` 45236 new_path=`$WHICH "$new_path" 2> /dev/null` 45237 # bat and cmd files are not always considered executable in cygwin causing which 45238 # to not find them 45239 if test "x$new_path" = x \ 45240 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 45241 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 45242 new_path=`$CYGPATH -u "$path"` 45243 fi 45244 if test "x$new_path" = x; then 45245 # It's still not found. Now this is an unrecoverable error. 45246 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BUILD_NM, which resolves as \"$complete\", is not found." >&5 45247 $as_echo "$as_me: The path of BUILD_NM, which resolves as \"$complete\", is not found." >&6;} 45248 has_space=`$ECHO "$complete" | $GREP " "` 45249 if test "x$has_space" != x; then 45250 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 45251 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 45252 fi 45253 as_fn_error $? "Cannot locate the the path of BUILD_NM" "$LINENO" 5 45254 fi 45255 fi 45256 45257 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 45258 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 45259 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 45260 # "foo.exe" is OK but "foo" is an error. 45261 # 45262 # This test is therefore slightly more accurate than "test -f" to check for file presence. 45263 # It is also a way to make sure we got the proper file name for the real test later on. 45264 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 45265 if test "x$test_shortpath" = x; then 45266 # Short path failed, file does not exist as specified. 45267 # Try adding .exe or .cmd 45268 if test -f "${new_path}.exe"; then 45269 input_to_shortpath="${new_path}.exe" 45270 elif test -f "${new_path}.cmd"; then 45271 input_to_shortpath="${new_path}.cmd" 45272 else 45273 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BUILD_NM, which resolves as \"$new_path\", is invalid." >&5 45274 $as_echo "$as_me: The path of BUILD_NM, which resolves as \"$new_path\", is invalid." >&6;} 45275 { $as_echo "$as_me:${as_lineno-$LINENO}: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&5 45276 $as_echo "$as_me: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&6;} 45277 as_fn_error $? "Cannot locate the the path of BUILD_NM" "$LINENO" 5 45278 fi 45279 else 45280 input_to_shortpath="$new_path" 45281 fi 45282 45283 # Call helper function which possibly converts this using DOS-style short mode. 45284 # If so, the updated path is stored in $new_path. 45285 new_path="$input_to_shortpath" 45286 45287 input_path="$input_to_shortpath" 45288 # Check if we need to convert this using DOS-style short mode. If the path 45289 # contains just simple characters, use it. Otherwise (spaces, weird characters), 45290 # take no chances and rewrite it. 45291 # Note: m4 eats our [], so we need to use [ and ] instead. 45292 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 45293 if test "x$has_forbidden_chars" != x; then 45294 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 45295 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 45296 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 45297 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 45298 # Going to short mode and back again did indeed matter. Since short mode is 45299 # case insensitive, let's make it lowercase to improve readability. 45300 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 45301 # Now convert it back to Unix-style (cygpath) 45302 input_path=`$CYGPATH -u "$shortmode_path"` 45303 new_path="$input_path" 45304 fi 45305 fi 45306 45307 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 45308 if test "x$test_cygdrive_prefix" = x; then 45309 # As a simple fix, exclude /usr/bin since it's not a real path. 45310 if test "x`$ECHO $input_to_shortpath | $GREP ^/usr/bin/`" = x; then 45311 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 45312 # a path prefixed by /cygdrive for fixpath to work. 45313 new_path="$CYGWIN_ROOT_PATH$input_path" 45314 fi 45315 fi 45316 45317 # remove trailing .exe if any 45318 new_path="${new_path/%.exe/}" 45319 45320 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 45321 45322 # First separate the path from the arguments. This will split at the first 45323 # space. 45324 complete="$BUILD_NM" 45325 path="${complete%% *}" 45326 tmp="$complete EOL" 45327 arguments="${tmp#* }" 45328 45329 # Input might be given as Windows format, start by converting to 45330 # unix format. 45331 new_path="$path" 45332 45333 windows_path="$new_path" 45334 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 45335 unix_path=`$CYGPATH -u "$windows_path"` 45336 new_path="$unix_path" 45337 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 45338 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 45339 new_path="$unix_path" 45340 fi 45341 45342 45343 # Now try to locate executable using which 45344 new_path=`$WHICH "$new_path" 2> /dev/null` 45345 45346 if test "x$new_path" = x; then 45347 # Oops. Which didn't find the executable. 45348 # The splitting of arguments from the executable at a space might have been incorrect, 45349 # since paths with space are more likely in Windows. Give it another try with the whole 45350 # argument. 45351 path="$complete" 45352 arguments="EOL" 45353 new_path="$path" 45354 45355 windows_path="$new_path" 45356 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 45357 unix_path=`$CYGPATH -u "$windows_path"` 45358 new_path="$unix_path" 45359 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 45360 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 45361 new_path="$unix_path" 45362 fi 45363 45364 45365 new_path=`$WHICH "$new_path" 2> /dev/null` 45366 # bat and cmd files are not always considered executable in MSYS causing which 45367 # to not find them 45368 if test "x$new_path" = x \ 45369 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 45370 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 45371 new_path="$path" 45372 45373 windows_path="$new_path" 45374 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 45375 unix_path=`$CYGPATH -u "$windows_path"` 45376 new_path="$unix_path" 45377 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 45378 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 45379 new_path="$unix_path" 45380 fi 45381 45382 fi 45383 45384 if test "x$new_path" = x; then 45385 # It's still not found. Now this is an unrecoverable error. 45386 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BUILD_NM, which resolves as \"$complete\", is not found." >&5 45387 $as_echo "$as_me: The path of BUILD_NM, which resolves as \"$complete\", is not found." >&6;} 45388 has_space=`$ECHO "$complete" | $GREP " "` 45389 if test "x$has_space" != x; then 45390 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 45391 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 45392 fi 45393 as_fn_error $? "Cannot locate the the path of BUILD_NM" "$LINENO" 5 45394 fi 45395 fi 45396 45397 # Now new_path has a complete unix path to the binary 45398 if test "x`$ECHO $new_path | $GREP ^/bin/`" != x; then 45399 # Keep paths in /bin as-is, but remove trailing .exe if any 45400 new_path="${new_path/%.exe/}" 45401 # Do not save /bin paths to all_fixpath_prefixes! 45402 else 45403 # Not in mixed or Windows style, start by that. 45404 new_path=`cmd //c echo $new_path` 45405 45406 input_path="$new_path" 45407 # Check if we need to convert this using DOS-style short mode. If the path 45408 # contains just simple characters, use it. Otherwise (spaces, weird characters), 45409 # take no chances and rewrite it. 45410 # Note: m4 eats our [], so we need to use [ and ] instead. 45411 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 45412 if test "x$has_forbidden_chars" != x; then 45413 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 45414 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 45415 fi 45416 45417 # Output is in $new_path 45418 45419 windows_path="$new_path" 45420 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 45421 unix_path=`$CYGPATH -u "$windows_path"` 45422 new_path="$unix_path" 45423 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 45424 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 45425 new_path="$unix_path" 45426 fi 45427 45428 # remove trailing .exe if any 45429 new_path="${new_path/%.exe/}" 45430 45431 # Save the first 10 bytes of this path to the storage, so fixpath can work. 45432 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 45433 fi 45434 45435 else 45436 # We're on a unix platform. Hooray! :) 45437 # First separate the path from the arguments. This will split at the first 45438 # space. 45439 complete="$BUILD_NM" 45440 path="${complete%% *}" 45441 tmp="$complete EOL" 45442 arguments="${tmp#* }" 45443 45444 # Cannot rely on the command "which" here since it doesn't always work. 45445 is_absolute_path=`$ECHO "$path" | $GREP ^/` 45446 if test -z "$is_absolute_path"; then 45447 # Path to executable is not absolute. Find it. 45448 IFS_save="$IFS" 45449 IFS=: 45450 for p in $PATH; do 45451 if test -f "$p/$path" && test -x "$p/$path"; then 45452 new_path="$p/$path" 45453 break 45454 fi 45455 done 45456 IFS="$IFS_save" 45457 else 45458 # This is an absolute path, we can use it without further modifications. 45459 new_path="$path" 45460 fi 45461 45462 if test "x$new_path" = x; then 45463 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BUILD_NM, which resolves as \"$complete\", is not found." >&5 45464 $as_echo "$as_me: The path of BUILD_NM, which resolves as \"$complete\", is not found." >&6;} 45465 has_space=`$ECHO "$complete" | $GREP " "` 45466 if test "x$has_space" != x; then 45467 { $as_echo "$as_me:${as_lineno-$LINENO}: This might be caused by spaces in the path, which is not allowed." >&5 45468 $as_echo "$as_me: This might be caused by spaces in the path, which is not allowed." >&6;} 45469 fi 45470 as_fn_error $? "Cannot locate the the path of BUILD_NM" "$LINENO" 5 45471 fi 45472 fi 45473 45474 # Now join together the path and the arguments once again 45475 if test "x$arguments" != xEOL; then 45476 new_complete="$new_path ${arguments% *}" 45477 else 45478 new_complete="$new_path" 45479 fi 45480 45481 if test "x$complete" != "x$new_complete"; then 45482 BUILD_NM="$new_complete" 45483 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BUILD_NM to \"$new_complete\"" >&5 45484 $as_echo "$as_me: Rewriting BUILD_NM to \"$new_complete\"" >&6;} 45485 fi 45486 fi 45487 45488 45489 45490 # Publish this variable in the help. 45491 45492 45493 if [ -z "${BUILD_AR+x}" ]; then 45494 # The variable is not set by user, try to locate tool using the code snippet 45495 for ac_prog in ar gcc-ar 45496 do 45497 # Extract the first word of "$ac_prog", so it can be a program name with args. 45498 set dummy $ac_prog; ac_word=$2 45499 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 45500 $as_echo_n "checking for $ac_word... " >&6; } 45501 if ${ac_cv_path_BUILD_AR+:} false; then : 45502 $as_echo_n "(cached) " >&6 45503 else 45504 case $BUILD_AR in 45505 [\\/]* | ?:[\\/]*) 45506 ac_cv_path_BUILD_AR="$BUILD_AR" # Let the user override the test with a path. 45507 ;; 45508 *) 45509 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 45510 for as_dir in $PATH 45511 do 45512 IFS=$as_save_IFS 45513 test -z "$as_dir" && as_dir=. 45514 for ac_exec_ext in '' $ac_executable_extensions; do 45515 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 45516 ac_cv_path_BUILD_AR="$as_dir/$ac_word$ac_exec_ext" 45517 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 45518 break 2 45519 fi 45520 done 45521 done 45522 IFS=$as_save_IFS 45523 45524 ;; 45525 esac 45526 fi 45527 BUILD_AR=$ac_cv_path_BUILD_AR 45528 if test -n "$BUILD_AR"; then 45529 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BUILD_AR" >&5 45530 $as_echo "$BUILD_AR" >&6; } 45531 else 45532 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 45533 $as_echo "no" >&6; } 45534 fi 45535 45536 45537 test -n "$BUILD_AR" && break 45538 done 45539 45540 else 45541 # The variable is set, but is it from the command line or the environment? 45542 45543 # Try to remove the string !BUILD_AR! from our list. 45544 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!BUILD_AR!/} 45545 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 45546 # If it failed, the variable was not from the command line. Ignore it, 45547 # but warn the user (except for BASH, which is always set by the calling BASH). 45548 if test "xBUILD_AR" != xBASH; then 45549 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of BUILD_AR from the environment. Use command line variables instead." >&5 45550 $as_echo "$as_me: WARNING: Ignoring value of BUILD_AR from the environment. Use command line variables instead." >&2;} 45551 fi 45552 # Try to locate tool using the code snippet 45553 for ac_prog in ar gcc-ar 45554 do 45555 # Extract the first word of "$ac_prog", so it can be a program name with args. 45556 set dummy $ac_prog; ac_word=$2 45557 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 45558 $as_echo_n "checking for $ac_word... " >&6; } 45559 if ${ac_cv_path_BUILD_AR+:} false; then : 45560 $as_echo_n "(cached) " >&6 45561 else 45562 case $BUILD_AR in 45563 [\\/]* | ?:[\\/]*) 45564 ac_cv_path_BUILD_AR="$BUILD_AR" # Let the user override the test with a path. 45565 ;; 45566 *) 45567 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 45568 for as_dir in $PATH 45569 do 45570 IFS=$as_save_IFS 45571 test -z "$as_dir" && as_dir=. 45572 for ac_exec_ext in '' $ac_executable_extensions; do 45573 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 45574 ac_cv_path_BUILD_AR="$as_dir/$ac_word$ac_exec_ext" 45575 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 45576 break 2 45577 fi 45578 done 45579 done 45580 IFS=$as_save_IFS 45581 45582 ;; 45583 esac 45584 fi 45585 BUILD_AR=$ac_cv_path_BUILD_AR 45586 if test -n "$BUILD_AR"; then 45587 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BUILD_AR" >&5 45588 $as_echo "$BUILD_AR" >&6; } 45589 else 45590 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 45591 $as_echo "no" >&6; } 45592 fi 45593 45594 45595 test -n "$BUILD_AR" && break 45596 done 45597 45598 else 45599 # If it succeeded, then it was overridden by the user. We will use it 45600 # for the tool. 45601 45602 # First remove it from the list of overridden variables, so we can test 45603 # for unknown variables in the end. 45604 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 45605 45606 # Check if we try to supply an empty value 45607 if test "x$BUILD_AR" = x; then 45608 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool BUILD_AR= (no value)" >&5 45609 $as_echo "$as_me: Setting user supplied tool BUILD_AR= (no value)" >&6;} 45610 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for BUILD_AR" >&5 45611 $as_echo_n "checking for BUILD_AR... " >&6; } 45612 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 45613 $as_echo "disabled" >&6; } 45614 else 45615 # Check if the provided tool contains a complete path. 45616 tool_specified="$BUILD_AR" 45617 tool_basename="${tool_specified##*/}" 45618 if test "x$tool_basename" = "x$tool_specified"; then 45619 # A command without a complete path is provided, search $PATH. 45620 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool BUILD_AR=$tool_basename" >&5 45621 $as_echo "$as_me: Will search for user supplied tool BUILD_AR=$tool_basename" >&6;} 45622 # Extract the first word of "$tool_basename", so it can be a program name with args. 45623 set dummy $tool_basename; ac_word=$2 45624 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 45625 $as_echo_n "checking for $ac_word... " >&6; } 45626 if ${ac_cv_path_BUILD_AR+:} false; then : 45627 $as_echo_n "(cached) " >&6 45628 else 45629 case $BUILD_AR in 45630 [\\/]* | ?:[\\/]*) 45631 ac_cv_path_BUILD_AR="$BUILD_AR" # Let the user override the test with a path. 45632 ;; 45633 *) 45634 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 45635 for as_dir in $PATH 45636 do 45637 IFS=$as_save_IFS 45638 test -z "$as_dir" && as_dir=. 45639 for ac_exec_ext in '' $ac_executable_extensions; do 45640 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 45641 ac_cv_path_BUILD_AR="$as_dir/$ac_word$ac_exec_ext" 45642 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 45643 break 2 45644 fi 45645 done 45646 done 45647 IFS=$as_save_IFS 45648 45649 ;; 45650 esac 45651 fi 45652 BUILD_AR=$ac_cv_path_BUILD_AR 45653 if test -n "$BUILD_AR"; then 45654 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BUILD_AR" >&5 45655 $as_echo "$BUILD_AR" >&6; } 45656 else 45657 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 45658 $as_echo "no" >&6; } 45659 fi 45660 45661 45662 if test "x$BUILD_AR" = x; then 45663 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 45664 fi 45665 else 45666 # Otherwise we believe it is a complete path. Use it as it is. 45667 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool BUILD_AR=$tool_specified" >&5 45668 $as_echo "$as_me: Will use user supplied tool BUILD_AR=$tool_specified" >&6;} 45669 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for BUILD_AR" >&5 45670 $as_echo_n "checking for BUILD_AR... " >&6; } 45671 if test ! -x "$tool_specified"; then 45672 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 45673 $as_echo "not found" >&6; } 45674 as_fn_error $? "User supplied tool BUILD_AR=$tool_specified does not exist or is not executable" "$LINENO" 5 45675 fi 45676 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 45677 $as_echo "$tool_specified" >&6; } 45678 fi 45679 fi 45680 fi 45681 45682 fi 45683 45684 45685 45686 # Only process if variable expands to non-empty 45687 45688 if test "x$BUILD_AR" != x; then 45689 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 45690 45691 # First separate the path from the arguments. This will split at the first 45692 # space. 45693 complete="$BUILD_AR" 45694 path="${complete%% *}" 45695 tmp="$complete EOL" 45696 arguments="${tmp#* }" 45697 45698 # Input might be given as Windows format, start by converting to 45699 # unix format. 45700 new_path=`$CYGPATH -u "$path"` 45701 45702 # Now try to locate executable using which 45703 new_path=`$WHICH "$new_path" 2> /dev/null` 45704 # bat and cmd files are not always considered executable in cygwin causing which 45705 # to not find them 45706 if test "x$new_path" = x \ 45707 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 45708 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 45709 new_path=`$CYGPATH -u "$path"` 45710 fi 45711 if test "x$new_path" = x; then 45712 # Oops. Which didn't find the executable. 45713 # The splitting of arguments from the executable at a space might have been incorrect, 45714 # since paths with space are more likely in Windows. Give it another try with the whole 45715 # argument. 45716 path="$complete" 45717 arguments="EOL" 45718 new_path=`$CYGPATH -u "$path"` 45719 new_path=`$WHICH "$new_path" 2> /dev/null` 45720 # bat and cmd files are not always considered executable in cygwin causing which 45721 # to not find them 45722 if test "x$new_path" = x \ 45723 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 45724 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 45725 new_path=`$CYGPATH -u "$path"` 45726 fi 45727 if test "x$new_path" = x; then 45728 # It's still not found. Now this is an unrecoverable error. 45729 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BUILD_AR, which resolves as \"$complete\", is not found." >&5 45730 $as_echo "$as_me: The path of BUILD_AR, which resolves as \"$complete\", is not found." >&6;} 45731 has_space=`$ECHO "$complete" | $GREP " "` 45732 if test "x$has_space" != x; then 45733 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 45734 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 45735 fi 45736 as_fn_error $? "Cannot locate the the path of BUILD_AR" "$LINENO" 5 45737 fi 45738 fi 45739 45740 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 45741 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 45742 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 45743 # "foo.exe" is OK but "foo" is an error. 45744 # 45745 # This test is therefore slightly more accurate than "test -f" to check for file presence. 45746 # It is also a way to make sure we got the proper file name for the real test later on. 45747 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 45748 if test "x$test_shortpath" = x; then 45749 # Short path failed, file does not exist as specified. 45750 # Try adding .exe or .cmd 45751 if test -f "${new_path}.exe"; then 45752 input_to_shortpath="${new_path}.exe" 45753 elif test -f "${new_path}.cmd"; then 45754 input_to_shortpath="${new_path}.cmd" 45755 else 45756 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BUILD_AR, which resolves as \"$new_path\", is invalid." >&5 45757 $as_echo "$as_me: The path of BUILD_AR, which resolves as \"$new_path\", is invalid." >&6;} 45758 { $as_echo "$as_me:${as_lineno-$LINENO}: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&5 45759 $as_echo "$as_me: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&6;} 45760 as_fn_error $? "Cannot locate the the path of BUILD_AR" "$LINENO" 5 45761 fi 45762 else 45763 input_to_shortpath="$new_path" 45764 fi 45765 45766 # Call helper function which possibly converts this using DOS-style short mode. 45767 # If so, the updated path is stored in $new_path. 45768 new_path="$input_to_shortpath" 45769 45770 input_path="$input_to_shortpath" 45771 # Check if we need to convert this using DOS-style short mode. If the path 45772 # contains just simple characters, use it. Otherwise (spaces, weird characters), 45773 # take no chances and rewrite it. 45774 # Note: m4 eats our [], so we need to use [ and ] instead. 45775 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 45776 if test "x$has_forbidden_chars" != x; then 45777 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 45778 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 45779 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 45780 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 45781 # Going to short mode and back again did indeed matter. Since short mode is 45782 # case insensitive, let's make it lowercase to improve readability. 45783 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 45784 # Now convert it back to Unix-style (cygpath) 45785 input_path=`$CYGPATH -u "$shortmode_path"` 45786 new_path="$input_path" 45787 fi 45788 fi 45789 45790 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 45791 if test "x$test_cygdrive_prefix" = x; then 45792 # As a simple fix, exclude /usr/bin since it's not a real path. 45793 if test "x`$ECHO $input_to_shortpath | $GREP ^/usr/bin/`" = x; then 45794 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 45795 # a path prefixed by /cygdrive for fixpath to work. 45796 new_path="$CYGWIN_ROOT_PATH$input_path" 45797 fi 45798 fi 45799 45800 # remove trailing .exe if any 45801 new_path="${new_path/%.exe/}" 45802 45803 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 45804 45805 # First separate the path from the arguments. This will split at the first 45806 # space. 45807 complete="$BUILD_AR" 45808 path="${complete%% *}" 45809 tmp="$complete EOL" 45810 arguments="${tmp#* }" 45811 45812 # Input might be given as Windows format, start by converting to 45813 # unix format. 45814 new_path="$path" 45815 45816 windows_path="$new_path" 45817 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 45818 unix_path=`$CYGPATH -u "$windows_path"` 45819 new_path="$unix_path" 45820 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 45821 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 45822 new_path="$unix_path" 45823 fi 45824 45825 45826 # Now try to locate executable using which 45827 new_path=`$WHICH "$new_path" 2> /dev/null` 45828 45829 if test "x$new_path" = x; then 45830 # Oops. Which didn't find the executable. 45831 # The splitting of arguments from the executable at a space might have been incorrect, 45832 # since paths with space are more likely in Windows. Give it another try with the whole 45833 # argument. 45834 path="$complete" 45835 arguments="EOL" 45836 new_path="$path" 45837 45838 windows_path="$new_path" 45839 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 45840 unix_path=`$CYGPATH -u "$windows_path"` 45841 new_path="$unix_path" 45842 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 45843 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 45844 new_path="$unix_path" 45845 fi 45846 45847 45848 new_path=`$WHICH "$new_path" 2> /dev/null` 45849 # bat and cmd files are not always considered executable in MSYS causing which 45850 # to not find them 45851 if test "x$new_path" = x \ 45852 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 45853 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 45854 new_path="$path" 45855 45856 windows_path="$new_path" 45857 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 45858 unix_path=`$CYGPATH -u "$windows_path"` 45859 new_path="$unix_path" 45860 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 45861 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 45862 new_path="$unix_path" 45863 fi 45864 45865 fi 45866 45867 if test "x$new_path" = x; then 45868 # It's still not found. Now this is an unrecoverable error. 45869 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BUILD_AR, which resolves as \"$complete\", is not found." >&5 45870 $as_echo "$as_me: The path of BUILD_AR, which resolves as \"$complete\", is not found." >&6;} 45871 has_space=`$ECHO "$complete" | $GREP " "` 45872 if test "x$has_space" != x; then 45873 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 45874 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 45875 fi 45876 as_fn_error $? "Cannot locate the the path of BUILD_AR" "$LINENO" 5 45877 fi 45878 fi 45879 45880 # Now new_path has a complete unix path to the binary 45881 if test "x`$ECHO $new_path | $GREP ^/bin/`" != x; then 45882 # Keep paths in /bin as-is, but remove trailing .exe if any 45883 new_path="${new_path/%.exe/}" 45884 # Do not save /bin paths to all_fixpath_prefixes! 45885 else 45886 # Not in mixed or Windows style, start by that. 45887 new_path=`cmd //c echo $new_path` 45888 45889 input_path="$new_path" 45890 # Check if we need to convert this using DOS-style short mode. If the path 45891 # contains just simple characters, use it. Otherwise (spaces, weird characters), 45892 # take no chances and rewrite it. 45893 # Note: m4 eats our [], so we need to use [ and ] instead. 45894 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 45895 if test "x$has_forbidden_chars" != x; then 45896 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 45897 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 45898 fi 45899 45900 # Output is in $new_path 45901 45902 windows_path="$new_path" 45903 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 45904 unix_path=`$CYGPATH -u "$windows_path"` 45905 new_path="$unix_path" 45906 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 45907 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 45908 new_path="$unix_path" 45909 fi 45910 45911 # remove trailing .exe if any 45912 new_path="${new_path/%.exe/}" 45913 45914 # Save the first 10 bytes of this path to the storage, so fixpath can work. 45915 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 45916 fi 45917 45918 else 45919 # We're on a unix platform. Hooray! :) 45920 # First separate the path from the arguments. This will split at the first 45921 # space. 45922 complete="$BUILD_AR" 45923 path="${complete%% *}" 45924 tmp="$complete EOL" 45925 arguments="${tmp#* }" 45926 45927 # Cannot rely on the command "which" here since it doesn't always work. 45928 is_absolute_path=`$ECHO "$path" | $GREP ^/` 45929 if test -z "$is_absolute_path"; then 45930 # Path to executable is not absolute. Find it. 45931 IFS_save="$IFS" 45932 IFS=: 45933 for p in $PATH; do 45934 if test -f "$p/$path" && test -x "$p/$path"; then 45935 new_path="$p/$path" 45936 break 45937 fi 45938 done 45939 IFS="$IFS_save" 45940 else 45941 # This is an absolute path, we can use it without further modifications. 45942 new_path="$path" 45943 fi 45944 45945 if test "x$new_path" = x; then 45946 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BUILD_AR, which resolves as \"$complete\", is not found." >&5 45947 $as_echo "$as_me: The path of BUILD_AR, which resolves as \"$complete\", is not found." >&6;} 45948 has_space=`$ECHO "$complete" | $GREP " "` 45949 if test "x$has_space" != x; then 45950 { $as_echo "$as_me:${as_lineno-$LINENO}: This might be caused by spaces in the path, which is not allowed." >&5 45951 $as_echo "$as_me: This might be caused by spaces in the path, which is not allowed." >&6;} 45952 fi 45953 as_fn_error $? "Cannot locate the the path of BUILD_AR" "$LINENO" 5 45954 fi 45955 fi 45956 45957 # Now join together the path and the arguments once again 45958 if test "x$arguments" != xEOL; then 45959 new_complete="$new_path ${arguments% *}" 45960 else 45961 new_complete="$new_path" 45962 fi 45963 45964 if test "x$complete" != "x$new_complete"; then 45965 BUILD_AR="$new_complete" 45966 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BUILD_AR to \"$new_complete\"" >&5 45967 $as_echo "$as_me: Rewriting BUILD_AR to \"$new_complete\"" >&6;} 45968 fi 45969 fi 45970 45971 45972 45973 # Publish this variable in the help. 45974 45975 45976 if [ -z "${BUILD_OBJCOPY+x}" ]; then 45977 # The variable is not set by user, try to locate tool using the code snippet 45978 for ac_prog in objcopy 45979 do 45980 # Extract the first word of "$ac_prog", so it can be a program name with args. 45981 set dummy $ac_prog; ac_word=$2 45982 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 45983 $as_echo_n "checking for $ac_word... " >&6; } 45984 if ${ac_cv_path_BUILD_OBJCOPY+:} false; then : 45985 $as_echo_n "(cached) " >&6 45986 else 45987 case $BUILD_OBJCOPY in 45988 [\\/]* | ?:[\\/]*) 45989 ac_cv_path_BUILD_OBJCOPY="$BUILD_OBJCOPY" # Let the user override the test with a path. 45990 ;; 45991 *) 45992 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 45993 for as_dir in $PATH 45994 do 45995 IFS=$as_save_IFS 45996 test -z "$as_dir" && as_dir=. 45997 for ac_exec_ext in '' $ac_executable_extensions; do 45998 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 45999 ac_cv_path_BUILD_OBJCOPY="$as_dir/$ac_word$ac_exec_ext" 46000 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 46001 break 2 46002 fi 46003 done 46004 done 46005 IFS=$as_save_IFS 46006 46007 ;; 46008 esac 46009 fi 46010 BUILD_OBJCOPY=$ac_cv_path_BUILD_OBJCOPY 46011 if test -n "$BUILD_OBJCOPY"; then 46012 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BUILD_OBJCOPY" >&5 46013 $as_echo "$BUILD_OBJCOPY" >&6; } 46014 else 46015 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 46016 $as_echo "no" >&6; } 46017 fi 46018 46019 46020 test -n "$BUILD_OBJCOPY" && break 46021 done 46022 46023 else 46024 # The variable is set, but is it from the command line or the environment? 46025 46026 # Try to remove the string !BUILD_OBJCOPY! from our list. 46027 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!BUILD_OBJCOPY!/} 46028 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 46029 # If it failed, the variable was not from the command line. Ignore it, 46030 # but warn the user (except for BASH, which is always set by the calling BASH). 46031 if test "xBUILD_OBJCOPY" != xBASH; then 46032 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of BUILD_OBJCOPY from the environment. Use command line variables instead." >&5 46033 $as_echo "$as_me: WARNING: Ignoring value of BUILD_OBJCOPY from the environment. Use command line variables instead." >&2;} 46034 fi 46035 # Try to locate tool using the code snippet 46036 for ac_prog in objcopy 46037 do 46038 # Extract the first word of "$ac_prog", so it can be a program name with args. 46039 set dummy $ac_prog; ac_word=$2 46040 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 46041 $as_echo_n "checking for $ac_word... " >&6; } 46042 if ${ac_cv_path_BUILD_OBJCOPY+:} false; then : 46043 $as_echo_n "(cached) " >&6 46044 else 46045 case $BUILD_OBJCOPY in 46046 [\\/]* | ?:[\\/]*) 46047 ac_cv_path_BUILD_OBJCOPY="$BUILD_OBJCOPY" # Let the user override the test with a path. 46048 ;; 46049 *) 46050 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 46051 for as_dir in $PATH 46052 do 46053 IFS=$as_save_IFS 46054 test -z "$as_dir" && as_dir=. 46055 for ac_exec_ext in '' $ac_executable_extensions; do 46056 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 46057 ac_cv_path_BUILD_OBJCOPY="$as_dir/$ac_word$ac_exec_ext" 46058 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 46059 break 2 46060 fi 46061 done 46062 done 46063 IFS=$as_save_IFS 46064 46065 ;; 46066 esac 46067 fi 46068 BUILD_OBJCOPY=$ac_cv_path_BUILD_OBJCOPY 46069 if test -n "$BUILD_OBJCOPY"; then 46070 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BUILD_OBJCOPY" >&5 46071 $as_echo "$BUILD_OBJCOPY" >&6; } 46072 else 46073 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 46074 $as_echo "no" >&6; } 46075 fi 46076 46077 46078 test -n "$BUILD_OBJCOPY" && break 46079 done 46080 46081 else 46082 # If it succeeded, then it was overridden by the user. We will use it 46083 # for the tool. 46084 46085 # First remove it from the list of overridden variables, so we can test 46086 # for unknown variables in the end. 46087 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 46088 46089 # Check if we try to supply an empty value 46090 if test "x$BUILD_OBJCOPY" = x; then 46091 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool BUILD_OBJCOPY= (no value)" >&5 46092 $as_echo "$as_me: Setting user supplied tool BUILD_OBJCOPY= (no value)" >&6;} 46093 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for BUILD_OBJCOPY" >&5 46094 $as_echo_n "checking for BUILD_OBJCOPY... " >&6; } 46095 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 46096 $as_echo "disabled" >&6; } 46097 else 46098 # Check if the provided tool contains a complete path. 46099 tool_specified="$BUILD_OBJCOPY" 46100 tool_basename="${tool_specified##*/}" 46101 if test "x$tool_basename" = "x$tool_specified"; then 46102 # A command without a complete path is provided, search $PATH. 46103 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool BUILD_OBJCOPY=$tool_basename" >&5 46104 $as_echo "$as_me: Will search for user supplied tool BUILD_OBJCOPY=$tool_basename" >&6;} 46105 # Extract the first word of "$tool_basename", so it can be a program name with args. 46106 set dummy $tool_basename; ac_word=$2 46107 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 46108 $as_echo_n "checking for $ac_word... " >&6; } 46109 if ${ac_cv_path_BUILD_OBJCOPY+:} false; then : 46110 $as_echo_n "(cached) " >&6 46111 else 46112 case $BUILD_OBJCOPY in 46113 [\\/]* | ?:[\\/]*) 46114 ac_cv_path_BUILD_OBJCOPY="$BUILD_OBJCOPY" # Let the user override the test with a path. 46115 ;; 46116 *) 46117 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 46118 for as_dir in $PATH 46119 do 46120 IFS=$as_save_IFS 46121 test -z "$as_dir" && as_dir=. 46122 for ac_exec_ext in '' $ac_executable_extensions; do 46123 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 46124 ac_cv_path_BUILD_OBJCOPY="$as_dir/$ac_word$ac_exec_ext" 46125 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 46126 break 2 46127 fi 46128 done 46129 done 46130 IFS=$as_save_IFS 46131 46132 ;; 46133 esac 46134 fi 46135 BUILD_OBJCOPY=$ac_cv_path_BUILD_OBJCOPY 46136 if test -n "$BUILD_OBJCOPY"; then 46137 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BUILD_OBJCOPY" >&5 46138 $as_echo "$BUILD_OBJCOPY" >&6; } 46139 else 46140 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 46141 $as_echo "no" >&6; } 46142 fi 46143 46144 46145 if test "x$BUILD_OBJCOPY" = x; then 46146 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 46147 fi 46148 else 46149 # Otherwise we believe it is a complete path. Use it as it is. 46150 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool BUILD_OBJCOPY=$tool_specified" >&5 46151 $as_echo "$as_me: Will use user supplied tool BUILD_OBJCOPY=$tool_specified" >&6;} 46152 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for BUILD_OBJCOPY" >&5 46153 $as_echo_n "checking for BUILD_OBJCOPY... " >&6; } 46154 if test ! -x "$tool_specified"; then 46155 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 46156 $as_echo "not found" >&6; } 46157 as_fn_error $? "User supplied tool BUILD_OBJCOPY=$tool_specified does not exist or is not executable" "$LINENO" 5 46158 fi 46159 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 46160 $as_echo "$tool_specified" >&6; } 46161 fi 46162 fi 46163 fi 46164 46165 fi 46166 46167 46168 46169 # Only process if variable expands to non-empty 46170 46171 if test "x$BUILD_OBJCOPY" != x; then 46172 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 46173 46174 # First separate the path from the arguments. This will split at the first 46175 # space. 46176 complete="$BUILD_OBJCOPY" 46177 path="${complete%% *}" 46178 tmp="$complete EOL" 46179 arguments="${tmp#* }" 46180 46181 # Input might be given as Windows format, start by converting to 46182 # unix format. 46183 new_path=`$CYGPATH -u "$path"` 46184 46185 # Now try to locate executable using which 46186 new_path=`$WHICH "$new_path" 2> /dev/null` 46187 # bat and cmd files are not always considered executable in cygwin causing which 46188 # to not find them 46189 if test "x$new_path" = x \ 46190 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 46191 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 46192 new_path=`$CYGPATH -u "$path"` 46193 fi 46194 if test "x$new_path" = x; then 46195 # Oops. Which didn't find the executable. 46196 # The splitting of arguments from the executable at a space might have been incorrect, 46197 # since paths with space are more likely in Windows. Give it another try with the whole 46198 # argument. 46199 path="$complete" 46200 arguments="EOL" 46201 new_path=`$CYGPATH -u "$path"` 46202 new_path=`$WHICH "$new_path" 2> /dev/null` 46203 # bat and cmd files are not always considered executable in cygwin causing which 46204 # to not find them 46205 if test "x$new_path" = x \ 46206 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 46207 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 46208 new_path=`$CYGPATH -u "$path"` 46209 fi 46210 if test "x$new_path" = x; then 46211 # It's still not found. Now this is an unrecoverable error. 46212 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BUILD_OBJCOPY, which resolves as \"$complete\", is not found." >&5 46213 $as_echo "$as_me: The path of BUILD_OBJCOPY, which resolves as \"$complete\", is not found." >&6;} 46214 has_space=`$ECHO "$complete" | $GREP " "` 46215 if test "x$has_space" != x; then 46216 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 46217 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 46218 fi 46219 as_fn_error $? "Cannot locate the the path of BUILD_OBJCOPY" "$LINENO" 5 46220 fi 46221 fi 46222 46223 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 46224 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 46225 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 46226 # "foo.exe" is OK but "foo" is an error. 46227 # 46228 # This test is therefore slightly more accurate than "test -f" to check for file presence. 46229 # It is also a way to make sure we got the proper file name for the real test later on. 46230 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 46231 if test "x$test_shortpath" = x; then 46232 # Short path failed, file does not exist as specified. 46233 # Try adding .exe or .cmd 46234 if test -f "${new_path}.exe"; then 46235 input_to_shortpath="${new_path}.exe" 46236 elif test -f "${new_path}.cmd"; then 46237 input_to_shortpath="${new_path}.cmd" 46238 else 46239 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BUILD_OBJCOPY, which resolves as \"$new_path\", is invalid." >&5 46240 $as_echo "$as_me: The path of BUILD_OBJCOPY, which resolves as \"$new_path\", is invalid." >&6;} 46241 { $as_echo "$as_me:${as_lineno-$LINENO}: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&5 46242 $as_echo "$as_me: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&6;} 46243 as_fn_error $? "Cannot locate the the path of BUILD_OBJCOPY" "$LINENO" 5 46244 fi 46245 else 46246 input_to_shortpath="$new_path" 46247 fi 46248 46249 # Call helper function which possibly converts this using DOS-style short mode. 46250 # If so, the updated path is stored in $new_path. 46251 new_path="$input_to_shortpath" 46252 46253 input_path="$input_to_shortpath" 46254 # Check if we need to convert this using DOS-style short mode. If the path 46255 # contains just simple characters, use it. Otherwise (spaces, weird characters), 46256 # take no chances and rewrite it. 46257 # Note: m4 eats our [], so we need to use [ and ] instead. 46258 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 46259 if test "x$has_forbidden_chars" != x; then 46260 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 46261 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 46262 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 46263 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 46264 # Going to short mode and back again did indeed matter. Since short mode is 46265 # case insensitive, let's make it lowercase to improve readability. 46266 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 46267 # Now convert it back to Unix-style (cygpath) 46268 input_path=`$CYGPATH -u "$shortmode_path"` 46269 new_path="$input_path" 46270 fi 46271 fi 46272 46273 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 46274 if test "x$test_cygdrive_prefix" = x; then 46275 # As a simple fix, exclude /usr/bin since it's not a real path. 46276 if test "x`$ECHO $input_to_shortpath | $GREP ^/usr/bin/`" = x; then 46277 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 46278 # a path prefixed by /cygdrive for fixpath to work. 46279 new_path="$CYGWIN_ROOT_PATH$input_path" 46280 fi 46281 fi 46282 46283 # remove trailing .exe if any 46284 new_path="${new_path/%.exe/}" 46285 46286 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 46287 46288 # First separate the path from the arguments. This will split at the first 46289 # space. 46290 complete="$BUILD_OBJCOPY" 46291 path="${complete%% *}" 46292 tmp="$complete EOL" 46293 arguments="${tmp#* }" 46294 46295 # Input might be given as Windows format, start by converting to 46296 # unix format. 46297 new_path="$path" 46298 46299 windows_path="$new_path" 46300 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 46301 unix_path=`$CYGPATH -u "$windows_path"` 46302 new_path="$unix_path" 46303 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 46304 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 46305 new_path="$unix_path" 46306 fi 46307 46308 46309 # Now try to locate executable using which 46310 new_path=`$WHICH "$new_path" 2> /dev/null` 46311 46312 if test "x$new_path" = x; then 46313 # Oops. Which didn't find the executable. 46314 # The splitting of arguments from the executable at a space might have been incorrect, 46315 # since paths with space are more likely in Windows. Give it another try with the whole 46316 # argument. 46317 path="$complete" 46318 arguments="EOL" 46319 new_path="$path" 46320 46321 windows_path="$new_path" 46322 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 46323 unix_path=`$CYGPATH -u "$windows_path"` 46324 new_path="$unix_path" 46325 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 46326 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 46327 new_path="$unix_path" 46328 fi 46329 46330 46331 new_path=`$WHICH "$new_path" 2> /dev/null` 46332 # bat and cmd files are not always considered executable in MSYS causing which 46333 # to not find them 46334 if test "x$new_path" = x \ 46335 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 46336 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 46337 new_path="$path" 46338 46339 windows_path="$new_path" 46340 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 46341 unix_path=`$CYGPATH -u "$windows_path"` 46342 new_path="$unix_path" 46343 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 46344 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 46345 new_path="$unix_path" 46346 fi 46347 46348 fi 46349 46350 if test "x$new_path" = x; then 46351 # It's still not found. Now this is an unrecoverable error. 46352 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BUILD_OBJCOPY, which resolves as \"$complete\", is not found." >&5 46353 $as_echo "$as_me: The path of BUILD_OBJCOPY, which resolves as \"$complete\", is not found." >&6;} 46354 has_space=`$ECHO "$complete" | $GREP " "` 46355 if test "x$has_space" != x; then 46356 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 46357 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 46358 fi 46359 as_fn_error $? "Cannot locate the the path of BUILD_OBJCOPY" "$LINENO" 5 46360 fi 46361 fi 46362 46363 # Now new_path has a complete unix path to the binary 46364 if test "x`$ECHO $new_path | $GREP ^/bin/`" != x; then 46365 # Keep paths in /bin as-is, but remove trailing .exe if any 46366 new_path="${new_path/%.exe/}" 46367 # Do not save /bin paths to all_fixpath_prefixes! 46368 else 46369 # Not in mixed or Windows style, start by that. 46370 new_path=`cmd //c echo $new_path` 46371 46372 input_path="$new_path" 46373 # Check if we need to convert this using DOS-style short mode. If the path 46374 # contains just simple characters, use it. Otherwise (spaces, weird characters), 46375 # take no chances and rewrite it. 46376 # Note: m4 eats our [], so we need to use [ and ] instead. 46377 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 46378 if test "x$has_forbidden_chars" != x; then 46379 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 46380 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 46381 fi 46382 46383 # Output is in $new_path 46384 46385 windows_path="$new_path" 46386 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 46387 unix_path=`$CYGPATH -u "$windows_path"` 46388 new_path="$unix_path" 46389 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 46390 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 46391 new_path="$unix_path" 46392 fi 46393 46394 # remove trailing .exe if any 46395 new_path="${new_path/%.exe/}" 46396 46397 # Save the first 10 bytes of this path to the storage, so fixpath can work. 46398 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 46399 fi 46400 46401 else 46402 # We're on a unix platform. Hooray! :) 46403 # First separate the path from the arguments. This will split at the first 46404 # space. 46405 complete="$BUILD_OBJCOPY" 46406 path="${complete%% *}" 46407 tmp="$complete EOL" 46408 arguments="${tmp#* }" 46409 46410 # Cannot rely on the command "which" here since it doesn't always work. 46411 is_absolute_path=`$ECHO "$path" | $GREP ^/` 46412 if test -z "$is_absolute_path"; then 46413 # Path to executable is not absolute. Find it. 46414 IFS_save="$IFS" 46415 IFS=: 46416 for p in $PATH; do 46417 if test -f "$p/$path" && test -x "$p/$path"; then 46418 new_path="$p/$path" 46419 break 46420 fi 46421 done 46422 IFS="$IFS_save" 46423 else 46424 # This is an absolute path, we can use it without further modifications. 46425 new_path="$path" 46426 fi 46427 46428 if test "x$new_path" = x; then 46429 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BUILD_OBJCOPY, which resolves as \"$complete\", is not found." >&5 46430 $as_echo "$as_me: The path of BUILD_OBJCOPY, which resolves as \"$complete\", is not found." >&6;} 46431 has_space=`$ECHO "$complete" | $GREP " "` 46432 if test "x$has_space" != x; then 46433 { $as_echo "$as_me:${as_lineno-$LINENO}: This might be caused by spaces in the path, which is not allowed." >&5 46434 $as_echo "$as_me: This might be caused by spaces in the path, which is not allowed." >&6;} 46435 fi 46436 as_fn_error $? "Cannot locate the the path of BUILD_OBJCOPY" "$LINENO" 5 46437 fi 46438 fi 46439 46440 # Now join together the path and the arguments once again 46441 if test "x$arguments" != xEOL; then 46442 new_complete="$new_path ${arguments% *}" 46443 else 46444 new_complete="$new_path" 46445 fi 46446 46447 if test "x$complete" != "x$new_complete"; then 46448 BUILD_OBJCOPY="$new_complete" 46449 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BUILD_OBJCOPY to \"$new_complete\"" >&5 46450 $as_echo "$as_me: Rewriting BUILD_OBJCOPY to \"$new_complete\"" >&6;} 46451 fi 46452 fi 46453 46454 46455 46456 # Publish this variable in the help. 46457 46458 46459 if [ -z "${BUILD_STRIP+x}" ]; then 46460 # The variable is not set by user, try to locate tool using the code snippet 46461 for ac_prog in strip 46462 do 46463 # Extract the first word of "$ac_prog", so it can be a program name with args. 46464 set dummy $ac_prog; ac_word=$2 46465 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 46466 $as_echo_n "checking for $ac_word... " >&6; } 46467 if ${ac_cv_path_BUILD_STRIP+:} false; then : 46468 $as_echo_n "(cached) " >&6 46469 else 46470 case $BUILD_STRIP in 46471 [\\/]* | ?:[\\/]*) 46472 ac_cv_path_BUILD_STRIP="$BUILD_STRIP" # Let the user override the test with a path. 46473 ;; 46474 *) 46475 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 46476 for as_dir in $PATH 46477 do 46478 IFS=$as_save_IFS 46479 test -z "$as_dir" && as_dir=. 46480 for ac_exec_ext in '' $ac_executable_extensions; do 46481 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 46482 ac_cv_path_BUILD_STRIP="$as_dir/$ac_word$ac_exec_ext" 46483 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 46484 break 2 46485 fi 46486 done 46487 done 46488 IFS=$as_save_IFS 46489 46490 ;; 46491 esac 46492 fi 46493 BUILD_STRIP=$ac_cv_path_BUILD_STRIP 46494 if test -n "$BUILD_STRIP"; then 46495 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BUILD_STRIP" >&5 46496 $as_echo "$BUILD_STRIP" >&6; } 46497 else 46498 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 46499 $as_echo "no" >&6; } 46500 fi 46501 46502 46503 test -n "$BUILD_STRIP" && break 46504 done 46505 46506 else 46507 # The variable is set, but is it from the command line or the environment? 46508 46509 # Try to remove the string !BUILD_STRIP! from our list. 46510 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!BUILD_STRIP!/} 46511 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 46512 # If it failed, the variable was not from the command line. Ignore it, 46513 # but warn the user (except for BASH, which is always set by the calling BASH). 46514 if test "xBUILD_STRIP" != xBASH; then 46515 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of BUILD_STRIP from the environment. Use command line variables instead." >&5 46516 $as_echo "$as_me: WARNING: Ignoring value of BUILD_STRIP from the environment. Use command line variables instead." >&2;} 46517 fi 46518 # Try to locate tool using the code snippet 46519 for ac_prog in strip 46520 do 46521 # Extract the first word of "$ac_prog", so it can be a program name with args. 46522 set dummy $ac_prog; ac_word=$2 46523 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 46524 $as_echo_n "checking for $ac_word... " >&6; } 46525 if ${ac_cv_path_BUILD_STRIP+:} false; then : 46526 $as_echo_n "(cached) " >&6 46527 else 46528 case $BUILD_STRIP in 46529 [\\/]* | ?:[\\/]*) 46530 ac_cv_path_BUILD_STRIP="$BUILD_STRIP" # Let the user override the test with a path. 46531 ;; 46532 *) 46533 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 46534 for as_dir in $PATH 46535 do 46536 IFS=$as_save_IFS 46537 test -z "$as_dir" && as_dir=. 46538 for ac_exec_ext in '' $ac_executable_extensions; do 46539 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 46540 ac_cv_path_BUILD_STRIP="$as_dir/$ac_word$ac_exec_ext" 46541 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 46542 break 2 46543 fi 46544 done 46545 done 46546 IFS=$as_save_IFS 46547 46548 ;; 46549 esac 46550 fi 46551 BUILD_STRIP=$ac_cv_path_BUILD_STRIP 46552 if test -n "$BUILD_STRIP"; then 46553 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BUILD_STRIP" >&5 46554 $as_echo "$BUILD_STRIP" >&6; } 46555 else 46556 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 46557 $as_echo "no" >&6; } 46558 fi 46559 46560 46561 test -n "$BUILD_STRIP" && break 46562 done 46563 46564 else 46565 # If it succeeded, then it was overridden by the user. We will use it 46566 # for the tool. 46567 46568 # First remove it from the list of overridden variables, so we can test 46569 # for unknown variables in the end. 46570 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 46571 46572 # Check if we try to supply an empty value 46573 if test "x$BUILD_STRIP" = x; then 46574 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool BUILD_STRIP= (no value)" >&5 46575 $as_echo "$as_me: Setting user supplied tool BUILD_STRIP= (no value)" >&6;} 46576 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for BUILD_STRIP" >&5 46577 $as_echo_n "checking for BUILD_STRIP... " >&6; } 46578 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 46579 $as_echo "disabled" >&6; } 46580 else 46581 # Check if the provided tool contains a complete path. 46582 tool_specified="$BUILD_STRIP" 46583 tool_basename="${tool_specified##*/}" 46584 if test "x$tool_basename" = "x$tool_specified"; then 46585 # A command without a complete path is provided, search $PATH. 46586 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool BUILD_STRIP=$tool_basename" >&5 46587 $as_echo "$as_me: Will search for user supplied tool BUILD_STRIP=$tool_basename" >&6;} 46588 # Extract the first word of "$tool_basename", so it can be a program name with args. 46589 set dummy $tool_basename; ac_word=$2 46590 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 46591 $as_echo_n "checking for $ac_word... " >&6; } 46592 if ${ac_cv_path_BUILD_STRIP+:} false; then : 46593 $as_echo_n "(cached) " >&6 46594 else 46595 case $BUILD_STRIP in 46596 [\\/]* | ?:[\\/]*) 46597 ac_cv_path_BUILD_STRIP="$BUILD_STRIP" # Let the user override the test with a path. 46598 ;; 46599 *) 46600 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 46601 for as_dir in $PATH 46602 do 46603 IFS=$as_save_IFS 46604 test -z "$as_dir" && as_dir=. 46605 for ac_exec_ext in '' $ac_executable_extensions; do 46606 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 46607 ac_cv_path_BUILD_STRIP="$as_dir/$ac_word$ac_exec_ext" 46608 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 46609 break 2 46610 fi 46611 done 46612 done 46613 IFS=$as_save_IFS 46614 46615 ;; 46616 esac 46617 fi 46618 BUILD_STRIP=$ac_cv_path_BUILD_STRIP 46619 if test -n "$BUILD_STRIP"; then 46620 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BUILD_STRIP" >&5 46621 $as_echo "$BUILD_STRIP" >&6; } 46622 else 46623 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 46624 $as_echo "no" >&6; } 46625 fi 46626 46627 46628 if test "x$BUILD_STRIP" = x; then 46629 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 46630 fi 46631 else 46632 # Otherwise we believe it is a complete path. Use it as it is. 46633 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool BUILD_STRIP=$tool_specified" >&5 46634 $as_echo "$as_me: Will use user supplied tool BUILD_STRIP=$tool_specified" >&6;} 46635 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for BUILD_STRIP" >&5 46636 $as_echo_n "checking for BUILD_STRIP... " >&6; } 46637 if test ! -x "$tool_specified"; then 46638 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 46639 $as_echo "not found" >&6; } 46640 as_fn_error $? "User supplied tool BUILD_STRIP=$tool_specified does not exist or is not executable" "$LINENO" 5 46641 fi 46642 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 46643 $as_echo "$tool_specified" >&6; } 46644 fi 46645 fi 46646 fi 46647 46648 fi 46649 46650 46651 46652 # Only process if variable expands to non-empty 46653 46654 if test "x$BUILD_STRIP" != x; then 46655 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 46656 46657 # First separate the path from the arguments. This will split at the first 46658 # space. 46659 complete="$BUILD_STRIP" 46660 path="${complete%% *}" 46661 tmp="$complete EOL" 46662 arguments="${tmp#* }" 46663 46664 # Input might be given as Windows format, start by converting to 46665 # unix format. 46666 new_path=`$CYGPATH -u "$path"` 46667 46668 # Now try to locate executable using which 46669 new_path=`$WHICH "$new_path" 2> /dev/null` 46670 # bat and cmd files are not always considered executable in cygwin causing which 46671 # to not find them 46672 if test "x$new_path" = x \ 46673 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 46674 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 46675 new_path=`$CYGPATH -u "$path"` 46676 fi 46677 if test "x$new_path" = x; then 46678 # Oops. Which didn't find the executable. 46679 # The splitting of arguments from the executable at a space might have been incorrect, 46680 # since paths with space are more likely in Windows. Give it another try with the whole 46681 # argument. 46682 path="$complete" 46683 arguments="EOL" 46684 new_path=`$CYGPATH -u "$path"` 46685 new_path=`$WHICH "$new_path" 2> /dev/null` 46686 # bat and cmd files are not always considered executable in cygwin causing which 46687 # to not find them 46688 if test "x$new_path" = x \ 46689 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 46690 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 46691 new_path=`$CYGPATH -u "$path"` 46692 fi 46693 if test "x$new_path" = x; then 46694 # It's still not found. Now this is an unrecoverable error. 46695 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BUILD_STRIP, which resolves as \"$complete\", is not found." >&5 46696 $as_echo "$as_me: The path of BUILD_STRIP, which resolves as \"$complete\", is not found." >&6;} 46697 has_space=`$ECHO "$complete" | $GREP " "` 46698 if test "x$has_space" != x; then 46699 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 46700 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 46701 fi 46702 as_fn_error $? "Cannot locate the the path of BUILD_STRIP" "$LINENO" 5 46703 fi 46704 fi 46705 46706 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 46707 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 46708 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 46709 # "foo.exe" is OK but "foo" is an error. 46710 # 46711 # This test is therefore slightly more accurate than "test -f" to check for file presence. 46712 # It is also a way to make sure we got the proper file name for the real test later on. 46713 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 46714 if test "x$test_shortpath" = x; then 46715 # Short path failed, file does not exist as specified. 46716 # Try adding .exe or .cmd 46717 if test -f "${new_path}.exe"; then 46718 input_to_shortpath="${new_path}.exe" 46719 elif test -f "${new_path}.cmd"; then 46720 input_to_shortpath="${new_path}.cmd" 46721 else 46722 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BUILD_STRIP, which resolves as \"$new_path\", is invalid." >&5 46723 $as_echo "$as_me: The path of BUILD_STRIP, which resolves as \"$new_path\", is invalid." >&6;} 46724 { $as_echo "$as_me:${as_lineno-$LINENO}: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&5 46725 $as_echo "$as_me: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&6;} 46726 as_fn_error $? "Cannot locate the the path of BUILD_STRIP" "$LINENO" 5 46727 fi 46728 else 46729 input_to_shortpath="$new_path" 46730 fi 46731 46732 # Call helper function which possibly converts this using DOS-style short mode. 46733 # If so, the updated path is stored in $new_path. 46734 new_path="$input_to_shortpath" 46735 46736 input_path="$input_to_shortpath" 46737 # Check if we need to convert this using DOS-style short mode. If the path 46738 # contains just simple characters, use it. Otherwise (spaces, weird characters), 46739 # take no chances and rewrite it. 46740 # Note: m4 eats our [], so we need to use [ and ] instead. 46741 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 46742 if test "x$has_forbidden_chars" != x; then 46743 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 46744 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 46745 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 46746 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 46747 # Going to short mode and back again did indeed matter. Since short mode is 46748 # case insensitive, let's make it lowercase to improve readability. 46749 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 46750 # Now convert it back to Unix-style (cygpath) 46751 input_path=`$CYGPATH -u "$shortmode_path"` 46752 new_path="$input_path" 46753 fi 46754 fi 46755 46756 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 46757 if test "x$test_cygdrive_prefix" = x; then 46758 # As a simple fix, exclude /usr/bin since it's not a real path. 46759 if test "x`$ECHO $input_to_shortpath | $GREP ^/usr/bin/`" = x; then 46760 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 46761 # a path prefixed by /cygdrive for fixpath to work. 46762 new_path="$CYGWIN_ROOT_PATH$input_path" 46763 fi 46764 fi 46765 46766 # remove trailing .exe if any 46767 new_path="${new_path/%.exe/}" 46768 46769 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 46770 46771 # First separate the path from the arguments. This will split at the first 46772 # space. 46773 complete="$BUILD_STRIP" 46774 path="${complete%% *}" 46775 tmp="$complete EOL" 46776 arguments="${tmp#* }" 46777 46778 # Input might be given as Windows format, start by converting to 46779 # unix format. 46780 new_path="$path" 46781 46782 windows_path="$new_path" 46783 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 46784 unix_path=`$CYGPATH -u "$windows_path"` 46785 new_path="$unix_path" 46786 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 46787 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 46788 new_path="$unix_path" 46789 fi 46790 46791 46792 # Now try to locate executable using which 46793 new_path=`$WHICH "$new_path" 2> /dev/null` 46794 46795 if test "x$new_path" = x; then 46796 # Oops. Which didn't find the executable. 46797 # The splitting of arguments from the executable at a space might have been incorrect, 46798 # since paths with space are more likely in Windows. Give it another try with the whole 46799 # argument. 46800 path="$complete" 46801 arguments="EOL" 46802 new_path="$path" 46803 46804 windows_path="$new_path" 46805 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 46806 unix_path=`$CYGPATH -u "$windows_path"` 46807 new_path="$unix_path" 46808 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 46809 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 46810 new_path="$unix_path" 46811 fi 46812 46813 46814 new_path=`$WHICH "$new_path" 2> /dev/null` 46815 # bat and cmd files are not always considered executable in MSYS causing which 46816 # to not find them 46817 if test "x$new_path" = x \ 46818 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 46819 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 46820 new_path="$path" 46821 46822 windows_path="$new_path" 46823 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 46824 unix_path=`$CYGPATH -u "$windows_path"` 46825 new_path="$unix_path" 46826 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 46827 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 46828 new_path="$unix_path" 46829 fi 46830 46831 fi 46832 46833 if test "x$new_path" = x; then 46834 # It's still not found. Now this is an unrecoverable error. 46835 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BUILD_STRIP, which resolves as \"$complete\", is not found." >&5 46836 $as_echo "$as_me: The path of BUILD_STRIP, which resolves as \"$complete\", is not found." >&6;} 46837 has_space=`$ECHO "$complete" | $GREP " "` 46838 if test "x$has_space" != x; then 46839 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 46840 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 46841 fi 46842 as_fn_error $? "Cannot locate the the path of BUILD_STRIP" "$LINENO" 5 46843 fi 46844 fi 46845 46846 # Now new_path has a complete unix path to the binary 46847 if test "x`$ECHO $new_path | $GREP ^/bin/`" != x; then 46848 # Keep paths in /bin as-is, but remove trailing .exe if any 46849 new_path="${new_path/%.exe/}" 46850 # Do not save /bin paths to all_fixpath_prefixes! 46851 else 46852 # Not in mixed or Windows style, start by that. 46853 new_path=`cmd //c echo $new_path` 46854 46855 input_path="$new_path" 46856 # Check if we need to convert this using DOS-style short mode. If the path 46857 # contains just simple characters, use it. Otherwise (spaces, weird characters), 46858 # take no chances and rewrite it. 46859 # Note: m4 eats our [], so we need to use [ and ] instead. 46860 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 46861 if test "x$has_forbidden_chars" != x; then 46862 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 46863 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 46864 fi 46865 46866 # Output is in $new_path 46867 46868 windows_path="$new_path" 46869 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 46870 unix_path=`$CYGPATH -u "$windows_path"` 46871 new_path="$unix_path" 46872 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 46873 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 46874 new_path="$unix_path" 46875 fi 46876 46877 # remove trailing .exe if any 46878 new_path="${new_path/%.exe/}" 46879 46880 # Save the first 10 bytes of this path to the storage, so fixpath can work. 46881 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 46882 fi 46883 46884 else 46885 # We're on a unix platform. Hooray! :) 46886 # First separate the path from the arguments. This will split at the first 46887 # space. 46888 complete="$BUILD_STRIP" 46889 path="${complete%% *}" 46890 tmp="$complete EOL" 46891 arguments="${tmp#* }" 46892 46893 # Cannot rely on the command "which" here since it doesn't always work. 46894 is_absolute_path=`$ECHO "$path" | $GREP ^/` 46895 if test -z "$is_absolute_path"; then 46896 # Path to executable is not absolute. Find it. 46897 IFS_save="$IFS" 46898 IFS=: 46899 for p in $PATH; do 46900 if test -f "$p/$path" && test -x "$p/$path"; then 46901 new_path="$p/$path" 46902 break 46903 fi 46904 done 46905 IFS="$IFS_save" 46906 else 46907 # This is an absolute path, we can use it without further modifications. 46908 new_path="$path" 46909 fi 46910 46911 if test "x$new_path" = x; then 46912 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BUILD_STRIP, which resolves as \"$complete\", is not found." >&5 46913 $as_echo "$as_me: The path of BUILD_STRIP, which resolves as \"$complete\", is not found." >&6;} 46914 has_space=`$ECHO "$complete" | $GREP " "` 46915 if test "x$has_space" != x; then 46916 { $as_echo "$as_me:${as_lineno-$LINENO}: This might be caused by spaces in the path, which is not allowed." >&5 46917 $as_echo "$as_me: This might be caused by spaces in the path, which is not allowed." >&6;} 46918 fi 46919 as_fn_error $? "Cannot locate the the path of BUILD_STRIP" "$LINENO" 5 46920 fi 46921 fi 46922 46923 # Now join together the path and the arguments once again 46924 if test "x$arguments" != xEOL; then 46925 new_complete="$new_path ${arguments% *}" 46926 else 46927 new_complete="$new_path" 46928 fi 46929 46930 if test "x$complete" != "x$new_complete"; then 46931 BUILD_STRIP="$new_complete" 46932 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BUILD_STRIP to \"$new_complete\"" >&5 46933 $as_echo "$as_me: Rewriting BUILD_STRIP to \"$new_complete\"" >&6;} 46934 fi 46935 fi 46936 46937 # Assume the C compiler is the assembler 46938 BUILD_AS="$BUILD_CC -c" 46939 # Just like for the target compiler, use the compiler as linker 46940 BUILD_LD="$BUILD_CC" 46941 BUILD_LDCXX="$BUILD_CXX" 46942 46943 PATH="$OLDPATH" 46944 46945 46946 COMPILER=$BUILD_CC 46947 COMPILER_NAME=BuildC 46948 46949 if test "x$TOOLCHAIN_TYPE" = xsolstudio; then 46950 # cc -V output typically looks like 46951 # cc: Sun C 5.12 Linux_i386 2011/11/16 46952 COMPILER_VERSION_OUTPUT=`$COMPILER -V 2>&1` 46953 # Check that this is likely to be the Solaris Studio cc. 46954 $ECHO "$COMPILER_VERSION_OUTPUT" | $GREP "^.*: Sun $COMPILER_NAME" > /dev/null 46955 if test $? -ne 0; then 46956 ALT_VERSION_OUTPUT=`$COMPILER --version 2>&1` 46957 { $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 46958 $as_echo "$as_me: The $COMPILER_NAME compiler (located as $COMPILER) does not seem to be the required $TOOLCHAIN_TYPE compiler." >&6;} 46959 { $as_echo "$as_me:${as_lineno-$LINENO}: The result from running with -V was: \"$COMPILER_VERSION_OUTPUT\"" >&5 46960 $as_echo "$as_me: The result from running with -V was: \"$COMPILER_VERSION_OUTPUT\"" >&6;} 46961 { $as_echo "$as_me:${as_lineno-$LINENO}: The result from running with --version was: \"$ALT_VERSION_OUTPUT\"" >&5 46962 $as_echo "$as_me: The result from running with --version was: \"$ALT_VERSION_OUTPUT\"" >&6;} 46963 as_fn_error $? "A $TOOLCHAIN_TYPE compiler is required. Try setting --with-tools-dir." "$LINENO" 5 46964 fi 46965 # Remove usage instructions (if present), and 46966 # collapse compiler output into a single line 46967 COMPILER_VERSION_STRING=`$ECHO $COMPILER_VERSION_OUTPUT | \ 46968 $SED -e 's/ *[Uu]sage:.*//'` 46969 COMPILER_VERSION_NUMBER=`$ECHO $COMPILER_VERSION_OUTPUT | \ 46970 $SED -e "s/^.*[ ,\t]$COMPILER_NAME[ ,\t]\([1-9]\.[0-9][0-9]*\).*/\1/"` 46971 elif test "x$TOOLCHAIN_TYPE" = xxlc; then 46972 # xlc -qversion output typically looks like 46973 # IBM XL C/C++ for AIX, V11.1 (5724-X13) 46974 # Version: 11.01.0000.0015 46975 COMPILER_VERSION_OUTPUT=`$COMPILER -qversion 2>&1` 46976 # Check that this is likely to be the IBM XL C compiler. 46977 $ECHO "$COMPILER_VERSION_OUTPUT" | $GREP "IBM XL C" > /dev/null 46978 if test $? -ne 0; then 46979 ALT_VERSION_OUTPUT=`$COMPILER --version 2>&1` 46980 { $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 46981 $as_echo "$as_me: The $COMPILER_NAME compiler (located as $COMPILER) does not seem to be the required $TOOLCHAIN_TYPE compiler." >&6;} 46982 { $as_echo "$as_me:${as_lineno-$LINENO}: The result from running with -qversion was: \"$COMPILER_VERSION_OUTPUT\"" >&5 46983 $as_echo "$as_me: The result from running with -qversion was: \"$COMPILER_VERSION_OUTPUT\"" >&6;} 46984 { $as_echo "$as_me:${as_lineno-$LINENO}: The result from running with --version was: \"$ALT_VERSION_OUTPUT\"" >&5 46985 $as_echo "$as_me: The result from running with --version was: \"$ALT_VERSION_OUTPUT\"" >&6;} 46986 as_fn_error $? "A $TOOLCHAIN_TYPE compiler is required. Try setting --with-tools-dir." "$LINENO" 5 46987 fi 46988 # Collapse compiler output into a single line 46989 COMPILER_VERSION_STRING=`$ECHO $COMPILER_VERSION_OUTPUT` 46990 COMPILER_VERSION_NUMBER=`$ECHO $COMPILER_VERSION_OUTPUT | \ 46991 $SED -e 's/^.*, V\([1-9][0-9.]*\).*$/\1/'` 46992 elif test "x$TOOLCHAIN_TYPE" = xmicrosoft; then 46993 # There is no specific version flag, but all output starts with a version string. 46994 # First line typically looks something like: 46995 # Microsoft (R) 32-bit C/C++ Optimizing Compiler Version 16.00.40219.01 for 80x86 46996 COMPILER_VERSION_OUTPUT=`$COMPILER 2>&1 | $HEAD -n 1 | $TR -d '\r'` 46997 # Check that this is likely to be Microsoft CL.EXE. 46998 $ECHO "$COMPILER_VERSION_OUTPUT" | $GREP "Microsoft.*Compiler" > /dev/null 46999 if test $? -ne 0; then 47000 { $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 47001 $as_echo "$as_me: The $COMPILER_NAME compiler (located as $COMPILER) does not seem to be the required $TOOLCHAIN_TYPE compiler." >&6;} 47002 { $as_echo "$as_me:${as_lineno-$LINENO}: The result from running it was: \"$COMPILER_VERSION_OUTPUT\"" >&5 47003 $as_echo "$as_me: The result from running it was: \"$COMPILER_VERSION_OUTPUT\"" >&6;} 47004 as_fn_error $? "A $TOOLCHAIN_TYPE compiler is required. Try setting --with-tools-dir." "$LINENO" 5 47005 fi 47006 # Collapse compiler output into a single line 47007 COMPILER_VERSION_STRING=`$ECHO $COMPILER_VERSION_OUTPUT` 47008 COMPILER_VERSION_NUMBER=`$ECHO $COMPILER_VERSION_OUTPUT | \ 47009 $SED -e 's/^.*ersion.\([1-9][0-9.]*\) .*$/\1/'` 47010 elif test "x$TOOLCHAIN_TYPE" = xgcc; then 47011 # gcc --version output typically looks like 47012 # gcc (Ubuntu/Linaro 4.8.1-10ubuntu9) 4.8.1 47013 # Copyright (C) 2013 Free Software Foundation, Inc. 47014 # This is free software; see the source for copying conditions. There is NO 47015 # warranty; not even for MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. 47016 COMPILER_VERSION_OUTPUT=`$COMPILER --version 2>&1` 47017 # Check that this is likely to be GCC. 47018 $ECHO "$COMPILER_VERSION_OUTPUT" | $GREP "Free Software Foundation" > /dev/null 47019 if test $? -ne 0; then 47020 { $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 47021 $as_echo "$as_me: The $COMPILER_NAME compiler (located as $COMPILER) does not seem to be the required $TOOLCHAIN_TYPE compiler." >&6;} 47022 { $as_echo "$as_me:${as_lineno-$LINENO}: The result from running with --version was: \"$COMPILER_VERSION\"" >&5 47023 $as_echo "$as_me: The result from running with --version was: \"$COMPILER_VERSION\"" >&6;} 47024 as_fn_error $? "A $TOOLCHAIN_TYPE compiler is required. Try setting --with-tools-dir." "$LINENO" 5 47025 fi 47026 # Remove Copyright and legalese from version string, and 47027 # collapse into a single line 47028 COMPILER_VERSION_STRING=`$ECHO $COMPILER_VERSION_OUTPUT | \ 47029 $SED -e 's/ *Copyright .*//'` 47030 COMPILER_VERSION_NUMBER=`$ECHO $COMPILER_VERSION_OUTPUT | \ 47031 $SED -e 's/^.* \([1-9]\.[0-9.]*\)[^0-9.].*$/\1/'` 47032 elif test "x$TOOLCHAIN_TYPE" = xclang; then 47033 # clang --version output typically looks like 47034 # Apple LLVM version 5.0 (clang-500.2.79) (based on LLVM 3.3svn) 47035 # clang version 3.3 (tags/RELEASE_33/final) 47036 # or 47037 # Debian clang version 3.2-7ubuntu1 (tags/RELEASE_32/final) (based on LLVM 3.2) 47038 # Target: x86_64-pc-linux-gnu 47039 # Thread model: posix 47040 COMPILER_VERSION_OUTPUT=`$COMPILER --version 2>&1` 47041 # Check that this is likely to be clang 47042 $ECHO "$COMPILER_VERSION_OUTPUT" | $GREP "clang" > /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_OUTPUT\"" >&5 47047 $as_echo "$as_me: The result from running with --version was: \"$COMPILER_VERSION_OUTPUT\"" >&6;} 47048 as_fn_error $? "A $TOOLCHAIN_TYPE compiler is required. Try setting --with-tools-dir." "$LINENO" 5 47049 fi 47050 # Collapse compiler output into a single line 47051 COMPILER_VERSION_STRING=`$ECHO $COMPILER_VERSION_OUTPUT` 47052 COMPILER_VERSION_NUMBER=`$ECHO $COMPILER_VERSION_OUTPUT | \ 47053 $SED -e 's/^.* version \([1-9][0-9.]*\).*$/\1/'` 47054 else 47055 as_fn_error $? "Unknown toolchain type $TOOLCHAIN_TYPE." "$LINENO" 5 47056 fi 47057 # This sets CC_VERSION_NUMBER or CXX_VERSION_NUMBER. (This comment is a grep marker) 47058 BUILD_CC_VERSION_NUMBER="$COMPILER_VERSION_NUMBER" 47059 # This sets CC_VERSION_STRING or CXX_VERSION_STRING. (This comment is a grep marker) 47060 BUILD_CC_VERSION_STRING="$COMPILER_VERSION_STRING" 47061 47062 { $as_echo "$as_me:${as_lineno-$LINENO}: Using $TOOLCHAIN_TYPE $COMPILER_NAME compiler version $COMPILER_VERSION_NUMBER [$COMPILER_VERSION_STRING]" >&5 47063 $as_echo "$as_me: Using $TOOLCHAIN_TYPE $COMPILER_NAME compiler version $COMPILER_VERSION_NUMBER [$COMPILER_VERSION_STRING]" >&6;} 47064 47065 47066 COMPILER=$BUILD_CXX 47067 COMPILER_NAME=BuildC++ 47068 47069 if test "x$TOOLCHAIN_TYPE" = xsolstudio; then 47070 # cc -V output typically looks like 47071 # cc: Sun C 5.12 Linux_i386 2011/11/16 47072 COMPILER_VERSION_OUTPUT=`$COMPILER -V 2>&1` 47073 # Check that this is likely to be the Solaris Studio cc. 47074 $ECHO "$COMPILER_VERSION_OUTPUT" | $GREP "^.*: Sun $COMPILER_NAME" > /dev/null 47075 if test $? -ne 0; then 47076 ALT_VERSION_OUTPUT=`$COMPILER --version 2>&1` 47077 { $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 47078 $as_echo "$as_me: The $COMPILER_NAME compiler (located as $COMPILER) does not seem to be the required $TOOLCHAIN_TYPE compiler." >&6;} 47079 { $as_echo "$as_me:${as_lineno-$LINENO}: The result from running with -V was: \"$COMPILER_VERSION_OUTPUT\"" >&5 47080 $as_echo "$as_me: The result from running with -V was: \"$COMPILER_VERSION_OUTPUT\"" >&6;} 47081 { $as_echo "$as_me:${as_lineno-$LINENO}: The result from running with --version was: \"$ALT_VERSION_OUTPUT\"" >&5 47082 $as_echo "$as_me: The result from running with --version was: \"$ALT_VERSION_OUTPUT\"" >&6;} 47083 as_fn_error $? "A $TOOLCHAIN_TYPE compiler is required. Try setting --with-tools-dir." "$LINENO" 5 47084 fi 47085 # Remove usage instructions (if present), and 47086 # collapse compiler output into a single line 47087 COMPILER_VERSION_STRING=`$ECHO $COMPILER_VERSION_OUTPUT | \ 47088 $SED -e 's/ *[Uu]sage:.*//'` 47089 COMPILER_VERSION_NUMBER=`$ECHO $COMPILER_VERSION_OUTPUT | \ 47090 $SED -e "s/^.*[ ,\t]$COMPILER_NAME[ ,\t]\([1-9]\.[0-9][0-9]*\).*/\1/"` 47091 elif test "x$TOOLCHAIN_TYPE" = xxlc; then 47092 # xlc -qversion output typically looks like 47093 # IBM XL C/C++ for AIX, V11.1 (5724-X13) 47094 # Version: 11.01.0000.0015 47095 COMPILER_VERSION_OUTPUT=`$COMPILER -qversion 2>&1` 47096 # Check that this is likely to be the IBM XL C compiler. 47097 $ECHO "$COMPILER_VERSION_OUTPUT" | $GREP "IBM XL C" > /dev/null 47098 if test $? -ne 0; then 47099 ALT_VERSION_OUTPUT=`$COMPILER --version 2>&1` 47100 { $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 47101 $as_echo "$as_me: The $COMPILER_NAME compiler (located as $COMPILER) does not seem to be the required $TOOLCHAIN_TYPE compiler." >&6;} 47102 { $as_echo "$as_me:${as_lineno-$LINENO}: The result from running with -qversion was: \"$COMPILER_VERSION_OUTPUT\"" >&5 47103 $as_echo "$as_me: The result from running with -qversion was: \"$COMPILER_VERSION_OUTPUT\"" >&6;} 47104 { $as_echo "$as_me:${as_lineno-$LINENO}: The result from running with --version was: \"$ALT_VERSION_OUTPUT\"" >&5 47105 $as_echo "$as_me: The result from running with --version was: \"$ALT_VERSION_OUTPUT\"" >&6;} 47106 as_fn_error $? "A $TOOLCHAIN_TYPE compiler is required. Try setting --with-tools-dir." "$LINENO" 5 47107 fi 47108 # Collapse compiler output into a single line 47109 COMPILER_VERSION_STRING=`$ECHO $COMPILER_VERSION_OUTPUT` 47110 COMPILER_VERSION_NUMBER=`$ECHO $COMPILER_VERSION_OUTPUT | \ 47111 $SED -e 's/^.*, V\([1-9][0-9.]*\).*$/\1/'` 47112 elif test "x$TOOLCHAIN_TYPE" = xmicrosoft; then 47113 # There is no specific version flag, but all output starts with a version string. 47114 # First line typically looks something like: 47115 # Microsoft (R) 32-bit C/C++ Optimizing Compiler Version 16.00.40219.01 for 80x86 47116 COMPILER_VERSION_OUTPUT=`$COMPILER 2>&1 | $HEAD -n 1 | $TR -d '\r'` 47117 # Check that this is likely to be Microsoft CL.EXE. 47118 $ECHO "$COMPILER_VERSION_OUTPUT" | $GREP "Microsoft.*Compiler" > /dev/null 47119 if test $? -ne 0; then 47120 { $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 47121 $as_echo "$as_me: The $COMPILER_NAME compiler (located as $COMPILER) does not seem to be the required $TOOLCHAIN_TYPE compiler." >&6;} 47122 { $as_echo "$as_me:${as_lineno-$LINENO}: The result from running it was: \"$COMPILER_VERSION_OUTPUT\"" >&5 47123 $as_echo "$as_me: The result from running it was: \"$COMPILER_VERSION_OUTPUT\"" >&6;} 47124 as_fn_error $? "A $TOOLCHAIN_TYPE compiler is required. Try setting --with-tools-dir." "$LINENO" 5 47125 fi 47126 # Collapse compiler output into a single line 47127 COMPILER_VERSION_STRING=`$ECHO $COMPILER_VERSION_OUTPUT` 47128 COMPILER_VERSION_NUMBER=`$ECHO $COMPILER_VERSION_OUTPUT | \ 47129 $SED -e 's/^.*ersion.\([1-9][0-9.]*\) .*$/\1/'` 47130 elif test "x$TOOLCHAIN_TYPE" = xgcc; then 47131 # gcc --version output typically looks like 47132 # gcc (Ubuntu/Linaro 4.8.1-10ubuntu9) 4.8.1 47133 # Copyright (C) 2013 Free Software Foundation, Inc. 47134 # This is free software; see the source for copying conditions. There is NO 47135 # warranty; not even for MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. 47136 COMPILER_VERSION_OUTPUT=`$COMPILER --version 2>&1` 47137 # Check that this is likely to be GCC. 47138 $ECHO "$COMPILER_VERSION_OUTPUT" | $GREP "Free Software Foundation" > /dev/null 47139 if test $? -ne 0; then 47140 { $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 47141 $as_echo "$as_me: The $COMPILER_NAME compiler (located as $COMPILER) does not seem to be the required $TOOLCHAIN_TYPE compiler." >&6;} 47142 { $as_echo "$as_me:${as_lineno-$LINENO}: The result from running with --version was: \"$COMPILER_VERSION\"" >&5 47143 $as_echo "$as_me: The result from running with --version was: \"$COMPILER_VERSION\"" >&6;} 47144 as_fn_error $? "A $TOOLCHAIN_TYPE compiler is required. Try setting --with-tools-dir." "$LINENO" 5 47145 fi 47146 # Remove Copyright and legalese from version string, and 47147 # collapse into a single line 47148 COMPILER_VERSION_STRING=`$ECHO $COMPILER_VERSION_OUTPUT | \ 47149 $SED -e 's/ *Copyright .*//'` 47150 COMPILER_VERSION_NUMBER=`$ECHO $COMPILER_VERSION_OUTPUT | \ 47151 $SED -e 's/^.* \([1-9]\.[0-9.]*\)[^0-9.].*$/\1/'` 47152 elif test "x$TOOLCHAIN_TYPE" = xclang; then 47153 # clang --version output typically looks like 47154 # Apple LLVM version 5.0 (clang-500.2.79) (based on LLVM 3.3svn) 47155 # clang version 3.3 (tags/RELEASE_33/final) 47156 # or 47157 # Debian clang version 3.2-7ubuntu1 (tags/RELEASE_32/final) (based on LLVM 3.2) 47158 # Target: x86_64-pc-linux-gnu 47159 # Thread model: posix 47160 COMPILER_VERSION_OUTPUT=`$COMPILER --version 2>&1` 47161 # Check that this is likely to be clang 47162 $ECHO "$COMPILER_VERSION_OUTPUT" | $GREP "clang" > /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_OUTPUT\"" >&5 47167 $as_echo "$as_me: The result from running with --version was: \"$COMPILER_VERSION_OUTPUT\"" >&6;} 47168 as_fn_error $? "A $TOOLCHAIN_TYPE compiler is required. Try setting --with-tools-dir." "$LINENO" 5 47169 fi 47170 # Collapse compiler output into a single line 47171 COMPILER_VERSION_STRING=`$ECHO $COMPILER_VERSION_OUTPUT` 47172 COMPILER_VERSION_NUMBER=`$ECHO $COMPILER_VERSION_OUTPUT | \ 47173 $SED -e 's/^.* version \([1-9][0-9.]*\).*$/\1/'` 47174 else 47175 as_fn_error $? "Unknown toolchain type $TOOLCHAIN_TYPE." "$LINENO" 5 47176 fi 47177 # This sets CC_VERSION_NUMBER or CXX_VERSION_NUMBER. (This comment is a grep marker) 47178 BUILD_CXX_VERSION_NUMBER="$COMPILER_VERSION_NUMBER" 47179 # This sets CC_VERSION_STRING or CXX_VERSION_STRING. (This comment is a grep marker) 47180 BUILD_CXX_VERSION_STRING="$COMPILER_VERSION_STRING" 47181 47182 { $as_echo "$as_me:${as_lineno-$LINENO}: Using $TOOLCHAIN_TYPE $COMPILER_NAME compiler version $COMPILER_VERSION_NUMBER [$COMPILER_VERSION_STRING]" >&5 47183 $as_echo "$as_me: Using $TOOLCHAIN_TYPE $COMPILER_NAME compiler version $COMPILER_VERSION_NUMBER [$COMPILER_VERSION_STRING]" >&6;} 47184 47185 47186 if test "x$BUILD_CC_VERSION_NUMBER" != "x$BUILD_CXX_VERSION_NUMBER"; then 47187 { $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 47188 $as_echo "$as_me: WARNING: C and C++ compiler have different version numbers, $BUILD_CC_VERSION_NUMBER vs $BUILD_CXX_VERSION_NUMBER." >&2;} 47189 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: This typically indicates a broken setup, and is not supported" >&5 47190 $as_echo "$as_me: WARNING: This typically indicates a broken setup, and is not supported" >&2;} 47191 fi 47192 47193 # We only check CC_VERSION_NUMBER since we assume CXX_VERSION_NUMBER is equal. 47194 if [[ "[$]BUILD_CC_VERSION_NUMBER" =~ (.*\.){3} ]] ; then 47195 { $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 47196 $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;} 47197 fi 47198 47199 if [[ "[$]BUILD_CC_VERSION_NUMBER" =~ [0-9]{6} ]] ; then 47200 { $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 47201 $as_echo "$as_me: WARNING: C compiler version number has a part larger than 99999: $BUILD_CC_VERSION_NUMBER. Comparisons might be wrong." >&2;} 47202 fi 47203 47204 OPENJDK_BUILD_COMPARABLE_ACTUAL_VERSION=`$AWK -F. '{ printf("%05d%05d%05d\n", $1, $2, $3) }' <<< "$BUILD_CC_VERSION_NUMBER"` 47205 47206 else 47207 # If we are not cross compiling, use the normal target compilers for 47208 # building the build platform executables. 47209 BUILD_CC="$CC" 47210 BUILD_CXX="$CXX" 47211 BUILD_LD="$LD" 47212 BUILD_LDCXX="$LDCXX" 47213 BUILD_NM="$NM" 47214 BUILD_AS="$AS" 47215 BUILD_OBJCOPY="$OBJCOPY" 47216 BUILD_STRIP="$STRIP" 47217 BUILD_SYSROOT_CFLAGS="$SYSROOT_CFLAGS" 47218 BUILD_SYSROOT_LDFLAGS="$SYSROOT_LDFLAGS" 47219 BUILD_AR="$AR" 47220 47221 47222 if test "x$CC_VERSION_NUMBER" != "x$CXX_VERSION_NUMBER"; then 47223 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: C and C++ compiler have different version numbers, $CC_VERSION_NUMBER vs $CXX_VERSION_NUMBER." >&5 47224 $as_echo "$as_me: WARNING: C and C++ compiler have different version numbers, $CC_VERSION_NUMBER vs $CXX_VERSION_NUMBER." >&2;} 47225 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: This typically indicates a broken setup, and is not supported" >&5 47226 $as_echo "$as_me: WARNING: This typically indicates a broken setup, and is not supported" >&2;} 47227 fi 47228 47229 # We only check CC_VERSION_NUMBER since we assume CXX_VERSION_NUMBER is equal. 47230 if [[ "[$]CC_VERSION_NUMBER" =~ (.*\.){3} ]] ; then 47231 { $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 47232 $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;} 47233 fi 47234 47235 if [[ "[$]CC_VERSION_NUMBER" =~ [0-9]{6} ]] ; then 47236 { $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 47237 $as_echo "$as_me: WARNING: C compiler version number has a part larger than 99999: $CC_VERSION_NUMBER. Comparisons might be wrong." >&2;} 47238 fi 47239 47240 OPENJDK_BUILD_COMPARABLE_ACTUAL_VERSION=`$AWK -F. '{ printf("%05d%05d%05d\n", $1, $2, $3) }' <<< "$CC_VERSION_NUMBER"` 47241 47242 fi 47243 47244 47245 47246 47247 47248 47249 47250 47251 47252 47253 47254 47255 if test "x$TOOLCHAIN_TYPE" = xmicrosoft; then 47256 # For hotspot, we need these in Windows mixed path, 47257 # so rewrite them all. Need added .exe suffix. 47258 HOTSPOT_CXX="$CXX.exe" 47259 HOTSPOT_LD="$LD.exe" 47260 HOTSPOT_MT="$MT.exe" 47261 HOTSPOT_RC="$RC.exe" 47262 47263 unix_path="$HOTSPOT_CXX" 47264 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 47265 windows_path=`$CYGPATH -m "$unix_path"` 47266 HOTSPOT_CXX="$windows_path" 47267 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 47268 windows_path=`cmd //c echo $unix_path` 47269 HOTSPOT_CXX="$windows_path" 47270 fi 47271 47272 47273 unix_path="$HOTSPOT_LD" 47274 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 47275 windows_path=`$CYGPATH -m "$unix_path"` 47276 HOTSPOT_LD="$windows_path" 47277 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 47278 windows_path=`cmd //c echo $unix_path` 47279 HOTSPOT_LD="$windows_path" 47280 fi 47281 47282 47283 unix_path="$HOTSPOT_MT" 47284 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 47285 windows_path=`$CYGPATH -m "$unix_path"` 47286 HOTSPOT_MT="$windows_path" 47287 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 47288 windows_path=`cmd //c echo $unix_path` 47289 HOTSPOT_MT="$windows_path" 47290 fi 47291 47292 47293 unix_path="$HOTSPOT_RC" 47294 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 47295 windows_path=`$CYGPATH -m "$unix_path"` 47296 HOTSPOT_RC="$windows_path" 47297 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 47298 windows_path=`cmd //c echo $unix_path` 47299 HOTSPOT_RC="$windows_path" 47300 fi 47301 47302 47303 47304 else 47305 HOTSPOT_CXX="$CXX" 47306 HOTSPOT_LD="$LD" 47307 fi 47308 47309 47310 47311 if test "x$TOOLCHAIN_TYPE" = xclang; then 47312 USE_CLANG=true 47313 fi 47314 47315 47316 47317 47318 47319 # The package path is used only on macosx? 47320 # FIXME: clean this up, and/or move it elsewhere. 47321 PACKAGE_PATH=/opt/local 47322 47323 47324 # Check for extra potential brokenness. 47325 if test "x$TOOLCHAIN_TYPE" = xmicrosoft; then 47326 # On Windows, double-check that we got the right compiler. 47327 CC_VERSION_OUTPUT=`$CC 2>&1 | $HEAD -n 1 | $TR -d '\r'` 47328 COMPILER_CPU_TEST=`$ECHO $CC_VERSION_OUTPUT | $SED -n "s/^.* \(.*\)$/\1/p"` 47329 if test "x$OPENJDK_TARGET_CPU" = "xx86"; then 47330 if test "x$COMPILER_CPU_TEST" != "x80x86" -a "x$COMPILER_CPU_TEST" != "xx86"; then 47331 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 47332 fi 47333 elif test "x$OPENJDK_TARGET_CPU" = "xx86_64"; then 47334 if test "x$COMPILER_CPU_TEST" != "xx64"; then 47335 as_fn_error $? "Target CPU mismatch. We are building for $OPENJDK_TARGET_CPU but CL is for \"$COMPILER_CPU_TEST\"; expected \"x64\"." "$LINENO" 5 47336 fi 47337 fi 47338 fi 47339 47340 if test "x$TOOLCHAIN_TYPE" = xgcc; then 47341 # If this is a --hash-style=gnu system, use --hash-style=both, why? 47342 HAS_GNU_HASH=`$CC -dumpspecs 2>/dev/null | $GREP 'hash-style=gnu'` 47343 # This is later checked when setting flags. 47344 47345 # "-Og" suppported for GCC 4.8 and later 47346 CFLAG_OPTIMIZE_DEBUG_FLAG="-Og" 47347 47348 47349 47350 47351 47352 47353 47354 47355 47356 47357 47358 47359 47360 47361 47362 47363 47364 47365 47366 47367 47368 47369 47370 47371 47372 47373 47374 47375 47376 47377 47378 47379 47380 47381 47382 47383 47384 47385 47386 47387 47388 47389 47390 47391 47392 47393 47394 # Execute function body 47395 47396 47397 47398 47399 47400 47401 47402 47403 47404 47405 47406 47407 47408 47409 47410 47411 47412 47413 47414 47415 47416 47417 47418 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 # Execute function body 47444 47445 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if the C compiler supports \"$CFLAG_OPTIMIZE_DEBUG_FLAG\"" >&5 47446 $as_echo_n "checking if the C compiler supports \"$CFLAG_OPTIMIZE_DEBUG_FLAG\"... " >&6; } 47447 supports=yes 47448 47449 saved_cflags="$CFLAGS" 47450 CFLAGS="$CFLAGS $CFLAG_OPTIMIZE_DEBUG_FLAG" 47451 ac_ext=c 47452 ac_cpp='$CPP $CPPFLAGS' 47453 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5' 47454 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' 47455 ac_compiler_gnu=$ac_cv_c_compiler_gnu 47456 47457 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 47458 /* end confdefs.h. */ 47459 int i; 47460 _ACEOF 47461 if ac_fn_c_try_compile "$LINENO"; then : 47462 47463 else 47464 supports=no 47465 fi 47466 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext 47467 ac_ext=cpp 47468 ac_cpp='$CXXCPP $CPPFLAGS' 47469 ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5' 47470 ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' 47471 ac_compiler_gnu=$ac_cv_cxx_compiler_gnu 47472 47473 CFLAGS="$saved_cflags" 47474 47475 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $supports" >&5 47476 $as_echo "$supports" >&6; } 47477 if test "x$supports" = "xyes" ; then 47478 : 47479 C_COMP_SUPPORTS="yes" 47480 else 47481 : 47482 C_COMP_SUPPORTS="no" 47483 fi 47484 47485 47486 47487 47488 47489 47490 47491 47492 47493 47494 47495 47496 47497 47498 47499 47500 47501 47502 47503 47504 47505 47506 47507 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 # Execute function body 47544 47545 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if the C++ compiler supports \"$CFLAG_OPTIMIZE_DEBUG_FLAG\"" >&5 47546 $as_echo_n "checking if the C++ compiler supports \"$CFLAG_OPTIMIZE_DEBUG_FLAG\"... " >&6; } 47547 supports=yes 47548 47549 saved_cxxflags="$CXXFLAGS" 47550 CXXFLAGS="$CXXFLAG $CFLAG_OPTIMIZE_DEBUG_FLAG" 47551 ac_ext=cpp 47552 ac_cpp='$CXXCPP $CPPFLAGS' 47553 ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5' 47554 ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' 47555 ac_compiler_gnu=$ac_cv_cxx_compiler_gnu 47556 47557 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 47558 /* end confdefs.h. */ 47559 int i; 47560 _ACEOF 47561 if ac_fn_cxx_try_compile "$LINENO"; then : 47562 47563 else 47564 supports=no 47565 fi 47566 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext 47567 ac_ext=cpp 47568 ac_cpp='$CXXCPP $CPPFLAGS' 47569 ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5' 47570 ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' 47571 ac_compiler_gnu=$ac_cv_cxx_compiler_gnu 47572 47573 CXXFLAGS="$saved_cxxflags" 47574 47575 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $supports" >&5 47576 $as_echo "$supports" >&6; } 47577 if test "x$supports" = "xyes" ; then 47578 : 47579 CXX_COMP_SUPPORTS="yes" 47580 else 47581 : 47582 CXX_COMP_SUPPORTS="no" 47583 fi 47584 47585 47586 47587 47588 47589 47590 47591 47592 47593 47594 47595 47596 47597 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if both compilers support \"$CFLAG_OPTIMIZE_DEBUG_FLAG\"" >&5 47598 $as_echo_n "checking if both compilers support \"$CFLAG_OPTIMIZE_DEBUG_FLAG\"... " >&6; } 47599 supports=no 47600 if test "x$C_COMP_SUPPORTS" = "xyes" -a "x$CXX_COMP_SUPPORTS" = "xyes"; then supports=yes; fi 47601 47602 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $supports" >&5 47603 $as_echo "$supports" >&6; } 47604 if test "x$supports" = "xyes" ; then 47605 : 47606 HAS_CFLAG_OPTIMIZE_DEBUG=true 47607 else 47608 : 47609 HAS_CFLAG_OPTIMIZE_DEBUG=false 47610 fi 47611 47612 47613 47614 47615 47616 47617 47618 # "-z relro" supported in GNU binutils 2.17 and later 47619 LINKER_RELRO_FLAG="-Wl,-z,relro" 47620 47621 47622 47623 47624 47625 47626 47627 47628 47629 47630 47631 47632 47633 47634 47635 47636 47637 47638 47639 47640 47641 47642 47643 47644 47645 47646 47647 47648 47649 47650 47651 47652 47653 47654 47655 47656 47657 47658 47659 47660 47661 47662 47663 47664 47665 47666 47667 # Execute function body 47668 47669 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if linker supports \"$LINKER_RELRO_FLAG\"" >&5 47670 $as_echo_n "checking if linker supports \"$LINKER_RELRO_FLAG\"... " >&6; } 47671 supports=yes 47672 47673 saved_ldflags="$LDFLAGS" 47674 LDFLAGS="$LDFLAGS $LINKER_RELRO_FLAG" 47675 ac_ext=c 47676 ac_cpp='$CPP $CPPFLAGS' 47677 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5' 47678 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' 47679 ac_compiler_gnu=$ac_cv_c_compiler_gnu 47680 47681 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 47682 /* end confdefs.h. */ 47683 47684 int 47685 main () 47686 { 47687 47688 ; 47689 return 0; 47690 } 47691 _ACEOF 47692 if ac_fn_c_try_link "$LINENO"; then : 47693 47694 else 47695 supports=no 47696 fi 47697 rm -f core conftest.err conftest.$ac_objext \ 47698 conftest$ac_exeext conftest.$ac_ext 47699 ac_ext=cpp 47700 ac_cpp='$CXXCPP $CPPFLAGS' 47701 ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5' 47702 ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' 47703 ac_compiler_gnu=$ac_cv_cxx_compiler_gnu 47704 47705 LDFLAGS="$saved_ldflags" 47706 47707 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $supports" >&5 47708 $as_echo "$supports" >&6; } 47709 if test "x$supports" = "xyes" ; then 47710 : 47711 HAS_LINKER_RELRO=true 47712 else 47713 : 47714 HAS_LINKER_RELRO=false 47715 fi 47716 47717 47718 47719 47720 47721 47722 47723 47724 47725 47726 47727 47728 47729 # "-z now" supported in GNU binutils 2.11 and later 47730 LINKER_NOW_FLAG="-Wl,-z,now" 47731 47732 47733 47734 47735 47736 47737 47738 47739 47740 47741 47742 47743 47744 47745 47746 47747 47748 47749 47750 47751 47752 47753 47754 47755 47756 47757 47758 47759 47760 47761 47762 47763 47764 47765 47766 47767 47768 47769 47770 47771 47772 47773 47774 47775 47776 47777 47778 # Execute function body 47779 47780 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if linker supports \"$LINKER_NOW_FLAG\"" >&5 47781 $as_echo_n "checking if linker supports \"$LINKER_NOW_FLAG\"... " >&6; } 47782 supports=yes 47783 47784 saved_ldflags="$LDFLAGS" 47785 LDFLAGS="$LDFLAGS $LINKER_NOW_FLAG" 47786 ac_ext=c 47787 ac_cpp='$CPP $CPPFLAGS' 47788 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5' 47789 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' 47790 ac_compiler_gnu=$ac_cv_c_compiler_gnu 47791 47792 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 47793 /* end confdefs.h. */ 47794 47795 int 47796 main () 47797 { 47798 47799 ; 47800 return 0; 47801 } 47802 _ACEOF 47803 if ac_fn_c_try_link "$LINENO"; then : 47804 47805 else 47806 supports=no 47807 fi 47808 rm -f core conftest.err conftest.$ac_objext \ 47809 conftest$ac_exeext conftest.$ac_ext 47810 ac_ext=cpp 47811 ac_cpp='$CXXCPP $CPPFLAGS' 47812 ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5' 47813 ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' 47814 ac_compiler_gnu=$ac_cv_cxx_compiler_gnu 47815 47816 LDFLAGS="$saved_ldflags" 47817 47818 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $supports" >&5 47819 $as_echo "$supports" >&6; } 47820 if test "x$supports" = "xyes" ; then 47821 : 47822 HAS_LINKER_NOW=true 47823 else 47824 : 47825 HAS_LINKER_NOW=false 47826 fi 47827 47828 47829 47830 47831 47832 47833 47834 47835 47836 47837 47838 47839 fi 47840 47841 # Check for broken SuSE 'ld' for which 'Only anonymous version tag is allowed 47842 # in executable.' 47843 USING_BROKEN_SUSE_LD=no 47844 if test "x$OPENJDK_TARGET_OS" = xlinux && test "x$TOOLCHAIN_TYPE" = xgcc; then 47845 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for broken SuSE 'ld' which only understands anonymous version tags in executables" >&5 47846 $as_echo_n "checking for broken SuSE 'ld' which only understands anonymous version tags in executables... " >&6; } 47847 $ECHO "SUNWprivate_1.1 { local: *; };" > version-script.map 47848 $ECHO "int main() { }" > main.c 47849 if $CXX -Wl,-version-script=version-script.map main.c 2>&5 >&5; then 47850 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 47851 $as_echo "no" >&6; } 47852 USING_BROKEN_SUSE_LD=no 47853 else 47854 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 47855 $as_echo "yes" >&6; } 47856 USING_BROKEN_SUSE_LD=yes 47857 fi 47858 $RM version-script.map main.c a.out 47859 fi 47860 47861 47862 # Setup hotspot lecagy names for toolchains 47863 HOTSPOT_TOOLCHAIN_TYPE=$TOOLCHAIN_TYPE 47864 if test "x$TOOLCHAIN_TYPE" = xclang; then 47865 HOTSPOT_TOOLCHAIN_TYPE=gcc 47866 elif test "x$TOOLCHAIN_TYPE" = xsolstudio; then 47867 HOTSPOT_TOOLCHAIN_TYPE=sparcWorks 47868 elif test "x$TOOLCHAIN_TYPE" = xmicrosoft; then 47869 HOTSPOT_TOOLCHAIN_TYPE=visCPP 47870 fi 47871 47872 47873 47874 # Setup the JTReg Regression Test Harness. 47875 47876 47877 # Check whether --with-jtreg was given. 47878 if test "${with_jtreg+set}" = set; then : 47879 withval=$with_jtreg; 47880 else 47881 with_jtreg=no 47882 fi 47883 47884 47885 if test "x$with_jtreg" = xno; then 47886 # jtreg disabled 47887 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for jtreg" >&5 47888 $as_echo_n "checking for jtreg... " >&6; } 47889 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 47890 $as_echo "no" >&6; } 47891 else 47892 if test "x$with_jtreg" != xyes; then 47893 # with path specified. 47894 JT_HOME="$with_jtreg" 47895 fi 47896 47897 if test "x$JT_HOME" != x; then 47898 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for jtreg" >&5 47899 $as_echo_n "checking for jtreg... " >&6; } 47900 47901 # use JT_HOME enviroment var. 47902 47903 # Only process if variable expands to non-empty 47904 47905 if test "x$JT_HOME" != x; then 47906 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 47907 47908 # Input might be given as Windows format, start by converting to 47909 # unix format. 47910 path="$JT_HOME" 47911 new_path=`$CYGPATH -u "$path"` 47912 47913 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 47914 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 47915 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 47916 # "foo.exe" is OK but "foo" is an error. 47917 # 47918 # This test is therefore slightly more accurate than "test -f" to check for file precense. 47919 # It is also a way to make sure we got the proper file name for the real test later on. 47920 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 47921 if test "x$test_shortpath" = x; then 47922 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of JT_HOME, which resolves as \"$path\", is invalid." >&5 47923 $as_echo "$as_me: The path of JT_HOME, which resolves as \"$path\", is invalid." >&6;} 47924 as_fn_error $? "Cannot locate the the path of JT_HOME" "$LINENO" 5 47925 fi 47926 47927 # Call helper function which possibly converts this using DOS-style short mode. 47928 # If so, the updated path is stored in $new_path. 47929 47930 input_path="$new_path" 47931 # Check if we need to convert this using DOS-style short mode. If the path 47932 # contains just simple characters, use it. Otherwise (spaces, weird characters), 47933 # take no chances and rewrite it. 47934 # Note: m4 eats our [], so we need to use [ and ] instead. 47935 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 47936 if test "x$has_forbidden_chars" != x; then 47937 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 47938 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 47939 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 47940 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 47941 # Going to short mode and back again did indeed matter. Since short mode is 47942 # case insensitive, let's make it lowercase to improve readability. 47943 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 47944 # Now convert it back to Unix-style (cygpath) 47945 input_path=`$CYGPATH -u "$shortmode_path"` 47946 new_path="$input_path" 47947 fi 47948 fi 47949 47950 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 47951 if test "x$test_cygdrive_prefix" = x; then 47952 # As a simple fix, exclude /usr/bin since it's not a real path. 47953 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 47954 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 47955 # a path prefixed by /cygdrive for fixpath to work. 47956 new_path="$CYGWIN_ROOT_PATH$input_path" 47957 fi 47958 fi 47959 47960 47961 if test "x$path" != "x$new_path"; then 47962 JT_HOME="$new_path" 47963 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting JT_HOME to \"$new_path\"" >&5 47964 $as_echo "$as_me: Rewriting JT_HOME to \"$new_path\"" >&6;} 47965 fi 47966 47967 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 47968 47969 path="$JT_HOME" 47970 has_colon=`$ECHO $path | $GREP ^.:` 47971 new_path="$path" 47972 if test "x$has_colon" = x; then 47973 # Not in mixed or Windows style, start by that. 47974 new_path=`cmd //c echo $path` 47975 fi 47976 47977 47978 input_path="$new_path" 47979 # Check if we need to convert this using DOS-style short mode. If the path 47980 # contains just simple characters, use it. Otherwise (spaces, weird characters), 47981 # take no chances and rewrite it. 47982 # Note: m4 eats our [], so we need to use [ and ] instead. 47983 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 47984 if test "x$has_forbidden_chars" != x; then 47985 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 47986 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 47987 fi 47988 47989 47990 windows_path="$new_path" 47991 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 47992 unix_path=`$CYGPATH -u "$windows_path"` 47993 new_path="$unix_path" 47994 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 47995 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 47996 new_path="$unix_path" 47997 fi 47998 47999 if test "x$path" != "x$new_path"; then 48000 JT_HOME="$new_path" 48001 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting JT_HOME to \"$new_path\"" >&5 48002 $as_echo "$as_me: Rewriting JT_HOME to \"$new_path\"" >&6;} 48003 fi 48004 48005 # Save the first 10 bytes of this path to the storage, so fixpath can work. 48006 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 48007 48008 else 48009 # We're on a unix platform. Hooray! :) 48010 path="$JT_HOME" 48011 has_space=`$ECHO "$path" | $GREP " "` 48012 if test "x$has_space" != x; then 48013 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of JT_HOME, which resolves as \"$path\", is invalid." >&5 48014 $as_echo "$as_me: The path of JT_HOME, which resolves as \"$path\", is invalid." >&6;} 48015 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 48016 fi 48017 48018 # Use eval to expand a potential ~ 48019 eval path="$path" 48020 if test ! -f "$path" && test ! -d "$path"; then 48021 as_fn_error $? "The path of JT_HOME, which resolves as \"$path\", is not found." "$LINENO" 5 48022 fi 48023 48024 if test -d "$path"; then 48025 JT_HOME="`cd "$path"; $THEPWDCMD -L`" 48026 else 48027 dir="`$DIRNAME "$path"`" 48028 base="`$BASENAME "$path"`" 48029 JT_HOME="`cd "$dir"; $THEPWDCMD -L`/$base" 48030 fi 48031 fi 48032 fi 48033 48034 48035 # jtreg win32 script works for everybody 48036 JTREGEXE="$JT_HOME/bin/jtreg" 48037 48038 if test ! -f "$JTREGEXE"; then 48039 as_fn_error $? "JTReg executable does not exist: $JTREGEXE" "$LINENO" 5 48040 fi 48041 48042 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $JTREGEXE" >&5 48043 $as_echo "$JTREGEXE" >&6; } 48044 else 48045 # try to find jtreg on path 48046 48047 48048 48049 # Publish this variable in the help. 48050 48051 48052 if [ -z "${JTREGEXE+x}" ]; then 48053 # The variable is not set by user, try to locate tool using the code snippet 48054 for ac_prog in jtreg 48055 do 48056 # Extract the first word of "$ac_prog", so it can be a program name with args. 48057 set dummy $ac_prog; ac_word=$2 48058 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 48059 $as_echo_n "checking for $ac_word... " >&6; } 48060 if ${ac_cv_path_JTREGEXE+:} false; then : 48061 $as_echo_n "(cached) " >&6 48062 else 48063 case $JTREGEXE in 48064 [\\/]* | ?:[\\/]*) 48065 ac_cv_path_JTREGEXE="$JTREGEXE" # Let the user override the test with a path. 48066 ;; 48067 *) 48068 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 48069 for as_dir in $PATH 48070 do 48071 IFS=$as_save_IFS 48072 test -z "$as_dir" && as_dir=. 48073 for ac_exec_ext in '' $ac_executable_extensions; do 48074 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 48075 ac_cv_path_JTREGEXE="$as_dir/$ac_word$ac_exec_ext" 48076 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 48077 break 2 48078 fi 48079 done 48080 done 48081 IFS=$as_save_IFS 48082 48083 ;; 48084 esac 48085 fi 48086 JTREGEXE=$ac_cv_path_JTREGEXE 48087 if test -n "$JTREGEXE"; then 48088 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $JTREGEXE" >&5 48089 $as_echo "$JTREGEXE" >&6; } 48090 else 48091 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 48092 $as_echo "no" >&6; } 48093 fi 48094 48095 48096 test -n "$JTREGEXE" && break 48097 done 48098 48099 else 48100 # The variable is set, but is it from the command line or the environment? 48101 48102 # Try to remove the string !JTREGEXE! from our list. 48103 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!JTREGEXE!/} 48104 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 48105 # If it failed, the variable was not from the command line. Ignore it, 48106 # but warn the user (except for BASH, which is always set by the calling BASH). 48107 if test "xJTREGEXE" != xBASH; then 48108 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of JTREGEXE from the environment. Use command line variables instead." >&5 48109 $as_echo "$as_me: WARNING: Ignoring value of JTREGEXE from the environment. Use command line variables instead." >&2;} 48110 fi 48111 # Try to locate tool using the code snippet 48112 for ac_prog in jtreg 48113 do 48114 # Extract the first word of "$ac_prog", so it can be a program name with args. 48115 set dummy $ac_prog; ac_word=$2 48116 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 48117 $as_echo_n "checking for $ac_word... " >&6; } 48118 if ${ac_cv_path_JTREGEXE+:} false; then : 48119 $as_echo_n "(cached) " >&6 48120 else 48121 case $JTREGEXE in 48122 [\\/]* | ?:[\\/]*) 48123 ac_cv_path_JTREGEXE="$JTREGEXE" # Let the user override the test with a path. 48124 ;; 48125 *) 48126 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 48127 for as_dir in $PATH 48128 do 48129 IFS=$as_save_IFS 48130 test -z "$as_dir" && as_dir=. 48131 for ac_exec_ext in '' $ac_executable_extensions; do 48132 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 48133 ac_cv_path_JTREGEXE="$as_dir/$ac_word$ac_exec_ext" 48134 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 48135 break 2 48136 fi 48137 done 48138 done 48139 IFS=$as_save_IFS 48140 48141 ;; 48142 esac 48143 fi 48144 JTREGEXE=$ac_cv_path_JTREGEXE 48145 if test -n "$JTREGEXE"; then 48146 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $JTREGEXE" >&5 48147 $as_echo "$JTREGEXE" >&6; } 48148 else 48149 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 48150 $as_echo "no" >&6; } 48151 fi 48152 48153 48154 test -n "$JTREGEXE" && break 48155 done 48156 48157 else 48158 # If it succeeded, then it was overridden by the user. We will use it 48159 # for the tool. 48160 48161 # First remove it from the list of overridden variables, so we can test 48162 # for unknown variables in the end. 48163 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 48164 48165 # Check if we try to supply an empty value 48166 if test "x$JTREGEXE" = x; then 48167 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool JTREGEXE= (no value)" >&5 48168 $as_echo "$as_me: Setting user supplied tool JTREGEXE= (no value)" >&6;} 48169 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for JTREGEXE" >&5 48170 $as_echo_n "checking for JTREGEXE... " >&6; } 48171 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 48172 $as_echo "disabled" >&6; } 48173 else 48174 # Check if the provided tool contains a complete path. 48175 tool_specified="$JTREGEXE" 48176 tool_basename="${tool_specified##*/}" 48177 if test "x$tool_basename" = "x$tool_specified"; then 48178 # A command without a complete path is provided, search $PATH. 48179 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool JTREGEXE=$tool_basename" >&5 48180 $as_echo "$as_me: Will search for user supplied tool JTREGEXE=$tool_basename" >&6;} 48181 # Extract the first word of "$tool_basename", so it can be a program name with args. 48182 set dummy $tool_basename; ac_word=$2 48183 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 48184 $as_echo_n "checking for $ac_word... " >&6; } 48185 if ${ac_cv_path_JTREGEXE+:} false; then : 48186 $as_echo_n "(cached) " >&6 48187 else 48188 case $JTREGEXE in 48189 [\\/]* | ?:[\\/]*) 48190 ac_cv_path_JTREGEXE="$JTREGEXE" # Let the user override the test with a path. 48191 ;; 48192 *) 48193 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 48194 for as_dir in $PATH 48195 do 48196 IFS=$as_save_IFS 48197 test -z "$as_dir" && as_dir=. 48198 for ac_exec_ext in '' $ac_executable_extensions; do 48199 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 48200 ac_cv_path_JTREGEXE="$as_dir/$ac_word$ac_exec_ext" 48201 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 48202 break 2 48203 fi 48204 done 48205 done 48206 IFS=$as_save_IFS 48207 48208 ;; 48209 esac 48210 fi 48211 JTREGEXE=$ac_cv_path_JTREGEXE 48212 if test -n "$JTREGEXE"; then 48213 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $JTREGEXE" >&5 48214 $as_echo "$JTREGEXE" >&6; } 48215 else 48216 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 48217 $as_echo "no" >&6; } 48218 fi 48219 48220 48221 if test "x$JTREGEXE" = x; then 48222 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 48223 fi 48224 else 48225 # Otherwise we believe it is a complete path. Use it as it is. 48226 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool JTREGEXE=$tool_specified" >&5 48227 $as_echo "$as_me: Will use user supplied tool JTREGEXE=$tool_specified" >&6;} 48228 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for JTREGEXE" >&5 48229 $as_echo_n "checking for JTREGEXE... " >&6; } 48230 if test ! -x "$tool_specified"; then 48231 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 48232 $as_echo "not found" >&6; } 48233 as_fn_error $? "User supplied tool JTREGEXE=$tool_specified does not exist or is not executable" "$LINENO" 5 48234 fi 48235 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 48236 $as_echo "$tool_specified" >&6; } 48237 fi 48238 fi 48239 fi 48240 48241 fi 48242 48243 48244 48245 if test "x$JTREGEXE" = x; then 48246 as_fn_error $? "Could not find required tool for JTREGEXE" "$LINENO" 5 48247 fi 48248 48249 48250 JT_HOME="`$DIRNAME $JTREGEXE`" 48251 fi 48252 fi 48253 48254 48255 48256 48257 48258 48259 # COMPILER_TARGET_BITS_FLAG : option for selecting 32- or 64-bit output 48260 # COMPILER_COMMAND_FILE_FLAG : option for passing a command file to the compiler 48261 # COMPILER_BINDCMD_FILE_FLAG : option for specifying a file which saves the binder 48262 # commands produced by the link step (currently AIX only) 48263 if test "x$TOOLCHAIN_TYPE" = xxlc; then 48264 COMPILER_TARGET_BITS_FLAG="-q" 48265 COMPILER_COMMAND_FILE_FLAG="-f" 48266 COMPILER_BINDCMD_FILE_FLAG="-bloadmap:" 48267 else 48268 COMPILER_TARGET_BITS_FLAG="-m" 48269 COMPILER_COMMAND_FILE_FLAG="@" 48270 COMPILER_BINDCMD_FILE_FLAG="" 48271 48272 # The solstudio linker does not support @-files. 48273 if test "x$TOOLCHAIN_TYPE" = xsolstudio; then 48274 COMPILER_COMMAND_FILE_FLAG= 48275 fi 48276 48277 # Check if @file is supported by gcc 48278 if test "x$TOOLCHAIN_TYPE" = xgcc; then 48279 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if @file is supported by gcc" >&5 48280 $as_echo_n "checking if @file is supported by gcc... " >&6; } 48281 # Extra emtpy "" to prevent ECHO from interpreting '--version' as argument 48282 $ECHO "" "--version" > command.file 48283 if $CXX @command.file 2>&5 >&5; then 48284 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 48285 $as_echo "yes" >&6; } 48286 COMPILER_COMMAND_FILE_FLAG="@" 48287 else 48288 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 48289 $as_echo "no" >&6; } 48290 COMPILER_COMMAND_FILE_FLAG= 48291 fi 48292 $RM command.file 48293 fi 48294 fi 48295 48296 48297 48298 48299 # FIXME: figure out if we should select AR flags depending on OS or toolchain. 48300 if test "x$OPENJDK_TARGET_OS" = xmacosx; then 48301 ARFLAGS="-r" 48302 elif test "x$OPENJDK_TARGET_OS" = xaix; then 48303 ARFLAGS="-X64" 48304 elif test "x$OPENJDK_TARGET_OS" = xwindows; then 48305 # lib.exe is used as AR to create static libraries. 48306 ARFLAGS="-nologo -NODEFAULTLIB:MSVCRT" 48307 else 48308 ARFLAGS="" 48309 fi 48310 48311 48312 ## Setup strip. 48313 # FIXME: should this really be per platform, or should it be per toolchain type? 48314 # strip is not provided by clang or solstudio; so guessing platform makes most sense. 48315 # FIXME: we should really only export STRIPFLAGS from here, not POST_STRIP_CMD. 48316 if test "x$OPENJDK_TARGET_OS" = xlinux; then 48317 STRIPFLAGS="-g" 48318 elif test "x$OPENJDK_TARGET_OS" = xsolaris; then 48319 STRIPFLAGS="-x" 48320 elif test "x$OPENJDK_TARGET_OS" = xmacosx; then 48321 STRIPFLAGS="-S" 48322 elif test "x$OPENJDK_TARGET_OS" = xaix; then 48323 STRIPFLAGS="-X32_64" 48324 fi 48325 48326 48327 48328 if test "x$TOOLCHAIN_TYPE" = xmicrosoft; then 48329 CC_OUT_OPTION=-Fo 48330 EXE_OUT_OPTION=-out: 48331 LD_OUT_OPTION=-out: 48332 AR_OUT_OPTION=-out: 48333 else 48334 # The option used to specify the target .o,.a or .so file. 48335 # When compiling, how to specify the to be created object file. 48336 CC_OUT_OPTION='-o$(SPACE)' 48337 # When linking, how to specify the to be created executable. 48338 EXE_OUT_OPTION='-o$(SPACE)' 48339 # When linking, how to specify the to be created dynamically linkable library. 48340 LD_OUT_OPTION='-o$(SPACE)' 48341 # When archiving, how to specify the to be create static archive for object files. 48342 AR_OUT_OPTION='rcs$(SPACE)' 48343 fi 48344 48345 48346 48347 48348 48349 # On Windows, we need to set RC flags. 48350 if test "x$TOOLCHAIN_TYPE" = xmicrosoft; then 48351 RC_FLAGS="-nologo -l0x409" 48352 JVM_RCFLAGS="-nologo" 48353 if test "x$DEBUG_LEVEL" = xrelease; then 48354 RC_FLAGS="$RC_FLAGS -DNDEBUG" 48355 JVM_RCFLAGS="$JVM_RCFLAGS -DNDEBUG" 48356 fi 48357 48358 # The version variables used to create RC_FLAGS may be overridden 48359 # in a custom configure script, or possibly the command line. 48360 # Let those variables be expanded at make time in spec.gmk. 48361 # The \$ are escaped to the shell, and the $(...) variables 48362 # are evaluated by make. 48363 RC_FLAGS="$RC_FLAGS \ 48364 -D\"JDK_VERSION_STRING=\$(VERSION_STRING)\" \ 48365 -D\"JDK_COMPANY=\$(COMPANY_NAME)\" \ 48366 -D\"JDK_COMPONENT=\$(PRODUCT_NAME) \$(JDK_RC_PLATFORM_NAME) binary\" \ 48367 -D\"JDK_VER=\$(VERSION_NUMBER)\" \ 48368 -D\"JDK_COPYRIGHT=Copyright \xA9 $COPYRIGHT_YEAR\" \ 48369 -D\"JDK_NAME=\$(PRODUCT_NAME) \$(JDK_RC_PLATFORM_NAME) \$(VERSION_MAJOR)\" \ 48370 -D\"JDK_FVER=\$(subst .,\$(COMMA),\$(VERSION_NUMBER_FOUR_POSITIONS))\"" 48371 48372 JVM_RCFLAGS="$JVM_RCFLAGS \ 48373 -D\"HS_BUILD_ID=\$(VERSION_STRING)\" \ 48374 -D\"HS_COMPANY=\$(COMPANY_NAME)\" \ 48375 -D\"JDK_DOTVER=\$(VERSION_NUMBER_FOUR_POSITIONS)\" \ 48376 -D\"HS_COPYRIGHT=Copyright $COPYRIGHT_YEAR\" \ 48377 -D\"HS_NAME=\$(PRODUCT_NAME) \$(VERSION_SHORT)\" \ 48378 -D\"JDK_VER=\$(subst .,\$(COMMA),\$(VERSION_NUMBER_FOUR_POSITIONS))\" \ 48379 -D\"HS_FNAME=jvm.dll\" \ 48380 -D\"HS_INTERNAL_NAME=jvm\"" 48381 fi 48382 48383 48384 48385 if test "x$TOOLCHAIN_TYPE" = xmicrosoft; then 48386 # silence copyright notice and other headers. 48387 COMMON_CCXXFLAGS="$COMMON_CCXXFLAGS -nologo" 48388 fi 48389 48390 48391 # Now we can test some aspects on the target using configure macros. 48392 48393 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ANSI C header files" >&5 48394 $as_echo_n "checking for ANSI C header files... " >&6; } 48395 if ${ac_cv_header_stdc+:} false; then : 48396 $as_echo_n "(cached) " >&6 48397 else 48398 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 48399 /* end confdefs.h. */ 48400 #include <stdlib.h> 48401 #include <stdarg.h> 48402 #include <string.h> 48403 #include <float.h> 48404 48405 int 48406 main () 48407 { 48408 48409 ; 48410 return 0; 48411 } 48412 _ACEOF 48413 if ac_fn_cxx_try_compile "$LINENO"; then : 48414 ac_cv_header_stdc=yes 48415 else 48416 ac_cv_header_stdc=no 48417 fi 48418 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext 48419 48420 if test $ac_cv_header_stdc = yes; then 48421 # SunOS 4.x string.h does not declare mem*, contrary to ANSI. 48422 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 48423 /* end confdefs.h. */ 48424 #include <string.h> 48425 48426 _ACEOF 48427 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | 48428 $EGREP "memchr" >/dev/null 2>&1; then : 48429 48430 else 48431 ac_cv_header_stdc=no 48432 fi 48433 rm -f conftest* 48434 48435 fi 48436 48437 if test $ac_cv_header_stdc = yes; then 48438 # ISC 2.0.2 stdlib.h does not declare free, contrary to ANSI. 48439 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 48440 /* end confdefs.h. */ 48441 #include <stdlib.h> 48442 48443 _ACEOF 48444 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | 48445 $EGREP "free" >/dev/null 2>&1; then : 48446 48447 else 48448 ac_cv_header_stdc=no 48449 fi 48450 rm -f conftest* 48451 48452 fi 48453 48454 if test $ac_cv_header_stdc = yes; then 48455 # /bin/cc in Irix-4.0.5 gets non-ANSI ctype macros unless using -ansi. 48456 if test "$cross_compiling" = yes; then : 48457 : 48458 else 48459 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 48460 /* end confdefs.h. */ 48461 #include <ctype.h> 48462 #include <stdlib.h> 48463 #if ((' ' & 0x0FF) == 0x020) 48464 # define ISLOWER(c) ('a' <= (c) && (c) <= 'z') 48465 # define TOUPPER(c) (ISLOWER(c) ? 'A' + ((c) - 'a') : (c)) 48466 #else 48467 # define ISLOWER(c) \ 48468 (('a' <= (c) && (c) <= 'i') \ 48469 || ('j' <= (c) && (c) <= 'r') \ 48470 || ('s' <= (c) && (c) <= 'z')) 48471 # define TOUPPER(c) (ISLOWER(c) ? ((c) | 0x40) : (c)) 48472 #endif 48473 48474 #define XOR(e, f) (((e) && !(f)) || (!(e) && (f))) 48475 int 48476 main () 48477 { 48478 int i; 48479 for (i = 0; i < 256; i++) 48480 if (XOR (islower (i), ISLOWER (i)) 48481 || toupper (i) != TOUPPER (i)) 48482 return 2; 48483 return 0; 48484 } 48485 _ACEOF 48486 if ac_fn_cxx_try_run "$LINENO"; then : 48487 48488 else 48489 ac_cv_header_stdc=no 48490 fi 48491 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \ 48492 conftest.$ac_objext conftest.beam conftest.$ac_ext 48493 fi 48494 48495 fi 48496 fi 48497 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_header_stdc" >&5 48498 $as_echo "$ac_cv_header_stdc" >&6; } 48499 if test $ac_cv_header_stdc = yes; then 48500 48501 $as_echo "#define STDC_HEADERS 1" >>confdefs.h 48502 48503 fi 48504 48505 # On IRIX 5.3, sys/types and inttypes.h are conflicting. 48506 for ac_header in sys/types.h sys/stat.h stdlib.h string.h memory.h strings.h \ 48507 inttypes.h stdint.h unistd.h 48508 do : 48509 as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh` 48510 ac_fn_cxx_check_header_compile "$LINENO" "$ac_header" "$as_ac_Header" "$ac_includes_default 48511 " 48512 if eval test \"x\$"$as_ac_Header"\" = x"yes"; then : 48513 cat >>confdefs.h <<_ACEOF 48514 #define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1 48515 _ACEOF 48516 48517 fi 48518 48519 done 48520 48521 48522 48523 ############################################################################### 48524 # 48525 # Now we check if libjvm.so will use 32 or 64 bit pointers for the C/C++ code. 48526 # (The JVM can use 32 or 64 bit Java pointers but that decision 48527 # is made at runtime.) 48528 # 48529 48530 if test "x$OPENJDK_TARGET_OS" = xsolaris || test "x$OPENJDK_TARGET_OS" = xaix; then 48531 # Always specify -m flag on Solaris 48532 # And -q on AIX because otherwise the compiler produces 32-bit objects by default 48533 48534 # When we add flags to the "official" CFLAGS etc, we need to 48535 # keep track of these additions in ADDED_CFLAGS etc. These 48536 # will later be checked to make sure only controlled additions 48537 # have been made to CFLAGS etc. 48538 ADDED_CFLAGS=" ${COMPILER_TARGET_BITS_FLAG}${OPENJDK_TARGET_CPU_BITS}" 48539 ADDED_CXXFLAGS=" ${COMPILER_TARGET_BITS_FLAG}${OPENJDK_TARGET_CPU_BITS}" 48540 ADDED_LDFLAGS=" ${COMPILER_TARGET_BITS_FLAG}${OPENJDK_TARGET_CPU_BITS}" 48541 48542 CFLAGS="${CFLAGS}${ADDED_CFLAGS}" 48543 CXXFLAGS="${CXXFLAGS}${ADDED_CXXFLAGS}" 48544 LDFLAGS="${LDFLAGS}${ADDED_LDFLAGS}" 48545 48546 CFLAGS_JDK="${CFLAGS_JDK}${ADDED_CFLAGS}" 48547 CXXFLAGS_JDK="${CXXFLAGS_JDK}${ADDED_CXXFLAGS}" 48548 LDFLAGS_JDK="${LDFLAGS_JDK}${ADDED_LDFLAGS}" 48549 48550 JVM_CFLAGS="$JVM_CFLAGS $ADDED_CFLAGS" 48551 JVM_LDFLAGS="$JVM_LDFLAGS $ADDED_LDFLAGS" 48552 JVM_ASFLAGS="$JVM_ASFLAGS $ADDED_CFLAGS" 48553 48554 elif test "x$COMPILE_TYPE" = xreduced; then 48555 if test "x$OPENJDK_TARGET_OS_TYPE" = xunix; then 48556 # Specify -m if running reduced on unix platforms 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 fi 48579 fi 48580 if test "x$OPENJDK_TARGET_OS" = xmacosx; then 48581 JVM_CFLAGS="$JVM_CFLAGS ${COMPILER_TARGET_BITS_FLAG}${OPENJDK_TARGET_CPU_BITS}" 48582 JVM_LDFLAGS="$JVM_LDFLAGS ${COMPILER_TARGET_BITS_FLAG}${OPENJDK_TARGET_CPU_BITS}" 48583 JVM_ASFLAGS="$JVM_ASFLAGS ${COMPILER_TARGET_BITS_FLAG}${OPENJDK_TARGET_CPU_BITS}" 48584 fi 48585 48586 # Make compilation sanity check 48587 for ac_header in stdio.h 48588 do : 48589 ac_fn_cxx_check_header_mongrel "$LINENO" "stdio.h" "ac_cv_header_stdio_h" "$ac_includes_default" 48590 if test "x$ac_cv_header_stdio_h" = xyes; then : 48591 cat >>confdefs.h <<_ACEOF 48592 #define HAVE_STDIO_H 1 48593 _ACEOF 48594 48595 else 48596 48597 { $as_echo "$as_me:${as_lineno-$LINENO}: Failed to compile stdio.h. This likely implies missing compile dependencies." >&5 48598 $as_echo "$as_me: Failed to compile stdio.h. This likely implies missing compile dependencies." >&6;} 48599 if test "x$COMPILE_TYPE" = xreduced; then 48600 48601 # Print a helpful message on how to acquire the necessary build dependency. 48602 # reduced is the help tag: freetype, cups, alsa etc 48603 MISSING_DEPENDENCY=reduced 48604 48605 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 48606 cygwin_help $MISSING_DEPENDENCY 48607 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 48608 msys_help $MISSING_DEPENDENCY 48609 else 48610 PKGHANDLER_COMMAND= 48611 48612 case $PKGHANDLER in 48613 apt-get) 48614 apt_help $MISSING_DEPENDENCY ;; 48615 yum) 48616 yum_help $MISSING_DEPENDENCY ;; 48617 port) 48618 port_help $MISSING_DEPENDENCY ;; 48619 pkgutil) 48620 pkgutil_help $MISSING_DEPENDENCY ;; 48621 pkgadd) 48622 pkgadd_help $MISSING_DEPENDENCY ;; 48623 esac 48624 48625 if test "x$PKGHANDLER_COMMAND" != x; then 48626 HELP_MSG="You might be able to fix this by running '$PKGHANDLER_COMMAND'." 48627 fi 48628 fi 48629 48630 { $as_echo "$as_me:${as_lineno-$LINENO}: You are doing a reduced build. Check that you have 32-bit libraries installed. $HELP_MSG" >&5 48631 $as_echo "$as_me: You are doing a reduced build. Check that you have 32-bit libraries installed. $HELP_MSG" >&6;} 48632 elif test "x$COMPILE_TYPE" = xcross; then 48633 { $as_echo "$as_me:${as_lineno-$LINENO}: You are doing a cross-compilation. Check that you have all target platform libraries installed." >&5 48634 $as_echo "$as_me: You are doing a cross-compilation. Check that you have all target platform libraries installed." >&6;} 48635 fi 48636 as_fn_error $? "Cannot continue." "$LINENO" 5 48637 48638 fi 48639 48640 done 48641 48642 48643 # The cast to long int works around a bug in the HP C Compiler 48644 # version HP92453-01 B.11.11.23709.GP, which incorrectly rejects 48645 # declarations like `int a3[[(sizeof (unsigned char)) >= 0]];'. 48646 # This bug is HP SR number 8606223364. 48647 { $as_echo "$as_me:${as_lineno-$LINENO}: checking size of int *" >&5 48648 $as_echo_n "checking size of int *... " >&6; } 48649 if ${ac_cv_sizeof_int_p+:} false; then : 48650 $as_echo_n "(cached) " >&6 48651 else 48652 if ac_fn_cxx_compute_int "$LINENO" "(long int) (sizeof (int *))" "ac_cv_sizeof_int_p" "$ac_includes_default"; then : 48653 48654 else 48655 if test "$ac_cv_type_int_p" = yes; then 48656 { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 48657 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;} 48658 as_fn_error 77 "cannot compute sizeof (int *) 48659 See \`config.log' for more details" "$LINENO" 5; } 48660 else 48661 ac_cv_sizeof_int_p=0 48662 fi 48663 fi 48664 48665 fi 48666 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sizeof_int_p" >&5 48667 $as_echo "$ac_cv_sizeof_int_p" >&6; } 48668 48669 48670 48671 cat >>confdefs.h <<_ACEOF 48672 #define SIZEOF_INT_P $ac_cv_sizeof_int_p 48673 _ACEOF 48674 48675 48676 48677 # AC_CHECK_SIZEOF defines 'ac_cv_sizeof_int_p' to hold the number of bytes used by an 'int*' 48678 if test "x$ac_cv_sizeof_int_p" = x; then 48679 # The test failed, lets stick to the assumed value. 48680 { $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 48681 $as_echo "$as_me: WARNING: The number of bits in the target could not be determined, using $OPENJDK_TARGET_CPU_BITS." >&2;} 48682 else 48683 TESTED_TARGET_CPU_BITS=`expr 8 \* $ac_cv_sizeof_int_p` 48684 48685 if test "x$TESTED_TARGET_CPU_BITS" != "x$OPENJDK_TARGET_CPU_BITS"; then 48686 # This situation may happen on 64-bit platforms where the compiler by default only generates 32-bit objects 48687 # Let's try to implicitely set the compilers target architecture and retry the test 48688 { $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 48689 $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;} 48690 { $as_echo "$as_me:${as_lineno-$LINENO}: Retrying with platforms compiler target bits flag to ${COMPILER_TARGET_BITS_FLAG}${OPENJDK_TARGET_CPU_BITS}" >&5 48691 $as_echo "$as_me: Retrying with platforms compiler target bits flag to ${COMPILER_TARGET_BITS_FLAG}${OPENJDK_TARGET_CPU_BITS}" >&6;} 48692 48693 # When we add flags to the "official" CFLAGS etc, we need to 48694 # keep track of these additions in ADDED_CFLAGS etc. These 48695 # will later be checked to make sure only controlled additions 48696 # have been made to CFLAGS etc. 48697 ADDED_CFLAGS=" ${COMPILER_TARGET_BITS_FLAG}${OPENJDK_TARGET_CPU_BITS}" 48698 ADDED_CXXFLAGS=" ${COMPILER_TARGET_BITS_FLAG}${OPENJDK_TARGET_CPU_BITS}" 48699 ADDED_LDFLAGS=" ${COMPILER_TARGET_BITS_FLAG}${OPENJDK_TARGET_CPU_BITS}" 48700 48701 CFLAGS="${CFLAGS}${ADDED_CFLAGS}" 48702 CXXFLAGS="${CXXFLAGS}${ADDED_CXXFLAGS}" 48703 LDFLAGS="${LDFLAGS}${ADDED_LDFLAGS}" 48704 48705 CFLAGS_JDK="${CFLAGS_JDK}${ADDED_CFLAGS}" 48706 CXXFLAGS_JDK="${CXXFLAGS_JDK}${ADDED_CXXFLAGS}" 48707 LDFLAGS_JDK="${LDFLAGS_JDK}${ADDED_LDFLAGS}" 48708 48709 JVM_CFLAGS="$JVM_CFLAGS $ADDED_CFLAGS" 48710 JVM_LDFLAGS="$JVM_LDFLAGS $ADDED_LDFLAGS" 48711 JVM_ASFLAGS="$JVM_ASFLAGS $ADDED_CFLAGS" 48712 48713 48714 # We have to unset 'ac_cv_sizeof_int_p' first, otherwise AC_CHECK_SIZEOF will use the previously cached value! 48715 unset ac_cv_sizeof_int_p 48716 # And we have to undef the definition of SIZEOF_INT_P in confdefs.h by the previous invocation of AC_CHECK_SIZEOF 48717 cat >>confdefs.h <<_ACEOF 48718 #undef SIZEOF_INT_P 48719 _ACEOF 48720 48721 # The cast to long int works around a bug in the HP C Compiler 48722 # version HP92453-01 B.11.11.23709.GP, which incorrectly rejects 48723 # declarations like `int a3[[(sizeof (unsigned char)) >= 0]];'. 48724 # This bug is HP SR number 8606223364. 48725 { $as_echo "$as_me:${as_lineno-$LINENO}: checking size of int *" >&5 48726 $as_echo_n "checking size of int *... " >&6; } 48727 if ${ac_cv_sizeof_int_p+:} false; then : 48728 $as_echo_n "(cached) " >&6 48729 else 48730 if ac_fn_cxx_compute_int "$LINENO" "(long int) (sizeof (int *))" "ac_cv_sizeof_int_p" "$ac_includes_default"; then : 48731 48732 else 48733 if test "$ac_cv_type_int_p" = yes; then 48734 { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 48735 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;} 48736 as_fn_error 77 "cannot compute sizeof (int *) 48737 See \`config.log' for more details" "$LINENO" 5; } 48738 else 48739 ac_cv_sizeof_int_p=0 48740 fi 48741 fi 48742 48743 fi 48744 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sizeof_int_p" >&5 48745 $as_echo "$ac_cv_sizeof_int_p" >&6; } 48746 48747 48748 48749 cat >>confdefs.h <<_ACEOF 48750 #define SIZEOF_INT_P $ac_cv_sizeof_int_p 48751 _ACEOF 48752 48753 48754 48755 TESTED_TARGET_CPU_BITS=`expr 8 \* $ac_cv_sizeof_int_p` 48756 48757 if test "x$TESTED_TARGET_CPU_BITS" != "x$OPENJDK_TARGET_CPU_BITS"; then 48758 { $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 48759 $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;} 48760 if test "x$COMPILE_TYPE" = xreduced; then 48761 48762 # Print a helpful message on how to acquire the necessary build dependency. 48763 # reduced is the help tag: freetype, cups, alsa etc 48764 MISSING_DEPENDENCY=reduced 48765 48766 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 48767 cygwin_help $MISSING_DEPENDENCY 48768 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 48769 msys_help $MISSING_DEPENDENCY 48770 else 48771 PKGHANDLER_COMMAND= 48772 48773 case $PKGHANDLER in 48774 apt-get) 48775 apt_help $MISSING_DEPENDENCY ;; 48776 yum) 48777 yum_help $MISSING_DEPENDENCY ;; 48778 port) 48779 port_help $MISSING_DEPENDENCY ;; 48780 pkgutil) 48781 pkgutil_help $MISSING_DEPENDENCY ;; 48782 pkgadd) 48783 pkgadd_help $MISSING_DEPENDENCY ;; 48784 esac 48785 48786 if test "x$PKGHANDLER_COMMAND" != x; then 48787 HELP_MSG="You might be able to fix this by running '$PKGHANDLER_COMMAND'." 48788 fi 48789 fi 48790 48791 { $as_echo "$as_me:${as_lineno-$LINENO}: You are doing a reduced build. Check that you have 32-bit libraries installed. $HELP_MSG" >&5 48792 $as_echo "$as_me: You are doing a reduced build. Check that you have 32-bit libraries installed. $HELP_MSG" >&6;} 48793 elif test "x$COMPILE_TYPE" = xcross; then 48794 { $as_echo "$as_me:${as_lineno-$LINENO}: You are doing a cross-compilation. Check that you have all target platform libraries installed." >&5 48795 $as_echo "$as_me: You are doing a cross-compilation. Check that you have all target platform libraries installed." >&6;} 48796 fi 48797 as_fn_error $? "Cannot continue." "$LINENO" 5 48798 fi 48799 fi 48800 fi 48801 48802 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for target address size" >&5 48803 $as_echo_n "checking for target address size... " >&6; } 48804 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $OPENJDK_TARGET_CPU_BITS bits" >&5 48805 $as_echo "$OPENJDK_TARGET_CPU_BITS bits" >&6; } 48806 48807 48808 ############################################################################### 48809 # 48810 # Is the target little of big endian? 48811 # 48812 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether byte ordering is bigendian" >&5 48813 $as_echo_n "checking whether byte ordering is bigendian... " >&6; } 48814 if ${ac_cv_c_bigendian+:} false; then : 48815 $as_echo_n "(cached) " >&6 48816 else 48817 ac_cv_c_bigendian=unknown 48818 # See if we're dealing with a universal compiler. 48819 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 48820 /* end confdefs.h. */ 48821 #ifndef __APPLE_CC__ 48822 not a universal capable compiler 48823 #endif 48824 typedef int dummy; 48825 48826 _ACEOF 48827 if ac_fn_cxx_try_compile "$LINENO"; then : 48828 48829 # Check for potential -arch flags. It is not universal unless 48830 # there are at least two -arch flags with different values. 48831 ac_arch= 48832 ac_prev= 48833 for ac_word in $CC $CFLAGS $CPPFLAGS $LDFLAGS; do 48834 if test -n "$ac_prev"; then 48835 case $ac_word in 48836 i?86 | x86_64 | ppc | ppc64) 48837 if test -z "$ac_arch" || test "$ac_arch" = "$ac_word"; then 48838 ac_arch=$ac_word 48839 else 48840 ac_cv_c_bigendian=universal 48841 break 48842 fi 48843 ;; 48844 esac 48845 ac_prev= 48846 elif test "x$ac_word" = "x-arch"; then 48847 ac_prev=arch 48848 fi 48849 done 48850 fi 48851 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext 48852 if test $ac_cv_c_bigendian = unknown; then 48853 # See if sys/param.h defines the BYTE_ORDER macro. 48854 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 48855 /* end confdefs.h. */ 48856 #include <sys/types.h> 48857 #include <sys/param.h> 48858 48859 int 48860 main () 48861 { 48862 #if ! (defined BYTE_ORDER && defined BIG_ENDIAN \ 48863 && defined LITTLE_ENDIAN && BYTE_ORDER && BIG_ENDIAN \ 48864 && LITTLE_ENDIAN) 48865 bogus endian macros 48866 #endif 48867 48868 ; 48869 return 0; 48870 } 48871 _ACEOF 48872 if ac_fn_cxx_try_compile "$LINENO"; then : 48873 # It does; now see whether it defined to BIG_ENDIAN or not. 48874 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 48875 /* end confdefs.h. */ 48876 #include <sys/types.h> 48877 #include <sys/param.h> 48878 48879 int 48880 main () 48881 { 48882 #if BYTE_ORDER != BIG_ENDIAN 48883 not big endian 48884 #endif 48885 48886 ; 48887 return 0; 48888 } 48889 _ACEOF 48890 if ac_fn_cxx_try_compile "$LINENO"; then : 48891 ac_cv_c_bigendian=yes 48892 else 48893 ac_cv_c_bigendian=no 48894 fi 48895 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext 48896 fi 48897 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext 48898 fi 48899 if test $ac_cv_c_bigendian = unknown; then 48900 # See if <limits.h> defines _LITTLE_ENDIAN or _BIG_ENDIAN (e.g., Solaris). 48901 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 48902 /* end confdefs.h. */ 48903 #include <limits.h> 48904 48905 int 48906 main () 48907 { 48908 #if ! (defined _LITTLE_ENDIAN || defined _BIG_ENDIAN) 48909 bogus endian macros 48910 #endif 48911 48912 ; 48913 return 0; 48914 } 48915 _ACEOF 48916 if ac_fn_cxx_try_compile "$LINENO"; then : 48917 # It does; now see whether it defined to _BIG_ENDIAN or not. 48918 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 48919 /* end confdefs.h. */ 48920 #include <limits.h> 48921 48922 int 48923 main () 48924 { 48925 #ifndef _BIG_ENDIAN 48926 not big endian 48927 #endif 48928 48929 ; 48930 return 0; 48931 } 48932 _ACEOF 48933 if ac_fn_cxx_try_compile "$LINENO"; then : 48934 ac_cv_c_bigendian=yes 48935 else 48936 ac_cv_c_bigendian=no 48937 fi 48938 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext 48939 fi 48940 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext 48941 fi 48942 if test $ac_cv_c_bigendian = unknown; then 48943 # Compile a test program. 48944 if test "$cross_compiling" = yes; then : 48945 # Try to guess by grepping values from an object file. 48946 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 48947 /* end confdefs.h. */ 48948 short int ascii_mm[] = 48949 { 0x4249, 0x4765, 0x6E44, 0x6961, 0x6E53, 0x7953, 0 }; 48950 short int ascii_ii[] = 48951 { 0x694C, 0x5454, 0x656C, 0x6E45, 0x6944, 0x6E61, 0 }; 48952 int use_ascii (int i) { 48953 return ascii_mm[i] + ascii_ii[i]; 48954 } 48955 short int ebcdic_ii[] = 48956 { 0x89D3, 0xE3E3, 0x8593, 0x95C5, 0x89C4, 0x9581, 0 }; 48957 short int ebcdic_mm[] = 48958 { 0xC2C9, 0xC785, 0x95C4, 0x8981, 0x95E2, 0xA8E2, 0 }; 48959 int use_ebcdic (int i) { 48960 return ebcdic_mm[i] + ebcdic_ii[i]; 48961 } 48962 extern int foo; 48963 48964 int 48965 main () 48966 { 48967 return use_ascii (foo) == use_ebcdic (foo); 48968 ; 48969 return 0; 48970 } 48971 _ACEOF 48972 if ac_fn_cxx_try_compile "$LINENO"; then : 48973 if grep BIGenDianSyS conftest.$ac_objext >/dev/null; then 48974 ac_cv_c_bigendian=yes 48975 fi 48976 if grep LiTTleEnDian conftest.$ac_objext >/dev/null ; then 48977 if test "$ac_cv_c_bigendian" = unknown; then 48978 ac_cv_c_bigendian=no 48979 else 48980 # finding both strings is unlikely to happen, but who knows? 48981 ac_cv_c_bigendian=unknown 48982 fi 48983 fi 48984 fi 48985 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext 48986 else 48987 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 48988 /* end confdefs.h. */ 48989 $ac_includes_default 48990 int 48991 main () 48992 { 48993 48994 /* Are we little or big endian? From Harbison&Steele. */ 48995 union 48996 { 48997 long int l; 48998 char c[sizeof (long int)]; 48999 } u; 49000 u.l = 1; 49001 return u.c[sizeof (long int) - 1] == 1; 49002 49003 ; 49004 return 0; 49005 } 49006 _ACEOF 49007 if ac_fn_cxx_try_run "$LINENO"; then : 49008 ac_cv_c_bigendian=no 49009 else 49010 ac_cv_c_bigendian=yes 49011 fi 49012 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \ 49013 conftest.$ac_objext conftest.beam conftest.$ac_ext 49014 fi 49015 49016 fi 49017 fi 49018 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_c_bigendian" >&5 49019 $as_echo "$ac_cv_c_bigendian" >&6; } 49020 case $ac_cv_c_bigendian in #( 49021 yes) 49022 ENDIAN="big";; #( 49023 no) 49024 ENDIAN="little" ;; #( 49025 universal) 49026 ENDIAN="universal_endianness" 49027 ;; #( 49028 *) 49029 ENDIAN="unknown" ;; 49030 esac 49031 49032 49033 if test "x$ENDIAN" = xuniversal_endianness; then 49034 as_fn_error $? "Building with both big and little endianness is not supported" "$LINENO" 5 49035 fi 49036 if test "x$ENDIAN" != "x$OPENJDK_TARGET_CPU_ENDIAN"; then 49037 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 49038 fi 49039 49040 49041 # Configure flags for the tools 49042 49043 ############################################################################### 49044 # 49045 # How to compile shared libraries. 49046 # 49047 49048 if test "x$TOOLCHAIN_TYPE" = xgcc; then 49049 PICFLAG="-fPIC" 49050 C_FLAG_REORDER='' 49051 CXX_FLAG_REORDER='' 49052 49053 if test "x$OPENJDK_TARGET_OS" = xmacosx; then 49054 # Linking is different on MacOSX 49055 if test "x$STATIC_BUILD" = xtrue; then 49056 SHARED_LIBRARY_FLAGS ='-undefined dynamic_lookup' 49057 else 49058 SHARED_LIBRARY_FLAGS="-dynamiclib -compatibility_version 1.0.0 -current_version 1.0.0 $PICFLAG" 49059 JVM_CFLAGS="$JVM_CFLAGS $PICFLAG" 49060 fi 49061 SET_EXECUTABLE_ORIGIN='-Wl,-rpath,@loader_path/.' 49062 SET_SHARED_LIBRARY_ORIGIN="$SET_EXECUTABLE_ORIGIN" 49063 SET_SHARED_LIBRARY_NAME='-Wl,-install_name,@rpath/$1' 49064 SET_SHARED_LIBRARY_MAPFILE='-Wl,-exported_symbols_list,$1' 49065 else 49066 # Default works for linux, might work on other platforms as well. 49067 SHARED_LIBRARY_FLAGS='-shared' 49068 SET_EXECUTABLE_ORIGIN='-Wl,-rpath,\$$$$ORIGIN$1' 49069 SET_SHARED_LIBRARY_ORIGIN="-Wl,-z,origin $SET_EXECUTABLE_ORIGIN" 49070 SET_SHARED_LIBRARY_NAME='-Wl,-soname=$1' 49071 SET_SHARED_LIBRARY_MAPFILE='-Wl,-version-script=$1' 49072 fi 49073 elif test "x$TOOLCHAIN_TYPE" = xclang; then 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 PICFLAG='' 49080 SHARED_LIBRARY_FLAGS="-dynamiclib -compatibility_version 1.0.0 -current_version 1.0.0 $PICFLAG" 49081 SET_EXECUTABLE_ORIGIN='-Wl,-rpath,@loader_path/.' 49082 SET_SHARED_LIBRARY_ORIGIN="$SET_EXECUTABLE_ORIGIN" 49083 SET_SHARED_LIBRARY_NAME='-Wl,-install_name,@rpath/$1' 49084 SET_SHARED_LIBRARY_MAPFILE='-Wl,-exported_symbols_list,$1' 49085 49086 if test "x$STATIC_BUILD" = xfalse; then 49087 JVM_CFLAGS="$JVM_CFLAGS -fPIC" 49088 fi 49089 else 49090 # Default works for linux, might work on other platforms as well. 49091 PICFLAG='-fPIC' 49092 SHARED_LIBRARY_FLAGS='-shared' 49093 SET_EXECUTABLE_ORIGIN='-Wl,-rpath,\$$$$ORIGIN$1' 49094 SET_SHARED_LIBRARY_ORIGIN="-Wl,-z,origin $SET_EXECUTABLE_ORIGIN" 49095 SET_SHARED_LIBRARY_NAME='-Wl,-soname=$1' 49096 SET_SHARED_LIBRARY_MAPFILE='-Wl,-version-script=$1' 49097 fi 49098 elif test "x$TOOLCHAIN_TYPE" = xsolstudio; then 49099 PICFLAG="-KPIC" 49100 C_FLAG_REORDER='-xF' 49101 CXX_FLAG_REORDER='-xF' 49102 SHARED_LIBRARY_FLAGS="-G" 49103 SET_EXECUTABLE_ORIGIN='-R\$$$$ORIGIN$1' 49104 SET_SHARED_LIBRARY_ORIGIN="$SET_EXECUTABLE_ORIGIN" 49105 SET_SHARED_LIBRARY_NAME='-h $1' 49106 SET_SHARED_LIBRARY_MAPFILE='-M$1' 49107 elif test "x$TOOLCHAIN_TYPE" = xxlc; then 49108 # '-qpic' defaults to 'qpic=small'. This means that the compiler generates only 49109 # one instruction for accessing the TOC. If the TOC grows larger than 64K, the linker 49110 # will have to patch this single instruction with a call to some out-of-order code which 49111 # does the load from the TOC. This is of course slow. But in that case we also would have 49112 # to use '-bbigtoc' for linking anyway so we could also change the PICFLAG to 'qpic=large'. 49113 # With 'qpic=large' the compiler will by default generate a two-instruction sequence which 49114 # can be patched directly by the linker and does not require a jump to out-of-order code. 49115 # Another alternative instead of using 'qpic=large -bbigtoc' may be to use '-qminimaltoc' 49116 # instead. This creates a distinct TOC for every compilation unit (and thus requires two 49117 # loads for accessing a global variable). But there are rumors that this may be seen as a 49118 # 'performance feature' because of improved code locality of the symbols used in a 49119 # compilation unit. 49120 PICFLAG="-qpic" 49121 JVM_CFLAGS="$JVM_CFLAGS $PICFLAG" 49122 C_FLAG_REORDER='' 49123 CXX_FLAG_REORDER='' 49124 SHARED_LIBRARY_FLAGS="-qmkshrobj -bM:SRE -bnoentry" 49125 SET_EXECUTABLE_ORIGIN="" 49126 SET_SHARED_LIBRARY_ORIGIN='' 49127 SET_SHARED_LIBRARY_NAME='' 49128 SET_SHARED_LIBRARY_MAPFILE='' 49129 elif test "x$TOOLCHAIN_TYPE" = xmicrosoft; then 49130 PICFLAG="" 49131 C_FLAG_REORDER='' 49132 CXX_FLAG_REORDER='' 49133 SHARED_LIBRARY_FLAGS="-dll" 49134 SET_EXECUTABLE_ORIGIN='' 49135 SET_SHARED_LIBRARY_ORIGIN='' 49136 SET_SHARED_LIBRARY_NAME='' 49137 SET_SHARED_LIBRARY_MAPFILE='-def:$1' 49138 fi 49139 49140 49141 49142 49143 49144 49145 49146 49147 49148 # The (cross) compiler is now configured, we can now test capabilities 49149 # of the target platform. 49150 49151 49152 49153 ############################################################################### 49154 # 49155 # Setup the opt flags for different compilers 49156 # and different operating systems. 49157 # 49158 49159 # FIXME: this was indirectly the old default, but just inherited. 49160 # if test "x$TOOLCHAIN_TYPE" = xmicrosoft; then 49161 # C_FLAG_DEPS="-MMD -MF" 49162 # fi 49163 49164 # Generate make dependency files 49165 if test "x$TOOLCHAIN_TYPE" = xgcc; then 49166 C_FLAG_DEPS="-MMD -MF" 49167 elif test "x$TOOLCHAIN_TYPE" = xclang; then 49168 C_FLAG_DEPS="-MMD -MF" 49169 elif test "x$TOOLCHAIN_TYPE" = xsolstudio; then 49170 C_FLAG_DEPS="-xMMD -xMF" 49171 elif test "x$TOOLCHAIN_TYPE" = xxlc; then 49172 C_FLAG_DEPS="-qmakedep=gcc -MF" 49173 fi 49174 CXX_FLAG_DEPS="$C_FLAG_DEPS" 49175 49176 49177 49178 # Debug symbols 49179 if test "x$TOOLCHAIN_TYPE" = xgcc; then 49180 if test "x$OPENJDK_TARGET_CPU_BITS" = "x64" && test "x$DEBUG_LEVEL" = "xfastdebug"; then 49181 # reduce from default "-g2" option to save space 49182 CFLAGS_DEBUG_SYMBOLS="-g1" 49183 CXXFLAGS_DEBUG_SYMBOLS="-g1" 49184 else 49185 CFLAGS_DEBUG_SYMBOLS="-g" 49186 CXXFLAGS_DEBUG_SYMBOLS="-g" 49187 fi 49188 elif test "x$TOOLCHAIN_TYPE" = xclang; then 49189 CFLAGS_DEBUG_SYMBOLS="-g" 49190 CXXFLAGS_DEBUG_SYMBOLS="-g" 49191 elif test "x$TOOLCHAIN_TYPE" = xsolstudio; then 49192 CFLAGS_DEBUG_SYMBOLS="-g -xs" 49193 # -g0 enables debug symbols without disabling inlining. 49194 CXXFLAGS_DEBUG_SYMBOLS="-g0 -xs" 49195 elif test "x$TOOLCHAIN_TYPE" = xxlc; then 49196 CFLAGS_DEBUG_SYMBOLS="-g" 49197 CXXFLAGS_DEBUG_SYMBOLS="-g" 49198 elif test "x$TOOLCHAIN_TYPE" = xmicrosoft; then 49199 CFLAGS_DEBUG_SYMBOLS="-Zi" 49200 CXXFLAGS_DEBUG_SYMBOLS="-Zi" 49201 fi 49202 49203 49204 49205 # Debug symbols for JVM_CFLAGS 49206 if test "x$TOOLCHAIN_TYPE" = xsolstudio; then 49207 JVM_CFLAGS_SYMBOLS="$JVM_CFLAGS_SYMBOLS -xs" 49208 if test "x$DEBUG_LEVEL" = xslowdebug; then 49209 JVM_CFLAGS_SYMBOLS="$JVM_CFLAGS_SYMBOLS -g" 49210 else 49211 # -g0 does not disable inlining, which -g does. 49212 JVM_CFLAGS_SYMBOLS="$JVM_CFLAGS_SYMBOLS -g0" 49213 fi 49214 elif test "x$TOOLCHAIN_TYPE" = xmicrosoft; then 49215 JVM_CFLAGS_SYMBOLS="$JVM_CFLAGS_SYMBOLS -Z7 -d2Zi+" 49216 else 49217 JVM_CFLAGS_SYMBOLS="$JVM_CFLAGS_SYMBOLS -g" 49218 fi 49219 49220 49221 # bounds, memory and behavior checking options 49222 if test "x$TOOLCHAIN_TYPE" = xgcc; then 49223 case $DEBUG_LEVEL in 49224 release ) 49225 # no adjustment 49226 ;; 49227 fastdebug ) 49228 # no adjustment 49229 ;; 49230 slowdebug ) 49231 # FIXME: By adding this to C(XX)FLAGS_DEBUG_OPTIONS/JVM_CFLAGS_SYMBOLS it 49232 # get's added conditionally on whether we produce debug symbols or not. 49233 # This is most likely not really correct. 49234 49235 # Add runtime stack smashing and undefined behavior checks. 49236 # Not all versions of gcc support -fstack-protector 49237 STACK_PROTECTOR_CFLAG="-fstack-protector-all" 49238 49239 49240 49241 49242 49243 49244 49245 49246 49247 49248 49249 49250 49251 49252 49253 49254 49255 49256 49257 49258 49259 49260 49261 49262 49263 49264 49265 49266 49267 49268 49269 49270 49271 49272 49273 49274 49275 49276 49277 49278 49279 49280 # Execute function body 49281 49282 49283 49284 49285 49286 49287 49288 49289 49290 49291 49292 49293 49294 49295 49296 49297 49298 49299 49300 49301 49302 49303 49304 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 # Execute function body 49330 49331 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if the C compiler supports \"$STACK_PROTECTOR_CFLAG -Werror\"" >&5 49332 $as_echo_n "checking if the C compiler supports \"$STACK_PROTECTOR_CFLAG -Werror\"... " >&6; } 49333 supports=yes 49334 49335 saved_cflags="$CFLAGS" 49336 CFLAGS="$CFLAGS $STACK_PROTECTOR_CFLAG -Werror" 49337 ac_ext=c 49338 ac_cpp='$CPP $CPPFLAGS' 49339 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5' 49340 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' 49341 ac_compiler_gnu=$ac_cv_c_compiler_gnu 49342 49343 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 49344 /* end confdefs.h. */ 49345 int i; 49346 _ACEOF 49347 if ac_fn_c_try_compile "$LINENO"; then : 49348 49349 else 49350 supports=no 49351 fi 49352 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext 49353 ac_ext=cpp 49354 ac_cpp='$CXXCPP $CPPFLAGS' 49355 ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5' 49356 ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' 49357 ac_compiler_gnu=$ac_cv_cxx_compiler_gnu 49358 49359 CFLAGS="$saved_cflags" 49360 49361 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $supports" >&5 49362 $as_echo "$supports" >&6; } 49363 if test "x$supports" = "xyes" ; then 49364 : 49365 C_COMP_SUPPORTS="yes" 49366 else 49367 : 49368 C_COMP_SUPPORTS="no" 49369 fi 49370 49371 49372 49373 49374 49375 49376 49377 49378 49379 49380 49381 49382 49383 49384 49385 49386 49387 49388 49389 49390 49391 49392 49393 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 # Execute function body 49430 49431 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if the C++ compiler supports \"$STACK_PROTECTOR_CFLAG -Werror\"" >&5 49432 $as_echo_n "checking if the C++ compiler supports \"$STACK_PROTECTOR_CFLAG -Werror\"... " >&6; } 49433 supports=yes 49434 49435 saved_cxxflags="$CXXFLAGS" 49436 CXXFLAGS="$CXXFLAG $STACK_PROTECTOR_CFLAG -Werror" 49437 ac_ext=cpp 49438 ac_cpp='$CXXCPP $CPPFLAGS' 49439 ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5' 49440 ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' 49441 ac_compiler_gnu=$ac_cv_cxx_compiler_gnu 49442 49443 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 49444 /* end confdefs.h. */ 49445 int i; 49446 _ACEOF 49447 if ac_fn_cxx_try_compile "$LINENO"; then : 49448 49449 else 49450 supports=no 49451 fi 49452 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext 49453 ac_ext=cpp 49454 ac_cpp='$CXXCPP $CPPFLAGS' 49455 ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5' 49456 ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' 49457 ac_compiler_gnu=$ac_cv_cxx_compiler_gnu 49458 49459 CXXFLAGS="$saved_cxxflags" 49460 49461 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $supports" >&5 49462 $as_echo "$supports" >&6; } 49463 if test "x$supports" = "xyes" ; then 49464 : 49465 CXX_COMP_SUPPORTS="yes" 49466 else 49467 : 49468 CXX_COMP_SUPPORTS="no" 49469 fi 49470 49471 49472 49473 49474 49475 49476 49477 49478 49479 49480 49481 49482 49483 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if both compilers support \"$STACK_PROTECTOR_CFLAG -Werror\"" >&5 49484 $as_echo_n "checking if both compilers support \"$STACK_PROTECTOR_CFLAG -Werror\"... " >&6; } 49485 supports=no 49486 if test "x$C_COMP_SUPPORTS" = "xyes" -a "x$CXX_COMP_SUPPORTS" = "xyes"; then supports=yes; fi 49487 49488 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $supports" >&5 49489 $as_echo "$supports" >&6; } 49490 if test "x$supports" = "xyes" ; then 49491 : 49492 49493 else 49494 : 49495 STACK_PROTECTOR_CFLAG="" 49496 fi 49497 49498 49499 49500 49501 49502 49503 49504 CFLAGS_DEBUG_OPTIONS="$STACK_PROTECTOR_CFLAG --param ssp-buffer-size=1" 49505 CXXFLAGS_DEBUG_OPTIONS="$STACK_PROTECTOR_CFLAG --param ssp-buffer-size=1" 49506 if test "x$STACK_PROTECTOR_CFLAG" != x; then 49507 JVM_CFLAGS_SYMBOLS="$JVM_CFLAGS_SYMBOLS $STACK_PROTECTOR_CFLAG --param ssp-buffer-size=1" 49508 fi 49509 ;; 49510 esac 49511 fi 49512 49513 if test "x$TOOLCHAIN_TYPE" = xmicrosoft; then 49514 if test "x$DEBUG_LEVEL" != xrelease; then 49515 if test "x$OPENJDK_TARGET_CPU" = xx86_64; then 49516 JVM_CFLAGS="$JVM_CFLAGS -homeparams" 49517 fi 49518 fi 49519 fi 49520 49521 # Optimization levels 49522 if test "x$TOOLCHAIN_TYPE" = xsolstudio; then 49523 CC_HIGHEST="$CC_HIGHEST -fns -fsimple -fsingle -xbuiltin=%all -xdepend -xrestrict -xlibmil" 49524 49525 if test "x$OPENJDK_TARGET_CPU_ARCH" = "xx86"; then 49526 # FIXME: seems we always set -xregs=no%frameptr; put it elsewhere more global? 49527 C_O_FLAG_HIGHEST_JVM="-xO4" 49528 C_O_FLAG_HIGHEST="-xO4 -Wu,-O4~yz $CC_HIGHEST -xalias_level=basic -xregs=no%frameptr" 49529 C_O_FLAG_HI="-xO4 -Wu,-O4~yz -xregs=no%frameptr" 49530 C_O_FLAG_NORM="-xO2 -Wu,-O2~yz -xregs=no%frameptr" 49531 C_O_FLAG_DEBUG="-xregs=no%frameptr" 49532 C_O_FLAG_DEBUG_JVM="" 49533 C_O_FLAG_NONE="-xregs=no%frameptr" 49534 CXX_O_FLAG_HIGHEST_JVM="-xO4" 49535 CXX_O_FLAG_HIGHEST="-xO4 -Qoption ube -O4~yz $CC_HIGHEST -xregs=no%frameptr" 49536 CXX_O_FLAG_HI="-xO4 -Qoption ube -O4~yz -xregs=no%frameptr" 49537 CXX_O_FLAG_NORM="-xO2 -Qoption ube -O2~yz -xregs=no%frameptr" 49538 CXX_O_FLAG_DEBUG="-xregs=no%frameptr" 49539 CXX_O_FLAG_DEBUG_JVM="" 49540 CXX_O_FLAG_NONE="-xregs=no%frameptr" 49541 if test "x$OPENJDK_TARGET_CPU_BITS" = "x32"; then 49542 C_O_FLAG_HIGHEST="$C_O_FLAG_HIGHEST -xchip=pentium" 49543 CXX_O_FLAG_HIGHEST="$CXX_O_FLAG_HIGHEST -xchip=pentium" 49544 fi 49545 elif test "x$OPENJDK_TARGET_CPU_ARCH" = "xsparc"; then 49546 C_O_FLAG_HIGHEST_JVM="-xO4" 49547 C_O_FLAG_HIGHEST="-xO4 -Wc,-Qrm-s -Wc,-Qiselect-T0 $CC_HIGHEST -xalias_level=basic -xprefetch=auto,explicit -xchip=ultra" 49548 C_O_FLAG_HI="-xO4 -Wc,-Qrm-s -Wc,-Qiselect-T0" 49549 C_O_FLAG_NORM="-xO2 -Wc,-Qrm-s -Wc,-Qiselect-T0" 49550 C_O_FLAG_DEBUG="" 49551 C_O_FLAG_DEBUG_JVM="" 49552 C_O_FLAG_NONE="" 49553 CXX_O_FLAG_HIGHEST_JVM="-xO4" 49554 CXX_O_FLAG_HIGHEST="-xO4 -Qoption cg -Qrm-s -Qoption cg -Qiselect-T0 $CC_HIGHEST -xprefetch=auto,explicit -xchip=ultra" 49555 CXX_O_FLAG_HI="-xO4 -Qoption cg -Qrm-s -Qoption cg -Qiselect-T0" 49556 CXX_O_FLAG_NORM="-xO2 -Qoption cg -Qrm-s -Qoption cg -Qiselect-T0" 49557 CXX_O_FLAG_DEBUG="" 49558 CXX_O_FLAG_DEBUG_JVM="" 49559 CXX_O_FLAG_NONE="" 49560 fi 49561 else 49562 # The remaining toolchains share opt flags between CC and CXX; 49563 # setup for C and duplicate afterwards. 49564 if test "x$TOOLCHAIN_TYPE" = xgcc; then 49565 if test "x$OPENJDK_TARGET_OS" = xmacosx; then 49566 # On MacOSX we optimize for size, something 49567 # we should do for all platforms? 49568 C_O_FLAG_HIGHEST_JVM="-Os" 49569 C_O_FLAG_HIGHEST="-Os" 49570 C_O_FLAG_HI="-Os" 49571 C_O_FLAG_NORM="-Os" 49572 C_O_FLAG_SIZE="-Os" 49573 else 49574 C_O_FLAG_HIGHEST_JVM="-O3" 49575 C_O_FLAG_HIGHEST="-O3" 49576 C_O_FLAG_HI="-O3" 49577 C_O_FLAG_NORM="-O2" 49578 C_O_FLAG_SIZE="-Os" 49579 fi 49580 C_O_FLAG_DEBUG="-O0" 49581 if test "x$OPENJDK_TARGET_OS" = xmacosx; then 49582 C_O_FLAG_DEBUG_JVM="" 49583 elif test "x$OPENJDK_TARGET_OS" = xlinux; then 49584 C_O_FLAG_DEBUG_JVM="-O0" 49585 fi 49586 C_O_FLAG_NONE="-O0" 49587 elif test "x$TOOLCHAIN_TYPE" = xclang; then 49588 if test "x$OPENJDK_TARGET_OS" = xmacosx; then 49589 # On MacOSX we optimize for size, something 49590 # we should do for all platforms? 49591 C_O_FLAG_HIGHEST_JVM="-Os" 49592 C_O_FLAG_HIGHEST="-Os" 49593 C_O_FLAG_HI="-Os" 49594 C_O_FLAG_NORM="-Os" 49595 C_O_FLAG_SIZE="-Os" 49596 else 49597 C_O_FLAG_HIGHEST_JVM="-O3" 49598 C_O_FLAG_HIGHEST="-O3" 49599 C_O_FLAG_HI="-O3" 49600 C_O_FLAG_NORM="-O2" 49601 C_O_FLAG_SIZE="-Os" 49602 fi 49603 C_O_FLAG_DEBUG="-O0" 49604 if test "x$OPENJDK_TARGET_OS" = xmacosx; then 49605 C_O_FLAG_DEBUG_JVM="" 49606 elif test "x$OPENJDK_TARGET_OS" = xlinux; then 49607 C_O_FLAG_DEBUG_JVM="-O0" 49608 fi 49609 C_O_FLAG_NONE="-O0" 49610 elif test "x$TOOLCHAIN_TYPE" = xxlc; then 49611 C_O_FLAG_HIGHEST_JVM="-O3 -qhot=level=1 -qinline -qinlglue" 49612 C_O_FLAG_HIGHEST="-O3 -qhot=level=1 -qinline -qinlglue" 49613 C_O_FLAG_HI="-O3 -qinline -qinlglue" 49614 C_O_FLAG_NORM="-O2" 49615 C_O_FLAG_DEBUG="-qnoopt" 49616 # FIXME: Value below not verified. 49617 C_O_FLAG_DEBUG_JVM="" 49618 C_O_FLAG_NONE="-qnoopt" 49619 elif test "x$TOOLCHAIN_TYPE" = xmicrosoft; then 49620 C_O_FLAG_HIGHEST_JVM="-O2 -Oy-" 49621 C_O_FLAG_HIGHEST="-O2" 49622 C_O_FLAG_HI="-O1" 49623 C_O_FLAG_NORM="-O1" 49624 C_O_FLAG_DEBUG="-Od" 49625 C_O_FLAG_DEBUG_JVM="" 49626 C_O_FLAG_NONE="-Od" 49627 C_O_FLAG_SIZE="-Os" 49628 fi 49629 CXX_O_FLAG_HIGHEST_JVM="$C_O_FLAG_HIGHEST_JVM" 49630 CXX_O_FLAG_HIGHEST="$C_O_FLAG_HIGHEST" 49631 CXX_O_FLAG_HI="$C_O_FLAG_HI" 49632 CXX_O_FLAG_NORM="$C_O_FLAG_NORM" 49633 CXX_O_FLAG_DEBUG="$C_O_FLAG_DEBUG" 49634 CXX_O_FLAG_DEBUG_JVM="$C_O_FLAG_DEBUG_JVM" 49635 CXX_O_FLAG_NONE="$C_O_FLAG_NONE" 49636 CXX_O_FLAG_SIZE="$C_O_FLAG_SIZE" 49637 fi 49638 49639 # Adjust optimization flags according to debug level. 49640 case $DEBUG_LEVEL in 49641 release ) 49642 # no adjustment 49643 ;; 49644 fastdebug ) 49645 # Not quite so much optimization 49646 C_O_FLAG_HI="$C_O_FLAG_NORM" 49647 CXX_O_FLAG_HI="$CXX_O_FLAG_NORM" 49648 ;; 49649 slowdebug ) 49650 # Disable optimization 49651 C_O_FLAG_HIGHEST_JVM="$C_O_FLAG_DEBUG_JVM" 49652 C_O_FLAG_HIGHEST="$C_O_FLAG_DEBUG" 49653 C_O_FLAG_HI="$C_O_FLAG_DEBUG" 49654 C_O_FLAG_NORM="$C_O_FLAG_DEBUG" 49655 C_O_FLAG_SIZE="$C_O_FLAG_DEBUG" 49656 CXX_O_FLAG_HIGHEST_JVM="$CXX_O_FLAG_DEBUG_JVM" 49657 CXX_O_FLAG_HIGHEST="$CXX_O_FLAG_DEBUG" 49658 CXX_O_FLAG_HI="$CXX_O_FLAG_DEBUG" 49659 CXX_O_FLAG_NORM="$CXX_O_FLAG_DEBUG" 49660 CXX_O_FLAG_SIZE="$CXX_O_FLAG_DEBUG" 49661 ;; 49662 esac 49663 49664 49665 49666 49667 49668 49669 49670 49671 49672 49673 49674 49675 49676 49677 49678 49679 49680 49681 49682 # Special extras... 49683 if test "x$TOOLCHAIN_TYPE" = xsolstudio; then 49684 if test "x$OPENJDK_TARGET_CPU_ARCH" = "xsparc"; then 49685 CFLAGS_JDKLIB_EXTRA="${CFLAGS_JDKLIB_EXTRA} -xregs=no%appl" 49686 CXXFLAGS_JDKLIB_EXTRA="${CXXFLAGS_JDKLIB_EXTRA} -xregs=no%appl" 49687 fi 49688 CFLAGS_JDKLIB_EXTRA="${CFLAGS_JDKLIB_EXTRA} -errtags=yes -errfmt" 49689 CXXFLAGS_JDKLIB_EXTRA="${CXXFLAGS_JDKLIB_EXTRA} -errtags=yes -errfmt" 49690 elif test "x$TOOLCHAIN_TYPE" = xxlc; then 49691 CFLAGS_JDK="${CFLAGS_JDK} -qchars=signed -qfullpath -qsaveopt" 49692 CXXFLAGS_JDK="${CXXFLAGS_JDK} -qchars=signed -qfullpath -qsaveopt" 49693 elif test "x$TOOLCHAIN_TYPE" = xgcc; then 49694 CXXSTD_CXXFLAG="-std=gnu++98" 49695 49696 49697 49698 49699 49700 49701 49702 49703 49704 49705 49706 49707 49708 49709 49710 49711 49712 49713 49714 49715 49716 49717 49718 49719 49720 49721 49722 49723 49724 49725 49726 49727 49728 49729 49730 49731 49732 49733 49734 49735 49736 49737 # Execute function body 49738 49739 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if the C++ compiler supports \"$CXXSTD_CXXFLAG -Werror\"" >&5 49740 $as_echo_n "checking if the C++ compiler supports \"$CXXSTD_CXXFLAG -Werror\"... " >&6; } 49741 supports=yes 49742 49743 saved_cxxflags="$CXXFLAGS" 49744 CXXFLAGS="$CXXFLAG $CXXSTD_CXXFLAG -Werror" 49745 ac_ext=cpp 49746 ac_cpp='$CXXCPP $CPPFLAGS' 49747 ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5' 49748 ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' 49749 ac_compiler_gnu=$ac_cv_cxx_compiler_gnu 49750 49751 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 49752 /* end confdefs.h. */ 49753 int i; 49754 _ACEOF 49755 if ac_fn_cxx_try_compile "$LINENO"; then : 49756 49757 else 49758 supports=no 49759 fi 49760 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext 49761 ac_ext=cpp 49762 ac_cpp='$CXXCPP $CPPFLAGS' 49763 ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5' 49764 ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' 49765 ac_compiler_gnu=$ac_cv_cxx_compiler_gnu 49766 49767 CXXFLAGS="$saved_cxxflags" 49768 49769 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $supports" >&5 49770 $as_echo "$supports" >&6; } 49771 if test "x$supports" = "xyes" ; then 49772 : 49773 49774 else 49775 : 49776 CXXSTD_CXXFLAG="" 49777 fi 49778 49779 49780 49781 49782 49783 49784 49785 49786 49787 49788 49789 49790 CXXFLAGS_JDK="${CXXFLAGS_JDK} ${CXXSTD_CXXFLAG}" 49791 JVM_CFLAGS="${JVM_CFLAGS} ${CXXSTD_CXXFLAG}" 49792 49793 fi 49794 if test "x$OPENJDK_TARGET_OS" = xsolaris; then 49795 CFLAGS_JDK="${CFLAGS_JDK} -D__solaris__" 49796 CXXFLAGS_JDK="${CXXFLAGS_JDK} -D__solaris__" 49797 fi 49798 49799 if test "x$OPENJDK_TARGET_OS" = xsolaris; then 49800 CFLAGS_JDK="${CFLAGS_JDK} -D__solaris__" 49801 CXXFLAGS_JDK="${CXXFLAGS_JDK} -D__solaris__" 49802 fi 49803 49804 CFLAGS_JDK="${CFLAGS_JDK} ${EXTRA_CFLAGS}" 49805 CXXFLAGS_JDK="${CXXFLAGS_JDK} ${EXTRA_CXXFLAGS}" 49806 LDFLAGS_JDK="${LDFLAGS_JDK} ${EXTRA_LDFLAGS}" 49807 49808 ############################################################################### 49809 # 49810 # Now setup the CFLAGS and LDFLAGS for the JDK build. 49811 # Later we will also have CFLAGS and LDFLAGS for the hotspot subrepo build. 49812 # 49813 49814 # Setup compiler/platform specific flags into 49815 # CFLAGS_JDK - C Compiler flags 49816 # CXXFLAGS_JDK - C++ Compiler flags 49817 # COMMON_CCXXFLAGS_JDK - common to C and C++ 49818 if test "x$TOOLCHAIN_TYPE" = xgcc; then 49819 JVM_CFLAGS="$JVM_CFLAGS -D_GNU_SOURCE" 49820 JVM_CFLAGS="$JVM_CFLAGS -D_REENTRANT" 49821 JVM_CFLAGS="$JVM_CFLAGS -fcheck-new" 49822 if test "x$OPENJDK_TARGET_CPU" = xx86; then 49823 # Force compatibility with i586 on 32 bit intel platforms. 49824 COMMON_CCXXFLAGS="${COMMON_CCXXFLAGS} -march=i586" 49825 JVM_CFLAGS="$JVM_CFLAGS -march=i586" 49826 fi 49827 COMMON_CCXXFLAGS_JDK="$COMMON_CCXXFLAGS $COMMON_CCXXFLAGS_JDK -Wall -Wextra -Wno-unused -Wno-unused-parameter -Wformat=2 \ 49828 -pipe -D_GNU_SOURCE -D_REENTRANT -D_LARGEFILE64_SOURCE" 49829 case $OPENJDK_TARGET_CPU_ARCH in 49830 arm ) 49831 # on arm we don't prevent gcc to omit frame pointer but do prevent strict aliasing 49832 CFLAGS_JDK="${CFLAGS_JDK} -fno-strict-aliasing" 49833 ;; 49834 ppc ) 49835 # on ppc we don't prevent gcc to omit frame pointer but do prevent strict aliasing 49836 CFLAGS_JDK="${CFLAGS_JDK} -fno-strict-aliasing" 49837 ;; 49838 * ) 49839 COMMON_CCXXFLAGS_JDK="$COMMON_CCXXFLAGS_JDK -fno-omit-frame-pointer" 49840 CFLAGS_JDK="${CFLAGS_JDK} -fno-strict-aliasing" 49841 ;; 49842 esac 49843 49844 49845 49846 49847 49848 49849 49850 49851 49852 49853 49854 49855 49856 49857 49858 49859 49860 49861 49862 49863 49864 49865 49866 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 # Execute function body 49898 49899 # Need to assign to a variable since m4 is blocked from modifying parts in []. 49900 REFERENCE_VERSION=6 49901 49902 if [[ "$REFERENCE_VERSION" =~ (.*\.){3} ]] ; then 49903 as_fn_error $? "Internal error: Cannot compare to 6, only three parts (X.Y.Z) is supported" "$LINENO" 5 49904 fi 49905 49906 if [[ "$REFERENCE_VERSION" =~ [0-9]{6} ]] ; then 49907 as_fn_error $? "Internal error: Cannot compare to 6, only parts < 99999 is supported" "$LINENO" 5 49908 fi 49909 49910 # Version comparison method inspired by http://stackoverflow.com/a/24067243 49911 COMPARABLE_REFERENCE_VERSION=`$AWK -F. '{ printf("%05d%05d%05d\n", $1, $2, $3) }' <<< "$REFERENCE_VERSION"` 49912 49913 if test $COMPARABLE_ACTUAL_VERSION -ge $COMPARABLE_REFERENCE_VERSION ; then 49914 : 49915 49916 # These flags are required for GCC 6 builds as undefined behaviour in OpenJDK code 49917 # runs afoul of the more aggressive versions of these optimisations. 49918 # Notably, value range propagation now assumes that the this pointer of C++ 49919 # member functions is non-null. 49920 NO_DELETE_NULL_POINTER_CHECKS_CFLAG="-fno-delete-null-pointer-checks" 49921 NO_LIFETIME_DSE_CFLAG="-fno-lifetime-dse" 49922 { $as_echo "$as_me:${as_lineno-$LINENO}: GCC >= 6 detected; adding ${NO_DELETE_NULL_POINTER_CHECKS_CFLAG} and ${NO_LIFETIME_DSE_CFLAG}" >&5 49923 $as_echo "$as_me: GCC >= 6 detected; adding ${NO_DELETE_NULL_POINTER_CHECKS_CFLAG} and ${NO_LIFETIME_DSE_CFLAG}" >&6;} 49924 CFLAGS_JDK="$CFLAGS_JDK ${NO_DELETE_NULL_POINTER_CHECKS_CFLAG} ${NO_LIFETIME_DSE_CFLAG}" 49925 JVM_CFLAGS="$JVM_CFLAGS ${NO_DELETE_NULL_POINTER_CHECKS_CFLAG} ${NO_LIFETIME_DSE_CFLAG}" 49926 49927 else 49928 : 49929 49930 fi 49931 49932 49933 49934 49935 49936 49937 49938 49939 49940 49941 49942 49943 49944 49945 elif test "x$TOOLCHAIN_TYPE" = xclang; then 49946 JVM_CFLAGS="$JVM_CFLAGS -D_GNU_SOURCE" 49947 49948 # Restrict the debug information created by Clang to avoid 49949 # too big object files and speed the build up a little bit 49950 # (see http://llvm.org/bugs/show_bug.cgi?id=7554) 49951 JVM_CFLAGS="$JVM_CFLAGS -flimit-debug-info" 49952 if test "x$OPENJDK_TARGET_OS" = xlinux; then 49953 if test "x$OPENJDK_TARGET_CPU" = xx86; then 49954 # Force compatibility with i586 on 32 bit intel platforms. 49955 COMMON_CCXXFLAGS="${COMMON_CCXXFLAGS} -march=i586" 49956 JVM_CFLAGS="$JVM_CFLAGS -march=i586" 49957 fi 49958 JVM_CFLAGS="$JVM_CFLAGS -Wno-sometimes-uninitialized" 49959 COMMON_CCXXFLAGS_JDK="$COMMON_CCXXFLAGS $COMMON_CCXXFLAGS_JDK -Wall -Wextra -Wno-unused -Wno-unused-parameter -Wformat=2 \ 49960 -pipe -D_GNU_SOURCE -D_REENTRANT -D_LARGEFILE64_SOURCE" 49961 case $OPENJDK_TARGET_CPU_ARCH in 49962 ppc ) 49963 # on ppc we don't prevent gcc to omit frame pointer but do prevent strict aliasing 49964 CFLAGS_JDK="${CFLAGS_JDK} -fno-strict-aliasing" 49965 ;; 49966 * ) 49967 COMMON_CCXXFLAGS_JDK="$COMMON_CCXXFLAGS_JDK -fno-omit-frame-pointer" 49968 CFLAGS_JDK="${CFLAGS_JDK} -fno-strict-aliasing" 49969 ;; 49970 esac 49971 fi 49972 elif test "x$TOOLCHAIN_TYPE" = xsolstudio; then 49973 JVM_CFLAGS="$JVM_CFLAGS -DSPARC_WORKS" 49974 COMMON_CCXXFLAGS_JDK="$COMMON_CCXXFLAGS $COMMON_CCXXFLAGS_JDK -DTRACING -DMACRO_MEMSYS_OPS -DBREAKPTS" 49975 if test "x$OPENJDK_TARGET_CPU_ARCH" = xx86; then 49976 COMMON_CCXXFLAGS_JDK="$COMMON_CCXXFLAGS_JDK -DcpuIntel -Di586 -D$OPENJDK_TARGET_CPU_LEGACY_LIB" 49977 fi 49978 49979 CFLAGS_JDK="$CFLAGS_JDK -xc99=%none -xCC -errshort=tags -Xa -v -mt -W0,-noglobal" 49980 CXXFLAGS_JDK="$CXXFLAGS_JDK -errtags=yes +w -mt -features=no%except -DCC_NOEX -norunpath -xnolib" 49981 elif test "x$TOOLCHAIN_TYPE" = xxlc; then 49982 JVM_CFLAGS="$JVM_CFLAGS -D_REENTRANT -D__STDC_FORMAT_MACROS" 49983 CFLAGS_JDK="$CFLAGS_JDK -D_GNU_SOURCE -D_REENTRANT -D_LARGEFILE64_SOURCE -DSTDC" 49984 CXXFLAGS_JDK="$CXXFLAGS_JDK -D_GNU_SOURCE -D_REENTRANT -D_LARGEFILE64_SOURCE -DSTDC" 49985 elif test "x$TOOLCHAIN_TYPE" = xmicrosoft; then 49986 COMMON_CCXXFLAGS_JDK="$COMMON_CCXXFLAGS $COMMON_CCXXFLAGS_JDK \ 49987 -MD -Zc:wchar_t- -W3 -wd4800 \ 49988 -DWIN32_LEAN_AND_MEAN \ 49989 -D_CRT_SECURE_NO_DEPRECATE -D_CRT_NONSTDC_NO_DEPRECATE \ 49990 -D_WINSOCK_DEPRECATED_NO_WARNINGS \ 49991 -DWIN32 -DIAL" 49992 if test "x$OPENJDK_TARGET_CPU" = xx86_64; then 49993 COMMON_CCXXFLAGS_JDK="$COMMON_CCXXFLAGS_JDK -D_AMD64_ -Damd64" 49994 else 49995 COMMON_CCXXFLAGS_JDK="$COMMON_CCXXFLAGS_JDK -D_X86_ -Dx86" 49996 fi 49997 # If building with Visual Studio 2010, we can still use _STATIC_CPPLIB to 49998 # avoid bundling msvcpNNN.dll. Doesn't work with newer versions of visual 49999 # studio. 50000 if test "x$TOOLCHAIN_VERSION" = "x2010"; then 50001 STATIC_CPPLIB_FLAGS="-D_STATIC_CPPLIB -D_DISABLE_DEPRECATE_STATIC_CPPLIB" 50002 COMMON_CCXXFLAGS_JDK="$COMMON_CCXXFLAGS_JDK $STATIC_CPPLIB_FLAGS" 50003 JVM_CFLAGS="$JVM_CFLAGS $STATIC_CPPLIB_FLAGS" 50004 fi 50005 fi 50006 50007 ############################################################################### 50008 50009 # Adjust flags according to debug level. 50010 case $DEBUG_LEVEL in 50011 fastdebug | slowdebug ) 50012 CFLAGS_JDK="$CFLAGS_JDK $CFLAGS_DEBUG_SYMBOLS $CFLAGS_DEBUG_OPTIONS" 50013 CXXFLAGS_JDK="$CXXFLAGS_JDK $CXXFLAGS_DEBUG_SYMBOLS $CXXFLAGS_DEBUG_OPTIONS" 50014 JAVAC_FLAGS="$JAVAC_FLAGS -g" 50015 ;; 50016 release ) 50017 ;; 50018 * ) 50019 as_fn_error $? "Unrecognized \$DEBUG_LEVEL: $DEBUG_LEVEL" "$LINENO" 5 50020 ;; 50021 esac 50022 50023 # Set some common defines. These works for all compilers, but assume 50024 # -D is universally accepted. 50025 50026 # Setup endianness 50027 if test "x$OPENJDK_TARGET_CPU_ENDIAN" = xlittle; then 50028 # The macro _LITTLE_ENDIAN needs to be defined the same to avoid the 50029 # Sun C compiler warning message: warning: macro redefined: _LITTLE_ENDIAN 50030 # (The Solaris X86 system defines this in file /usr/include/sys/isa_defs.h). 50031 # Note: -Dmacro is the same as #define macro 1 50032 # -Dmacro= is the same as #define macro 50033 if test "x$OPENJDK_TARGET_OS" = xsolaris; then 50034 COMMON_CCXXFLAGS_JDK="$COMMON_CCXXFLAGS_JDK -D_LITTLE_ENDIAN=" 50035 else 50036 COMMON_CCXXFLAGS_JDK="$COMMON_CCXXFLAGS_JDK -D_LITTLE_ENDIAN" 50037 fi 50038 else 50039 # Same goes for _BIG_ENDIAN. Do we really need to set *ENDIAN on Solaris if they 50040 # are defined in the system? 50041 if test "x$OPENJDK_TARGET_OS" = xsolaris; then 50042 COMMON_CCXXFLAGS_JDK="$COMMON_CCXXFLAGS_JDK -D_BIG_ENDIAN=" 50043 else 50044 COMMON_CCXXFLAGS_JDK="$COMMON_CCXXFLAGS_JDK -D_BIG_ENDIAN" 50045 fi 50046 fi 50047 50048 # Setup target OS define. Use OS target name but in upper case. 50049 OPENJDK_TARGET_OS_UPPERCASE=`$ECHO $OPENJDK_TARGET_OS | $TR 'abcdefghijklmnopqrstuvwxyz' 'ABCDEFGHIJKLMNOPQRSTUVWXYZ'` 50050 COMMON_CCXXFLAGS_JDK="$COMMON_CCXXFLAGS_JDK -D$OPENJDK_TARGET_OS_UPPERCASE" 50051 50052 # Setup target CPU 50053 COMMON_CCXXFLAGS_JDK="$COMMON_CCXXFLAGS_JDK \ 50054 $OPENJDK_TARGET_ADD_LP64 \ 50055 -DARCH='\"$OPENJDK_TARGET_CPU_LEGACY\"' -D$OPENJDK_TARGET_CPU_LEGACY" 50056 50057 # Setup debug/release defines 50058 if test "x$DEBUG_LEVEL" = xrelease; then 50059 COMMON_CCXXFLAGS_JDK="$COMMON_CCXXFLAGS_JDK -DNDEBUG" 50060 if test "x$OPENJDK_TARGET_OS" = xsolaris; then 50061 COMMON_CCXXFLAGS_JDK="$COMMON_CCXXFLAGS_JDK -DTRIMMED" 50062 fi 50063 else 50064 COMMON_CCXXFLAGS_JDK="$COMMON_CCXXFLAGS_JDK -DDEBUG" 50065 fi 50066 50067 # Set some additional per-OS defines. 50068 if test "x$OPENJDK_TARGET_OS" = xlinux; then 50069 JVM_CFLAGS="$JVM_CFLAGS -DLINUX" 50070 JVM_CFLAGS="$JVM_CFLAGS -pipe -fPIC -fno-rtti -fno-exceptions \ 50071 -fvisibility=hidden -fno-strict-aliasing -fno-omit-frame-pointer" 50072 elif test "x$OPENJDK_TARGET_OS" = xsolaris; then 50073 JVM_CFLAGS="$JVM_CFLAGS -DSOLARIS" 50074 JVM_CFLAGS="$JVM_CFLAGS -template=no%extdef -features=no%split_init \ 50075 -D_Crun_inline_placement -library=%none -KPIC -mt -xwe -features=no%except" 50076 elif test "x$OPENJDK_TARGET_OS" = xmacosx; then 50077 COMMON_CCXXFLAGS_JDK="$COMMON_CCXXFLAGS_JDK -D_ALLBSD_SOURCE -D_DARWIN_UNLIMITED_SELECT" 50078 JVM_CFLAGS="$JVM_CFLAGS -D_ALLBSD_SOURCE" 50079 JVM_CFLAGS="$JVM_CFLAGS -D_DARWIN_C_SOURCE -D_XOPEN_SOURCE" 50080 JVM_CFLAGS="$JVM_CFLAGS -fno-rtti -fno-exceptions -fvisibility=hidden \ 50081 -mno-omit-leaf-frame-pointer -mstack-alignment=16 -pipe -fno-strict-aliasing \ 50082 -DMAC_OS_X_VERSION_MAX_ALLOWED=1070 -mmacosx-version-min=10.7.0 \ 50083 -fno-omit-frame-pointer" 50084 elif test "x$OPENJDK_TARGET_OS" = xaix; then 50085 JVM_CFLAGS="$JVM_CFLAGS -DAIX" 50086 # We may need '-qminimaltoc' or '-qpic=large -bbigtoc' if the TOC overflows. 50087 JVM_CFLAGS="$JVM_CFLAGS -qtune=balanced \ 50088 -qalias=noansi -qstrict -qtls=default -qlanglvl=c99vla \ 50089 -qlanglvl=noredefmac -qnortti -qnoeh -qignerrno" 50090 elif test "x$OPENJDK_TARGET_OS" = xbsd; then 50091 COMMON_CCXXFLAGS_JDK="$COMMON_CCXXFLAGS_JDK -D_ALLBSD_SOURCE" 50092 elif test "x$OPENJDK_TARGET_OS" = xwindows; then 50093 JVM_CFLAGS="$JVM_CFLAGS -D_WINDOWS -DWIN32 -D_JNI_IMPLEMENTATION_" 50094 JVM_CFLAGS="$JVM_CFLAGS -nologo -W3 -MD -MP" 50095 fi 50096 50097 # Set some additional per-CPU defines. 50098 if test "x$OPENJDK_TARGET_OS-$OPENJDK_TARGET_CPU" = xwindows-x86; then 50099 JVM_CFLAGS="$JVM_CFLAGS -arch:IA32" 50100 elif test "x$OPENJDK_TARGET_CPU" = xsparcv9; then 50101 JVM_CFLAGS="$JVM_CFLAGS -xarch=sparc" 50102 elif test "x$OPENJDK_TARGET_CPU" = xppc64; then 50103 if test "x$OPENJDK_TARGET_OS" = xlinux; then 50104 JVM_CFLAGS="$JVM_CFLAGS -minsert-sched-nops=regroup_exact -mno-multiple -mno-string" 50105 # fixes `relocation truncated to fit' error for gcc 4.1. 50106 JVM_CFLAGS="$JVM_CFLAGS -mminimal-toc" 50107 # Use ppc64 instructions, but schedule for power5 50108 JVM_CFLAGS="$JVM_CFLAGS -mcpu=powerpc64 -mtune=power5" 50109 elif test "x$OPENJDK_TARGET_OS" = xaix; then 50110 JVM_CFLAGS="$JVM_CFLAGS -qarch=ppc64" 50111 fi 50112 elif test "x$OPENJDK_TARGET_CPU" = xppc64le; then 50113 if test "x$OPENJDK_TARGET_OS" = xlinux; then 50114 JVM_CFLAGS="$JVM_CFLAGS -minsert-sched-nops=regroup_exact -mno-multiple -mno-string" 50115 # Little endian machine uses ELFv2 ABI. 50116 JVM_CFLAGS="$JVM_CFLAGS -DABI_ELFv2" 50117 # Use Power8, this is the first CPU to support PPC64 LE with ELFv2 ABI. 50118 JVM_CFLAGS="$JVM_CFLAGS -mcpu=power7 -mtune=power8" 50119 fi 50120 fi 50121 50122 if test "x$OPENJDK_TARGET_CPU_ENDIAN" = xlittle; then 50123 JVM_CFLAGS="$JVM_CFLAGS -DVM_LITTLE_ENDIAN" 50124 fi 50125 50126 if test "x$OPENJDK_TARGET_CPU_BITS" = x64; then 50127 if test "x$OPENJDK_TARGET_OS" != xsolaris && test "x$OPENJDK_TARGET_OS" != xaix; then 50128 # Solaris does not have _LP64=1 in the old build. 50129 # xlc on AIX defines _LP64=1 by default and issues a warning if we redefine it. 50130 JVM_CFLAGS="$JVM_CFLAGS -D_LP64=1" 50131 fi 50132 fi 50133 50134 # Set JVM_CFLAGS warning handling 50135 if test "x$OPENJDK_TARGET_OS" = xlinux; then 50136 JVM_CFLAGS="$JVM_CFLAGS -Wpointer-arith -Wsign-compare -Wunused-function \ 50137 -Wunused-value -Woverloaded-virtual" 50138 50139 if test "x$TOOLCHAIN_TYPE" = xgcc; then 50140 50141 50142 50143 50144 50145 50146 50147 50148 50149 50150 50151 50152 50153 50154 50155 50156 50157 50158 50159 50160 50161 50162 50163 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 # Execute function body 50195 50196 # Need to assign to a variable since m4 is blocked from modifying parts in []. 50197 REFERENCE_VERSION=4.8 50198 50199 if [[ "$REFERENCE_VERSION" =~ (.*\.){3} ]] ; then 50200 as_fn_error $? "Internal error: Cannot compare to 4.8, only three parts (X.Y.Z) is supported" "$LINENO" 5 50201 fi 50202 50203 if [[ "$REFERENCE_VERSION" =~ [0-9]{6} ]] ; then 50204 as_fn_error $? "Internal error: Cannot compare to 4.8, only parts < 99999 is supported" "$LINENO" 5 50205 fi 50206 50207 # Version comparison method inspired by http://stackoverflow.com/a/24067243 50208 COMPARABLE_REFERENCE_VERSION=`$AWK -F. '{ printf("%05d%05d%05d\n", $1, $2, $3) }' <<< "$REFERENCE_VERSION"` 50209 50210 if test $COMPARABLE_ACTUAL_VERSION -ge $COMPARABLE_REFERENCE_VERSION ; then 50211 : 50212 50213 # These flags either do not work or give spurious warnings prior to gcc 4.8. 50214 JVM_CFLAGS="$JVM_CFLAGS -Wno-format-zero-length -Wtype-limits -Wuninitialized" 50215 50216 50217 else 50218 : 50219 50220 fi 50221 50222 50223 50224 50225 50226 50227 50228 50229 50230 50231 50232 50233 50234 50235 fi 50236 if ! [[ " $JVM_VARIANTS " =~ " zero " ]] && ! [[ " $JVM_VARIANTS " =~ " zeroshark " ]] ; then 50237 # Non-zero builds have stricter warnings 50238 JVM_CFLAGS="$JVM_CFLAGS -Wreturn-type -Wundef -Wformat=2" 50239 else 50240 if test "x$TOOLCHAIN_TYPE" = xclang; then 50241 # Some versions of llvm do not like -Wundef 50242 JVM_CFLAGS="$JVM_CFLAGS -Wno-undef" 50243 fi 50244 fi 50245 elif test "x$OPENJDK_TARGET_OS" = xmacosx; then 50246 JVM_CFLAGS="$JVM_CFLAGS -Wno-deprecated -Wpointer-arith \ 50247 -Wsign-compare -Wundef -Wunused-function -Wformat=2" 50248 fi 50249 50250 # Additional macosx handling 50251 if test "x$OPENJDK_TARGET_OS" = xmacosx; then 50252 # Setting these parameters makes it an error to link to macosx APIs that are 50253 # newer than the given OS version and makes the linked binaries compatible 50254 # even if built on a newer version of the OS. 50255 # The expected format is X.Y.Z 50256 MACOSX_VERSION_MIN=10.7.0 50257 50258 50259 # The macro takes the version with no dots, ex: 1070 50260 # Let the flags variables get resolved in make for easier override on make 50261 # command line. 50262 COMMON_CCXXFLAGS_JDK="$COMMON_CCXXFLAGS_JDK -DMAC_OS_X_VERSION_MAX_ALLOWED=\$(subst .,,\$(MACOSX_VERSION_MIN)) -mmacosx-version-min=\$(MACOSX_VERSION_MIN)" 50263 LDFLAGS_JDK="$LDFLAGS_JDK -mmacosx-version-min=\$(MACOSX_VERSION_MIN)" 50264 fi 50265 50266 # Setup some hard coded includes 50267 COMMON_CCXXFLAGS_JDK="$COMMON_CCXXFLAGS_JDK \ 50268 -I${JDK_TOPDIR}/src/java.base/share/native/include \ 50269 -I${JDK_TOPDIR}/src/java.base/$OPENJDK_TARGET_OS/native/include \ 50270 -I${JDK_TOPDIR}/src/java.base/$OPENJDK_TARGET_OS_TYPE/native/include \ 50271 -I${JDK_TOPDIR}/src/java.base/share/native/libjava \ 50272 -I${JDK_TOPDIR}/src/java.base/$OPENJDK_TARGET_OS_TYPE/native/libjava" 50273 50274 # The shared libraries are compiled using the picflag. 50275 CFLAGS_JDKLIB="$COMMON_CCXXFLAGS_JDK \ 50276 $CFLAGS_JDK $EXTRA_CFLAGS_JDK $PICFLAG $CFLAGS_JDKLIB_EXTRA" 50277 CXXFLAGS_JDKLIB="$COMMON_CCXXFLAGS_JDK \ 50278 $CXXFLAGS_JDK $EXTRA_CXXFLAGS_JDK $PICFLAG $CXXFLAGS_JDKLIB_EXTRA" 50279 50280 # Executable flags 50281 CFLAGS_JDKEXE="$COMMON_CCXXFLAGS_JDK $CFLAGS_JDK $EXTRA_CFLAGS_JDK" 50282 CXXFLAGS_JDKEXE="$COMMON_CCXXFLAGS_JDK $CXXFLAGS_JDK $EXTRA_CXXFLAGS_JDK" 50283 50284 50285 50286 50287 50288 50289 # Setup LDFLAGS et al. 50290 # 50291 50292 if test "x$TOOLCHAIN_TYPE" = xmicrosoft; then 50293 LDFLAGS_MICROSOFT="-nologo -opt:ref" 50294 LDFLAGS_JDK="$LDFLAGS_JDK $LDFLAGS_MICROSOFT -incremental:no" 50295 JVM_LDFLAGS="$JVM_LDFLAGS $LDFLAGS_MICROSOFT -opt:icf,8 -subsystem:windows -base:0x8000000" 50296 if test "x$OPENJDK_TARGET_CPU_BITS" = "x32"; then 50297 LDFLAGS_SAFESH="-safeseh" 50298 LDFLAGS_JDK="$LDFLAGS_JDK $LDFLAGS_SAFESH" 50299 JVM_LDFLAGS="$JVM_LDFLAGS $LDFLAGS_SAFESH" 50300 # NOTE: Old build added -machine. Probably not needed. 50301 JVM_LDFLAGS="$JVM_LDFLAGS -machine:I386" 50302 else 50303 JVM_LDFLAGS="$JVM_LDFLAGS -machine:AMD64" 50304 fi 50305 elif test "x$TOOLCHAIN_TYPE" = xclang; then 50306 JVM_LDFLAGS="$JVM_LDFLAGS -mno-omit-leaf-frame-pointer -mstack-alignment=16 -stdlib=libstdc++ -fPIC" 50307 if test "x$OPENJDK_TARGET_OS" = xmacosx; then 50308 # FIXME: We should really generalize SET_SHARED_LIBRARY_ORIGIN instead. 50309 JVM_LDFLAGS="$JVM_LDFLAGS -Wl,-rpath,@loader_path/. -Wl,-rpath,@loader_path/.." 50310 fi 50311 elif test "x$TOOLCHAIN_TYPE" = xgcc; then 50312 # If this is a --hash-style=gnu system, use --hash-style=both, why? 50313 # We have previously set HAS_GNU_HASH if this is the case 50314 if test -n "$HAS_GNU_HASH"; then 50315 LDFLAGS_HASH_STYLE="-Wl,--hash-style=both" 50316 LDFLAGS_JDK="${LDFLAGS_JDK} $LDFLAGS_HASH_STYLE" 50317 JVM_LDFLAGS="$JVM_LDFLAGS $LDFLAGS_HASH_STYLE" 50318 fi 50319 if test "x$OPENJDK_TARGET_OS" = xmacosx; then 50320 JVM_LDFLAGS="$JVM_LDFLAGS -Wl,-rpath,@loader_path/. -Wl,-rpath,@loader_path/.." 50321 fi 50322 if test "x$OPENJDK_TARGET_OS" = xlinux; then 50323 # And since we now know that the linker is gnu, then add -z defs, to forbid 50324 # undefined symbols in object files. 50325 LDFLAGS_NO_UNDEF_SYM="-Wl,-z,defs" 50326 LDFLAGS_JDK="${LDFLAGS_JDK} $LDFLAGS_NO_UNDEF_SYM" 50327 JVM_LDFLAGS="$JVM_LDFLAGS $LDFLAGS_NO_UNDEF_SYM" 50328 LDFLAGS_NO_EXEC_STACK="-Wl,-z,noexecstack" 50329 JVM_LDFLAGS="$JVM_LDFLAGS $LDFLAGS_NO_EXEC_STACK" 50330 if test "x$OPENJDK_TARGET_CPU" = xx86; then 50331 JVM_LDFLAGS="$JVM_LDFLAGS -march=i586" 50332 fi 50333 case $DEBUG_LEVEL in 50334 release ) 50335 # tell linker to optimize libraries. 50336 # Should this be supplied to the OSS linker as well? 50337 LDFLAGS_DEBUGLEVEL_release="-Wl,-O1" 50338 LDFLAGS_JDK="${LDFLAGS_JDK} $LDFLAGS_DEBUGLEVEL_release" 50339 JVM_LDFLAGS="$JVM_LDFLAGS $LDFLAGS_DEBUGLEVEL_release" 50340 if test "x$HAS_LINKER_RELRO" = "xtrue"; then 50341 JVM_LDFLAGS="$JVM_LDFLAGS $LINKER_RELRO_FLAG" 50342 fi 50343 ;; 50344 slowdebug ) 50345 # Hotspot always let the linker optimize 50346 JVM_LDFLAGS="$JVM_LDFLAGS -Wl,-O1" 50347 if test "x$HAS_LINKER_NOW" = "xtrue"; then 50348 # do relocations at load 50349 LDFLAGS_JDK="$LDFLAGS_JDK $LINKER_NOW_FLAG" 50350 LDFLAGS_CXX_JDK="$LDFLAGS_CXX_JDK $LINKER_NOW_FLAG" 50351 JVM_LDFLAGS="$JVM_LDFLAGS $LINKER_NOW_FLAG" 50352 fi 50353 if test "x$HAS_LINKER_RELRO" = "xtrue"; then 50354 # mark relocations read only 50355 LDFLAGS_JDK="$LDFLAGS_JDK $LINKER_RELRO_FLAG" 50356 LDFLAGS_CXX_JDK="$LDFLAGS_CXX_JDK $LINKER_RELRO_FLAG" 50357 JVM_LDFLAGS="$JVM_LDFLAGS $LINKER_RELRO_FLAG" 50358 fi 50359 ;; 50360 fastdebug ) 50361 # Hotspot always let the linker optimize 50362 JVM_LDFLAGS="$JVM_LDFLAGS -Wl,-O1" 50363 if test "x$HAS_LINKER_RELRO" = "xtrue"; then 50364 # mark relocations read only 50365 LDFLAGS_JDK="$LDFLAGS_JDK $LINKER_RELRO_FLAG" 50366 LDFLAGS_CXX_JDK="$LDFLAGS_CXX_JDK $LINKER_RELRO_FLAG" 50367 JVM_LDFLAGS="$JVM_LDFLAGS $LINKER_RELRO_FLAG" 50368 fi 50369 ;; 50370 * ) 50371 as_fn_error $? "Unrecognized \$DEBUG_LEVEL: $DEBUG_LEVEL" "$LINENO" 5 50372 ;; 50373 esac 50374 fi 50375 elif test "x$TOOLCHAIN_TYPE" = xsolstudio; then 50376 LDFLAGS_SOLSTUDIO="-Wl,-z,defs" 50377 LDFLAGS_JDK="$LDFLAGS_JDK $LDFLAGS_SOLSTUDIO -ztext" 50378 LDFLAGS_CXX_SOLSTUDIO="-norunpath" 50379 LDFLAGS_CXX_JDK="$LDFLAGS_CXX_JDK $LDFLAGS_CXX_SOLSTUDIO -xnolib" 50380 JVM_LDFLAGS="$JVM_LDFLAGS $LDFLAGS_SOLSTUDIO -library=%none -mt $LDFLAGS_CXX_SOLSTUDIO -z noversion" 50381 if test "x$OPENJDK_TARGET_CPU_ARCH" = "xsparc"; then 50382 JVM_LDFLAGS="$JVM_LDFLAGS -xarch=sparc" 50383 fi 50384 elif test "x$TOOLCHAIN_TYPE" = xxlc; then 50385 LDFLAGS_XLC="-b64 -brtl -bnolibpath -bexpall -bernotok" 50386 LDFLAGS_JDK="${LDFLAGS_JDK} $LDFLAGS_XLC" 50387 JVM_LDFLAGS="$JVM_LDFLAGS $LDFLAGS_XLC" 50388 fi 50389 50390 # Customize LDFLAGS for executables 50391 50392 LDFLAGS_JDKEXE="${LDFLAGS_JDK}" 50393 50394 if test "x$TOOLCHAIN_TYPE" = xmicrosoft; then 50395 if test "x$OPENJDK_TARGET_CPU_BITS" = "x64"; then 50396 LDFLAGS_STACK_SIZE=1048576 50397 else 50398 LDFLAGS_STACK_SIZE=327680 50399 fi 50400 LDFLAGS_JDKEXE="${LDFLAGS_JDKEXE} /STACK:$LDFLAGS_STACK_SIZE" 50401 elif test "x$OPENJDK_TARGET_OS" = xlinux; then 50402 LDFLAGS_JDKEXE="$LDFLAGS_JDKEXE -Wl,--allow-shlib-undefined" 50403 fi 50404 50405 LDFLAGS_JDKEXE="${LDFLAGS_JDKEXE} ${EXTRA_LDFLAGS_JDK}" 50406 50407 # Customize LDFLAGS for libs 50408 LDFLAGS_JDKLIB="${LDFLAGS_JDK}" 50409 50410 LDFLAGS_JDKLIB="${LDFLAGS_JDKLIB} ${SHARED_LIBRARY_FLAGS}" 50411 if test "x$TOOLCHAIN_TYPE" = xmicrosoft; then 50412 JAVA_BASE_LDFLAGS="${JAVA_BASE_LDFLAGS} \ 50413 -libpath:${OUTPUT_ROOT}/support/modules_libs/java.base" 50414 JDKLIB_LIBS="" 50415 else 50416 JAVA_BASE_LDFLAGS="${JAVA_BASE_LDFLAGS} \ 50417 -L\$(SUPPORT_OUTPUTDIR)/modules_libs/java.base\$(OPENJDK_TARGET_CPU_LIBDIR)" 50418 50419 if test "xTARGET" = "xTARGET"; then 50420 # On some platforms (mac) the linker warns about non existing -L dirs. 50421 # Add server first if available. Linking aginst client does not always produce the same results. 50422 # Only add client/minimal dir if client/minimal is being built. 50423 # Default to server for other variants. 50424 if [[ " $JVM_VARIANTS " =~ " server " ]] ; then 50425 JAVA_BASE_LDFLAGS="${JAVA_BASE_LDFLAGS} -L\$(SUPPORT_OUTPUTDIR)/modules_libs/java.base\$(OPENJDK_TARGET_CPU_LIBDIR)/server" 50426 elif [[ " $JVM_VARIANTS " =~ " client " ]] ; then 50427 JAVA_BASE_LDFLAGS="${JAVA_BASE_LDFLAGS} -L\$(SUPPORT_OUTPUTDIR)/modules_libs/java.base\$(OPENJDK_TARGET_CPU_LIBDIR)/client" 50428 elif [[ " $JVM_VARIANTS " =~ " minimal " ]] ; then 50429 JAVA_BASE_LDFLAGS="${JAVA_BASE_LDFLAGS} -L\$(SUPPORT_OUTPUTDIR)/modules_libs/java.base\$(OPENJDK_TARGET_CPU_LIBDIR)/minimal" 50430 else 50431 JAVA_BASE_LDFLAGS="${JAVA_BASE_LDFLAGS} -L\$(SUPPORT_OUTPUTDIR)/modules_libs/java.base\$(OPENJDK_TARGET_CPU_LIBDIR)/server" 50432 fi 50433 elif test "xTARGET" = "xBUILD"; then 50434 # When building a buildjdk, it's always only the server variant 50435 JAVA_BASE_LDFLAGS="${JAVA_BASE_LDFLAGS} \ 50436 -L\$(SUPPORT_OUTPUTDIR)/modules_libs/java.base\$(OPENJDK_TARGET_CPU_LIBDIR)/server" 50437 fi 50438 50439 JDKLIB_LIBS="-ljava -ljvm" 50440 if test "x$TOOLCHAIN_TYPE" = xsolstudio; then 50441 JDKLIB_LIBS="$JDKLIB_LIBS -lc" 50442 fi 50443 50444 fi 50445 50446 LDFLAGS_JDKLIB="${LDFLAGS_JDKLIB} ${JAVA_BASE_LDFLAGS}" 50447 50448 # Set JVM_LIBS (per os) 50449 if test "x$OPENJDK_TARGET_OS" = xlinux; then 50450 JVM_LIBS="$JVM_LIBS -lm -ldl -lpthread" 50451 elif test "x$OPENJDK_TARGET_OS" = xsolaris; then 50452 # FIXME: This hard-coded path is not really proper. 50453 if test "x$OPENJDK_TARGET_CPU" = xx86_64; then 50454 SOLARIS_LIBM_LIBS="/usr/lib/amd64/libm.so.1" 50455 elif test "x$OPENJDK_TARGET_CPU" = xsparcv9; then 50456 SOLARIS_LIBM_LIBS="/usr/lib/sparcv9/libm.so.1" 50457 fi 50458 JVM_LIBS="$JVM_LIBS -lsocket -lsched -ldl $SOLARIS_LIBM_LIBS -lCrun \ 50459 -lthread -ldoor -lc -ldemangle -lnsl -lkstat -lrt" 50460 elif test "x$OPENJDK_TARGET_OS" = xmacosx; then 50461 JVM_LIBS="$JVM_LIBS -lm" 50462 elif test "x$OPENJDK_TARGET_OS" = xaix; then 50463 JVM_LIBS="$JVM_LIBS -Wl,-lC_r -lm -ldl -lpthread" 50464 elif test "x$OPENJDK_TARGET_OS" = xbsd; then 50465 JVM_LIBS="$JVM_LIBS -lm" 50466 elif test "x$OPENJDK_TARGET_OS" = xwindows; then 50467 JVM_LIBS="$JVM_LIBS kernel32.lib user32.lib gdi32.lib winspool.lib \ 50468 comdlg32.lib advapi32.lib shell32.lib ole32.lib oleaut32.lib uuid.lib \ 50469 wsock32.lib winmm.lib version.lib psapi.lib" 50470 fi 50471 50472 # Set JVM_ASFLAGS 50473 if test "x$OPENJDK_TARGET_OS" = xlinux; then 50474 if test "x$OPENJDK_TARGET_CPU" = xx86; then 50475 JVM_ASFLAGS="$JVM_ASFLAGS -march=i586" 50476 fi 50477 elif test "x$OPENJDK_TARGET_OS" = xmacosx; then 50478 JVM_ASFLAGS="$JVM_ASFLAGS -x assembler-with-cpp -mno-omit-leaf-frame-pointer -mstack-alignment=16" 50479 fi 50480 50481 LDFLAGS_JDKLIB="${LDFLAGS_JDKLIB} ${EXTRA_LDFLAGS_JDK}" 50482 50483 50484 50485 50486 50487 50488 50489 50490 50491 50492 50493 50494 50495 50496 50497 # Special extras... 50498 if test "x$TOOLCHAIN_TYPE" = xsolstudio; then 50499 if test "x$OPENJDK_BUILD_CPU_ARCH" = "xsparc"; then 50500 OPENJDK_BUILD_CFLAGS_JDKLIB_EXTRA="${OPENJDK_BUILD_CFLAGS_JDKLIB_EXTRA} -xregs=no%appl" 50501 OPENJDK_BUILD_CXXFLAGS_JDKLIB_EXTRA="${OPENJDK_BUILD_CXXFLAGS_JDKLIB_EXTRA} -xregs=no%appl" 50502 fi 50503 OPENJDK_BUILD_CFLAGS_JDKLIB_EXTRA="${OPENJDK_BUILD_CFLAGS_JDKLIB_EXTRA} -errtags=yes -errfmt" 50504 OPENJDK_BUILD_CXXFLAGS_JDKLIB_EXTRA="${OPENJDK_BUILD_CXXFLAGS_JDKLIB_EXTRA} -errtags=yes -errfmt" 50505 elif test "x$TOOLCHAIN_TYPE" = xxlc; then 50506 OPENJDK_BUILD_CFLAGS_JDK="${OPENJDK_BUILD_CFLAGS_JDK} -qchars=signed -qfullpath -qsaveopt" 50507 OPENJDK_BUILD_CXXFLAGS_JDK="${OPENJDK_BUILD_CXXFLAGS_JDK} -qchars=signed -qfullpath -qsaveopt" 50508 elif test "x$TOOLCHAIN_TYPE" = xgcc; then 50509 OPENJDK_BUILD_CXXSTD_CXXFLAG="-std=gnu++98" 50510 50511 50512 50513 50514 50515 50516 50517 50518 50519 50520 50521 50522 50523 50524 50525 50526 50527 50528 50529 50530 50531 50532 50533 50534 50535 50536 50537 50538 50539 50540 50541 50542 50543 50544 50545 50546 50547 50548 50549 50550 50551 50552 # Execute function body 50553 50554 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if the C++ compiler supports \"$OPENJDK_BUILD_CXXSTD_CXXFLAG -Werror\"" >&5 50555 $as_echo_n "checking if the C++ compiler supports \"$OPENJDK_BUILD_CXXSTD_CXXFLAG -Werror\"... " >&6; } 50556 supports=yes 50557 50558 saved_cxxflags="$CXXFLAGS" 50559 CXXFLAGS="$CXXFLAG $OPENJDK_BUILD_CXXSTD_CXXFLAG -Werror" 50560 ac_ext=cpp 50561 ac_cpp='$CXXCPP $CPPFLAGS' 50562 ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5' 50563 ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' 50564 ac_compiler_gnu=$ac_cv_cxx_compiler_gnu 50565 50566 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 50567 /* end confdefs.h. */ 50568 int i; 50569 _ACEOF 50570 if ac_fn_cxx_try_compile "$LINENO"; then : 50571 50572 else 50573 supports=no 50574 fi 50575 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext 50576 ac_ext=cpp 50577 ac_cpp='$CXXCPP $CPPFLAGS' 50578 ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5' 50579 ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' 50580 ac_compiler_gnu=$ac_cv_cxx_compiler_gnu 50581 50582 CXXFLAGS="$saved_cxxflags" 50583 50584 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $supports" >&5 50585 $as_echo "$supports" >&6; } 50586 if test "x$supports" = "xyes" ; then 50587 : 50588 50589 else 50590 : 50591 OPENJDK_BUILD_CXXSTD_CXXFLAG="" 50592 fi 50593 50594 50595 50596 50597 50598 50599 50600 50601 50602 50603 50604 50605 OPENJDK_BUILD_CXXFLAGS_JDK="${OPENJDK_BUILD_CXXFLAGS_JDK} ${OPENJDK_BUILD_CXXSTD_CXXFLAG}" 50606 OPENJDK_BUILD_JVM_CFLAGS="${OPENJDK_BUILD_JVM_CFLAGS} ${OPENJDK_BUILD_CXXSTD_CXXFLAG}" 50607 50608 fi 50609 if test "x$OPENJDK_TARGET_OS" = xsolaris; then 50610 OPENJDK_BUILD_CFLAGS_JDK="${OPENJDK_BUILD_CFLAGS_JDK} -D__solaris__" 50611 OPENJDK_BUILD_CXXFLAGS_JDK="${OPENJDK_BUILD_CXXFLAGS_JDK} -D__solaris__" 50612 fi 50613 50614 if test "x$OPENJDK_TARGET_OS" = xsolaris; then 50615 OPENJDK_BUILD_CFLAGS_JDK="${OPENJDK_BUILD_CFLAGS_JDK} -D__solaris__" 50616 OPENJDK_BUILD_CXXFLAGS_JDK="${OPENJDK_BUILD_CXXFLAGS_JDK} -D__solaris__" 50617 fi 50618 50619 OPENJDK_BUILD_CFLAGS_JDK="${OPENJDK_BUILD_CFLAGS_JDK} ${OPENJDK_BUILD_EXTRA_CFLAGS}" 50620 OPENJDK_BUILD_CXXFLAGS_JDK="${OPENJDK_BUILD_CXXFLAGS_JDK} ${OPENJDK_BUILD_EXTRA_CXXFLAGS}" 50621 OPENJDK_BUILD_LDFLAGS_JDK="${OPENJDK_BUILD_LDFLAGS_JDK} ${OPENJDK_BUILD_EXTRA_LDFLAGS}" 50622 50623 ############################################################################### 50624 # 50625 # Now setup the CFLAGS and LDFLAGS for the JDK build. 50626 # Later we will also have CFLAGS and LDFLAGS for the hotspot subrepo build. 50627 # 50628 50629 # Setup compiler/platform specific flags into 50630 # OPENJDK_BUILD_CFLAGS_JDK - C Compiler flags 50631 # OPENJDK_BUILD_CXXFLAGS_JDK - C++ Compiler flags 50632 # OPENJDK_BUILD_COMMON_CCXXFLAGS_JDK - common to C and C++ 50633 if test "x$TOOLCHAIN_TYPE" = xgcc; then 50634 OPENJDK_BUILD_JVM_CFLAGS="$OPENJDK_BUILD_JVM_CFLAGS -D_GNU_SOURCE" 50635 OPENJDK_BUILD_JVM_CFLAGS="$OPENJDK_BUILD_JVM_CFLAGS -D_REENTRANT" 50636 OPENJDK_BUILD_JVM_CFLAGS="$OPENJDK_BUILD_JVM_CFLAGS -fcheck-new" 50637 if test "x$OPENJDK_BUILD_CPU" = xx86; then 50638 # Force compatibility with i586 on 32 bit intel platforms. 50639 OPENJDK_BUILD_COMMON_CCXXFLAGS="${OPENJDK_BUILD_COMMON_CCXXFLAGS} -march=i586" 50640 OPENJDK_BUILD_JVM_CFLAGS="$OPENJDK_BUILD_JVM_CFLAGS -march=i586" 50641 fi 50642 OPENJDK_BUILD_COMMON_CCXXFLAGS_JDK="$OPENJDK_BUILD_COMMON_CCXXFLAGS $OPENJDK_BUILD_COMMON_CCXXFLAGS_JDK -Wall -Wextra -Wno-unused -Wno-unused-parameter -Wformat=2 \ 50643 -pipe -D_GNU_SOURCE -D_REENTRANT -D_LARGEFILE64_SOURCE" 50644 case $OPENJDK_BUILD_CPU_ARCH in 50645 arm ) 50646 # on arm we don't prevent gcc to omit frame pointer but do prevent strict aliasing 50647 OPENJDK_BUILD_CFLAGS_JDK="${OPENJDK_BUILD_CFLAGS_JDK} -fno-strict-aliasing" 50648 ;; 50649 ppc ) 50650 # on ppc we don't prevent gcc to omit frame pointer but do prevent strict aliasing 50651 OPENJDK_BUILD_CFLAGS_JDK="${OPENJDK_BUILD_CFLAGS_JDK} -fno-strict-aliasing" 50652 ;; 50653 * ) 50654 OPENJDK_BUILD_COMMON_CCXXFLAGS_JDK="$OPENJDK_BUILD_COMMON_CCXXFLAGS_JDK -fno-omit-frame-pointer" 50655 OPENJDK_BUILD_CFLAGS_JDK="${OPENJDK_BUILD_CFLAGS_JDK} -fno-strict-aliasing" 50656 ;; 50657 esac 50658 50659 50660 50661 50662 50663 50664 50665 50666 50667 50668 50669 50670 50671 50672 50673 50674 50675 50676 50677 50678 50679 50680 50681 50682 50683 50684 50685 50686 50687 50688 50689 50690 50691 50692 50693 50694 50695 50696 50697 50698 50699 50700 50701 50702 50703 50704 50705 50706 50707 50708 50709 50710 50711 50712 # Execute function body 50713 50714 # Need to assign to a variable since m4 is blocked from modifying parts in []. 50715 REFERENCE_VERSION=6 50716 50717 if [[ "$REFERENCE_VERSION" =~ (.*\.){3} ]] ; then 50718 as_fn_error $? "Internal error: Cannot compare to 6, only three parts (X.Y.Z) is supported" "$LINENO" 5 50719 fi 50720 50721 if [[ "$REFERENCE_VERSION" =~ [0-9]{6} ]] ; then 50722 as_fn_error $? "Internal error: Cannot compare to 6, only parts < 99999 is supported" "$LINENO" 5 50723 fi 50724 50725 # Version comparison method inspired by http://stackoverflow.com/a/24067243 50726 COMPARABLE_REFERENCE_VERSION=`$AWK -F. '{ printf("%05d%05d%05d\n", $1, $2, $3) }' <<< "$REFERENCE_VERSION"` 50727 50728 if test $OPENJDK_BUILD_COMPARABLE_ACTUAL_VERSION -ge $COMPARABLE_REFERENCE_VERSION ; then 50729 : 50730 50731 # These flags are required for GCC 6 builds as undefined behaviour in OpenJDK code 50732 # runs afoul of the more aggressive versions of these optimisations. 50733 # Notably, value range propagation now assumes that the this pointer of C++ 50734 # member functions is non-null. 50735 NO_DELETE_NULL_POINTER_CHECKS_CFLAG="-fno-delete-null-pointer-checks" 50736 NO_LIFETIME_DSE_CFLAG="-fno-lifetime-dse" 50737 { $as_echo "$as_me:${as_lineno-$LINENO}: GCC >= 6 detected; adding ${NO_DELETE_NULL_POINTER_CHECKS_CFLAG} and ${NO_LIFETIME_DSE_CFLAG}" >&5 50738 $as_echo "$as_me: GCC >= 6 detected; adding ${NO_DELETE_NULL_POINTER_CHECKS_CFLAG} and ${NO_LIFETIME_DSE_CFLAG}" >&6;} 50739 OPENJDK_BUILD_CFLAGS_JDK="$OPENJDK_BUILD_CFLAGS_JDK ${NO_DELETE_NULL_POINTER_CHECKS_CFLAG} ${NO_LIFETIME_DSE_CFLAG}" 50740 OPENJDK_BUILD_JVM_CFLAGS="$OPENJDK_BUILD_JVM_CFLAGS ${NO_DELETE_NULL_POINTER_CHECKS_CFLAG} ${NO_LIFETIME_DSE_CFLAG}" 50741 50742 else 50743 : 50744 50745 fi 50746 50747 50748 50749 50750 50751 50752 50753 50754 50755 50756 50757 50758 50759 50760 elif test "x$TOOLCHAIN_TYPE" = xclang; then 50761 OPENJDK_BUILD_JVM_CFLAGS="$OPENJDK_BUILD_JVM_CFLAGS -D_GNU_SOURCE" 50762 50763 # Restrict the debug information created by Clang to avoid 50764 # too big object files and speed the build up a little bit 50765 # (see http://llvm.org/bugs/show_bug.cgi?id=7554) 50766 OPENJDK_BUILD_JVM_CFLAGS="$OPENJDK_BUILD_JVM_CFLAGS -flimit-debug-info" 50767 if test "x$OPENJDK_BUILD_OS" = xlinux; then 50768 if test "x$OPENJDK_BUILD_CPU" = xx86; then 50769 # Force compatibility with i586 on 32 bit intel platforms. 50770 OPENJDK_BUILD_COMMON_CCXXFLAGS="${OPENJDK_BUILD_COMMON_CCXXFLAGS} -march=i586" 50771 OPENJDK_BUILD_JVM_CFLAGS="$OPENJDK_BUILD_JVM_CFLAGS -march=i586" 50772 fi 50773 OPENJDK_BUILD_JVM_CFLAGS="$OPENJDK_BUILD_JVM_CFLAGS -Wno-sometimes-uninitialized" 50774 OPENJDK_BUILD_COMMON_CCXXFLAGS_JDK="$OPENJDK_BUILD_COMMON_CCXXFLAGS $OPENJDK_BUILD_COMMON_CCXXFLAGS_JDK -Wall -Wextra -Wno-unused -Wno-unused-parameter -Wformat=2 \ 50775 -pipe -D_GNU_SOURCE -D_REENTRANT -D_LARGEFILE64_SOURCE" 50776 case $OPENJDK_BUILD_CPU_ARCH in 50777 ppc ) 50778 # on ppc we don't prevent gcc to omit frame pointer but do prevent strict aliasing 50779 OPENJDK_BUILD_CFLAGS_JDK="${OPENJDK_BUILD_CFLAGS_JDK} -fno-strict-aliasing" 50780 ;; 50781 * ) 50782 OPENJDK_BUILD_COMMON_CCXXFLAGS_JDK="$OPENJDK_BUILD_COMMON_CCXXFLAGS_JDK -fno-omit-frame-pointer" 50783 OPENJDK_BUILD_CFLAGS_JDK="${OPENJDK_BUILD_CFLAGS_JDK} -fno-strict-aliasing" 50784 ;; 50785 esac 50786 fi 50787 elif test "x$TOOLCHAIN_TYPE" = xsolstudio; then 50788 OPENJDK_BUILD_JVM_CFLAGS="$OPENJDK_BUILD_JVM_CFLAGS -DSPARC_WORKS" 50789 OPENJDK_BUILD_COMMON_CCXXFLAGS_JDK="$OPENJDK_BUILD_COMMON_CCXXFLAGS $OPENJDK_BUILD_COMMON_CCXXFLAGS_JDK -DTRACING -DMACRO_MEMSYS_OPS -DBREAKPTS" 50790 if test "x$OPENJDK_BUILD_CPU_ARCH" = xx86; then 50791 OPENJDK_BUILD_COMMON_CCXXFLAGS_JDK="$OPENJDK_BUILD_COMMON_CCXXFLAGS_JDK -DcpuIntel -Di586 -D$OPENJDK_BUILD_CPU_LEGACY_LIB" 50792 fi 50793 50794 OPENJDK_BUILD_CFLAGS_JDK="$OPENJDK_BUILD_CFLAGS_JDK -xc99=%none -xCC -errshort=tags -Xa -v -mt -W0,-noglobal" 50795 OPENJDK_BUILD_CXXFLAGS_JDK="$OPENJDK_BUILD_CXXFLAGS_JDK -errtags=yes +w -mt -features=no%except -DCC_NOEX -norunpath -xnolib" 50796 elif test "x$TOOLCHAIN_TYPE" = xxlc; then 50797 OPENJDK_BUILD_JVM_CFLAGS="$OPENJDK_BUILD_JVM_CFLAGS -D_REENTRANT -D__STDC_FORMAT_MACROS" 50798 OPENJDK_BUILD_CFLAGS_JDK="$OPENJDK_BUILD_CFLAGS_JDK -D_GNU_SOURCE -D_REENTRANT -D_LARGEFILE64_SOURCE -DSTDC" 50799 OPENJDK_BUILD_CXXFLAGS_JDK="$OPENJDK_BUILD_CXXFLAGS_JDK -D_GNU_SOURCE -D_REENTRANT -D_LARGEFILE64_SOURCE -DSTDC" 50800 elif test "x$TOOLCHAIN_TYPE" = xmicrosoft; then 50801 OPENJDK_BUILD_COMMON_CCXXFLAGS_JDK="$OPENJDK_BUILD_COMMON_CCXXFLAGS $OPENJDK_BUILD_COMMON_CCXXFLAGS_JDK \ 50802 -MD -Zc:wchar_t- -W3 -wd4800 \ 50803 -DWIN32_LEAN_AND_MEAN \ 50804 -D_CRT_SECURE_NO_DEPRECATE -D_CRT_NONSTDC_NO_DEPRECATE \ 50805 -D_WINSOCK_DEPRECATED_NO_WARNINGS \ 50806 -DWIN32 -DIAL" 50807 if test "x$OPENJDK_BUILD_CPU" = xx86_64; then 50808 OPENJDK_BUILD_COMMON_CCXXFLAGS_JDK="$OPENJDK_BUILD_COMMON_CCXXFLAGS_JDK -D_AMD64_ -Damd64" 50809 else 50810 OPENJDK_BUILD_COMMON_CCXXFLAGS_JDK="$OPENJDK_BUILD_COMMON_CCXXFLAGS_JDK -D_X86_ -Dx86" 50811 fi 50812 # If building with Visual Studio 2010, we can still use _STATIC_CPPLIB to 50813 # avoid bundling msvcpNNN.dll. Doesn't work with newer versions of visual 50814 # studio. 50815 if test "x$TOOLCHAIN_VERSION" = "x2010"; then 50816 STATIC_CPPLIB_FLAGS="-D_STATIC_CPPLIB -D_DISABLE_DEPRECATE_STATIC_CPPLIB" 50817 OPENJDK_BUILD_COMMON_CCXXFLAGS_JDK="$OPENJDK_BUILD_COMMON_CCXXFLAGS_JDK $STATIC_CPPLIB_FLAGS" 50818 OPENJDK_BUILD_JVM_CFLAGS="$OPENJDK_BUILD_JVM_CFLAGS $STATIC_CPPLIB_FLAGS" 50819 fi 50820 fi 50821 50822 ############################################################################### 50823 50824 # Adjust flags according to debug level. 50825 case $DEBUG_LEVEL in 50826 fastdebug | slowdebug ) 50827 OPENJDK_BUILD_CFLAGS_JDK="$OPENJDK_BUILD_CFLAGS_JDK $CFLAGS_DEBUG_SYMBOLS $CFLAGS_DEBUG_OPTIONS" 50828 OPENJDK_BUILD_CXXFLAGS_JDK="$OPENJDK_BUILD_CXXFLAGS_JDK $CXXFLAGS_DEBUG_SYMBOLS $CXXFLAGS_DEBUG_OPTIONS" 50829 JAVAC_FLAGS="$JAVAC_FLAGS -g" 50830 ;; 50831 release ) 50832 ;; 50833 * ) 50834 as_fn_error $? "Unrecognized \$DEBUG_LEVEL: $DEBUG_LEVEL" "$LINENO" 5 50835 ;; 50836 esac 50837 50838 # Set some common defines. These works for all compilers, but assume 50839 # -D is universally accepted. 50840 50841 # Setup endianness 50842 if test "x$OPENJDK_BUILD_CPU_ENDIAN" = xlittle; then 50843 # The macro _LITTLE_ENDIAN needs to be defined the same to avoid the 50844 # Sun C compiler warning message: warning: macro redefined: _LITTLE_ENDIAN 50845 # (The Solaris X86 system defines this in file /usr/include/sys/isa_defs.h). 50846 # Note: -Dmacro is the same as #define macro 1 50847 # -Dmacro= is the same as #define macro 50848 if test "x$OPENJDK_BUILD_OS" = xsolaris; then 50849 OPENJDK_BUILD_COMMON_CCXXFLAGS_JDK="$OPENJDK_BUILD_COMMON_CCXXFLAGS_JDK -D_LITTLE_ENDIAN=" 50850 else 50851 OPENJDK_BUILD_COMMON_CCXXFLAGS_JDK="$OPENJDK_BUILD_COMMON_CCXXFLAGS_JDK -D_LITTLE_ENDIAN" 50852 fi 50853 else 50854 # Same goes for _BIG_ENDIAN. Do we really need to set *ENDIAN on Solaris if they 50855 # are defined in the system? 50856 if test "x$OPENJDK_BUILD_OS" = xsolaris; then 50857 OPENJDK_BUILD_COMMON_CCXXFLAGS_JDK="$OPENJDK_BUILD_COMMON_CCXXFLAGS_JDK -D_BIG_ENDIAN=" 50858 else 50859 OPENJDK_BUILD_COMMON_CCXXFLAGS_JDK="$OPENJDK_BUILD_COMMON_CCXXFLAGS_JDK -D_BIG_ENDIAN" 50860 fi 50861 fi 50862 50863 # Setup target OS define. Use OS target name but in upper case. 50864 OPENJDK_BUILD_OS_UPPERCASE=`$ECHO $OPENJDK_BUILD_OS | $TR 'abcdefghijklmnopqrstuvwxyz' 'ABCDEFGHIJKLMNOPQRSTUVWXYZ'` 50865 OPENJDK_BUILD_COMMON_CCXXFLAGS_JDK="$OPENJDK_BUILD_COMMON_CCXXFLAGS_JDK -D$OPENJDK_BUILD_OS_UPPERCASE" 50866 50867 # Setup target CPU 50868 OPENJDK_BUILD_COMMON_CCXXFLAGS_JDK="$OPENJDK_BUILD_COMMON_CCXXFLAGS_JDK \ 50869 $OPENJDK_BUILD_ADD_LP64 \ 50870 -DARCH='\"$OPENJDK_BUILD_CPU_LEGACY\"' -D$OPENJDK_BUILD_CPU_LEGACY" 50871 50872 # Setup debug/release defines 50873 if test "x$DEBUG_LEVEL" = xrelease; then 50874 OPENJDK_BUILD_COMMON_CCXXFLAGS_JDK="$OPENJDK_BUILD_COMMON_CCXXFLAGS_JDK -DNDEBUG" 50875 if test "x$OPENJDK_BUILD_OS" = xsolaris; then 50876 OPENJDK_BUILD_COMMON_CCXXFLAGS_JDK="$OPENJDK_BUILD_COMMON_CCXXFLAGS_JDK -DTRIMMED" 50877 fi 50878 else 50879 OPENJDK_BUILD_COMMON_CCXXFLAGS_JDK="$OPENJDK_BUILD_COMMON_CCXXFLAGS_JDK -DDEBUG" 50880 fi 50881 50882 # Set some additional per-OS defines. 50883 if test "x$OPENJDK_BUILD_OS" = xlinux; then 50884 OPENJDK_BUILD_JVM_CFLAGS="$OPENJDK_BUILD_JVM_CFLAGS -DLINUX" 50885 OPENJDK_BUILD_JVM_CFLAGS="$OPENJDK_BUILD_JVM_CFLAGS -pipe -fPIC -fno-rtti -fno-exceptions \ 50886 -fvisibility=hidden -fno-strict-aliasing -fno-omit-frame-pointer" 50887 elif test "x$OPENJDK_BUILD_OS" = xsolaris; then 50888 OPENJDK_BUILD_JVM_CFLAGS="$OPENJDK_BUILD_JVM_CFLAGS -DSOLARIS" 50889 OPENJDK_BUILD_JVM_CFLAGS="$OPENJDK_BUILD_JVM_CFLAGS -template=no%extdef -features=no%split_init \ 50890 -D_Crun_inline_placement -library=%none -KPIC -mt -xwe -features=no%except" 50891 elif test "x$OPENJDK_BUILD_OS" = xmacosx; then 50892 OPENJDK_BUILD_COMMON_CCXXFLAGS_JDK="$OPENJDK_BUILD_COMMON_CCXXFLAGS_JDK -D_ALLBSD_SOURCE -D_DARWIN_UNLIMITED_SELECT" 50893 OPENJDK_BUILD_JVM_CFLAGS="$OPENJDK_BUILD_JVM_CFLAGS -D_ALLBSD_SOURCE" 50894 OPENJDK_BUILD_JVM_CFLAGS="$OPENJDK_BUILD_JVM_CFLAGS -D_DARWIN_C_SOURCE -D_XOPEN_SOURCE" 50895 OPENJDK_BUILD_JVM_CFLAGS="$OPENJDK_BUILD_JVM_CFLAGS -fno-rtti -fno-exceptions -fvisibility=hidden \ 50896 -mno-omit-leaf-frame-pointer -mstack-alignment=16 -pipe -fno-strict-aliasing \ 50897 -DMAC_OS_X_VERSION_MAX_ALLOWED=1070 -mmacosx-version-min=10.7.0 \ 50898 -fno-omit-frame-pointer" 50899 elif test "x$OPENJDK_BUILD_OS" = xaix; then 50900 OPENJDK_BUILD_JVM_CFLAGS="$OPENJDK_BUILD_JVM_CFLAGS -DAIX" 50901 # We may need '-qminimaltoc' or '-qpic=large -bbigtoc' if the TOC overflows. 50902 OPENJDK_BUILD_JVM_CFLAGS="$OPENJDK_BUILD_JVM_CFLAGS -qtune=balanced \ 50903 -qalias=noansi -qstrict -qtls=default -qlanglvl=c99vla \ 50904 -qlanglvl=noredefmac -qnortti -qnoeh -qignerrno" 50905 elif test "x$OPENJDK_BUILD_OS" = xbsd; then 50906 OPENJDK_BUILD_COMMON_CCXXFLAGS_JDK="$OPENJDK_BUILD_COMMON_CCXXFLAGS_JDK -D_ALLBSD_SOURCE" 50907 elif test "x$OPENJDK_BUILD_OS" = xwindows; then 50908 OPENJDK_BUILD_JVM_CFLAGS="$OPENJDK_BUILD_JVM_CFLAGS -D_WINDOWS -DWIN32 -D_JNI_IMPLEMENTATION_" 50909 OPENJDK_BUILD_JVM_CFLAGS="$OPENJDK_BUILD_JVM_CFLAGS -nologo -W3 -MD -MP" 50910 fi 50911 50912 # Set some additional per-CPU defines. 50913 if test "x$OPENJDK_BUILD_OS-$OPENJDK_BUILD_CPU" = xwindows-x86; then 50914 OPENJDK_BUILD_JVM_CFLAGS="$OPENJDK_BUILD_JVM_CFLAGS -arch:IA32" 50915 elif test "x$OPENJDK_BUILD_CPU" = xsparcv9; then 50916 OPENJDK_BUILD_JVM_CFLAGS="$OPENJDK_BUILD_JVM_CFLAGS -xarch=sparc" 50917 elif test "x$OPENJDK_BUILD_CPU" = xppc64; then 50918 if test "x$OPENJDK_BUILD_OS" = xlinux; then 50919 OPENJDK_BUILD_JVM_CFLAGS="$OPENJDK_BUILD_JVM_CFLAGS -minsert-sched-nops=regroup_exact -mno-multiple -mno-string" 50920 # fixes `relocation truncated to fit' error for gcc 4.1. 50921 OPENJDK_BUILD_JVM_CFLAGS="$OPENJDK_BUILD_JVM_CFLAGS -mminimal-toc" 50922 # Use ppc64 instructions, but schedule for power5 50923 OPENJDK_BUILD_JVM_CFLAGS="$OPENJDK_BUILD_JVM_CFLAGS -mcpu=powerpc64 -mtune=power5" 50924 elif test "x$OPENJDK_BUILD_OS" = xaix; then 50925 OPENJDK_BUILD_JVM_CFLAGS="$OPENJDK_BUILD_JVM_CFLAGS -qarch=ppc64" 50926 fi 50927 elif test "x$OPENJDK_BUILD_CPU" = xppc64le; then 50928 if test "x$OPENJDK_BUILD_OS" = xlinux; then 50929 OPENJDK_BUILD_JVM_CFLAGS="$OPENJDK_BUILD_JVM_CFLAGS -minsert-sched-nops=regroup_exact -mno-multiple -mno-string" 50930 # Little endian machine uses ELFv2 ABI. 50931 OPENJDK_BUILD_JVM_CFLAGS="$OPENJDK_BUILD_JVM_CFLAGS -DABI_ELFv2" 50932 # Use Power8, this is the first CPU to support PPC64 LE with ELFv2 ABI. 50933 OPENJDK_BUILD_JVM_CFLAGS="$OPENJDK_BUILD_JVM_CFLAGS -mcpu=power7 -mtune=power8" 50934 fi 50935 fi 50936 50937 if test "x$OPENJDK_BUILD_CPU_ENDIAN" = xlittle; then 50938 OPENJDK_BUILD_JVM_CFLAGS="$OPENJDK_BUILD_JVM_CFLAGS -DVM_LITTLE_ENDIAN" 50939 fi 50940 50941 if test "x$OPENJDK_BUILD_CPU_BITS" = x64; then 50942 if test "x$OPENJDK_BUILD_OS" != xsolaris && test "x$OPENJDK_BUILD_OS" != xaix; then 50943 # Solaris does not have _LP64=1 in the old build. 50944 # xlc on AIX defines _LP64=1 by default and issues a warning if we redefine it. 50945 OPENJDK_BUILD_JVM_CFLAGS="$OPENJDK_BUILD_JVM_CFLAGS -D_LP64=1" 50946 fi 50947 fi 50948 50949 # Set OPENJDK_BUILD_JVM_CFLAGS warning handling 50950 if test "x$OPENJDK_BUILD_OS" = xlinux; then 50951 OPENJDK_BUILD_JVM_CFLAGS="$OPENJDK_BUILD_JVM_CFLAGS -Wpointer-arith -Wsign-compare -Wunused-function \ 50952 -Wunused-value -Woverloaded-virtual" 50953 50954 if test "x$TOOLCHAIN_TYPE" = xgcc; then 50955 50956 50957 50958 50959 50960 50961 50962 50963 50964 50965 50966 50967 50968 50969 50970 50971 50972 50973 50974 50975 50976 50977 50978 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 # Execute function body 51010 51011 # Need to assign to a variable since m4 is blocked from modifying parts in []. 51012 REFERENCE_VERSION=4.8 51013 51014 if [[ "$REFERENCE_VERSION" =~ (.*\.){3} ]] ; then 51015 as_fn_error $? "Internal error: Cannot compare to 4.8, only three parts (X.Y.Z) is supported" "$LINENO" 5 51016 fi 51017 51018 if [[ "$REFERENCE_VERSION" =~ [0-9]{6} ]] ; then 51019 as_fn_error $? "Internal error: Cannot compare to 4.8, only parts < 99999 is supported" "$LINENO" 5 51020 fi 51021 51022 # Version comparison method inspired by http://stackoverflow.com/a/24067243 51023 COMPARABLE_REFERENCE_VERSION=`$AWK -F. '{ printf("%05d%05d%05d\n", $1, $2, $3) }' <<< "$REFERENCE_VERSION"` 51024 51025 if test $OPENJDK_BUILD_COMPARABLE_ACTUAL_VERSION -ge $COMPARABLE_REFERENCE_VERSION ; then 51026 : 51027 51028 # These flags either do not work or give spurious warnings prior to gcc 4.8. 51029 OPENJDK_BUILD_JVM_CFLAGS="$OPENJDK_BUILD_JVM_CFLAGS -Wno-format-zero-length -Wtype-limits -Wuninitialized" 51030 51031 51032 else 51033 : 51034 51035 fi 51036 51037 51038 51039 51040 51041 51042 51043 51044 51045 51046 51047 51048 51049 51050 fi 51051 if ! [[ " $JVM_VARIANTS " =~ " zero " ]] && ! [[ " $JVM_VARIANTS " =~ " zeroshark " ]] ; then 51052 # Non-zero builds have stricter warnings 51053 OPENJDK_BUILD_JVM_CFLAGS="$OPENJDK_BUILD_JVM_CFLAGS -Wreturn-type -Wundef -Wformat=2" 51054 else 51055 if test "x$TOOLCHAIN_TYPE" = xclang; then 51056 # Some versions of llvm do not like -Wundef 51057 OPENJDK_BUILD_JVM_CFLAGS="$OPENJDK_BUILD_JVM_CFLAGS -Wno-undef" 51058 fi 51059 fi 51060 elif test "x$OPENJDK_BUILD_OS" = xmacosx; then 51061 OPENJDK_BUILD_JVM_CFLAGS="$OPENJDK_BUILD_JVM_CFLAGS -Wno-deprecated -Wpointer-arith \ 51062 -Wsign-compare -Wundef -Wunused-function -Wformat=2" 51063 fi 51064 51065 # Additional macosx handling 51066 if test "x$OPENJDK_BUILD_OS" = xmacosx; then 51067 # Setting these parameters makes it an error to link to macosx APIs that are 51068 # newer than the given OS version and makes the linked binaries compatible 51069 # even if built on a newer version of the OS. 51070 # The expected format is X.Y.Z 51071 MACOSX_VERSION_MIN=10.7.0 51072 51073 51074 # The macro takes the version with no dots, ex: 1070 51075 # Let the flags variables get resolved in make for easier override on make 51076 # command line. 51077 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)" 51078 OPENJDK_BUILD_LDFLAGS_JDK="$OPENJDK_BUILD_LDFLAGS_JDK -mmacosx-version-min=\$(MACOSX_VERSION_MIN)" 51079 fi 51080 51081 # Setup some hard coded includes 51082 OPENJDK_BUILD_COMMON_CCXXFLAGS_JDK="$OPENJDK_BUILD_COMMON_CCXXFLAGS_JDK \ 51083 -I${JDK_TOPDIR}/src/java.base/share/native/include \ 51084 -I${JDK_TOPDIR}/src/java.base/$OPENJDK_BUILD_OS/native/include \ 51085 -I${JDK_TOPDIR}/src/java.base/$OPENJDK_BUILD_OS_TYPE/native/include \ 51086 -I${JDK_TOPDIR}/src/java.base/share/native/libjava \ 51087 -I${JDK_TOPDIR}/src/java.base/$OPENJDK_BUILD_OS_TYPE/native/libjava" 51088 51089 # The shared libraries are compiled using the picflag. 51090 OPENJDK_BUILD_CFLAGS_JDKLIB="$OPENJDK_BUILD_COMMON_CCXXFLAGS_JDK \ 51091 $OPENJDK_BUILD_CFLAGS_JDK $OPENJDK_BUILD_EXTRA_CFLAGS_JDK $PICFLAG $OPENJDK_BUILD_CFLAGS_JDKLIB_EXTRA" 51092 OPENJDK_BUILD_CXXFLAGS_JDKLIB="$OPENJDK_BUILD_COMMON_CCXXFLAGS_JDK \ 51093 $OPENJDK_BUILD_CXXFLAGS_JDK $OPENJDK_BUILD_EXTRA_CXXFLAGS_JDK $PICFLAG $OPENJDK_BUILD_CXXFLAGS_JDKLIB_EXTRA" 51094 51095 # Executable flags 51096 OPENJDK_BUILD_CFLAGS_JDKEXE="$OPENJDK_BUILD_COMMON_CCXXFLAGS_JDK $OPENJDK_BUILD_CFLAGS_JDK $OPENJDK_BUILD_EXTRA_CFLAGS_JDK" 51097 OPENJDK_BUILD_CXXFLAGS_JDKEXE="$OPENJDK_BUILD_COMMON_CCXXFLAGS_JDK $OPENJDK_BUILD_CXXFLAGS_JDK $OPENJDK_BUILD_EXTRA_CXXFLAGS_JDK" 51098 51099 51100 51101 51102 51103 51104 # Setup LDFLAGS et al. 51105 # 51106 51107 if test "x$TOOLCHAIN_TYPE" = xmicrosoft; then 51108 LDFLAGS_MICROSOFT="-nologo -opt:ref" 51109 OPENJDK_BUILD_LDFLAGS_JDK="$OPENJDK_BUILD_LDFLAGS_JDK $LDFLAGS_MICROSOFT -incremental:no" 51110 OPENJDK_BUILD_JVM_LDFLAGS="$OPENJDK_BUILD_JVM_LDFLAGS $LDFLAGS_MICROSOFT -opt:icf,8 -subsystem:windows -base:0x8000000" 51111 if test "x$OPENJDK_BUILD_CPU_BITS" = "x32"; then 51112 LDFLAGS_SAFESH="-safeseh" 51113 OPENJDK_BUILD_LDFLAGS_JDK="$OPENJDK_BUILD_LDFLAGS_JDK $LDFLAGS_SAFESH" 51114 OPENJDK_BUILD_JVM_LDFLAGS="$OPENJDK_BUILD_JVM_LDFLAGS $LDFLAGS_SAFESH" 51115 # NOTE: Old build added -machine. Probably not needed. 51116 OPENJDK_BUILD_JVM_LDFLAGS="$OPENJDK_BUILD_JVM_LDFLAGS -machine:I386" 51117 else 51118 OPENJDK_BUILD_JVM_LDFLAGS="$OPENJDK_BUILD_JVM_LDFLAGS -machine:AMD64" 51119 fi 51120 elif test "x$TOOLCHAIN_TYPE" = xclang; then 51121 OPENJDK_BUILD_JVM_LDFLAGS="$OPENJDK_BUILD_JVM_LDFLAGS -mno-omit-leaf-frame-pointer -mstack-alignment=16 -stdlib=libstdc++ -fPIC" 51122 if test "x$OPENJDK_BUILD_OS" = xmacosx; then 51123 # FIXME: We should really generalize SET_SHARED_LIBRARY_ORIGIN instead. 51124 OPENJDK_BUILD_JVM_LDFLAGS="$OPENJDK_BUILD_JVM_LDFLAGS -Wl,-rpath,@loader_path/. -Wl,-rpath,@loader_path/.." 51125 fi 51126 elif test "x$TOOLCHAIN_TYPE" = xgcc; then 51127 # If this is a --hash-style=gnu system, use --hash-style=both, why? 51128 # We have previously set HAS_GNU_HASH if this is the case 51129 if test -n "$HAS_GNU_HASH"; then 51130 OPENJDK_BUILD_LDFLAGS_HASH_STYLE="-Wl,--hash-style=both" 51131 OPENJDK_BUILD_LDFLAGS_JDK="${OPENJDK_BUILD_LDFLAGS_JDK} $OPENJDK_BUILD_LDFLAGS_HASH_STYLE" 51132 OPENJDK_BUILD_JVM_LDFLAGS="$OPENJDK_BUILD_JVM_LDFLAGS $OPENJDK_BUILD_LDFLAGS_HASH_STYLE" 51133 fi 51134 if test "x$OPENJDK_BUILD_OS" = xmacosx; then 51135 OPENJDK_BUILD_JVM_LDFLAGS="$OPENJDK_BUILD_JVM_LDFLAGS -Wl,-rpath,@loader_path/. -Wl,-rpath,@loader_path/.." 51136 fi 51137 if test "x$OPENJDK_BUILD_OS" = xlinux; then 51138 # And since we now know that the linker is gnu, then add -z defs, to forbid 51139 # undefined symbols in object files. 51140 LDFLAGS_NO_UNDEF_SYM="-Wl,-z,defs" 51141 OPENJDK_BUILD_LDFLAGS_JDK="${OPENJDK_BUILD_LDFLAGS_JDK} $LDFLAGS_NO_UNDEF_SYM" 51142 OPENJDK_BUILD_JVM_LDFLAGS="$OPENJDK_BUILD_JVM_LDFLAGS $LDFLAGS_NO_UNDEF_SYM" 51143 LDFLAGS_NO_EXEC_STACK="-Wl,-z,noexecstack" 51144 OPENJDK_BUILD_JVM_LDFLAGS="$OPENJDK_BUILD_JVM_LDFLAGS $LDFLAGS_NO_EXEC_STACK" 51145 if test "x$OPENJDK_BUILD_CPU" = xx86; then 51146 OPENJDK_BUILD_JVM_LDFLAGS="$OPENJDK_BUILD_JVM_LDFLAGS -march=i586" 51147 fi 51148 case $DEBUG_LEVEL in 51149 release ) 51150 # tell linker to optimize libraries. 51151 # Should this be supplied to the OSS linker as well? 51152 LDFLAGS_DEBUGLEVEL_release="-Wl,-O1" 51153 OPENJDK_BUILD_LDFLAGS_JDK="${OPENJDK_BUILD_LDFLAGS_JDK} $LDFLAGS_DEBUGLEVEL_release" 51154 OPENJDK_BUILD_JVM_LDFLAGS="$OPENJDK_BUILD_JVM_LDFLAGS $LDFLAGS_DEBUGLEVEL_release" 51155 if test "x$HAS_LINKER_RELRO" = "xtrue"; then 51156 OPENJDK_BUILD_JVM_LDFLAGS="$OPENJDK_BUILD_JVM_LDFLAGS $LINKER_RELRO_FLAG" 51157 fi 51158 ;; 51159 slowdebug ) 51160 # Hotspot always let the linker optimize 51161 OPENJDK_BUILD_JVM_LDFLAGS="$OPENJDK_BUILD_JVM_LDFLAGS -Wl,-O1" 51162 if test "x$HAS_LINKER_NOW" = "xtrue"; then 51163 # do relocations at load 51164 OPENJDK_BUILD_LDFLAGS_JDK="$OPENJDK_BUILD_LDFLAGS_JDK $LINKER_NOW_FLAG" 51165 OPENJDK_BUILD_LDFLAGS_CXX_JDK="$OPENJDK_BUILD_LDFLAGS_CXX_JDK $LINKER_NOW_FLAG" 51166 OPENJDK_BUILD_JVM_LDFLAGS="$OPENJDK_BUILD_JVM_LDFLAGS $LINKER_NOW_FLAG" 51167 fi 51168 if test "x$HAS_LINKER_RELRO" = "xtrue"; then 51169 # mark relocations read only 51170 OPENJDK_BUILD_LDFLAGS_JDK="$OPENJDK_BUILD_LDFLAGS_JDK $LINKER_RELRO_FLAG" 51171 OPENJDK_BUILD_LDFLAGS_CXX_JDK="$OPENJDK_BUILD_LDFLAGS_CXX_JDK $LINKER_RELRO_FLAG" 51172 OPENJDK_BUILD_JVM_LDFLAGS="$OPENJDK_BUILD_JVM_LDFLAGS $LINKER_RELRO_FLAG" 51173 fi 51174 ;; 51175 fastdebug ) 51176 # Hotspot always let the linker optimize 51177 OPENJDK_BUILD_JVM_LDFLAGS="$OPENJDK_BUILD_JVM_LDFLAGS -Wl,-O1" 51178 if test "x$HAS_LINKER_RELRO" = "xtrue"; then 51179 # mark relocations read only 51180 OPENJDK_BUILD_LDFLAGS_JDK="$OPENJDK_BUILD_LDFLAGS_JDK $LINKER_RELRO_FLAG" 51181 OPENJDK_BUILD_LDFLAGS_CXX_JDK="$OPENJDK_BUILD_LDFLAGS_CXX_JDK $LINKER_RELRO_FLAG" 51182 OPENJDK_BUILD_JVM_LDFLAGS="$OPENJDK_BUILD_JVM_LDFLAGS $LINKER_RELRO_FLAG" 51183 fi 51184 ;; 51185 * ) 51186 as_fn_error $? "Unrecognized \$DEBUG_LEVEL: $DEBUG_LEVEL" "$LINENO" 5 51187 ;; 51188 esac 51189 fi 51190 elif test "x$TOOLCHAIN_TYPE" = xsolstudio; then 51191 LDFLAGS_SOLSTUDIO="-Wl,-z,defs" 51192 OPENJDK_BUILD_LDFLAGS_JDK="$OPENJDK_BUILD_LDFLAGS_JDK $LDFLAGS_SOLSTUDIO -ztext" 51193 LDFLAGS_CXX_SOLSTUDIO="-norunpath" 51194 OPENJDK_BUILD_LDFLAGS_CXX_JDK="$OPENJDK_BUILD_LDFLAGS_CXX_JDK $LDFLAGS_CXX_SOLSTUDIO -xnolib" 51195 OPENJDK_BUILD_JVM_LDFLAGS="$OPENJDK_BUILD_JVM_LDFLAGS $LDFLAGS_SOLSTUDIO -library=%none -mt $LDFLAGS_CXX_SOLSTUDIO -z noversion" 51196 if test "x$OPENJDK_BUILD_CPU_ARCH" = "xsparc"; then 51197 OPENJDK_BUILD_JVM_LDFLAGS="$OPENJDK_BUILD_JVM_LDFLAGS -xarch=sparc" 51198 fi 51199 elif test "x$TOOLCHAIN_TYPE" = xxlc; then 51200 LDFLAGS_XLC="-b64 -brtl -bnolibpath -bexpall -bernotok" 51201 OPENJDK_BUILD_LDFLAGS_JDK="${OPENJDK_BUILD_LDFLAGS_JDK} $LDFLAGS_XLC" 51202 OPENJDK_BUILD_JVM_LDFLAGS="$OPENJDK_BUILD_JVM_LDFLAGS $LDFLAGS_XLC" 51203 fi 51204 51205 # Customize LDFLAGS for executables 51206 51207 OPENJDK_BUILD_LDFLAGS_JDKEXE="${OPENJDK_BUILD_LDFLAGS_JDK}" 51208 51209 if test "x$TOOLCHAIN_TYPE" = xmicrosoft; then 51210 if test "x$OPENJDK_BUILD_CPU_BITS" = "x64"; then 51211 LDFLAGS_STACK_SIZE=1048576 51212 else 51213 LDFLAGS_STACK_SIZE=327680 51214 fi 51215 OPENJDK_BUILD_LDFLAGS_JDKEXE="${OPENJDK_BUILD_LDFLAGS_JDKEXE} /STACK:$LDFLAGS_STACK_SIZE" 51216 elif test "x$OPENJDK_BUILD_OS" = xlinux; then 51217 OPENJDK_BUILD_LDFLAGS_JDKEXE="$OPENJDK_BUILD_LDFLAGS_JDKEXE -Wl,--allow-shlib-undefined" 51218 fi 51219 51220 OPENJDK_BUILD_LDFLAGS_JDKEXE="${OPENJDK_BUILD_LDFLAGS_JDKEXE} ${OPENJDK_BUILD_EXTRA_LDFLAGS_JDK}" 51221 51222 # Customize LDFLAGS for libs 51223 OPENJDK_BUILD_LDFLAGS_JDKLIB="${OPENJDK_BUILD_LDFLAGS_JDK}" 51224 51225 OPENJDK_BUILD_LDFLAGS_JDKLIB="${OPENJDK_BUILD_LDFLAGS_JDKLIB} ${SHARED_LIBRARY_FLAGS}" 51226 if test "x$TOOLCHAIN_TYPE" = xmicrosoft; then 51227 OPENJDK_BUILD_JAVA_BASE_LDFLAGS="${OPENJDK_BUILD_JAVA_BASE_LDFLAGS} \ 51228 -libpath:${OUTPUT_ROOT}/support/modules_libs/java.base" 51229 OPENJDK_BUILD_JDKLIB_LIBS="" 51230 else 51231 OPENJDK_BUILD_JAVA_BASE_LDFLAGS="${OPENJDK_BUILD_JAVA_BASE_LDFLAGS} \ 51232 -L\$(SUPPORT_OUTPUTDIR)/modules_libs/java.base\$(OPENJDK_BUILD_CPU_LIBDIR)" 51233 51234 if test "xBUILD" = "xTARGET"; then 51235 # On some platforms (mac) the linker warns about non existing -L dirs. 51236 # Add server first if available. Linking aginst client does not always produce the same results. 51237 # Only add client/minimal dir if client/minimal is being built. 51238 # Default to server for other variants. 51239 if [[ " $JVM_VARIANTS " =~ " server " ]] ; then 51240 OPENJDK_BUILD_JAVA_BASE_LDFLAGS="${OPENJDK_BUILD_JAVA_BASE_LDFLAGS} -L\$(SUPPORT_OUTPUTDIR)/modules_libs/java.base\$(OPENJDK_BUILD_CPU_LIBDIR)/server" 51241 elif [[ " $JVM_VARIANTS " =~ " client " ]] ; then 51242 OPENJDK_BUILD_JAVA_BASE_LDFLAGS="${OPENJDK_BUILD_JAVA_BASE_LDFLAGS} -L\$(SUPPORT_OUTPUTDIR)/modules_libs/java.base\$(OPENJDK_BUILD_CPU_LIBDIR)/client" 51243 elif [[ " $JVM_VARIANTS " =~ " minimal " ]] ; then 51244 OPENJDK_BUILD_JAVA_BASE_LDFLAGS="${OPENJDK_BUILD_JAVA_BASE_LDFLAGS} -L\$(SUPPORT_OUTPUTDIR)/modules_libs/java.base\$(OPENJDK_BUILD_CPU_LIBDIR)/minimal" 51245 else 51246 OPENJDK_BUILD_JAVA_BASE_LDFLAGS="${OPENJDK_BUILD_JAVA_BASE_LDFLAGS} -L\$(SUPPORT_OUTPUTDIR)/modules_libs/java.base\$(OPENJDK_BUILD_CPU_LIBDIR)/server" 51247 fi 51248 elif test "xBUILD" = "xBUILD"; then 51249 # When building a buildjdk, it's always only the server variant 51250 OPENJDK_BUILD_JAVA_BASE_LDFLAGS="${OPENJDK_BUILD_JAVA_BASE_LDFLAGS} \ 51251 -L\$(SUPPORT_OUTPUTDIR)/modules_libs/java.base\$(OPENJDK_BUILD_CPU_LIBDIR)/server" 51252 fi 51253 51254 OPENJDK_BUILD_JDKLIB_LIBS="-ljava -ljvm" 51255 if test "x$TOOLCHAIN_TYPE" = xsolstudio; then 51256 OPENJDK_BUILD_JDKLIB_LIBS="$OPENJDK_BUILD_JDKLIB_LIBS -lc" 51257 fi 51258 51259 fi 51260 51261 OPENJDK_BUILD_LDFLAGS_JDKLIB="${OPENJDK_BUILD_LDFLAGS_JDKLIB} ${OPENJDK_BUILD_JAVA_BASE_LDFLAGS}" 51262 51263 # Set OPENJDK_BUILD_JVM_LIBS (per os) 51264 if test "x$OPENJDK_BUILD_OS" = xlinux; then 51265 OPENJDK_BUILD_JVM_LIBS="$OPENJDK_BUILD_JVM_LIBS -lm -ldl -lpthread" 51266 elif test "x$OPENJDK_BUILD_OS" = xsolaris; then 51267 # FIXME: This hard-coded path is not really proper. 51268 if test "x$OPENJDK_BUILD_CPU" = xx86_64; then 51269 OPENJDK_BUILD_SOLARIS_LIBM_LIBS="/usr/lib/amd64/libm.so.1" 51270 elif test "x$OPENJDK_BUILD_CPU" = xsparcv9; then 51271 OPENJDK_BUILD_SOLARIS_LIBM_LIBS="/usr/lib/sparcv9/libm.so.1" 51272 fi 51273 OPENJDK_BUILD_JVM_LIBS="$OPENJDK_BUILD_JVM_LIBS -lsocket -lsched -ldl $SOLARIS_LIBM_LIBS -lCrun \ 51274 -lthread -ldoor -lc -ldemangle -lnsl -lkstat -lrt" 51275 elif test "x$OPENJDK_BUILD_OS" = xmacosx; then 51276 OPENJDK_BUILD_JVM_LIBS="$OPENJDK_BUILD_JVM_LIBS -lm" 51277 elif test "x$OPENJDK_BUILD_OS" = xaix; then 51278 OPENJDK_BUILD_JVM_LIBS="$OPENJDK_BUILD_JVM_LIBS -Wl,-lC_r -lm -ldl -lpthread" 51279 elif test "x$OPENJDK_BUILD_OS" = xbsd; then 51280 OPENJDK_BUILD_JVM_LIBS="$OPENJDK_BUILD_JVM_LIBS -lm" 51281 elif test "x$OPENJDK_BUILD_OS" = xwindows; then 51282 OPENJDK_BUILD_JVM_LIBS="$OPENJDK_BUILD_JVM_LIBS kernel32.lib user32.lib gdi32.lib winspool.lib \ 51283 comdlg32.lib advapi32.lib shell32.lib ole32.lib oleaut32.lib uuid.lib \ 51284 wsock32.lib winmm.lib version.lib psapi.lib" 51285 fi 51286 51287 # Set OPENJDK_BUILD_JVM_ASFLAGS 51288 if test "x$OPENJDK_BUILD_OS" = xlinux; then 51289 if test "x$OPENJDK_BUILD_CPU" = xx86; then 51290 OPENJDK_BUILD_JVM_ASFLAGS="$OPENJDK_BUILD_JVM_ASFLAGS -march=i586" 51291 fi 51292 elif test "x$OPENJDK_BUILD_OS" = xmacosx; then 51293 OPENJDK_BUILD_JVM_ASFLAGS="$OPENJDK_BUILD_JVM_ASFLAGS -x assembler-with-cpp -mno-omit-leaf-frame-pointer -mstack-alignment=16" 51294 fi 51295 51296 OPENJDK_BUILD_LDFLAGS_JDKLIB="${OPENJDK_BUILD_LDFLAGS_JDKLIB} ${OPENJDK_BUILD_EXTRA_LDFLAGS_JDK}" 51297 51298 51299 51300 51301 51302 51303 51304 51305 51306 51307 51308 51309 51310 51311 51312 # Tests are only ever compiled for TARGET 51313 # Flags for compiling test libraries 51314 CFLAGS_TESTLIB="$COMMON_CCXXFLAGS_JDK $CFLAGS_JDK $PICFLAG $CFLAGS_JDKLIB_EXTRA" 51315 CXXFLAGS_TESTLIB="$COMMON_CCXXFLAGS_JDK $CXXFLAGS_JDK $PICFLAG $CXXFLAGS_JDKLIB_EXTRA" 51316 51317 # Flags for compiling test executables 51318 CFLAGS_TESTEXE="$COMMON_CCXXFLAGS_JDK $CFLAGS_JDK" 51319 CXXFLAGS_TESTEXE="$COMMON_CCXXFLAGS_JDK $CXXFLAGS_JDK" 51320 51321 51322 51323 51324 51325 51326 LDFLAGS_TESTLIB="$LDFLAGS_JDKLIB" 51327 LDFLAGS_TESTEXE="$LDFLAGS_JDKEXE $JAVA_BASE_LDFLAGS" 51328 51329 51330 51331 51332 51333 51334 # Some Zero and Shark settings. 51335 # ZERO_ARCHFLAG tells the compiler which mode to build for 51336 case "${OPENJDK_TARGET_CPU}" in 51337 s390) 51338 ZERO_ARCHFLAG="${COMPILER_TARGET_BITS_FLAG}31" 51339 ;; 51340 *) 51341 ZERO_ARCHFLAG="${COMPILER_TARGET_BITS_FLAG}${OPENJDK_TARGET_CPU_BITS}" 51342 esac 51343 51344 51345 51346 51347 51348 51349 51350 51351 51352 51353 51354 51355 51356 51357 51358 51359 51360 51361 51362 51363 51364 51365 51366 51367 51368 51369 51370 51371 51372 51373 51374 51375 51376 51377 51378 51379 51380 51381 51382 51383 51384 51385 # Execute function body 51386 51387 51388 51389 51390 51391 51392 51393 51394 51395 51396 51397 51398 51399 51400 51401 51402 51403 51404 51405 51406 51407 51408 51409 51410 51411 51412 51413 51414 51415 51416 51417 51418 51419 51420 51421 51422 51423 51424 51425 51426 51427 51428 51429 51430 51431 51432 51433 51434 # Execute function body 51435 51436 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if the C compiler supports \"$ZERO_ARCHFLAG\"" >&5 51437 $as_echo_n "checking if the C compiler supports \"$ZERO_ARCHFLAG\"... " >&6; } 51438 supports=yes 51439 51440 saved_cflags="$CFLAGS" 51441 CFLAGS="$CFLAGS $ZERO_ARCHFLAG" 51442 ac_ext=c 51443 ac_cpp='$CPP $CPPFLAGS' 51444 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5' 51445 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' 51446 ac_compiler_gnu=$ac_cv_c_compiler_gnu 51447 51448 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 51449 /* end confdefs.h. */ 51450 int i; 51451 _ACEOF 51452 if ac_fn_c_try_compile "$LINENO"; then : 51453 51454 else 51455 supports=no 51456 fi 51457 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext 51458 ac_ext=cpp 51459 ac_cpp='$CXXCPP $CPPFLAGS' 51460 ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5' 51461 ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' 51462 ac_compiler_gnu=$ac_cv_cxx_compiler_gnu 51463 51464 CFLAGS="$saved_cflags" 51465 51466 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $supports" >&5 51467 $as_echo "$supports" >&6; } 51468 if test "x$supports" = "xyes" ; then 51469 : 51470 C_COMP_SUPPORTS="yes" 51471 else 51472 : 51473 C_COMP_SUPPORTS="no" 51474 fi 51475 51476 51477 51478 51479 51480 51481 51482 51483 51484 51485 51486 51487 51488 51489 51490 51491 51492 51493 51494 51495 51496 51497 51498 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 # Execute function body 51535 51536 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if the C++ compiler supports \"$ZERO_ARCHFLAG\"" >&5 51537 $as_echo_n "checking if the C++ compiler supports \"$ZERO_ARCHFLAG\"... " >&6; } 51538 supports=yes 51539 51540 saved_cxxflags="$CXXFLAGS" 51541 CXXFLAGS="$CXXFLAG $ZERO_ARCHFLAG" 51542 ac_ext=cpp 51543 ac_cpp='$CXXCPP $CPPFLAGS' 51544 ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5' 51545 ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' 51546 ac_compiler_gnu=$ac_cv_cxx_compiler_gnu 51547 51548 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 51549 /* end confdefs.h. */ 51550 int i; 51551 _ACEOF 51552 if ac_fn_cxx_try_compile "$LINENO"; then : 51553 51554 else 51555 supports=no 51556 fi 51557 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext 51558 ac_ext=cpp 51559 ac_cpp='$CXXCPP $CPPFLAGS' 51560 ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5' 51561 ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' 51562 ac_compiler_gnu=$ac_cv_cxx_compiler_gnu 51563 51564 CXXFLAGS="$saved_cxxflags" 51565 51566 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $supports" >&5 51567 $as_echo "$supports" >&6; } 51568 if test "x$supports" = "xyes" ; then 51569 : 51570 CXX_COMP_SUPPORTS="yes" 51571 else 51572 : 51573 CXX_COMP_SUPPORTS="no" 51574 fi 51575 51576 51577 51578 51579 51580 51581 51582 51583 51584 51585 51586 51587 51588 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if both compilers support \"$ZERO_ARCHFLAG\"" >&5 51589 $as_echo_n "checking if both compilers support \"$ZERO_ARCHFLAG\"... " >&6; } 51590 supports=no 51591 if test "x$C_COMP_SUPPORTS" = "xyes" -a "x$CXX_COMP_SUPPORTS" = "xyes"; then supports=yes; fi 51592 51593 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $supports" >&5 51594 $as_echo "$supports" >&6; } 51595 if test "x$supports" = "xyes" ; then 51596 : 51597 51598 else 51599 : 51600 ZERO_ARCHFLAG="" 51601 fi 51602 51603 51604 51605 51606 51607 51608 51609 51610 # Check that the compiler supports -mX (or -qX on AIX) flags 51611 # Set COMPILER_SUPPORTS_TARGET_BITS_FLAG to 'true' if it does 51612 51613 51614 51615 51616 51617 51618 51619 51620 51621 51622 51623 51624 51625 51626 51627 51628 51629 51630 51631 51632 51633 51634 51635 51636 51637 51638 51639 51640 51641 51642 51643 51644 51645 51646 51647 51648 51649 51650 51651 51652 51653 51654 51655 51656 51657 51658 51659 # Execute function body 51660 51661 51662 51663 51664 51665 51666 51667 51668 51669 51670 51671 51672 51673 51674 51675 51676 51677 51678 51679 51680 51681 51682 51683 51684 51685 51686 51687 51688 51689 51690 51691 51692 51693 51694 51695 51696 51697 51698 51699 51700 51701 51702 51703 51704 51705 51706 51707 51708 # Execute function body 51709 51710 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if the C compiler supports \"${COMPILER_TARGET_BITS_FLAG}${OPENJDK_TARGET_CPU_BITS}\"" >&5 51711 $as_echo_n "checking if the C compiler supports \"${COMPILER_TARGET_BITS_FLAG}${OPENJDK_TARGET_CPU_BITS}\"... " >&6; } 51712 supports=yes 51713 51714 saved_cflags="$CFLAGS" 51715 CFLAGS="$CFLAGS ${COMPILER_TARGET_BITS_FLAG}${OPENJDK_TARGET_CPU_BITS}" 51716 ac_ext=c 51717 ac_cpp='$CPP $CPPFLAGS' 51718 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5' 51719 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' 51720 ac_compiler_gnu=$ac_cv_c_compiler_gnu 51721 51722 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 51723 /* end confdefs.h. */ 51724 int i; 51725 _ACEOF 51726 if ac_fn_c_try_compile "$LINENO"; then : 51727 51728 else 51729 supports=no 51730 fi 51731 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext 51732 ac_ext=cpp 51733 ac_cpp='$CXXCPP $CPPFLAGS' 51734 ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5' 51735 ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' 51736 ac_compiler_gnu=$ac_cv_cxx_compiler_gnu 51737 51738 CFLAGS="$saved_cflags" 51739 51740 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $supports" >&5 51741 $as_echo "$supports" >&6; } 51742 if test "x$supports" = "xyes" ; then 51743 : 51744 C_COMP_SUPPORTS="yes" 51745 else 51746 : 51747 C_COMP_SUPPORTS="no" 51748 fi 51749 51750 51751 51752 51753 51754 51755 51756 51757 51758 51759 51760 51761 51762 51763 51764 51765 51766 51767 51768 51769 51770 51771 51772 51773 51774 51775 51776 51777 51778 51779 51780 51781 51782 51783 51784 51785 51786 51787 51788 51789 51790 51791 51792 51793 51794 51795 51796 51797 51798 51799 51800 51801 51802 51803 51804 51805 51806 51807 51808 # Execute function body 51809 51810 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if the C++ compiler supports \"${COMPILER_TARGET_BITS_FLAG}${OPENJDK_TARGET_CPU_BITS}\"" >&5 51811 $as_echo_n "checking if the C++ compiler supports \"${COMPILER_TARGET_BITS_FLAG}${OPENJDK_TARGET_CPU_BITS}\"... " >&6; } 51812 supports=yes 51813 51814 saved_cxxflags="$CXXFLAGS" 51815 CXXFLAGS="$CXXFLAG ${COMPILER_TARGET_BITS_FLAG}${OPENJDK_TARGET_CPU_BITS}" 51816 ac_ext=cpp 51817 ac_cpp='$CXXCPP $CPPFLAGS' 51818 ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5' 51819 ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' 51820 ac_compiler_gnu=$ac_cv_cxx_compiler_gnu 51821 51822 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 51823 /* end confdefs.h. */ 51824 int i; 51825 _ACEOF 51826 if ac_fn_cxx_try_compile "$LINENO"; then : 51827 51828 else 51829 supports=no 51830 fi 51831 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext 51832 ac_ext=cpp 51833 ac_cpp='$CXXCPP $CPPFLAGS' 51834 ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5' 51835 ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' 51836 ac_compiler_gnu=$ac_cv_cxx_compiler_gnu 51837 51838 CXXFLAGS="$saved_cxxflags" 51839 51840 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $supports" >&5 51841 $as_echo "$supports" >&6; } 51842 if test "x$supports" = "xyes" ; then 51843 : 51844 CXX_COMP_SUPPORTS="yes" 51845 else 51846 : 51847 CXX_COMP_SUPPORTS="no" 51848 fi 51849 51850 51851 51852 51853 51854 51855 51856 51857 51858 51859 51860 51861 51862 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if both compilers support \"${COMPILER_TARGET_BITS_FLAG}${OPENJDK_TARGET_CPU_BITS}\"" >&5 51863 $as_echo_n "checking if both compilers support \"${COMPILER_TARGET_BITS_FLAG}${OPENJDK_TARGET_CPU_BITS}\"... " >&6; } 51864 supports=no 51865 if test "x$C_COMP_SUPPORTS" = "xyes" -a "x$CXX_COMP_SUPPORTS" = "xyes"; then supports=yes; fi 51866 51867 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $supports" >&5 51868 $as_echo "$supports" >&6; } 51869 if test "x$supports" = "xyes" ; then 51870 : 51871 COMPILER_SUPPORTS_TARGET_BITS_FLAG=true 51872 else 51873 : 51874 COMPILER_SUPPORTS_TARGET_BITS_FLAG=false 51875 fi 51876 51877 51878 51879 51880 51881 51882 51883 51884 # Check whether --enable-warnings-as-errors was given. 51885 if test "${enable_warnings_as_errors+set}" = set; then : 51886 enableval=$enable_warnings_as_errors; 51887 fi 51888 51889 51890 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if native warnings are errors" >&5 51891 $as_echo_n "checking if native warnings are errors... " >&6; } 51892 if test "x$enable_warnings_as_errors" = "xyes"; then 51893 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes (explicitely set)" >&5 51894 $as_echo "yes (explicitely set)" >&6; } 51895 WARNINGS_AS_ERRORS=true 51896 elif test "x$enable_warnings_as_errors" = "xno"; then 51897 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 51898 $as_echo "no" >&6; } 51899 WARNINGS_AS_ERRORS=false 51900 elif test "x$enable_warnings_as_errors" = "x"; then 51901 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes (default)" >&5 51902 $as_echo "yes (default)" >&6; } 51903 WARNINGS_AS_ERRORS=true 51904 else 51905 as_fn_error $? "--enable-warnings-as-errors accepts no argument" "$LINENO" 5 51906 fi 51907 51908 if test "x$WARNINGS_AS_ERRORS" = "xfalse"; then 51909 # Set legacy hotspot variable 51910 HOTSPOT_SET_WARNINGS_AS_ERRORS="WARNINGS_ARE_ERRORS=" 51911 else 51912 HOTSPOT_SET_WARNINGS_AS_ERRORS="" 51913 fi 51914 51915 51916 51917 51918 case "${TOOLCHAIN_TYPE}" in 51919 microsoft) 51920 DISABLE_WARNING_PREFIX="-wd" 51921 CFLAGS_WARNINGS_ARE_ERRORS="-WX" 51922 ;; 51923 solstudio) 51924 DISABLE_WARNING_PREFIX="-erroff=" 51925 CFLAGS_WARNINGS_ARE_ERRORS="-errtags -errwarn=%all" 51926 ;; 51927 gcc) 51928 # Prior to gcc 4.4, a -Wno-X where X is unknown for that version of gcc will cause an error 51929 51930 51931 51932 51933 51934 51935 51936 51937 51938 51939 51940 51941 51942 51943 51944 51945 51946 51947 51948 51949 51950 51951 51952 51953 51954 51955 51956 51957 51958 51959 51960 51961 51962 51963 51964 51965 51966 51967 51968 51969 51970 51971 51972 51973 51974 51975 51976 # Execute function body 51977 51978 51979 51980 51981 51982 51983 51984 51985 51986 51987 51988 51989 51990 51991 51992 51993 51994 51995 51996 51997 51998 51999 52000 52001 52002 52003 52004 52005 52006 52007 52008 52009 52010 52011 52012 52013 52014 52015 52016 52017 52018 52019 52020 52021 52022 52023 52024 52025 # Execute function body 52026 52027 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if the C compiler supports \"-Wno-this-is-a-warning-that-do-not-exist\"" >&5 52028 $as_echo_n "checking if the C compiler supports \"-Wno-this-is-a-warning-that-do-not-exist\"... " >&6; } 52029 supports=yes 52030 52031 saved_cflags="$CFLAGS" 52032 CFLAGS="$CFLAGS -Wno-this-is-a-warning-that-do-not-exist" 52033 ac_ext=c 52034 ac_cpp='$CPP $CPPFLAGS' 52035 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5' 52036 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' 52037 ac_compiler_gnu=$ac_cv_c_compiler_gnu 52038 52039 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 52040 /* end confdefs.h. */ 52041 int i; 52042 _ACEOF 52043 if ac_fn_c_try_compile "$LINENO"; then : 52044 52045 else 52046 supports=no 52047 fi 52048 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext 52049 ac_ext=cpp 52050 ac_cpp='$CXXCPP $CPPFLAGS' 52051 ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5' 52052 ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' 52053 ac_compiler_gnu=$ac_cv_cxx_compiler_gnu 52054 52055 CFLAGS="$saved_cflags" 52056 52057 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $supports" >&5 52058 $as_echo "$supports" >&6; } 52059 if test "x$supports" = "xyes" ; then 52060 : 52061 C_COMP_SUPPORTS="yes" 52062 else 52063 : 52064 C_COMP_SUPPORTS="no" 52065 fi 52066 52067 52068 52069 52070 52071 52072 52073 52074 52075 52076 52077 52078 52079 52080 52081 52082 52083 52084 52085 52086 52087 52088 52089 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 # Execute function body 52126 52127 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if the C++ compiler supports \"-Wno-this-is-a-warning-that-do-not-exist\"" >&5 52128 $as_echo_n "checking if the C++ compiler supports \"-Wno-this-is-a-warning-that-do-not-exist\"... " >&6; } 52129 supports=yes 52130 52131 saved_cxxflags="$CXXFLAGS" 52132 CXXFLAGS="$CXXFLAG -Wno-this-is-a-warning-that-do-not-exist" 52133 ac_ext=cpp 52134 ac_cpp='$CXXCPP $CPPFLAGS' 52135 ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5' 52136 ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' 52137 ac_compiler_gnu=$ac_cv_cxx_compiler_gnu 52138 52139 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 52140 /* end confdefs.h. */ 52141 int i; 52142 _ACEOF 52143 if ac_fn_cxx_try_compile "$LINENO"; then : 52144 52145 else 52146 supports=no 52147 fi 52148 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext 52149 ac_ext=cpp 52150 ac_cpp='$CXXCPP $CPPFLAGS' 52151 ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5' 52152 ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' 52153 ac_compiler_gnu=$ac_cv_cxx_compiler_gnu 52154 52155 CXXFLAGS="$saved_cxxflags" 52156 52157 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $supports" >&5 52158 $as_echo "$supports" >&6; } 52159 if test "x$supports" = "xyes" ; then 52160 : 52161 CXX_COMP_SUPPORTS="yes" 52162 else 52163 : 52164 CXX_COMP_SUPPORTS="no" 52165 fi 52166 52167 52168 52169 52170 52171 52172 52173 52174 52175 52176 52177 52178 52179 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if both compilers support \"-Wno-this-is-a-warning-that-do-not-exist\"" >&5 52180 $as_echo_n "checking if both compilers support \"-Wno-this-is-a-warning-that-do-not-exist\"... " >&6; } 52181 supports=no 52182 if test "x$C_COMP_SUPPORTS" = "xyes" -a "x$CXX_COMP_SUPPORTS" = "xyes"; then supports=yes; fi 52183 52184 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $supports" >&5 52185 $as_echo "$supports" >&6; } 52186 if test "x$supports" = "xyes" ; then 52187 : 52188 GCC_CAN_DISABLE_WARNINGS=true 52189 else 52190 : 52191 GCC_CAN_DISABLE_WARNINGS=false 52192 52193 fi 52194 52195 52196 52197 52198 52199 52200 if test "x$GCC_CAN_DISABLE_WARNINGS" = "xtrue"; then 52201 DISABLE_WARNING_PREFIX="-Wno-" 52202 else 52203 DISABLE_WARNING_PREFIX= 52204 fi 52205 CFLAGS_WARNINGS_ARE_ERRORS="-Werror" 52206 # Repeate the check for the BUILD_CC and BUILD_CXX. Need to also reset 52207 # CFLAGS since any target specific flags will likely not work with the 52208 # build compiler 52209 CC_OLD="$CC" 52210 CXX_OLD="$CXX" 52211 CC="$BUILD_CC" 52212 CXX="$BUILD_CXX" 52213 CFLAGS_OLD="$CFLAGS" 52214 CFLAGS="" 52215 52216 52217 52218 52219 52220 52221 52222 52223 52224 52225 52226 52227 52228 52229 52230 52231 52232 52233 52234 52235 52236 52237 52238 52239 52240 52241 52242 52243 52244 52245 52246 52247 52248 52249 52250 52251 52252 52253 52254 52255 52256 52257 52258 52259 52260 52261 52262 # Execute function body 52263 52264 52265 52266 52267 52268 52269 52270 52271 52272 52273 52274 52275 52276 52277 52278 52279 52280 52281 52282 52283 52284 52285 52286 52287 52288 52289 52290 52291 52292 52293 52294 52295 52296 52297 52298 52299 52300 52301 52302 52303 52304 52305 52306 52307 52308 52309 52310 52311 # Execute function body 52312 52313 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if the C compiler supports \"-Wno-this-is-a-warning-that-do-not-exist\"" >&5 52314 $as_echo_n "checking if the C compiler supports \"-Wno-this-is-a-warning-that-do-not-exist\"... " >&6; } 52315 supports=yes 52316 52317 saved_cflags="$CFLAGS" 52318 CFLAGS="$CFLAGS -Wno-this-is-a-warning-that-do-not-exist" 52319 ac_ext=c 52320 ac_cpp='$CPP $CPPFLAGS' 52321 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5' 52322 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' 52323 ac_compiler_gnu=$ac_cv_c_compiler_gnu 52324 52325 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 52326 /* end confdefs.h. */ 52327 int i; 52328 _ACEOF 52329 if ac_fn_c_try_compile "$LINENO"; then : 52330 52331 else 52332 supports=no 52333 fi 52334 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext 52335 ac_ext=cpp 52336 ac_cpp='$CXXCPP $CPPFLAGS' 52337 ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5' 52338 ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' 52339 ac_compiler_gnu=$ac_cv_cxx_compiler_gnu 52340 52341 CFLAGS="$saved_cflags" 52342 52343 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $supports" >&5 52344 $as_echo "$supports" >&6; } 52345 if test "x$supports" = "xyes" ; then 52346 : 52347 C_COMP_SUPPORTS="yes" 52348 else 52349 : 52350 C_COMP_SUPPORTS="no" 52351 fi 52352 52353 52354 52355 52356 52357 52358 52359 52360 52361 52362 52363 52364 52365 52366 52367 52368 52369 52370 52371 52372 52373 52374 52375 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 # Execute function body 52412 52413 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if the C++ compiler supports \"-Wno-this-is-a-warning-that-do-not-exist\"" >&5 52414 $as_echo_n "checking if the C++ compiler supports \"-Wno-this-is-a-warning-that-do-not-exist\"... " >&6; } 52415 supports=yes 52416 52417 saved_cxxflags="$CXXFLAGS" 52418 CXXFLAGS="$CXXFLAG -Wno-this-is-a-warning-that-do-not-exist" 52419 ac_ext=cpp 52420 ac_cpp='$CXXCPP $CPPFLAGS' 52421 ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5' 52422 ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' 52423 ac_compiler_gnu=$ac_cv_cxx_compiler_gnu 52424 52425 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 52426 /* end confdefs.h. */ 52427 int i; 52428 _ACEOF 52429 if ac_fn_cxx_try_compile "$LINENO"; then : 52430 52431 else 52432 supports=no 52433 fi 52434 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext 52435 ac_ext=cpp 52436 ac_cpp='$CXXCPP $CPPFLAGS' 52437 ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5' 52438 ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' 52439 ac_compiler_gnu=$ac_cv_cxx_compiler_gnu 52440 52441 CXXFLAGS="$saved_cxxflags" 52442 52443 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $supports" >&5 52444 $as_echo "$supports" >&6; } 52445 if test "x$supports" = "xyes" ; then 52446 : 52447 CXX_COMP_SUPPORTS="yes" 52448 else 52449 : 52450 CXX_COMP_SUPPORTS="no" 52451 fi 52452 52453 52454 52455 52456 52457 52458 52459 52460 52461 52462 52463 52464 52465 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if both compilers support \"-Wno-this-is-a-warning-that-do-not-exist\"" >&5 52466 $as_echo_n "checking if both compilers support \"-Wno-this-is-a-warning-that-do-not-exist\"... " >&6; } 52467 supports=no 52468 if test "x$C_COMP_SUPPORTS" = "xyes" -a "x$CXX_COMP_SUPPORTS" = "xyes"; then supports=yes; fi 52469 52470 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $supports" >&5 52471 $as_echo "$supports" >&6; } 52472 if test "x$supports" = "xyes" ; then 52473 : 52474 BUILD_CC_CAN_DISABLE_WARNINGS=true 52475 else 52476 : 52477 BUILD_CC_CAN_DISABLE_WARNINGS=false 52478 52479 fi 52480 52481 52482 52483 52484 52485 52486 if test "x$BUILD_CC_CAN_DISABLE_WARNINGS" = "xtrue"; then 52487 BUILD_CC_DISABLE_WARNING_PREFIX="-Wno-" 52488 else 52489 BUILD_CC_DISABLE_WARNING_PREFIX= 52490 fi 52491 CC="$CC_OLD" 52492 CXX="$CXX_OLD" 52493 CFLAGS="$CFLAGS_OLD" 52494 ;; 52495 clang) 52496 DISABLE_WARNING_PREFIX="-Wno-" 52497 CFLAGS_WARNINGS_ARE_ERRORS="-Werror" 52498 ;; 52499 xlc) 52500 DISABLE_WARNING_PREFIX="-qsuppress=" 52501 CFLAGS_WARNINGS_ARE_ERRORS="-qhalt=w" 52502 ;; 52503 esac 52504 52505 52506 52507 52508 52509 # Setup debug symbols (need objcopy from the toolchain for that) 52510 52511 # 52512 # NATIVE_DEBUG_SYMBOLS 52513 # This must be done after the toolchain is setup, since we're looking at objcopy. 52514 # 52515 { $as_echo "$as_me:${as_lineno-$LINENO}: checking what type of native debug symbols to use" >&5 52516 $as_echo_n "checking what type of native debug symbols to use... " >&6; } 52517 52518 # Check whether --with-native-debug-symbols was given. 52519 if test "${with_native_debug_symbols+set}" = set; then : 52520 withval=$with_native_debug_symbols; 52521 if test "x$OPENJDK_TARGET_OS" = xaix; then 52522 if test "x$withval" = xexternal || test "x$withval" = xzipped; then 52523 as_fn_error $? "AIX only supports the parameters 'none' and 'internal' for --with-native-debug-symbols" "$LINENO" 5 52524 fi 52525 fi 52526 52527 else 52528 52529 if test "x$OPENJDK_TARGET_OS" = xaix; then 52530 # AIX doesn't support 'zipped' so use 'internal' as default 52531 with_native_debug_symbols="internal" 52532 else 52533 if test "x$STATIC_BUILD" = xtrue; then 52534 with_native_debug_symbols="none" 52535 else 52536 with_native_debug_symbols="zipped" 52537 fi 52538 fi 52539 52540 fi 52541 52542 NATIVE_DEBUG_SYMBOLS=$with_native_debug_symbols 52543 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $NATIVE_DEBUG_SYMBOLS" >&5 52544 $as_echo "$NATIVE_DEBUG_SYMBOLS" >&6; } 52545 52546 if test "x$NATIVE_DEBUG_SYMBOLS" = xzipped; then 52547 52548 if test "x$OPENJDK_TARGET_OS" = xsolaris || test "x$OPENJDK_TARGET_OS" = xlinux; then 52549 if test "x$OBJCOPY" = x; then 52550 # enabling of enable-debug-symbols and can't find objcopy 52551 # this is an error 52552 as_fn_error $? "Unable to find objcopy, cannot enable native debug symbols" "$LINENO" 5 52553 fi 52554 fi 52555 52556 COMPILE_WITH_DEBUG_SYMBOLS=true 52557 COPY_DEBUG_SYMBOLS=true 52558 ZIP_EXTERNAL_DEBUG_SYMBOLS=true 52559 52560 # Hotspot legacy support, not relevant with COPY_DEBUG_SYMBOLS=true 52561 DEBUG_BINARIES=false 52562 STRIP_POLICY=min_strip 52563 52564 elif test "x$NATIVE_DEBUG_SYMBOLS" = xnone; then 52565 COMPILE_WITH_DEBUG_SYMBOLS=false 52566 COPY_DEBUG_SYMBOLS=false 52567 ZIP_EXTERNAL_DEBUG_SYMBOLS=false 52568 52569 DEBUG_BINARIES=false 52570 STRIP_POLICY=no_strip 52571 elif test "x$NATIVE_DEBUG_SYMBOLS" = xinternal; then 52572 COMPILE_WITH_DEBUG_SYMBOLS=true 52573 COPY_DEBUG_SYMBOLS=false 52574 ZIP_EXTERNAL_DEBUG_SYMBOLS=false 52575 52576 # Hotspot legacy support, will turn on -g when COPY_DEBUG_SYMBOLS=false 52577 DEBUG_BINARIES=true 52578 STRIP_POLICY=no_strip 52579 STRIP="" 52580 52581 elif test "x$NATIVE_DEBUG_SYMBOLS" = xexternal; then 52582 52583 if test "x$OPENJDK_TARGET_OS" = xsolaris || test "x$OPENJDK_TARGET_OS" = xlinux; then 52584 if test "x$OBJCOPY" = x; then 52585 # enabling of enable-debug-symbols and can't find objcopy 52586 # this is an error 52587 as_fn_error $? "Unable to find objcopy, cannot enable native debug symbols" "$LINENO" 5 52588 fi 52589 fi 52590 52591 COMPILE_WITH_DEBUG_SYMBOLS=true 52592 COPY_DEBUG_SYMBOLS=true 52593 ZIP_EXTERNAL_DEBUG_SYMBOLS=false 52594 52595 # Hotspot legacy support, not relevant with COPY_DEBUG_SYMBOLS=true 52596 DEBUG_BINARIES=false 52597 STRIP_POLICY=min_strip 52598 else 52599 as_fn_error $? "Allowed native debug symbols are: none, internal, external, zipped" "$LINENO" 5 52600 fi 52601 52602 # --enable-debug-symbols is deprecated. 52603 # Please use --with-native-debug-symbols=[internal,external,zipped] . 52604 52605 # Check whether --enable-debug-symbols was given. 52606 if test "${enable_debug_symbols+set}" = set; then : 52607 enableval=$enable_debug_symbols; 52608 fi 52609 52610 if test "x$enable_debug_symbols" != x; then 52611 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Option --enable-debug-symbols is deprecated and will be ignored." >&5 52612 $as_echo "$as_me: WARNING: Option --enable-debug-symbols is deprecated and will be ignored." >&2;} 52613 52614 if test "xPlease use --with-native-debug-symbols=[internal,external,zipped] ." != x; then 52615 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Please use --with-native-debug-symbols=[internal,external,zipped] ." >&5 52616 $as_echo "$as_me: WARNING: Please use --with-native-debug-symbols=[internal,external,zipped] ." >&2;} 52617 fi 52618 52619 fi 52620 52621 52622 # --enable-zip-debug-info is deprecated. 52623 # Please use --with-native-debug-symbols=zipped . 52624 52625 # Check whether --enable-zip-debug-info was given. 52626 if test "${enable_zip_debug_info+set}" = set; then : 52627 enableval=$enable_zip_debug_info; 52628 fi 52629 52630 if test "x$enable_zip_debug_info" != x; then 52631 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Option --enable-zip-debug-info is deprecated and will be ignored." >&5 52632 $as_echo "$as_me: WARNING: Option --enable-zip-debug-info is deprecated and will be ignored." >&2;} 52633 52634 if test "xPlease use --with-native-debug-symbols=zipped ." != x; then 52635 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Please use --with-native-debug-symbols=zipped ." >&5 52636 $as_echo "$as_me: WARNING: Please use --with-native-debug-symbols=zipped ." >&2;} 52637 fi 52638 52639 fi 52640 52641 52642 52643 52644 52645 52646 # Legacy values 52647 52648 52649 52650 52651 # Check whether --enable-native-coverage was given. 52652 if test "${enable_native_coverage+set}" = set; then : 52653 enableval=$enable_native_coverage; 52654 fi 52655 52656 GCOV_ENABLED="false" 52657 if test "x$enable_native_coverage" = "xyes"; then 52658 if test "x$TOOLCHAIN_TYPE" = "xgcc"; then 52659 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if native coverage is enabled" >&5 52660 $as_echo_n "checking if native coverage is enabled... " >&6; } 52661 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 52662 $as_echo "yes" >&6; } 52663 GCOV_CFLAGS="-fprofile-arcs -ftest-coverage -fno-inline" 52664 GCOV_LDFLAGS="-fprofile-arcs" 52665 LEGACY_EXTRA_CFLAGS="$LEGACY_EXTRA_CFLAGS $GCOV_CFLAGS" 52666 LEGACY_EXTRA_CXXFLAGS="$LEGACY_EXTRA_CXXFLAGS $GCOV_CFLAGS" 52667 LEGACY_EXTRA_LDFLAGS="$LEGACY_EXTRA_LDFLAGS $GCOV_LDFLAGS" 52668 CFLAGS_JDKLIB="$CFLAGS_JDKLIB $GCOV_CFLAGS" 52669 CFLAGS_JDKEXE="$CFLAGS_JDKEXE $GCOV_CFLAGS" 52670 CXXFLAGS_JDKLIB="$CXXFLAGS_JDKLIB $GCOV_CFLAGS" 52671 CXXFLAGS_JDKEXE="$CXXFLAGS_JDKEXE $GCOV_CFLAGS" 52672 LDFLAGS_JDKLIB="$LDFLAGS_JDKLIB $GCOV_LDFLAGS" 52673 LDFLAGS_JDKEXE="$LDFLAGS_JDKEXE $GCOV_LDFLAGS" 52674 GCOV_ENABLED="true" 52675 else 52676 as_fn_error $? "--enable-native-coverage only works with toolchain type gcc" "$LINENO" 5 52677 fi 52678 elif test "x$enable_native_coverage" = "xno"; then 52679 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if native coverage is enabled" >&5 52680 $as_echo_n "checking if native coverage is enabled... " >&6; } 52681 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 52682 $as_echo "no" >&6; } 52683 elif test "x$enable_native_coverage" != "x"; then 52684 as_fn_error $? "--enable-native-coverage can only be assigned \"yes\" or \"no\"" "$LINENO" 5 52685 fi 52686 52687 52688 52689 52690 # Need toolchain to setup dtrace 52691 52692 # Test for dtrace dependencies 52693 # Check whether --enable-dtrace was given. 52694 if test "${enable_dtrace+set}" = set; then : 52695 enableval=$enable_dtrace; 52696 fi 52697 52698 52699 DTRACE_DEP_MISSING=false 52700 52701 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for dtrace tool" >&5 52702 $as_echo_n "checking for dtrace tool... " >&6; } 52703 if test "x$DTRACE" != "x" && test -x "$DTRACE"; then 52704 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $DTRACE" >&5 52705 $as_echo "$DTRACE" >&6; } 52706 else 52707 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found, cannot build dtrace" >&5 52708 $as_echo "not found, cannot build dtrace" >&6; } 52709 DTRACE_DEP_MISSING=true 52710 fi 52711 52712 for ac_header in sys/sdt.h 52713 do : 52714 ac_fn_cxx_check_header_mongrel "$LINENO" "sys/sdt.h" "ac_cv_header_sys_sdt_h" "$ac_includes_default" 52715 if test "x$ac_cv_header_sys_sdt_h" = xyes; then : 52716 cat >>confdefs.h <<_ACEOF 52717 #define HAVE_SYS_SDT_H 1 52718 _ACEOF 52719 DTRACE_HEADERS_OK=yes 52720 else 52721 DTRACE_HEADERS_OK=no 52722 fi 52723 52724 done 52725 52726 if test "x$DTRACE_HEADERS_OK" != "xyes"; then 52727 DTRACE_DEP_MISSING=true 52728 fi 52729 52730 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if dtrace should be built" >&5 52731 $as_echo_n "checking if dtrace should be built... " >&6; } 52732 if test "x$enable_dtrace" = "xyes"; then 52733 if test "x$DTRACE_DEP_MISSING" = "xtrue"; then 52734 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no, missing dependencies" >&5 52735 $as_echo "no, missing dependencies" >&6; } 52736 52737 # Print a helpful message on how to acquire the necessary build dependency. 52738 # dtrace is the help tag: freetype, cups, alsa etc 52739 MISSING_DEPENDENCY=dtrace 52740 52741 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 52742 cygwin_help $MISSING_DEPENDENCY 52743 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 52744 msys_help $MISSING_DEPENDENCY 52745 else 52746 PKGHANDLER_COMMAND= 52747 52748 case $PKGHANDLER in 52749 apt-get) 52750 apt_help $MISSING_DEPENDENCY ;; 52751 yum) 52752 yum_help $MISSING_DEPENDENCY ;; 52753 port) 52754 port_help $MISSING_DEPENDENCY ;; 52755 pkgutil) 52756 pkgutil_help $MISSING_DEPENDENCY ;; 52757 pkgadd) 52758 pkgadd_help $MISSING_DEPENDENCY ;; 52759 esac 52760 52761 if test "x$PKGHANDLER_COMMAND" != x; then 52762 HELP_MSG="You might be able to fix this by running '$PKGHANDLER_COMMAND'." 52763 fi 52764 fi 52765 52766 as_fn_error $? "Cannot enable dtrace with missing dependencies. See above. $HELP_MSG" "$LINENO" 5 52767 else 52768 INCLUDE_DTRACE=true 52769 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes, forced" >&5 52770 $as_echo "yes, forced" >&6; } 52771 fi 52772 elif test "x$enable_dtrace" = "xno"; then 52773 INCLUDE_DTRACE=false 52774 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no, forced" >&5 52775 $as_echo "no, forced" >&6; } 52776 elif test "x$enable_dtrace" = "xauto" || test "x$enable_dtrace" = "x"; then 52777 if test "x$DTRACE_DEP_MISSING" = "xtrue"; then 52778 INCLUDE_DTRACE=false 52779 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no, missing dependencies" >&5 52780 $as_echo "no, missing dependencies" >&6; } 52781 else 52782 INCLUDE_DTRACE=true 52783 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes, dependencies present" >&5 52784 $as_echo "yes, dependencies present" >&6; } 52785 fi 52786 else 52787 as_fn_error $? "Invalid value for --enable-dtrace: $enable_dtrace" "$LINENO" 5 52788 fi 52789 52790 52791 52792 # The user can in some cases supply additional jvm features. For the custom 52793 # variant, this defines the entire variant. 52794 52795 # Check whether --with-jvm-features was given. 52796 if test "${with_jvm_features+set}" = set; then : 52797 withval=$with_jvm_features; 52798 fi 52799 52800 if test "x$with_jvm_features" != x; then 52801 { $as_echo "$as_me:${as_lineno-$LINENO}: checking additional JVM features" >&5 52802 $as_echo_n "checking additional JVM features... " >&6; } 52803 JVM_FEATURES=`$ECHO $with_jvm_features | $SED -e 's/,/ /g'` 52804 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $JVM_FEATURES" >&5 52805 $as_echo "$JVM_FEATURES" >&6; } 52806 fi 52807 52808 # Verify that dependencies are met for explicitly set features. 52809 if [[ " $JVM_FEATURES " =~ " jvmti " ]] && ! [[ " $JVM_FEATURES " =~ " services " ]] ; then 52810 as_fn_error $? "Specified JVM feature 'jvmti' requires feature 'services'" "$LINENO" 5 52811 fi 52812 52813 if [[ " $JVM_FEATURES " =~ " management " ]] && ! [[ " $JVM_FEATURES " =~ " nmt " ]] ; then 52814 as_fn_error $? "Specified JVM feature 'management' requires feature 'nmt'" "$LINENO" 5 52815 fi 52816 52817 if [[ " $JVM_FEATURES " =~ " jvmci " ]] && ! ( [[ " $JVM_FEATURES " =~ " compiler1 " ]] || [[ " $JVM_FEATURES " =~ " compiler2 " ]] ); then 52818 as_fn_error $? "Specified JVM feature 'jvmci' requires feature 'compiler2' or 'compiler1'" "$LINENO" 5 52819 fi 52820 52821 if [[ " $JVM_FEATURES " =~ " compiler2 " ]] && ! [[ " $JVM_FEATURES " =~ " all-gcs " ]] ; then 52822 as_fn_error $? "Specified JVM feature 'compiler2' requires feature 'all-gcs'" "$LINENO" 5 52823 fi 52824 52825 if [[ " $JVM_FEATURES " =~ " vm-structs " ]] && ! [[ " $JVM_FEATURES " =~ " all-gcs " ]] ; then 52826 as_fn_error $? "Specified JVM feature 'vm-structs' requires feature 'all-gcs'" "$LINENO" 5 52827 fi 52828 52829 # Turn on additional features based on other parts of configure 52830 if test "x$INCLUDE_DTRACE" = "xtrue"; then 52831 JVM_FEATURES="$JVM_FEATURES dtrace" 52832 else 52833 if [[ " $JVM_FEATURES " =~ " dtrace " ]] ; then 52834 as_fn_error $? "To enable dtrace, you must use --enable-dtrace" "$LINENO" 5 52835 fi 52836 fi 52837 52838 if test "x$STATIC_BUILD" = "xtrue"; then 52839 JVM_FEATURES="$JVM_FEATURES static-build" 52840 else 52841 if [[ " $JVM_FEATURES " =~ " static-build " ]] ; then 52842 as_fn_error $? "To enable static-build, you must use --enable-static-build" "$LINENO" 5 52843 fi 52844 fi 52845 52846 if ! [[ " $JVM_VARIANTS " =~ " zero " ]] && ! [[ " $JVM_VARIANTS " =~ " zeroshark " ]] ; then 52847 if [[ " $JVM_FEATURES " =~ " zero " ]] ; then 52848 as_fn_error $? "To enable zero/zeroshark, you must use --with-jvm-variants=zero/zeroshark" "$LINENO" 5 52849 fi 52850 fi 52851 52852 if ! [[ " $JVM_VARIANTS " =~ " zeroshark " ]] ; then 52853 if [[ " $JVM_FEATURES " =~ " shark " ]] ; then 52854 as_fn_error $? "To enable shark, you must use --with-jvm-variants=zeroshark" "$LINENO" 5 52855 fi 52856 fi 52857 52858 # Only enable jvmci on x86_64, sparcv9 and aarch64. 52859 if test "x$OPENJDK_TARGET_CPU" = "xx86_64" || \ 52860 test "x$OPENJDK_TARGET_CPU" = "xsparcv9" || \ 52861 test "x$OPENJDK_TARGET_CPU" = "xaarch64" ; then 52862 JVM_FEATURES_jvmci="jvmci" 52863 else 52864 JVM_FEATURES_jvmci="" 52865 fi 52866 52867 # All variants but minimal (and custom) get these features 52868 NON_MINIMAL_FEATURES="$NON_MINIMAL_FEATURES jvmti fprof vm-structs jni-check services management all-gcs nmt cds" 52869 52870 # Enable features depending on variant. 52871 JVM_FEATURES_server="compiler1 compiler2 $NON_MINIMAL_FEATURES $JVM_FEATURES $JVM_FEATURES_jvmci" 52872 JVM_FEATURES_client="compiler1 $NON_MINIMAL_FEATURES $JVM_FEATURES $JVM_FEATURES_jvmci" 52873 JVM_FEATURES_core="$NON_MINIMAL_FEATURES $JVM_FEATURES" 52874 JVM_FEATURES_minimal="compiler1 minimal $JVM_FEATURES" 52875 JVM_FEATURES_zero="zero $NON_MINIMAL_FEATURES $JVM_FEATURES" 52876 JVM_FEATURES_zeroshark="zero shark $NON_MINIMAL_FEATURES $JVM_FEATURES" 52877 JVM_FEATURES_custom="$JVM_FEATURES" 52878 52879 52880 52881 52882 52883 52884 52885 52886 52887 # Used for verification of Makefiles by check-jvm-feature 52888 52889 52890 # We don't support --with-jvm-interpreter anymore, use zero instead. 52891 52892 52893 # Check whether --with-jvm-interpreter was given. 52894 if test "${with_jvm_interpreter+set}" = set; then : 52895 withval=$with_jvm_interpreter; { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Option --with-jvm-interpreter is deprecated and will be ignored." >&5 52896 $as_echo "$as_me: WARNING: Option --with-jvm-interpreter is deprecated and will be ignored." >&2;} 52897 fi 52898 52899 52900 52901 52902 # Check whether --enable-hotspot-gtest was given. 52903 if test "${enable_hotspot_gtest+set}" = set; then : 52904 enableval=$enable_hotspot_gtest; 52905 fi 52906 52907 52908 if test -e "$HOTSPOT_TOPDIR/test/native"; then 52909 GTEST_DIR_EXISTS="true" 52910 else 52911 GTEST_DIR_EXISTS="false" 52912 fi 52913 52914 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if Hotspot gtest unit tests should be built" >&5 52915 $as_echo_n "checking if Hotspot gtest unit tests should be built... " >&6; } 52916 if test "x$enable_hotspot_gtest" = "xyes"; then 52917 if test "x$GTEST_DIR_EXISTS" = "xtrue"; then 52918 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes, forced" >&5 52919 $as_echo "yes, forced" >&6; } 52920 BUILD_GTEST="true" 52921 else 52922 as_fn_error $? "Cannot build gtest without the test source" "$LINENO" 5 52923 fi 52924 elif test "x$enable_hotspot_gtest" = "xno"; then 52925 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no, forced" >&5 52926 $as_echo "no, forced" >&6; } 52927 BUILD_GTEST="false" 52928 elif test "x$enable_hotspot_gtest" = "x"; then 52929 if test "x$GTEST_DIR_EXISTS" = "xtrue" && test "x$OPENJDK_TARGET_OS" != "xaix"; then 52930 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 52931 $as_echo "yes" >&6; } 52932 BUILD_GTEST="true" 52933 else 52934 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 52935 $as_echo "no" >&6; } 52936 BUILD_GTEST="false" 52937 fi 52938 else 52939 as_fn_error $? "--enable-gtest must be either yes or no" "$LINENO" 5 52940 fi 52941 52942 52943 52944 52945 ############################################################################### 52946 # 52947 # Check dependencies for external and internal libraries. 52948 # 52949 ############################################################################### 52950 52951 # After we have toolchain, we can compile fixpath. It's needed by the lib checks. 52952 52953 # When using cygwin or msys, we need a wrapper binary that renames 52954 # /cygdrive/c/ arguments into c:/ arguments and peeks into 52955 # @files and rewrites these too! This wrapper binary is 52956 # called fixpath. 52957 FIXPATH= 52958 if test "x$OPENJDK_BUILD_OS" = xwindows; then 52959 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if fixpath can be created" >&5 52960 $as_echo_n "checking if fixpath can be created... " >&6; } 52961 FIXPATH_SRC="$SRC_ROOT/common/src/fixpath.c" 52962 FIXPATH_BIN="$CONFIGURESUPPORT_OUTPUTDIR/bin/fixpath.exe" 52963 FIXPATH_DIR="$CONFIGURESUPPORT_OUTPUTDIR/fixpath" 52964 if test "x$OPENJDK_BUILD_OS_ENV" = xwindows.cygwin; then 52965 # Important to keep the .exe suffix on Cygwin for Hotspot makefiles 52966 FIXPATH="$FIXPATH_BIN -c" 52967 elif test "x$OPENJDK_BUILD_OS_ENV" = xwindows.msys; then 52968 # Take all collected prefixes and turn them into a -m/c/foo@/c/bar@... command line 52969 # @ was chosen as separator to minimize risk of other tools messing around with it 52970 all_unique_prefixes=`echo "${all_fixpath_prefixes[@]}" \ 52971 | tr ' ' '\n' | $GREP '^/./' | $SORT | $UNIQ` 52972 fixpath_argument_list=`echo $all_unique_prefixes | tr ' ' '@'` 52973 FIXPATH="$FIXPATH_BIN -m$fixpath_argument_list" 52974 fi 52975 FIXPATH_SRC_W="$FIXPATH_SRC" 52976 FIXPATH_BIN_W="$FIXPATH_BIN" 52977 52978 unix_path="$FIXPATH_SRC_W" 52979 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 52980 windows_path=`$CYGPATH -m "$unix_path"` 52981 FIXPATH_SRC_W="$windows_path" 52982 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 52983 windows_path=`cmd //c echo $unix_path` 52984 FIXPATH_SRC_W="$windows_path" 52985 fi 52986 52987 52988 unix_path="$FIXPATH_BIN_W" 52989 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 52990 windows_path=`$CYGPATH -m "$unix_path"` 52991 FIXPATH_BIN_W="$windows_path" 52992 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 52993 windows_path=`cmd //c echo $unix_path` 52994 FIXPATH_BIN_W="$windows_path" 52995 fi 52996 52997 $RM -rf $FIXPATH_BIN $FIXPATH_DIR 52998 $MKDIR -p $FIXPATH_DIR $CONFIGURESUPPORT_OUTPUTDIR/bin 52999 cd $FIXPATH_DIR 53000 $CC $FIXPATH_SRC_W -Fe$FIXPATH_BIN_W > $FIXPATH_DIR/fixpath1.log 2>&1 53001 cd $CURDIR 53002 53003 if test ! -x $FIXPATH_BIN; then 53004 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 53005 $as_echo "no" >&6; } 53006 cat $FIXPATH_DIR/fixpath1.log 53007 as_fn_error $? "Could not create $FIXPATH_BIN" "$LINENO" 5 53008 fi 53009 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 53010 $as_echo "yes" >&6; } 53011 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if fixpath.exe works" >&5 53012 $as_echo_n "checking if fixpath.exe works... " >&6; } 53013 cd $FIXPATH_DIR 53014 $FIXPATH $CC $FIXPATH_SRC -Fe$FIXPATH_DIR/fixpath2.exe \ 53015 > $FIXPATH_DIR/fixpath2.log 2>&1 53016 cd $CURDIR 53017 if test ! -x $FIXPATH_DIR/fixpath2.exe; then 53018 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 53019 $as_echo "no" >&6; } 53020 cat $FIXPATH_DIR/fixpath2.log 53021 as_fn_error $? "fixpath did not work!" "$LINENO" 5 53022 fi 53023 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 53024 $as_echo "yes" >&6; } 53025 53026 FIXPATH_DETACH_FLAG="--detach" 53027 fi 53028 53029 53030 53031 53032 53033 53034 # Check if X11 is needed 53035 if test "x$OPENJDK_TARGET_OS" = xwindows || test "x$OPENJDK_TARGET_OS" = xmacosx; then 53036 # No X11 support on windows or macosx 53037 NEEDS_LIB_X11=false 53038 else 53039 # All other instances need X11, even if building headless only, libawt still 53040 # needs X11 headers. 53041 NEEDS_LIB_X11=true 53042 fi 53043 53044 # Check if cups is needed 53045 if test "x$OPENJDK_TARGET_OS" = xwindows; then 53046 # Windows have a separate print system 53047 NEEDS_LIB_CUPS=false 53048 else 53049 NEEDS_LIB_CUPS=true 53050 fi 53051 53052 # A custom hook may have set this already 53053 if test "x$NEEDS_LIB_FREETYPE" = "x"; then 53054 NEEDS_LIB_FREETYPE=true 53055 fi 53056 53057 # Check if alsa is needed 53058 if test "x$OPENJDK_TARGET_OS" = xlinux; then 53059 NEEDS_LIB_ALSA=true 53060 else 53061 NEEDS_LIB_ALSA=false 53062 fi 53063 53064 # Check if ffi is needed 53065 if [[ " $JVM_VARIANTS " =~ " zero " ]] || [[ " $JVM_VARIANTS " =~ " zeroshark " ]] ; then 53066 NEEDS_LIB_FFI=true 53067 else 53068 NEEDS_LIB_FFI=false 53069 fi 53070 53071 53072 # statically link libstdc++ before C++ ABI is stablized on Linux unless 53073 # dynamic build is configured on command line. 53074 53075 # Check whether --with-stdc++lib was given. 53076 if test "${with_stdc__lib+set}" = set; then : 53077 withval=$with_stdc__lib; 53078 if test "x$with_stdc__lib" != xdynamic && test "x$with_stdc__lib" != xstatic \ 53079 && test "x$with_stdc__lib" != xdefault; then 53080 as_fn_error $? "Bad parameter value --with-stdc++lib=$with_stdc__lib!" "$LINENO" 5 53081 fi 53082 53083 else 53084 with_stdc__lib=default 53085 53086 fi 53087 53088 53089 if test "x$OPENJDK_TARGET_OS" = xlinux; then 53090 # Test if -lstdc++ works. 53091 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if dynamic link of stdc++ is possible" >&5 53092 $as_echo_n "checking if dynamic link of stdc++ is possible... " >&6; } 53093 ac_ext=cpp 53094 ac_cpp='$CXXCPP $CPPFLAGS' 53095 ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5' 53096 ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' 53097 ac_compiler_gnu=$ac_cv_cxx_compiler_gnu 53098 53099 OLD_CXXFLAGS="$CXXFLAGS" 53100 CXXFLAGS="$CXXFLAGS -lstdc++" 53101 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 53102 /* end confdefs.h. */ 53103 53104 int 53105 main () 53106 { 53107 return 0; 53108 ; 53109 return 0; 53110 } 53111 _ACEOF 53112 if ac_fn_cxx_try_link "$LINENO"; then : 53113 has_dynamic_libstdcxx=yes 53114 else 53115 has_dynamic_libstdcxx=no 53116 fi 53117 rm -f core conftest.err conftest.$ac_objext \ 53118 conftest$ac_exeext conftest.$ac_ext 53119 CXXFLAGS="$OLD_CXXFLAGS" 53120 ac_ext=cpp 53121 ac_cpp='$CXXCPP $CPPFLAGS' 53122 ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5' 53123 ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' 53124 ac_compiler_gnu=$ac_cv_cxx_compiler_gnu 53125 53126 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $has_dynamic_libstdcxx" >&5 53127 $as_echo "$has_dynamic_libstdcxx" >&6; } 53128 53129 # Test if stdc++ can be linked statically. 53130 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if static link of stdc++ is possible" >&5 53131 $as_echo_n "checking if static link of stdc++ is possible... " >&6; } 53132 STATIC_STDCXX_FLAGS="-Wl,-Bstatic -lstdc++ -lgcc -Wl,-Bdynamic" 53133 ac_ext=cpp 53134 ac_cpp='$CXXCPP $CPPFLAGS' 53135 ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5' 53136 ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' 53137 ac_compiler_gnu=$ac_cv_cxx_compiler_gnu 53138 53139 OLD_LIBS="$LIBS" 53140 OLD_CXX="$CXX" 53141 LIBS="$STATIC_STDCXX_FLAGS" 53142 CXX="$CC" 53143 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 53144 /* end confdefs.h. */ 53145 53146 int 53147 main () 53148 { 53149 return 0; 53150 ; 53151 return 0; 53152 } 53153 _ACEOF 53154 if ac_fn_cxx_try_link "$LINENO"; then : 53155 has_static_libstdcxx=yes 53156 else 53157 has_static_libstdcxx=no 53158 fi 53159 rm -f core conftest.err conftest.$ac_objext \ 53160 conftest$ac_exeext conftest.$ac_ext 53161 LIBS="$OLD_LIBS" 53162 CXX="$OLD_CXX" 53163 ac_ext=cpp 53164 ac_cpp='$CXXCPP $CPPFLAGS' 53165 ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5' 53166 ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' 53167 ac_compiler_gnu=$ac_cv_cxx_compiler_gnu 53168 53169 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $has_static_libstdcxx" >&5 53170 $as_echo "$has_static_libstdcxx" >&6; } 53171 53172 if test "x$has_static_libstdcxx" = xno && test "x$has_dynamic_libstdcxx" = xno; then 53173 as_fn_error $? "Cannot link to stdc++, neither dynamically nor statically!" "$LINENO" 5 53174 fi 53175 53176 if test "x$with_stdc__lib" = xstatic && test "x$has_static_libstdcxx" = xno; then 53177 as_fn_error $? "Static linking of libstdc++ was not possible!" "$LINENO" 5 53178 fi 53179 53180 if test "x$with_stdc__lib" = xdynamic && test "x$has_dynamic_libstdcxx" = xno; then 53181 as_fn_error $? "Dynamic linking of libstdc++ was not possible!" "$LINENO" 5 53182 fi 53183 53184 # If dynamic was requested, it's available since it would fail above otherwise. 53185 # If dynamic wasn't requested, go with static unless it isn't available. 53186 { $as_echo "$as_me:${as_lineno-$LINENO}: checking how to link with libstdc++" >&5 53187 $as_echo_n "checking how to link with libstdc++... " >&6; } 53188 if test "x$with_stdc__lib" = xdynamic || test "x$has_static_libstdcxx" = xno || [[ " $JVM_VARIANTS " =~ " zeroshark " ]] ; then 53189 LIBCXX="$LIBCXX -lstdc++" 53190 # To help comparisons with old build, put stdc++ first in JVM_LIBS 53191 JVM_LIBS="-lstdc++ $JVM_LIBS" 53192 # Ideally, we should test stdc++ for the BUILD toolchain separately. For now 53193 # just use the same setting as for the TARGET toolchain. 53194 OPENJDK_BUILD_JVM_LIBS="-lstdc++ $OPENJDK_BUILD_JVM_LIBS" 53195 LDCXX="$CXX" 53196 STATIC_CXX_SETTING="STATIC_CXX=false" 53197 { $as_echo "$as_me:${as_lineno-$LINENO}: result: dynamic" >&5 53198 $as_echo "dynamic" >&6; } 53199 else 53200 LIBCXX="$LIBCXX $STATIC_STDCXX_FLAGS" 53201 JVM_LDFLAGS="$JVM_LDFLAGS -static-libgcc" 53202 # To help comparisons with old build, put stdc++ first in JVM_LIBS 53203 JVM_LIBS="-Wl,-Bstatic -lstdc++ -Wl,-Bdynamic $JVM_LIBS" 53204 # Ideally, we should test stdc++ for the BUILD toolchain separately. For now 53205 # just use the same setting as for the TARGET toolchain. 53206 OPENJDK_BUILD_JVM_LDFLAGS="$OPENJDK_BUILD_JVM_LDFLAGS -static-libgcc" 53207 OPENJDK_BUILD_JVM_LIBS="-Wl,-Bstatic -lstdc++ -Wl,-Bdynamic $OPENJDK_BUILD_JVM_LIBS" 53208 LDCXX="$CC" 53209 STATIC_CXX_SETTING="STATIC_CXX=true" 53210 { $as_echo "$as_me:${as_lineno-$LINENO}: result: static" >&5 53211 $as_echo "static" >&6; } 53212 fi 53213 fi 53214 53215 53216 # libCrun is the c++ runtime-library with SunStudio (roughly the equivalent of gcc's libstdc++.so) 53217 if test "x$TOOLCHAIN_TYPE" = xsolstudio && test "x$LIBCXX" = x; then 53218 LIBCXX="${SYSROOT}/usr/lib${OPENJDK_TARGET_CPU_ISADIR}/libCrun.so.1" 53219 fi 53220 53221 # TODO better (platform agnostic) test 53222 if test "x$OPENJDK_TARGET_OS" = xmacosx && test "x$LIBCXX" = x && test "x$TOOLCHAIN_TYPE" = xgcc; then 53223 LIBCXX="-lstdc++" 53224 fi 53225 53226 53227 # Setup Windows runtime dlls 53228 if test "x$OPENJDK_TARGET_OS" = "xwindows"; then 53229 53230 53231 # Check whether --with-msvcr-dll was given. 53232 if test "${with_msvcr_dll+set}" = set; then : 53233 withval=$with_msvcr_dll; 53234 fi 53235 53236 53237 if test "x$with_msvcr_dll" != x; then 53238 # If given explicitely by user, do not probe. If not present, fail directly. 53239 53240 DLL_NAME="$MSVCR_NAME" 53241 POSSIBLE_MSVC_DLL="$with_msvcr_dll" 53242 METHOD="--with-msvcr-dll" 53243 if test -n "$POSSIBLE_MSVC_DLL" -a -e "$POSSIBLE_MSVC_DLL"; then 53244 { $as_echo "$as_me:${as_lineno-$LINENO}: Found $DLL_NAME at $POSSIBLE_MSVC_DLL using $METHOD" >&5 53245 $as_echo "$as_me: Found $DLL_NAME at $POSSIBLE_MSVC_DLL using $METHOD" >&6;} 53246 53247 # Need to check if the found msvcr is correct architecture 53248 { $as_echo "$as_me:${as_lineno-$LINENO}: checking found $DLL_NAME architecture" >&5 53249 $as_echo_n "checking found $DLL_NAME architecture... " >&6; } 53250 MSVC_DLL_FILETYPE=`$FILE -b "$POSSIBLE_MSVC_DLL"` 53251 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 53252 # The MSYS 'file' command returns "PE32 executable for MS Windows (DLL) (GUI) Intel 80386 32-bit" 53253 # on x32 and "PE32+ executable for MS Windows (DLL) (GUI) Mono/.Net assembly" on x64 systems. 53254 if test "x$OPENJDK_TARGET_CPU_BITS" = x32; then 53255 CORRECT_MSVCR_ARCH="PE32 executable" 53256 else 53257 CORRECT_MSVCR_ARCH="PE32+ executable" 53258 fi 53259 else 53260 if test "x$OPENJDK_TARGET_CPU_BITS" = x32; then 53261 CORRECT_MSVCR_ARCH=386 53262 else 53263 CORRECT_MSVCR_ARCH=x86-64 53264 fi 53265 fi 53266 if $ECHO "$MSVC_DLL_FILETYPE" | $GREP "$CORRECT_MSVCR_ARCH" 2>&1 > /dev/null; then 53267 { $as_echo "$as_me:${as_lineno-$LINENO}: result: ok" >&5 53268 $as_echo "ok" >&6; } 53269 MSVC_DLL="$POSSIBLE_MSVC_DLL" 53270 53271 # Only process if variable expands to non-empty 53272 53273 if test "x$MSVC_DLL" != x; then 53274 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 53275 53276 # Input might be given as Windows format, start by converting to 53277 # unix format. 53278 path="$MSVC_DLL" 53279 new_path=`$CYGPATH -u "$path"` 53280 53281 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 53282 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 53283 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 53284 # "foo.exe" is OK but "foo" is an error. 53285 # 53286 # This test is therefore slightly more accurate than "test -f" to check for file precense. 53287 # It is also a way to make sure we got the proper file name for the real test later on. 53288 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 53289 if test "x$test_shortpath" = x; then 53290 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of MSVC_DLL, which resolves as \"$path\", is invalid." >&5 53291 $as_echo "$as_me: The path of MSVC_DLL, which resolves as \"$path\", is invalid." >&6;} 53292 as_fn_error $? "Cannot locate the the path of MSVC_DLL" "$LINENO" 5 53293 fi 53294 53295 # Call helper function which possibly converts this using DOS-style short mode. 53296 # If so, the updated path is stored in $new_path. 53297 53298 input_path="$new_path" 53299 # Check if we need to convert this using DOS-style short mode. If the path 53300 # contains just simple characters, use it. Otherwise (spaces, weird characters), 53301 # take no chances and rewrite it. 53302 # Note: m4 eats our [], so we need to use [ and ] instead. 53303 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 53304 if test "x$has_forbidden_chars" != x; then 53305 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 53306 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 53307 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 53308 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 53309 # Going to short mode and back again did indeed matter. Since short mode is 53310 # case insensitive, let's make it lowercase to improve readability. 53311 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 53312 # Now convert it back to Unix-style (cygpath) 53313 input_path=`$CYGPATH -u "$shortmode_path"` 53314 new_path="$input_path" 53315 fi 53316 fi 53317 53318 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 53319 if test "x$test_cygdrive_prefix" = x; then 53320 # As a simple fix, exclude /usr/bin since it's not a real path. 53321 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 53322 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 53323 # a path prefixed by /cygdrive for fixpath to work. 53324 new_path="$CYGWIN_ROOT_PATH$input_path" 53325 fi 53326 fi 53327 53328 53329 if test "x$path" != "x$new_path"; then 53330 MSVC_DLL="$new_path" 53331 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting MSVC_DLL to \"$new_path\"" >&5 53332 $as_echo "$as_me: Rewriting MSVC_DLL to \"$new_path\"" >&6;} 53333 fi 53334 53335 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 53336 53337 path="$MSVC_DLL" 53338 has_colon=`$ECHO $path | $GREP ^.:` 53339 new_path="$path" 53340 if test "x$has_colon" = x; then 53341 # Not in mixed or Windows style, start by that. 53342 new_path=`cmd //c echo $path` 53343 fi 53344 53345 53346 input_path="$new_path" 53347 # Check if we need to convert this using DOS-style short mode. If the path 53348 # contains just simple characters, use it. Otherwise (spaces, weird characters), 53349 # take no chances and rewrite it. 53350 # Note: m4 eats our [], so we need to use [ and ] instead. 53351 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 53352 if test "x$has_forbidden_chars" != x; then 53353 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 53354 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 53355 fi 53356 53357 53358 windows_path="$new_path" 53359 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 53360 unix_path=`$CYGPATH -u "$windows_path"` 53361 new_path="$unix_path" 53362 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 53363 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 53364 new_path="$unix_path" 53365 fi 53366 53367 if test "x$path" != "x$new_path"; then 53368 MSVC_DLL="$new_path" 53369 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting MSVC_DLL to \"$new_path\"" >&5 53370 $as_echo "$as_me: Rewriting MSVC_DLL to \"$new_path\"" >&6;} 53371 fi 53372 53373 # Save the first 10 bytes of this path to the storage, so fixpath can work. 53374 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 53375 53376 else 53377 # We're on a unix platform. Hooray! :) 53378 path="$MSVC_DLL" 53379 has_space=`$ECHO "$path" | $GREP " "` 53380 if test "x$has_space" != x; then 53381 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of MSVC_DLL, which resolves as \"$path\", is invalid." >&5 53382 $as_echo "$as_me: The path of MSVC_DLL, which resolves as \"$path\", is invalid." >&6;} 53383 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 53384 fi 53385 53386 # Use eval to expand a potential ~ 53387 eval path="$path" 53388 if test ! -f "$path" && test ! -d "$path"; then 53389 as_fn_error $? "The path of MSVC_DLL, which resolves as \"$path\", is not found." "$LINENO" 5 53390 fi 53391 53392 if test -d "$path"; then 53393 MSVC_DLL="`cd "$path"; $THEPWDCMD -L`" 53394 else 53395 dir="`$DIRNAME "$path"`" 53396 base="`$BASENAME "$path"`" 53397 MSVC_DLL="`cd "$dir"; $THEPWDCMD -L`/$base" 53398 fi 53399 fi 53400 fi 53401 53402 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $DLL_NAME" >&5 53403 $as_echo_n "checking for $DLL_NAME... " >&6; } 53404 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MSVC_DLL" >&5 53405 $as_echo "$MSVC_DLL" >&6; } 53406 else 53407 { $as_echo "$as_me:${as_lineno-$LINENO}: result: incorrect, ignoring" >&5 53408 $as_echo "incorrect, ignoring" >&6; } 53409 { $as_echo "$as_me:${as_lineno-$LINENO}: The file type of the located $DLL_NAME is $MSVC_DLL_FILETYPE" >&5 53410 $as_echo "$as_me: The file type of the located $DLL_NAME is $MSVC_DLL_FILETYPE" >&6;} 53411 fi 53412 fi 53413 53414 if test "x$MSVC_DLL" = x; then 53415 as_fn_error $? "Could not find a proper $MSVCR_NAME as specified by --with-msvcr-dll" "$LINENO" 5 53416 fi 53417 MSVCR_DLL="$MSVC_DLL" 53418 elif test "x$DEVKIT_MSVCR_DLL" != x; then 53419 53420 DLL_NAME="$MSVCR_NAME" 53421 POSSIBLE_MSVC_DLL="$DEVKIT_MSVCR_DLL" 53422 METHOD="devkit" 53423 if test -n "$POSSIBLE_MSVC_DLL" -a -e "$POSSIBLE_MSVC_DLL"; then 53424 { $as_echo "$as_me:${as_lineno-$LINENO}: Found $DLL_NAME at $POSSIBLE_MSVC_DLL using $METHOD" >&5 53425 $as_echo "$as_me: Found $DLL_NAME at $POSSIBLE_MSVC_DLL using $METHOD" >&6;} 53426 53427 # Need to check if the found msvcr is correct architecture 53428 { $as_echo "$as_me:${as_lineno-$LINENO}: checking found $DLL_NAME architecture" >&5 53429 $as_echo_n "checking found $DLL_NAME architecture... " >&6; } 53430 MSVC_DLL_FILETYPE=`$FILE -b "$POSSIBLE_MSVC_DLL"` 53431 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 53432 # The MSYS 'file' command returns "PE32 executable for MS Windows (DLL) (GUI) Intel 80386 32-bit" 53433 # on x32 and "PE32+ executable for MS Windows (DLL) (GUI) Mono/.Net assembly" on x64 systems. 53434 if test "x$OPENJDK_TARGET_CPU_BITS" = x32; then 53435 CORRECT_MSVCR_ARCH="PE32 executable" 53436 else 53437 CORRECT_MSVCR_ARCH="PE32+ executable" 53438 fi 53439 else 53440 if test "x$OPENJDK_TARGET_CPU_BITS" = x32; then 53441 CORRECT_MSVCR_ARCH=386 53442 else 53443 CORRECT_MSVCR_ARCH=x86-64 53444 fi 53445 fi 53446 if $ECHO "$MSVC_DLL_FILETYPE" | $GREP "$CORRECT_MSVCR_ARCH" 2>&1 > /dev/null; then 53447 { $as_echo "$as_me:${as_lineno-$LINENO}: result: ok" >&5 53448 $as_echo "ok" >&6; } 53449 MSVC_DLL="$POSSIBLE_MSVC_DLL" 53450 53451 # Only process if variable expands to non-empty 53452 53453 if test "x$MSVC_DLL" != x; then 53454 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 53455 53456 # Input might be given as Windows format, start by converting to 53457 # unix format. 53458 path="$MSVC_DLL" 53459 new_path=`$CYGPATH -u "$path"` 53460 53461 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 53462 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 53463 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 53464 # "foo.exe" is OK but "foo" is an error. 53465 # 53466 # This test is therefore slightly more accurate than "test -f" to check for file precense. 53467 # It is also a way to make sure we got the proper file name for the real test later on. 53468 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 53469 if test "x$test_shortpath" = x; then 53470 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of MSVC_DLL, which resolves as \"$path\", is invalid." >&5 53471 $as_echo "$as_me: The path of MSVC_DLL, which resolves as \"$path\", is invalid." >&6;} 53472 as_fn_error $? "Cannot locate the the path of MSVC_DLL" "$LINENO" 5 53473 fi 53474 53475 # Call helper function which possibly converts this using DOS-style short mode. 53476 # If so, the updated path is stored in $new_path. 53477 53478 input_path="$new_path" 53479 # Check if we need to convert this using DOS-style short mode. If the path 53480 # contains just simple characters, use it. Otherwise (spaces, weird characters), 53481 # take no chances and rewrite it. 53482 # Note: m4 eats our [], so we need to use [ and ] instead. 53483 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 53484 if test "x$has_forbidden_chars" != x; then 53485 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 53486 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 53487 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 53488 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 53489 # Going to short mode and back again did indeed matter. Since short mode is 53490 # case insensitive, let's make it lowercase to improve readability. 53491 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 53492 # Now convert it back to Unix-style (cygpath) 53493 input_path=`$CYGPATH -u "$shortmode_path"` 53494 new_path="$input_path" 53495 fi 53496 fi 53497 53498 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 53499 if test "x$test_cygdrive_prefix" = x; then 53500 # As a simple fix, exclude /usr/bin since it's not a real path. 53501 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 53502 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 53503 # a path prefixed by /cygdrive for fixpath to work. 53504 new_path="$CYGWIN_ROOT_PATH$input_path" 53505 fi 53506 fi 53507 53508 53509 if test "x$path" != "x$new_path"; then 53510 MSVC_DLL="$new_path" 53511 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting MSVC_DLL to \"$new_path\"" >&5 53512 $as_echo "$as_me: Rewriting MSVC_DLL to \"$new_path\"" >&6;} 53513 fi 53514 53515 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 53516 53517 path="$MSVC_DLL" 53518 has_colon=`$ECHO $path | $GREP ^.:` 53519 new_path="$path" 53520 if test "x$has_colon" = x; then 53521 # Not in mixed or Windows style, start by that. 53522 new_path=`cmd //c echo $path` 53523 fi 53524 53525 53526 input_path="$new_path" 53527 # Check if we need to convert this using DOS-style short mode. If the path 53528 # contains just simple characters, use it. Otherwise (spaces, weird characters), 53529 # take no chances and rewrite it. 53530 # Note: m4 eats our [], so we need to use [ and ] instead. 53531 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 53532 if test "x$has_forbidden_chars" != x; then 53533 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 53534 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 53535 fi 53536 53537 53538 windows_path="$new_path" 53539 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 53540 unix_path=`$CYGPATH -u "$windows_path"` 53541 new_path="$unix_path" 53542 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 53543 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 53544 new_path="$unix_path" 53545 fi 53546 53547 if test "x$path" != "x$new_path"; then 53548 MSVC_DLL="$new_path" 53549 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting MSVC_DLL to \"$new_path\"" >&5 53550 $as_echo "$as_me: Rewriting MSVC_DLL to \"$new_path\"" >&6;} 53551 fi 53552 53553 # Save the first 10 bytes of this path to the storage, so fixpath can work. 53554 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 53555 53556 else 53557 # We're on a unix platform. Hooray! :) 53558 path="$MSVC_DLL" 53559 has_space=`$ECHO "$path" | $GREP " "` 53560 if test "x$has_space" != x; then 53561 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of MSVC_DLL, which resolves as \"$path\", is invalid." >&5 53562 $as_echo "$as_me: The path of MSVC_DLL, which resolves as \"$path\", is invalid." >&6;} 53563 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 53564 fi 53565 53566 # Use eval to expand a potential ~ 53567 eval path="$path" 53568 if test ! -f "$path" && test ! -d "$path"; then 53569 as_fn_error $? "The path of MSVC_DLL, which resolves as \"$path\", is not found." "$LINENO" 5 53570 fi 53571 53572 if test -d "$path"; then 53573 MSVC_DLL="`cd "$path"; $THEPWDCMD -L`" 53574 else 53575 dir="`$DIRNAME "$path"`" 53576 base="`$BASENAME "$path"`" 53577 MSVC_DLL="`cd "$dir"; $THEPWDCMD -L`/$base" 53578 fi 53579 fi 53580 fi 53581 53582 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $DLL_NAME" >&5 53583 $as_echo_n "checking for $DLL_NAME... " >&6; } 53584 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MSVC_DLL" >&5 53585 $as_echo "$MSVC_DLL" >&6; } 53586 else 53587 { $as_echo "$as_me:${as_lineno-$LINENO}: result: incorrect, ignoring" >&5 53588 $as_echo "incorrect, ignoring" >&6; } 53589 { $as_echo "$as_me:${as_lineno-$LINENO}: The file type of the located $DLL_NAME is $MSVC_DLL_FILETYPE" >&5 53590 $as_echo "$as_me: The file type of the located $DLL_NAME is $MSVC_DLL_FILETYPE" >&6;} 53591 fi 53592 fi 53593 53594 if test "x$MSVC_DLL" = x; then 53595 as_fn_error $? "Could not find a proper $MSVCR_NAME as specified by devkit" "$LINENO" 5 53596 fi 53597 MSVCR_DLL="$MSVC_DLL" 53598 else 53599 53600 DLL_NAME="${MSVCR_NAME}" 53601 MSVC_DLL= 53602 53603 if test "x$MSVC_DLL" = x; then 53604 # Probe: Using well-known location from Visual Studio 10.0 53605 if test "x$VCINSTALLDIR" != x; then 53606 CYGWIN_VC_INSTALL_DIR="$VCINSTALLDIR" 53607 53608 windows_path="$CYGWIN_VC_INSTALL_DIR" 53609 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 53610 unix_path=`$CYGPATH -u "$windows_path"` 53611 CYGWIN_VC_INSTALL_DIR="$unix_path" 53612 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 53613 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 53614 CYGWIN_VC_INSTALL_DIR="$unix_path" 53615 fi 53616 53617 if test "x$OPENJDK_TARGET_CPU_BITS" = x64; then 53618 POSSIBLE_MSVC_DLL="$CYGWIN_VC_INSTALL_DIR/redist/x64/Microsoft.VC${VS_VERSION_INTERNAL}.CRT/$DLL_NAME" 53619 else 53620 POSSIBLE_MSVC_DLL="$CYGWIN_VC_INSTALL_DIR/redist/x86/Microsoft.VC${VS_VERSION_INTERNAL}.CRT/$DLL_NAME" 53621 fi 53622 $ECHO "POSSIBLE_MSVC_DLL $POSSIBLEMSVC_DLL" 53623 53624 DLL_NAME="$DLL_NAME" 53625 POSSIBLE_MSVC_DLL="$POSSIBLE_MSVC_DLL" 53626 METHOD="well-known location in VCINSTALLDIR" 53627 if test -n "$POSSIBLE_MSVC_DLL" -a -e "$POSSIBLE_MSVC_DLL"; then 53628 { $as_echo "$as_me:${as_lineno-$LINENO}: Found $DLL_NAME at $POSSIBLE_MSVC_DLL using $METHOD" >&5 53629 $as_echo "$as_me: Found $DLL_NAME at $POSSIBLE_MSVC_DLL using $METHOD" >&6;} 53630 53631 # Need to check if the found msvcr is correct architecture 53632 { $as_echo "$as_me:${as_lineno-$LINENO}: checking found $DLL_NAME architecture" >&5 53633 $as_echo_n "checking found $DLL_NAME architecture... " >&6; } 53634 MSVC_DLL_FILETYPE=`$FILE -b "$POSSIBLE_MSVC_DLL"` 53635 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 53636 # The MSYS 'file' command returns "PE32 executable for MS Windows (DLL) (GUI) Intel 80386 32-bit" 53637 # on x32 and "PE32+ executable for MS Windows (DLL) (GUI) Mono/.Net assembly" on x64 systems. 53638 if test "x$OPENJDK_TARGET_CPU_BITS" = x32; then 53639 CORRECT_MSVCR_ARCH="PE32 executable" 53640 else 53641 CORRECT_MSVCR_ARCH="PE32+ executable" 53642 fi 53643 else 53644 if test "x$OPENJDK_TARGET_CPU_BITS" = x32; then 53645 CORRECT_MSVCR_ARCH=386 53646 else 53647 CORRECT_MSVCR_ARCH=x86-64 53648 fi 53649 fi 53650 if $ECHO "$MSVC_DLL_FILETYPE" | $GREP "$CORRECT_MSVCR_ARCH" 2>&1 > /dev/null; then 53651 { $as_echo "$as_me:${as_lineno-$LINENO}: result: ok" >&5 53652 $as_echo "ok" >&6; } 53653 MSVC_DLL="$POSSIBLE_MSVC_DLL" 53654 53655 # Only process if variable expands to non-empty 53656 53657 if test "x$MSVC_DLL" != x; then 53658 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 53659 53660 # Input might be given as Windows format, start by converting to 53661 # unix format. 53662 path="$MSVC_DLL" 53663 new_path=`$CYGPATH -u "$path"` 53664 53665 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 53666 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 53667 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 53668 # "foo.exe" is OK but "foo" is an error. 53669 # 53670 # This test is therefore slightly more accurate than "test -f" to check for file precense. 53671 # It is also a way to make sure we got the proper file name for the real test later on. 53672 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 53673 if test "x$test_shortpath" = x; then 53674 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of MSVC_DLL, which resolves as \"$path\", is invalid." >&5 53675 $as_echo "$as_me: The path of MSVC_DLL, which resolves as \"$path\", is invalid." >&6;} 53676 as_fn_error $? "Cannot locate the the path of MSVC_DLL" "$LINENO" 5 53677 fi 53678 53679 # Call helper function which possibly converts this using DOS-style short mode. 53680 # If so, the updated path is stored in $new_path. 53681 53682 input_path="$new_path" 53683 # Check if we need to convert this using DOS-style short mode. If the path 53684 # contains just simple characters, use it. Otherwise (spaces, weird characters), 53685 # take no chances and rewrite it. 53686 # Note: m4 eats our [], so we need to use [ and ] instead. 53687 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 53688 if test "x$has_forbidden_chars" != x; then 53689 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 53690 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 53691 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 53692 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 53693 # Going to short mode and back again did indeed matter. Since short mode is 53694 # case insensitive, let's make it lowercase to improve readability. 53695 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 53696 # Now convert it back to Unix-style (cygpath) 53697 input_path=`$CYGPATH -u "$shortmode_path"` 53698 new_path="$input_path" 53699 fi 53700 fi 53701 53702 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 53703 if test "x$test_cygdrive_prefix" = x; then 53704 # As a simple fix, exclude /usr/bin since it's not a real path. 53705 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 53706 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 53707 # a path prefixed by /cygdrive for fixpath to work. 53708 new_path="$CYGWIN_ROOT_PATH$input_path" 53709 fi 53710 fi 53711 53712 53713 if test "x$path" != "x$new_path"; then 53714 MSVC_DLL="$new_path" 53715 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting MSVC_DLL to \"$new_path\"" >&5 53716 $as_echo "$as_me: Rewriting MSVC_DLL to \"$new_path\"" >&6;} 53717 fi 53718 53719 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 53720 53721 path="$MSVC_DLL" 53722 has_colon=`$ECHO $path | $GREP ^.:` 53723 new_path="$path" 53724 if test "x$has_colon" = x; then 53725 # Not in mixed or Windows style, start by that. 53726 new_path=`cmd //c echo $path` 53727 fi 53728 53729 53730 input_path="$new_path" 53731 # Check if we need to convert this using DOS-style short mode. If the path 53732 # contains just simple characters, use it. Otherwise (spaces, weird characters), 53733 # take no chances and rewrite it. 53734 # Note: m4 eats our [], so we need to use [ and ] instead. 53735 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 53736 if test "x$has_forbidden_chars" != x; then 53737 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 53738 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 53739 fi 53740 53741 53742 windows_path="$new_path" 53743 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 53744 unix_path=`$CYGPATH -u "$windows_path"` 53745 new_path="$unix_path" 53746 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 53747 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 53748 new_path="$unix_path" 53749 fi 53750 53751 if test "x$path" != "x$new_path"; then 53752 MSVC_DLL="$new_path" 53753 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting MSVC_DLL to \"$new_path\"" >&5 53754 $as_echo "$as_me: Rewriting MSVC_DLL to \"$new_path\"" >&6;} 53755 fi 53756 53757 # Save the first 10 bytes of this path to the storage, so fixpath can work. 53758 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 53759 53760 else 53761 # We're on a unix platform. Hooray! :) 53762 path="$MSVC_DLL" 53763 has_space=`$ECHO "$path" | $GREP " "` 53764 if test "x$has_space" != x; then 53765 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of MSVC_DLL, which resolves as \"$path\", is invalid." >&5 53766 $as_echo "$as_me: The path of MSVC_DLL, which resolves as \"$path\", is invalid." >&6;} 53767 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 53768 fi 53769 53770 # Use eval to expand a potential ~ 53771 eval path="$path" 53772 if test ! -f "$path" && test ! -d "$path"; then 53773 as_fn_error $? "The path of MSVC_DLL, which resolves as \"$path\", is not found." "$LINENO" 5 53774 fi 53775 53776 if test -d "$path"; then 53777 MSVC_DLL="`cd "$path"; $THEPWDCMD -L`" 53778 else 53779 dir="`$DIRNAME "$path"`" 53780 base="`$BASENAME "$path"`" 53781 MSVC_DLL="`cd "$dir"; $THEPWDCMD -L`/$base" 53782 fi 53783 fi 53784 fi 53785 53786 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $DLL_NAME" >&5 53787 $as_echo_n "checking for $DLL_NAME... " >&6; } 53788 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MSVC_DLL" >&5 53789 $as_echo "$MSVC_DLL" >&6; } 53790 else 53791 { $as_echo "$as_me:${as_lineno-$LINENO}: result: incorrect, ignoring" >&5 53792 $as_echo "incorrect, ignoring" >&6; } 53793 { $as_echo "$as_me:${as_lineno-$LINENO}: The file type of the located $DLL_NAME is $MSVC_DLL_FILETYPE" >&5 53794 $as_echo "$as_me: The file type of the located $DLL_NAME is $MSVC_DLL_FILETYPE" >&6;} 53795 fi 53796 fi 53797 53798 fi 53799 fi 53800 53801 if test "x$MSVC_DLL" = x; then 53802 # Probe: Check in the Boot JDK directory. 53803 POSSIBLE_MSVC_DLL="$BOOT_JDK/bin/$DLL_NAME" 53804 53805 DLL_NAME="$DLL_NAME" 53806 POSSIBLE_MSVC_DLL="$POSSIBLE_MSVC_DLL" 53807 METHOD="well-known location in Boot JDK" 53808 if test -n "$POSSIBLE_MSVC_DLL" -a -e "$POSSIBLE_MSVC_DLL"; then 53809 { $as_echo "$as_me:${as_lineno-$LINENO}: Found $DLL_NAME at $POSSIBLE_MSVC_DLL using $METHOD" >&5 53810 $as_echo "$as_me: Found $DLL_NAME at $POSSIBLE_MSVC_DLL using $METHOD" >&6;} 53811 53812 # Need to check if the found msvcr is correct architecture 53813 { $as_echo "$as_me:${as_lineno-$LINENO}: checking found $DLL_NAME architecture" >&5 53814 $as_echo_n "checking found $DLL_NAME architecture... " >&6; } 53815 MSVC_DLL_FILETYPE=`$FILE -b "$POSSIBLE_MSVC_DLL"` 53816 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 53817 # The MSYS 'file' command returns "PE32 executable for MS Windows (DLL) (GUI) Intel 80386 32-bit" 53818 # on x32 and "PE32+ executable for MS Windows (DLL) (GUI) Mono/.Net assembly" on x64 systems. 53819 if test "x$OPENJDK_TARGET_CPU_BITS" = x32; then 53820 CORRECT_MSVCR_ARCH="PE32 executable" 53821 else 53822 CORRECT_MSVCR_ARCH="PE32+ executable" 53823 fi 53824 else 53825 if test "x$OPENJDK_TARGET_CPU_BITS" = x32; then 53826 CORRECT_MSVCR_ARCH=386 53827 else 53828 CORRECT_MSVCR_ARCH=x86-64 53829 fi 53830 fi 53831 if $ECHO "$MSVC_DLL_FILETYPE" | $GREP "$CORRECT_MSVCR_ARCH" 2>&1 > /dev/null; then 53832 { $as_echo "$as_me:${as_lineno-$LINENO}: result: ok" >&5 53833 $as_echo "ok" >&6; } 53834 MSVC_DLL="$POSSIBLE_MSVC_DLL" 53835 53836 # Only process if variable expands to non-empty 53837 53838 if test "x$MSVC_DLL" != x; then 53839 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 53840 53841 # Input might be given as Windows format, start by converting to 53842 # unix format. 53843 path="$MSVC_DLL" 53844 new_path=`$CYGPATH -u "$path"` 53845 53846 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 53847 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 53848 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 53849 # "foo.exe" is OK but "foo" is an error. 53850 # 53851 # This test is therefore slightly more accurate than "test -f" to check for file precense. 53852 # It is also a way to make sure we got the proper file name for the real test later on. 53853 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 53854 if test "x$test_shortpath" = x; then 53855 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of MSVC_DLL, which resolves as \"$path\", is invalid." >&5 53856 $as_echo "$as_me: The path of MSVC_DLL, which resolves as \"$path\", is invalid." >&6;} 53857 as_fn_error $? "Cannot locate the the path of MSVC_DLL" "$LINENO" 5 53858 fi 53859 53860 # Call helper function which possibly converts this using DOS-style short mode. 53861 # If so, the updated path is stored in $new_path. 53862 53863 input_path="$new_path" 53864 # Check if we need to convert this using DOS-style short mode. If the path 53865 # contains just simple characters, use it. Otherwise (spaces, weird characters), 53866 # take no chances and rewrite it. 53867 # Note: m4 eats our [], so we need to use [ and ] instead. 53868 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 53869 if test "x$has_forbidden_chars" != x; then 53870 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 53871 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 53872 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 53873 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 53874 # Going to short mode and back again did indeed matter. Since short mode is 53875 # case insensitive, let's make it lowercase to improve readability. 53876 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 53877 # Now convert it back to Unix-style (cygpath) 53878 input_path=`$CYGPATH -u "$shortmode_path"` 53879 new_path="$input_path" 53880 fi 53881 fi 53882 53883 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 53884 if test "x$test_cygdrive_prefix" = x; then 53885 # As a simple fix, exclude /usr/bin since it's not a real path. 53886 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 53887 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 53888 # a path prefixed by /cygdrive for fixpath to work. 53889 new_path="$CYGWIN_ROOT_PATH$input_path" 53890 fi 53891 fi 53892 53893 53894 if test "x$path" != "x$new_path"; then 53895 MSVC_DLL="$new_path" 53896 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting MSVC_DLL to \"$new_path\"" >&5 53897 $as_echo "$as_me: Rewriting MSVC_DLL to \"$new_path\"" >&6;} 53898 fi 53899 53900 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 53901 53902 path="$MSVC_DLL" 53903 has_colon=`$ECHO $path | $GREP ^.:` 53904 new_path="$path" 53905 if test "x$has_colon" = x; then 53906 # Not in mixed or Windows style, start by that. 53907 new_path=`cmd //c echo $path` 53908 fi 53909 53910 53911 input_path="$new_path" 53912 # Check if we need to convert this using DOS-style short mode. If the path 53913 # contains just simple characters, use it. Otherwise (spaces, weird characters), 53914 # take no chances and rewrite it. 53915 # Note: m4 eats our [], so we need to use [ and ] instead. 53916 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 53917 if test "x$has_forbidden_chars" != x; then 53918 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 53919 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 53920 fi 53921 53922 53923 windows_path="$new_path" 53924 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 53925 unix_path=`$CYGPATH -u "$windows_path"` 53926 new_path="$unix_path" 53927 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 53928 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 53929 new_path="$unix_path" 53930 fi 53931 53932 if test "x$path" != "x$new_path"; then 53933 MSVC_DLL="$new_path" 53934 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting MSVC_DLL to \"$new_path\"" >&5 53935 $as_echo "$as_me: Rewriting MSVC_DLL to \"$new_path\"" >&6;} 53936 fi 53937 53938 # Save the first 10 bytes of this path to the storage, so fixpath can work. 53939 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 53940 53941 else 53942 # We're on a unix platform. Hooray! :) 53943 path="$MSVC_DLL" 53944 has_space=`$ECHO "$path" | $GREP " "` 53945 if test "x$has_space" != x; then 53946 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of MSVC_DLL, which resolves as \"$path\", is invalid." >&5 53947 $as_echo "$as_me: The path of MSVC_DLL, which resolves as \"$path\", is invalid." >&6;} 53948 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 53949 fi 53950 53951 # Use eval to expand a potential ~ 53952 eval path="$path" 53953 if test ! -f "$path" && test ! -d "$path"; then 53954 as_fn_error $? "The path of MSVC_DLL, which resolves as \"$path\", is not found." "$LINENO" 5 53955 fi 53956 53957 if test -d "$path"; then 53958 MSVC_DLL="`cd "$path"; $THEPWDCMD -L`" 53959 else 53960 dir="`$DIRNAME "$path"`" 53961 base="`$BASENAME "$path"`" 53962 MSVC_DLL="`cd "$dir"; $THEPWDCMD -L`/$base" 53963 fi 53964 fi 53965 fi 53966 53967 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $DLL_NAME" >&5 53968 $as_echo_n "checking for $DLL_NAME... " >&6; } 53969 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MSVC_DLL" >&5 53970 $as_echo "$MSVC_DLL" >&6; } 53971 else 53972 { $as_echo "$as_me:${as_lineno-$LINENO}: result: incorrect, ignoring" >&5 53973 $as_echo "incorrect, ignoring" >&6; } 53974 { $as_echo "$as_me:${as_lineno-$LINENO}: The file type of the located $DLL_NAME is $MSVC_DLL_FILETYPE" >&5 53975 $as_echo "$as_me: The file type of the located $DLL_NAME is $MSVC_DLL_FILETYPE" >&6;} 53976 fi 53977 fi 53978 53979 fi 53980 53981 if test "x$MSVC_DLL" = x; then 53982 # Probe: Look in the Windows system32 directory 53983 CYGWIN_SYSTEMROOT="$SYSTEMROOT" 53984 53985 windows_path="$CYGWIN_SYSTEMROOT" 53986 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 53987 unix_path=`$CYGPATH -u "$windows_path"` 53988 CYGWIN_SYSTEMROOT="$unix_path" 53989 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 53990 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 53991 CYGWIN_SYSTEMROOT="$unix_path" 53992 fi 53993 53994 POSSIBLE_MSVC_DLL="$CYGWIN_SYSTEMROOT/system32/$DLL_NAME" 53995 53996 DLL_NAME="$DLL_NAME" 53997 POSSIBLE_MSVC_DLL="$POSSIBLE_MSVC_DLL" 53998 METHOD="well-known location in SYSTEMROOT" 53999 if test -n "$POSSIBLE_MSVC_DLL" -a -e "$POSSIBLE_MSVC_DLL"; then 54000 { $as_echo "$as_me:${as_lineno-$LINENO}: Found $DLL_NAME at $POSSIBLE_MSVC_DLL using $METHOD" >&5 54001 $as_echo "$as_me: Found $DLL_NAME at $POSSIBLE_MSVC_DLL using $METHOD" >&6;} 54002 54003 # Need to check if the found msvcr is correct architecture 54004 { $as_echo "$as_me:${as_lineno-$LINENO}: checking found $DLL_NAME architecture" >&5 54005 $as_echo_n "checking found $DLL_NAME architecture... " >&6; } 54006 MSVC_DLL_FILETYPE=`$FILE -b "$POSSIBLE_MSVC_DLL"` 54007 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 54008 # The MSYS 'file' command returns "PE32 executable for MS Windows (DLL) (GUI) Intel 80386 32-bit" 54009 # on x32 and "PE32+ executable for MS Windows (DLL) (GUI) Mono/.Net assembly" on x64 systems. 54010 if test "x$OPENJDK_TARGET_CPU_BITS" = x32; then 54011 CORRECT_MSVCR_ARCH="PE32 executable" 54012 else 54013 CORRECT_MSVCR_ARCH="PE32+ executable" 54014 fi 54015 else 54016 if test "x$OPENJDK_TARGET_CPU_BITS" = x32; then 54017 CORRECT_MSVCR_ARCH=386 54018 else 54019 CORRECT_MSVCR_ARCH=x86-64 54020 fi 54021 fi 54022 if $ECHO "$MSVC_DLL_FILETYPE" | $GREP "$CORRECT_MSVCR_ARCH" 2>&1 > /dev/null; then 54023 { $as_echo "$as_me:${as_lineno-$LINENO}: result: ok" >&5 54024 $as_echo "ok" >&6; } 54025 MSVC_DLL="$POSSIBLE_MSVC_DLL" 54026 54027 # Only process if variable expands to non-empty 54028 54029 if test "x$MSVC_DLL" != x; then 54030 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 54031 54032 # Input might be given as Windows format, start by converting to 54033 # unix format. 54034 path="$MSVC_DLL" 54035 new_path=`$CYGPATH -u "$path"` 54036 54037 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 54038 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 54039 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 54040 # "foo.exe" is OK but "foo" is an error. 54041 # 54042 # This test is therefore slightly more accurate than "test -f" to check for file precense. 54043 # It is also a way to make sure we got the proper file name for the real test later on. 54044 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 54045 if test "x$test_shortpath" = x; then 54046 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of MSVC_DLL, which resolves as \"$path\", is invalid." >&5 54047 $as_echo "$as_me: The path of MSVC_DLL, which resolves as \"$path\", is invalid." >&6;} 54048 as_fn_error $? "Cannot locate the the path of MSVC_DLL" "$LINENO" 5 54049 fi 54050 54051 # Call helper function which possibly converts this using DOS-style short mode. 54052 # If so, the updated path is stored in $new_path. 54053 54054 input_path="$new_path" 54055 # Check if we need to convert this using DOS-style short mode. If the path 54056 # contains just simple characters, use it. Otherwise (spaces, weird characters), 54057 # take no chances and rewrite it. 54058 # Note: m4 eats our [], so we need to use [ and ] instead. 54059 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 54060 if test "x$has_forbidden_chars" != x; then 54061 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 54062 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 54063 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 54064 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 54065 # Going to short mode and back again did indeed matter. Since short mode is 54066 # case insensitive, let's make it lowercase to improve readability. 54067 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 54068 # Now convert it back to Unix-style (cygpath) 54069 input_path=`$CYGPATH -u "$shortmode_path"` 54070 new_path="$input_path" 54071 fi 54072 fi 54073 54074 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 54075 if test "x$test_cygdrive_prefix" = x; then 54076 # As a simple fix, exclude /usr/bin since it's not a real path. 54077 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 54078 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 54079 # a path prefixed by /cygdrive for fixpath to work. 54080 new_path="$CYGWIN_ROOT_PATH$input_path" 54081 fi 54082 fi 54083 54084 54085 if test "x$path" != "x$new_path"; then 54086 MSVC_DLL="$new_path" 54087 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting MSVC_DLL to \"$new_path\"" >&5 54088 $as_echo "$as_me: Rewriting MSVC_DLL to \"$new_path\"" >&6;} 54089 fi 54090 54091 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 54092 54093 path="$MSVC_DLL" 54094 has_colon=`$ECHO $path | $GREP ^.:` 54095 new_path="$path" 54096 if test "x$has_colon" = x; then 54097 # Not in mixed or Windows style, start by that. 54098 new_path=`cmd //c echo $path` 54099 fi 54100 54101 54102 input_path="$new_path" 54103 # Check if we need to convert this using DOS-style short mode. If the path 54104 # contains just simple characters, use it. Otherwise (spaces, weird characters), 54105 # take no chances and rewrite it. 54106 # Note: m4 eats our [], so we need to use [ and ] instead. 54107 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 54108 if test "x$has_forbidden_chars" != x; then 54109 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 54110 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 54111 fi 54112 54113 54114 windows_path="$new_path" 54115 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 54116 unix_path=`$CYGPATH -u "$windows_path"` 54117 new_path="$unix_path" 54118 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 54119 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 54120 new_path="$unix_path" 54121 fi 54122 54123 if test "x$path" != "x$new_path"; then 54124 MSVC_DLL="$new_path" 54125 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting MSVC_DLL to \"$new_path\"" >&5 54126 $as_echo "$as_me: Rewriting MSVC_DLL to \"$new_path\"" >&6;} 54127 fi 54128 54129 # Save the first 10 bytes of this path to the storage, so fixpath can work. 54130 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 54131 54132 else 54133 # We're on a unix platform. Hooray! :) 54134 path="$MSVC_DLL" 54135 has_space=`$ECHO "$path" | $GREP " "` 54136 if test "x$has_space" != x; then 54137 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of MSVC_DLL, which resolves as \"$path\", is invalid." >&5 54138 $as_echo "$as_me: The path of MSVC_DLL, which resolves as \"$path\", is invalid." >&6;} 54139 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 54140 fi 54141 54142 # Use eval to expand a potential ~ 54143 eval path="$path" 54144 if test ! -f "$path" && test ! -d "$path"; then 54145 as_fn_error $? "The path of MSVC_DLL, which resolves as \"$path\", is not found." "$LINENO" 5 54146 fi 54147 54148 if test -d "$path"; then 54149 MSVC_DLL="`cd "$path"; $THEPWDCMD -L`" 54150 else 54151 dir="`$DIRNAME "$path"`" 54152 base="`$BASENAME "$path"`" 54153 MSVC_DLL="`cd "$dir"; $THEPWDCMD -L`/$base" 54154 fi 54155 fi 54156 fi 54157 54158 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $DLL_NAME" >&5 54159 $as_echo_n "checking for $DLL_NAME... " >&6; } 54160 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MSVC_DLL" >&5 54161 $as_echo "$MSVC_DLL" >&6; } 54162 else 54163 { $as_echo "$as_me:${as_lineno-$LINENO}: result: incorrect, ignoring" >&5 54164 $as_echo "incorrect, ignoring" >&6; } 54165 { $as_echo "$as_me:${as_lineno-$LINENO}: The file type of the located $DLL_NAME is $MSVC_DLL_FILETYPE" >&5 54166 $as_echo "$as_me: The file type of the located $DLL_NAME is $MSVC_DLL_FILETYPE" >&6;} 54167 fi 54168 fi 54169 54170 fi 54171 54172 if test "x$MSVC_DLL" = x; then 54173 # Probe: If Visual Studio Express is installed, there is usually one with the debugger 54174 if test "x$VS100COMNTOOLS" != x; then 54175 CYGWIN_VS_TOOLS_DIR="$VS100COMNTOOLS/.." 54176 54177 windows_path="$CYGWIN_VS_TOOLS_DIR" 54178 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 54179 unix_path=`$CYGPATH -u "$windows_path"` 54180 CYGWIN_VS_TOOLS_DIR="$unix_path" 54181 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 54182 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 54183 CYGWIN_VS_TOOLS_DIR="$unix_path" 54184 fi 54185 54186 if test "x$OPENJDK_TARGET_CPU_BITS" = x64; then 54187 POSSIBLE_MSVC_DLL=`$FIND "$CYGWIN_VS_TOOLS_DIR" -name $DLL_NAME \ 54188 | $GREP -i /x64/ | $HEAD --lines 1` 54189 else 54190 POSSIBLE_MSVC_DLL=`$FIND "$CYGWIN_VS_TOOLS_DIR" -name $DLL_NAME \ 54191 | $GREP -i /x86/ | $HEAD --lines 1` 54192 fi 54193 54194 DLL_NAME="$DLL_NAME" 54195 POSSIBLE_MSVC_DLL="$POSSIBLE_MSVC_DLL" 54196 METHOD="search of VS100COMNTOOLS" 54197 if test -n "$POSSIBLE_MSVC_DLL" -a -e "$POSSIBLE_MSVC_DLL"; then 54198 { $as_echo "$as_me:${as_lineno-$LINENO}: Found $DLL_NAME at $POSSIBLE_MSVC_DLL using $METHOD" >&5 54199 $as_echo "$as_me: Found $DLL_NAME at $POSSIBLE_MSVC_DLL using $METHOD" >&6;} 54200 54201 # Need to check if the found msvcr is correct architecture 54202 { $as_echo "$as_me:${as_lineno-$LINENO}: checking found $DLL_NAME architecture" >&5 54203 $as_echo_n "checking found $DLL_NAME architecture... " >&6; } 54204 MSVC_DLL_FILETYPE=`$FILE -b "$POSSIBLE_MSVC_DLL"` 54205 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 54206 # The MSYS 'file' command returns "PE32 executable for MS Windows (DLL) (GUI) Intel 80386 32-bit" 54207 # on x32 and "PE32+ executable for MS Windows (DLL) (GUI) Mono/.Net assembly" on x64 systems. 54208 if test "x$OPENJDK_TARGET_CPU_BITS" = x32; then 54209 CORRECT_MSVCR_ARCH="PE32 executable" 54210 else 54211 CORRECT_MSVCR_ARCH="PE32+ executable" 54212 fi 54213 else 54214 if test "x$OPENJDK_TARGET_CPU_BITS" = x32; then 54215 CORRECT_MSVCR_ARCH=386 54216 else 54217 CORRECT_MSVCR_ARCH=x86-64 54218 fi 54219 fi 54220 if $ECHO "$MSVC_DLL_FILETYPE" | $GREP "$CORRECT_MSVCR_ARCH" 2>&1 > /dev/null; then 54221 { $as_echo "$as_me:${as_lineno-$LINENO}: result: ok" >&5 54222 $as_echo "ok" >&6; } 54223 MSVC_DLL="$POSSIBLE_MSVC_DLL" 54224 54225 # Only process if variable expands to non-empty 54226 54227 if test "x$MSVC_DLL" != x; then 54228 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 54229 54230 # Input might be given as Windows format, start by converting to 54231 # unix format. 54232 path="$MSVC_DLL" 54233 new_path=`$CYGPATH -u "$path"` 54234 54235 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 54236 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 54237 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 54238 # "foo.exe" is OK but "foo" is an error. 54239 # 54240 # This test is therefore slightly more accurate than "test -f" to check for file precense. 54241 # It is also a way to make sure we got the proper file name for the real test later on. 54242 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 54243 if test "x$test_shortpath" = x; then 54244 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of MSVC_DLL, which resolves as \"$path\", is invalid." >&5 54245 $as_echo "$as_me: The path of MSVC_DLL, which resolves as \"$path\", is invalid." >&6;} 54246 as_fn_error $? "Cannot locate the the path of MSVC_DLL" "$LINENO" 5 54247 fi 54248 54249 # Call helper function which possibly converts this using DOS-style short mode. 54250 # If so, the updated path is stored in $new_path. 54251 54252 input_path="$new_path" 54253 # Check if we need to convert this using DOS-style short mode. If the path 54254 # contains just simple characters, use it. Otherwise (spaces, weird characters), 54255 # take no chances and rewrite it. 54256 # Note: m4 eats our [], so we need to use [ and ] instead. 54257 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 54258 if test "x$has_forbidden_chars" != x; then 54259 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 54260 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 54261 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 54262 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 54263 # Going to short mode and back again did indeed matter. Since short mode is 54264 # case insensitive, let's make it lowercase to improve readability. 54265 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 54266 # Now convert it back to Unix-style (cygpath) 54267 input_path=`$CYGPATH -u "$shortmode_path"` 54268 new_path="$input_path" 54269 fi 54270 fi 54271 54272 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 54273 if test "x$test_cygdrive_prefix" = x; then 54274 # As a simple fix, exclude /usr/bin since it's not a real path. 54275 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 54276 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 54277 # a path prefixed by /cygdrive for fixpath to work. 54278 new_path="$CYGWIN_ROOT_PATH$input_path" 54279 fi 54280 fi 54281 54282 54283 if test "x$path" != "x$new_path"; then 54284 MSVC_DLL="$new_path" 54285 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting MSVC_DLL to \"$new_path\"" >&5 54286 $as_echo "$as_me: Rewriting MSVC_DLL to \"$new_path\"" >&6;} 54287 fi 54288 54289 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 54290 54291 path="$MSVC_DLL" 54292 has_colon=`$ECHO $path | $GREP ^.:` 54293 new_path="$path" 54294 if test "x$has_colon" = x; then 54295 # Not in mixed or Windows style, start by that. 54296 new_path=`cmd //c echo $path` 54297 fi 54298 54299 54300 input_path="$new_path" 54301 # Check if we need to convert this using DOS-style short mode. If the path 54302 # contains just simple characters, use it. Otherwise (spaces, weird characters), 54303 # take no chances and rewrite it. 54304 # Note: m4 eats our [], so we need to use [ and ] instead. 54305 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 54306 if test "x$has_forbidden_chars" != x; then 54307 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 54308 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 54309 fi 54310 54311 54312 windows_path="$new_path" 54313 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 54314 unix_path=`$CYGPATH -u "$windows_path"` 54315 new_path="$unix_path" 54316 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 54317 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 54318 new_path="$unix_path" 54319 fi 54320 54321 if test "x$path" != "x$new_path"; then 54322 MSVC_DLL="$new_path" 54323 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting MSVC_DLL to \"$new_path\"" >&5 54324 $as_echo "$as_me: Rewriting MSVC_DLL to \"$new_path\"" >&6;} 54325 fi 54326 54327 # Save the first 10 bytes of this path to the storage, so fixpath can work. 54328 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 54329 54330 else 54331 # We're on a unix platform. Hooray! :) 54332 path="$MSVC_DLL" 54333 has_space=`$ECHO "$path" | $GREP " "` 54334 if test "x$has_space" != x; then 54335 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of MSVC_DLL, which resolves as \"$path\", is invalid." >&5 54336 $as_echo "$as_me: The path of MSVC_DLL, which resolves as \"$path\", is invalid." >&6;} 54337 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 54338 fi 54339 54340 # Use eval to expand a potential ~ 54341 eval path="$path" 54342 if test ! -f "$path" && test ! -d "$path"; then 54343 as_fn_error $? "The path of MSVC_DLL, which resolves as \"$path\", is not found." "$LINENO" 5 54344 fi 54345 54346 if test -d "$path"; then 54347 MSVC_DLL="`cd "$path"; $THEPWDCMD -L`" 54348 else 54349 dir="`$DIRNAME "$path"`" 54350 base="`$BASENAME "$path"`" 54351 MSVC_DLL="`cd "$dir"; $THEPWDCMD -L`/$base" 54352 fi 54353 fi 54354 fi 54355 54356 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $DLL_NAME" >&5 54357 $as_echo_n "checking for $DLL_NAME... " >&6; } 54358 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MSVC_DLL" >&5 54359 $as_echo "$MSVC_DLL" >&6; } 54360 else 54361 { $as_echo "$as_me:${as_lineno-$LINENO}: result: incorrect, ignoring" >&5 54362 $as_echo "incorrect, ignoring" >&6; } 54363 { $as_echo "$as_me:${as_lineno-$LINENO}: The file type of the located $DLL_NAME is $MSVC_DLL_FILETYPE" >&5 54364 $as_echo "$as_me: The file type of the located $DLL_NAME is $MSVC_DLL_FILETYPE" >&6;} 54365 fi 54366 fi 54367 54368 fi 54369 fi 54370 54371 if test "x$MSVC_DLL" = x; then 54372 # Probe: Search wildly in the VCINSTALLDIR. We've probably lost by now. 54373 # (This was the original behaviour; kept since it might turn something up) 54374 if test "x$CYGWIN_VC_INSTALL_DIR" != x; then 54375 if test "x$OPENJDK_TARGET_CPU_BITS" = x64; then 54376 POSSIBLE_MSVC_DLL=`$FIND "$CYGWIN_VC_INSTALL_DIR" -name $DLL_NAME \ 54377 | $GREP x64 | $HEAD --lines 1` 54378 else 54379 POSSIBLE_MSVC_DLL=`$FIND "$CYGWIN_VC_INSTALL_DIR" -name $DLL_NAME \ 54380 | $GREP x86 | $GREP -v ia64 | $GREP -v x64 | $HEAD --lines 1` 54381 if test "x$POSSIBLE_MSVC_DLL" = x; then 54382 # We're grasping at straws now... 54383 POSSIBLE_MSVC_DLL=`$FIND "$CYGWIN_VC_INSTALL_DIR" -name $DLL_NAME \ 54384 | $HEAD --lines 1` 54385 fi 54386 fi 54387 54388 54389 DLL_NAME="$DLL_NAME" 54390 POSSIBLE_MSVC_DLL="$POSSIBLE_MSVC_DLL" 54391 METHOD="search of VCINSTALLDIR" 54392 if test -n "$POSSIBLE_MSVC_DLL" -a -e "$POSSIBLE_MSVC_DLL"; then 54393 { $as_echo "$as_me:${as_lineno-$LINENO}: Found $DLL_NAME at $POSSIBLE_MSVC_DLL using $METHOD" >&5 54394 $as_echo "$as_me: Found $DLL_NAME at $POSSIBLE_MSVC_DLL using $METHOD" >&6;} 54395 54396 # Need to check if the found msvcr is correct architecture 54397 { $as_echo "$as_me:${as_lineno-$LINENO}: checking found $DLL_NAME architecture" >&5 54398 $as_echo_n "checking found $DLL_NAME architecture... " >&6; } 54399 MSVC_DLL_FILETYPE=`$FILE -b "$POSSIBLE_MSVC_DLL"` 54400 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 54401 # The MSYS 'file' command returns "PE32 executable for MS Windows (DLL) (GUI) Intel 80386 32-bit" 54402 # on x32 and "PE32+ executable for MS Windows (DLL) (GUI) Mono/.Net assembly" on x64 systems. 54403 if test "x$OPENJDK_TARGET_CPU_BITS" = x32; then 54404 CORRECT_MSVCR_ARCH="PE32 executable" 54405 else 54406 CORRECT_MSVCR_ARCH="PE32+ executable" 54407 fi 54408 else 54409 if test "x$OPENJDK_TARGET_CPU_BITS" = x32; then 54410 CORRECT_MSVCR_ARCH=386 54411 else 54412 CORRECT_MSVCR_ARCH=x86-64 54413 fi 54414 fi 54415 if $ECHO "$MSVC_DLL_FILETYPE" | $GREP "$CORRECT_MSVCR_ARCH" 2>&1 > /dev/null; then 54416 { $as_echo "$as_me:${as_lineno-$LINENO}: result: ok" >&5 54417 $as_echo "ok" >&6; } 54418 MSVC_DLL="$POSSIBLE_MSVC_DLL" 54419 54420 # Only process if variable expands to non-empty 54421 54422 if test "x$MSVC_DLL" != x; then 54423 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 54424 54425 # Input might be given as Windows format, start by converting to 54426 # unix format. 54427 path="$MSVC_DLL" 54428 new_path=`$CYGPATH -u "$path"` 54429 54430 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 54431 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 54432 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 54433 # "foo.exe" is OK but "foo" is an error. 54434 # 54435 # This test is therefore slightly more accurate than "test -f" to check for file precense. 54436 # It is also a way to make sure we got the proper file name for the real test later on. 54437 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 54438 if test "x$test_shortpath" = x; then 54439 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of MSVC_DLL, which resolves as \"$path\", is invalid." >&5 54440 $as_echo "$as_me: The path of MSVC_DLL, which resolves as \"$path\", is invalid." >&6;} 54441 as_fn_error $? "Cannot locate the the path of MSVC_DLL" "$LINENO" 5 54442 fi 54443 54444 # Call helper function which possibly converts this using DOS-style short mode. 54445 # If so, the updated path is stored in $new_path. 54446 54447 input_path="$new_path" 54448 # Check if we need to convert this using DOS-style short mode. If the path 54449 # contains just simple characters, use it. Otherwise (spaces, weird characters), 54450 # take no chances and rewrite it. 54451 # Note: m4 eats our [], so we need to use [ and ] instead. 54452 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 54453 if test "x$has_forbidden_chars" != x; then 54454 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 54455 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 54456 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 54457 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 54458 # Going to short mode and back again did indeed matter. Since short mode is 54459 # case insensitive, let's make it lowercase to improve readability. 54460 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 54461 # Now convert it back to Unix-style (cygpath) 54462 input_path=`$CYGPATH -u "$shortmode_path"` 54463 new_path="$input_path" 54464 fi 54465 fi 54466 54467 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 54468 if test "x$test_cygdrive_prefix" = x; then 54469 # As a simple fix, exclude /usr/bin since it's not a real path. 54470 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 54471 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 54472 # a path prefixed by /cygdrive for fixpath to work. 54473 new_path="$CYGWIN_ROOT_PATH$input_path" 54474 fi 54475 fi 54476 54477 54478 if test "x$path" != "x$new_path"; then 54479 MSVC_DLL="$new_path" 54480 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting MSVC_DLL to \"$new_path\"" >&5 54481 $as_echo "$as_me: Rewriting MSVC_DLL to \"$new_path\"" >&6;} 54482 fi 54483 54484 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 54485 54486 path="$MSVC_DLL" 54487 has_colon=`$ECHO $path | $GREP ^.:` 54488 new_path="$path" 54489 if test "x$has_colon" = x; then 54490 # Not in mixed or Windows style, start by that. 54491 new_path=`cmd //c echo $path` 54492 fi 54493 54494 54495 input_path="$new_path" 54496 # Check if we need to convert this using DOS-style short mode. If the path 54497 # contains just simple characters, use it. Otherwise (spaces, weird characters), 54498 # take no chances and rewrite it. 54499 # Note: m4 eats our [], so we need to use [ and ] instead. 54500 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 54501 if test "x$has_forbidden_chars" != x; then 54502 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 54503 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 54504 fi 54505 54506 54507 windows_path="$new_path" 54508 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 54509 unix_path=`$CYGPATH -u "$windows_path"` 54510 new_path="$unix_path" 54511 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 54512 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 54513 new_path="$unix_path" 54514 fi 54515 54516 if test "x$path" != "x$new_path"; then 54517 MSVC_DLL="$new_path" 54518 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting MSVC_DLL to \"$new_path\"" >&5 54519 $as_echo "$as_me: Rewriting MSVC_DLL to \"$new_path\"" >&6;} 54520 fi 54521 54522 # Save the first 10 bytes of this path to the storage, so fixpath can work. 54523 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 54524 54525 else 54526 # We're on a unix platform. Hooray! :) 54527 path="$MSVC_DLL" 54528 has_space=`$ECHO "$path" | $GREP " "` 54529 if test "x$has_space" != x; then 54530 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of MSVC_DLL, which resolves as \"$path\", is invalid." >&5 54531 $as_echo "$as_me: The path of MSVC_DLL, which resolves as \"$path\", is invalid." >&6;} 54532 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 54533 fi 54534 54535 # Use eval to expand a potential ~ 54536 eval path="$path" 54537 if test ! -f "$path" && test ! -d "$path"; then 54538 as_fn_error $? "The path of MSVC_DLL, which resolves as \"$path\", is not found." "$LINENO" 5 54539 fi 54540 54541 if test -d "$path"; then 54542 MSVC_DLL="`cd "$path"; $THEPWDCMD -L`" 54543 else 54544 dir="`$DIRNAME "$path"`" 54545 base="`$BASENAME "$path"`" 54546 MSVC_DLL="`cd "$dir"; $THEPWDCMD -L`/$base" 54547 fi 54548 fi 54549 fi 54550 54551 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $DLL_NAME" >&5 54552 $as_echo_n "checking for $DLL_NAME... " >&6; } 54553 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MSVC_DLL" >&5 54554 $as_echo "$MSVC_DLL" >&6; } 54555 else 54556 { $as_echo "$as_me:${as_lineno-$LINENO}: result: incorrect, ignoring" >&5 54557 $as_echo "incorrect, ignoring" >&6; } 54558 { $as_echo "$as_me:${as_lineno-$LINENO}: The file type of the located $DLL_NAME is $MSVC_DLL_FILETYPE" >&5 54559 $as_echo "$as_me: The file type of the located $DLL_NAME is $MSVC_DLL_FILETYPE" >&6;} 54560 fi 54561 fi 54562 54563 fi 54564 fi 54565 54566 if test "x$MSVC_DLL" = x; then 54567 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $DLL_NAME" >&5 54568 $as_echo_n "checking for $DLL_NAME... " >&6; } 54569 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 54570 $as_echo "no" >&6; } 54571 as_fn_error $? "Could not find $DLL_NAME. Please specify using --with-msvcr-dll." "$LINENO" 5 54572 fi 54573 54574 MSVCR_DLL="$MSVC_DLL" 54575 fi 54576 54577 54578 54579 # Check whether --with-msvcp-dll was given. 54580 if test "${with_msvcp_dll+set}" = set; then : 54581 withval=$with_msvcp_dll; 54582 fi 54583 54584 54585 if test "x$MSVCP_NAME" != "x"; then 54586 if test "x$with_msvcp_dll" != x; then 54587 # If given explicitely by user, do not probe. If not present, fail directly. 54588 54589 DLL_NAME="$MSVCP_NAME" 54590 POSSIBLE_MSVC_DLL="$with_msvcp_dll" 54591 METHOD="--with-msvcp-dll" 54592 if test -n "$POSSIBLE_MSVC_DLL" -a -e "$POSSIBLE_MSVC_DLL"; then 54593 { $as_echo "$as_me:${as_lineno-$LINENO}: Found $DLL_NAME at $POSSIBLE_MSVC_DLL using $METHOD" >&5 54594 $as_echo "$as_me: Found $DLL_NAME at $POSSIBLE_MSVC_DLL using $METHOD" >&6;} 54595 54596 # Need to check if the found msvcr is correct architecture 54597 { $as_echo "$as_me:${as_lineno-$LINENO}: checking found $DLL_NAME architecture" >&5 54598 $as_echo_n "checking found $DLL_NAME architecture... " >&6; } 54599 MSVC_DLL_FILETYPE=`$FILE -b "$POSSIBLE_MSVC_DLL"` 54600 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 54601 # The MSYS 'file' command returns "PE32 executable for MS Windows (DLL) (GUI) Intel 80386 32-bit" 54602 # on x32 and "PE32+ executable for MS Windows (DLL) (GUI) Mono/.Net assembly" on x64 systems. 54603 if test "x$OPENJDK_TARGET_CPU_BITS" = x32; then 54604 CORRECT_MSVCR_ARCH="PE32 executable" 54605 else 54606 CORRECT_MSVCR_ARCH="PE32+ executable" 54607 fi 54608 else 54609 if test "x$OPENJDK_TARGET_CPU_BITS" = x32; then 54610 CORRECT_MSVCR_ARCH=386 54611 else 54612 CORRECT_MSVCR_ARCH=x86-64 54613 fi 54614 fi 54615 if $ECHO "$MSVC_DLL_FILETYPE" | $GREP "$CORRECT_MSVCR_ARCH" 2>&1 > /dev/null; then 54616 { $as_echo "$as_me:${as_lineno-$LINENO}: result: ok" >&5 54617 $as_echo "ok" >&6; } 54618 MSVC_DLL="$POSSIBLE_MSVC_DLL" 54619 54620 # Only process if variable expands to non-empty 54621 54622 if test "x$MSVC_DLL" != x; then 54623 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 54624 54625 # Input might be given as Windows format, start by converting to 54626 # unix format. 54627 path="$MSVC_DLL" 54628 new_path=`$CYGPATH -u "$path"` 54629 54630 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 54631 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 54632 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 54633 # "foo.exe" is OK but "foo" is an error. 54634 # 54635 # This test is therefore slightly more accurate than "test -f" to check for file precense. 54636 # It is also a way to make sure we got the proper file name for the real test later on. 54637 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 54638 if test "x$test_shortpath" = x; then 54639 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of MSVC_DLL, which resolves as \"$path\", is invalid." >&5 54640 $as_echo "$as_me: The path of MSVC_DLL, which resolves as \"$path\", is invalid." >&6;} 54641 as_fn_error $? "Cannot locate the the path of MSVC_DLL" "$LINENO" 5 54642 fi 54643 54644 # Call helper function which possibly converts this using DOS-style short mode. 54645 # If so, the updated path is stored in $new_path. 54646 54647 input_path="$new_path" 54648 # Check if we need to convert this using DOS-style short mode. If the path 54649 # contains just simple characters, use it. Otherwise (spaces, weird characters), 54650 # take no chances and rewrite it. 54651 # Note: m4 eats our [], so we need to use [ and ] instead. 54652 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 54653 if test "x$has_forbidden_chars" != x; then 54654 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 54655 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 54656 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 54657 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 54658 # Going to short mode and back again did indeed matter. Since short mode is 54659 # case insensitive, let's make it lowercase to improve readability. 54660 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 54661 # Now convert it back to Unix-style (cygpath) 54662 input_path=`$CYGPATH -u "$shortmode_path"` 54663 new_path="$input_path" 54664 fi 54665 fi 54666 54667 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 54668 if test "x$test_cygdrive_prefix" = x; then 54669 # As a simple fix, exclude /usr/bin since it's not a real path. 54670 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 54671 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 54672 # a path prefixed by /cygdrive for fixpath to work. 54673 new_path="$CYGWIN_ROOT_PATH$input_path" 54674 fi 54675 fi 54676 54677 54678 if test "x$path" != "x$new_path"; then 54679 MSVC_DLL="$new_path" 54680 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting MSVC_DLL to \"$new_path\"" >&5 54681 $as_echo "$as_me: Rewriting MSVC_DLL to \"$new_path\"" >&6;} 54682 fi 54683 54684 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 54685 54686 path="$MSVC_DLL" 54687 has_colon=`$ECHO $path | $GREP ^.:` 54688 new_path="$path" 54689 if test "x$has_colon" = x; then 54690 # Not in mixed or Windows style, start by that. 54691 new_path=`cmd //c echo $path` 54692 fi 54693 54694 54695 input_path="$new_path" 54696 # Check if we need to convert this using DOS-style short mode. If the path 54697 # contains just simple characters, use it. Otherwise (spaces, weird characters), 54698 # take no chances and rewrite it. 54699 # Note: m4 eats our [], so we need to use [ and ] instead. 54700 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 54701 if test "x$has_forbidden_chars" != x; then 54702 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 54703 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 54704 fi 54705 54706 54707 windows_path="$new_path" 54708 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 54709 unix_path=`$CYGPATH -u "$windows_path"` 54710 new_path="$unix_path" 54711 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 54712 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 54713 new_path="$unix_path" 54714 fi 54715 54716 if test "x$path" != "x$new_path"; then 54717 MSVC_DLL="$new_path" 54718 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting MSVC_DLL to \"$new_path\"" >&5 54719 $as_echo "$as_me: Rewriting MSVC_DLL to \"$new_path\"" >&6;} 54720 fi 54721 54722 # Save the first 10 bytes of this path to the storage, so fixpath can work. 54723 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 54724 54725 else 54726 # We're on a unix platform. Hooray! :) 54727 path="$MSVC_DLL" 54728 has_space=`$ECHO "$path" | $GREP " "` 54729 if test "x$has_space" != x; then 54730 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of MSVC_DLL, which resolves as \"$path\", is invalid." >&5 54731 $as_echo "$as_me: The path of MSVC_DLL, which resolves as \"$path\", is invalid." >&6;} 54732 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 54733 fi 54734 54735 # Use eval to expand a potential ~ 54736 eval path="$path" 54737 if test ! -f "$path" && test ! -d "$path"; then 54738 as_fn_error $? "The path of MSVC_DLL, which resolves as \"$path\", is not found." "$LINENO" 5 54739 fi 54740 54741 if test -d "$path"; then 54742 MSVC_DLL="`cd "$path"; $THEPWDCMD -L`" 54743 else 54744 dir="`$DIRNAME "$path"`" 54745 base="`$BASENAME "$path"`" 54746 MSVC_DLL="`cd "$dir"; $THEPWDCMD -L`/$base" 54747 fi 54748 fi 54749 fi 54750 54751 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $DLL_NAME" >&5 54752 $as_echo_n "checking for $DLL_NAME... " >&6; } 54753 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MSVC_DLL" >&5 54754 $as_echo "$MSVC_DLL" >&6; } 54755 else 54756 { $as_echo "$as_me:${as_lineno-$LINENO}: result: incorrect, ignoring" >&5 54757 $as_echo "incorrect, ignoring" >&6; } 54758 { $as_echo "$as_me:${as_lineno-$LINENO}: The file type of the located $DLL_NAME is $MSVC_DLL_FILETYPE" >&5 54759 $as_echo "$as_me: The file type of the located $DLL_NAME is $MSVC_DLL_FILETYPE" >&6;} 54760 fi 54761 fi 54762 54763 if test "x$MSVC_DLL" = x; then 54764 as_fn_error $? "Could not find a proper $MSVCP_NAME as specified by --with-msvcp-dll" "$LINENO" 5 54765 fi 54766 MSVCP_DLL="$MSVC_DLL" 54767 elif test "x$DEVKIT_MSVCP_DLL" != x; then 54768 54769 DLL_NAME="$MSVCP_NAME" 54770 POSSIBLE_MSVC_DLL="$DEVKIT_MSVCP_DLL" 54771 METHOD="devkit" 54772 if test -n "$POSSIBLE_MSVC_DLL" -a -e "$POSSIBLE_MSVC_DLL"; then 54773 { $as_echo "$as_me:${as_lineno-$LINENO}: Found $DLL_NAME at $POSSIBLE_MSVC_DLL using $METHOD" >&5 54774 $as_echo "$as_me: Found $DLL_NAME at $POSSIBLE_MSVC_DLL using $METHOD" >&6;} 54775 54776 # Need to check if the found msvcr is correct architecture 54777 { $as_echo "$as_me:${as_lineno-$LINENO}: checking found $DLL_NAME architecture" >&5 54778 $as_echo_n "checking found $DLL_NAME architecture... " >&6; } 54779 MSVC_DLL_FILETYPE=`$FILE -b "$POSSIBLE_MSVC_DLL"` 54780 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 54781 # The MSYS 'file' command returns "PE32 executable for MS Windows (DLL) (GUI) Intel 80386 32-bit" 54782 # on x32 and "PE32+ executable for MS Windows (DLL) (GUI) Mono/.Net assembly" on x64 systems. 54783 if test "x$OPENJDK_TARGET_CPU_BITS" = x32; then 54784 CORRECT_MSVCR_ARCH="PE32 executable" 54785 else 54786 CORRECT_MSVCR_ARCH="PE32+ executable" 54787 fi 54788 else 54789 if test "x$OPENJDK_TARGET_CPU_BITS" = x32; then 54790 CORRECT_MSVCR_ARCH=386 54791 else 54792 CORRECT_MSVCR_ARCH=x86-64 54793 fi 54794 fi 54795 if $ECHO "$MSVC_DLL_FILETYPE" | $GREP "$CORRECT_MSVCR_ARCH" 2>&1 > /dev/null; then 54796 { $as_echo "$as_me:${as_lineno-$LINENO}: result: ok" >&5 54797 $as_echo "ok" >&6; } 54798 MSVC_DLL="$POSSIBLE_MSVC_DLL" 54799 54800 # Only process if variable expands to non-empty 54801 54802 if test "x$MSVC_DLL" != x; then 54803 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 54804 54805 # Input might be given as Windows format, start by converting to 54806 # unix format. 54807 path="$MSVC_DLL" 54808 new_path=`$CYGPATH -u "$path"` 54809 54810 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 54811 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 54812 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 54813 # "foo.exe" is OK but "foo" is an error. 54814 # 54815 # This test is therefore slightly more accurate than "test -f" to check for file precense. 54816 # It is also a way to make sure we got the proper file name for the real test later on. 54817 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 54818 if test "x$test_shortpath" = x; then 54819 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of MSVC_DLL, which resolves as \"$path\", is invalid." >&5 54820 $as_echo "$as_me: The path of MSVC_DLL, which resolves as \"$path\", is invalid." >&6;} 54821 as_fn_error $? "Cannot locate the the path of MSVC_DLL" "$LINENO" 5 54822 fi 54823 54824 # Call helper function which possibly converts this using DOS-style short mode. 54825 # If so, the updated path is stored in $new_path. 54826 54827 input_path="$new_path" 54828 # Check if we need to convert this using DOS-style short mode. If the path 54829 # contains just simple characters, use it. Otherwise (spaces, weird characters), 54830 # take no chances and rewrite it. 54831 # Note: m4 eats our [], so we need to use [ and ] instead. 54832 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 54833 if test "x$has_forbidden_chars" != x; then 54834 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 54835 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 54836 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 54837 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 54838 # Going to short mode and back again did indeed matter. Since short mode is 54839 # case insensitive, let's make it lowercase to improve readability. 54840 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 54841 # Now convert it back to Unix-style (cygpath) 54842 input_path=`$CYGPATH -u "$shortmode_path"` 54843 new_path="$input_path" 54844 fi 54845 fi 54846 54847 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 54848 if test "x$test_cygdrive_prefix" = x; then 54849 # As a simple fix, exclude /usr/bin since it's not a real path. 54850 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 54851 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 54852 # a path prefixed by /cygdrive for fixpath to work. 54853 new_path="$CYGWIN_ROOT_PATH$input_path" 54854 fi 54855 fi 54856 54857 54858 if test "x$path" != "x$new_path"; then 54859 MSVC_DLL="$new_path" 54860 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting MSVC_DLL to \"$new_path\"" >&5 54861 $as_echo "$as_me: Rewriting MSVC_DLL to \"$new_path\"" >&6;} 54862 fi 54863 54864 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 54865 54866 path="$MSVC_DLL" 54867 has_colon=`$ECHO $path | $GREP ^.:` 54868 new_path="$path" 54869 if test "x$has_colon" = x; then 54870 # Not in mixed or Windows style, start by that. 54871 new_path=`cmd //c echo $path` 54872 fi 54873 54874 54875 input_path="$new_path" 54876 # Check if we need to convert this using DOS-style short mode. If the path 54877 # contains just simple characters, use it. Otherwise (spaces, weird characters), 54878 # take no chances and rewrite it. 54879 # Note: m4 eats our [], so we need to use [ and ] instead. 54880 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 54881 if test "x$has_forbidden_chars" != x; then 54882 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 54883 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 54884 fi 54885 54886 54887 windows_path="$new_path" 54888 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 54889 unix_path=`$CYGPATH -u "$windows_path"` 54890 new_path="$unix_path" 54891 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 54892 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 54893 new_path="$unix_path" 54894 fi 54895 54896 if test "x$path" != "x$new_path"; then 54897 MSVC_DLL="$new_path" 54898 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting MSVC_DLL to \"$new_path\"" >&5 54899 $as_echo "$as_me: Rewriting MSVC_DLL to \"$new_path\"" >&6;} 54900 fi 54901 54902 # Save the first 10 bytes of this path to the storage, so fixpath can work. 54903 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 54904 54905 else 54906 # We're on a unix platform. Hooray! :) 54907 path="$MSVC_DLL" 54908 has_space=`$ECHO "$path" | $GREP " "` 54909 if test "x$has_space" != x; then 54910 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of MSVC_DLL, which resolves as \"$path\", is invalid." >&5 54911 $as_echo "$as_me: The path of MSVC_DLL, which resolves as \"$path\", is invalid." >&6;} 54912 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 54913 fi 54914 54915 # Use eval to expand a potential ~ 54916 eval path="$path" 54917 if test ! -f "$path" && test ! -d "$path"; then 54918 as_fn_error $? "The path of MSVC_DLL, which resolves as \"$path\", is not found." "$LINENO" 5 54919 fi 54920 54921 if test -d "$path"; then 54922 MSVC_DLL="`cd "$path"; $THEPWDCMD -L`" 54923 else 54924 dir="`$DIRNAME "$path"`" 54925 base="`$BASENAME "$path"`" 54926 MSVC_DLL="`cd "$dir"; $THEPWDCMD -L`/$base" 54927 fi 54928 fi 54929 fi 54930 54931 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $DLL_NAME" >&5 54932 $as_echo_n "checking for $DLL_NAME... " >&6; } 54933 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MSVC_DLL" >&5 54934 $as_echo "$MSVC_DLL" >&6; } 54935 else 54936 { $as_echo "$as_me:${as_lineno-$LINENO}: result: incorrect, ignoring" >&5 54937 $as_echo "incorrect, ignoring" >&6; } 54938 { $as_echo "$as_me:${as_lineno-$LINENO}: The file type of the located $DLL_NAME is $MSVC_DLL_FILETYPE" >&5 54939 $as_echo "$as_me: The file type of the located $DLL_NAME is $MSVC_DLL_FILETYPE" >&6;} 54940 fi 54941 fi 54942 54943 if test "x$MSVC_DLL" = x; then 54944 as_fn_error $? "Could not find a proper $MSVCP_NAME as specified by devkit" "$LINENO" 5 54945 fi 54946 MSVCP_DLL="$MSVC_DLL" 54947 else 54948 54949 DLL_NAME="${MSVCP_NAME}" 54950 MSVC_DLL= 54951 54952 if test "x$MSVC_DLL" = x; then 54953 # Probe: Using well-known location from Visual Studio 10.0 54954 if test "x$VCINSTALLDIR" != x; then 54955 CYGWIN_VC_INSTALL_DIR="$VCINSTALLDIR" 54956 54957 windows_path="$CYGWIN_VC_INSTALL_DIR" 54958 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 54959 unix_path=`$CYGPATH -u "$windows_path"` 54960 CYGWIN_VC_INSTALL_DIR="$unix_path" 54961 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 54962 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 54963 CYGWIN_VC_INSTALL_DIR="$unix_path" 54964 fi 54965 54966 if test "x$OPENJDK_TARGET_CPU_BITS" = x64; then 54967 POSSIBLE_MSVC_DLL="$CYGWIN_VC_INSTALL_DIR/redist/x64/Microsoft.VC${VS_VERSION_INTERNAL}.CRT/$DLL_NAME" 54968 else 54969 POSSIBLE_MSVC_DLL="$CYGWIN_VC_INSTALL_DIR/redist/x86/Microsoft.VC${VS_VERSION_INTERNAL}.CRT/$DLL_NAME" 54970 fi 54971 $ECHO "POSSIBLE_MSVC_DLL $POSSIBLEMSVC_DLL" 54972 54973 DLL_NAME="$DLL_NAME" 54974 POSSIBLE_MSVC_DLL="$POSSIBLE_MSVC_DLL" 54975 METHOD="well-known location in VCINSTALLDIR" 54976 if test -n "$POSSIBLE_MSVC_DLL" -a -e "$POSSIBLE_MSVC_DLL"; then 54977 { $as_echo "$as_me:${as_lineno-$LINENO}: Found $DLL_NAME at $POSSIBLE_MSVC_DLL using $METHOD" >&5 54978 $as_echo "$as_me: Found $DLL_NAME at $POSSIBLE_MSVC_DLL using $METHOD" >&6;} 54979 54980 # Need to check if the found msvcr is correct architecture 54981 { $as_echo "$as_me:${as_lineno-$LINENO}: checking found $DLL_NAME architecture" >&5 54982 $as_echo_n "checking found $DLL_NAME architecture... " >&6; } 54983 MSVC_DLL_FILETYPE=`$FILE -b "$POSSIBLE_MSVC_DLL"` 54984 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 54985 # The MSYS 'file' command returns "PE32 executable for MS Windows (DLL) (GUI) Intel 80386 32-bit" 54986 # on x32 and "PE32+ executable for MS Windows (DLL) (GUI) Mono/.Net assembly" on x64 systems. 54987 if test "x$OPENJDK_TARGET_CPU_BITS" = x32; then 54988 CORRECT_MSVCR_ARCH="PE32 executable" 54989 else 54990 CORRECT_MSVCR_ARCH="PE32+ executable" 54991 fi 54992 else 54993 if test "x$OPENJDK_TARGET_CPU_BITS" = x32; then 54994 CORRECT_MSVCR_ARCH=386 54995 else 54996 CORRECT_MSVCR_ARCH=x86-64 54997 fi 54998 fi 54999 if $ECHO "$MSVC_DLL_FILETYPE" | $GREP "$CORRECT_MSVCR_ARCH" 2>&1 > /dev/null; then 55000 { $as_echo "$as_me:${as_lineno-$LINENO}: result: ok" >&5 55001 $as_echo "ok" >&6; } 55002 MSVC_DLL="$POSSIBLE_MSVC_DLL" 55003 55004 # Only process if variable expands to non-empty 55005 55006 if test "x$MSVC_DLL" != x; then 55007 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 55008 55009 # Input might be given as Windows format, start by converting to 55010 # unix format. 55011 path="$MSVC_DLL" 55012 new_path=`$CYGPATH -u "$path"` 55013 55014 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 55015 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 55016 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 55017 # "foo.exe" is OK but "foo" is an error. 55018 # 55019 # This test is therefore slightly more accurate than "test -f" to check for file precense. 55020 # It is also a way to make sure we got the proper file name for the real test later on. 55021 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 55022 if test "x$test_shortpath" = x; then 55023 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of MSVC_DLL, which resolves as \"$path\", is invalid." >&5 55024 $as_echo "$as_me: The path of MSVC_DLL, which resolves as \"$path\", is invalid." >&6;} 55025 as_fn_error $? "Cannot locate the the path of MSVC_DLL" "$LINENO" 5 55026 fi 55027 55028 # Call helper function which possibly converts this using DOS-style short mode. 55029 # If so, the updated path is stored in $new_path. 55030 55031 input_path="$new_path" 55032 # Check if we need to convert this using DOS-style short mode. If the path 55033 # contains just simple characters, use it. Otherwise (spaces, weird characters), 55034 # take no chances and rewrite it. 55035 # Note: m4 eats our [], so we need to use [ and ] instead. 55036 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 55037 if test "x$has_forbidden_chars" != x; then 55038 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 55039 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 55040 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 55041 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 55042 # Going to short mode and back again did indeed matter. Since short mode is 55043 # case insensitive, let's make it lowercase to improve readability. 55044 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 55045 # Now convert it back to Unix-style (cygpath) 55046 input_path=`$CYGPATH -u "$shortmode_path"` 55047 new_path="$input_path" 55048 fi 55049 fi 55050 55051 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 55052 if test "x$test_cygdrive_prefix" = x; then 55053 # As a simple fix, exclude /usr/bin since it's not a real path. 55054 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 55055 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 55056 # a path prefixed by /cygdrive for fixpath to work. 55057 new_path="$CYGWIN_ROOT_PATH$input_path" 55058 fi 55059 fi 55060 55061 55062 if test "x$path" != "x$new_path"; then 55063 MSVC_DLL="$new_path" 55064 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting MSVC_DLL to \"$new_path\"" >&5 55065 $as_echo "$as_me: Rewriting MSVC_DLL to \"$new_path\"" >&6;} 55066 fi 55067 55068 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 55069 55070 path="$MSVC_DLL" 55071 has_colon=`$ECHO $path | $GREP ^.:` 55072 new_path="$path" 55073 if test "x$has_colon" = x; then 55074 # Not in mixed or Windows style, start by that. 55075 new_path=`cmd //c echo $path` 55076 fi 55077 55078 55079 input_path="$new_path" 55080 # Check if we need to convert this using DOS-style short mode. If the path 55081 # contains just simple characters, use it. Otherwise (spaces, weird characters), 55082 # take no chances and rewrite it. 55083 # Note: m4 eats our [], so we need to use [ and ] instead. 55084 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 55085 if test "x$has_forbidden_chars" != x; then 55086 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 55087 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 55088 fi 55089 55090 55091 windows_path="$new_path" 55092 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 55093 unix_path=`$CYGPATH -u "$windows_path"` 55094 new_path="$unix_path" 55095 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 55096 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 55097 new_path="$unix_path" 55098 fi 55099 55100 if test "x$path" != "x$new_path"; then 55101 MSVC_DLL="$new_path" 55102 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting MSVC_DLL to \"$new_path\"" >&5 55103 $as_echo "$as_me: Rewriting MSVC_DLL to \"$new_path\"" >&6;} 55104 fi 55105 55106 # Save the first 10 bytes of this path to the storage, so fixpath can work. 55107 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 55108 55109 else 55110 # We're on a unix platform. Hooray! :) 55111 path="$MSVC_DLL" 55112 has_space=`$ECHO "$path" | $GREP " "` 55113 if test "x$has_space" != x; then 55114 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of MSVC_DLL, which resolves as \"$path\", is invalid." >&5 55115 $as_echo "$as_me: The path of MSVC_DLL, which resolves as \"$path\", is invalid." >&6;} 55116 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 55117 fi 55118 55119 # Use eval to expand a potential ~ 55120 eval path="$path" 55121 if test ! -f "$path" && test ! -d "$path"; then 55122 as_fn_error $? "The path of MSVC_DLL, which resolves as \"$path\", is not found." "$LINENO" 5 55123 fi 55124 55125 if test -d "$path"; then 55126 MSVC_DLL="`cd "$path"; $THEPWDCMD -L`" 55127 else 55128 dir="`$DIRNAME "$path"`" 55129 base="`$BASENAME "$path"`" 55130 MSVC_DLL="`cd "$dir"; $THEPWDCMD -L`/$base" 55131 fi 55132 fi 55133 fi 55134 55135 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $DLL_NAME" >&5 55136 $as_echo_n "checking for $DLL_NAME... " >&6; } 55137 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MSVC_DLL" >&5 55138 $as_echo "$MSVC_DLL" >&6; } 55139 else 55140 { $as_echo "$as_me:${as_lineno-$LINENO}: result: incorrect, ignoring" >&5 55141 $as_echo "incorrect, ignoring" >&6; } 55142 { $as_echo "$as_me:${as_lineno-$LINENO}: The file type of the located $DLL_NAME is $MSVC_DLL_FILETYPE" >&5 55143 $as_echo "$as_me: The file type of the located $DLL_NAME is $MSVC_DLL_FILETYPE" >&6;} 55144 fi 55145 fi 55146 55147 fi 55148 fi 55149 55150 if test "x$MSVC_DLL" = x; then 55151 # Probe: Check in the Boot JDK directory. 55152 POSSIBLE_MSVC_DLL="$BOOT_JDK/bin/$DLL_NAME" 55153 55154 DLL_NAME="$DLL_NAME" 55155 POSSIBLE_MSVC_DLL="$POSSIBLE_MSVC_DLL" 55156 METHOD="well-known location in Boot JDK" 55157 if test -n "$POSSIBLE_MSVC_DLL" -a -e "$POSSIBLE_MSVC_DLL"; then 55158 { $as_echo "$as_me:${as_lineno-$LINENO}: Found $DLL_NAME at $POSSIBLE_MSVC_DLL using $METHOD" >&5 55159 $as_echo "$as_me: Found $DLL_NAME at $POSSIBLE_MSVC_DLL using $METHOD" >&6;} 55160 55161 # Need to check if the found msvcr is correct architecture 55162 { $as_echo "$as_me:${as_lineno-$LINENO}: checking found $DLL_NAME architecture" >&5 55163 $as_echo_n "checking found $DLL_NAME architecture... " >&6; } 55164 MSVC_DLL_FILETYPE=`$FILE -b "$POSSIBLE_MSVC_DLL"` 55165 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 55166 # The MSYS 'file' command returns "PE32 executable for MS Windows (DLL) (GUI) Intel 80386 32-bit" 55167 # on x32 and "PE32+ executable for MS Windows (DLL) (GUI) Mono/.Net assembly" on x64 systems. 55168 if test "x$OPENJDK_TARGET_CPU_BITS" = x32; then 55169 CORRECT_MSVCR_ARCH="PE32 executable" 55170 else 55171 CORRECT_MSVCR_ARCH="PE32+ executable" 55172 fi 55173 else 55174 if test "x$OPENJDK_TARGET_CPU_BITS" = x32; then 55175 CORRECT_MSVCR_ARCH=386 55176 else 55177 CORRECT_MSVCR_ARCH=x86-64 55178 fi 55179 fi 55180 if $ECHO "$MSVC_DLL_FILETYPE" | $GREP "$CORRECT_MSVCR_ARCH" 2>&1 > /dev/null; then 55181 { $as_echo "$as_me:${as_lineno-$LINENO}: result: ok" >&5 55182 $as_echo "ok" >&6; } 55183 MSVC_DLL="$POSSIBLE_MSVC_DLL" 55184 55185 # Only process if variable expands to non-empty 55186 55187 if test "x$MSVC_DLL" != x; then 55188 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 55189 55190 # Input might be given as Windows format, start by converting to 55191 # unix format. 55192 path="$MSVC_DLL" 55193 new_path=`$CYGPATH -u "$path"` 55194 55195 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 55196 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 55197 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 55198 # "foo.exe" is OK but "foo" is an error. 55199 # 55200 # This test is therefore slightly more accurate than "test -f" to check for file precense. 55201 # It is also a way to make sure we got the proper file name for the real test later on. 55202 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 55203 if test "x$test_shortpath" = x; then 55204 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of MSVC_DLL, which resolves as \"$path\", is invalid." >&5 55205 $as_echo "$as_me: The path of MSVC_DLL, which resolves as \"$path\", is invalid." >&6;} 55206 as_fn_error $? "Cannot locate the the path of MSVC_DLL" "$LINENO" 5 55207 fi 55208 55209 # Call helper function which possibly converts this using DOS-style short mode. 55210 # If so, the updated path is stored in $new_path. 55211 55212 input_path="$new_path" 55213 # Check if we need to convert this using DOS-style short mode. If the path 55214 # contains just simple characters, use it. Otherwise (spaces, weird characters), 55215 # take no chances and rewrite it. 55216 # Note: m4 eats our [], so we need to use [ and ] instead. 55217 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 55218 if test "x$has_forbidden_chars" != x; then 55219 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 55220 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 55221 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 55222 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 55223 # Going to short mode and back again did indeed matter. Since short mode is 55224 # case insensitive, let's make it lowercase to improve readability. 55225 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 55226 # Now convert it back to Unix-style (cygpath) 55227 input_path=`$CYGPATH -u "$shortmode_path"` 55228 new_path="$input_path" 55229 fi 55230 fi 55231 55232 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 55233 if test "x$test_cygdrive_prefix" = x; then 55234 # As a simple fix, exclude /usr/bin since it's not a real path. 55235 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 55236 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 55237 # a path prefixed by /cygdrive for fixpath to work. 55238 new_path="$CYGWIN_ROOT_PATH$input_path" 55239 fi 55240 fi 55241 55242 55243 if test "x$path" != "x$new_path"; then 55244 MSVC_DLL="$new_path" 55245 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting MSVC_DLL to \"$new_path\"" >&5 55246 $as_echo "$as_me: Rewriting MSVC_DLL to \"$new_path\"" >&6;} 55247 fi 55248 55249 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 55250 55251 path="$MSVC_DLL" 55252 has_colon=`$ECHO $path | $GREP ^.:` 55253 new_path="$path" 55254 if test "x$has_colon" = x; then 55255 # Not in mixed or Windows style, start by that. 55256 new_path=`cmd //c echo $path` 55257 fi 55258 55259 55260 input_path="$new_path" 55261 # Check if we need to convert this using DOS-style short mode. If the path 55262 # contains just simple characters, use it. Otherwise (spaces, weird characters), 55263 # take no chances and rewrite it. 55264 # Note: m4 eats our [], so we need to use [ and ] instead. 55265 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 55266 if test "x$has_forbidden_chars" != x; then 55267 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 55268 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 55269 fi 55270 55271 55272 windows_path="$new_path" 55273 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 55274 unix_path=`$CYGPATH -u "$windows_path"` 55275 new_path="$unix_path" 55276 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 55277 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 55278 new_path="$unix_path" 55279 fi 55280 55281 if test "x$path" != "x$new_path"; then 55282 MSVC_DLL="$new_path" 55283 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting MSVC_DLL to \"$new_path\"" >&5 55284 $as_echo "$as_me: Rewriting MSVC_DLL to \"$new_path\"" >&6;} 55285 fi 55286 55287 # Save the first 10 bytes of this path to the storage, so fixpath can work. 55288 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 55289 55290 else 55291 # We're on a unix platform. Hooray! :) 55292 path="$MSVC_DLL" 55293 has_space=`$ECHO "$path" | $GREP " "` 55294 if test "x$has_space" != x; then 55295 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of MSVC_DLL, which resolves as \"$path\", is invalid." >&5 55296 $as_echo "$as_me: The path of MSVC_DLL, which resolves as \"$path\", is invalid." >&6;} 55297 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 55298 fi 55299 55300 # Use eval to expand a potential ~ 55301 eval path="$path" 55302 if test ! -f "$path" && test ! -d "$path"; then 55303 as_fn_error $? "The path of MSVC_DLL, which resolves as \"$path\", is not found." "$LINENO" 5 55304 fi 55305 55306 if test -d "$path"; then 55307 MSVC_DLL="`cd "$path"; $THEPWDCMD -L`" 55308 else 55309 dir="`$DIRNAME "$path"`" 55310 base="`$BASENAME "$path"`" 55311 MSVC_DLL="`cd "$dir"; $THEPWDCMD -L`/$base" 55312 fi 55313 fi 55314 fi 55315 55316 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $DLL_NAME" >&5 55317 $as_echo_n "checking for $DLL_NAME... " >&6; } 55318 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MSVC_DLL" >&5 55319 $as_echo "$MSVC_DLL" >&6; } 55320 else 55321 { $as_echo "$as_me:${as_lineno-$LINENO}: result: incorrect, ignoring" >&5 55322 $as_echo "incorrect, ignoring" >&6; } 55323 { $as_echo "$as_me:${as_lineno-$LINENO}: The file type of the located $DLL_NAME is $MSVC_DLL_FILETYPE" >&5 55324 $as_echo "$as_me: The file type of the located $DLL_NAME is $MSVC_DLL_FILETYPE" >&6;} 55325 fi 55326 fi 55327 55328 fi 55329 55330 if test "x$MSVC_DLL" = x; then 55331 # Probe: Look in the Windows system32 directory 55332 CYGWIN_SYSTEMROOT="$SYSTEMROOT" 55333 55334 windows_path="$CYGWIN_SYSTEMROOT" 55335 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 55336 unix_path=`$CYGPATH -u "$windows_path"` 55337 CYGWIN_SYSTEMROOT="$unix_path" 55338 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 55339 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 55340 CYGWIN_SYSTEMROOT="$unix_path" 55341 fi 55342 55343 POSSIBLE_MSVC_DLL="$CYGWIN_SYSTEMROOT/system32/$DLL_NAME" 55344 55345 DLL_NAME="$DLL_NAME" 55346 POSSIBLE_MSVC_DLL="$POSSIBLE_MSVC_DLL" 55347 METHOD="well-known location in SYSTEMROOT" 55348 if test -n "$POSSIBLE_MSVC_DLL" -a -e "$POSSIBLE_MSVC_DLL"; then 55349 { $as_echo "$as_me:${as_lineno-$LINENO}: Found $DLL_NAME at $POSSIBLE_MSVC_DLL using $METHOD" >&5 55350 $as_echo "$as_me: Found $DLL_NAME at $POSSIBLE_MSVC_DLL using $METHOD" >&6;} 55351 55352 # Need to check if the found msvcr is correct architecture 55353 { $as_echo "$as_me:${as_lineno-$LINENO}: checking found $DLL_NAME architecture" >&5 55354 $as_echo_n "checking found $DLL_NAME architecture... " >&6; } 55355 MSVC_DLL_FILETYPE=`$FILE -b "$POSSIBLE_MSVC_DLL"` 55356 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 55357 # The MSYS 'file' command returns "PE32 executable for MS Windows (DLL) (GUI) Intel 80386 32-bit" 55358 # on x32 and "PE32+ executable for MS Windows (DLL) (GUI) Mono/.Net assembly" on x64 systems. 55359 if test "x$OPENJDK_TARGET_CPU_BITS" = x32; then 55360 CORRECT_MSVCR_ARCH="PE32 executable" 55361 else 55362 CORRECT_MSVCR_ARCH="PE32+ executable" 55363 fi 55364 else 55365 if test "x$OPENJDK_TARGET_CPU_BITS" = x32; then 55366 CORRECT_MSVCR_ARCH=386 55367 else 55368 CORRECT_MSVCR_ARCH=x86-64 55369 fi 55370 fi 55371 if $ECHO "$MSVC_DLL_FILETYPE" | $GREP "$CORRECT_MSVCR_ARCH" 2>&1 > /dev/null; then 55372 { $as_echo "$as_me:${as_lineno-$LINENO}: result: ok" >&5 55373 $as_echo "ok" >&6; } 55374 MSVC_DLL="$POSSIBLE_MSVC_DLL" 55375 55376 # Only process if variable expands to non-empty 55377 55378 if test "x$MSVC_DLL" != x; then 55379 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 55380 55381 # Input might be given as Windows format, start by converting to 55382 # unix format. 55383 path="$MSVC_DLL" 55384 new_path=`$CYGPATH -u "$path"` 55385 55386 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 55387 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 55388 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 55389 # "foo.exe" is OK but "foo" is an error. 55390 # 55391 # This test is therefore slightly more accurate than "test -f" to check for file precense. 55392 # It is also a way to make sure we got the proper file name for the real test later on. 55393 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 55394 if test "x$test_shortpath" = x; then 55395 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of MSVC_DLL, which resolves as \"$path\", is invalid." >&5 55396 $as_echo "$as_me: The path of MSVC_DLL, which resolves as \"$path\", is invalid." >&6;} 55397 as_fn_error $? "Cannot locate the the path of MSVC_DLL" "$LINENO" 5 55398 fi 55399 55400 # Call helper function which possibly converts this using DOS-style short mode. 55401 # If so, the updated path is stored in $new_path. 55402 55403 input_path="$new_path" 55404 # Check if we need to convert this using DOS-style short mode. If the path 55405 # contains just simple characters, use it. Otherwise (spaces, weird characters), 55406 # take no chances and rewrite it. 55407 # Note: m4 eats our [], so we need to use [ and ] instead. 55408 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 55409 if test "x$has_forbidden_chars" != x; then 55410 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 55411 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 55412 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 55413 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 55414 # Going to short mode and back again did indeed matter. Since short mode is 55415 # case insensitive, let's make it lowercase to improve readability. 55416 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 55417 # Now convert it back to Unix-style (cygpath) 55418 input_path=`$CYGPATH -u "$shortmode_path"` 55419 new_path="$input_path" 55420 fi 55421 fi 55422 55423 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 55424 if test "x$test_cygdrive_prefix" = x; then 55425 # As a simple fix, exclude /usr/bin since it's not a real path. 55426 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 55427 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 55428 # a path prefixed by /cygdrive for fixpath to work. 55429 new_path="$CYGWIN_ROOT_PATH$input_path" 55430 fi 55431 fi 55432 55433 55434 if test "x$path" != "x$new_path"; then 55435 MSVC_DLL="$new_path" 55436 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting MSVC_DLL to \"$new_path\"" >&5 55437 $as_echo "$as_me: Rewriting MSVC_DLL to \"$new_path\"" >&6;} 55438 fi 55439 55440 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 55441 55442 path="$MSVC_DLL" 55443 has_colon=`$ECHO $path | $GREP ^.:` 55444 new_path="$path" 55445 if test "x$has_colon" = x; then 55446 # Not in mixed or Windows style, start by that. 55447 new_path=`cmd //c echo $path` 55448 fi 55449 55450 55451 input_path="$new_path" 55452 # Check if we need to convert this using DOS-style short mode. If the path 55453 # contains just simple characters, use it. Otherwise (spaces, weird characters), 55454 # take no chances and rewrite it. 55455 # Note: m4 eats our [], so we need to use [ and ] instead. 55456 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 55457 if test "x$has_forbidden_chars" != x; then 55458 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 55459 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 55460 fi 55461 55462 55463 windows_path="$new_path" 55464 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 55465 unix_path=`$CYGPATH -u "$windows_path"` 55466 new_path="$unix_path" 55467 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 55468 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 55469 new_path="$unix_path" 55470 fi 55471 55472 if test "x$path" != "x$new_path"; then 55473 MSVC_DLL="$new_path" 55474 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting MSVC_DLL to \"$new_path\"" >&5 55475 $as_echo "$as_me: Rewriting MSVC_DLL to \"$new_path\"" >&6;} 55476 fi 55477 55478 # Save the first 10 bytes of this path to the storage, so fixpath can work. 55479 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 55480 55481 else 55482 # We're on a unix platform. Hooray! :) 55483 path="$MSVC_DLL" 55484 has_space=`$ECHO "$path" | $GREP " "` 55485 if test "x$has_space" != x; then 55486 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of MSVC_DLL, which resolves as \"$path\", is invalid." >&5 55487 $as_echo "$as_me: The path of MSVC_DLL, which resolves as \"$path\", is invalid." >&6;} 55488 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 55489 fi 55490 55491 # Use eval to expand a potential ~ 55492 eval path="$path" 55493 if test ! -f "$path" && test ! -d "$path"; then 55494 as_fn_error $? "The path of MSVC_DLL, which resolves as \"$path\", is not found." "$LINENO" 5 55495 fi 55496 55497 if test -d "$path"; then 55498 MSVC_DLL="`cd "$path"; $THEPWDCMD -L`" 55499 else 55500 dir="`$DIRNAME "$path"`" 55501 base="`$BASENAME "$path"`" 55502 MSVC_DLL="`cd "$dir"; $THEPWDCMD -L`/$base" 55503 fi 55504 fi 55505 fi 55506 55507 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $DLL_NAME" >&5 55508 $as_echo_n "checking for $DLL_NAME... " >&6; } 55509 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MSVC_DLL" >&5 55510 $as_echo "$MSVC_DLL" >&6; } 55511 else 55512 { $as_echo "$as_me:${as_lineno-$LINENO}: result: incorrect, ignoring" >&5 55513 $as_echo "incorrect, ignoring" >&6; } 55514 { $as_echo "$as_me:${as_lineno-$LINENO}: The file type of the located $DLL_NAME is $MSVC_DLL_FILETYPE" >&5 55515 $as_echo "$as_me: The file type of the located $DLL_NAME is $MSVC_DLL_FILETYPE" >&6;} 55516 fi 55517 fi 55518 55519 fi 55520 55521 if test "x$MSVC_DLL" = x; then 55522 # Probe: If Visual Studio Express is installed, there is usually one with the debugger 55523 if test "x$VS100COMNTOOLS" != x; then 55524 CYGWIN_VS_TOOLS_DIR="$VS100COMNTOOLS/.." 55525 55526 windows_path="$CYGWIN_VS_TOOLS_DIR" 55527 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 55528 unix_path=`$CYGPATH -u "$windows_path"` 55529 CYGWIN_VS_TOOLS_DIR="$unix_path" 55530 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 55531 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 55532 CYGWIN_VS_TOOLS_DIR="$unix_path" 55533 fi 55534 55535 if test "x$OPENJDK_TARGET_CPU_BITS" = x64; then 55536 POSSIBLE_MSVC_DLL=`$FIND "$CYGWIN_VS_TOOLS_DIR" -name $DLL_NAME \ 55537 | $GREP -i /x64/ | $HEAD --lines 1` 55538 else 55539 POSSIBLE_MSVC_DLL=`$FIND "$CYGWIN_VS_TOOLS_DIR" -name $DLL_NAME \ 55540 | $GREP -i /x86/ | $HEAD --lines 1` 55541 fi 55542 55543 DLL_NAME="$DLL_NAME" 55544 POSSIBLE_MSVC_DLL="$POSSIBLE_MSVC_DLL" 55545 METHOD="search of VS100COMNTOOLS" 55546 if test -n "$POSSIBLE_MSVC_DLL" -a -e "$POSSIBLE_MSVC_DLL"; then 55547 { $as_echo "$as_me:${as_lineno-$LINENO}: Found $DLL_NAME at $POSSIBLE_MSVC_DLL using $METHOD" >&5 55548 $as_echo "$as_me: Found $DLL_NAME at $POSSIBLE_MSVC_DLL using $METHOD" >&6;} 55549 55550 # Need to check if the found msvcr is correct architecture 55551 { $as_echo "$as_me:${as_lineno-$LINENO}: checking found $DLL_NAME architecture" >&5 55552 $as_echo_n "checking found $DLL_NAME architecture... " >&6; } 55553 MSVC_DLL_FILETYPE=`$FILE -b "$POSSIBLE_MSVC_DLL"` 55554 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 55555 # The MSYS 'file' command returns "PE32 executable for MS Windows (DLL) (GUI) Intel 80386 32-bit" 55556 # on x32 and "PE32+ executable for MS Windows (DLL) (GUI) Mono/.Net assembly" on x64 systems. 55557 if test "x$OPENJDK_TARGET_CPU_BITS" = x32; then 55558 CORRECT_MSVCR_ARCH="PE32 executable" 55559 else 55560 CORRECT_MSVCR_ARCH="PE32+ executable" 55561 fi 55562 else 55563 if test "x$OPENJDK_TARGET_CPU_BITS" = x32; then 55564 CORRECT_MSVCR_ARCH=386 55565 else 55566 CORRECT_MSVCR_ARCH=x86-64 55567 fi 55568 fi 55569 if $ECHO "$MSVC_DLL_FILETYPE" | $GREP "$CORRECT_MSVCR_ARCH" 2>&1 > /dev/null; then 55570 { $as_echo "$as_me:${as_lineno-$LINENO}: result: ok" >&5 55571 $as_echo "ok" >&6; } 55572 MSVC_DLL="$POSSIBLE_MSVC_DLL" 55573 55574 # Only process if variable expands to non-empty 55575 55576 if test "x$MSVC_DLL" != x; then 55577 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 55578 55579 # Input might be given as Windows format, start by converting to 55580 # unix format. 55581 path="$MSVC_DLL" 55582 new_path=`$CYGPATH -u "$path"` 55583 55584 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 55585 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 55586 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 55587 # "foo.exe" is OK but "foo" is an error. 55588 # 55589 # This test is therefore slightly more accurate than "test -f" to check for file precense. 55590 # It is also a way to make sure we got the proper file name for the real test later on. 55591 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 55592 if test "x$test_shortpath" = x; then 55593 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of MSVC_DLL, which resolves as \"$path\", is invalid." >&5 55594 $as_echo "$as_me: The path of MSVC_DLL, which resolves as \"$path\", is invalid." >&6;} 55595 as_fn_error $? "Cannot locate the the path of MSVC_DLL" "$LINENO" 5 55596 fi 55597 55598 # Call helper function which possibly converts this using DOS-style short mode. 55599 # If so, the updated path is stored in $new_path. 55600 55601 input_path="$new_path" 55602 # Check if we need to convert this using DOS-style short mode. If the path 55603 # contains just simple characters, use it. Otherwise (spaces, weird characters), 55604 # take no chances and rewrite it. 55605 # Note: m4 eats our [], so we need to use [ and ] instead. 55606 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 55607 if test "x$has_forbidden_chars" != x; then 55608 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 55609 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 55610 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 55611 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 55612 # Going to short mode and back again did indeed matter. Since short mode is 55613 # case insensitive, let's make it lowercase to improve readability. 55614 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 55615 # Now convert it back to Unix-style (cygpath) 55616 input_path=`$CYGPATH -u "$shortmode_path"` 55617 new_path="$input_path" 55618 fi 55619 fi 55620 55621 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 55622 if test "x$test_cygdrive_prefix" = x; then 55623 # As a simple fix, exclude /usr/bin since it's not a real path. 55624 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 55625 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 55626 # a path prefixed by /cygdrive for fixpath to work. 55627 new_path="$CYGWIN_ROOT_PATH$input_path" 55628 fi 55629 fi 55630 55631 55632 if test "x$path" != "x$new_path"; then 55633 MSVC_DLL="$new_path" 55634 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting MSVC_DLL to \"$new_path\"" >&5 55635 $as_echo "$as_me: Rewriting MSVC_DLL to \"$new_path\"" >&6;} 55636 fi 55637 55638 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 55639 55640 path="$MSVC_DLL" 55641 has_colon=`$ECHO $path | $GREP ^.:` 55642 new_path="$path" 55643 if test "x$has_colon" = x; then 55644 # Not in mixed or Windows style, start by that. 55645 new_path=`cmd //c echo $path` 55646 fi 55647 55648 55649 input_path="$new_path" 55650 # Check if we need to convert this using DOS-style short mode. If the path 55651 # contains just simple characters, use it. Otherwise (spaces, weird characters), 55652 # take no chances and rewrite it. 55653 # Note: m4 eats our [], so we need to use [ and ] instead. 55654 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 55655 if test "x$has_forbidden_chars" != x; then 55656 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 55657 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 55658 fi 55659 55660 55661 windows_path="$new_path" 55662 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 55663 unix_path=`$CYGPATH -u "$windows_path"` 55664 new_path="$unix_path" 55665 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 55666 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 55667 new_path="$unix_path" 55668 fi 55669 55670 if test "x$path" != "x$new_path"; then 55671 MSVC_DLL="$new_path" 55672 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting MSVC_DLL to \"$new_path\"" >&5 55673 $as_echo "$as_me: Rewriting MSVC_DLL to \"$new_path\"" >&6;} 55674 fi 55675 55676 # Save the first 10 bytes of this path to the storage, so fixpath can work. 55677 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 55678 55679 else 55680 # We're on a unix platform. Hooray! :) 55681 path="$MSVC_DLL" 55682 has_space=`$ECHO "$path" | $GREP " "` 55683 if test "x$has_space" != x; then 55684 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of MSVC_DLL, which resolves as \"$path\", is invalid." >&5 55685 $as_echo "$as_me: The path of MSVC_DLL, which resolves as \"$path\", is invalid." >&6;} 55686 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 55687 fi 55688 55689 # Use eval to expand a potential ~ 55690 eval path="$path" 55691 if test ! -f "$path" && test ! -d "$path"; then 55692 as_fn_error $? "The path of MSVC_DLL, which resolves as \"$path\", is not found." "$LINENO" 5 55693 fi 55694 55695 if test -d "$path"; then 55696 MSVC_DLL="`cd "$path"; $THEPWDCMD -L`" 55697 else 55698 dir="`$DIRNAME "$path"`" 55699 base="`$BASENAME "$path"`" 55700 MSVC_DLL="`cd "$dir"; $THEPWDCMD -L`/$base" 55701 fi 55702 fi 55703 fi 55704 55705 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $DLL_NAME" >&5 55706 $as_echo_n "checking for $DLL_NAME... " >&6; } 55707 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MSVC_DLL" >&5 55708 $as_echo "$MSVC_DLL" >&6; } 55709 else 55710 { $as_echo "$as_me:${as_lineno-$LINENO}: result: incorrect, ignoring" >&5 55711 $as_echo "incorrect, ignoring" >&6; } 55712 { $as_echo "$as_me:${as_lineno-$LINENO}: The file type of the located $DLL_NAME is $MSVC_DLL_FILETYPE" >&5 55713 $as_echo "$as_me: The file type of the located $DLL_NAME is $MSVC_DLL_FILETYPE" >&6;} 55714 fi 55715 fi 55716 55717 fi 55718 fi 55719 55720 if test "x$MSVC_DLL" = x; then 55721 # Probe: Search wildly in the VCINSTALLDIR. We've probably lost by now. 55722 # (This was the original behaviour; kept since it might turn something up) 55723 if test "x$CYGWIN_VC_INSTALL_DIR" != x; then 55724 if test "x$OPENJDK_TARGET_CPU_BITS" = x64; then 55725 POSSIBLE_MSVC_DLL=`$FIND "$CYGWIN_VC_INSTALL_DIR" -name $DLL_NAME \ 55726 | $GREP x64 | $HEAD --lines 1` 55727 else 55728 POSSIBLE_MSVC_DLL=`$FIND "$CYGWIN_VC_INSTALL_DIR" -name $DLL_NAME \ 55729 | $GREP x86 | $GREP -v ia64 | $GREP -v x64 | $HEAD --lines 1` 55730 if test "x$POSSIBLE_MSVC_DLL" = x; then 55731 # We're grasping at straws now... 55732 POSSIBLE_MSVC_DLL=`$FIND "$CYGWIN_VC_INSTALL_DIR" -name $DLL_NAME \ 55733 | $HEAD --lines 1` 55734 fi 55735 fi 55736 55737 55738 DLL_NAME="$DLL_NAME" 55739 POSSIBLE_MSVC_DLL="$POSSIBLE_MSVC_DLL" 55740 METHOD="search of VCINSTALLDIR" 55741 if test -n "$POSSIBLE_MSVC_DLL" -a -e "$POSSIBLE_MSVC_DLL"; then 55742 { $as_echo "$as_me:${as_lineno-$LINENO}: Found $DLL_NAME at $POSSIBLE_MSVC_DLL using $METHOD" >&5 55743 $as_echo "$as_me: Found $DLL_NAME at $POSSIBLE_MSVC_DLL using $METHOD" >&6;} 55744 55745 # Need to check if the found msvcr is correct architecture 55746 { $as_echo "$as_me:${as_lineno-$LINENO}: checking found $DLL_NAME architecture" >&5 55747 $as_echo_n "checking found $DLL_NAME architecture... " >&6; } 55748 MSVC_DLL_FILETYPE=`$FILE -b "$POSSIBLE_MSVC_DLL"` 55749 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 55750 # The MSYS 'file' command returns "PE32 executable for MS Windows (DLL) (GUI) Intel 80386 32-bit" 55751 # on x32 and "PE32+ executable for MS Windows (DLL) (GUI) Mono/.Net assembly" on x64 systems. 55752 if test "x$OPENJDK_TARGET_CPU_BITS" = x32; then 55753 CORRECT_MSVCR_ARCH="PE32 executable" 55754 else 55755 CORRECT_MSVCR_ARCH="PE32+ executable" 55756 fi 55757 else 55758 if test "x$OPENJDK_TARGET_CPU_BITS" = x32; then 55759 CORRECT_MSVCR_ARCH=386 55760 else 55761 CORRECT_MSVCR_ARCH=x86-64 55762 fi 55763 fi 55764 if $ECHO "$MSVC_DLL_FILETYPE" | $GREP "$CORRECT_MSVCR_ARCH" 2>&1 > /dev/null; then 55765 { $as_echo "$as_me:${as_lineno-$LINENO}: result: ok" >&5 55766 $as_echo "ok" >&6; } 55767 MSVC_DLL="$POSSIBLE_MSVC_DLL" 55768 55769 # Only process if variable expands to non-empty 55770 55771 if test "x$MSVC_DLL" != x; then 55772 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 55773 55774 # Input might be given as Windows format, start by converting to 55775 # unix format. 55776 path="$MSVC_DLL" 55777 new_path=`$CYGPATH -u "$path"` 55778 55779 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 55780 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 55781 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 55782 # "foo.exe" is OK but "foo" is an error. 55783 # 55784 # This test is therefore slightly more accurate than "test -f" to check for file precense. 55785 # It is also a way to make sure we got the proper file name for the real test later on. 55786 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 55787 if test "x$test_shortpath" = x; then 55788 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of MSVC_DLL, which resolves as \"$path\", is invalid." >&5 55789 $as_echo "$as_me: The path of MSVC_DLL, which resolves as \"$path\", is invalid." >&6;} 55790 as_fn_error $? "Cannot locate the the path of MSVC_DLL" "$LINENO" 5 55791 fi 55792 55793 # Call helper function which possibly converts this using DOS-style short mode. 55794 # If so, the updated path is stored in $new_path. 55795 55796 input_path="$new_path" 55797 # Check if we need to convert this using DOS-style short mode. If the path 55798 # contains just simple characters, use it. Otherwise (spaces, weird characters), 55799 # take no chances and rewrite it. 55800 # Note: m4 eats our [], so we need to use [ and ] instead. 55801 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 55802 if test "x$has_forbidden_chars" != x; then 55803 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 55804 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 55805 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 55806 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 55807 # Going to short mode and back again did indeed matter. Since short mode is 55808 # case insensitive, let's make it lowercase to improve readability. 55809 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 55810 # Now convert it back to Unix-style (cygpath) 55811 input_path=`$CYGPATH -u "$shortmode_path"` 55812 new_path="$input_path" 55813 fi 55814 fi 55815 55816 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 55817 if test "x$test_cygdrive_prefix" = x; then 55818 # As a simple fix, exclude /usr/bin since it's not a real path. 55819 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 55820 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 55821 # a path prefixed by /cygdrive for fixpath to work. 55822 new_path="$CYGWIN_ROOT_PATH$input_path" 55823 fi 55824 fi 55825 55826 55827 if test "x$path" != "x$new_path"; then 55828 MSVC_DLL="$new_path" 55829 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting MSVC_DLL to \"$new_path\"" >&5 55830 $as_echo "$as_me: Rewriting MSVC_DLL to \"$new_path\"" >&6;} 55831 fi 55832 55833 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 55834 55835 path="$MSVC_DLL" 55836 has_colon=`$ECHO $path | $GREP ^.:` 55837 new_path="$path" 55838 if test "x$has_colon" = x; then 55839 # Not in mixed or Windows style, start by that. 55840 new_path=`cmd //c echo $path` 55841 fi 55842 55843 55844 input_path="$new_path" 55845 # Check if we need to convert this using DOS-style short mode. If the path 55846 # contains just simple characters, use it. Otherwise (spaces, weird characters), 55847 # take no chances and rewrite it. 55848 # Note: m4 eats our [], so we need to use [ and ] instead. 55849 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 55850 if test "x$has_forbidden_chars" != x; then 55851 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 55852 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 55853 fi 55854 55855 55856 windows_path="$new_path" 55857 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 55858 unix_path=`$CYGPATH -u "$windows_path"` 55859 new_path="$unix_path" 55860 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 55861 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 55862 new_path="$unix_path" 55863 fi 55864 55865 if test "x$path" != "x$new_path"; then 55866 MSVC_DLL="$new_path" 55867 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting MSVC_DLL to \"$new_path\"" >&5 55868 $as_echo "$as_me: Rewriting MSVC_DLL to \"$new_path\"" >&6;} 55869 fi 55870 55871 # Save the first 10 bytes of this path to the storage, so fixpath can work. 55872 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 55873 55874 else 55875 # We're on a unix platform. Hooray! :) 55876 path="$MSVC_DLL" 55877 has_space=`$ECHO "$path" | $GREP " "` 55878 if test "x$has_space" != x; then 55879 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of MSVC_DLL, which resolves as \"$path\", is invalid." >&5 55880 $as_echo "$as_me: The path of MSVC_DLL, which resolves as \"$path\", is invalid." >&6;} 55881 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 55882 fi 55883 55884 # Use eval to expand a potential ~ 55885 eval path="$path" 55886 if test ! -f "$path" && test ! -d "$path"; then 55887 as_fn_error $? "The path of MSVC_DLL, which resolves as \"$path\", is not found." "$LINENO" 5 55888 fi 55889 55890 if test -d "$path"; then 55891 MSVC_DLL="`cd "$path"; $THEPWDCMD -L`" 55892 else 55893 dir="`$DIRNAME "$path"`" 55894 base="`$BASENAME "$path"`" 55895 MSVC_DLL="`cd "$dir"; $THEPWDCMD -L`/$base" 55896 fi 55897 fi 55898 fi 55899 55900 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $DLL_NAME" >&5 55901 $as_echo_n "checking for $DLL_NAME... " >&6; } 55902 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MSVC_DLL" >&5 55903 $as_echo "$MSVC_DLL" >&6; } 55904 else 55905 { $as_echo "$as_me:${as_lineno-$LINENO}: result: incorrect, ignoring" >&5 55906 $as_echo "incorrect, ignoring" >&6; } 55907 { $as_echo "$as_me:${as_lineno-$LINENO}: The file type of the located $DLL_NAME is $MSVC_DLL_FILETYPE" >&5 55908 $as_echo "$as_me: The file type of the located $DLL_NAME is $MSVC_DLL_FILETYPE" >&6;} 55909 fi 55910 fi 55911 55912 fi 55913 fi 55914 55915 if test "x$MSVC_DLL" = x; then 55916 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $DLL_NAME" >&5 55917 $as_echo_n "checking for $DLL_NAME... " >&6; } 55918 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 55919 $as_echo "no" >&6; } 55920 as_fn_error $? "Could not find $DLL_NAME. Please specify using --with-msvcr-dll." "$LINENO" 5 55921 fi 55922 55923 MSVCP_DLL="$MSVC_DLL" 55924 fi 55925 55926 fi 55927 55928 fi 55929 55930 55931 if test "x$NEEDS_LIB_X11" = xfalse; then 55932 if (test "x${with_x}" != x && test "x${with_x}" != xno); then 55933 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: X11 is not used, so --with-x is ignored" >&5 55934 $as_echo "$as_me: WARNING: X11 is not used, so --with-x is ignored" >&2;} 55935 fi 55936 X_CFLAGS= 55937 X_LIBS= 55938 else 55939 55940 if test "x${with_x}" = xno; then 55941 as_fn_error $? "It is not possible to disable the use of X11. Remove the --without-x option." "$LINENO" 5 55942 fi 55943 55944 if test "x${with_x}" != x && test "x${with_x}" != xyes; then 55945 # The user has specified a X11 base directory. Use it for includes and 55946 # libraries, unless explicitely overridden. 55947 if test "x$x_includes" = xNONE; then 55948 x_includes="${with_x}/include" 55949 fi 55950 if test "x$x_libraries" = xNONE; then 55951 x_libraries="${with_x}/lib" 55952 fi 55953 else 55954 # Check if the user has specified sysroot, but not --with-x, --x-includes or --x-libraries. 55955 # Make a simple check for the libraries at the sysroot, and setup --x-includes and 55956 # --x-libraries for the sysroot, if that seems to be correct. 55957 if test "x$SYSROOT" != "x"; then 55958 if test "x$x_includes" = xNONE; then 55959 if test -f "$SYSROOT/usr/X11R6/include/X11/Xlib.h"; then 55960 x_includes="$SYSROOT/usr/X11R6/include" 55961 elif test -f "$SYSROOT/usr/include/X11/Xlib.h"; then 55962 x_includes="$SYSROOT/usr/include" 55963 fi 55964 fi 55965 if test "x$x_libraries" = xNONE; then 55966 if test -f "$SYSROOT/usr/X11R6/lib/libX11.so"; then 55967 x_libraries="$SYSROOT/usr/X11R6/lib" 55968 elif test -f "$SYSROOT/usr/lib64/libX11.so" && test "x$OPENJDK_TARGET_CPU_BITS" = x64; then 55969 x_libraries="$SYSROOT/usr/lib64" 55970 elif test -f "$SYSROOT/usr/lib/libX11.so"; then 55971 x_libraries="$SYSROOT/usr/lib" 55972 fi 55973 fi 55974 fi 55975 fi 55976 55977 # Now let autoconf do it's magic 55978 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for X" >&5 55979 $as_echo_n "checking for X... " >&6; } 55980 55981 55982 # Check whether --with-x was given. 55983 if test "${with_x+set}" = set; then : 55984 withval=$with_x; 55985 fi 55986 55987 # $have_x is `yes', `no', `disabled', or empty when we do not yet know. 55988 if test "x$with_x" = xno; then 55989 # The user explicitly disabled X. 55990 have_x=disabled 55991 else 55992 case $x_includes,$x_libraries in #( 55993 *\'*) as_fn_error $? "cannot use X directory names containing '" "$LINENO" 5;; #( 55994 *,NONE | NONE,*) if ${ac_cv_have_x+:} false; then : 55995 $as_echo_n "(cached) " >&6 55996 else 55997 # One or both of the vars are not set, and there is no cached value. 55998 ac_x_includes=no ac_x_libraries=no 55999 rm -f -r conftest.dir 56000 if mkdir conftest.dir; then 56001 cd conftest.dir 56002 cat >Imakefile <<'_ACEOF' 56003 incroot: 56004 @echo incroot='${INCROOT}' 56005 usrlibdir: 56006 @echo usrlibdir='${USRLIBDIR}' 56007 libdir: 56008 @echo libdir='${LIBDIR}' 56009 _ACEOF 56010 if (export CC; ${XMKMF-xmkmf}) >/dev/null 2>/dev/null && test -f Makefile; then 56011 # GNU make sometimes prints "make[1]: Entering ...", which would confuse us. 56012 for ac_var in incroot usrlibdir libdir; do 56013 eval "ac_im_$ac_var=\`\${MAKE-make} $ac_var 2>/dev/null | sed -n 's/^$ac_var=//p'\`" 56014 done 56015 # Open Windows xmkmf reportedly sets LIBDIR instead of USRLIBDIR. 56016 for ac_extension in a so sl dylib la dll; do 56017 if test ! -f "$ac_im_usrlibdir/libX11.$ac_extension" && 56018 test -f "$ac_im_libdir/libX11.$ac_extension"; then 56019 ac_im_usrlibdir=$ac_im_libdir; break 56020 fi 56021 done 56022 # Screen out bogus values from the imake configuration. They are 56023 # bogus both because they are the default anyway, and because 56024 # using them would break gcc on systems where it needs fixed includes. 56025 case $ac_im_incroot in 56026 /usr/include) ac_x_includes= ;; 56027 *) test -f "$ac_im_incroot/X11/Xos.h" && ac_x_includes=$ac_im_incroot;; 56028 esac 56029 case $ac_im_usrlibdir in 56030 /usr/lib | /usr/lib64 | /lib | /lib64) ;; 56031 *) test -d "$ac_im_usrlibdir" && ac_x_libraries=$ac_im_usrlibdir ;; 56032 esac 56033 fi 56034 cd .. 56035 rm -f -r conftest.dir 56036 fi 56037 56038 # Standard set of common directories for X headers. 56039 # Check X11 before X11Rn because it is often a symlink to the current release. 56040 ac_x_header_dirs=' 56041 /usr/X11/include 56042 /usr/X11R7/include 56043 /usr/X11R6/include 56044 /usr/X11R5/include 56045 /usr/X11R4/include 56046 56047 /usr/include/X11 56048 /usr/include/X11R7 56049 /usr/include/X11R6 56050 /usr/include/X11R5 56051 /usr/include/X11R4 56052 56053 /usr/local/X11/include 56054 /usr/local/X11R7/include 56055 /usr/local/X11R6/include 56056 /usr/local/X11R5/include 56057 /usr/local/X11R4/include 56058 56059 /usr/local/include/X11 56060 /usr/local/include/X11R7 56061 /usr/local/include/X11R6 56062 /usr/local/include/X11R5 56063 /usr/local/include/X11R4 56064 56065 /usr/X386/include 56066 /usr/x386/include 56067 /usr/XFree86/include/X11 56068 56069 /usr/include 56070 /usr/local/include 56071 /usr/unsupported/include 56072 /usr/athena/include 56073 /usr/local/x11r5/include 56074 /usr/lpp/Xamples/include 56075 56076 /usr/openwin/include 56077 /usr/openwin/share/include' 56078 56079 if test "$ac_x_includes" = no; then 56080 # Guess where to find include files, by looking for Xlib.h. 56081 # First, try using that file with no special directory specified. 56082 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 56083 /* end confdefs.h. */ 56084 #include <X11/Xlib.h> 56085 _ACEOF 56086 if ac_fn_cxx_try_cpp "$LINENO"; then : 56087 # We can compile using X headers with no special include directory. 56088 ac_x_includes= 56089 else 56090 for ac_dir in $ac_x_header_dirs; do 56091 if test -r "$ac_dir/X11/Xlib.h"; then 56092 ac_x_includes=$ac_dir 56093 break 56094 fi 56095 done 56096 fi 56097 rm -f conftest.err conftest.i conftest.$ac_ext 56098 fi # $ac_x_includes = no 56099 56100 if test "$ac_x_libraries" = no; then 56101 # Check for the libraries. 56102 # See if we find them without any special options. 56103 # Don't add to $LIBS permanently. 56104 ac_save_LIBS=$LIBS 56105 LIBS="-lX11 $LIBS" 56106 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 56107 /* end confdefs.h. */ 56108 #include <X11/Xlib.h> 56109 int 56110 main () 56111 { 56112 XrmInitialize () 56113 ; 56114 return 0; 56115 } 56116 _ACEOF 56117 if ac_fn_cxx_try_link "$LINENO"; then : 56118 LIBS=$ac_save_LIBS 56119 # We can link X programs with no special library path. 56120 ac_x_libraries= 56121 else 56122 LIBS=$ac_save_LIBS 56123 for ac_dir in `$as_echo "$ac_x_includes $ac_x_header_dirs" | sed s/include/lib/g` 56124 do 56125 # Don't even attempt the hair of trying to link an X program! 56126 for ac_extension in a so sl dylib la dll; do 56127 if test -r "$ac_dir/libX11.$ac_extension"; then 56128 ac_x_libraries=$ac_dir 56129 break 2 56130 fi 56131 done 56132 done 56133 fi 56134 rm -f core conftest.err conftest.$ac_objext \ 56135 conftest$ac_exeext conftest.$ac_ext 56136 fi # $ac_x_libraries = no 56137 56138 case $ac_x_includes,$ac_x_libraries in #( 56139 no,* | *,no | *\'*) 56140 # Didn't find X, or a directory has "'" in its name. 56141 ac_cv_have_x="have_x=no";; #( 56142 *) 56143 # Record where we found X for the cache. 56144 ac_cv_have_x="have_x=yes\ 56145 ac_x_includes='$ac_x_includes'\ 56146 ac_x_libraries='$ac_x_libraries'" 56147 esac 56148 fi 56149 ;; #( 56150 *) have_x=yes;; 56151 esac 56152 eval "$ac_cv_have_x" 56153 fi # $with_x != no 56154 56155 if test "$have_x" != yes; then 56156 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $have_x" >&5 56157 $as_echo "$have_x" >&6; } 56158 no_x=yes 56159 else 56160 # If each of the values was on the command line, it overrides each guess. 56161 test "x$x_includes" = xNONE && x_includes=$ac_x_includes 56162 test "x$x_libraries" = xNONE && x_libraries=$ac_x_libraries 56163 # Update the cache value to reflect the command line values. 56164 ac_cv_have_x="have_x=yes\ 56165 ac_x_includes='$x_includes'\ 56166 ac_x_libraries='$x_libraries'" 56167 { $as_echo "$as_me:${as_lineno-$LINENO}: result: libraries $x_libraries, headers $x_includes" >&5 56168 $as_echo "libraries $x_libraries, headers $x_includes" >&6; } 56169 fi 56170 56171 if test "$no_x" = yes; then 56172 # Not all programs may use this symbol, but it does not hurt to define it. 56173 56174 $as_echo "#define X_DISPLAY_MISSING 1" >>confdefs.h 56175 56176 X_CFLAGS= X_PRE_LIBS= X_LIBS= X_EXTRA_LIBS= 56177 else 56178 if test -n "$x_includes"; then 56179 X_CFLAGS="$X_CFLAGS -I$x_includes" 56180 fi 56181 56182 # It would also be nice to do this for all -L options, not just this one. 56183 if test -n "$x_libraries"; then 56184 X_LIBS="$X_LIBS -L$x_libraries" 56185 # For Solaris; some versions of Sun CC require a space after -R and 56186 # others require no space. Words are not sufficient . . . . 56187 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether -R must be followed by a space" >&5 56188 $as_echo_n "checking whether -R must be followed by a space... " >&6; } 56189 ac_xsave_LIBS=$LIBS; LIBS="$LIBS -R$x_libraries" 56190 ac_xsave_cxx_werror_flag=$ac_cxx_werror_flag 56191 ac_cxx_werror_flag=yes 56192 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 56193 /* end confdefs.h. */ 56194 56195 int 56196 main () 56197 { 56198 56199 ; 56200 return 0; 56201 } 56202 _ACEOF 56203 if ac_fn_cxx_try_link "$LINENO"; then : 56204 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 56205 $as_echo "no" >&6; } 56206 X_LIBS="$X_LIBS -R$x_libraries" 56207 else 56208 LIBS="$ac_xsave_LIBS -R $x_libraries" 56209 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 56210 /* end confdefs.h. */ 56211 56212 int 56213 main () 56214 { 56215 56216 ; 56217 return 0; 56218 } 56219 _ACEOF 56220 if ac_fn_cxx_try_link "$LINENO"; then : 56221 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 56222 $as_echo "yes" >&6; } 56223 X_LIBS="$X_LIBS -R $x_libraries" 56224 else 56225 { $as_echo "$as_me:${as_lineno-$LINENO}: result: neither works" >&5 56226 $as_echo "neither works" >&6; } 56227 fi 56228 rm -f core conftest.err conftest.$ac_objext \ 56229 conftest$ac_exeext conftest.$ac_ext 56230 fi 56231 rm -f core conftest.err conftest.$ac_objext \ 56232 conftest$ac_exeext conftest.$ac_ext 56233 ac_cxx_werror_flag=$ac_xsave_cxx_werror_flag 56234 LIBS=$ac_xsave_LIBS 56235 fi 56236 56237 # Check for system-dependent libraries X programs must link with. 56238 # Do this before checking for the system-independent R6 libraries 56239 # (-lICE), since we may need -lsocket or whatever for X linking. 56240 56241 if test "$ISC" = yes; then 56242 X_EXTRA_LIBS="$X_EXTRA_LIBS -lnsl_s -linet" 56243 else 56244 # Martyn Johnson says this is needed for Ultrix, if the X 56245 # libraries were built with DECnet support. And Karl Berry says 56246 # the Alpha needs dnet_stub (dnet does not exist). 56247 ac_xsave_LIBS="$LIBS"; LIBS="$LIBS $X_LIBS -lX11" 56248 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 56249 /* end confdefs.h. */ 56250 56251 /* Override any GCC internal prototype to avoid an error. 56252 Use char because int might match the return type of a GCC 56253 builtin and then its argument prototype would still apply. */ 56254 #ifdef __cplusplus 56255 extern "C" 56256 #endif 56257 char XOpenDisplay (); 56258 int 56259 main () 56260 { 56261 return XOpenDisplay (); 56262 ; 56263 return 0; 56264 } 56265 _ACEOF 56266 if ac_fn_cxx_try_link "$LINENO"; then : 56267 56268 else 56269 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for dnet_ntoa in -ldnet" >&5 56270 $as_echo_n "checking for dnet_ntoa in -ldnet... " >&6; } 56271 if ${ac_cv_lib_dnet_dnet_ntoa+:} false; then : 56272 $as_echo_n "(cached) " >&6 56273 else 56274 ac_check_lib_save_LIBS=$LIBS 56275 LIBS="-ldnet $LIBS" 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 dnet_ntoa (); 56286 int 56287 main () 56288 { 56289 return dnet_ntoa (); 56290 ; 56291 return 0; 56292 } 56293 _ACEOF 56294 if ac_fn_cxx_try_link "$LINENO"; then : 56295 ac_cv_lib_dnet_dnet_ntoa=yes 56296 else 56297 ac_cv_lib_dnet_dnet_ntoa=no 56298 fi 56299 rm -f core conftest.err conftest.$ac_objext \ 56300 conftest$ac_exeext conftest.$ac_ext 56301 LIBS=$ac_check_lib_save_LIBS 56302 fi 56303 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_dnet_dnet_ntoa" >&5 56304 $as_echo "$ac_cv_lib_dnet_dnet_ntoa" >&6; } 56305 if test "x$ac_cv_lib_dnet_dnet_ntoa" = xyes; then : 56306 X_EXTRA_LIBS="$X_EXTRA_LIBS -ldnet" 56307 fi 56308 56309 if test $ac_cv_lib_dnet_dnet_ntoa = no; then 56310 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for dnet_ntoa in -ldnet_stub" >&5 56311 $as_echo_n "checking for dnet_ntoa in -ldnet_stub... " >&6; } 56312 if ${ac_cv_lib_dnet_stub_dnet_ntoa+:} false; then : 56313 $as_echo_n "(cached) " >&6 56314 else 56315 ac_check_lib_save_LIBS=$LIBS 56316 LIBS="-ldnet_stub $LIBS" 56317 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 56318 /* end confdefs.h. */ 56319 56320 /* Override any GCC internal prototype to avoid an error. 56321 Use char because int might match the return type of a GCC 56322 builtin and then its argument prototype would still apply. */ 56323 #ifdef __cplusplus 56324 extern "C" 56325 #endif 56326 char dnet_ntoa (); 56327 int 56328 main () 56329 { 56330 return dnet_ntoa (); 56331 ; 56332 return 0; 56333 } 56334 _ACEOF 56335 if ac_fn_cxx_try_link "$LINENO"; then : 56336 ac_cv_lib_dnet_stub_dnet_ntoa=yes 56337 else 56338 ac_cv_lib_dnet_stub_dnet_ntoa=no 56339 fi 56340 rm -f core conftest.err conftest.$ac_objext \ 56341 conftest$ac_exeext conftest.$ac_ext 56342 LIBS=$ac_check_lib_save_LIBS 56343 fi 56344 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_dnet_stub_dnet_ntoa" >&5 56345 $as_echo "$ac_cv_lib_dnet_stub_dnet_ntoa" >&6; } 56346 if test "x$ac_cv_lib_dnet_stub_dnet_ntoa" = xyes; then : 56347 X_EXTRA_LIBS="$X_EXTRA_LIBS -ldnet_stub" 56348 fi 56349 56350 fi 56351 fi 56352 rm -f core conftest.err conftest.$ac_objext \ 56353 conftest$ac_exeext conftest.$ac_ext 56354 LIBS="$ac_xsave_LIBS" 56355 56356 # msh@cis.ufl.edu says -lnsl (and -lsocket) are needed for his 386/AT, 56357 # to get the SysV transport functions. 56358 # Chad R. Larson says the Pyramis MIS-ES running DC/OSx (SVR4) 56359 # needs -lnsl. 56360 # The nsl library prevents programs from opening the X display 56361 # on Irix 5.2, according to T.E. Dickey. 56362 # The functions gethostbyname, getservbyname, and inet_addr are 56363 # in -lbsd on LynxOS 3.0.1/i386, according to Lars Hecking. 56364 ac_fn_cxx_check_func "$LINENO" "gethostbyname" "ac_cv_func_gethostbyname" 56365 if test "x$ac_cv_func_gethostbyname" = xyes; then : 56366 56367 fi 56368 56369 if test $ac_cv_func_gethostbyname = no; then 56370 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for gethostbyname in -lnsl" >&5 56371 $as_echo_n "checking for gethostbyname in -lnsl... " >&6; } 56372 if ${ac_cv_lib_nsl_gethostbyname+:} false; then : 56373 $as_echo_n "(cached) " >&6 56374 else 56375 ac_check_lib_save_LIBS=$LIBS 56376 LIBS="-lnsl $LIBS" 56377 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 56378 /* end confdefs.h. */ 56379 56380 /* Override any GCC internal prototype to avoid an error. 56381 Use char because int might match the return type of a GCC 56382 builtin and then its argument prototype would still apply. */ 56383 #ifdef __cplusplus 56384 extern "C" 56385 #endif 56386 char gethostbyname (); 56387 int 56388 main () 56389 { 56390 return gethostbyname (); 56391 ; 56392 return 0; 56393 } 56394 _ACEOF 56395 if ac_fn_cxx_try_link "$LINENO"; then : 56396 ac_cv_lib_nsl_gethostbyname=yes 56397 else 56398 ac_cv_lib_nsl_gethostbyname=no 56399 fi 56400 rm -f core conftest.err conftest.$ac_objext \ 56401 conftest$ac_exeext conftest.$ac_ext 56402 LIBS=$ac_check_lib_save_LIBS 56403 fi 56404 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_nsl_gethostbyname" >&5 56405 $as_echo "$ac_cv_lib_nsl_gethostbyname" >&6; } 56406 if test "x$ac_cv_lib_nsl_gethostbyname" = xyes; then : 56407 X_EXTRA_LIBS="$X_EXTRA_LIBS -lnsl" 56408 fi 56409 56410 if test $ac_cv_lib_nsl_gethostbyname = no; then 56411 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for gethostbyname in -lbsd" >&5 56412 $as_echo_n "checking for gethostbyname in -lbsd... " >&6; } 56413 if ${ac_cv_lib_bsd_gethostbyname+:} false; then : 56414 $as_echo_n "(cached) " >&6 56415 else 56416 ac_check_lib_save_LIBS=$LIBS 56417 LIBS="-lbsd $LIBS" 56418 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 56419 /* end confdefs.h. */ 56420 56421 /* Override any GCC internal prototype to avoid an error. 56422 Use char because int might match the return type of a GCC 56423 builtin and then its argument prototype would still apply. */ 56424 #ifdef __cplusplus 56425 extern "C" 56426 #endif 56427 char gethostbyname (); 56428 int 56429 main () 56430 { 56431 return gethostbyname (); 56432 ; 56433 return 0; 56434 } 56435 _ACEOF 56436 if ac_fn_cxx_try_link "$LINENO"; then : 56437 ac_cv_lib_bsd_gethostbyname=yes 56438 else 56439 ac_cv_lib_bsd_gethostbyname=no 56440 fi 56441 rm -f core conftest.err conftest.$ac_objext \ 56442 conftest$ac_exeext conftest.$ac_ext 56443 LIBS=$ac_check_lib_save_LIBS 56444 fi 56445 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_bsd_gethostbyname" >&5 56446 $as_echo "$ac_cv_lib_bsd_gethostbyname" >&6; } 56447 if test "x$ac_cv_lib_bsd_gethostbyname" = xyes; then : 56448 X_EXTRA_LIBS="$X_EXTRA_LIBS -lbsd" 56449 fi 56450 56451 fi 56452 fi 56453 56454 # lieder@skyler.mavd.honeywell.com says without -lsocket, 56455 # socket/setsockopt and other routines are undefined under SCO ODT 56456 # 2.0. But -lsocket is broken on IRIX 5.2 (and is not necessary 56457 # on later versions), says Simon Leinen: it contains gethostby* 56458 # variants that don't use the name server (or something). -lsocket 56459 # must be given before -lnsl if both are needed. We assume that 56460 # if connect needs -lnsl, so does gethostbyname. 56461 ac_fn_cxx_check_func "$LINENO" "connect" "ac_cv_func_connect" 56462 if test "x$ac_cv_func_connect" = xyes; then : 56463 56464 fi 56465 56466 if test $ac_cv_func_connect = no; then 56467 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for connect in -lsocket" >&5 56468 $as_echo_n "checking for connect in -lsocket... " >&6; } 56469 if ${ac_cv_lib_socket_connect+:} false; then : 56470 $as_echo_n "(cached) " >&6 56471 else 56472 ac_check_lib_save_LIBS=$LIBS 56473 LIBS="-lsocket $X_EXTRA_LIBS $LIBS" 56474 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 56475 /* end confdefs.h. */ 56476 56477 /* Override any GCC internal prototype to avoid an error. 56478 Use char because int might match the return type of a GCC 56479 builtin and then its argument prototype would still apply. */ 56480 #ifdef __cplusplus 56481 extern "C" 56482 #endif 56483 char connect (); 56484 int 56485 main () 56486 { 56487 return connect (); 56488 ; 56489 return 0; 56490 } 56491 _ACEOF 56492 if ac_fn_cxx_try_link "$LINENO"; then : 56493 ac_cv_lib_socket_connect=yes 56494 else 56495 ac_cv_lib_socket_connect=no 56496 fi 56497 rm -f core conftest.err conftest.$ac_objext \ 56498 conftest$ac_exeext conftest.$ac_ext 56499 LIBS=$ac_check_lib_save_LIBS 56500 fi 56501 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_socket_connect" >&5 56502 $as_echo "$ac_cv_lib_socket_connect" >&6; } 56503 if test "x$ac_cv_lib_socket_connect" = xyes; then : 56504 X_EXTRA_LIBS="-lsocket $X_EXTRA_LIBS" 56505 fi 56506 56507 fi 56508 56509 # Guillermo Gomez says -lposix is necessary on A/UX. 56510 ac_fn_cxx_check_func "$LINENO" "remove" "ac_cv_func_remove" 56511 if test "x$ac_cv_func_remove" = xyes; then : 56512 56513 fi 56514 56515 if test $ac_cv_func_remove = no; then 56516 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for remove in -lposix" >&5 56517 $as_echo_n "checking for remove in -lposix... " >&6; } 56518 if ${ac_cv_lib_posix_remove+:} false; then : 56519 $as_echo_n "(cached) " >&6 56520 else 56521 ac_check_lib_save_LIBS=$LIBS 56522 LIBS="-lposix $LIBS" 56523 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 56524 /* end confdefs.h. */ 56525 56526 /* Override any GCC internal prototype to avoid an error. 56527 Use char because int might match the return type of a GCC 56528 builtin and then its argument prototype would still apply. */ 56529 #ifdef __cplusplus 56530 extern "C" 56531 #endif 56532 char remove (); 56533 int 56534 main () 56535 { 56536 return remove (); 56537 ; 56538 return 0; 56539 } 56540 _ACEOF 56541 if ac_fn_cxx_try_link "$LINENO"; then : 56542 ac_cv_lib_posix_remove=yes 56543 else 56544 ac_cv_lib_posix_remove=no 56545 fi 56546 rm -f core conftest.err conftest.$ac_objext \ 56547 conftest$ac_exeext conftest.$ac_ext 56548 LIBS=$ac_check_lib_save_LIBS 56549 fi 56550 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_posix_remove" >&5 56551 $as_echo "$ac_cv_lib_posix_remove" >&6; } 56552 if test "x$ac_cv_lib_posix_remove" = xyes; then : 56553 X_EXTRA_LIBS="$X_EXTRA_LIBS -lposix" 56554 fi 56555 56556 fi 56557 56558 # BSDI BSD/OS 2.1 needs -lipc for XOpenDisplay. 56559 ac_fn_cxx_check_func "$LINENO" "shmat" "ac_cv_func_shmat" 56560 if test "x$ac_cv_func_shmat" = xyes; then : 56561 56562 fi 56563 56564 if test $ac_cv_func_shmat = no; then 56565 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for shmat in -lipc" >&5 56566 $as_echo_n "checking for shmat in -lipc... " >&6; } 56567 if ${ac_cv_lib_ipc_shmat+:} false; then : 56568 $as_echo_n "(cached) " >&6 56569 else 56570 ac_check_lib_save_LIBS=$LIBS 56571 LIBS="-lipc $LIBS" 56572 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 56573 /* end confdefs.h. */ 56574 56575 /* Override any GCC internal prototype to avoid an error. 56576 Use char because int might match the return type of a GCC 56577 builtin and then its argument prototype would still apply. */ 56578 #ifdef __cplusplus 56579 extern "C" 56580 #endif 56581 char shmat (); 56582 int 56583 main () 56584 { 56585 return shmat (); 56586 ; 56587 return 0; 56588 } 56589 _ACEOF 56590 if ac_fn_cxx_try_link "$LINENO"; then : 56591 ac_cv_lib_ipc_shmat=yes 56592 else 56593 ac_cv_lib_ipc_shmat=no 56594 fi 56595 rm -f core conftest.err conftest.$ac_objext \ 56596 conftest$ac_exeext conftest.$ac_ext 56597 LIBS=$ac_check_lib_save_LIBS 56598 fi 56599 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_ipc_shmat" >&5 56600 $as_echo "$ac_cv_lib_ipc_shmat" >&6; } 56601 if test "x$ac_cv_lib_ipc_shmat" = xyes; then : 56602 X_EXTRA_LIBS="$X_EXTRA_LIBS -lipc" 56603 fi 56604 56605 fi 56606 fi 56607 56608 # Check for libraries that X11R6 Xt/Xaw programs need. 56609 ac_save_LDFLAGS=$LDFLAGS 56610 test -n "$x_libraries" && LDFLAGS="$LDFLAGS -L$x_libraries" 56611 # SM needs ICE to (dynamically) link under SunOS 4.x (so we have to 56612 # check for ICE first), but we must link in the order -lSM -lICE or 56613 # we get undefined symbols. So assume we have SM if we have ICE. 56614 # These have to be linked with before -lX11, unlike the other 56615 # libraries we check for below, so use a different variable. 56616 # John Interrante, Karl Berry 56617 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for IceConnectionNumber in -lICE" >&5 56618 $as_echo_n "checking for IceConnectionNumber in -lICE... " >&6; } 56619 if ${ac_cv_lib_ICE_IceConnectionNumber+:} false; then : 56620 $as_echo_n "(cached) " >&6 56621 else 56622 ac_check_lib_save_LIBS=$LIBS 56623 LIBS="-lICE $X_EXTRA_LIBS $LIBS" 56624 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 56625 /* end confdefs.h. */ 56626 56627 /* Override any GCC internal prototype to avoid an error. 56628 Use char because int might match the return type of a GCC 56629 builtin and then its argument prototype would still apply. */ 56630 #ifdef __cplusplus 56631 extern "C" 56632 #endif 56633 char IceConnectionNumber (); 56634 int 56635 main () 56636 { 56637 return IceConnectionNumber (); 56638 ; 56639 return 0; 56640 } 56641 _ACEOF 56642 if ac_fn_cxx_try_link "$LINENO"; then : 56643 ac_cv_lib_ICE_IceConnectionNumber=yes 56644 else 56645 ac_cv_lib_ICE_IceConnectionNumber=no 56646 fi 56647 rm -f core conftest.err conftest.$ac_objext \ 56648 conftest$ac_exeext conftest.$ac_ext 56649 LIBS=$ac_check_lib_save_LIBS 56650 fi 56651 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_ICE_IceConnectionNumber" >&5 56652 $as_echo "$ac_cv_lib_ICE_IceConnectionNumber" >&6; } 56653 if test "x$ac_cv_lib_ICE_IceConnectionNumber" = xyes; then : 56654 X_PRE_LIBS="$X_PRE_LIBS -lSM -lICE" 56655 fi 56656 56657 LDFLAGS=$ac_save_LDFLAGS 56658 56659 fi 56660 56661 56662 # AC_PATH_XTRA creates X_LIBS and sometimes adds -R flags. When cross compiling 56663 # this doesn't make sense so we remove it. 56664 if test "x$COMPILE_TYPE" = xcross; then 56665 X_LIBS=`$ECHO $X_LIBS | $SED 's/-R \{0,1\}[^ ]*//g'` 56666 fi 56667 56668 if test "x$no_x" = xyes; then 56669 56670 # Print a helpful message on how to acquire the necessary build dependency. 56671 # x11 is the help tag: freetype, cups, alsa etc 56672 MISSING_DEPENDENCY=x11 56673 56674 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 56675 cygwin_help $MISSING_DEPENDENCY 56676 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 56677 msys_help $MISSING_DEPENDENCY 56678 else 56679 PKGHANDLER_COMMAND= 56680 56681 case $PKGHANDLER in 56682 apt-get) 56683 apt_help $MISSING_DEPENDENCY ;; 56684 yum) 56685 yum_help $MISSING_DEPENDENCY ;; 56686 port) 56687 port_help $MISSING_DEPENDENCY ;; 56688 pkgutil) 56689 pkgutil_help $MISSING_DEPENDENCY ;; 56690 pkgadd) 56691 pkgadd_help $MISSING_DEPENDENCY ;; 56692 esac 56693 56694 if test "x$PKGHANDLER_COMMAND" != x; then 56695 HELP_MSG="You might be able to fix this by running '$PKGHANDLER_COMMAND'." 56696 fi 56697 fi 56698 56699 as_fn_error $? "Could not find X11 libraries. $HELP_MSG" "$LINENO" 5 56700 fi 56701 56702 if test "x$OPENJDK_TARGET_OS" = xsolaris; then 56703 OPENWIN_HOME="/usr/openwin" 56704 X_CFLAGS="-I$SYSROOT$OPENWIN_HOME/include -I$SYSROOT$OPENWIN_HOME/include/X11/extensions" 56705 X_LIBS="-L$SYSROOT$OPENWIN_HOME/lib$OPENJDK_TARGET_CPU_ISADIR \ 56706 -R$OPENWIN_HOME/lib$OPENJDK_TARGET_CPU_ISADIR" 56707 fi 56708 56709 ac_ext=c 56710 ac_cpp='$CPP $CPPFLAGS' 56711 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5' 56712 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' 56713 ac_compiler_gnu=$ac_cv_c_compiler_gnu 56714 56715 OLD_CFLAGS="$CFLAGS" 56716 CFLAGS="$CFLAGS $SYSROOT_CFLAGS $X_CFLAGS" 56717 56718 # Need to include Xlib.h and Xutil.h to avoid "present but cannot be compiled" warnings on Solaris 10 56719 for ac_header in X11/extensions/shape.h X11/extensions/Xrender.h X11/extensions/XTest.h X11/Intrinsic.h 56720 do : 56721 as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh` 56722 ac_fn_c_check_header_compile "$LINENO" "$ac_header" "$as_ac_Header" " 56723 # include <X11/Xlib.h> 56724 # include <X11/Xutil.h> 56725 56726 56727 " 56728 if eval test \"x\$"$as_ac_Header"\" = x"yes"; then : 56729 cat >>confdefs.h <<_ACEOF 56730 #define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1 56731 _ACEOF 56732 X11_HEADERS_OK=yes 56733 else 56734 X11_HEADERS_OK=no; break 56735 fi 56736 56737 done 56738 56739 56740 if test "x$X11_HEADERS_OK" = xno; then 56741 56742 # Print a helpful message on how to acquire the necessary build dependency. 56743 # x11 is the help tag: freetype, cups, alsa etc 56744 MISSING_DEPENDENCY=x11 56745 56746 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 56747 cygwin_help $MISSING_DEPENDENCY 56748 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 56749 msys_help $MISSING_DEPENDENCY 56750 else 56751 PKGHANDLER_COMMAND= 56752 56753 case $PKGHANDLER in 56754 apt-get) 56755 apt_help $MISSING_DEPENDENCY ;; 56756 yum) 56757 yum_help $MISSING_DEPENDENCY ;; 56758 port) 56759 port_help $MISSING_DEPENDENCY ;; 56760 pkgutil) 56761 pkgutil_help $MISSING_DEPENDENCY ;; 56762 pkgadd) 56763 pkgadd_help $MISSING_DEPENDENCY ;; 56764 esac 56765 56766 if test "x$PKGHANDLER_COMMAND" != x; then 56767 HELP_MSG="You might be able to fix this by running '$PKGHANDLER_COMMAND'." 56768 fi 56769 fi 56770 56771 as_fn_error $? "Could not find all X11 headers (shape.h Xrender.h XTest.h Intrinsic.h). $HELP_MSG" "$LINENO" 5 56772 fi 56773 56774 # If XLinearGradient isn't available in Xrender.h, signal that it needs to be 56775 # defined in libawt_xawt. 56776 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if XlinearGradient is defined in Xrender.h" >&5 56777 $as_echo_n "checking if XlinearGradient is defined in Xrender.h... " >&6; } 56778 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 56779 /* end confdefs.h. */ 56780 #include <X11/extensions/Xrender.h> 56781 int 56782 main () 56783 { 56784 XLinearGradient x; 56785 ; 56786 return 0; 56787 } 56788 _ACEOF 56789 if ac_fn_c_try_compile "$LINENO"; then : 56790 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 56791 $as_echo "yes" >&6; } 56792 else 56793 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 56794 $as_echo "no" >&6; } 56795 X_CFLAGS="$X_CFLAGS -DSOLARIS10_NO_XRENDER_STRUCTS" 56796 fi 56797 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext 56798 56799 CFLAGS="$OLD_CFLAGS" 56800 ac_ext=cpp 56801 ac_cpp='$CXXCPP $CPPFLAGS' 56802 ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5' 56803 ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' 56804 ac_compiler_gnu=$ac_cv_cxx_compiler_gnu 56805 56806 fi # NEEDS_LIB_X11 56807 56808 56809 56810 56811 56812 56813 # Check whether --with-cups was given. 56814 if test "${with_cups+set}" = set; then : 56815 withval=$with_cups; 56816 fi 56817 56818 56819 # Check whether --with-cups-include was given. 56820 if test "${with_cups_include+set}" = set; then : 56821 withval=$with_cups_include; 56822 fi 56823 56824 56825 if test "x$NEEDS_LIB_CUPS" = xfalse; then 56826 if (test "x${with_cups}" != x && test "x${with_cups}" != xno) || \ 56827 (test "x${with_cups_include}" != x && test "x${with_cups_include}" != xno); then 56828 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: cups not used, so --with-cups[-*] is ignored" >&5 56829 $as_echo "$as_me: WARNING: cups not used, so --with-cups[-*] is ignored" >&2;} 56830 fi 56831 CUPS_CFLAGS= 56832 else 56833 CUPS_FOUND=no 56834 56835 if test "x${with_cups}" = xno || test "x${with_cups_include}" = xno; then 56836 as_fn_error $? "It is not possible to disable the use of cups. Remove the --without-cups option." "$LINENO" 5 56837 fi 56838 56839 if test "x${with_cups}" != x; then 56840 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for cups headers" >&5 56841 $as_echo_n "checking for cups headers... " >&6; } 56842 if test -s "${with_cups}/include/cups/cups.h"; then 56843 CUPS_CFLAGS="-I${with_cups}/include" 56844 CUPS_FOUND=yes 56845 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CUPS_FOUND" >&5 56846 $as_echo "$CUPS_FOUND" >&6; } 56847 else 56848 as_fn_error $? "Can't find 'include/cups/cups.h' under ${with_cups} given with the --with-cups option." "$LINENO" 5 56849 fi 56850 fi 56851 if test "x${with_cups_include}" != x; then 56852 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for cups headers" >&5 56853 $as_echo_n "checking for cups headers... " >&6; } 56854 if test -s "${with_cups_include}/cups/cups.h"; then 56855 CUPS_CFLAGS="-I${with_cups_include}" 56856 CUPS_FOUND=yes 56857 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CUPS_FOUND" >&5 56858 $as_echo "$CUPS_FOUND" >&6; } 56859 else 56860 as_fn_error $? "Can't find 'cups/cups.h' under ${with_cups_include} given with the --with-cups-include option." "$LINENO" 5 56861 fi 56862 fi 56863 if test "x$CUPS_FOUND" = xno; then 56864 # Are the cups headers installed in the default /usr/include location? 56865 for ac_header in cups/cups.h cups/ppd.h 56866 do : 56867 as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh` 56868 ac_fn_cxx_check_header_mongrel "$LINENO" "$ac_header" "$as_ac_Header" "$ac_includes_default" 56869 if eval test \"x\$"$as_ac_Header"\" = x"yes"; then : 56870 cat >>confdefs.h <<_ACEOF 56871 #define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1 56872 _ACEOF 56873 56874 CUPS_FOUND=yes 56875 CUPS_CFLAGS= 56876 DEFAULT_CUPS=yes 56877 56878 fi 56879 56880 done 56881 56882 fi 56883 if test "x$CUPS_FOUND" = xno; then 56884 56885 # Print a helpful message on how to acquire the necessary build dependency. 56886 # cups is the help tag: freetype, cups, alsa etc 56887 MISSING_DEPENDENCY=cups 56888 56889 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 56890 cygwin_help $MISSING_DEPENDENCY 56891 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 56892 msys_help $MISSING_DEPENDENCY 56893 else 56894 PKGHANDLER_COMMAND= 56895 56896 case $PKGHANDLER in 56897 apt-get) 56898 apt_help $MISSING_DEPENDENCY ;; 56899 yum) 56900 yum_help $MISSING_DEPENDENCY ;; 56901 port) 56902 port_help $MISSING_DEPENDENCY ;; 56903 pkgutil) 56904 pkgutil_help $MISSING_DEPENDENCY ;; 56905 pkgadd) 56906 pkgadd_help $MISSING_DEPENDENCY ;; 56907 esac 56908 56909 if test "x$PKGHANDLER_COMMAND" != x; then 56910 HELP_MSG="You might be able to fix this by running '$PKGHANDLER_COMMAND'." 56911 fi 56912 fi 56913 56914 as_fn_error $? "Could not find cups! $HELP_MSG " "$LINENO" 5 56915 fi 56916 fi 56917 56918 56919 56920 56921 56922 # Check whether --with-freetype was given. 56923 if test "${with_freetype+set}" = set; then : 56924 withval=$with_freetype; 56925 fi 56926 56927 56928 # Check whether --with-freetype-include was given. 56929 if test "${with_freetype_include+set}" = set; then : 56930 withval=$with_freetype_include; 56931 fi 56932 56933 56934 # Check whether --with-freetype-lib was given. 56935 if test "${with_freetype_lib+set}" = set; then : 56936 withval=$with_freetype_lib; 56937 fi 56938 56939 56940 # Check whether --with-freetype-src was given. 56941 if test "${with_freetype_src+set}" = set; then : 56942 withval=$with_freetype_src; 56943 fi 56944 56945 # Check whether --enable-freetype-bundling was given. 56946 if test "${enable_freetype_bundling+set}" = set; then : 56947 enableval=$enable_freetype_bundling; 56948 fi 56949 56950 56951 # Need to specify explicitly since it needs to be overridden on some versions of macosx 56952 FREETYPE_BASE_NAME=freetype 56953 FREETYPE_CFLAGS= 56954 FREETYPE_LIBS= 56955 FREETYPE_BUNDLE_LIB_PATH= 56956 56957 if test "x$NEEDS_LIB_FREETYPE" = xfalse; then 56958 if (test "x$with_freetype" != x && test "x$with_freetype" != xno) || \ 56959 (test "x$with_freetype_include" != x && test "x$with_freetype_include" != xno) || \ 56960 (test "x$with_freetype_lib" != x && test "x$with_freetype_lib" != xno) || \ 56961 (test "x$with_freetype_src" != x && test "x$with_freetype_src" != xno); then 56962 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: freetype not used, so --with-freetype[-*] is ignored" >&5 56963 $as_echo "$as_me: WARNING: freetype not used, so --with-freetype[-*] is ignored" >&2;} 56964 fi 56965 if (test "x$enable_freetype_bundling" != x && test "x$enable_freetype_bundling" != xno); then 56966 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: freetype not used, so --enable-freetype-bundling is ignored" >&5 56967 $as_echo "$as_me: WARNING: freetype not used, so --enable-freetype-bundling is ignored" >&2;} 56968 fi 56969 else 56970 # freetype is needed to build; go get it! 56971 56972 BUNDLE_FREETYPE="$enable_freetype_bundling" 56973 56974 if test "x$with_freetype_src" != x; then 56975 if test "x$OPENJDK_TARGET_OS" = xwindows; then 56976 # Try to build freetype if --with-freetype-src was given on Windows 56977 56978 FREETYPE_SRC_PATH="$with_freetype_src" 56979 BUILD_FREETYPE=yes 56980 56981 # Check if the freetype sources are acessible.. 56982 if ! test -d $FREETYPE_SRC_PATH; then 56983 { $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 56984 $as_echo "$as_me: WARNING: --with-freetype-src specified, but can not find path \"$FREETYPE_SRC_PATH\" - ignoring --with-freetype-src" >&2;} 56985 BUILD_FREETYPE=no 56986 fi 56987 # ..and contain a vc2010 project file 56988 vcxproj_path="$FREETYPE_SRC_PATH/builds/windows/vc2010/freetype.vcxproj" 56989 if test "x$BUILD_FREETYPE" = xyes && ! test -s $vcxproj_path; then 56990 { $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 56991 $as_echo "$as_me: WARNING: Can not find project file $vcxproj_path (you may try a newer freetype version) - ignoring --with-freetype-src" >&2;} 56992 BUILD_FREETYPE=no 56993 fi 56994 # Now check if configure found a version of 'msbuild.exe' 56995 if test "x$BUILD_FREETYPE" = xyes && test "x$MSBUILD" == x ; then 56996 { $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 56997 $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;} 56998 BUILD_FREETYPE=no 56999 fi 57000 57001 # Ready to go.. 57002 if test "x$BUILD_FREETYPE" = xyes; then 57003 # msbuild requires trailing slashes for output directories 57004 freetype_lib_path="$FREETYPE_SRC_PATH/lib$OPENJDK_TARGET_CPU_BITS/" 57005 freetype_lib_path_unix="$freetype_lib_path" 57006 freetype_obj_path="$FREETYPE_SRC_PATH/obj$OPENJDK_TARGET_CPU_BITS/" 57007 57008 unix_path="$vcxproj_path" 57009 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 57010 windows_path=`$CYGPATH -m "$unix_path"` 57011 vcxproj_path="$windows_path" 57012 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 57013 windows_path=`cmd //c echo $unix_path` 57014 vcxproj_path="$windows_path" 57015 fi 57016 57017 57018 unix_path="$freetype_lib_path" 57019 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 57020 windows_path=`$CYGPATH -m "$unix_path"` 57021 freetype_lib_path="$windows_path" 57022 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 57023 windows_path=`cmd //c echo $unix_path` 57024 freetype_lib_path="$windows_path" 57025 fi 57026 57027 57028 unix_path="$freetype_obj_path" 57029 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 57030 windows_path=`$CYGPATH -m "$unix_path"` 57031 freetype_obj_path="$windows_path" 57032 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 57033 windows_path=`cmd //c echo $unix_path` 57034 freetype_obj_path="$windows_path" 57035 fi 57036 57037 if test "x$OPENJDK_TARGET_CPU_BITS" = x64; then 57038 freetype_platform=x64 57039 else 57040 freetype_platform=win32 57041 fi 57042 57043 # The original freetype project file is for VS 2010 (i.e. 'v100'), 57044 # so we have to adapt the toolset if building with any other toolsed (i.e. SDK). 57045 # Currently 'PLATFORM_TOOLSET' is set in 'TOOLCHAIN_CHECK_POSSIBLE_VISUAL_STUDIO_ROOT'/ 57046 # 'TOOLCHAIN_CHECK_POSSIBLE_WIN_SDK_ROOT' in toolchain_windows.m4 57047 { $as_echo "$as_me:${as_lineno-$LINENO}: Trying to compile freetype sources with PlatformToolset=$PLATFORM_TOOLSET to $freetype_lib_path_unix ..." >&5 57048 $as_echo "$as_me: Trying to compile freetype sources with PlatformToolset=$PLATFORM_TOOLSET to $freetype_lib_path_unix ..." >&6;} 57049 57050 # First we try to build the freetype.dll 57051 $ECHO -e "@echo off\n"\ 57052 "$MSBUILD $vcxproj_path "\ 57053 "/p:PlatformToolset=$PLATFORM_TOOLSET "\ 57054 "/p:Configuration=\"Release Multithreaded\" "\ 57055 "/p:Platform=$freetype_platform "\ 57056 "/p:ConfigurationType=DynamicLibrary "\ 57057 "/p:TargetName=freetype "\ 57058 "/p:OutDir=\"$freetype_lib_path\" "\ 57059 "/p:IntDir=\"$freetype_obj_path\" > freetype.log" > freetype.bat 57060 cmd /c freetype.bat 57061 57062 if test -s "$freetype_lib_path_unix/freetype.dll"; then 57063 # If that succeeds we also build freetype.lib 57064 $ECHO -e "@echo off\n"\ 57065 "$MSBUILD $vcxproj_path "\ 57066 "/p:PlatformToolset=$PLATFORM_TOOLSET "\ 57067 "/p:Configuration=\"Release Multithreaded\" "\ 57068 "/p:Platform=$freetype_platform "\ 57069 "/p:ConfigurationType=StaticLibrary "\ 57070 "/p:TargetName=freetype "\ 57071 "/p:OutDir=\"$freetype_lib_path\" "\ 57072 "/p:IntDir=\"$freetype_obj_path\" >> freetype.log" > freetype.bat 57073 cmd /c freetype.bat 57074 57075 if test -s "$freetype_lib_path_unix/freetype.lib"; then 57076 # Once we build both, lib and dll, set freetype lib and include path appropriately 57077 POTENTIAL_FREETYPE_INCLUDE_PATH="$FREETYPE_SRC_PATH/include" 57078 POTENTIAL_FREETYPE_LIB_PATH="$freetype_lib_path_unix" 57079 { $as_echo "$as_me:${as_lineno-$LINENO}: Compiling freetype sources succeeded! (see freetype.log for build results)" >&5 57080 $as_echo "$as_me: Compiling freetype sources succeeded! (see freetype.log for build results)" >&6;} 57081 else 57082 BUILD_FREETYPE=no 57083 fi 57084 else 57085 BUILD_FREETYPE=no 57086 fi 57087 fi 57088 57089 if test "x$BUILD_FREETYPE" = xyes; then 57090 # Okay, we built it. Check that it works. 57091 57092 POTENTIAL_FREETYPE_INCLUDE_PATH="$POTENTIAL_FREETYPE_INCLUDE_PATH" 57093 POTENTIAL_FREETYPE_LIB_PATH="$POTENTIAL_FREETYPE_LIB_PATH" 57094 METHOD="--with-freetype-src" 57095 57096 # Let's start with an optimistic view of the world :-) 57097 FOUND_FREETYPE=yes 57098 57099 # First look for the canonical freetype main include file ft2build.h. 57100 if ! test -s "$POTENTIAL_FREETYPE_INCLUDE_PATH/ft2build.h"; then 57101 # Oh no! Let's try in the freetype2 directory. This is needed at least at Mac OS X Yosemite. 57102 POTENTIAL_FREETYPE_INCLUDE_PATH="$POTENTIAL_FREETYPE_INCLUDE_PATH/freetype2" 57103 if ! test -s "$POTENTIAL_FREETYPE_INCLUDE_PATH/ft2build.h"; then 57104 # Fail. 57105 FOUND_FREETYPE=no 57106 fi 57107 fi 57108 57109 if test "x$FOUND_FREETYPE" = xyes; then 57110 # Include file found, let's continue the sanity check. 57111 { $as_echo "$as_me:${as_lineno-$LINENO}: Found freetype include files at $POTENTIAL_FREETYPE_INCLUDE_PATH using $METHOD" >&5 57112 $as_echo "$as_me: Found freetype include files at $POTENTIAL_FREETYPE_INCLUDE_PATH using $METHOD" >&6;} 57113 57114 # Reset to default value 57115 FREETYPE_BASE_NAME=freetype 57116 FREETYPE_LIB_NAME="${LIBRARY_PREFIX}${FREETYPE_BASE_NAME}${SHARED_LIBRARY_SUFFIX}" 57117 if ! test -s "$POTENTIAL_FREETYPE_LIB_PATH/$FREETYPE_LIB_NAME"; then 57118 if test "x$OPENJDK_TARGET_OS" = xmacosx \ 57119 && test -s "$POTENTIAL_FREETYPE_LIB_PATH/${LIBRARY_PREFIX}freetype.6${SHARED_LIBRARY_SUFFIX}"; then 57120 # On Mac OS X Yosemite, the symlink from libfreetype.dylib to libfreetype.6.dylib disappeared. Check 57121 # for the .6 version explicitly. 57122 FREETYPE_BASE_NAME=freetype.6 57123 FREETYPE_LIB_NAME="${LIBRARY_PREFIX}${FREETYPE_BASE_NAME}${SHARED_LIBRARY_SUFFIX}" 57124 { $as_echo "$as_me:${as_lineno-$LINENO}: Compensating for missing symlink by using version 6 explicitly" >&5 57125 $as_echo "$as_me: Compensating for missing symlink by using version 6 explicitly" >&6;} 57126 else 57127 { $as_echo "$as_me:${as_lineno-$LINENO}: Could not find $POTENTIAL_FREETYPE_LIB_PATH/$FREETYPE_LIB_NAME. Ignoring location." >&5 57128 $as_echo "$as_me: Could not find $POTENTIAL_FREETYPE_LIB_PATH/$FREETYPE_LIB_NAME. Ignoring location." >&6;} 57129 FOUND_FREETYPE=no 57130 fi 57131 else 57132 if test "x$OPENJDK_TARGET_OS" = xwindows; then 57133 # On Windows, we will need both .lib and .dll file. 57134 if ! test -s "$POTENTIAL_FREETYPE_LIB_PATH/${FREETYPE_BASE_NAME}.lib"; then 57135 { $as_echo "$as_me:${as_lineno-$LINENO}: Could not find $POTENTIAL_FREETYPE_LIB_PATH/${FREETYPE_BASE_NAME}.lib. Ignoring location." >&5 57136 $as_echo "$as_me: Could not find $POTENTIAL_FREETYPE_LIB_PATH/${FREETYPE_BASE_NAME}.lib. Ignoring location." >&6;} 57137 FOUND_FREETYPE=no 57138 fi 57139 elif test "x$OPENJDK_TARGET_OS" = xsolaris \ 57140 && test -s "$POTENTIAL_FREETYPE_LIB_PATH$OPENJDK_TARGET_CPU_ISADIR/$FREETYPE_LIB_NAME"; then 57141 # Found lib in isa dir, use that instead. 57142 POTENTIAL_FREETYPE_LIB_PATH="$POTENTIAL_FREETYPE_LIB_PATH$OPENJDK_TARGET_CPU_ISADIR" 57143 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting to use $POTENTIAL_FREETYPE_LIB_PATH instead" >&5 57144 $as_echo "$as_me: Rewriting to use $POTENTIAL_FREETYPE_LIB_PATH instead" >&6;} 57145 fi 57146 fi 57147 fi 57148 57149 if test "x$FOUND_FREETYPE" = xyes; then 57150 57151 # Only process if variable expands to non-empty 57152 57153 if test "x$POTENTIAL_FREETYPE_INCLUDE_PATH" != x; then 57154 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 57155 57156 # Input might be given as Windows format, start by converting to 57157 # unix format. 57158 path="$POTENTIAL_FREETYPE_INCLUDE_PATH" 57159 new_path=`$CYGPATH -u "$path"` 57160 57161 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 57162 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 57163 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 57164 # "foo.exe" is OK but "foo" is an error. 57165 # 57166 # This test is therefore slightly more accurate than "test -f" to check for file precense. 57167 # It is also a way to make sure we got the proper file name for the real test later on. 57168 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 57169 if test "x$test_shortpath" = x; then 57170 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&5 57171 $as_echo "$as_me: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&6;} 57172 as_fn_error $? "Cannot locate the the path of POTENTIAL_FREETYPE_INCLUDE_PATH" "$LINENO" 5 57173 fi 57174 57175 # Call helper function which possibly converts this using DOS-style short mode. 57176 # If so, the updated path is stored in $new_path. 57177 57178 input_path="$new_path" 57179 # Check if we need to convert this using DOS-style short mode. If the path 57180 # contains just simple characters, use it. Otherwise (spaces, weird characters), 57181 # take no chances and rewrite it. 57182 # Note: m4 eats our [], so we need to use [ and ] instead. 57183 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 57184 if test "x$has_forbidden_chars" != x; then 57185 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 57186 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 57187 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 57188 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 57189 # Going to short mode and back again did indeed matter. Since short mode is 57190 # case insensitive, let's make it lowercase to improve readability. 57191 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 57192 # Now convert it back to Unix-style (cygpath) 57193 input_path=`$CYGPATH -u "$shortmode_path"` 57194 new_path="$input_path" 57195 fi 57196 fi 57197 57198 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 57199 if test "x$test_cygdrive_prefix" = x; then 57200 # As a simple fix, exclude /usr/bin since it's not a real path. 57201 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 57202 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 57203 # a path prefixed by /cygdrive for fixpath to work. 57204 new_path="$CYGWIN_ROOT_PATH$input_path" 57205 fi 57206 fi 57207 57208 57209 if test "x$path" != "x$new_path"; then 57210 POTENTIAL_FREETYPE_INCLUDE_PATH="$new_path" 57211 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&5 57212 $as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&6;} 57213 fi 57214 57215 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 57216 57217 path="$POTENTIAL_FREETYPE_INCLUDE_PATH" 57218 has_colon=`$ECHO $path | $GREP ^.:` 57219 new_path="$path" 57220 if test "x$has_colon" = x; then 57221 # Not in mixed or Windows style, start by that. 57222 new_path=`cmd //c echo $path` 57223 fi 57224 57225 57226 input_path="$new_path" 57227 # Check if we need to convert this using DOS-style short mode. If the path 57228 # contains just simple characters, use it. Otherwise (spaces, weird characters), 57229 # take no chances and rewrite it. 57230 # Note: m4 eats our [], so we need to use [ and ] instead. 57231 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 57232 if test "x$has_forbidden_chars" != x; then 57233 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 57234 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 57235 fi 57236 57237 57238 windows_path="$new_path" 57239 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 57240 unix_path=`$CYGPATH -u "$windows_path"` 57241 new_path="$unix_path" 57242 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 57243 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 57244 new_path="$unix_path" 57245 fi 57246 57247 if test "x$path" != "x$new_path"; then 57248 POTENTIAL_FREETYPE_INCLUDE_PATH="$new_path" 57249 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&5 57250 $as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&6;} 57251 fi 57252 57253 # Save the first 10 bytes of this path to the storage, so fixpath can work. 57254 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 57255 57256 else 57257 # We're on a unix platform. Hooray! :) 57258 path="$POTENTIAL_FREETYPE_INCLUDE_PATH" 57259 has_space=`$ECHO "$path" | $GREP " "` 57260 if test "x$has_space" != x; then 57261 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&5 57262 $as_echo "$as_me: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&6;} 57263 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 57264 fi 57265 57266 # Use eval to expand a potential ~ 57267 eval path="$path" 57268 if test ! -f "$path" && test ! -d "$path"; then 57269 as_fn_error $? "The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is not found." "$LINENO" 5 57270 fi 57271 57272 if test -d "$path"; then 57273 POTENTIAL_FREETYPE_INCLUDE_PATH="`cd "$path"; $THEPWDCMD -L`" 57274 else 57275 dir="`$DIRNAME "$path"`" 57276 base="`$BASENAME "$path"`" 57277 POTENTIAL_FREETYPE_INCLUDE_PATH="`cd "$dir"; $THEPWDCMD -L`/$base" 57278 fi 57279 fi 57280 fi 57281 57282 57283 # Only process if variable expands to non-empty 57284 57285 if test "x$POTENTIAL_FREETYPE_LIB_PATH" != x; then 57286 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 57287 57288 # Input might be given as Windows format, start by converting to 57289 # unix format. 57290 path="$POTENTIAL_FREETYPE_LIB_PATH" 57291 new_path=`$CYGPATH -u "$path"` 57292 57293 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 57294 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 57295 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 57296 # "foo.exe" is OK but "foo" is an error. 57297 # 57298 # This test is therefore slightly more accurate than "test -f" to check for file precense. 57299 # It is also a way to make sure we got the proper file name for the real test later on. 57300 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 57301 if test "x$test_shortpath" = x; then 57302 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&5 57303 $as_echo "$as_me: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&6;} 57304 as_fn_error $? "Cannot locate the the path of POTENTIAL_FREETYPE_LIB_PATH" "$LINENO" 5 57305 fi 57306 57307 # Call helper function which possibly converts this using DOS-style short mode. 57308 # If so, the updated path is stored in $new_path. 57309 57310 input_path="$new_path" 57311 # Check if we need to convert this using DOS-style short mode. If the path 57312 # contains just simple characters, use it. Otherwise (spaces, weird characters), 57313 # take no chances and rewrite it. 57314 # Note: m4 eats our [], so we need to use [ and ] instead. 57315 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 57316 if test "x$has_forbidden_chars" != x; then 57317 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 57318 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 57319 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 57320 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 57321 # Going to short mode and back again did indeed matter. Since short mode is 57322 # case insensitive, let's make it lowercase to improve readability. 57323 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 57324 # Now convert it back to Unix-style (cygpath) 57325 input_path=`$CYGPATH -u "$shortmode_path"` 57326 new_path="$input_path" 57327 fi 57328 fi 57329 57330 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 57331 if test "x$test_cygdrive_prefix" = x; then 57332 # As a simple fix, exclude /usr/bin since it's not a real path. 57333 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 57334 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 57335 # a path prefixed by /cygdrive for fixpath to work. 57336 new_path="$CYGWIN_ROOT_PATH$input_path" 57337 fi 57338 fi 57339 57340 57341 if test "x$path" != "x$new_path"; then 57342 POTENTIAL_FREETYPE_LIB_PATH="$new_path" 57343 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&5 57344 $as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&6;} 57345 fi 57346 57347 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 57348 57349 path="$POTENTIAL_FREETYPE_LIB_PATH" 57350 has_colon=`$ECHO $path | $GREP ^.:` 57351 new_path="$path" 57352 if test "x$has_colon" = x; then 57353 # Not in mixed or Windows style, start by that. 57354 new_path=`cmd //c echo $path` 57355 fi 57356 57357 57358 input_path="$new_path" 57359 # Check if we need to convert this using DOS-style short mode. If the path 57360 # contains just simple characters, use it. Otherwise (spaces, weird characters), 57361 # take no chances and rewrite it. 57362 # Note: m4 eats our [], so we need to use [ and ] instead. 57363 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 57364 if test "x$has_forbidden_chars" != x; then 57365 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 57366 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 57367 fi 57368 57369 57370 windows_path="$new_path" 57371 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 57372 unix_path=`$CYGPATH -u "$windows_path"` 57373 new_path="$unix_path" 57374 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 57375 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 57376 new_path="$unix_path" 57377 fi 57378 57379 if test "x$path" != "x$new_path"; then 57380 POTENTIAL_FREETYPE_LIB_PATH="$new_path" 57381 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&5 57382 $as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&6;} 57383 fi 57384 57385 # Save the first 10 bytes of this path to the storage, so fixpath can work. 57386 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 57387 57388 else 57389 # We're on a unix platform. Hooray! :) 57390 path="$POTENTIAL_FREETYPE_LIB_PATH" 57391 has_space=`$ECHO "$path" | $GREP " "` 57392 if test "x$has_space" != x; then 57393 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&5 57394 $as_echo "$as_me: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&6;} 57395 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 57396 fi 57397 57398 # Use eval to expand a potential ~ 57399 eval path="$path" 57400 if test ! -f "$path" && test ! -d "$path"; then 57401 as_fn_error $? "The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is not found." "$LINENO" 5 57402 fi 57403 57404 if test -d "$path"; then 57405 POTENTIAL_FREETYPE_LIB_PATH="`cd "$path"; $THEPWDCMD -L`" 57406 else 57407 dir="`$DIRNAME "$path"`" 57408 base="`$BASENAME "$path"`" 57409 POTENTIAL_FREETYPE_LIB_PATH="`cd "$dir"; $THEPWDCMD -L`/$base" 57410 fi 57411 fi 57412 fi 57413 57414 57415 FREETYPE_INCLUDE_PATH="$POTENTIAL_FREETYPE_INCLUDE_PATH" 57416 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for freetype includes" >&5 57417 $as_echo_n "checking for freetype includes... " >&6; } 57418 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $FREETYPE_INCLUDE_PATH" >&5 57419 $as_echo "$FREETYPE_INCLUDE_PATH" >&6; } 57420 FREETYPE_LIB_PATH="$POTENTIAL_FREETYPE_LIB_PATH" 57421 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for freetype libraries" >&5 57422 $as_echo_n "checking for freetype libraries... " >&6; } 57423 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $FREETYPE_LIB_PATH" >&5 57424 $as_echo "$FREETYPE_LIB_PATH" >&6; } 57425 fi 57426 57427 if test "x$FOUND_FREETYPE" != xyes; then 57428 as_fn_error $? "Can not use the built freetype at location given by --with-freetype-src" "$LINENO" 5 57429 fi 57430 else 57431 { $as_echo "$as_me:${as_lineno-$LINENO}: User specified --with-freetype-src but building freetype failed. (see freetype.log for build results)" >&5 57432 $as_echo "$as_me: User specified --with-freetype-src but building freetype failed. (see freetype.log for build results)" >&6;} 57433 as_fn_error $? "Consider building freetype manually and using --with-freetype instead." "$LINENO" 5 57434 fi 57435 else 57436 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: --with-freetype-src is currently only supported on Windows - ignoring" >&5 57437 $as_echo "$as_me: WARNING: --with-freetype-src is currently only supported on Windows - ignoring" >&2;} 57438 fi 57439 fi 57440 57441 if test "x$with_freetype" != x || test "x$with_freetype_include" != x || test "x$with_freetype_lib" != x; then 57442 # User has specified settings 57443 57444 if test "x$BUNDLE_FREETYPE" = x; then 57445 # If not specified, default is to bundle freetype 57446 BUNDLE_FREETYPE=yes 57447 fi 57448 57449 if test "x$with_freetype" != x; then 57450 POTENTIAL_FREETYPE_INCLUDE_PATH="$with_freetype/include" 57451 POTENTIAL_FREETYPE_LIB_PATH="$with_freetype/lib" 57452 fi 57453 57454 # Allow --with-freetype-lib and --with-freetype-include to override 57455 if test "x$with_freetype_include" != x; then 57456 POTENTIAL_FREETYPE_INCLUDE_PATH="$with_freetype_include" 57457 fi 57458 if test "x$with_freetype_lib" != x; then 57459 POTENTIAL_FREETYPE_LIB_PATH="$with_freetype_lib" 57460 fi 57461 57462 if test "x$POTENTIAL_FREETYPE_INCLUDE_PATH" != x && test "x$POTENTIAL_FREETYPE_LIB_PATH" != x; then 57463 # Okay, we got it. Check that it works. 57464 57465 POTENTIAL_FREETYPE_INCLUDE_PATH="$POTENTIAL_FREETYPE_INCLUDE_PATH" 57466 POTENTIAL_FREETYPE_LIB_PATH="$POTENTIAL_FREETYPE_LIB_PATH" 57467 METHOD="--with-freetype" 57468 57469 # Let's start with an optimistic view of the world :-) 57470 FOUND_FREETYPE=yes 57471 57472 # First look for the canonical freetype main include file ft2build.h. 57473 if ! test -s "$POTENTIAL_FREETYPE_INCLUDE_PATH/ft2build.h"; then 57474 # Oh no! Let's try in the freetype2 directory. This is needed at least at Mac OS X Yosemite. 57475 POTENTIAL_FREETYPE_INCLUDE_PATH="$POTENTIAL_FREETYPE_INCLUDE_PATH/freetype2" 57476 if ! test -s "$POTENTIAL_FREETYPE_INCLUDE_PATH/ft2build.h"; then 57477 # Fail. 57478 FOUND_FREETYPE=no 57479 fi 57480 fi 57481 57482 if test "x$FOUND_FREETYPE" = xyes; then 57483 # Include file found, let's continue the sanity check. 57484 { $as_echo "$as_me:${as_lineno-$LINENO}: Found freetype include files at $POTENTIAL_FREETYPE_INCLUDE_PATH using $METHOD" >&5 57485 $as_echo "$as_me: Found freetype include files at $POTENTIAL_FREETYPE_INCLUDE_PATH using $METHOD" >&6;} 57486 57487 # Reset to default value 57488 FREETYPE_BASE_NAME=freetype 57489 FREETYPE_LIB_NAME="${LIBRARY_PREFIX}${FREETYPE_BASE_NAME}${SHARED_LIBRARY_SUFFIX}" 57490 if ! test -s "$POTENTIAL_FREETYPE_LIB_PATH/$FREETYPE_LIB_NAME"; then 57491 if test "x$OPENJDK_TARGET_OS" = xmacosx \ 57492 && test -s "$POTENTIAL_FREETYPE_LIB_PATH/${LIBRARY_PREFIX}freetype.6${SHARED_LIBRARY_SUFFIX}"; then 57493 # On Mac OS X Yosemite, the symlink from libfreetype.dylib to libfreetype.6.dylib disappeared. Check 57494 # for the .6 version explicitly. 57495 FREETYPE_BASE_NAME=freetype.6 57496 FREETYPE_LIB_NAME="${LIBRARY_PREFIX}${FREETYPE_BASE_NAME}${SHARED_LIBRARY_SUFFIX}" 57497 { $as_echo "$as_me:${as_lineno-$LINENO}: Compensating for missing symlink by using version 6 explicitly" >&5 57498 $as_echo "$as_me: Compensating for missing symlink by using version 6 explicitly" >&6;} 57499 else 57500 { $as_echo "$as_me:${as_lineno-$LINENO}: Could not find $POTENTIAL_FREETYPE_LIB_PATH/$FREETYPE_LIB_NAME. Ignoring location." >&5 57501 $as_echo "$as_me: Could not find $POTENTIAL_FREETYPE_LIB_PATH/$FREETYPE_LIB_NAME. Ignoring location." >&6;} 57502 FOUND_FREETYPE=no 57503 fi 57504 else 57505 if test "x$OPENJDK_TARGET_OS" = xwindows; then 57506 # On Windows, we will need both .lib and .dll file. 57507 if ! test -s "$POTENTIAL_FREETYPE_LIB_PATH/${FREETYPE_BASE_NAME}.lib"; then 57508 { $as_echo "$as_me:${as_lineno-$LINENO}: Could not find $POTENTIAL_FREETYPE_LIB_PATH/${FREETYPE_BASE_NAME}.lib. Ignoring location." >&5 57509 $as_echo "$as_me: Could not find $POTENTIAL_FREETYPE_LIB_PATH/${FREETYPE_BASE_NAME}.lib. Ignoring location." >&6;} 57510 FOUND_FREETYPE=no 57511 fi 57512 elif test "x$OPENJDK_TARGET_OS" = xsolaris \ 57513 && test -s "$POTENTIAL_FREETYPE_LIB_PATH$OPENJDK_TARGET_CPU_ISADIR/$FREETYPE_LIB_NAME"; then 57514 # Found lib in isa dir, use that instead. 57515 POTENTIAL_FREETYPE_LIB_PATH="$POTENTIAL_FREETYPE_LIB_PATH$OPENJDK_TARGET_CPU_ISADIR" 57516 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting to use $POTENTIAL_FREETYPE_LIB_PATH instead" >&5 57517 $as_echo "$as_me: Rewriting to use $POTENTIAL_FREETYPE_LIB_PATH instead" >&6;} 57518 fi 57519 fi 57520 fi 57521 57522 if test "x$FOUND_FREETYPE" = xyes; then 57523 57524 # Only process if variable expands to non-empty 57525 57526 if test "x$POTENTIAL_FREETYPE_INCLUDE_PATH" != x; then 57527 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 57528 57529 # Input might be given as Windows format, start by converting to 57530 # unix format. 57531 path="$POTENTIAL_FREETYPE_INCLUDE_PATH" 57532 new_path=`$CYGPATH -u "$path"` 57533 57534 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 57535 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 57536 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 57537 # "foo.exe" is OK but "foo" is an error. 57538 # 57539 # This test is therefore slightly more accurate than "test -f" to check for file precense. 57540 # It is also a way to make sure we got the proper file name for the real test later on. 57541 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 57542 if test "x$test_shortpath" = x; then 57543 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&5 57544 $as_echo "$as_me: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&6;} 57545 as_fn_error $? "Cannot locate the the path of POTENTIAL_FREETYPE_INCLUDE_PATH" "$LINENO" 5 57546 fi 57547 57548 # Call helper function which possibly converts this using DOS-style short mode. 57549 # If so, the updated path is stored in $new_path. 57550 57551 input_path="$new_path" 57552 # Check if we need to convert this using DOS-style short mode. If the path 57553 # contains just simple characters, use it. Otherwise (spaces, weird characters), 57554 # take no chances and rewrite it. 57555 # Note: m4 eats our [], so we need to use [ and ] instead. 57556 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 57557 if test "x$has_forbidden_chars" != x; then 57558 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 57559 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 57560 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 57561 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 57562 # Going to short mode and back again did indeed matter. Since short mode is 57563 # case insensitive, let's make it lowercase to improve readability. 57564 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 57565 # Now convert it back to Unix-style (cygpath) 57566 input_path=`$CYGPATH -u "$shortmode_path"` 57567 new_path="$input_path" 57568 fi 57569 fi 57570 57571 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 57572 if test "x$test_cygdrive_prefix" = x; then 57573 # As a simple fix, exclude /usr/bin since it's not a real path. 57574 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 57575 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 57576 # a path prefixed by /cygdrive for fixpath to work. 57577 new_path="$CYGWIN_ROOT_PATH$input_path" 57578 fi 57579 fi 57580 57581 57582 if test "x$path" != "x$new_path"; then 57583 POTENTIAL_FREETYPE_INCLUDE_PATH="$new_path" 57584 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&5 57585 $as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&6;} 57586 fi 57587 57588 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 57589 57590 path="$POTENTIAL_FREETYPE_INCLUDE_PATH" 57591 has_colon=`$ECHO $path | $GREP ^.:` 57592 new_path="$path" 57593 if test "x$has_colon" = x; then 57594 # Not in mixed or Windows style, start by that. 57595 new_path=`cmd //c echo $path` 57596 fi 57597 57598 57599 input_path="$new_path" 57600 # Check if we need to convert this using DOS-style short mode. If the path 57601 # contains just simple characters, use it. Otherwise (spaces, weird characters), 57602 # take no chances and rewrite it. 57603 # Note: m4 eats our [], so we need to use [ and ] instead. 57604 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 57605 if test "x$has_forbidden_chars" != x; then 57606 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 57607 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 57608 fi 57609 57610 57611 windows_path="$new_path" 57612 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 57613 unix_path=`$CYGPATH -u "$windows_path"` 57614 new_path="$unix_path" 57615 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 57616 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 57617 new_path="$unix_path" 57618 fi 57619 57620 if test "x$path" != "x$new_path"; then 57621 POTENTIAL_FREETYPE_INCLUDE_PATH="$new_path" 57622 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&5 57623 $as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&6;} 57624 fi 57625 57626 # Save the first 10 bytes of this path to the storage, so fixpath can work. 57627 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 57628 57629 else 57630 # We're on a unix platform. Hooray! :) 57631 path="$POTENTIAL_FREETYPE_INCLUDE_PATH" 57632 has_space=`$ECHO "$path" | $GREP " "` 57633 if test "x$has_space" != x; then 57634 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&5 57635 $as_echo "$as_me: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&6;} 57636 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 57637 fi 57638 57639 # Use eval to expand a potential ~ 57640 eval path="$path" 57641 if test ! -f "$path" && test ! -d "$path"; then 57642 as_fn_error $? "The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is not found." "$LINENO" 5 57643 fi 57644 57645 if test -d "$path"; then 57646 POTENTIAL_FREETYPE_INCLUDE_PATH="`cd "$path"; $THEPWDCMD -L`" 57647 else 57648 dir="`$DIRNAME "$path"`" 57649 base="`$BASENAME "$path"`" 57650 POTENTIAL_FREETYPE_INCLUDE_PATH="`cd "$dir"; $THEPWDCMD -L`/$base" 57651 fi 57652 fi 57653 fi 57654 57655 57656 # Only process if variable expands to non-empty 57657 57658 if test "x$POTENTIAL_FREETYPE_LIB_PATH" != x; then 57659 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 57660 57661 # Input might be given as Windows format, start by converting to 57662 # unix format. 57663 path="$POTENTIAL_FREETYPE_LIB_PATH" 57664 new_path=`$CYGPATH -u "$path"` 57665 57666 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 57667 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 57668 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 57669 # "foo.exe" is OK but "foo" is an error. 57670 # 57671 # This test is therefore slightly more accurate than "test -f" to check for file precense. 57672 # It is also a way to make sure we got the proper file name for the real test later on. 57673 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 57674 if test "x$test_shortpath" = x; then 57675 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&5 57676 $as_echo "$as_me: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&6;} 57677 as_fn_error $? "Cannot locate the the path of POTENTIAL_FREETYPE_LIB_PATH" "$LINENO" 5 57678 fi 57679 57680 # Call helper function which possibly converts this using DOS-style short mode. 57681 # If so, the updated path is stored in $new_path. 57682 57683 input_path="$new_path" 57684 # Check if we need to convert this using DOS-style short mode. If the path 57685 # contains just simple characters, use it. Otherwise (spaces, weird characters), 57686 # take no chances and rewrite it. 57687 # Note: m4 eats our [], so we need to use [ and ] instead. 57688 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 57689 if test "x$has_forbidden_chars" != x; then 57690 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 57691 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 57692 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 57693 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 57694 # Going to short mode and back again did indeed matter. Since short mode is 57695 # case insensitive, let's make it lowercase to improve readability. 57696 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 57697 # Now convert it back to Unix-style (cygpath) 57698 input_path=`$CYGPATH -u "$shortmode_path"` 57699 new_path="$input_path" 57700 fi 57701 fi 57702 57703 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 57704 if test "x$test_cygdrive_prefix" = x; then 57705 # As a simple fix, exclude /usr/bin since it's not a real path. 57706 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 57707 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 57708 # a path prefixed by /cygdrive for fixpath to work. 57709 new_path="$CYGWIN_ROOT_PATH$input_path" 57710 fi 57711 fi 57712 57713 57714 if test "x$path" != "x$new_path"; then 57715 POTENTIAL_FREETYPE_LIB_PATH="$new_path" 57716 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&5 57717 $as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&6;} 57718 fi 57719 57720 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 57721 57722 path="$POTENTIAL_FREETYPE_LIB_PATH" 57723 has_colon=`$ECHO $path | $GREP ^.:` 57724 new_path="$path" 57725 if test "x$has_colon" = x; then 57726 # Not in mixed or Windows style, start by that. 57727 new_path=`cmd //c echo $path` 57728 fi 57729 57730 57731 input_path="$new_path" 57732 # Check if we need to convert this using DOS-style short mode. If the path 57733 # contains just simple characters, use it. Otherwise (spaces, weird characters), 57734 # take no chances and rewrite it. 57735 # Note: m4 eats our [], so we need to use [ and ] instead. 57736 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 57737 if test "x$has_forbidden_chars" != x; then 57738 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 57739 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 57740 fi 57741 57742 57743 windows_path="$new_path" 57744 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 57745 unix_path=`$CYGPATH -u "$windows_path"` 57746 new_path="$unix_path" 57747 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 57748 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 57749 new_path="$unix_path" 57750 fi 57751 57752 if test "x$path" != "x$new_path"; then 57753 POTENTIAL_FREETYPE_LIB_PATH="$new_path" 57754 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&5 57755 $as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&6;} 57756 fi 57757 57758 # Save the first 10 bytes of this path to the storage, so fixpath can work. 57759 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 57760 57761 else 57762 # We're on a unix platform. Hooray! :) 57763 path="$POTENTIAL_FREETYPE_LIB_PATH" 57764 has_space=`$ECHO "$path" | $GREP " "` 57765 if test "x$has_space" != x; then 57766 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&5 57767 $as_echo "$as_me: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&6;} 57768 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 57769 fi 57770 57771 # Use eval to expand a potential ~ 57772 eval path="$path" 57773 if test ! -f "$path" && test ! -d "$path"; then 57774 as_fn_error $? "The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is not found." "$LINENO" 5 57775 fi 57776 57777 if test -d "$path"; then 57778 POTENTIAL_FREETYPE_LIB_PATH="`cd "$path"; $THEPWDCMD -L`" 57779 else 57780 dir="`$DIRNAME "$path"`" 57781 base="`$BASENAME "$path"`" 57782 POTENTIAL_FREETYPE_LIB_PATH="`cd "$dir"; $THEPWDCMD -L`/$base" 57783 fi 57784 fi 57785 fi 57786 57787 57788 FREETYPE_INCLUDE_PATH="$POTENTIAL_FREETYPE_INCLUDE_PATH" 57789 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for freetype includes" >&5 57790 $as_echo_n "checking for freetype includes... " >&6; } 57791 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $FREETYPE_INCLUDE_PATH" >&5 57792 $as_echo "$FREETYPE_INCLUDE_PATH" >&6; } 57793 FREETYPE_LIB_PATH="$POTENTIAL_FREETYPE_LIB_PATH" 57794 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for freetype libraries" >&5 57795 $as_echo_n "checking for freetype libraries... " >&6; } 57796 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $FREETYPE_LIB_PATH" >&5 57797 $as_echo "$FREETYPE_LIB_PATH" >&6; } 57798 fi 57799 57800 if test "x$FOUND_FREETYPE" != xyes; then 57801 as_fn_error $? "Can not find or use freetype at location given by --with-freetype" "$LINENO" 5 57802 fi 57803 else 57804 # User specified only one of lib or include. This is an error. 57805 if test "x$POTENTIAL_FREETYPE_INCLUDE_PATH" = x ; then 57806 { $as_echo "$as_me:${as_lineno-$LINENO}: User specified --with-freetype-lib but not --with-freetype-include" >&5 57807 $as_echo "$as_me: User specified --with-freetype-lib but not --with-freetype-include" >&6;} 57808 as_fn_error $? "Need both freetype lib and include paths. Consider using --with-freetype instead." "$LINENO" 5 57809 else 57810 { $as_echo "$as_me:${as_lineno-$LINENO}: User specified --with-freetype-include but not --with-freetype-lib" >&5 57811 $as_echo "$as_me: User specified --with-freetype-include but not --with-freetype-lib" >&6;} 57812 as_fn_error $? "Need both freetype lib and include paths. Consider using --with-freetype instead." "$LINENO" 5 57813 fi 57814 fi 57815 else 57816 # User did not specify settings, but we need freetype. Try to locate it. 57817 57818 if test "x$BUNDLE_FREETYPE" = x; then 57819 # If not specified, default is to bundle freetype only on windows 57820 if test "x$OPENJDK_TARGET_OS" = xwindows; then 57821 BUNDLE_FREETYPE=yes 57822 else 57823 BUNDLE_FREETYPE=no 57824 fi 57825 fi 57826 57827 # If we have a sysroot, assume that's where we are supposed to look and skip pkg-config. 57828 if test "x$SYSROOT" = x; then 57829 if test "x$FOUND_FREETYPE" != xyes; then 57830 # Check modules using pkg-config, but only if we have it (ugly output results otherwise) 57831 if test "x$PKG_CONFIG" != x; then 57832 57833 pkg_failed=no 57834 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for FREETYPE" >&5 57835 $as_echo_n "checking for FREETYPE... " >&6; } 57836 57837 if test -n "$FREETYPE_CFLAGS"; then 57838 pkg_cv_FREETYPE_CFLAGS="$FREETYPE_CFLAGS" 57839 elif test -n "$PKG_CONFIG"; then 57840 if test -n "$PKG_CONFIG" && \ 57841 { { $as_echo "$as_me:${as_lineno-$LINENO}: \$PKG_CONFIG --exists --print-errors \"freetype2\""; } >&5 57842 ($PKG_CONFIG --exists --print-errors "freetype2") 2>&5 57843 ac_status=$? 57844 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 57845 test $ac_status = 0; }; then 57846 pkg_cv_FREETYPE_CFLAGS=`$PKG_CONFIG --cflags "freetype2" 2>/dev/null` 57847 else 57848 pkg_failed=yes 57849 fi 57850 else 57851 pkg_failed=untried 57852 fi 57853 if test -n "$FREETYPE_LIBS"; then 57854 pkg_cv_FREETYPE_LIBS="$FREETYPE_LIBS" 57855 elif test -n "$PKG_CONFIG"; then 57856 if test -n "$PKG_CONFIG" && \ 57857 { { $as_echo "$as_me:${as_lineno-$LINENO}: \$PKG_CONFIG --exists --print-errors \"freetype2\""; } >&5 57858 ($PKG_CONFIG --exists --print-errors "freetype2") 2>&5 57859 ac_status=$? 57860 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 57861 test $ac_status = 0; }; then 57862 pkg_cv_FREETYPE_LIBS=`$PKG_CONFIG --libs "freetype2" 2>/dev/null` 57863 else 57864 pkg_failed=yes 57865 fi 57866 else 57867 pkg_failed=untried 57868 fi 57869 57870 57871 57872 if test $pkg_failed = yes; then 57873 57874 if $PKG_CONFIG --atleast-pkgconfig-version 0.20; then 57875 _pkg_short_errors_supported=yes 57876 else 57877 _pkg_short_errors_supported=no 57878 fi 57879 if test $_pkg_short_errors_supported = yes; then 57880 FREETYPE_PKG_ERRORS=`$PKG_CONFIG --short-errors --print-errors "freetype2" 2>&1` 57881 else 57882 FREETYPE_PKG_ERRORS=`$PKG_CONFIG --print-errors "freetype2" 2>&1` 57883 fi 57884 # Put the nasty error message in config.log where it belongs 57885 echo "$FREETYPE_PKG_ERRORS" >&5 57886 57887 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 57888 $as_echo "no" >&6; } 57889 FOUND_FREETYPE=no 57890 elif test $pkg_failed = untried; then 57891 FOUND_FREETYPE=no 57892 else 57893 FREETYPE_CFLAGS=$pkg_cv_FREETYPE_CFLAGS 57894 FREETYPE_LIBS=$pkg_cv_FREETYPE_LIBS 57895 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 57896 $as_echo "yes" >&6; } 57897 FOUND_FREETYPE=yes 57898 fi 57899 if test "x$FOUND_FREETYPE" = xyes; then 57900 # On solaris, pkg_check adds -lz to freetype libs, which isn't necessary for us. 57901 FREETYPE_LIBS=`$ECHO $FREETYPE_LIBS | $SED 's/-lz//g'` 57902 # 64-bit libs for Solaris x86 are installed in the amd64 subdirectory, change lib to lib/amd64 57903 if test "x$OPENJDK_TARGET_OS" = xsolaris && test "x$OPENJDK_TARGET_CPU" = xx86_64; then 57904 FREETYPE_LIBS=`$ECHO $FREETYPE_LIBS | $SED 's?/lib?/lib/amd64?g'` 57905 fi 57906 # PKG_CHECK_MODULES will set FREETYPE_CFLAGS and _LIBS, but we don't get a lib path for bundling. 57907 if test "x$BUNDLE_FREETYPE" = xyes; then 57908 { $as_echo "$as_me:${as_lineno-$LINENO}: Found freetype using pkg-config, but ignoring since we can not bundle that" >&5 57909 $as_echo "$as_me: Found freetype using pkg-config, but ignoring since we can not bundle that" >&6;} 57910 FOUND_FREETYPE=no 57911 else 57912 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for freetype" >&5 57913 $as_echo_n "checking for freetype... " >&6; } 57914 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes (using pkg-config)" >&5 57915 $as_echo "yes (using pkg-config)" >&6; } 57916 fi 57917 fi 57918 fi 57919 fi 57920 fi 57921 57922 if test "x$FOUND_FREETYPE" != xyes; then 57923 # Check in well-known locations 57924 if test "x$OPENJDK_TARGET_OS" = xwindows; then 57925 FREETYPE_BASE_DIR="$PROGRAMFILES/GnuWin32" 57926 57927 windows_path="$FREETYPE_BASE_DIR" 57928 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 57929 unix_path=`$CYGPATH -u "$windows_path"` 57930 FREETYPE_BASE_DIR="$unix_path" 57931 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 57932 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 57933 FREETYPE_BASE_DIR="$unix_path" 57934 fi 57935 57936 57937 POTENTIAL_FREETYPE_INCLUDE_PATH="$FREETYPE_BASE_DIR/include" 57938 POTENTIAL_FREETYPE_LIB_PATH="$FREETYPE_BASE_DIR/lib" 57939 METHOD="well-known location" 57940 57941 # Let's start with an optimistic view of the world :-) 57942 FOUND_FREETYPE=yes 57943 57944 # First look for the canonical freetype main include file ft2build.h. 57945 if ! test -s "$POTENTIAL_FREETYPE_INCLUDE_PATH/ft2build.h"; then 57946 # Oh no! Let's try in the freetype2 directory. This is needed at least at Mac OS X Yosemite. 57947 POTENTIAL_FREETYPE_INCLUDE_PATH="$POTENTIAL_FREETYPE_INCLUDE_PATH/freetype2" 57948 if ! test -s "$POTENTIAL_FREETYPE_INCLUDE_PATH/ft2build.h"; then 57949 # Fail. 57950 FOUND_FREETYPE=no 57951 fi 57952 fi 57953 57954 if test "x$FOUND_FREETYPE" = xyes; then 57955 # Include file found, let's continue the sanity check. 57956 { $as_echo "$as_me:${as_lineno-$LINENO}: Found freetype include files at $POTENTIAL_FREETYPE_INCLUDE_PATH using $METHOD" >&5 57957 $as_echo "$as_me: Found freetype include files at $POTENTIAL_FREETYPE_INCLUDE_PATH using $METHOD" >&6;} 57958 57959 # Reset to default value 57960 FREETYPE_BASE_NAME=freetype 57961 FREETYPE_LIB_NAME="${LIBRARY_PREFIX}${FREETYPE_BASE_NAME}${SHARED_LIBRARY_SUFFIX}" 57962 if ! test -s "$POTENTIAL_FREETYPE_LIB_PATH/$FREETYPE_LIB_NAME"; then 57963 if test "x$OPENJDK_TARGET_OS" = xmacosx \ 57964 && test -s "$POTENTIAL_FREETYPE_LIB_PATH/${LIBRARY_PREFIX}freetype.6${SHARED_LIBRARY_SUFFIX}"; then 57965 # On Mac OS X Yosemite, the symlink from libfreetype.dylib to libfreetype.6.dylib disappeared. Check 57966 # for the .6 version explicitly. 57967 FREETYPE_BASE_NAME=freetype.6 57968 FREETYPE_LIB_NAME="${LIBRARY_PREFIX}${FREETYPE_BASE_NAME}${SHARED_LIBRARY_SUFFIX}" 57969 { $as_echo "$as_me:${as_lineno-$LINENO}: Compensating for missing symlink by using version 6 explicitly" >&5 57970 $as_echo "$as_me: Compensating for missing symlink by using version 6 explicitly" >&6;} 57971 else 57972 { $as_echo "$as_me:${as_lineno-$LINENO}: Could not find $POTENTIAL_FREETYPE_LIB_PATH/$FREETYPE_LIB_NAME. Ignoring location." >&5 57973 $as_echo "$as_me: Could not find $POTENTIAL_FREETYPE_LIB_PATH/$FREETYPE_LIB_NAME. Ignoring location." >&6;} 57974 FOUND_FREETYPE=no 57975 fi 57976 else 57977 if test "x$OPENJDK_TARGET_OS" = xwindows; then 57978 # On Windows, we will need both .lib and .dll file. 57979 if ! test -s "$POTENTIAL_FREETYPE_LIB_PATH/${FREETYPE_BASE_NAME}.lib"; then 57980 { $as_echo "$as_me:${as_lineno-$LINENO}: Could not find $POTENTIAL_FREETYPE_LIB_PATH/${FREETYPE_BASE_NAME}.lib. Ignoring location." >&5 57981 $as_echo "$as_me: Could not find $POTENTIAL_FREETYPE_LIB_PATH/${FREETYPE_BASE_NAME}.lib. Ignoring location." >&6;} 57982 FOUND_FREETYPE=no 57983 fi 57984 elif test "x$OPENJDK_TARGET_OS" = xsolaris \ 57985 && test -s "$POTENTIAL_FREETYPE_LIB_PATH$OPENJDK_TARGET_CPU_ISADIR/$FREETYPE_LIB_NAME"; then 57986 # Found lib in isa dir, use that instead. 57987 POTENTIAL_FREETYPE_LIB_PATH="$POTENTIAL_FREETYPE_LIB_PATH$OPENJDK_TARGET_CPU_ISADIR" 57988 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting to use $POTENTIAL_FREETYPE_LIB_PATH instead" >&5 57989 $as_echo "$as_me: Rewriting to use $POTENTIAL_FREETYPE_LIB_PATH instead" >&6;} 57990 fi 57991 fi 57992 fi 57993 57994 if test "x$FOUND_FREETYPE" = xyes; then 57995 57996 # Only process if variable expands to non-empty 57997 57998 if test "x$POTENTIAL_FREETYPE_INCLUDE_PATH" != x; then 57999 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 58000 58001 # Input might be given as Windows format, start by converting to 58002 # unix format. 58003 path="$POTENTIAL_FREETYPE_INCLUDE_PATH" 58004 new_path=`$CYGPATH -u "$path"` 58005 58006 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 58007 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 58008 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 58009 # "foo.exe" is OK but "foo" is an error. 58010 # 58011 # This test is therefore slightly more accurate than "test -f" to check for file precense. 58012 # It is also a way to make sure we got the proper file name for the real test later on. 58013 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 58014 if test "x$test_shortpath" = x; then 58015 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&5 58016 $as_echo "$as_me: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&6;} 58017 as_fn_error $? "Cannot locate the the path of POTENTIAL_FREETYPE_INCLUDE_PATH" "$LINENO" 5 58018 fi 58019 58020 # Call helper function which possibly converts this using DOS-style short mode. 58021 # If so, the updated path is stored in $new_path. 58022 58023 input_path="$new_path" 58024 # Check if we need to convert this using DOS-style short mode. If the path 58025 # contains just simple characters, use it. Otherwise (spaces, weird characters), 58026 # take no chances and rewrite it. 58027 # Note: m4 eats our [], so we need to use [ and ] instead. 58028 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 58029 if test "x$has_forbidden_chars" != x; then 58030 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 58031 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 58032 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 58033 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 58034 # Going to short mode and back again did indeed matter. Since short mode is 58035 # case insensitive, let's make it lowercase to improve readability. 58036 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 58037 # Now convert it back to Unix-style (cygpath) 58038 input_path=`$CYGPATH -u "$shortmode_path"` 58039 new_path="$input_path" 58040 fi 58041 fi 58042 58043 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 58044 if test "x$test_cygdrive_prefix" = x; then 58045 # As a simple fix, exclude /usr/bin since it's not a real path. 58046 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 58047 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 58048 # a path prefixed by /cygdrive for fixpath to work. 58049 new_path="$CYGWIN_ROOT_PATH$input_path" 58050 fi 58051 fi 58052 58053 58054 if test "x$path" != "x$new_path"; then 58055 POTENTIAL_FREETYPE_INCLUDE_PATH="$new_path" 58056 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&5 58057 $as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&6;} 58058 fi 58059 58060 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 58061 58062 path="$POTENTIAL_FREETYPE_INCLUDE_PATH" 58063 has_colon=`$ECHO $path | $GREP ^.:` 58064 new_path="$path" 58065 if test "x$has_colon" = x; then 58066 # Not in mixed or Windows style, start by that. 58067 new_path=`cmd //c echo $path` 58068 fi 58069 58070 58071 input_path="$new_path" 58072 # Check if we need to convert this using DOS-style short mode. If the path 58073 # contains just simple characters, use it. Otherwise (spaces, weird characters), 58074 # take no chances and rewrite it. 58075 # Note: m4 eats our [], so we need to use [ and ] instead. 58076 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 58077 if test "x$has_forbidden_chars" != x; then 58078 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 58079 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 58080 fi 58081 58082 58083 windows_path="$new_path" 58084 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 58085 unix_path=`$CYGPATH -u "$windows_path"` 58086 new_path="$unix_path" 58087 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 58088 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 58089 new_path="$unix_path" 58090 fi 58091 58092 if test "x$path" != "x$new_path"; then 58093 POTENTIAL_FREETYPE_INCLUDE_PATH="$new_path" 58094 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&5 58095 $as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&6;} 58096 fi 58097 58098 # Save the first 10 bytes of this path to the storage, so fixpath can work. 58099 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 58100 58101 else 58102 # We're on a unix platform. Hooray! :) 58103 path="$POTENTIAL_FREETYPE_INCLUDE_PATH" 58104 has_space=`$ECHO "$path" | $GREP " "` 58105 if test "x$has_space" != x; then 58106 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&5 58107 $as_echo "$as_me: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&6;} 58108 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 58109 fi 58110 58111 # Use eval to expand a potential ~ 58112 eval path="$path" 58113 if test ! -f "$path" && test ! -d "$path"; then 58114 as_fn_error $? "The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is not found." "$LINENO" 5 58115 fi 58116 58117 if test -d "$path"; then 58118 POTENTIAL_FREETYPE_INCLUDE_PATH="`cd "$path"; $THEPWDCMD -L`" 58119 else 58120 dir="`$DIRNAME "$path"`" 58121 base="`$BASENAME "$path"`" 58122 POTENTIAL_FREETYPE_INCLUDE_PATH="`cd "$dir"; $THEPWDCMD -L`/$base" 58123 fi 58124 fi 58125 fi 58126 58127 58128 # Only process if variable expands to non-empty 58129 58130 if test "x$POTENTIAL_FREETYPE_LIB_PATH" != x; then 58131 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 58132 58133 # Input might be given as Windows format, start by converting to 58134 # unix format. 58135 path="$POTENTIAL_FREETYPE_LIB_PATH" 58136 new_path=`$CYGPATH -u "$path"` 58137 58138 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 58139 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 58140 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 58141 # "foo.exe" is OK but "foo" is an error. 58142 # 58143 # This test is therefore slightly more accurate than "test -f" to check for file precense. 58144 # It is also a way to make sure we got the proper file name for the real test later on. 58145 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 58146 if test "x$test_shortpath" = x; then 58147 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&5 58148 $as_echo "$as_me: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&6;} 58149 as_fn_error $? "Cannot locate the the path of POTENTIAL_FREETYPE_LIB_PATH" "$LINENO" 5 58150 fi 58151 58152 # Call helper function which possibly converts this using DOS-style short mode. 58153 # If so, the updated path is stored in $new_path. 58154 58155 input_path="$new_path" 58156 # Check if we need to convert this using DOS-style short mode. If the path 58157 # contains just simple characters, use it. Otherwise (spaces, weird characters), 58158 # take no chances and rewrite it. 58159 # Note: m4 eats our [], so we need to use [ and ] instead. 58160 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 58161 if test "x$has_forbidden_chars" != x; then 58162 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 58163 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 58164 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 58165 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 58166 # Going to short mode and back again did indeed matter. Since short mode is 58167 # case insensitive, let's make it lowercase to improve readability. 58168 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 58169 # Now convert it back to Unix-style (cygpath) 58170 input_path=`$CYGPATH -u "$shortmode_path"` 58171 new_path="$input_path" 58172 fi 58173 fi 58174 58175 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 58176 if test "x$test_cygdrive_prefix" = x; then 58177 # As a simple fix, exclude /usr/bin since it's not a real path. 58178 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 58179 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 58180 # a path prefixed by /cygdrive for fixpath to work. 58181 new_path="$CYGWIN_ROOT_PATH$input_path" 58182 fi 58183 fi 58184 58185 58186 if test "x$path" != "x$new_path"; then 58187 POTENTIAL_FREETYPE_LIB_PATH="$new_path" 58188 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&5 58189 $as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&6;} 58190 fi 58191 58192 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 58193 58194 path="$POTENTIAL_FREETYPE_LIB_PATH" 58195 has_colon=`$ECHO $path | $GREP ^.:` 58196 new_path="$path" 58197 if test "x$has_colon" = x; then 58198 # Not in mixed or Windows style, start by that. 58199 new_path=`cmd //c echo $path` 58200 fi 58201 58202 58203 input_path="$new_path" 58204 # Check if we need to convert this using DOS-style short mode. If the path 58205 # contains just simple characters, use it. Otherwise (spaces, weird characters), 58206 # take no chances and rewrite it. 58207 # Note: m4 eats our [], so we need to use [ and ] instead. 58208 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 58209 if test "x$has_forbidden_chars" != x; then 58210 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 58211 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 58212 fi 58213 58214 58215 windows_path="$new_path" 58216 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 58217 unix_path=`$CYGPATH -u "$windows_path"` 58218 new_path="$unix_path" 58219 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 58220 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 58221 new_path="$unix_path" 58222 fi 58223 58224 if test "x$path" != "x$new_path"; then 58225 POTENTIAL_FREETYPE_LIB_PATH="$new_path" 58226 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&5 58227 $as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&6;} 58228 fi 58229 58230 # Save the first 10 bytes of this path to the storage, so fixpath can work. 58231 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 58232 58233 else 58234 # We're on a unix platform. Hooray! :) 58235 path="$POTENTIAL_FREETYPE_LIB_PATH" 58236 has_space=`$ECHO "$path" | $GREP " "` 58237 if test "x$has_space" != x; then 58238 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&5 58239 $as_echo "$as_me: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&6;} 58240 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 58241 fi 58242 58243 # Use eval to expand a potential ~ 58244 eval path="$path" 58245 if test ! -f "$path" && test ! -d "$path"; then 58246 as_fn_error $? "The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is not found." "$LINENO" 5 58247 fi 58248 58249 if test -d "$path"; then 58250 POTENTIAL_FREETYPE_LIB_PATH="`cd "$path"; $THEPWDCMD -L`" 58251 else 58252 dir="`$DIRNAME "$path"`" 58253 base="`$BASENAME "$path"`" 58254 POTENTIAL_FREETYPE_LIB_PATH="`cd "$dir"; $THEPWDCMD -L`/$base" 58255 fi 58256 fi 58257 fi 58258 58259 58260 FREETYPE_INCLUDE_PATH="$POTENTIAL_FREETYPE_INCLUDE_PATH" 58261 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for freetype includes" >&5 58262 $as_echo_n "checking for freetype includes... " >&6; } 58263 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $FREETYPE_INCLUDE_PATH" >&5 58264 $as_echo "$FREETYPE_INCLUDE_PATH" >&6; } 58265 FREETYPE_LIB_PATH="$POTENTIAL_FREETYPE_LIB_PATH" 58266 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for freetype libraries" >&5 58267 $as_echo_n "checking for freetype libraries... " >&6; } 58268 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $FREETYPE_LIB_PATH" >&5 58269 $as_echo "$FREETYPE_LIB_PATH" >&6; } 58270 fi 58271 58272 if test "x$FOUND_FREETYPE" != xyes; then 58273 FREETYPE_BASE_DIR="$ProgramW6432/GnuWin32" 58274 58275 windows_path="$FREETYPE_BASE_DIR" 58276 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 58277 unix_path=`$CYGPATH -u "$windows_path"` 58278 FREETYPE_BASE_DIR="$unix_path" 58279 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 58280 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 58281 FREETYPE_BASE_DIR="$unix_path" 58282 fi 58283 58284 58285 POTENTIAL_FREETYPE_INCLUDE_PATH="$FREETYPE_BASE_DIR/include" 58286 POTENTIAL_FREETYPE_LIB_PATH="$FREETYPE_BASE_DIR/lib" 58287 METHOD="well-known location" 58288 58289 # Let's start with an optimistic view of the world :-) 58290 FOUND_FREETYPE=yes 58291 58292 # First look for the canonical freetype main include file ft2build.h. 58293 if ! test -s "$POTENTIAL_FREETYPE_INCLUDE_PATH/ft2build.h"; then 58294 # Oh no! Let's try in the freetype2 directory. This is needed at least at Mac OS X Yosemite. 58295 POTENTIAL_FREETYPE_INCLUDE_PATH="$POTENTIAL_FREETYPE_INCLUDE_PATH/freetype2" 58296 if ! test -s "$POTENTIAL_FREETYPE_INCLUDE_PATH/ft2build.h"; then 58297 # Fail. 58298 FOUND_FREETYPE=no 58299 fi 58300 fi 58301 58302 if test "x$FOUND_FREETYPE" = xyes; then 58303 # Include file found, let's continue the sanity check. 58304 { $as_echo "$as_me:${as_lineno-$LINENO}: Found freetype include files at $POTENTIAL_FREETYPE_INCLUDE_PATH using $METHOD" >&5 58305 $as_echo "$as_me: Found freetype include files at $POTENTIAL_FREETYPE_INCLUDE_PATH using $METHOD" >&6;} 58306 58307 # Reset to default value 58308 FREETYPE_BASE_NAME=freetype 58309 FREETYPE_LIB_NAME="${LIBRARY_PREFIX}${FREETYPE_BASE_NAME}${SHARED_LIBRARY_SUFFIX}" 58310 if ! test -s "$POTENTIAL_FREETYPE_LIB_PATH/$FREETYPE_LIB_NAME"; then 58311 if test "x$OPENJDK_TARGET_OS" = xmacosx \ 58312 && test -s "$POTENTIAL_FREETYPE_LIB_PATH/${LIBRARY_PREFIX}freetype.6${SHARED_LIBRARY_SUFFIX}"; then 58313 # On Mac OS X Yosemite, the symlink from libfreetype.dylib to libfreetype.6.dylib disappeared. Check 58314 # for the .6 version explicitly. 58315 FREETYPE_BASE_NAME=freetype.6 58316 FREETYPE_LIB_NAME="${LIBRARY_PREFIX}${FREETYPE_BASE_NAME}${SHARED_LIBRARY_SUFFIX}" 58317 { $as_echo "$as_me:${as_lineno-$LINENO}: Compensating for missing symlink by using version 6 explicitly" >&5 58318 $as_echo "$as_me: Compensating for missing symlink by using version 6 explicitly" >&6;} 58319 else 58320 { $as_echo "$as_me:${as_lineno-$LINENO}: Could not find $POTENTIAL_FREETYPE_LIB_PATH/$FREETYPE_LIB_NAME. Ignoring location." >&5 58321 $as_echo "$as_me: Could not find $POTENTIAL_FREETYPE_LIB_PATH/$FREETYPE_LIB_NAME. Ignoring location." >&6;} 58322 FOUND_FREETYPE=no 58323 fi 58324 else 58325 if test "x$OPENJDK_TARGET_OS" = xwindows; then 58326 # On Windows, we will need both .lib and .dll file. 58327 if ! test -s "$POTENTIAL_FREETYPE_LIB_PATH/${FREETYPE_BASE_NAME}.lib"; then 58328 { $as_echo "$as_me:${as_lineno-$LINENO}: Could not find $POTENTIAL_FREETYPE_LIB_PATH/${FREETYPE_BASE_NAME}.lib. Ignoring location." >&5 58329 $as_echo "$as_me: Could not find $POTENTIAL_FREETYPE_LIB_PATH/${FREETYPE_BASE_NAME}.lib. Ignoring location." >&6;} 58330 FOUND_FREETYPE=no 58331 fi 58332 elif test "x$OPENJDK_TARGET_OS" = xsolaris \ 58333 && test -s "$POTENTIAL_FREETYPE_LIB_PATH$OPENJDK_TARGET_CPU_ISADIR/$FREETYPE_LIB_NAME"; then 58334 # Found lib in isa dir, use that instead. 58335 POTENTIAL_FREETYPE_LIB_PATH="$POTENTIAL_FREETYPE_LIB_PATH$OPENJDK_TARGET_CPU_ISADIR" 58336 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting to use $POTENTIAL_FREETYPE_LIB_PATH instead" >&5 58337 $as_echo "$as_me: Rewriting to use $POTENTIAL_FREETYPE_LIB_PATH instead" >&6;} 58338 fi 58339 fi 58340 fi 58341 58342 if test "x$FOUND_FREETYPE" = xyes; then 58343 58344 # Only process if variable expands to non-empty 58345 58346 if test "x$POTENTIAL_FREETYPE_INCLUDE_PATH" != x; then 58347 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 58348 58349 # Input might be given as Windows format, start by converting to 58350 # unix format. 58351 path="$POTENTIAL_FREETYPE_INCLUDE_PATH" 58352 new_path=`$CYGPATH -u "$path"` 58353 58354 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 58355 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 58356 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 58357 # "foo.exe" is OK but "foo" is an error. 58358 # 58359 # This test is therefore slightly more accurate than "test -f" to check for file precense. 58360 # It is also a way to make sure we got the proper file name for the real test later on. 58361 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 58362 if test "x$test_shortpath" = x; then 58363 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&5 58364 $as_echo "$as_me: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&6;} 58365 as_fn_error $? "Cannot locate the the path of POTENTIAL_FREETYPE_INCLUDE_PATH" "$LINENO" 5 58366 fi 58367 58368 # Call helper function which possibly converts this using DOS-style short mode. 58369 # If so, the updated path is stored in $new_path. 58370 58371 input_path="$new_path" 58372 # Check if we need to convert this using DOS-style short mode. If the path 58373 # contains just simple characters, use it. Otherwise (spaces, weird characters), 58374 # take no chances and rewrite it. 58375 # Note: m4 eats our [], so we need to use [ and ] instead. 58376 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 58377 if test "x$has_forbidden_chars" != x; then 58378 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 58379 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 58380 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 58381 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 58382 # Going to short mode and back again did indeed matter. Since short mode is 58383 # case insensitive, let's make it lowercase to improve readability. 58384 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 58385 # Now convert it back to Unix-style (cygpath) 58386 input_path=`$CYGPATH -u "$shortmode_path"` 58387 new_path="$input_path" 58388 fi 58389 fi 58390 58391 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 58392 if test "x$test_cygdrive_prefix" = x; then 58393 # As a simple fix, exclude /usr/bin since it's not a real path. 58394 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 58395 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 58396 # a path prefixed by /cygdrive for fixpath to work. 58397 new_path="$CYGWIN_ROOT_PATH$input_path" 58398 fi 58399 fi 58400 58401 58402 if test "x$path" != "x$new_path"; then 58403 POTENTIAL_FREETYPE_INCLUDE_PATH="$new_path" 58404 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&5 58405 $as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&6;} 58406 fi 58407 58408 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 58409 58410 path="$POTENTIAL_FREETYPE_INCLUDE_PATH" 58411 has_colon=`$ECHO $path | $GREP ^.:` 58412 new_path="$path" 58413 if test "x$has_colon" = x; then 58414 # Not in mixed or Windows style, start by that. 58415 new_path=`cmd //c echo $path` 58416 fi 58417 58418 58419 input_path="$new_path" 58420 # Check if we need to convert this using DOS-style short mode. If the path 58421 # contains just simple characters, use it. Otherwise (spaces, weird characters), 58422 # take no chances and rewrite it. 58423 # Note: m4 eats our [], so we need to use [ and ] instead. 58424 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 58425 if test "x$has_forbidden_chars" != x; then 58426 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 58427 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 58428 fi 58429 58430 58431 windows_path="$new_path" 58432 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 58433 unix_path=`$CYGPATH -u "$windows_path"` 58434 new_path="$unix_path" 58435 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 58436 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 58437 new_path="$unix_path" 58438 fi 58439 58440 if test "x$path" != "x$new_path"; then 58441 POTENTIAL_FREETYPE_INCLUDE_PATH="$new_path" 58442 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&5 58443 $as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&6;} 58444 fi 58445 58446 # Save the first 10 bytes of this path to the storage, so fixpath can work. 58447 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 58448 58449 else 58450 # We're on a unix platform. Hooray! :) 58451 path="$POTENTIAL_FREETYPE_INCLUDE_PATH" 58452 has_space=`$ECHO "$path" | $GREP " "` 58453 if test "x$has_space" != x; then 58454 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&5 58455 $as_echo "$as_me: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&6;} 58456 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 58457 fi 58458 58459 # Use eval to expand a potential ~ 58460 eval path="$path" 58461 if test ! -f "$path" && test ! -d "$path"; then 58462 as_fn_error $? "The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is not found." "$LINENO" 5 58463 fi 58464 58465 if test -d "$path"; then 58466 POTENTIAL_FREETYPE_INCLUDE_PATH="`cd "$path"; $THEPWDCMD -L`" 58467 else 58468 dir="`$DIRNAME "$path"`" 58469 base="`$BASENAME "$path"`" 58470 POTENTIAL_FREETYPE_INCLUDE_PATH="`cd "$dir"; $THEPWDCMD -L`/$base" 58471 fi 58472 fi 58473 fi 58474 58475 58476 # Only process if variable expands to non-empty 58477 58478 if test "x$POTENTIAL_FREETYPE_LIB_PATH" != x; then 58479 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 58480 58481 # Input might be given as Windows format, start by converting to 58482 # unix format. 58483 path="$POTENTIAL_FREETYPE_LIB_PATH" 58484 new_path=`$CYGPATH -u "$path"` 58485 58486 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 58487 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 58488 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 58489 # "foo.exe" is OK but "foo" is an error. 58490 # 58491 # This test is therefore slightly more accurate than "test -f" to check for file precense. 58492 # It is also a way to make sure we got the proper file name for the real test later on. 58493 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 58494 if test "x$test_shortpath" = x; then 58495 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&5 58496 $as_echo "$as_me: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&6;} 58497 as_fn_error $? "Cannot locate the the path of POTENTIAL_FREETYPE_LIB_PATH" "$LINENO" 5 58498 fi 58499 58500 # Call helper function which possibly converts this using DOS-style short mode. 58501 # If so, the updated path is stored in $new_path. 58502 58503 input_path="$new_path" 58504 # Check if we need to convert this using DOS-style short mode. If the path 58505 # contains just simple characters, use it. Otherwise (spaces, weird characters), 58506 # take no chances and rewrite it. 58507 # Note: m4 eats our [], so we need to use [ and ] instead. 58508 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 58509 if test "x$has_forbidden_chars" != x; then 58510 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 58511 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 58512 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 58513 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 58514 # Going to short mode and back again did indeed matter. Since short mode is 58515 # case insensitive, let's make it lowercase to improve readability. 58516 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 58517 # Now convert it back to Unix-style (cygpath) 58518 input_path=`$CYGPATH -u "$shortmode_path"` 58519 new_path="$input_path" 58520 fi 58521 fi 58522 58523 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 58524 if test "x$test_cygdrive_prefix" = x; then 58525 # As a simple fix, exclude /usr/bin since it's not a real path. 58526 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 58527 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 58528 # a path prefixed by /cygdrive for fixpath to work. 58529 new_path="$CYGWIN_ROOT_PATH$input_path" 58530 fi 58531 fi 58532 58533 58534 if test "x$path" != "x$new_path"; then 58535 POTENTIAL_FREETYPE_LIB_PATH="$new_path" 58536 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&5 58537 $as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&6;} 58538 fi 58539 58540 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 58541 58542 path="$POTENTIAL_FREETYPE_LIB_PATH" 58543 has_colon=`$ECHO $path | $GREP ^.:` 58544 new_path="$path" 58545 if test "x$has_colon" = x; then 58546 # Not in mixed or Windows style, start by that. 58547 new_path=`cmd //c echo $path` 58548 fi 58549 58550 58551 input_path="$new_path" 58552 # Check if we need to convert this using DOS-style short mode. If the path 58553 # contains just simple characters, use it. Otherwise (spaces, weird characters), 58554 # take no chances and rewrite it. 58555 # Note: m4 eats our [], so we need to use [ and ] instead. 58556 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 58557 if test "x$has_forbidden_chars" != x; then 58558 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 58559 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 58560 fi 58561 58562 58563 windows_path="$new_path" 58564 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 58565 unix_path=`$CYGPATH -u "$windows_path"` 58566 new_path="$unix_path" 58567 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 58568 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 58569 new_path="$unix_path" 58570 fi 58571 58572 if test "x$path" != "x$new_path"; then 58573 POTENTIAL_FREETYPE_LIB_PATH="$new_path" 58574 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&5 58575 $as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&6;} 58576 fi 58577 58578 # Save the first 10 bytes of this path to the storage, so fixpath can work. 58579 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 58580 58581 else 58582 # We're on a unix platform. Hooray! :) 58583 path="$POTENTIAL_FREETYPE_LIB_PATH" 58584 has_space=`$ECHO "$path" | $GREP " "` 58585 if test "x$has_space" != x; then 58586 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&5 58587 $as_echo "$as_me: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&6;} 58588 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 58589 fi 58590 58591 # Use eval to expand a potential ~ 58592 eval path="$path" 58593 if test ! -f "$path" && test ! -d "$path"; then 58594 as_fn_error $? "The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is not found." "$LINENO" 5 58595 fi 58596 58597 if test -d "$path"; then 58598 POTENTIAL_FREETYPE_LIB_PATH="`cd "$path"; $THEPWDCMD -L`" 58599 else 58600 dir="`$DIRNAME "$path"`" 58601 base="`$BASENAME "$path"`" 58602 POTENTIAL_FREETYPE_LIB_PATH="`cd "$dir"; $THEPWDCMD -L`/$base" 58603 fi 58604 fi 58605 fi 58606 58607 58608 FREETYPE_INCLUDE_PATH="$POTENTIAL_FREETYPE_INCLUDE_PATH" 58609 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for freetype includes" >&5 58610 $as_echo_n "checking for freetype includes... " >&6; } 58611 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $FREETYPE_INCLUDE_PATH" >&5 58612 $as_echo "$FREETYPE_INCLUDE_PATH" >&6; } 58613 FREETYPE_LIB_PATH="$POTENTIAL_FREETYPE_LIB_PATH" 58614 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for freetype libraries" >&5 58615 $as_echo_n "checking for freetype libraries... " >&6; } 58616 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $FREETYPE_LIB_PATH" >&5 58617 $as_echo "$FREETYPE_LIB_PATH" >&6; } 58618 fi 58619 58620 fi 58621 if test "x$FOUND_FREETYPE" != xyes; then 58622 FREETYPE_BASE_DIR="$HOME/freetype" 58623 58624 windows_path="$FREETYPE_BASE_DIR" 58625 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 58626 unix_path=`$CYGPATH -u "$windows_path"` 58627 FREETYPE_BASE_DIR="$unix_path" 58628 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 58629 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 58630 FREETYPE_BASE_DIR="$unix_path" 58631 fi 58632 58633 if test "x$OPENJDK_TARGET_CPU_BITS" = x64; then 58634 58635 POTENTIAL_FREETYPE_INCLUDE_PATH="$FREETYPE_BASE_DIR/include" 58636 POTENTIAL_FREETYPE_LIB_PATH="$FREETYPE_BASE_DIR/lib64" 58637 METHOD="well-known location" 58638 58639 # Let's start with an optimistic view of the world :-) 58640 FOUND_FREETYPE=yes 58641 58642 # First look for the canonical freetype main include file ft2build.h. 58643 if ! test -s "$POTENTIAL_FREETYPE_INCLUDE_PATH/ft2build.h"; then 58644 # Oh no! Let's try in the freetype2 directory. This is needed at least at Mac OS X Yosemite. 58645 POTENTIAL_FREETYPE_INCLUDE_PATH="$POTENTIAL_FREETYPE_INCLUDE_PATH/freetype2" 58646 if ! test -s "$POTENTIAL_FREETYPE_INCLUDE_PATH/ft2build.h"; then 58647 # Fail. 58648 FOUND_FREETYPE=no 58649 fi 58650 fi 58651 58652 if test "x$FOUND_FREETYPE" = xyes; then 58653 # Include file found, let's continue the sanity check. 58654 { $as_echo "$as_me:${as_lineno-$LINENO}: Found freetype include files at $POTENTIAL_FREETYPE_INCLUDE_PATH using $METHOD" >&5 58655 $as_echo "$as_me: Found freetype include files at $POTENTIAL_FREETYPE_INCLUDE_PATH using $METHOD" >&6;} 58656 58657 # Reset to default value 58658 FREETYPE_BASE_NAME=freetype 58659 FREETYPE_LIB_NAME="${LIBRARY_PREFIX}${FREETYPE_BASE_NAME}${SHARED_LIBRARY_SUFFIX}" 58660 if ! test -s "$POTENTIAL_FREETYPE_LIB_PATH/$FREETYPE_LIB_NAME"; then 58661 if test "x$OPENJDK_TARGET_OS" = xmacosx \ 58662 && test -s "$POTENTIAL_FREETYPE_LIB_PATH/${LIBRARY_PREFIX}freetype.6${SHARED_LIBRARY_SUFFIX}"; then 58663 # On Mac OS X Yosemite, the symlink from libfreetype.dylib to libfreetype.6.dylib disappeared. Check 58664 # for the .6 version explicitly. 58665 FREETYPE_BASE_NAME=freetype.6 58666 FREETYPE_LIB_NAME="${LIBRARY_PREFIX}${FREETYPE_BASE_NAME}${SHARED_LIBRARY_SUFFIX}" 58667 { $as_echo "$as_me:${as_lineno-$LINENO}: Compensating for missing symlink by using version 6 explicitly" >&5 58668 $as_echo "$as_me: Compensating for missing symlink by using version 6 explicitly" >&6;} 58669 else 58670 { $as_echo "$as_me:${as_lineno-$LINENO}: Could not find $POTENTIAL_FREETYPE_LIB_PATH/$FREETYPE_LIB_NAME. Ignoring location." >&5 58671 $as_echo "$as_me: Could not find $POTENTIAL_FREETYPE_LIB_PATH/$FREETYPE_LIB_NAME. Ignoring location." >&6;} 58672 FOUND_FREETYPE=no 58673 fi 58674 else 58675 if test "x$OPENJDK_TARGET_OS" = xwindows; then 58676 # On Windows, we will need both .lib and .dll file. 58677 if ! test -s "$POTENTIAL_FREETYPE_LIB_PATH/${FREETYPE_BASE_NAME}.lib"; then 58678 { $as_echo "$as_me:${as_lineno-$LINENO}: Could not find $POTENTIAL_FREETYPE_LIB_PATH/${FREETYPE_BASE_NAME}.lib. Ignoring location." >&5 58679 $as_echo "$as_me: Could not find $POTENTIAL_FREETYPE_LIB_PATH/${FREETYPE_BASE_NAME}.lib. Ignoring location." >&6;} 58680 FOUND_FREETYPE=no 58681 fi 58682 elif test "x$OPENJDK_TARGET_OS" = xsolaris \ 58683 && test -s "$POTENTIAL_FREETYPE_LIB_PATH$OPENJDK_TARGET_CPU_ISADIR/$FREETYPE_LIB_NAME"; then 58684 # Found lib in isa dir, use that instead. 58685 POTENTIAL_FREETYPE_LIB_PATH="$POTENTIAL_FREETYPE_LIB_PATH$OPENJDK_TARGET_CPU_ISADIR" 58686 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting to use $POTENTIAL_FREETYPE_LIB_PATH instead" >&5 58687 $as_echo "$as_me: Rewriting to use $POTENTIAL_FREETYPE_LIB_PATH instead" >&6;} 58688 fi 58689 fi 58690 fi 58691 58692 if test "x$FOUND_FREETYPE" = xyes; then 58693 58694 # Only process if variable expands to non-empty 58695 58696 if test "x$POTENTIAL_FREETYPE_INCLUDE_PATH" != x; then 58697 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 58698 58699 # Input might be given as Windows format, start by converting to 58700 # unix format. 58701 path="$POTENTIAL_FREETYPE_INCLUDE_PATH" 58702 new_path=`$CYGPATH -u "$path"` 58703 58704 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 58705 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 58706 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 58707 # "foo.exe" is OK but "foo" is an error. 58708 # 58709 # This test is therefore slightly more accurate than "test -f" to check for file precense. 58710 # It is also a way to make sure we got the proper file name for the real test later on. 58711 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 58712 if test "x$test_shortpath" = x; then 58713 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&5 58714 $as_echo "$as_me: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&6;} 58715 as_fn_error $? "Cannot locate the the path of POTENTIAL_FREETYPE_INCLUDE_PATH" "$LINENO" 5 58716 fi 58717 58718 # Call helper function which possibly converts this using DOS-style short mode. 58719 # If so, the updated path is stored in $new_path. 58720 58721 input_path="$new_path" 58722 # Check if we need to convert this using DOS-style short mode. If the path 58723 # contains just simple characters, use it. Otherwise (spaces, weird characters), 58724 # take no chances and rewrite it. 58725 # Note: m4 eats our [], so we need to use [ and ] instead. 58726 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 58727 if test "x$has_forbidden_chars" != x; then 58728 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 58729 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 58730 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 58731 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 58732 # Going to short mode and back again did indeed matter. Since short mode is 58733 # case insensitive, let's make it lowercase to improve readability. 58734 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 58735 # Now convert it back to Unix-style (cygpath) 58736 input_path=`$CYGPATH -u "$shortmode_path"` 58737 new_path="$input_path" 58738 fi 58739 fi 58740 58741 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 58742 if test "x$test_cygdrive_prefix" = x; then 58743 # As a simple fix, exclude /usr/bin since it's not a real path. 58744 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 58745 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 58746 # a path prefixed by /cygdrive for fixpath to work. 58747 new_path="$CYGWIN_ROOT_PATH$input_path" 58748 fi 58749 fi 58750 58751 58752 if test "x$path" != "x$new_path"; then 58753 POTENTIAL_FREETYPE_INCLUDE_PATH="$new_path" 58754 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&5 58755 $as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&6;} 58756 fi 58757 58758 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 58759 58760 path="$POTENTIAL_FREETYPE_INCLUDE_PATH" 58761 has_colon=`$ECHO $path | $GREP ^.:` 58762 new_path="$path" 58763 if test "x$has_colon" = x; then 58764 # Not in mixed or Windows style, start by that. 58765 new_path=`cmd //c echo $path` 58766 fi 58767 58768 58769 input_path="$new_path" 58770 # Check if we need to convert this using DOS-style short mode. If the path 58771 # contains just simple characters, use it. Otherwise (spaces, weird characters), 58772 # take no chances and rewrite it. 58773 # Note: m4 eats our [], so we need to use [ and ] instead. 58774 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 58775 if test "x$has_forbidden_chars" != x; then 58776 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 58777 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 58778 fi 58779 58780 58781 windows_path="$new_path" 58782 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 58783 unix_path=`$CYGPATH -u "$windows_path"` 58784 new_path="$unix_path" 58785 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 58786 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 58787 new_path="$unix_path" 58788 fi 58789 58790 if test "x$path" != "x$new_path"; then 58791 POTENTIAL_FREETYPE_INCLUDE_PATH="$new_path" 58792 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&5 58793 $as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&6;} 58794 fi 58795 58796 # Save the first 10 bytes of this path to the storage, so fixpath can work. 58797 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 58798 58799 else 58800 # We're on a unix platform. Hooray! :) 58801 path="$POTENTIAL_FREETYPE_INCLUDE_PATH" 58802 has_space=`$ECHO "$path" | $GREP " "` 58803 if test "x$has_space" != x; then 58804 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&5 58805 $as_echo "$as_me: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&6;} 58806 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 58807 fi 58808 58809 # Use eval to expand a potential ~ 58810 eval path="$path" 58811 if test ! -f "$path" && test ! -d "$path"; then 58812 as_fn_error $? "The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is not found." "$LINENO" 5 58813 fi 58814 58815 if test -d "$path"; then 58816 POTENTIAL_FREETYPE_INCLUDE_PATH="`cd "$path"; $THEPWDCMD -L`" 58817 else 58818 dir="`$DIRNAME "$path"`" 58819 base="`$BASENAME "$path"`" 58820 POTENTIAL_FREETYPE_INCLUDE_PATH="`cd "$dir"; $THEPWDCMD -L`/$base" 58821 fi 58822 fi 58823 fi 58824 58825 58826 # Only process if variable expands to non-empty 58827 58828 if test "x$POTENTIAL_FREETYPE_LIB_PATH" != x; then 58829 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 58830 58831 # Input might be given as Windows format, start by converting to 58832 # unix format. 58833 path="$POTENTIAL_FREETYPE_LIB_PATH" 58834 new_path=`$CYGPATH -u "$path"` 58835 58836 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 58837 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 58838 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 58839 # "foo.exe" is OK but "foo" is an error. 58840 # 58841 # This test is therefore slightly more accurate than "test -f" to check for file precense. 58842 # It is also a way to make sure we got the proper file name for the real test later on. 58843 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 58844 if test "x$test_shortpath" = x; then 58845 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&5 58846 $as_echo "$as_me: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&6;} 58847 as_fn_error $? "Cannot locate the the path of POTENTIAL_FREETYPE_LIB_PATH" "$LINENO" 5 58848 fi 58849 58850 # Call helper function which possibly converts this using DOS-style short mode. 58851 # If so, the updated path is stored in $new_path. 58852 58853 input_path="$new_path" 58854 # Check if we need to convert this using DOS-style short mode. If the path 58855 # contains just simple characters, use it. Otherwise (spaces, weird characters), 58856 # take no chances and rewrite it. 58857 # Note: m4 eats our [], so we need to use [ and ] instead. 58858 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 58859 if test "x$has_forbidden_chars" != x; then 58860 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 58861 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 58862 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 58863 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 58864 # Going to short mode and back again did indeed matter. Since short mode is 58865 # case insensitive, let's make it lowercase to improve readability. 58866 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 58867 # Now convert it back to Unix-style (cygpath) 58868 input_path=`$CYGPATH -u "$shortmode_path"` 58869 new_path="$input_path" 58870 fi 58871 fi 58872 58873 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 58874 if test "x$test_cygdrive_prefix" = x; then 58875 # As a simple fix, exclude /usr/bin since it's not a real path. 58876 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 58877 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 58878 # a path prefixed by /cygdrive for fixpath to work. 58879 new_path="$CYGWIN_ROOT_PATH$input_path" 58880 fi 58881 fi 58882 58883 58884 if test "x$path" != "x$new_path"; then 58885 POTENTIAL_FREETYPE_LIB_PATH="$new_path" 58886 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&5 58887 $as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&6;} 58888 fi 58889 58890 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 58891 58892 path="$POTENTIAL_FREETYPE_LIB_PATH" 58893 has_colon=`$ECHO $path | $GREP ^.:` 58894 new_path="$path" 58895 if test "x$has_colon" = x; then 58896 # Not in mixed or Windows style, start by that. 58897 new_path=`cmd //c echo $path` 58898 fi 58899 58900 58901 input_path="$new_path" 58902 # Check if we need to convert this using DOS-style short mode. If the path 58903 # contains just simple characters, use it. Otherwise (spaces, weird characters), 58904 # take no chances and rewrite it. 58905 # Note: m4 eats our [], so we need to use [ and ] instead. 58906 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 58907 if test "x$has_forbidden_chars" != x; then 58908 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 58909 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 58910 fi 58911 58912 58913 windows_path="$new_path" 58914 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 58915 unix_path=`$CYGPATH -u "$windows_path"` 58916 new_path="$unix_path" 58917 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 58918 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 58919 new_path="$unix_path" 58920 fi 58921 58922 if test "x$path" != "x$new_path"; then 58923 POTENTIAL_FREETYPE_LIB_PATH="$new_path" 58924 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&5 58925 $as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&6;} 58926 fi 58927 58928 # Save the first 10 bytes of this path to the storage, so fixpath can work. 58929 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 58930 58931 else 58932 # We're on a unix platform. Hooray! :) 58933 path="$POTENTIAL_FREETYPE_LIB_PATH" 58934 has_space=`$ECHO "$path" | $GREP " "` 58935 if test "x$has_space" != x; then 58936 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&5 58937 $as_echo "$as_me: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&6;} 58938 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 58939 fi 58940 58941 # Use eval to expand a potential ~ 58942 eval path="$path" 58943 if test ! -f "$path" && test ! -d "$path"; then 58944 as_fn_error $? "The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is not found." "$LINENO" 5 58945 fi 58946 58947 if test -d "$path"; then 58948 POTENTIAL_FREETYPE_LIB_PATH="`cd "$path"; $THEPWDCMD -L`" 58949 else 58950 dir="`$DIRNAME "$path"`" 58951 base="`$BASENAME "$path"`" 58952 POTENTIAL_FREETYPE_LIB_PATH="`cd "$dir"; $THEPWDCMD -L`/$base" 58953 fi 58954 fi 58955 fi 58956 58957 58958 FREETYPE_INCLUDE_PATH="$POTENTIAL_FREETYPE_INCLUDE_PATH" 58959 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for freetype includes" >&5 58960 $as_echo_n "checking for freetype includes... " >&6; } 58961 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $FREETYPE_INCLUDE_PATH" >&5 58962 $as_echo "$FREETYPE_INCLUDE_PATH" >&6; } 58963 FREETYPE_LIB_PATH="$POTENTIAL_FREETYPE_LIB_PATH" 58964 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for freetype libraries" >&5 58965 $as_echo_n "checking for freetype libraries... " >&6; } 58966 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $FREETYPE_LIB_PATH" >&5 58967 $as_echo "$FREETYPE_LIB_PATH" >&6; } 58968 fi 58969 58970 else 58971 58972 POTENTIAL_FREETYPE_INCLUDE_PATH="$FREETYPE_BASE_DIR/include" 58973 POTENTIAL_FREETYPE_LIB_PATH="$FREETYPE_BASE_DIR/lib32" 58974 METHOD="well-known location" 58975 58976 # Let's start with an optimistic view of the world :-) 58977 FOUND_FREETYPE=yes 58978 58979 # First look for the canonical freetype main include file ft2build.h. 58980 if ! test -s "$POTENTIAL_FREETYPE_INCLUDE_PATH/ft2build.h"; then 58981 # Oh no! Let's try in the freetype2 directory. This is needed at least at Mac OS X Yosemite. 58982 POTENTIAL_FREETYPE_INCLUDE_PATH="$POTENTIAL_FREETYPE_INCLUDE_PATH/freetype2" 58983 if ! test -s "$POTENTIAL_FREETYPE_INCLUDE_PATH/ft2build.h"; then 58984 # Fail. 58985 FOUND_FREETYPE=no 58986 fi 58987 fi 58988 58989 if test "x$FOUND_FREETYPE" = xyes; then 58990 # Include file found, let's continue the sanity check. 58991 { $as_echo "$as_me:${as_lineno-$LINENO}: Found freetype include files at $POTENTIAL_FREETYPE_INCLUDE_PATH using $METHOD" >&5 58992 $as_echo "$as_me: Found freetype include files at $POTENTIAL_FREETYPE_INCLUDE_PATH using $METHOD" >&6;} 58993 58994 # Reset to default value 58995 FREETYPE_BASE_NAME=freetype 58996 FREETYPE_LIB_NAME="${LIBRARY_PREFIX}${FREETYPE_BASE_NAME}${SHARED_LIBRARY_SUFFIX}" 58997 if ! test -s "$POTENTIAL_FREETYPE_LIB_PATH/$FREETYPE_LIB_NAME"; then 58998 if test "x$OPENJDK_TARGET_OS" = xmacosx \ 58999 && test -s "$POTENTIAL_FREETYPE_LIB_PATH/${LIBRARY_PREFIX}freetype.6${SHARED_LIBRARY_SUFFIX}"; then 59000 # On Mac OS X Yosemite, the symlink from libfreetype.dylib to libfreetype.6.dylib disappeared. Check 59001 # for the .6 version explicitly. 59002 FREETYPE_BASE_NAME=freetype.6 59003 FREETYPE_LIB_NAME="${LIBRARY_PREFIX}${FREETYPE_BASE_NAME}${SHARED_LIBRARY_SUFFIX}" 59004 { $as_echo "$as_me:${as_lineno-$LINENO}: Compensating for missing symlink by using version 6 explicitly" >&5 59005 $as_echo "$as_me: Compensating for missing symlink by using version 6 explicitly" >&6;} 59006 else 59007 { $as_echo "$as_me:${as_lineno-$LINENO}: Could not find $POTENTIAL_FREETYPE_LIB_PATH/$FREETYPE_LIB_NAME. Ignoring location." >&5 59008 $as_echo "$as_me: Could not find $POTENTIAL_FREETYPE_LIB_PATH/$FREETYPE_LIB_NAME. Ignoring location." >&6;} 59009 FOUND_FREETYPE=no 59010 fi 59011 else 59012 if test "x$OPENJDK_TARGET_OS" = xwindows; then 59013 # On Windows, we will need both .lib and .dll file. 59014 if ! test -s "$POTENTIAL_FREETYPE_LIB_PATH/${FREETYPE_BASE_NAME}.lib"; then 59015 { $as_echo "$as_me:${as_lineno-$LINENO}: Could not find $POTENTIAL_FREETYPE_LIB_PATH/${FREETYPE_BASE_NAME}.lib. Ignoring location." >&5 59016 $as_echo "$as_me: Could not find $POTENTIAL_FREETYPE_LIB_PATH/${FREETYPE_BASE_NAME}.lib. Ignoring location." >&6;} 59017 FOUND_FREETYPE=no 59018 fi 59019 elif test "x$OPENJDK_TARGET_OS" = xsolaris \ 59020 && test -s "$POTENTIAL_FREETYPE_LIB_PATH$OPENJDK_TARGET_CPU_ISADIR/$FREETYPE_LIB_NAME"; then 59021 # Found lib in isa dir, use that instead. 59022 POTENTIAL_FREETYPE_LIB_PATH="$POTENTIAL_FREETYPE_LIB_PATH$OPENJDK_TARGET_CPU_ISADIR" 59023 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting to use $POTENTIAL_FREETYPE_LIB_PATH instead" >&5 59024 $as_echo "$as_me: Rewriting to use $POTENTIAL_FREETYPE_LIB_PATH instead" >&6;} 59025 fi 59026 fi 59027 fi 59028 59029 if test "x$FOUND_FREETYPE" = xyes; then 59030 59031 # Only process if variable expands to non-empty 59032 59033 if test "x$POTENTIAL_FREETYPE_INCLUDE_PATH" != x; then 59034 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 59035 59036 # Input might be given as Windows format, start by converting to 59037 # unix format. 59038 path="$POTENTIAL_FREETYPE_INCLUDE_PATH" 59039 new_path=`$CYGPATH -u "$path"` 59040 59041 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 59042 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 59043 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 59044 # "foo.exe" is OK but "foo" is an error. 59045 # 59046 # This test is therefore slightly more accurate than "test -f" to check for file precense. 59047 # It is also a way to make sure we got the proper file name for the real test later on. 59048 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 59049 if test "x$test_shortpath" = x; then 59050 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&5 59051 $as_echo "$as_me: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&6;} 59052 as_fn_error $? "Cannot locate the the path of POTENTIAL_FREETYPE_INCLUDE_PATH" "$LINENO" 5 59053 fi 59054 59055 # Call helper function which possibly converts this using DOS-style short mode. 59056 # If so, the updated path is stored in $new_path. 59057 59058 input_path="$new_path" 59059 # Check if we need to convert this using DOS-style short mode. If the path 59060 # contains just simple characters, use it. Otherwise (spaces, weird characters), 59061 # take no chances and rewrite it. 59062 # Note: m4 eats our [], so we need to use [ and ] instead. 59063 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 59064 if test "x$has_forbidden_chars" != x; then 59065 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 59066 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 59067 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 59068 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 59069 # Going to short mode and back again did indeed matter. Since short mode is 59070 # case insensitive, let's make it lowercase to improve readability. 59071 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 59072 # Now convert it back to Unix-style (cygpath) 59073 input_path=`$CYGPATH -u "$shortmode_path"` 59074 new_path="$input_path" 59075 fi 59076 fi 59077 59078 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 59079 if test "x$test_cygdrive_prefix" = x; then 59080 # As a simple fix, exclude /usr/bin since it's not a real path. 59081 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 59082 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 59083 # a path prefixed by /cygdrive for fixpath to work. 59084 new_path="$CYGWIN_ROOT_PATH$input_path" 59085 fi 59086 fi 59087 59088 59089 if test "x$path" != "x$new_path"; then 59090 POTENTIAL_FREETYPE_INCLUDE_PATH="$new_path" 59091 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&5 59092 $as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&6;} 59093 fi 59094 59095 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 59096 59097 path="$POTENTIAL_FREETYPE_INCLUDE_PATH" 59098 has_colon=`$ECHO $path | $GREP ^.:` 59099 new_path="$path" 59100 if test "x$has_colon" = x; then 59101 # Not in mixed or Windows style, start by that. 59102 new_path=`cmd //c echo $path` 59103 fi 59104 59105 59106 input_path="$new_path" 59107 # Check if we need to convert this using DOS-style short mode. If the path 59108 # contains just simple characters, use it. Otherwise (spaces, weird characters), 59109 # take no chances and rewrite it. 59110 # Note: m4 eats our [], so we need to use [ and ] instead. 59111 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 59112 if test "x$has_forbidden_chars" != x; then 59113 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 59114 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 59115 fi 59116 59117 59118 windows_path="$new_path" 59119 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 59120 unix_path=`$CYGPATH -u "$windows_path"` 59121 new_path="$unix_path" 59122 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 59123 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 59124 new_path="$unix_path" 59125 fi 59126 59127 if test "x$path" != "x$new_path"; then 59128 POTENTIAL_FREETYPE_INCLUDE_PATH="$new_path" 59129 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&5 59130 $as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&6;} 59131 fi 59132 59133 # Save the first 10 bytes of this path to the storage, so fixpath can work. 59134 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 59135 59136 else 59137 # We're on a unix platform. Hooray! :) 59138 path="$POTENTIAL_FREETYPE_INCLUDE_PATH" 59139 has_space=`$ECHO "$path" | $GREP " "` 59140 if test "x$has_space" != x; then 59141 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&5 59142 $as_echo "$as_me: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&6;} 59143 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 59144 fi 59145 59146 # Use eval to expand a potential ~ 59147 eval path="$path" 59148 if test ! -f "$path" && test ! -d "$path"; then 59149 as_fn_error $? "The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is not found." "$LINENO" 5 59150 fi 59151 59152 if test -d "$path"; then 59153 POTENTIAL_FREETYPE_INCLUDE_PATH="`cd "$path"; $THEPWDCMD -L`" 59154 else 59155 dir="`$DIRNAME "$path"`" 59156 base="`$BASENAME "$path"`" 59157 POTENTIAL_FREETYPE_INCLUDE_PATH="`cd "$dir"; $THEPWDCMD -L`/$base" 59158 fi 59159 fi 59160 fi 59161 59162 59163 # Only process if variable expands to non-empty 59164 59165 if test "x$POTENTIAL_FREETYPE_LIB_PATH" != x; then 59166 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 59167 59168 # Input might be given as Windows format, start by converting to 59169 # unix format. 59170 path="$POTENTIAL_FREETYPE_LIB_PATH" 59171 new_path=`$CYGPATH -u "$path"` 59172 59173 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 59174 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 59175 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 59176 # "foo.exe" is OK but "foo" is an error. 59177 # 59178 # This test is therefore slightly more accurate than "test -f" to check for file precense. 59179 # It is also a way to make sure we got the proper file name for the real test later on. 59180 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 59181 if test "x$test_shortpath" = x; then 59182 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&5 59183 $as_echo "$as_me: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&6;} 59184 as_fn_error $? "Cannot locate the the path of POTENTIAL_FREETYPE_LIB_PATH" "$LINENO" 5 59185 fi 59186 59187 # Call helper function which possibly converts this using DOS-style short mode. 59188 # If so, the updated path is stored in $new_path. 59189 59190 input_path="$new_path" 59191 # Check if we need to convert this using DOS-style short mode. If the path 59192 # contains just simple characters, use it. Otherwise (spaces, weird characters), 59193 # take no chances and rewrite it. 59194 # Note: m4 eats our [], so we need to use [ and ] instead. 59195 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 59196 if test "x$has_forbidden_chars" != x; then 59197 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 59198 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 59199 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 59200 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 59201 # Going to short mode and back again did indeed matter. Since short mode is 59202 # case insensitive, let's make it lowercase to improve readability. 59203 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 59204 # Now convert it back to Unix-style (cygpath) 59205 input_path=`$CYGPATH -u "$shortmode_path"` 59206 new_path="$input_path" 59207 fi 59208 fi 59209 59210 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 59211 if test "x$test_cygdrive_prefix" = x; then 59212 # As a simple fix, exclude /usr/bin since it's not a real path. 59213 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 59214 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 59215 # a path prefixed by /cygdrive for fixpath to work. 59216 new_path="$CYGWIN_ROOT_PATH$input_path" 59217 fi 59218 fi 59219 59220 59221 if test "x$path" != "x$new_path"; then 59222 POTENTIAL_FREETYPE_LIB_PATH="$new_path" 59223 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&5 59224 $as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&6;} 59225 fi 59226 59227 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 59228 59229 path="$POTENTIAL_FREETYPE_LIB_PATH" 59230 has_colon=`$ECHO $path | $GREP ^.:` 59231 new_path="$path" 59232 if test "x$has_colon" = x; then 59233 # Not in mixed or Windows style, start by that. 59234 new_path=`cmd //c echo $path` 59235 fi 59236 59237 59238 input_path="$new_path" 59239 # Check if we need to convert this using DOS-style short mode. If the path 59240 # contains just simple characters, use it. Otherwise (spaces, weird characters), 59241 # take no chances and rewrite it. 59242 # Note: m4 eats our [], so we need to use [ and ] instead. 59243 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 59244 if test "x$has_forbidden_chars" != x; then 59245 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 59246 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 59247 fi 59248 59249 59250 windows_path="$new_path" 59251 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 59252 unix_path=`$CYGPATH -u "$windows_path"` 59253 new_path="$unix_path" 59254 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 59255 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 59256 new_path="$unix_path" 59257 fi 59258 59259 if test "x$path" != "x$new_path"; then 59260 POTENTIAL_FREETYPE_LIB_PATH="$new_path" 59261 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&5 59262 $as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&6;} 59263 fi 59264 59265 # Save the first 10 bytes of this path to the storage, so fixpath can work. 59266 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 59267 59268 else 59269 # We're on a unix platform. Hooray! :) 59270 path="$POTENTIAL_FREETYPE_LIB_PATH" 59271 has_space=`$ECHO "$path" | $GREP " "` 59272 if test "x$has_space" != x; then 59273 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&5 59274 $as_echo "$as_me: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&6;} 59275 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 59276 fi 59277 59278 # Use eval to expand a potential ~ 59279 eval path="$path" 59280 if test ! -f "$path" && test ! -d "$path"; then 59281 as_fn_error $? "The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is not found." "$LINENO" 5 59282 fi 59283 59284 if test -d "$path"; then 59285 POTENTIAL_FREETYPE_LIB_PATH="`cd "$path"; $THEPWDCMD -L`" 59286 else 59287 dir="`$DIRNAME "$path"`" 59288 base="`$BASENAME "$path"`" 59289 POTENTIAL_FREETYPE_LIB_PATH="`cd "$dir"; $THEPWDCMD -L`/$base" 59290 fi 59291 fi 59292 fi 59293 59294 59295 FREETYPE_INCLUDE_PATH="$POTENTIAL_FREETYPE_INCLUDE_PATH" 59296 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for freetype includes" >&5 59297 $as_echo_n "checking for freetype includes... " >&6; } 59298 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $FREETYPE_INCLUDE_PATH" >&5 59299 $as_echo "$FREETYPE_INCLUDE_PATH" >&6; } 59300 FREETYPE_LIB_PATH="$POTENTIAL_FREETYPE_LIB_PATH" 59301 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for freetype libraries" >&5 59302 $as_echo_n "checking for freetype libraries... " >&6; } 59303 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $FREETYPE_LIB_PATH" >&5 59304 $as_echo "$FREETYPE_LIB_PATH" >&6; } 59305 fi 59306 59307 fi 59308 if test "x$FOUND_FREETYPE" != xyes && test -d $FREETYPE_BASE_DIR \ 59309 && test -s "$FREETYPE_BASE_DIR/builds/windows/vc2010/freetype.vcxproj" && test "x$MSBUILD" != x; then 59310 # Source is available, as a last resort try to build freetype in default location 59311 59312 FREETYPE_SRC_PATH="$FREETYPE_BASE_DIR" 59313 BUILD_FREETYPE=yes 59314 59315 # Check if the freetype sources are acessible.. 59316 if ! test -d $FREETYPE_SRC_PATH; then 59317 { $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 59318 $as_echo "$as_me: WARNING: --with-freetype-src specified, but can not find path \"$FREETYPE_SRC_PATH\" - ignoring --with-freetype-src" >&2;} 59319 BUILD_FREETYPE=no 59320 fi 59321 # ..and contain a vc2010 project file 59322 vcxproj_path="$FREETYPE_SRC_PATH/builds/windows/vc2010/freetype.vcxproj" 59323 if test "x$BUILD_FREETYPE" = xyes && ! test -s $vcxproj_path; then 59324 { $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 59325 $as_echo "$as_me: WARNING: Can not find project file $vcxproj_path (you may try a newer freetype version) - ignoring --with-freetype-src" >&2;} 59326 BUILD_FREETYPE=no 59327 fi 59328 # Now check if configure found a version of 'msbuild.exe' 59329 if test "x$BUILD_FREETYPE" = xyes && test "x$MSBUILD" == x ; then 59330 { $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 59331 $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;} 59332 BUILD_FREETYPE=no 59333 fi 59334 59335 # Ready to go.. 59336 if test "x$BUILD_FREETYPE" = xyes; then 59337 # msbuild requires trailing slashes for output directories 59338 freetype_lib_path="$FREETYPE_SRC_PATH/lib$OPENJDK_TARGET_CPU_BITS/" 59339 freetype_lib_path_unix="$freetype_lib_path" 59340 freetype_obj_path="$FREETYPE_SRC_PATH/obj$OPENJDK_TARGET_CPU_BITS/" 59341 59342 unix_path="$vcxproj_path" 59343 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 59344 windows_path=`$CYGPATH -m "$unix_path"` 59345 vcxproj_path="$windows_path" 59346 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 59347 windows_path=`cmd //c echo $unix_path` 59348 vcxproj_path="$windows_path" 59349 fi 59350 59351 59352 unix_path="$freetype_lib_path" 59353 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 59354 windows_path=`$CYGPATH -m "$unix_path"` 59355 freetype_lib_path="$windows_path" 59356 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 59357 windows_path=`cmd //c echo $unix_path` 59358 freetype_lib_path="$windows_path" 59359 fi 59360 59361 59362 unix_path="$freetype_obj_path" 59363 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 59364 windows_path=`$CYGPATH -m "$unix_path"` 59365 freetype_obj_path="$windows_path" 59366 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 59367 windows_path=`cmd //c echo $unix_path` 59368 freetype_obj_path="$windows_path" 59369 fi 59370 59371 if test "x$OPENJDK_TARGET_CPU_BITS" = x64; then 59372 freetype_platform=x64 59373 else 59374 freetype_platform=win32 59375 fi 59376 59377 # The original freetype project file is for VS 2010 (i.e. 'v100'), 59378 # so we have to adapt the toolset if building with any other toolsed (i.e. SDK). 59379 # Currently 'PLATFORM_TOOLSET' is set in 'TOOLCHAIN_CHECK_POSSIBLE_VISUAL_STUDIO_ROOT'/ 59380 # 'TOOLCHAIN_CHECK_POSSIBLE_WIN_SDK_ROOT' in toolchain_windows.m4 59381 { $as_echo "$as_me:${as_lineno-$LINENO}: Trying to compile freetype sources with PlatformToolset=$PLATFORM_TOOLSET to $freetype_lib_path_unix ..." >&5 59382 $as_echo "$as_me: Trying to compile freetype sources with PlatformToolset=$PLATFORM_TOOLSET to $freetype_lib_path_unix ..." >&6;} 59383 59384 # First we try to build the freetype.dll 59385 $ECHO -e "@echo off\n"\ 59386 "$MSBUILD $vcxproj_path "\ 59387 "/p:PlatformToolset=$PLATFORM_TOOLSET "\ 59388 "/p:Configuration=\"Release Multithreaded\" "\ 59389 "/p:Platform=$freetype_platform "\ 59390 "/p:ConfigurationType=DynamicLibrary "\ 59391 "/p:TargetName=freetype "\ 59392 "/p:OutDir=\"$freetype_lib_path\" "\ 59393 "/p:IntDir=\"$freetype_obj_path\" > freetype.log" > freetype.bat 59394 cmd /c freetype.bat 59395 59396 if test -s "$freetype_lib_path_unix/freetype.dll"; then 59397 # If that succeeds we also build freetype.lib 59398 $ECHO -e "@echo off\n"\ 59399 "$MSBUILD $vcxproj_path "\ 59400 "/p:PlatformToolset=$PLATFORM_TOOLSET "\ 59401 "/p:Configuration=\"Release Multithreaded\" "\ 59402 "/p:Platform=$freetype_platform "\ 59403 "/p:ConfigurationType=StaticLibrary "\ 59404 "/p:TargetName=freetype "\ 59405 "/p:OutDir=\"$freetype_lib_path\" "\ 59406 "/p:IntDir=\"$freetype_obj_path\" >> freetype.log" > freetype.bat 59407 cmd /c freetype.bat 59408 59409 if test -s "$freetype_lib_path_unix/freetype.lib"; then 59410 # Once we build both, lib and dll, set freetype lib and include path appropriately 59411 POTENTIAL_FREETYPE_INCLUDE_PATH="$FREETYPE_SRC_PATH/include" 59412 POTENTIAL_FREETYPE_LIB_PATH="$freetype_lib_path_unix" 59413 { $as_echo "$as_me:${as_lineno-$LINENO}: Compiling freetype sources succeeded! (see freetype.log for build results)" >&5 59414 $as_echo "$as_me: Compiling freetype sources succeeded! (see freetype.log for build results)" >&6;} 59415 else 59416 BUILD_FREETYPE=no 59417 fi 59418 else 59419 BUILD_FREETYPE=no 59420 fi 59421 fi 59422 59423 if test "x$OPENJDK_TARGET_CPU_BITS" = x64; then 59424 59425 POTENTIAL_FREETYPE_INCLUDE_PATH="$FREETYPE_BASE_DIR/include" 59426 POTENTIAL_FREETYPE_LIB_PATH="$FREETYPE_BASE_DIR/lib64" 59427 METHOD="well-known location" 59428 59429 # Let's start with an optimistic view of the world :-) 59430 FOUND_FREETYPE=yes 59431 59432 # First look for the canonical freetype main include file ft2build.h. 59433 if ! test -s "$POTENTIAL_FREETYPE_INCLUDE_PATH/ft2build.h"; then 59434 # Oh no! Let's try in the freetype2 directory. This is needed at least at Mac OS X Yosemite. 59435 POTENTIAL_FREETYPE_INCLUDE_PATH="$POTENTIAL_FREETYPE_INCLUDE_PATH/freetype2" 59436 if ! test -s "$POTENTIAL_FREETYPE_INCLUDE_PATH/ft2build.h"; then 59437 # Fail. 59438 FOUND_FREETYPE=no 59439 fi 59440 fi 59441 59442 if test "x$FOUND_FREETYPE" = xyes; then 59443 # Include file found, let's continue the sanity check. 59444 { $as_echo "$as_me:${as_lineno-$LINENO}: Found freetype include files at $POTENTIAL_FREETYPE_INCLUDE_PATH using $METHOD" >&5 59445 $as_echo "$as_me: Found freetype include files at $POTENTIAL_FREETYPE_INCLUDE_PATH using $METHOD" >&6;} 59446 59447 # Reset to default value 59448 FREETYPE_BASE_NAME=freetype 59449 FREETYPE_LIB_NAME="${LIBRARY_PREFIX}${FREETYPE_BASE_NAME}${SHARED_LIBRARY_SUFFIX}" 59450 if ! test -s "$POTENTIAL_FREETYPE_LIB_PATH/$FREETYPE_LIB_NAME"; then 59451 if test "x$OPENJDK_TARGET_OS" = xmacosx \ 59452 && test -s "$POTENTIAL_FREETYPE_LIB_PATH/${LIBRARY_PREFIX}freetype.6${SHARED_LIBRARY_SUFFIX}"; then 59453 # On Mac OS X Yosemite, the symlink from libfreetype.dylib to libfreetype.6.dylib disappeared. Check 59454 # for the .6 version explicitly. 59455 FREETYPE_BASE_NAME=freetype.6 59456 FREETYPE_LIB_NAME="${LIBRARY_PREFIX}${FREETYPE_BASE_NAME}${SHARED_LIBRARY_SUFFIX}" 59457 { $as_echo "$as_me:${as_lineno-$LINENO}: Compensating for missing symlink by using version 6 explicitly" >&5 59458 $as_echo "$as_me: Compensating for missing symlink by using version 6 explicitly" >&6;} 59459 else 59460 { $as_echo "$as_me:${as_lineno-$LINENO}: Could not find $POTENTIAL_FREETYPE_LIB_PATH/$FREETYPE_LIB_NAME. Ignoring location." >&5 59461 $as_echo "$as_me: Could not find $POTENTIAL_FREETYPE_LIB_PATH/$FREETYPE_LIB_NAME. Ignoring location." >&6;} 59462 FOUND_FREETYPE=no 59463 fi 59464 else 59465 if test "x$OPENJDK_TARGET_OS" = xwindows; then 59466 # On Windows, we will need both .lib and .dll file. 59467 if ! test -s "$POTENTIAL_FREETYPE_LIB_PATH/${FREETYPE_BASE_NAME}.lib"; then 59468 { $as_echo "$as_me:${as_lineno-$LINENO}: Could not find $POTENTIAL_FREETYPE_LIB_PATH/${FREETYPE_BASE_NAME}.lib. Ignoring location." >&5 59469 $as_echo "$as_me: Could not find $POTENTIAL_FREETYPE_LIB_PATH/${FREETYPE_BASE_NAME}.lib. Ignoring location." >&6;} 59470 FOUND_FREETYPE=no 59471 fi 59472 elif test "x$OPENJDK_TARGET_OS" = xsolaris \ 59473 && test -s "$POTENTIAL_FREETYPE_LIB_PATH$OPENJDK_TARGET_CPU_ISADIR/$FREETYPE_LIB_NAME"; then 59474 # Found lib in isa dir, use that instead. 59475 POTENTIAL_FREETYPE_LIB_PATH="$POTENTIAL_FREETYPE_LIB_PATH$OPENJDK_TARGET_CPU_ISADIR" 59476 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting to use $POTENTIAL_FREETYPE_LIB_PATH instead" >&5 59477 $as_echo "$as_me: Rewriting to use $POTENTIAL_FREETYPE_LIB_PATH instead" >&6;} 59478 fi 59479 fi 59480 fi 59481 59482 if test "x$FOUND_FREETYPE" = xyes; then 59483 59484 # Only process if variable expands to non-empty 59485 59486 if test "x$POTENTIAL_FREETYPE_INCLUDE_PATH" != x; then 59487 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 59488 59489 # Input might be given as Windows format, start by converting to 59490 # unix format. 59491 path="$POTENTIAL_FREETYPE_INCLUDE_PATH" 59492 new_path=`$CYGPATH -u "$path"` 59493 59494 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 59495 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 59496 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 59497 # "foo.exe" is OK but "foo" is an error. 59498 # 59499 # This test is therefore slightly more accurate than "test -f" to check for file precense. 59500 # It is also a way to make sure we got the proper file name for the real test later on. 59501 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 59502 if test "x$test_shortpath" = x; then 59503 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&5 59504 $as_echo "$as_me: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&6;} 59505 as_fn_error $? "Cannot locate the the path of POTENTIAL_FREETYPE_INCLUDE_PATH" "$LINENO" 5 59506 fi 59507 59508 # Call helper function which possibly converts this using DOS-style short mode. 59509 # If so, the updated path is stored in $new_path. 59510 59511 input_path="$new_path" 59512 # Check if we need to convert this using DOS-style short mode. If the path 59513 # contains just simple characters, use it. Otherwise (spaces, weird characters), 59514 # take no chances and rewrite it. 59515 # Note: m4 eats our [], so we need to use [ and ] instead. 59516 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 59517 if test "x$has_forbidden_chars" != x; then 59518 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 59519 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 59520 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 59521 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 59522 # Going to short mode and back again did indeed matter. Since short mode is 59523 # case insensitive, let's make it lowercase to improve readability. 59524 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 59525 # Now convert it back to Unix-style (cygpath) 59526 input_path=`$CYGPATH -u "$shortmode_path"` 59527 new_path="$input_path" 59528 fi 59529 fi 59530 59531 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 59532 if test "x$test_cygdrive_prefix" = x; then 59533 # As a simple fix, exclude /usr/bin since it's not a real path. 59534 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 59535 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 59536 # a path prefixed by /cygdrive for fixpath to work. 59537 new_path="$CYGWIN_ROOT_PATH$input_path" 59538 fi 59539 fi 59540 59541 59542 if test "x$path" != "x$new_path"; then 59543 POTENTIAL_FREETYPE_INCLUDE_PATH="$new_path" 59544 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&5 59545 $as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&6;} 59546 fi 59547 59548 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 59549 59550 path="$POTENTIAL_FREETYPE_INCLUDE_PATH" 59551 has_colon=`$ECHO $path | $GREP ^.:` 59552 new_path="$path" 59553 if test "x$has_colon" = x; then 59554 # Not in mixed or Windows style, start by that. 59555 new_path=`cmd //c echo $path` 59556 fi 59557 59558 59559 input_path="$new_path" 59560 # Check if we need to convert this using DOS-style short mode. If the path 59561 # contains just simple characters, use it. Otherwise (spaces, weird characters), 59562 # take no chances and rewrite it. 59563 # Note: m4 eats our [], so we need to use [ and ] instead. 59564 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 59565 if test "x$has_forbidden_chars" != x; then 59566 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 59567 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 59568 fi 59569 59570 59571 windows_path="$new_path" 59572 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 59573 unix_path=`$CYGPATH -u "$windows_path"` 59574 new_path="$unix_path" 59575 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 59576 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 59577 new_path="$unix_path" 59578 fi 59579 59580 if test "x$path" != "x$new_path"; then 59581 POTENTIAL_FREETYPE_INCLUDE_PATH="$new_path" 59582 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&5 59583 $as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&6;} 59584 fi 59585 59586 # Save the first 10 bytes of this path to the storage, so fixpath can work. 59587 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 59588 59589 else 59590 # We're on a unix platform. Hooray! :) 59591 path="$POTENTIAL_FREETYPE_INCLUDE_PATH" 59592 has_space=`$ECHO "$path" | $GREP " "` 59593 if test "x$has_space" != x; then 59594 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&5 59595 $as_echo "$as_me: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&6;} 59596 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 59597 fi 59598 59599 # Use eval to expand a potential ~ 59600 eval path="$path" 59601 if test ! -f "$path" && test ! -d "$path"; then 59602 as_fn_error $? "The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is not found." "$LINENO" 5 59603 fi 59604 59605 if test -d "$path"; then 59606 POTENTIAL_FREETYPE_INCLUDE_PATH="`cd "$path"; $THEPWDCMD -L`" 59607 else 59608 dir="`$DIRNAME "$path"`" 59609 base="`$BASENAME "$path"`" 59610 POTENTIAL_FREETYPE_INCLUDE_PATH="`cd "$dir"; $THEPWDCMD -L`/$base" 59611 fi 59612 fi 59613 fi 59614 59615 59616 # Only process if variable expands to non-empty 59617 59618 if test "x$POTENTIAL_FREETYPE_LIB_PATH" != x; then 59619 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 59620 59621 # Input might be given as Windows format, start by converting to 59622 # unix format. 59623 path="$POTENTIAL_FREETYPE_LIB_PATH" 59624 new_path=`$CYGPATH -u "$path"` 59625 59626 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 59627 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 59628 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 59629 # "foo.exe" is OK but "foo" is an error. 59630 # 59631 # This test is therefore slightly more accurate than "test -f" to check for file precense. 59632 # It is also a way to make sure we got the proper file name for the real test later on. 59633 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 59634 if test "x$test_shortpath" = x; then 59635 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&5 59636 $as_echo "$as_me: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&6;} 59637 as_fn_error $? "Cannot locate the the path of POTENTIAL_FREETYPE_LIB_PATH" "$LINENO" 5 59638 fi 59639 59640 # Call helper function which possibly converts this using DOS-style short mode. 59641 # If so, the updated path is stored in $new_path. 59642 59643 input_path="$new_path" 59644 # Check if we need to convert this using DOS-style short mode. If the path 59645 # contains just simple characters, use it. Otherwise (spaces, weird characters), 59646 # take no chances and rewrite it. 59647 # Note: m4 eats our [], so we need to use [ and ] instead. 59648 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 59649 if test "x$has_forbidden_chars" != x; then 59650 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 59651 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 59652 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 59653 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 59654 # Going to short mode and back again did indeed matter. Since short mode is 59655 # case insensitive, let's make it lowercase to improve readability. 59656 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 59657 # Now convert it back to Unix-style (cygpath) 59658 input_path=`$CYGPATH -u "$shortmode_path"` 59659 new_path="$input_path" 59660 fi 59661 fi 59662 59663 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 59664 if test "x$test_cygdrive_prefix" = x; then 59665 # As a simple fix, exclude /usr/bin since it's not a real path. 59666 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 59667 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 59668 # a path prefixed by /cygdrive for fixpath to work. 59669 new_path="$CYGWIN_ROOT_PATH$input_path" 59670 fi 59671 fi 59672 59673 59674 if test "x$path" != "x$new_path"; then 59675 POTENTIAL_FREETYPE_LIB_PATH="$new_path" 59676 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&5 59677 $as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&6;} 59678 fi 59679 59680 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 59681 59682 path="$POTENTIAL_FREETYPE_LIB_PATH" 59683 has_colon=`$ECHO $path | $GREP ^.:` 59684 new_path="$path" 59685 if test "x$has_colon" = x; then 59686 # Not in mixed or Windows style, start by that. 59687 new_path=`cmd //c echo $path` 59688 fi 59689 59690 59691 input_path="$new_path" 59692 # Check if we need to convert this using DOS-style short mode. If the path 59693 # contains just simple characters, use it. Otherwise (spaces, weird characters), 59694 # take no chances and rewrite it. 59695 # Note: m4 eats our [], so we need to use [ and ] instead. 59696 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 59697 if test "x$has_forbidden_chars" != x; then 59698 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 59699 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 59700 fi 59701 59702 59703 windows_path="$new_path" 59704 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 59705 unix_path=`$CYGPATH -u "$windows_path"` 59706 new_path="$unix_path" 59707 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 59708 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 59709 new_path="$unix_path" 59710 fi 59711 59712 if test "x$path" != "x$new_path"; then 59713 POTENTIAL_FREETYPE_LIB_PATH="$new_path" 59714 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&5 59715 $as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&6;} 59716 fi 59717 59718 # Save the first 10 bytes of this path to the storage, so fixpath can work. 59719 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 59720 59721 else 59722 # We're on a unix platform. Hooray! :) 59723 path="$POTENTIAL_FREETYPE_LIB_PATH" 59724 has_space=`$ECHO "$path" | $GREP " "` 59725 if test "x$has_space" != x; then 59726 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&5 59727 $as_echo "$as_me: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&6;} 59728 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 59729 fi 59730 59731 # Use eval to expand a potential ~ 59732 eval path="$path" 59733 if test ! -f "$path" && test ! -d "$path"; then 59734 as_fn_error $? "The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is not found." "$LINENO" 5 59735 fi 59736 59737 if test -d "$path"; then 59738 POTENTIAL_FREETYPE_LIB_PATH="`cd "$path"; $THEPWDCMD -L`" 59739 else 59740 dir="`$DIRNAME "$path"`" 59741 base="`$BASENAME "$path"`" 59742 POTENTIAL_FREETYPE_LIB_PATH="`cd "$dir"; $THEPWDCMD -L`/$base" 59743 fi 59744 fi 59745 fi 59746 59747 59748 FREETYPE_INCLUDE_PATH="$POTENTIAL_FREETYPE_INCLUDE_PATH" 59749 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for freetype includes" >&5 59750 $as_echo_n "checking for freetype includes... " >&6; } 59751 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $FREETYPE_INCLUDE_PATH" >&5 59752 $as_echo "$FREETYPE_INCLUDE_PATH" >&6; } 59753 FREETYPE_LIB_PATH="$POTENTIAL_FREETYPE_LIB_PATH" 59754 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for freetype libraries" >&5 59755 $as_echo_n "checking for freetype libraries... " >&6; } 59756 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $FREETYPE_LIB_PATH" >&5 59757 $as_echo "$FREETYPE_LIB_PATH" >&6; } 59758 fi 59759 59760 else 59761 59762 POTENTIAL_FREETYPE_INCLUDE_PATH="$FREETYPE_BASE_DIR/include" 59763 POTENTIAL_FREETYPE_LIB_PATH="$FREETYPE_BASE_DIR/lib32" 59764 METHOD="well-known location" 59765 59766 # Let's start with an optimistic view of the world :-) 59767 FOUND_FREETYPE=yes 59768 59769 # First look for the canonical freetype main include file ft2build.h. 59770 if ! test -s "$POTENTIAL_FREETYPE_INCLUDE_PATH/ft2build.h"; then 59771 # Oh no! Let's try in the freetype2 directory. This is needed at least at Mac OS X Yosemite. 59772 POTENTIAL_FREETYPE_INCLUDE_PATH="$POTENTIAL_FREETYPE_INCLUDE_PATH/freetype2" 59773 if ! test -s "$POTENTIAL_FREETYPE_INCLUDE_PATH/ft2build.h"; then 59774 # Fail. 59775 FOUND_FREETYPE=no 59776 fi 59777 fi 59778 59779 if test "x$FOUND_FREETYPE" = xyes; then 59780 # Include file found, let's continue the sanity check. 59781 { $as_echo "$as_me:${as_lineno-$LINENO}: Found freetype include files at $POTENTIAL_FREETYPE_INCLUDE_PATH using $METHOD" >&5 59782 $as_echo "$as_me: Found freetype include files at $POTENTIAL_FREETYPE_INCLUDE_PATH using $METHOD" >&6;} 59783 59784 # Reset to default value 59785 FREETYPE_BASE_NAME=freetype 59786 FREETYPE_LIB_NAME="${LIBRARY_PREFIX}${FREETYPE_BASE_NAME}${SHARED_LIBRARY_SUFFIX}" 59787 if ! test -s "$POTENTIAL_FREETYPE_LIB_PATH/$FREETYPE_LIB_NAME"; then 59788 if test "x$OPENJDK_TARGET_OS" = xmacosx \ 59789 && test -s "$POTENTIAL_FREETYPE_LIB_PATH/${LIBRARY_PREFIX}freetype.6${SHARED_LIBRARY_SUFFIX}"; then 59790 # On Mac OS X Yosemite, the symlink from libfreetype.dylib to libfreetype.6.dylib disappeared. Check 59791 # for the .6 version explicitly. 59792 FREETYPE_BASE_NAME=freetype.6 59793 FREETYPE_LIB_NAME="${LIBRARY_PREFIX}${FREETYPE_BASE_NAME}${SHARED_LIBRARY_SUFFIX}" 59794 { $as_echo "$as_me:${as_lineno-$LINENO}: Compensating for missing symlink by using version 6 explicitly" >&5 59795 $as_echo "$as_me: Compensating for missing symlink by using version 6 explicitly" >&6;} 59796 else 59797 { $as_echo "$as_me:${as_lineno-$LINENO}: Could not find $POTENTIAL_FREETYPE_LIB_PATH/$FREETYPE_LIB_NAME. Ignoring location." >&5 59798 $as_echo "$as_me: Could not find $POTENTIAL_FREETYPE_LIB_PATH/$FREETYPE_LIB_NAME. Ignoring location." >&6;} 59799 FOUND_FREETYPE=no 59800 fi 59801 else 59802 if test "x$OPENJDK_TARGET_OS" = xwindows; then 59803 # On Windows, we will need both .lib and .dll file. 59804 if ! test -s "$POTENTIAL_FREETYPE_LIB_PATH/${FREETYPE_BASE_NAME}.lib"; then 59805 { $as_echo "$as_me:${as_lineno-$LINENO}: Could not find $POTENTIAL_FREETYPE_LIB_PATH/${FREETYPE_BASE_NAME}.lib. Ignoring location." >&5 59806 $as_echo "$as_me: Could not find $POTENTIAL_FREETYPE_LIB_PATH/${FREETYPE_BASE_NAME}.lib. Ignoring location." >&6;} 59807 FOUND_FREETYPE=no 59808 fi 59809 elif test "x$OPENJDK_TARGET_OS" = xsolaris \ 59810 && test -s "$POTENTIAL_FREETYPE_LIB_PATH$OPENJDK_TARGET_CPU_ISADIR/$FREETYPE_LIB_NAME"; then 59811 # Found lib in isa dir, use that instead. 59812 POTENTIAL_FREETYPE_LIB_PATH="$POTENTIAL_FREETYPE_LIB_PATH$OPENJDK_TARGET_CPU_ISADIR" 59813 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting to use $POTENTIAL_FREETYPE_LIB_PATH instead" >&5 59814 $as_echo "$as_me: Rewriting to use $POTENTIAL_FREETYPE_LIB_PATH instead" >&6;} 59815 fi 59816 fi 59817 fi 59818 59819 if test "x$FOUND_FREETYPE" = xyes; then 59820 59821 # Only process if variable expands to non-empty 59822 59823 if test "x$POTENTIAL_FREETYPE_INCLUDE_PATH" != x; then 59824 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 59825 59826 # Input might be given as Windows format, start by converting to 59827 # unix format. 59828 path="$POTENTIAL_FREETYPE_INCLUDE_PATH" 59829 new_path=`$CYGPATH -u "$path"` 59830 59831 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 59832 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 59833 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 59834 # "foo.exe" is OK but "foo" is an error. 59835 # 59836 # This test is therefore slightly more accurate than "test -f" to check for file precense. 59837 # It is also a way to make sure we got the proper file name for the real test later on. 59838 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 59839 if test "x$test_shortpath" = x; then 59840 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&5 59841 $as_echo "$as_me: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&6;} 59842 as_fn_error $? "Cannot locate the the path of POTENTIAL_FREETYPE_INCLUDE_PATH" "$LINENO" 5 59843 fi 59844 59845 # Call helper function which possibly converts this using DOS-style short mode. 59846 # If so, the updated path is stored in $new_path. 59847 59848 input_path="$new_path" 59849 # Check if we need to convert this using DOS-style short mode. If the path 59850 # contains just simple characters, use it. Otherwise (spaces, weird characters), 59851 # take no chances and rewrite it. 59852 # Note: m4 eats our [], so we need to use [ and ] instead. 59853 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 59854 if test "x$has_forbidden_chars" != x; then 59855 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 59856 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 59857 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 59858 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 59859 # Going to short mode and back again did indeed matter. Since short mode is 59860 # case insensitive, let's make it lowercase to improve readability. 59861 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 59862 # Now convert it back to Unix-style (cygpath) 59863 input_path=`$CYGPATH -u "$shortmode_path"` 59864 new_path="$input_path" 59865 fi 59866 fi 59867 59868 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 59869 if test "x$test_cygdrive_prefix" = x; then 59870 # As a simple fix, exclude /usr/bin since it's not a real path. 59871 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 59872 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 59873 # a path prefixed by /cygdrive for fixpath to work. 59874 new_path="$CYGWIN_ROOT_PATH$input_path" 59875 fi 59876 fi 59877 59878 59879 if test "x$path" != "x$new_path"; then 59880 POTENTIAL_FREETYPE_INCLUDE_PATH="$new_path" 59881 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&5 59882 $as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&6;} 59883 fi 59884 59885 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 59886 59887 path="$POTENTIAL_FREETYPE_INCLUDE_PATH" 59888 has_colon=`$ECHO $path | $GREP ^.:` 59889 new_path="$path" 59890 if test "x$has_colon" = x; then 59891 # Not in mixed or Windows style, start by that. 59892 new_path=`cmd //c echo $path` 59893 fi 59894 59895 59896 input_path="$new_path" 59897 # Check if we need to convert this using DOS-style short mode. If the path 59898 # contains just simple characters, use it. Otherwise (spaces, weird characters), 59899 # take no chances and rewrite it. 59900 # Note: m4 eats our [], so we need to use [ and ] instead. 59901 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 59902 if test "x$has_forbidden_chars" != x; then 59903 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 59904 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 59905 fi 59906 59907 59908 windows_path="$new_path" 59909 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 59910 unix_path=`$CYGPATH -u "$windows_path"` 59911 new_path="$unix_path" 59912 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 59913 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 59914 new_path="$unix_path" 59915 fi 59916 59917 if test "x$path" != "x$new_path"; then 59918 POTENTIAL_FREETYPE_INCLUDE_PATH="$new_path" 59919 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&5 59920 $as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&6;} 59921 fi 59922 59923 # Save the first 10 bytes of this path to the storage, so fixpath can work. 59924 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 59925 59926 else 59927 # We're on a unix platform. Hooray! :) 59928 path="$POTENTIAL_FREETYPE_INCLUDE_PATH" 59929 has_space=`$ECHO "$path" | $GREP " "` 59930 if test "x$has_space" != x; then 59931 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&5 59932 $as_echo "$as_me: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&6;} 59933 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 59934 fi 59935 59936 # Use eval to expand a potential ~ 59937 eval path="$path" 59938 if test ! -f "$path" && test ! -d "$path"; then 59939 as_fn_error $? "The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is not found." "$LINENO" 5 59940 fi 59941 59942 if test -d "$path"; then 59943 POTENTIAL_FREETYPE_INCLUDE_PATH="`cd "$path"; $THEPWDCMD -L`" 59944 else 59945 dir="`$DIRNAME "$path"`" 59946 base="`$BASENAME "$path"`" 59947 POTENTIAL_FREETYPE_INCLUDE_PATH="`cd "$dir"; $THEPWDCMD -L`/$base" 59948 fi 59949 fi 59950 fi 59951 59952 59953 # Only process if variable expands to non-empty 59954 59955 if test "x$POTENTIAL_FREETYPE_LIB_PATH" != x; then 59956 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 59957 59958 # Input might be given as Windows format, start by converting to 59959 # unix format. 59960 path="$POTENTIAL_FREETYPE_LIB_PATH" 59961 new_path=`$CYGPATH -u "$path"` 59962 59963 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 59964 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 59965 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 59966 # "foo.exe" is OK but "foo" is an error. 59967 # 59968 # This test is therefore slightly more accurate than "test -f" to check for file precense. 59969 # It is also a way to make sure we got the proper file name for the real test later on. 59970 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 59971 if test "x$test_shortpath" = x; then 59972 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&5 59973 $as_echo "$as_me: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&6;} 59974 as_fn_error $? "Cannot locate the the path of POTENTIAL_FREETYPE_LIB_PATH" "$LINENO" 5 59975 fi 59976 59977 # Call helper function which possibly converts this using DOS-style short mode. 59978 # If so, the updated path is stored in $new_path. 59979 59980 input_path="$new_path" 59981 # Check if we need to convert this using DOS-style short mode. If the path 59982 # contains just simple characters, use it. Otherwise (spaces, weird characters), 59983 # take no chances and rewrite it. 59984 # Note: m4 eats our [], so we need to use [ and ] instead. 59985 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 59986 if test "x$has_forbidden_chars" != x; then 59987 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 59988 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 59989 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 59990 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 59991 # Going to short mode and back again did indeed matter. Since short mode is 59992 # case insensitive, let's make it lowercase to improve readability. 59993 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 59994 # Now convert it back to Unix-style (cygpath) 59995 input_path=`$CYGPATH -u "$shortmode_path"` 59996 new_path="$input_path" 59997 fi 59998 fi 59999 60000 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 60001 if test "x$test_cygdrive_prefix" = x; then 60002 # As a simple fix, exclude /usr/bin since it's not a real path. 60003 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 60004 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 60005 # a path prefixed by /cygdrive for fixpath to work. 60006 new_path="$CYGWIN_ROOT_PATH$input_path" 60007 fi 60008 fi 60009 60010 60011 if test "x$path" != "x$new_path"; then 60012 POTENTIAL_FREETYPE_LIB_PATH="$new_path" 60013 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&5 60014 $as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&6;} 60015 fi 60016 60017 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 60018 60019 path="$POTENTIAL_FREETYPE_LIB_PATH" 60020 has_colon=`$ECHO $path | $GREP ^.:` 60021 new_path="$path" 60022 if test "x$has_colon" = x; then 60023 # Not in mixed or Windows style, start by that. 60024 new_path=`cmd //c echo $path` 60025 fi 60026 60027 60028 input_path="$new_path" 60029 # Check if we need to convert this using DOS-style short mode. If the path 60030 # contains just simple characters, use it. Otherwise (spaces, weird characters), 60031 # take no chances and rewrite it. 60032 # Note: m4 eats our [], so we need to use [ and ] instead. 60033 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 60034 if test "x$has_forbidden_chars" != x; then 60035 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 60036 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 60037 fi 60038 60039 60040 windows_path="$new_path" 60041 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 60042 unix_path=`$CYGPATH -u "$windows_path"` 60043 new_path="$unix_path" 60044 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 60045 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 60046 new_path="$unix_path" 60047 fi 60048 60049 if test "x$path" != "x$new_path"; then 60050 POTENTIAL_FREETYPE_LIB_PATH="$new_path" 60051 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&5 60052 $as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&6;} 60053 fi 60054 60055 # Save the first 10 bytes of this path to the storage, so fixpath can work. 60056 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 60057 60058 else 60059 # We're on a unix platform. Hooray! :) 60060 path="$POTENTIAL_FREETYPE_LIB_PATH" 60061 has_space=`$ECHO "$path" | $GREP " "` 60062 if test "x$has_space" != x; then 60063 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&5 60064 $as_echo "$as_me: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&6;} 60065 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 60066 fi 60067 60068 # Use eval to expand a potential ~ 60069 eval path="$path" 60070 if test ! -f "$path" && test ! -d "$path"; then 60071 as_fn_error $? "The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is not found." "$LINENO" 5 60072 fi 60073 60074 if test -d "$path"; then 60075 POTENTIAL_FREETYPE_LIB_PATH="`cd "$path"; $THEPWDCMD -L`" 60076 else 60077 dir="`$DIRNAME "$path"`" 60078 base="`$BASENAME "$path"`" 60079 POTENTIAL_FREETYPE_LIB_PATH="`cd "$dir"; $THEPWDCMD -L`/$base" 60080 fi 60081 fi 60082 fi 60083 60084 60085 FREETYPE_INCLUDE_PATH="$POTENTIAL_FREETYPE_INCLUDE_PATH" 60086 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for freetype includes" >&5 60087 $as_echo_n "checking for freetype includes... " >&6; } 60088 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $FREETYPE_INCLUDE_PATH" >&5 60089 $as_echo "$FREETYPE_INCLUDE_PATH" >&6; } 60090 FREETYPE_LIB_PATH="$POTENTIAL_FREETYPE_LIB_PATH" 60091 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for freetype libraries" >&5 60092 $as_echo_n "checking for freetype libraries... " >&6; } 60093 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $FREETYPE_LIB_PATH" >&5 60094 $as_echo "$FREETYPE_LIB_PATH" >&6; } 60095 fi 60096 60097 fi 60098 fi 60099 fi 60100 else 60101 FREETYPE_BASE_DIR="$SYSROOT/usr" 60102 60103 POTENTIAL_FREETYPE_INCLUDE_PATH="$FREETYPE_BASE_DIR/include" 60104 POTENTIAL_FREETYPE_LIB_PATH="$FREETYPE_BASE_DIR/lib" 60105 METHOD="well-known location" 60106 60107 # Let's start with an optimistic view of the world :-) 60108 FOUND_FREETYPE=yes 60109 60110 # First look for the canonical freetype main include file ft2build.h. 60111 if ! test -s "$POTENTIAL_FREETYPE_INCLUDE_PATH/ft2build.h"; then 60112 # Oh no! Let's try in the freetype2 directory. This is needed at least at Mac OS X Yosemite. 60113 POTENTIAL_FREETYPE_INCLUDE_PATH="$POTENTIAL_FREETYPE_INCLUDE_PATH/freetype2" 60114 if ! test -s "$POTENTIAL_FREETYPE_INCLUDE_PATH/ft2build.h"; then 60115 # Fail. 60116 FOUND_FREETYPE=no 60117 fi 60118 fi 60119 60120 if test "x$FOUND_FREETYPE" = xyes; then 60121 # Include file found, let's continue the sanity check. 60122 { $as_echo "$as_me:${as_lineno-$LINENO}: Found freetype include files at $POTENTIAL_FREETYPE_INCLUDE_PATH using $METHOD" >&5 60123 $as_echo "$as_me: Found freetype include files at $POTENTIAL_FREETYPE_INCLUDE_PATH using $METHOD" >&6;} 60124 60125 # Reset to default value 60126 FREETYPE_BASE_NAME=freetype 60127 FREETYPE_LIB_NAME="${LIBRARY_PREFIX}${FREETYPE_BASE_NAME}${SHARED_LIBRARY_SUFFIX}" 60128 if ! test -s "$POTENTIAL_FREETYPE_LIB_PATH/$FREETYPE_LIB_NAME"; then 60129 if test "x$OPENJDK_TARGET_OS" = xmacosx \ 60130 && test -s "$POTENTIAL_FREETYPE_LIB_PATH/${LIBRARY_PREFIX}freetype.6${SHARED_LIBRARY_SUFFIX}"; then 60131 # On Mac OS X Yosemite, the symlink from libfreetype.dylib to libfreetype.6.dylib disappeared. Check 60132 # for the .6 version explicitly. 60133 FREETYPE_BASE_NAME=freetype.6 60134 FREETYPE_LIB_NAME="${LIBRARY_PREFIX}${FREETYPE_BASE_NAME}${SHARED_LIBRARY_SUFFIX}" 60135 { $as_echo "$as_me:${as_lineno-$LINENO}: Compensating for missing symlink by using version 6 explicitly" >&5 60136 $as_echo "$as_me: Compensating for missing symlink by using version 6 explicitly" >&6;} 60137 else 60138 { $as_echo "$as_me:${as_lineno-$LINENO}: Could not find $POTENTIAL_FREETYPE_LIB_PATH/$FREETYPE_LIB_NAME. Ignoring location." >&5 60139 $as_echo "$as_me: Could not find $POTENTIAL_FREETYPE_LIB_PATH/$FREETYPE_LIB_NAME. Ignoring location." >&6;} 60140 FOUND_FREETYPE=no 60141 fi 60142 else 60143 if test "x$OPENJDK_TARGET_OS" = xwindows; then 60144 # On Windows, we will need both .lib and .dll file. 60145 if ! test -s "$POTENTIAL_FREETYPE_LIB_PATH/${FREETYPE_BASE_NAME}.lib"; then 60146 { $as_echo "$as_me:${as_lineno-$LINENO}: Could not find $POTENTIAL_FREETYPE_LIB_PATH/${FREETYPE_BASE_NAME}.lib. Ignoring location." >&5 60147 $as_echo "$as_me: Could not find $POTENTIAL_FREETYPE_LIB_PATH/${FREETYPE_BASE_NAME}.lib. Ignoring location." >&6;} 60148 FOUND_FREETYPE=no 60149 fi 60150 elif test "x$OPENJDK_TARGET_OS" = xsolaris \ 60151 && test -s "$POTENTIAL_FREETYPE_LIB_PATH$OPENJDK_TARGET_CPU_ISADIR/$FREETYPE_LIB_NAME"; then 60152 # Found lib in isa dir, use that instead. 60153 POTENTIAL_FREETYPE_LIB_PATH="$POTENTIAL_FREETYPE_LIB_PATH$OPENJDK_TARGET_CPU_ISADIR" 60154 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting to use $POTENTIAL_FREETYPE_LIB_PATH instead" >&5 60155 $as_echo "$as_me: Rewriting to use $POTENTIAL_FREETYPE_LIB_PATH instead" >&6;} 60156 fi 60157 fi 60158 fi 60159 60160 if test "x$FOUND_FREETYPE" = xyes; then 60161 60162 # Only process if variable expands to non-empty 60163 60164 if test "x$POTENTIAL_FREETYPE_INCLUDE_PATH" != x; then 60165 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 60166 60167 # Input might be given as Windows format, start by converting to 60168 # unix format. 60169 path="$POTENTIAL_FREETYPE_INCLUDE_PATH" 60170 new_path=`$CYGPATH -u "$path"` 60171 60172 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 60173 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 60174 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 60175 # "foo.exe" is OK but "foo" is an error. 60176 # 60177 # This test is therefore slightly more accurate than "test -f" to check for file precense. 60178 # It is also a way to make sure we got the proper file name for the real test later on. 60179 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 60180 if test "x$test_shortpath" = x; then 60181 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&5 60182 $as_echo "$as_me: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&6;} 60183 as_fn_error $? "Cannot locate the the path of POTENTIAL_FREETYPE_INCLUDE_PATH" "$LINENO" 5 60184 fi 60185 60186 # Call helper function which possibly converts this using DOS-style short mode. 60187 # If so, the updated path is stored in $new_path. 60188 60189 input_path="$new_path" 60190 # Check if we need to convert this using DOS-style short mode. If the path 60191 # contains just simple characters, use it. Otherwise (spaces, weird characters), 60192 # take no chances and rewrite it. 60193 # Note: m4 eats our [], so we need to use [ and ] instead. 60194 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 60195 if test "x$has_forbidden_chars" != x; then 60196 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 60197 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 60198 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 60199 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 60200 # Going to short mode and back again did indeed matter. Since short mode is 60201 # case insensitive, let's make it lowercase to improve readability. 60202 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 60203 # Now convert it back to Unix-style (cygpath) 60204 input_path=`$CYGPATH -u "$shortmode_path"` 60205 new_path="$input_path" 60206 fi 60207 fi 60208 60209 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 60210 if test "x$test_cygdrive_prefix" = x; then 60211 # As a simple fix, exclude /usr/bin since it's not a real path. 60212 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 60213 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 60214 # a path prefixed by /cygdrive for fixpath to work. 60215 new_path="$CYGWIN_ROOT_PATH$input_path" 60216 fi 60217 fi 60218 60219 60220 if test "x$path" != "x$new_path"; then 60221 POTENTIAL_FREETYPE_INCLUDE_PATH="$new_path" 60222 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&5 60223 $as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&6;} 60224 fi 60225 60226 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 60227 60228 path="$POTENTIAL_FREETYPE_INCLUDE_PATH" 60229 has_colon=`$ECHO $path | $GREP ^.:` 60230 new_path="$path" 60231 if test "x$has_colon" = x; then 60232 # Not in mixed or Windows style, start by that. 60233 new_path=`cmd //c echo $path` 60234 fi 60235 60236 60237 input_path="$new_path" 60238 # Check if we need to convert this using DOS-style short mode. If the path 60239 # contains just simple characters, use it. Otherwise (spaces, weird characters), 60240 # take no chances and rewrite it. 60241 # Note: m4 eats our [], so we need to use [ and ] instead. 60242 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 60243 if test "x$has_forbidden_chars" != x; then 60244 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 60245 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 60246 fi 60247 60248 60249 windows_path="$new_path" 60250 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 60251 unix_path=`$CYGPATH -u "$windows_path"` 60252 new_path="$unix_path" 60253 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 60254 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 60255 new_path="$unix_path" 60256 fi 60257 60258 if test "x$path" != "x$new_path"; then 60259 POTENTIAL_FREETYPE_INCLUDE_PATH="$new_path" 60260 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&5 60261 $as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&6;} 60262 fi 60263 60264 # Save the first 10 bytes of this path to the storage, so fixpath can work. 60265 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 60266 60267 else 60268 # We're on a unix platform. Hooray! :) 60269 path="$POTENTIAL_FREETYPE_INCLUDE_PATH" 60270 has_space=`$ECHO "$path" | $GREP " "` 60271 if test "x$has_space" != x; then 60272 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&5 60273 $as_echo "$as_me: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&6;} 60274 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 60275 fi 60276 60277 # Use eval to expand a potential ~ 60278 eval path="$path" 60279 if test ! -f "$path" && test ! -d "$path"; then 60280 as_fn_error $? "The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is not found." "$LINENO" 5 60281 fi 60282 60283 if test -d "$path"; then 60284 POTENTIAL_FREETYPE_INCLUDE_PATH="`cd "$path"; $THEPWDCMD -L`" 60285 else 60286 dir="`$DIRNAME "$path"`" 60287 base="`$BASENAME "$path"`" 60288 POTENTIAL_FREETYPE_INCLUDE_PATH="`cd "$dir"; $THEPWDCMD -L`/$base" 60289 fi 60290 fi 60291 fi 60292 60293 60294 # Only process if variable expands to non-empty 60295 60296 if test "x$POTENTIAL_FREETYPE_LIB_PATH" != x; then 60297 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 60298 60299 # Input might be given as Windows format, start by converting to 60300 # unix format. 60301 path="$POTENTIAL_FREETYPE_LIB_PATH" 60302 new_path=`$CYGPATH -u "$path"` 60303 60304 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 60305 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 60306 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 60307 # "foo.exe" is OK but "foo" is an error. 60308 # 60309 # This test is therefore slightly more accurate than "test -f" to check for file precense. 60310 # It is also a way to make sure we got the proper file name for the real test later on. 60311 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 60312 if test "x$test_shortpath" = x; then 60313 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&5 60314 $as_echo "$as_me: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&6;} 60315 as_fn_error $? "Cannot locate the the path of POTENTIAL_FREETYPE_LIB_PATH" "$LINENO" 5 60316 fi 60317 60318 # Call helper function which possibly converts this using DOS-style short mode. 60319 # If so, the updated path is stored in $new_path. 60320 60321 input_path="$new_path" 60322 # Check if we need to convert this using DOS-style short mode. If the path 60323 # contains just simple characters, use it. Otherwise (spaces, weird characters), 60324 # take no chances and rewrite it. 60325 # Note: m4 eats our [], so we need to use [ and ] instead. 60326 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 60327 if test "x$has_forbidden_chars" != x; then 60328 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 60329 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 60330 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 60331 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 60332 # Going to short mode and back again did indeed matter. Since short mode is 60333 # case insensitive, let's make it lowercase to improve readability. 60334 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 60335 # Now convert it back to Unix-style (cygpath) 60336 input_path=`$CYGPATH -u "$shortmode_path"` 60337 new_path="$input_path" 60338 fi 60339 fi 60340 60341 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 60342 if test "x$test_cygdrive_prefix" = x; then 60343 # As a simple fix, exclude /usr/bin since it's not a real path. 60344 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 60345 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 60346 # a path prefixed by /cygdrive for fixpath to work. 60347 new_path="$CYGWIN_ROOT_PATH$input_path" 60348 fi 60349 fi 60350 60351 60352 if test "x$path" != "x$new_path"; then 60353 POTENTIAL_FREETYPE_LIB_PATH="$new_path" 60354 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&5 60355 $as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&6;} 60356 fi 60357 60358 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 60359 60360 path="$POTENTIAL_FREETYPE_LIB_PATH" 60361 has_colon=`$ECHO $path | $GREP ^.:` 60362 new_path="$path" 60363 if test "x$has_colon" = x; then 60364 # Not in mixed or Windows style, start by that. 60365 new_path=`cmd //c echo $path` 60366 fi 60367 60368 60369 input_path="$new_path" 60370 # Check if we need to convert this using DOS-style short mode. If the path 60371 # contains just simple characters, use it. Otherwise (spaces, weird characters), 60372 # take no chances and rewrite it. 60373 # Note: m4 eats our [], so we need to use [ and ] instead. 60374 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 60375 if test "x$has_forbidden_chars" != x; then 60376 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 60377 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 60378 fi 60379 60380 60381 windows_path="$new_path" 60382 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 60383 unix_path=`$CYGPATH -u "$windows_path"` 60384 new_path="$unix_path" 60385 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 60386 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 60387 new_path="$unix_path" 60388 fi 60389 60390 if test "x$path" != "x$new_path"; then 60391 POTENTIAL_FREETYPE_LIB_PATH="$new_path" 60392 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&5 60393 $as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&6;} 60394 fi 60395 60396 # Save the first 10 bytes of this path to the storage, so fixpath can work. 60397 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 60398 60399 else 60400 # We're on a unix platform. Hooray! :) 60401 path="$POTENTIAL_FREETYPE_LIB_PATH" 60402 has_space=`$ECHO "$path" | $GREP " "` 60403 if test "x$has_space" != x; then 60404 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&5 60405 $as_echo "$as_me: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&6;} 60406 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 60407 fi 60408 60409 # Use eval to expand a potential ~ 60410 eval path="$path" 60411 if test ! -f "$path" && test ! -d "$path"; then 60412 as_fn_error $? "The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is not found." "$LINENO" 5 60413 fi 60414 60415 if test -d "$path"; then 60416 POTENTIAL_FREETYPE_LIB_PATH="`cd "$path"; $THEPWDCMD -L`" 60417 else 60418 dir="`$DIRNAME "$path"`" 60419 base="`$BASENAME "$path"`" 60420 POTENTIAL_FREETYPE_LIB_PATH="`cd "$dir"; $THEPWDCMD -L`/$base" 60421 fi 60422 fi 60423 fi 60424 60425 60426 FREETYPE_INCLUDE_PATH="$POTENTIAL_FREETYPE_INCLUDE_PATH" 60427 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for freetype includes" >&5 60428 $as_echo_n "checking for freetype includes... " >&6; } 60429 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $FREETYPE_INCLUDE_PATH" >&5 60430 $as_echo "$FREETYPE_INCLUDE_PATH" >&6; } 60431 FREETYPE_LIB_PATH="$POTENTIAL_FREETYPE_LIB_PATH" 60432 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for freetype libraries" >&5 60433 $as_echo_n "checking for freetype libraries... " >&6; } 60434 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $FREETYPE_LIB_PATH" >&5 60435 $as_echo "$FREETYPE_LIB_PATH" >&6; } 60436 fi 60437 60438 60439 if test "x$FOUND_FREETYPE" != xyes; then 60440 FREETYPE_BASE_DIR="$SYSROOT/usr/X11" 60441 60442 POTENTIAL_FREETYPE_INCLUDE_PATH="$FREETYPE_BASE_DIR/include" 60443 POTENTIAL_FREETYPE_LIB_PATH="$FREETYPE_BASE_DIR/lib" 60444 METHOD="well-known location" 60445 60446 # Let's start with an optimistic view of the world :-) 60447 FOUND_FREETYPE=yes 60448 60449 # First look for the canonical freetype main include file ft2build.h. 60450 if ! test -s "$POTENTIAL_FREETYPE_INCLUDE_PATH/ft2build.h"; then 60451 # Oh no! Let's try in the freetype2 directory. This is needed at least at Mac OS X Yosemite. 60452 POTENTIAL_FREETYPE_INCLUDE_PATH="$POTENTIAL_FREETYPE_INCLUDE_PATH/freetype2" 60453 if ! test -s "$POTENTIAL_FREETYPE_INCLUDE_PATH/ft2build.h"; then 60454 # Fail. 60455 FOUND_FREETYPE=no 60456 fi 60457 fi 60458 60459 if test "x$FOUND_FREETYPE" = xyes; then 60460 # Include file found, let's continue the sanity check. 60461 { $as_echo "$as_me:${as_lineno-$LINENO}: Found freetype include files at $POTENTIAL_FREETYPE_INCLUDE_PATH using $METHOD" >&5 60462 $as_echo "$as_me: Found freetype include files at $POTENTIAL_FREETYPE_INCLUDE_PATH using $METHOD" >&6;} 60463 60464 # Reset to default value 60465 FREETYPE_BASE_NAME=freetype 60466 FREETYPE_LIB_NAME="${LIBRARY_PREFIX}${FREETYPE_BASE_NAME}${SHARED_LIBRARY_SUFFIX}" 60467 if ! test -s "$POTENTIAL_FREETYPE_LIB_PATH/$FREETYPE_LIB_NAME"; then 60468 if test "x$OPENJDK_TARGET_OS" = xmacosx \ 60469 && test -s "$POTENTIAL_FREETYPE_LIB_PATH/${LIBRARY_PREFIX}freetype.6${SHARED_LIBRARY_SUFFIX}"; then 60470 # On Mac OS X Yosemite, the symlink from libfreetype.dylib to libfreetype.6.dylib disappeared. Check 60471 # for the .6 version explicitly. 60472 FREETYPE_BASE_NAME=freetype.6 60473 FREETYPE_LIB_NAME="${LIBRARY_PREFIX}${FREETYPE_BASE_NAME}${SHARED_LIBRARY_SUFFIX}" 60474 { $as_echo "$as_me:${as_lineno-$LINENO}: Compensating for missing symlink by using version 6 explicitly" >&5 60475 $as_echo "$as_me: Compensating for missing symlink by using version 6 explicitly" >&6;} 60476 else 60477 { $as_echo "$as_me:${as_lineno-$LINENO}: Could not find $POTENTIAL_FREETYPE_LIB_PATH/$FREETYPE_LIB_NAME. Ignoring location." >&5 60478 $as_echo "$as_me: Could not find $POTENTIAL_FREETYPE_LIB_PATH/$FREETYPE_LIB_NAME. Ignoring location." >&6;} 60479 FOUND_FREETYPE=no 60480 fi 60481 else 60482 if test "x$OPENJDK_TARGET_OS" = xwindows; then 60483 # On Windows, we will need both .lib and .dll file. 60484 if ! test -s "$POTENTIAL_FREETYPE_LIB_PATH/${FREETYPE_BASE_NAME}.lib"; then 60485 { $as_echo "$as_me:${as_lineno-$LINENO}: Could not find $POTENTIAL_FREETYPE_LIB_PATH/${FREETYPE_BASE_NAME}.lib. Ignoring location." >&5 60486 $as_echo "$as_me: Could not find $POTENTIAL_FREETYPE_LIB_PATH/${FREETYPE_BASE_NAME}.lib. Ignoring location." >&6;} 60487 FOUND_FREETYPE=no 60488 fi 60489 elif test "x$OPENJDK_TARGET_OS" = xsolaris \ 60490 && test -s "$POTENTIAL_FREETYPE_LIB_PATH$OPENJDK_TARGET_CPU_ISADIR/$FREETYPE_LIB_NAME"; then 60491 # Found lib in isa dir, use that instead. 60492 POTENTIAL_FREETYPE_LIB_PATH="$POTENTIAL_FREETYPE_LIB_PATH$OPENJDK_TARGET_CPU_ISADIR" 60493 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting to use $POTENTIAL_FREETYPE_LIB_PATH instead" >&5 60494 $as_echo "$as_me: Rewriting to use $POTENTIAL_FREETYPE_LIB_PATH instead" >&6;} 60495 fi 60496 fi 60497 fi 60498 60499 if test "x$FOUND_FREETYPE" = xyes; then 60500 60501 # Only process if variable expands to non-empty 60502 60503 if test "x$POTENTIAL_FREETYPE_INCLUDE_PATH" != x; then 60504 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 60505 60506 # Input might be given as Windows format, start by converting to 60507 # unix format. 60508 path="$POTENTIAL_FREETYPE_INCLUDE_PATH" 60509 new_path=`$CYGPATH -u "$path"` 60510 60511 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 60512 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 60513 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 60514 # "foo.exe" is OK but "foo" is an error. 60515 # 60516 # This test is therefore slightly more accurate than "test -f" to check for file precense. 60517 # It is also a way to make sure we got the proper file name for the real test later on. 60518 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 60519 if test "x$test_shortpath" = x; then 60520 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&5 60521 $as_echo "$as_me: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&6;} 60522 as_fn_error $? "Cannot locate the the path of POTENTIAL_FREETYPE_INCLUDE_PATH" "$LINENO" 5 60523 fi 60524 60525 # Call helper function which possibly converts this using DOS-style short mode. 60526 # If so, the updated path is stored in $new_path. 60527 60528 input_path="$new_path" 60529 # Check if we need to convert this using DOS-style short mode. If the path 60530 # contains just simple characters, use it. Otherwise (spaces, weird characters), 60531 # take no chances and rewrite it. 60532 # Note: m4 eats our [], so we need to use [ and ] instead. 60533 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 60534 if test "x$has_forbidden_chars" != x; then 60535 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 60536 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 60537 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 60538 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 60539 # Going to short mode and back again did indeed matter. Since short mode is 60540 # case insensitive, let's make it lowercase to improve readability. 60541 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 60542 # Now convert it back to Unix-style (cygpath) 60543 input_path=`$CYGPATH -u "$shortmode_path"` 60544 new_path="$input_path" 60545 fi 60546 fi 60547 60548 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 60549 if test "x$test_cygdrive_prefix" = x; then 60550 # As a simple fix, exclude /usr/bin since it's not a real path. 60551 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 60552 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 60553 # a path prefixed by /cygdrive for fixpath to work. 60554 new_path="$CYGWIN_ROOT_PATH$input_path" 60555 fi 60556 fi 60557 60558 60559 if test "x$path" != "x$new_path"; then 60560 POTENTIAL_FREETYPE_INCLUDE_PATH="$new_path" 60561 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&5 60562 $as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&6;} 60563 fi 60564 60565 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 60566 60567 path="$POTENTIAL_FREETYPE_INCLUDE_PATH" 60568 has_colon=`$ECHO $path | $GREP ^.:` 60569 new_path="$path" 60570 if test "x$has_colon" = x; then 60571 # Not in mixed or Windows style, start by that. 60572 new_path=`cmd //c echo $path` 60573 fi 60574 60575 60576 input_path="$new_path" 60577 # Check if we need to convert this using DOS-style short mode. If the path 60578 # contains just simple characters, use it. Otherwise (spaces, weird characters), 60579 # take no chances and rewrite it. 60580 # Note: m4 eats our [], so we need to use [ and ] instead. 60581 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 60582 if test "x$has_forbidden_chars" != x; then 60583 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 60584 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 60585 fi 60586 60587 60588 windows_path="$new_path" 60589 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 60590 unix_path=`$CYGPATH -u "$windows_path"` 60591 new_path="$unix_path" 60592 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 60593 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 60594 new_path="$unix_path" 60595 fi 60596 60597 if test "x$path" != "x$new_path"; then 60598 POTENTIAL_FREETYPE_INCLUDE_PATH="$new_path" 60599 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&5 60600 $as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&6;} 60601 fi 60602 60603 # Save the first 10 bytes of this path to the storage, so fixpath can work. 60604 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 60605 60606 else 60607 # We're on a unix platform. Hooray! :) 60608 path="$POTENTIAL_FREETYPE_INCLUDE_PATH" 60609 has_space=`$ECHO "$path" | $GREP " "` 60610 if test "x$has_space" != x; then 60611 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&5 60612 $as_echo "$as_me: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&6;} 60613 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 60614 fi 60615 60616 # Use eval to expand a potential ~ 60617 eval path="$path" 60618 if test ! -f "$path" && test ! -d "$path"; then 60619 as_fn_error $? "The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is not found." "$LINENO" 5 60620 fi 60621 60622 if test -d "$path"; then 60623 POTENTIAL_FREETYPE_INCLUDE_PATH="`cd "$path"; $THEPWDCMD -L`" 60624 else 60625 dir="`$DIRNAME "$path"`" 60626 base="`$BASENAME "$path"`" 60627 POTENTIAL_FREETYPE_INCLUDE_PATH="`cd "$dir"; $THEPWDCMD -L`/$base" 60628 fi 60629 fi 60630 fi 60631 60632 60633 # Only process if variable expands to non-empty 60634 60635 if test "x$POTENTIAL_FREETYPE_LIB_PATH" != x; then 60636 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 60637 60638 # Input might be given as Windows format, start by converting to 60639 # unix format. 60640 path="$POTENTIAL_FREETYPE_LIB_PATH" 60641 new_path=`$CYGPATH -u "$path"` 60642 60643 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 60644 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 60645 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 60646 # "foo.exe" is OK but "foo" is an error. 60647 # 60648 # This test is therefore slightly more accurate than "test -f" to check for file precense. 60649 # It is also a way to make sure we got the proper file name for the real test later on. 60650 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 60651 if test "x$test_shortpath" = x; then 60652 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&5 60653 $as_echo "$as_me: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&6;} 60654 as_fn_error $? "Cannot locate the the path of POTENTIAL_FREETYPE_LIB_PATH" "$LINENO" 5 60655 fi 60656 60657 # Call helper function which possibly converts this using DOS-style short mode. 60658 # If so, the updated path is stored in $new_path. 60659 60660 input_path="$new_path" 60661 # Check if we need to convert this using DOS-style short mode. If the path 60662 # contains just simple characters, use it. Otherwise (spaces, weird characters), 60663 # take no chances and rewrite it. 60664 # Note: m4 eats our [], so we need to use [ and ] instead. 60665 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 60666 if test "x$has_forbidden_chars" != x; then 60667 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 60668 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 60669 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 60670 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 60671 # Going to short mode and back again did indeed matter. Since short mode is 60672 # case insensitive, let's make it lowercase to improve readability. 60673 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 60674 # Now convert it back to Unix-style (cygpath) 60675 input_path=`$CYGPATH -u "$shortmode_path"` 60676 new_path="$input_path" 60677 fi 60678 fi 60679 60680 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 60681 if test "x$test_cygdrive_prefix" = x; then 60682 # As a simple fix, exclude /usr/bin since it's not a real path. 60683 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 60684 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 60685 # a path prefixed by /cygdrive for fixpath to work. 60686 new_path="$CYGWIN_ROOT_PATH$input_path" 60687 fi 60688 fi 60689 60690 60691 if test "x$path" != "x$new_path"; then 60692 POTENTIAL_FREETYPE_LIB_PATH="$new_path" 60693 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&5 60694 $as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&6;} 60695 fi 60696 60697 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 60698 60699 path="$POTENTIAL_FREETYPE_LIB_PATH" 60700 has_colon=`$ECHO $path | $GREP ^.:` 60701 new_path="$path" 60702 if test "x$has_colon" = x; then 60703 # Not in mixed or Windows style, start by that. 60704 new_path=`cmd //c echo $path` 60705 fi 60706 60707 60708 input_path="$new_path" 60709 # Check if we need to convert this using DOS-style short mode. If the path 60710 # contains just simple characters, use it. Otherwise (spaces, weird characters), 60711 # take no chances and rewrite it. 60712 # Note: m4 eats our [], so we need to use [ and ] instead. 60713 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 60714 if test "x$has_forbidden_chars" != x; then 60715 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 60716 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 60717 fi 60718 60719 60720 windows_path="$new_path" 60721 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 60722 unix_path=`$CYGPATH -u "$windows_path"` 60723 new_path="$unix_path" 60724 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 60725 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 60726 new_path="$unix_path" 60727 fi 60728 60729 if test "x$path" != "x$new_path"; then 60730 POTENTIAL_FREETYPE_LIB_PATH="$new_path" 60731 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&5 60732 $as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&6;} 60733 fi 60734 60735 # Save the first 10 bytes of this path to the storage, so fixpath can work. 60736 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 60737 60738 else 60739 # We're on a unix platform. Hooray! :) 60740 path="$POTENTIAL_FREETYPE_LIB_PATH" 60741 has_space=`$ECHO "$path" | $GREP " "` 60742 if test "x$has_space" != x; then 60743 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&5 60744 $as_echo "$as_me: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&6;} 60745 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 60746 fi 60747 60748 # Use eval to expand a potential ~ 60749 eval path="$path" 60750 if test ! -f "$path" && test ! -d "$path"; then 60751 as_fn_error $? "The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is not found." "$LINENO" 5 60752 fi 60753 60754 if test -d "$path"; then 60755 POTENTIAL_FREETYPE_LIB_PATH="`cd "$path"; $THEPWDCMD -L`" 60756 else 60757 dir="`$DIRNAME "$path"`" 60758 base="`$BASENAME "$path"`" 60759 POTENTIAL_FREETYPE_LIB_PATH="`cd "$dir"; $THEPWDCMD -L`/$base" 60760 fi 60761 fi 60762 fi 60763 60764 60765 FREETYPE_INCLUDE_PATH="$POTENTIAL_FREETYPE_INCLUDE_PATH" 60766 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for freetype includes" >&5 60767 $as_echo_n "checking for freetype includes... " >&6; } 60768 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $FREETYPE_INCLUDE_PATH" >&5 60769 $as_echo "$FREETYPE_INCLUDE_PATH" >&6; } 60770 FREETYPE_LIB_PATH="$POTENTIAL_FREETYPE_LIB_PATH" 60771 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for freetype libraries" >&5 60772 $as_echo_n "checking for freetype libraries... " >&6; } 60773 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $FREETYPE_LIB_PATH" >&5 60774 $as_echo "$FREETYPE_LIB_PATH" >&6; } 60775 fi 60776 60777 fi 60778 60779 if test "x$OPENJDK_TARGET_OS" = xmacosx; then 60780 if test "x$FOUND_FREETYPE" != xyes; then 60781 # Due to changes in OSX 10.11 XQuartz now installs to /opt/X11 60782 FREETYPE_BASE_DIR="$SYSROOT/opt/X11" 60783 60784 POTENTIAL_FREETYPE_INCLUDE_PATH="$FREETYPE_BASE_DIR/include" 60785 POTENTIAL_FREETYPE_LIB_PATH="$FREETYPE_BASE_DIR/lib" 60786 METHOD="well-known location" 60787 60788 # Let's start with an optimistic view of the world :-) 60789 FOUND_FREETYPE=yes 60790 60791 # First look for the canonical freetype main include file ft2build.h. 60792 if ! test -s "$POTENTIAL_FREETYPE_INCLUDE_PATH/ft2build.h"; then 60793 # Oh no! Let's try in the freetype2 directory. This is needed at least at Mac OS X Yosemite. 60794 POTENTIAL_FREETYPE_INCLUDE_PATH="$POTENTIAL_FREETYPE_INCLUDE_PATH/freetype2" 60795 if ! test -s "$POTENTIAL_FREETYPE_INCLUDE_PATH/ft2build.h"; then 60796 # Fail. 60797 FOUND_FREETYPE=no 60798 fi 60799 fi 60800 60801 if test "x$FOUND_FREETYPE" = xyes; then 60802 # Include file found, let's continue the sanity check. 60803 { $as_echo "$as_me:${as_lineno-$LINENO}: Found freetype include files at $POTENTIAL_FREETYPE_INCLUDE_PATH using $METHOD" >&5 60804 $as_echo "$as_me: Found freetype include files at $POTENTIAL_FREETYPE_INCLUDE_PATH using $METHOD" >&6;} 60805 60806 # Reset to default value 60807 FREETYPE_BASE_NAME=freetype 60808 FREETYPE_LIB_NAME="${LIBRARY_PREFIX}${FREETYPE_BASE_NAME}${SHARED_LIBRARY_SUFFIX}" 60809 if ! test -s "$POTENTIAL_FREETYPE_LIB_PATH/$FREETYPE_LIB_NAME"; then 60810 if test "x$OPENJDK_TARGET_OS" = xmacosx \ 60811 && test -s "$POTENTIAL_FREETYPE_LIB_PATH/${LIBRARY_PREFIX}freetype.6${SHARED_LIBRARY_SUFFIX}"; then 60812 # On Mac OS X Yosemite, the symlink from libfreetype.dylib to libfreetype.6.dylib disappeared. Check 60813 # for the .6 version explicitly. 60814 FREETYPE_BASE_NAME=freetype.6 60815 FREETYPE_LIB_NAME="${LIBRARY_PREFIX}${FREETYPE_BASE_NAME}${SHARED_LIBRARY_SUFFIX}" 60816 { $as_echo "$as_me:${as_lineno-$LINENO}: Compensating for missing symlink by using version 6 explicitly" >&5 60817 $as_echo "$as_me: Compensating for missing symlink by using version 6 explicitly" >&6;} 60818 else 60819 { $as_echo "$as_me:${as_lineno-$LINENO}: Could not find $POTENTIAL_FREETYPE_LIB_PATH/$FREETYPE_LIB_NAME. Ignoring location." >&5 60820 $as_echo "$as_me: Could not find $POTENTIAL_FREETYPE_LIB_PATH/$FREETYPE_LIB_NAME. Ignoring location." >&6;} 60821 FOUND_FREETYPE=no 60822 fi 60823 else 60824 if test "x$OPENJDK_TARGET_OS" = xwindows; then 60825 # On Windows, we will need both .lib and .dll file. 60826 if ! test -s "$POTENTIAL_FREETYPE_LIB_PATH/${FREETYPE_BASE_NAME}.lib"; then 60827 { $as_echo "$as_me:${as_lineno-$LINENO}: Could not find $POTENTIAL_FREETYPE_LIB_PATH/${FREETYPE_BASE_NAME}.lib. Ignoring location." >&5 60828 $as_echo "$as_me: Could not find $POTENTIAL_FREETYPE_LIB_PATH/${FREETYPE_BASE_NAME}.lib. Ignoring location." >&6;} 60829 FOUND_FREETYPE=no 60830 fi 60831 elif test "x$OPENJDK_TARGET_OS" = xsolaris \ 60832 && test -s "$POTENTIAL_FREETYPE_LIB_PATH$OPENJDK_TARGET_CPU_ISADIR/$FREETYPE_LIB_NAME"; then 60833 # Found lib in isa dir, use that instead. 60834 POTENTIAL_FREETYPE_LIB_PATH="$POTENTIAL_FREETYPE_LIB_PATH$OPENJDK_TARGET_CPU_ISADIR" 60835 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting to use $POTENTIAL_FREETYPE_LIB_PATH instead" >&5 60836 $as_echo "$as_me: Rewriting to use $POTENTIAL_FREETYPE_LIB_PATH instead" >&6;} 60837 fi 60838 fi 60839 fi 60840 60841 if test "x$FOUND_FREETYPE" = xyes; then 60842 60843 # Only process if variable expands to non-empty 60844 60845 if test "x$POTENTIAL_FREETYPE_INCLUDE_PATH" != x; then 60846 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 60847 60848 # Input might be given as Windows format, start by converting to 60849 # unix format. 60850 path="$POTENTIAL_FREETYPE_INCLUDE_PATH" 60851 new_path=`$CYGPATH -u "$path"` 60852 60853 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 60854 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 60855 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 60856 # "foo.exe" is OK but "foo" is an error. 60857 # 60858 # This test is therefore slightly more accurate than "test -f" to check for file precense. 60859 # It is also a way to make sure we got the proper file name for the real test later on. 60860 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 60861 if test "x$test_shortpath" = x; then 60862 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&5 60863 $as_echo "$as_me: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&6;} 60864 as_fn_error $? "Cannot locate the the path of POTENTIAL_FREETYPE_INCLUDE_PATH" "$LINENO" 5 60865 fi 60866 60867 # Call helper function which possibly converts this using DOS-style short mode. 60868 # If so, the updated path is stored in $new_path. 60869 60870 input_path="$new_path" 60871 # Check if we need to convert this using DOS-style short mode. If the path 60872 # contains just simple characters, use it. Otherwise (spaces, weird characters), 60873 # take no chances and rewrite it. 60874 # Note: m4 eats our [], so we need to use [ and ] instead. 60875 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 60876 if test "x$has_forbidden_chars" != x; then 60877 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 60878 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 60879 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 60880 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 60881 # Going to short mode and back again did indeed matter. Since short mode is 60882 # case insensitive, let's make it lowercase to improve readability. 60883 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 60884 # Now convert it back to Unix-style (cygpath) 60885 input_path=`$CYGPATH -u "$shortmode_path"` 60886 new_path="$input_path" 60887 fi 60888 fi 60889 60890 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 60891 if test "x$test_cygdrive_prefix" = x; then 60892 # As a simple fix, exclude /usr/bin since it's not a real path. 60893 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 60894 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 60895 # a path prefixed by /cygdrive for fixpath to work. 60896 new_path="$CYGWIN_ROOT_PATH$input_path" 60897 fi 60898 fi 60899 60900 60901 if test "x$path" != "x$new_path"; then 60902 POTENTIAL_FREETYPE_INCLUDE_PATH="$new_path" 60903 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&5 60904 $as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&6;} 60905 fi 60906 60907 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 60908 60909 path="$POTENTIAL_FREETYPE_INCLUDE_PATH" 60910 has_colon=`$ECHO $path | $GREP ^.:` 60911 new_path="$path" 60912 if test "x$has_colon" = x; then 60913 # Not in mixed or Windows style, start by that. 60914 new_path=`cmd //c echo $path` 60915 fi 60916 60917 60918 input_path="$new_path" 60919 # Check if we need to convert this using DOS-style short mode. If the path 60920 # contains just simple characters, use it. Otherwise (spaces, weird characters), 60921 # take no chances and rewrite it. 60922 # Note: m4 eats our [], so we need to use [ and ] instead. 60923 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 60924 if test "x$has_forbidden_chars" != x; then 60925 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 60926 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 60927 fi 60928 60929 60930 windows_path="$new_path" 60931 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 60932 unix_path=`$CYGPATH -u "$windows_path"` 60933 new_path="$unix_path" 60934 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 60935 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 60936 new_path="$unix_path" 60937 fi 60938 60939 if test "x$path" != "x$new_path"; then 60940 POTENTIAL_FREETYPE_INCLUDE_PATH="$new_path" 60941 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&5 60942 $as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&6;} 60943 fi 60944 60945 # Save the first 10 bytes of this path to the storage, so fixpath can work. 60946 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 60947 60948 else 60949 # We're on a unix platform. Hooray! :) 60950 path="$POTENTIAL_FREETYPE_INCLUDE_PATH" 60951 has_space=`$ECHO "$path" | $GREP " "` 60952 if test "x$has_space" != x; then 60953 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&5 60954 $as_echo "$as_me: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&6;} 60955 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 60956 fi 60957 60958 # Use eval to expand a potential ~ 60959 eval path="$path" 60960 if test ! -f "$path" && test ! -d "$path"; then 60961 as_fn_error $? "The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is not found." "$LINENO" 5 60962 fi 60963 60964 if test -d "$path"; then 60965 POTENTIAL_FREETYPE_INCLUDE_PATH="`cd "$path"; $THEPWDCMD -L`" 60966 else 60967 dir="`$DIRNAME "$path"`" 60968 base="`$BASENAME "$path"`" 60969 POTENTIAL_FREETYPE_INCLUDE_PATH="`cd "$dir"; $THEPWDCMD -L`/$base" 60970 fi 60971 fi 60972 fi 60973 60974 60975 # Only process if variable expands to non-empty 60976 60977 if test "x$POTENTIAL_FREETYPE_LIB_PATH" != x; then 60978 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 60979 60980 # Input might be given as Windows format, start by converting to 60981 # unix format. 60982 path="$POTENTIAL_FREETYPE_LIB_PATH" 60983 new_path=`$CYGPATH -u "$path"` 60984 60985 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 60986 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 60987 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 60988 # "foo.exe" is OK but "foo" is an error. 60989 # 60990 # This test is therefore slightly more accurate than "test -f" to check for file precense. 60991 # It is also a way to make sure we got the proper file name for the real test later on. 60992 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 60993 if test "x$test_shortpath" = x; then 60994 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&5 60995 $as_echo "$as_me: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&6;} 60996 as_fn_error $? "Cannot locate the the path of POTENTIAL_FREETYPE_LIB_PATH" "$LINENO" 5 60997 fi 60998 60999 # Call helper function which possibly converts this using DOS-style short mode. 61000 # If so, the updated path is stored in $new_path. 61001 61002 input_path="$new_path" 61003 # Check if we need to convert this using DOS-style short mode. If the path 61004 # contains just simple characters, use it. Otherwise (spaces, weird characters), 61005 # take no chances and rewrite it. 61006 # Note: m4 eats our [], so we need to use [ and ] instead. 61007 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 61008 if test "x$has_forbidden_chars" != x; then 61009 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 61010 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 61011 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 61012 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 61013 # Going to short mode and back again did indeed matter. Since short mode is 61014 # case insensitive, let's make it lowercase to improve readability. 61015 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 61016 # Now convert it back to Unix-style (cygpath) 61017 input_path=`$CYGPATH -u "$shortmode_path"` 61018 new_path="$input_path" 61019 fi 61020 fi 61021 61022 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 61023 if test "x$test_cygdrive_prefix" = x; then 61024 # As a simple fix, exclude /usr/bin since it's not a real path. 61025 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 61026 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 61027 # a path prefixed by /cygdrive for fixpath to work. 61028 new_path="$CYGWIN_ROOT_PATH$input_path" 61029 fi 61030 fi 61031 61032 61033 if test "x$path" != "x$new_path"; then 61034 POTENTIAL_FREETYPE_LIB_PATH="$new_path" 61035 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&5 61036 $as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&6;} 61037 fi 61038 61039 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 61040 61041 path="$POTENTIAL_FREETYPE_LIB_PATH" 61042 has_colon=`$ECHO $path | $GREP ^.:` 61043 new_path="$path" 61044 if test "x$has_colon" = x; then 61045 # Not in mixed or Windows style, start by that. 61046 new_path=`cmd //c echo $path` 61047 fi 61048 61049 61050 input_path="$new_path" 61051 # Check if we need to convert this using DOS-style short mode. If the path 61052 # contains just simple characters, use it. Otherwise (spaces, weird characters), 61053 # take no chances and rewrite it. 61054 # Note: m4 eats our [], so we need to use [ and ] instead. 61055 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 61056 if test "x$has_forbidden_chars" != x; then 61057 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 61058 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 61059 fi 61060 61061 61062 windows_path="$new_path" 61063 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 61064 unix_path=`$CYGPATH -u "$windows_path"` 61065 new_path="$unix_path" 61066 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 61067 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 61068 new_path="$unix_path" 61069 fi 61070 61071 if test "x$path" != "x$new_path"; then 61072 POTENTIAL_FREETYPE_LIB_PATH="$new_path" 61073 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&5 61074 $as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&6;} 61075 fi 61076 61077 # Save the first 10 bytes of this path to the storage, so fixpath can work. 61078 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 61079 61080 else 61081 # We're on a unix platform. Hooray! :) 61082 path="$POTENTIAL_FREETYPE_LIB_PATH" 61083 has_space=`$ECHO "$path" | $GREP " "` 61084 if test "x$has_space" != x; then 61085 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&5 61086 $as_echo "$as_me: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&6;} 61087 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 61088 fi 61089 61090 # Use eval to expand a potential ~ 61091 eval path="$path" 61092 if test ! -f "$path" && test ! -d "$path"; then 61093 as_fn_error $? "The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is not found." "$LINENO" 5 61094 fi 61095 61096 if test -d "$path"; then 61097 POTENTIAL_FREETYPE_LIB_PATH="`cd "$path"; $THEPWDCMD -L`" 61098 else 61099 dir="`$DIRNAME "$path"`" 61100 base="`$BASENAME "$path"`" 61101 POTENTIAL_FREETYPE_LIB_PATH="`cd "$dir"; $THEPWDCMD -L`/$base" 61102 fi 61103 fi 61104 fi 61105 61106 61107 FREETYPE_INCLUDE_PATH="$POTENTIAL_FREETYPE_INCLUDE_PATH" 61108 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for freetype includes" >&5 61109 $as_echo_n "checking for freetype includes... " >&6; } 61110 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $FREETYPE_INCLUDE_PATH" >&5 61111 $as_echo "$FREETYPE_INCLUDE_PATH" >&6; } 61112 FREETYPE_LIB_PATH="$POTENTIAL_FREETYPE_LIB_PATH" 61113 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for freetype libraries" >&5 61114 $as_echo_n "checking for freetype libraries... " >&6; } 61115 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $FREETYPE_LIB_PATH" >&5 61116 $as_echo "$FREETYPE_LIB_PATH" >&6; } 61117 fi 61118 61119 fi 61120 fi 61121 61122 if test "x$FOUND_FREETYPE" != xyes; then 61123 FREETYPE_BASE_DIR="$SYSROOT/usr" 61124 if test "x$OPENJDK_TARGET_CPU_BITS" = x64; then 61125 61126 POTENTIAL_FREETYPE_INCLUDE_PATH="$FREETYPE_BASE_DIR/include" 61127 POTENTIAL_FREETYPE_LIB_PATH="$FREETYPE_BASE_DIR/lib/x86_64-linux-gnu" 61128 METHOD="well-known location" 61129 61130 # Let's start with an optimistic view of the world :-) 61131 FOUND_FREETYPE=yes 61132 61133 # First look for the canonical freetype main include file ft2build.h. 61134 if ! test -s "$POTENTIAL_FREETYPE_INCLUDE_PATH/ft2build.h"; then 61135 # Oh no! Let's try in the freetype2 directory. This is needed at least at Mac OS X Yosemite. 61136 POTENTIAL_FREETYPE_INCLUDE_PATH="$POTENTIAL_FREETYPE_INCLUDE_PATH/freetype2" 61137 if ! test -s "$POTENTIAL_FREETYPE_INCLUDE_PATH/ft2build.h"; then 61138 # Fail. 61139 FOUND_FREETYPE=no 61140 fi 61141 fi 61142 61143 if test "x$FOUND_FREETYPE" = xyes; then 61144 # Include file found, let's continue the sanity check. 61145 { $as_echo "$as_me:${as_lineno-$LINENO}: Found freetype include files at $POTENTIAL_FREETYPE_INCLUDE_PATH using $METHOD" >&5 61146 $as_echo "$as_me: Found freetype include files at $POTENTIAL_FREETYPE_INCLUDE_PATH using $METHOD" >&6;} 61147 61148 # Reset to default value 61149 FREETYPE_BASE_NAME=freetype 61150 FREETYPE_LIB_NAME="${LIBRARY_PREFIX}${FREETYPE_BASE_NAME}${SHARED_LIBRARY_SUFFIX}" 61151 if ! test -s "$POTENTIAL_FREETYPE_LIB_PATH/$FREETYPE_LIB_NAME"; then 61152 if test "x$OPENJDK_TARGET_OS" = xmacosx \ 61153 && test -s "$POTENTIAL_FREETYPE_LIB_PATH/${LIBRARY_PREFIX}freetype.6${SHARED_LIBRARY_SUFFIX}"; then 61154 # On Mac OS X Yosemite, the symlink from libfreetype.dylib to libfreetype.6.dylib disappeared. Check 61155 # for the .6 version explicitly. 61156 FREETYPE_BASE_NAME=freetype.6 61157 FREETYPE_LIB_NAME="${LIBRARY_PREFIX}${FREETYPE_BASE_NAME}${SHARED_LIBRARY_SUFFIX}" 61158 { $as_echo "$as_me:${as_lineno-$LINENO}: Compensating for missing symlink by using version 6 explicitly" >&5 61159 $as_echo "$as_me: Compensating for missing symlink by using version 6 explicitly" >&6;} 61160 else 61161 { $as_echo "$as_me:${as_lineno-$LINENO}: Could not find $POTENTIAL_FREETYPE_LIB_PATH/$FREETYPE_LIB_NAME. Ignoring location." >&5 61162 $as_echo "$as_me: Could not find $POTENTIAL_FREETYPE_LIB_PATH/$FREETYPE_LIB_NAME. Ignoring location." >&6;} 61163 FOUND_FREETYPE=no 61164 fi 61165 else 61166 if test "x$OPENJDK_TARGET_OS" = xwindows; then 61167 # On Windows, we will need both .lib and .dll file. 61168 if ! test -s "$POTENTIAL_FREETYPE_LIB_PATH/${FREETYPE_BASE_NAME}.lib"; then 61169 { $as_echo "$as_me:${as_lineno-$LINENO}: Could not find $POTENTIAL_FREETYPE_LIB_PATH/${FREETYPE_BASE_NAME}.lib. Ignoring location." >&5 61170 $as_echo "$as_me: Could not find $POTENTIAL_FREETYPE_LIB_PATH/${FREETYPE_BASE_NAME}.lib. Ignoring location." >&6;} 61171 FOUND_FREETYPE=no 61172 fi 61173 elif test "x$OPENJDK_TARGET_OS" = xsolaris \ 61174 && test -s "$POTENTIAL_FREETYPE_LIB_PATH$OPENJDK_TARGET_CPU_ISADIR/$FREETYPE_LIB_NAME"; then 61175 # Found lib in isa dir, use that instead. 61176 POTENTIAL_FREETYPE_LIB_PATH="$POTENTIAL_FREETYPE_LIB_PATH$OPENJDK_TARGET_CPU_ISADIR" 61177 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting to use $POTENTIAL_FREETYPE_LIB_PATH instead" >&5 61178 $as_echo "$as_me: Rewriting to use $POTENTIAL_FREETYPE_LIB_PATH instead" >&6;} 61179 fi 61180 fi 61181 fi 61182 61183 if test "x$FOUND_FREETYPE" = xyes; then 61184 61185 # Only process if variable expands to non-empty 61186 61187 if test "x$POTENTIAL_FREETYPE_INCLUDE_PATH" != x; then 61188 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 61189 61190 # Input might be given as Windows format, start by converting to 61191 # unix format. 61192 path="$POTENTIAL_FREETYPE_INCLUDE_PATH" 61193 new_path=`$CYGPATH -u "$path"` 61194 61195 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 61196 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 61197 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 61198 # "foo.exe" is OK but "foo" is an error. 61199 # 61200 # This test is therefore slightly more accurate than "test -f" to check for file precense. 61201 # It is also a way to make sure we got the proper file name for the real test later on. 61202 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 61203 if test "x$test_shortpath" = x; then 61204 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&5 61205 $as_echo "$as_me: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&6;} 61206 as_fn_error $? "Cannot locate the the path of POTENTIAL_FREETYPE_INCLUDE_PATH" "$LINENO" 5 61207 fi 61208 61209 # Call helper function which possibly converts this using DOS-style short mode. 61210 # If so, the updated path is stored in $new_path. 61211 61212 input_path="$new_path" 61213 # Check if we need to convert this using DOS-style short mode. If the path 61214 # contains just simple characters, use it. Otherwise (spaces, weird characters), 61215 # take no chances and rewrite it. 61216 # Note: m4 eats our [], so we need to use [ and ] instead. 61217 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 61218 if test "x$has_forbidden_chars" != x; then 61219 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 61220 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 61221 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 61222 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 61223 # Going to short mode and back again did indeed matter. Since short mode is 61224 # case insensitive, let's make it lowercase to improve readability. 61225 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 61226 # Now convert it back to Unix-style (cygpath) 61227 input_path=`$CYGPATH -u "$shortmode_path"` 61228 new_path="$input_path" 61229 fi 61230 fi 61231 61232 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 61233 if test "x$test_cygdrive_prefix" = x; then 61234 # As a simple fix, exclude /usr/bin since it's not a real path. 61235 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 61236 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 61237 # a path prefixed by /cygdrive for fixpath to work. 61238 new_path="$CYGWIN_ROOT_PATH$input_path" 61239 fi 61240 fi 61241 61242 61243 if test "x$path" != "x$new_path"; then 61244 POTENTIAL_FREETYPE_INCLUDE_PATH="$new_path" 61245 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&5 61246 $as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&6;} 61247 fi 61248 61249 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 61250 61251 path="$POTENTIAL_FREETYPE_INCLUDE_PATH" 61252 has_colon=`$ECHO $path | $GREP ^.:` 61253 new_path="$path" 61254 if test "x$has_colon" = x; then 61255 # Not in mixed or Windows style, start by that. 61256 new_path=`cmd //c echo $path` 61257 fi 61258 61259 61260 input_path="$new_path" 61261 # Check if we need to convert this using DOS-style short mode. If the path 61262 # contains just simple characters, use it. Otherwise (spaces, weird characters), 61263 # take no chances and rewrite it. 61264 # Note: m4 eats our [], so we need to use [ and ] instead. 61265 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 61266 if test "x$has_forbidden_chars" != x; then 61267 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 61268 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 61269 fi 61270 61271 61272 windows_path="$new_path" 61273 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 61274 unix_path=`$CYGPATH -u "$windows_path"` 61275 new_path="$unix_path" 61276 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 61277 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 61278 new_path="$unix_path" 61279 fi 61280 61281 if test "x$path" != "x$new_path"; then 61282 POTENTIAL_FREETYPE_INCLUDE_PATH="$new_path" 61283 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&5 61284 $as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&6;} 61285 fi 61286 61287 # Save the first 10 bytes of this path to the storage, so fixpath can work. 61288 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 61289 61290 else 61291 # We're on a unix platform. Hooray! :) 61292 path="$POTENTIAL_FREETYPE_INCLUDE_PATH" 61293 has_space=`$ECHO "$path" | $GREP " "` 61294 if test "x$has_space" != x; then 61295 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&5 61296 $as_echo "$as_me: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&6;} 61297 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 61298 fi 61299 61300 # Use eval to expand a potential ~ 61301 eval path="$path" 61302 if test ! -f "$path" && test ! -d "$path"; then 61303 as_fn_error $? "The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is not found." "$LINENO" 5 61304 fi 61305 61306 if test -d "$path"; then 61307 POTENTIAL_FREETYPE_INCLUDE_PATH="`cd "$path"; $THEPWDCMD -L`" 61308 else 61309 dir="`$DIRNAME "$path"`" 61310 base="`$BASENAME "$path"`" 61311 POTENTIAL_FREETYPE_INCLUDE_PATH="`cd "$dir"; $THEPWDCMD -L`/$base" 61312 fi 61313 fi 61314 fi 61315 61316 61317 # Only process if variable expands to non-empty 61318 61319 if test "x$POTENTIAL_FREETYPE_LIB_PATH" != x; then 61320 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 61321 61322 # Input might be given as Windows format, start by converting to 61323 # unix format. 61324 path="$POTENTIAL_FREETYPE_LIB_PATH" 61325 new_path=`$CYGPATH -u "$path"` 61326 61327 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 61328 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 61329 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 61330 # "foo.exe" is OK but "foo" is an error. 61331 # 61332 # This test is therefore slightly more accurate than "test -f" to check for file precense. 61333 # It is also a way to make sure we got the proper file name for the real test later on. 61334 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 61335 if test "x$test_shortpath" = x; then 61336 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&5 61337 $as_echo "$as_me: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&6;} 61338 as_fn_error $? "Cannot locate the the path of POTENTIAL_FREETYPE_LIB_PATH" "$LINENO" 5 61339 fi 61340 61341 # Call helper function which possibly converts this using DOS-style short mode. 61342 # If so, the updated path is stored in $new_path. 61343 61344 input_path="$new_path" 61345 # Check if we need to convert this using DOS-style short mode. If the path 61346 # contains just simple characters, use it. Otherwise (spaces, weird characters), 61347 # take no chances and rewrite it. 61348 # Note: m4 eats our [], so we need to use [ and ] instead. 61349 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 61350 if test "x$has_forbidden_chars" != x; then 61351 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 61352 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 61353 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 61354 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 61355 # Going to short mode and back again did indeed matter. Since short mode is 61356 # case insensitive, let's make it lowercase to improve readability. 61357 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 61358 # Now convert it back to Unix-style (cygpath) 61359 input_path=`$CYGPATH -u "$shortmode_path"` 61360 new_path="$input_path" 61361 fi 61362 fi 61363 61364 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 61365 if test "x$test_cygdrive_prefix" = x; then 61366 # As a simple fix, exclude /usr/bin since it's not a real path. 61367 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 61368 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 61369 # a path prefixed by /cygdrive for fixpath to work. 61370 new_path="$CYGWIN_ROOT_PATH$input_path" 61371 fi 61372 fi 61373 61374 61375 if test "x$path" != "x$new_path"; then 61376 POTENTIAL_FREETYPE_LIB_PATH="$new_path" 61377 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&5 61378 $as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&6;} 61379 fi 61380 61381 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 61382 61383 path="$POTENTIAL_FREETYPE_LIB_PATH" 61384 has_colon=`$ECHO $path | $GREP ^.:` 61385 new_path="$path" 61386 if test "x$has_colon" = x; then 61387 # Not in mixed or Windows style, start by that. 61388 new_path=`cmd //c echo $path` 61389 fi 61390 61391 61392 input_path="$new_path" 61393 # Check if we need to convert this using DOS-style short mode. If the path 61394 # contains just simple characters, use it. Otherwise (spaces, weird characters), 61395 # take no chances and rewrite it. 61396 # Note: m4 eats our [], so we need to use [ and ] instead. 61397 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 61398 if test "x$has_forbidden_chars" != x; then 61399 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 61400 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 61401 fi 61402 61403 61404 windows_path="$new_path" 61405 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 61406 unix_path=`$CYGPATH -u "$windows_path"` 61407 new_path="$unix_path" 61408 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 61409 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 61410 new_path="$unix_path" 61411 fi 61412 61413 if test "x$path" != "x$new_path"; then 61414 POTENTIAL_FREETYPE_LIB_PATH="$new_path" 61415 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&5 61416 $as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&6;} 61417 fi 61418 61419 # Save the first 10 bytes of this path to the storage, so fixpath can work. 61420 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 61421 61422 else 61423 # We're on a unix platform. Hooray! :) 61424 path="$POTENTIAL_FREETYPE_LIB_PATH" 61425 has_space=`$ECHO "$path" | $GREP " "` 61426 if test "x$has_space" != x; then 61427 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&5 61428 $as_echo "$as_me: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&6;} 61429 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 61430 fi 61431 61432 # Use eval to expand a potential ~ 61433 eval path="$path" 61434 if test ! -f "$path" && test ! -d "$path"; then 61435 as_fn_error $? "The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is not found." "$LINENO" 5 61436 fi 61437 61438 if test -d "$path"; then 61439 POTENTIAL_FREETYPE_LIB_PATH="`cd "$path"; $THEPWDCMD -L`" 61440 else 61441 dir="`$DIRNAME "$path"`" 61442 base="`$BASENAME "$path"`" 61443 POTENTIAL_FREETYPE_LIB_PATH="`cd "$dir"; $THEPWDCMD -L`/$base" 61444 fi 61445 fi 61446 fi 61447 61448 61449 FREETYPE_INCLUDE_PATH="$POTENTIAL_FREETYPE_INCLUDE_PATH" 61450 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for freetype includes" >&5 61451 $as_echo_n "checking for freetype includes... " >&6; } 61452 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $FREETYPE_INCLUDE_PATH" >&5 61453 $as_echo "$FREETYPE_INCLUDE_PATH" >&6; } 61454 FREETYPE_LIB_PATH="$POTENTIAL_FREETYPE_LIB_PATH" 61455 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for freetype libraries" >&5 61456 $as_echo_n "checking for freetype libraries... " >&6; } 61457 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $FREETYPE_LIB_PATH" >&5 61458 $as_echo "$FREETYPE_LIB_PATH" >&6; } 61459 fi 61460 61461 else 61462 61463 POTENTIAL_FREETYPE_INCLUDE_PATH="$FREETYPE_BASE_DIR/include" 61464 POTENTIAL_FREETYPE_LIB_PATH="$FREETYPE_BASE_DIR/lib/i386-linux-gnu" 61465 METHOD="well-known location" 61466 61467 # Let's start with an optimistic view of the world :-) 61468 FOUND_FREETYPE=yes 61469 61470 # First look for the canonical freetype main include file ft2build.h. 61471 if ! test -s "$POTENTIAL_FREETYPE_INCLUDE_PATH/ft2build.h"; then 61472 # Oh no! Let's try in the freetype2 directory. This is needed at least at Mac OS X Yosemite. 61473 POTENTIAL_FREETYPE_INCLUDE_PATH="$POTENTIAL_FREETYPE_INCLUDE_PATH/freetype2" 61474 if ! test -s "$POTENTIAL_FREETYPE_INCLUDE_PATH/ft2build.h"; then 61475 # Fail. 61476 FOUND_FREETYPE=no 61477 fi 61478 fi 61479 61480 if test "x$FOUND_FREETYPE" = xyes; then 61481 # Include file found, let's continue the sanity check. 61482 { $as_echo "$as_me:${as_lineno-$LINENO}: Found freetype include files at $POTENTIAL_FREETYPE_INCLUDE_PATH using $METHOD" >&5 61483 $as_echo "$as_me: Found freetype include files at $POTENTIAL_FREETYPE_INCLUDE_PATH using $METHOD" >&6;} 61484 61485 # Reset to default value 61486 FREETYPE_BASE_NAME=freetype 61487 FREETYPE_LIB_NAME="${LIBRARY_PREFIX}${FREETYPE_BASE_NAME}${SHARED_LIBRARY_SUFFIX}" 61488 if ! test -s "$POTENTIAL_FREETYPE_LIB_PATH/$FREETYPE_LIB_NAME"; then 61489 if test "x$OPENJDK_TARGET_OS" = xmacosx \ 61490 && test -s "$POTENTIAL_FREETYPE_LIB_PATH/${LIBRARY_PREFIX}freetype.6${SHARED_LIBRARY_SUFFIX}"; then 61491 # On Mac OS X Yosemite, the symlink from libfreetype.dylib to libfreetype.6.dylib disappeared. Check 61492 # for the .6 version explicitly. 61493 FREETYPE_BASE_NAME=freetype.6 61494 FREETYPE_LIB_NAME="${LIBRARY_PREFIX}${FREETYPE_BASE_NAME}${SHARED_LIBRARY_SUFFIX}" 61495 { $as_echo "$as_me:${as_lineno-$LINENO}: Compensating for missing symlink by using version 6 explicitly" >&5 61496 $as_echo "$as_me: Compensating for missing symlink by using version 6 explicitly" >&6;} 61497 else 61498 { $as_echo "$as_me:${as_lineno-$LINENO}: Could not find $POTENTIAL_FREETYPE_LIB_PATH/$FREETYPE_LIB_NAME. Ignoring location." >&5 61499 $as_echo "$as_me: Could not find $POTENTIAL_FREETYPE_LIB_PATH/$FREETYPE_LIB_NAME. Ignoring location." >&6;} 61500 FOUND_FREETYPE=no 61501 fi 61502 else 61503 if test "x$OPENJDK_TARGET_OS" = xwindows; then 61504 # On Windows, we will need both .lib and .dll file. 61505 if ! test -s "$POTENTIAL_FREETYPE_LIB_PATH/${FREETYPE_BASE_NAME}.lib"; then 61506 { $as_echo "$as_me:${as_lineno-$LINENO}: Could not find $POTENTIAL_FREETYPE_LIB_PATH/${FREETYPE_BASE_NAME}.lib. Ignoring location." >&5 61507 $as_echo "$as_me: Could not find $POTENTIAL_FREETYPE_LIB_PATH/${FREETYPE_BASE_NAME}.lib. Ignoring location." >&6;} 61508 FOUND_FREETYPE=no 61509 fi 61510 elif test "x$OPENJDK_TARGET_OS" = xsolaris \ 61511 && test -s "$POTENTIAL_FREETYPE_LIB_PATH$OPENJDK_TARGET_CPU_ISADIR/$FREETYPE_LIB_NAME"; then 61512 # Found lib in isa dir, use that instead. 61513 POTENTIAL_FREETYPE_LIB_PATH="$POTENTIAL_FREETYPE_LIB_PATH$OPENJDK_TARGET_CPU_ISADIR" 61514 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting to use $POTENTIAL_FREETYPE_LIB_PATH instead" >&5 61515 $as_echo "$as_me: Rewriting to use $POTENTIAL_FREETYPE_LIB_PATH instead" >&6;} 61516 fi 61517 fi 61518 fi 61519 61520 if test "x$FOUND_FREETYPE" = xyes; then 61521 61522 # Only process if variable expands to non-empty 61523 61524 if test "x$POTENTIAL_FREETYPE_INCLUDE_PATH" != x; then 61525 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 61526 61527 # Input might be given as Windows format, start by converting to 61528 # unix format. 61529 path="$POTENTIAL_FREETYPE_INCLUDE_PATH" 61530 new_path=`$CYGPATH -u "$path"` 61531 61532 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 61533 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 61534 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 61535 # "foo.exe" is OK but "foo" is an error. 61536 # 61537 # This test is therefore slightly more accurate than "test -f" to check for file precense. 61538 # It is also a way to make sure we got the proper file name for the real test later on. 61539 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 61540 if test "x$test_shortpath" = x; then 61541 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&5 61542 $as_echo "$as_me: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&6;} 61543 as_fn_error $? "Cannot locate the the path of POTENTIAL_FREETYPE_INCLUDE_PATH" "$LINENO" 5 61544 fi 61545 61546 # Call helper function which possibly converts this using DOS-style short mode. 61547 # If so, the updated path is stored in $new_path. 61548 61549 input_path="$new_path" 61550 # Check if we need to convert this using DOS-style short mode. If the path 61551 # contains just simple characters, use it. Otherwise (spaces, weird characters), 61552 # take no chances and rewrite it. 61553 # Note: m4 eats our [], so we need to use [ and ] instead. 61554 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 61555 if test "x$has_forbidden_chars" != x; then 61556 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 61557 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 61558 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 61559 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 61560 # Going to short mode and back again did indeed matter. Since short mode is 61561 # case insensitive, let's make it lowercase to improve readability. 61562 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 61563 # Now convert it back to Unix-style (cygpath) 61564 input_path=`$CYGPATH -u "$shortmode_path"` 61565 new_path="$input_path" 61566 fi 61567 fi 61568 61569 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 61570 if test "x$test_cygdrive_prefix" = x; then 61571 # As a simple fix, exclude /usr/bin since it's not a real path. 61572 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 61573 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 61574 # a path prefixed by /cygdrive for fixpath to work. 61575 new_path="$CYGWIN_ROOT_PATH$input_path" 61576 fi 61577 fi 61578 61579 61580 if test "x$path" != "x$new_path"; then 61581 POTENTIAL_FREETYPE_INCLUDE_PATH="$new_path" 61582 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&5 61583 $as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&6;} 61584 fi 61585 61586 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 61587 61588 path="$POTENTIAL_FREETYPE_INCLUDE_PATH" 61589 has_colon=`$ECHO $path | $GREP ^.:` 61590 new_path="$path" 61591 if test "x$has_colon" = x; then 61592 # Not in mixed or Windows style, start by that. 61593 new_path=`cmd //c echo $path` 61594 fi 61595 61596 61597 input_path="$new_path" 61598 # Check if we need to convert this using DOS-style short mode. If the path 61599 # contains just simple characters, use it. Otherwise (spaces, weird characters), 61600 # take no chances and rewrite it. 61601 # Note: m4 eats our [], so we need to use [ and ] instead. 61602 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 61603 if test "x$has_forbidden_chars" != x; then 61604 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 61605 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 61606 fi 61607 61608 61609 windows_path="$new_path" 61610 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 61611 unix_path=`$CYGPATH -u "$windows_path"` 61612 new_path="$unix_path" 61613 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 61614 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 61615 new_path="$unix_path" 61616 fi 61617 61618 if test "x$path" != "x$new_path"; then 61619 POTENTIAL_FREETYPE_INCLUDE_PATH="$new_path" 61620 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&5 61621 $as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&6;} 61622 fi 61623 61624 # Save the first 10 bytes of this path to the storage, so fixpath can work. 61625 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 61626 61627 else 61628 # We're on a unix platform. Hooray! :) 61629 path="$POTENTIAL_FREETYPE_INCLUDE_PATH" 61630 has_space=`$ECHO "$path" | $GREP " "` 61631 if test "x$has_space" != x; then 61632 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&5 61633 $as_echo "$as_me: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&6;} 61634 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 61635 fi 61636 61637 # Use eval to expand a potential ~ 61638 eval path="$path" 61639 if test ! -f "$path" && test ! -d "$path"; then 61640 as_fn_error $? "The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is not found." "$LINENO" 5 61641 fi 61642 61643 if test -d "$path"; then 61644 POTENTIAL_FREETYPE_INCLUDE_PATH="`cd "$path"; $THEPWDCMD -L`" 61645 else 61646 dir="`$DIRNAME "$path"`" 61647 base="`$BASENAME "$path"`" 61648 POTENTIAL_FREETYPE_INCLUDE_PATH="`cd "$dir"; $THEPWDCMD -L`/$base" 61649 fi 61650 fi 61651 fi 61652 61653 61654 # Only process if variable expands to non-empty 61655 61656 if test "x$POTENTIAL_FREETYPE_LIB_PATH" != x; then 61657 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 61658 61659 # Input might be given as Windows format, start by converting to 61660 # unix format. 61661 path="$POTENTIAL_FREETYPE_LIB_PATH" 61662 new_path=`$CYGPATH -u "$path"` 61663 61664 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 61665 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 61666 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 61667 # "foo.exe" is OK but "foo" is an error. 61668 # 61669 # This test is therefore slightly more accurate than "test -f" to check for file precense. 61670 # It is also a way to make sure we got the proper file name for the real test later on. 61671 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 61672 if test "x$test_shortpath" = x; then 61673 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&5 61674 $as_echo "$as_me: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&6;} 61675 as_fn_error $? "Cannot locate the the path of POTENTIAL_FREETYPE_LIB_PATH" "$LINENO" 5 61676 fi 61677 61678 # Call helper function which possibly converts this using DOS-style short mode. 61679 # If so, the updated path is stored in $new_path. 61680 61681 input_path="$new_path" 61682 # Check if we need to convert this using DOS-style short mode. If the path 61683 # contains just simple characters, use it. Otherwise (spaces, weird characters), 61684 # take no chances and rewrite it. 61685 # Note: m4 eats our [], so we need to use [ and ] instead. 61686 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 61687 if test "x$has_forbidden_chars" != x; then 61688 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 61689 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 61690 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 61691 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 61692 # Going to short mode and back again did indeed matter. Since short mode is 61693 # case insensitive, let's make it lowercase to improve readability. 61694 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 61695 # Now convert it back to Unix-style (cygpath) 61696 input_path=`$CYGPATH -u "$shortmode_path"` 61697 new_path="$input_path" 61698 fi 61699 fi 61700 61701 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 61702 if test "x$test_cygdrive_prefix" = x; then 61703 # As a simple fix, exclude /usr/bin since it's not a real path. 61704 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 61705 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 61706 # a path prefixed by /cygdrive for fixpath to work. 61707 new_path="$CYGWIN_ROOT_PATH$input_path" 61708 fi 61709 fi 61710 61711 61712 if test "x$path" != "x$new_path"; then 61713 POTENTIAL_FREETYPE_LIB_PATH="$new_path" 61714 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&5 61715 $as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&6;} 61716 fi 61717 61718 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 61719 61720 path="$POTENTIAL_FREETYPE_LIB_PATH" 61721 has_colon=`$ECHO $path | $GREP ^.:` 61722 new_path="$path" 61723 if test "x$has_colon" = x; then 61724 # Not in mixed or Windows style, start by that. 61725 new_path=`cmd //c echo $path` 61726 fi 61727 61728 61729 input_path="$new_path" 61730 # Check if we need to convert this using DOS-style short mode. If the path 61731 # contains just simple characters, use it. Otherwise (spaces, weird characters), 61732 # take no chances and rewrite it. 61733 # Note: m4 eats our [], so we need to use [ and ] instead. 61734 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 61735 if test "x$has_forbidden_chars" != x; then 61736 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 61737 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 61738 fi 61739 61740 61741 windows_path="$new_path" 61742 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 61743 unix_path=`$CYGPATH -u "$windows_path"` 61744 new_path="$unix_path" 61745 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 61746 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 61747 new_path="$unix_path" 61748 fi 61749 61750 if test "x$path" != "x$new_path"; then 61751 POTENTIAL_FREETYPE_LIB_PATH="$new_path" 61752 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&5 61753 $as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&6;} 61754 fi 61755 61756 # Save the first 10 bytes of this path to the storage, so fixpath can work. 61757 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 61758 61759 else 61760 # We're on a unix platform. Hooray! :) 61761 path="$POTENTIAL_FREETYPE_LIB_PATH" 61762 has_space=`$ECHO "$path" | $GREP " "` 61763 if test "x$has_space" != x; then 61764 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&5 61765 $as_echo "$as_me: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&6;} 61766 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 61767 fi 61768 61769 # Use eval to expand a potential ~ 61770 eval path="$path" 61771 if test ! -f "$path" && test ! -d "$path"; then 61772 as_fn_error $? "The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is not found." "$LINENO" 5 61773 fi 61774 61775 if test -d "$path"; then 61776 POTENTIAL_FREETYPE_LIB_PATH="`cd "$path"; $THEPWDCMD -L`" 61777 else 61778 dir="`$DIRNAME "$path"`" 61779 base="`$BASENAME "$path"`" 61780 POTENTIAL_FREETYPE_LIB_PATH="`cd "$dir"; $THEPWDCMD -L`/$base" 61781 fi 61782 fi 61783 fi 61784 61785 61786 FREETYPE_INCLUDE_PATH="$POTENTIAL_FREETYPE_INCLUDE_PATH" 61787 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for freetype includes" >&5 61788 $as_echo_n "checking for freetype includes... " >&6; } 61789 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $FREETYPE_INCLUDE_PATH" >&5 61790 $as_echo "$FREETYPE_INCLUDE_PATH" >&6; } 61791 FREETYPE_LIB_PATH="$POTENTIAL_FREETYPE_LIB_PATH" 61792 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for freetype libraries" >&5 61793 $as_echo_n "checking for freetype libraries... " >&6; } 61794 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $FREETYPE_LIB_PATH" >&5 61795 $as_echo "$FREETYPE_LIB_PATH" >&6; } 61796 fi 61797 61798 if test "x$FOUND_FREETYPE" != xyes; then 61799 61800 POTENTIAL_FREETYPE_INCLUDE_PATH="$FREETYPE_BASE_DIR/include" 61801 POTENTIAL_FREETYPE_LIB_PATH="$FREETYPE_BASE_DIR/lib32" 61802 METHOD="well-known location" 61803 61804 # Let's start with an optimistic view of the world :-) 61805 FOUND_FREETYPE=yes 61806 61807 # First look for the canonical freetype main include file ft2build.h. 61808 if ! test -s "$POTENTIAL_FREETYPE_INCLUDE_PATH/ft2build.h"; then 61809 # Oh no! Let's try in the freetype2 directory. This is needed at least at Mac OS X Yosemite. 61810 POTENTIAL_FREETYPE_INCLUDE_PATH="$POTENTIAL_FREETYPE_INCLUDE_PATH/freetype2" 61811 if ! test -s "$POTENTIAL_FREETYPE_INCLUDE_PATH/ft2build.h"; then 61812 # Fail. 61813 FOUND_FREETYPE=no 61814 fi 61815 fi 61816 61817 if test "x$FOUND_FREETYPE" = xyes; then 61818 # Include file found, let's continue the sanity check. 61819 { $as_echo "$as_me:${as_lineno-$LINENO}: Found freetype include files at $POTENTIAL_FREETYPE_INCLUDE_PATH using $METHOD" >&5 61820 $as_echo "$as_me: Found freetype include files at $POTENTIAL_FREETYPE_INCLUDE_PATH using $METHOD" >&6;} 61821 61822 # Reset to default value 61823 FREETYPE_BASE_NAME=freetype 61824 FREETYPE_LIB_NAME="${LIBRARY_PREFIX}${FREETYPE_BASE_NAME}${SHARED_LIBRARY_SUFFIX}" 61825 if ! test -s "$POTENTIAL_FREETYPE_LIB_PATH/$FREETYPE_LIB_NAME"; then 61826 if test "x$OPENJDK_TARGET_OS" = xmacosx \ 61827 && test -s "$POTENTIAL_FREETYPE_LIB_PATH/${LIBRARY_PREFIX}freetype.6${SHARED_LIBRARY_SUFFIX}"; then 61828 # On Mac OS X Yosemite, the symlink from libfreetype.dylib to libfreetype.6.dylib disappeared. Check 61829 # for the .6 version explicitly. 61830 FREETYPE_BASE_NAME=freetype.6 61831 FREETYPE_LIB_NAME="${LIBRARY_PREFIX}${FREETYPE_BASE_NAME}${SHARED_LIBRARY_SUFFIX}" 61832 { $as_echo "$as_me:${as_lineno-$LINENO}: Compensating for missing symlink by using version 6 explicitly" >&5 61833 $as_echo "$as_me: Compensating for missing symlink by using version 6 explicitly" >&6;} 61834 else 61835 { $as_echo "$as_me:${as_lineno-$LINENO}: Could not find $POTENTIAL_FREETYPE_LIB_PATH/$FREETYPE_LIB_NAME. Ignoring location." >&5 61836 $as_echo "$as_me: Could not find $POTENTIAL_FREETYPE_LIB_PATH/$FREETYPE_LIB_NAME. Ignoring location." >&6;} 61837 FOUND_FREETYPE=no 61838 fi 61839 else 61840 if test "x$OPENJDK_TARGET_OS" = xwindows; then 61841 # On Windows, we will need both .lib and .dll file. 61842 if ! test -s "$POTENTIAL_FREETYPE_LIB_PATH/${FREETYPE_BASE_NAME}.lib"; then 61843 { $as_echo "$as_me:${as_lineno-$LINENO}: Could not find $POTENTIAL_FREETYPE_LIB_PATH/${FREETYPE_BASE_NAME}.lib. Ignoring location." >&5 61844 $as_echo "$as_me: Could not find $POTENTIAL_FREETYPE_LIB_PATH/${FREETYPE_BASE_NAME}.lib. Ignoring location." >&6;} 61845 FOUND_FREETYPE=no 61846 fi 61847 elif test "x$OPENJDK_TARGET_OS" = xsolaris \ 61848 && test -s "$POTENTIAL_FREETYPE_LIB_PATH$OPENJDK_TARGET_CPU_ISADIR/$FREETYPE_LIB_NAME"; then 61849 # Found lib in isa dir, use that instead. 61850 POTENTIAL_FREETYPE_LIB_PATH="$POTENTIAL_FREETYPE_LIB_PATH$OPENJDK_TARGET_CPU_ISADIR" 61851 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting to use $POTENTIAL_FREETYPE_LIB_PATH instead" >&5 61852 $as_echo "$as_me: Rewriting to use $POTENTIAL_FREETYPE_LIB_PATH instead" >&6;} 61853 fi 61854 fi 61855 fi 61856 61857 if test "x$FOUND_FREETYPE" = xyes; then 61858 61859 # Only process if variable expands to non-empty 61860 61861 if test "x$POTENTIAL_FREETYPE_INCLUDE_PATH" != x; then 61862 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 61863 61864 # Input might be given as Windows format, start by converting to 61865 # unix format. 61866 path="$POTENTIAL_FREETYPE_INCLUDE_PATH" 61867 new_path=`$CYGPATH -u "$path"` 61868 61869 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 61870 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 61871 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 61872 # "foo.exe" is OK but "foo" is an error. 61873 # 61874 # This test is therefore slightly more accurate than "test -f" to check for file precense. 61875 # It is also a way to make sure we got the proper file name for the real test later on. 61876 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 61877 if test "x$test_shortpath" = x; then 61878 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&5 61879 $as_echo "$as_me: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&6;} 61880 as_fn_error $? "Cannot locate the the path of POTENTIAL_FREETYPE_INCLUDE_PATH" "$LINENO" 5 61881 fi 61882 61883 # Call helper function which possibly converts this using DOS-style short mode. 61884 # If so, the updated path is stored in $new_path. 61885 61886 input_path="$new_path" 61887 # Check if we need to convert this using DOS-style short mode. If the path 61888 # contains just simple characters, use it. Otherwise (spaces, weird characters), 61889 # take no chances and rewrite it. 61890 # Note: m4 eats our [], so we need to use [ and ] instead. 61891 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 61892 if test "x$has_forbidden_chars" != x; then 61893 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 61894 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 61895 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 61896 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 61897 # Going to short mode and back again did indeed matter. Since short mode is 61898 # case insensitive, let's make it lowercase to improve readability. 61899 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 61900 # Now convert it back to Unix-style (cygpath) 61901 input_path=`$CYGPATH -u "$shortmode_path"` 61902 new_path="$input_path" 61903 fi 61904 fi 61905 61906 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 61907 if test "x$test_cygdrive_prefix" = x; then 61908 # As a simple fix, exclude /usr/bin since it's not a real path. 61909 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 61910 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 61911 # a path prefixed by /cygdrive for fixpath to work. 61912 new_path="$CYGWIN_ROOT_PATH$input_path" 61913 fi 61914 fi 61915 61916 61917 if test "x$path" != "x$new_path"; then 61918 POTENTIAL_FREETYPE_INCLUDE_PATH="$new_path" 61919 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&5 61920 $as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&6;} 61921 fi 61922 61923 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 61924 61925 path="$POTENTIAL_FREETYPE_INCLUDE_PATH" 61926 has_colon=`$ECHO $path | $GREP ^.:` 61927 new_path="$path" 61928 if test "x$has_colon" = x; then 61929 # Not in mixed or Windows style, start by that. 61930 new_path=`cmd //c echo $path` 61931 fi 61932 61933 61934 input_path="$new_path" 61935 # Check if we need to convert this using DOS-style short mode. If the path 61936 # contains just simple characters, use it. Otherwise (spaces, weird characters), 61937 # take no chances and rewrite it. 61938 # Note: m4 eats our [], so we need to use [ and ] instead. 61939 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 61940 if test "x$has_forbidden_chars" != x; then 61941 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 61942 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 61943 fi 61944 61945 61946 windows_path="$new_path" 61947 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 61948 unix_path=`$CYGPATH -u "$windows_path"` 61949 new_path="$unix_path" 61950 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 61951 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 61952 new_path="$unix_path" 61953 fi 61954 61955 if test "x$path" != "x$new_path"; then 61956 POTENTIAL_FREETYPE_INCLUDE_PATH="$new_path" 61957 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&5 61958 $as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&6;} 61959 fi 61960 61961 # Save the first 10 bytes of this path to the storage, so fixpath can work. 61962 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 61963 61964 else 61965 # We're on a unix platform. Hooray! :) 61966 path="$POTENTIAL_FREETYPE_INCLUDE_PATH" 61967 has_space=`$ECHO "$path" | $GREP " "` 61968 if test "x$has_space" != x; then 61969 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&5 61970 $as_echo "$as_me: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&6;} 61971 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 61972 fi 61973 61974 # Use eval to expand a potential ~ 61975 eval path="$path" 61976 if test ! -f "$path" && test ! -d "$path"; then 61977 as_fn_error $? "The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is not found." "$LINENO" 5 61978 fi 61979 61980 if test -d "$path"; then 61981 POTENTIAL_FREETYPE_INCLUDE_PATH="`cd "$path"; $THEPWDCMD -L`" 61982 else 61983 dir="`$DIRNAME "$path"`" 61984 base="`$BASENAME "$path"`" 61985 POTENTIAL_FREETYPE_INCLUDE_PATH="`cd "$dir"; $THEPWDCMD -L`/$base" 61986 fi 61987 fi 61988 fi 61989 61990 61991 # Only process if variable expands to non-empty 61992 61993 if test "x$POTENTIAL_FREETYPE_LIB_PATH" != x; then 61994 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 61995 61996 # Input might be given as Windows format, start by converting to 61997 # unix format. 61998 path="$POTENTIAL_FREETYPE_LIB_PATH" 61999 new_path=`$CYGPATH -u "$path"` 62000 62001 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 62002 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 62003 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 62004 # "foo.exe" is OK but "foo" is an error. 62005 # 62006 # This test is therefore slightly more accurate than "test -f" to check for file precense. 62007 # It is also a way to make sure we got the proper file name for the real test later on. 62008 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 62009 if test "x$test_shortpath" = x; then 62010 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&5 62011 $as_echo "$as_me: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&6;} 62012 as_fn_error $? "Cannot locate the the path of POTENTIAL_FREETYPE_LIB_PATH" "$LINENO" 5 62013 fi 62014 62015 # Call helper function which possibly converts this using DOS-style short mode. 62016 # If so, the updated path is stored in $new_path. 62017 62018 input_path="$new_path" 62019 # Check if we need to convert this using DOS-style short mode. If the path 62020 # contains just simple characters, use it. Otherwise (spaces, weird characters), 62021 # take no chances and rewrite it. 62022 # Note: m4 eats our [], so we need to use [ and ] instead. 62023 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 62024 if test "x$has_forbidden_chars" != x; then 62025 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 62026 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 62027 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 62028 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 62029 # Going to short mode and back again did indeed matter. Since short mode is 62030 # case insensitive, let's make it lowercase to improve readability. 62031 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 62032 # Now convert it back to Unix-style (cygpath) 62033 input_path=`$CYGPATH -u "$shortmode_path"` 62034 new_path="$input_path" 62035 fi 62036 fi 62037 62038 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 62039 if test "x$test_cygdrive_prefix" = x; then 62040 # As a simple fix, exclude /usr/bin since it's not a real path. 62041 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 62042 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 62043 # a path prefixed by /cygdrive for fixpath to work. 62044 new_path="$CYGWIN_ROOT_PATH$input_path" 62045 fi 62046 fi 62047 62048 62049 if test "x$path" != "x$new_path"; then 62050 POTENTIAL_FREETYPE_LIB_PATH="$new_path" 62051 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&5 62052 $as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&6;} 62053 fi 62054 62055 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 62056 62057 path="$POTENTIAL_FREETYPE_LIB_PATH" 62058 has_colon=`$ECHO $path | $GREP ^.:` 62059 new_path="$path" 62060 if test "x$has_colon" = x; then 62061 # Not in mixed or Windows style, start by that. 62062 new_path=`cmd //c echo $path` 62063 fi 62064 62065 62066 input_path="$new_path" 62067 # Check if we need to convert this using DOS-style short mode. If the path 62068 # contains just simple characters, use it. Otherwise (spaces, weird characters), 62069 # take no chances and rewrite it. 62070 # Note: m4 eats our [], so we need to use [ and ] instead. 62071 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 62072 if test "x$has_forbidden_chars" != x; then 62073 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 62074 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 62075 fi 62076 62077 62078 windows_path="$new_path" 62079 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 62080 unix_path=`$CYGPATH -u "$windows_path"` 62081 new_path="$unix_path" 62082 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 62083 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 62084 new_path="$unix_path" 62085 fi 62086 62087 if test "x$path" != "x$new_path"; then 62088 POTENTIAL_FREETYPE_LIB_PATH="$new_path" 62089 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&5 62090 $as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&6;} 62091 fi 62092 62093 # Save the first 10 bytes of this path to the storage, so fixpath can work. 62094 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 62095 62096 else 62097 # We're on a unix platform. Hooray! :) 62098 path="$POTENTIAL_FREETYPE_LIB_PATH" 62099 has_space=`$ECHO "$path" | $GREP " "` 62100 if test "x$has_space" != x; then 62101 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&5 62102 $as_echo "$as_me: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&6;} 62103 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 62104 fi 62105 62106 # Use eval to expand a potential ~ 62107 eval path="$path" 62108 if test ! -f "$path" && test ! -d "$path"; then 62109 as_fn_error $? "The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is not found." "$LINENO" 5 62110 fi 62111 62112 if test -d "$path"; then 62113 POTENTIAL_FREETYPE_LIB_PATH="`cd "$path"; $THEPWDCMD -L`" 62114 else 62115 dir="`$DIRNAME "$path"`" 62116 base="`$BASENAME "$path"`" 62117 POTENTIAL_FREETYPE_LIB_PATH="`cd "$dir"; $THEPWDCMD -L`/$base" 62118 fi 62119 fi 62120 fi 62121 62122 62123 FREETYPE_INCLUDE_PATH="$POTENTIAL_FREETYPE_INCLUDE_PATH" 62124 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for freetype includes" >&5 62125 $as_echo_n "checking for freetype includes... " >&6; } 62126 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $FREETYPE_INCLUDE_PATH" >&5 62127 $as_echo "$FREETYPE_INCLUDE_PATH" >&6; } 62128 FREETYPE_LIB_PATH="$POTENTIAL_FREETYPE_LIB_PATH" 62129 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for freetype libraries" >&5 62130 $as_echo_n "checking for freetype libraries... " >&6; } 62131 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $FREETYPE_LIB_PATH" >&5 62132 $as_echo "$FREETYPE_LIB_PATH" >&6; } 62133 fi 62134 62135 fi 62136 fi 62137 fi 62138 fi 62139 fi # end check in well-known locations 62140 62141 if test "x$FOUND_FREETYPE" != xyes; then 62142 62143 # Print a helpful message on how to acquire the necessary build dependency. 62144 # freetype is the help tag: freetype, cups, alsa etc 62145 MISSING_DEPENDENCY=freetype 62146 62147 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 62148 cygwin_help $MISSING_DEPENDENCY 62149 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 62150 msys_help $MISSING_DEPENDENCY 62151 else 62152 PKGHANDLER_COMMAND= 62153 62154 case $PKGHANDLER in 62155 apt-get) 62156 apt_help $MISSING_DEPENDENCY ;; 62157 yum) 62158 yum_help $MISSING_DEPENDENCY ;; 62159 port) 62160 port_help $MISSING_DEPENDENCY ;; 62161 pkgutil) 62162 pkgutil_help $MISSING_DEPENDENCY ;; 62163 pkgadd) 62164 pkgadd_help $MISSING_DEPENDENCY ;; 62165 esac 62166 62167 if test "x$PKGHANDLER_COMMAND" != x; then 62168 HELP_MSG="You might be able to fix this by running '$PKGHANDLER_COMMAND'." 62169 fi 62170 fi 62171 62172 as_fn_error $? "Could not find freetype! $HELP_MSG " "$LINENO" 5 62173 fi 62174 fi # end user specified settings 62175 62176 # Set FREETYPE_CFLAGS, _LIBS and _LIB_PATH from include and lib dir. 62177 if test "x$FREETYPE_CFLAGS" = x; then 62178 62179 # Only process if variable expands to non-empty 62180 62181 if test "x$FREETYPE_INCLUDE_PATH" != x; then 62182 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 62183 62184 # Input might be given as Windows format, start by converting to 62185 # unix format. 62186 path="$FREETYPE_INCLUDE_PATH" 62187 new_path=`$CYGPATH -u "$path"` 62188 62189 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 62190 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 62191 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 62192 # "foo.exe" is OK but "foo" is an error. 62193 # 62194 # This test is therefore slightly more accurate than "test -f" to check for file precense. 62195 # It is also a way to make sure we got the proper file name for the real test later on. 62196 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 62197 if test "x$test_shortpath" = x; then 62198 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&5 62199 $as_echo "$as_me: The path of FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&6;} 62200 as_fn_error $? "Cannot locate the the path of FREETYPE_INCLUDE_PATH" "$LINENO" 5 62201 fi 62202 62203 # Call helper function which possibly converts this using DOS-style short mode. 62204 # If so, the updated path is stored in $new_path. 62205 62206 input_path="$new_path" 62207 # Check if we need to convert this using DOS-style short mode. If the path 62208 # contains just simple characters, use it. Otherwise (spaces, weird characters), 62209 # take no chances and rewrite it. 62210 # Note: m4 eats our [], so we need to use [ and ] instead. 62211 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 62212 if test "x$has_forbidden_chars" != x; then 62213 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 62214 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 62215 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 62216 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 62217 # Going to short mode and back again did indeed matter. Since short mode is 62218 # case insensitive, let's make it lowercase to improve readability. 62219 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 62220 # Now convert it back to Unix-style (cygpath) 62221 input_path=`$CYGPATH -u "$shortmode_path"` 62222 new_path="$input_path" 62223 fi 62224 fi 62225 62226 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 62227 if test "x$test_cygdrive_prefix" = x; then 62228 # As a simple fix, exclude /usr/bin since it's not a real path. 62229 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 62230 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 62231 # a path prefixed by /cygdrive for fixpath to work. 62232 new_path="$CYGWIN_ROOT_PATH$input_path" 62233 fi 62234 fi 62235 62236 62237 if test "x$path" != "x$new_path"; then 62238 FREETYPE_INCLUDE_PATH="$new_path" 62239 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting FREETYPE_INCLUDE_PATH to \"$new_path\"" >&5 62240 $as_echo "$as_me: Rewriting FREETYPE_INCLUDE_PATH to \"$new_path\"" >&6;} 62241 fi 62242 62243 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 62244 62245 path="$FREETYPE_INCLUDE_PATH" 62246 has_colon=`$ECHO $path | $GREP ^.:` 62247 new_path="$path" 62248 if test "x$has_colon" = x; then 62249 # Not in mixed or Windows style, start by that. 62250 new_path=`cmd //c echo $path` 62251 fi 62252 62253 62254 input_path="$new_path" 62255 # Check if we need to convert this using DOS-style short mode. If the path 62256 # contains just simple characters, use it. Otherwise (spaces, weird characters), 62257 # take no chances and rewrite it. 62258 # Note: m4 eats our [], so we need to use [ and ] instead. 62259 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 62260 if test "x$has_forbidden_chars" != x; then 62261 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 62262 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 62263 fi 62264 62265 62266 windows_path="$new_path" 62267 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 62268 unix_path=`$CYGPATH -u "$windows_path"` 62269 new_path="$unix_path" 62270 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 62271 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 62272 new_path="$unix_path" 62273 fi 62274 62275 if test "x$path" != "x$new_path"; then 62276 FREETYPE_INCLUDE_PATH="$new_path" 62277 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting FREETYPE_INCLUDE_PATH to \"$new_path\"" >&5 62278 $as_echo "$as_me: Rewriting FREETYPE_INCLUDE_PATH to \"$new_path\"" >&6;} 62279 fi 62280 62281 # Save the first 10 bytes of this path to the storage, so fixpath can work. 62282 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 62283 62284 else 62285 # We're on a unix platform. Hooray! :) 62286 path="$FREETYPE_INCLUDE_PATH" 62287 has_space=`$ECHO "$path" | $GREP " "` 62288 if test "x$has_space" != x; then 62289 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&5 62290 $as_echo "$as_me: The path of FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&6;} 62291 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 62292 fi 62293 62294 # Use eval to expand a potential ~ 62295 eval path="$path" 62296 if test ! -f "$path" && test ! -d "$path"; then 62297 as_fn_error $? "The path of FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is not found." "$LINENO" 5 62298 fi 62299 62300 if test -d "$path"; then 62301 FREETYPE_INCLUDE_PATH="`cd "$path"; $THEPWDCMD -L`" 62302 else 62303 dir="`$DIRNAME "$path"`" 62304 base="`$BASENAME "$path"`" 62305 FREETYPE_INCLUDE_PATH="`cd "$dir"; $THEPWDCMD -L`/$base" 62306 fi 62307 fi 62308 fi 62309 62310 if test -d $FREETYPE_INCLUDE_PATH/freetype2/freetype; then 62311 FREETYPE_CFLAGS="-I$FREETYPE_INCLUDE_PATH/freetype2 -I$FREETYPE_INCLUDE_PATH" 62312 else 62313 FREETYPE_CFLAGS="-I$FREETYPE_INCLUDE_PATH" 62314 fi 62315 fi 62316 62317 if test "x$FREETYPE_LIBS" = x; then 62318 62319 # Only process if variable expands to non-empty 62320 62321 if test "x$FREETYPE_LIB_PATH" != x; then 62322 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 62323 62324 # Input might be given as Windows format, start by converting to 62325 # unix format. 62326 path="$FREETYPE_LIB_PATH" 62327 new_path=`$CYGPATH -u "$path"` 62328 62329 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 62330 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 62331 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 62332 # "foo.exe" is OK but "foo" is an error. 62333 # 62334 # This test is therefore slightly more accurate than "test -f" to check for file precense. 62335 # It is also a way to make sure we got the proper file name for the real test later on. 62336 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 62337 if test "x$test_shortpath" = x; then 62338 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&5 62339 $as_echo "$as_me: The path of FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&6;} 62340 as_fn_error $? "Cannot locate the the path of FREETYPE_LIB_PATH" "$LINENO" 5 62341 fi 62342 62343 # Call helper function which possibly converts this using DOS-style short mode. 62344 # If so, the updated path is stored in $new_path. 62345 62346 input_path="$new_path" 62347 # Check if we need to convert this using DOS-style short mode. If the path 62348 # contains just simple characters, use it. Otherwise (spaces, weird characters), 62349 # take no chances and rewrite it. 62350 # Note: m4 eats our [], so we need to use [ and ] instead. 62351 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 62352 if test "x$has_forbidden_chars" != x; then 62353 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 62354 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 62355 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 62356 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 62357 # Going to short mode and back again did indeed matter. Since short mode is 62358 # case insensitive, let's make it lowercase to improve readability. 62359 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 62360 # Now convert it back to Unix-style (cygpath) 62361 input_path=`$CYGPATH -u "$shortmode_path"` 62362 new_path="$input_path" 62363 fi 62364 fi 62365 62366 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 62367 if test "x$test_cygdrive_prefix" = x; then 62368 # As a simple fix, exclude /usr/bin since it's not a real path. 62369 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 62370 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 62371 # a path prefixed by /cygdrive for fixpath to work. 62372 new_path="$CYGWIN_ROOT_PATH$input_path" 62373 fi 62374 fi 62375 62376 62377 if test "x$path" != "x$new_path"; then 62378 FREETYPE_LIB_PATH="$new_path" 62379 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting FREETYPE_LIB_PATH to \"$new_path\"" >&5 62380 $as_echo "$as_me: Rewriting FREETYPE_LIB_PATH to \"$new_path\"" >&6;} 62381 fi 62382 62383 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 62384 62385 path="$FREETYPE_LIB_PATH" 62386 has_colon=`$ECHO $path | $GREP ^.:` 62387 new_path="$path" 62388 if test "x$has_colon" = x; then 62389 # Not in mixed or Windows style, start by that. 62390 new_path=`cmd //c echo $path` 62391 fi 62392 62393 62394 input_path="$new_path" 62395 # Check if we need to convert this using DOS-style short mode. If the path 62396 # contains just simple characters, use it. Otherwise (spaces, weird characters), 62397 # take no chances and rewrite it. 62398 # Note: m4 eats our [], so we need to use [ and ] instead. 62399 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 62400 if test "x$has_forbidden_chars" != x; then 62401 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 62402 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 62403 fi 62404 62405 62406 windows_path="$new_path" 62407 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 62408 unix_path=`$CYGPATH -u "$windows_path"` 62409 new_path="$unix_path" 62410 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 62411 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 62412 new_path="$unix_path" 62413 fi 62414 62415 if test "x$path" != "x$new_path"; then 62416 FREETYPE_LIB_PATH="$new_path" 62417 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting FREETYPE_LIB_PATH to \"$new_path\"" >&5 62418 $as_echo "$as_me: Rewriting FREETYPE_LIB_PATH to \"$new_path\"" >&6;} 62419 fi 62420 62421 # Save the first 10 bytes of this path to the storage, so fixpath can work. 62422 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 62423 62424 else 62425 # We're on a unix platform. Hooray! :) 62426 path="$FREETYPE_LIB_PATH" 62427 has_space=`$ECHO "$path" | $GREP " "` 62428 if test "x$has_space" != x; then 62429 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&5 62430 $as_echo "$as_me: The path of FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&6;} 62431 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 62432 fi 62433 62434 # Use eval to expand a potential ~ 62435 eval path="$path" 62436 if test ! -f "$path" && test ! -d "$path"; then 62437 as_fn_error $? "The path of FREETYPE_LIB_PATH, which resolves as \"$path\", is not found." "$LINENO" 5 62438 fi 62439 62440 if test -d "$path"; then 62441 FREETYPE_LIB_PATH="`cd "$path"; $THEPWDCMD -L`" 62442 else 62443 dir="`$DIRNAME "$path"`" 62444 base="`$BASENAME "$path"`" 62445 FREETYPE_LIB_PATH="`cd "$dir"; $THEPWDCMD -L`/$base" 62446 fi 62447 fi 62448 fi 62449 62450 if test "x$OPENJDK_TARGET_OS" = xwindows; then 62451 FREETYPE_LIBS="$FREETYPE_LIB_PATH/$FREETYPE_BASE_NAME.lib" 62452 else 62453 FREETYPE_LIBS="-L$FREETYPE_LIB_PATH -l$FREETYPE_BASE_NAME" 62454 fi 62455 fi 62456 62457 # Try to compile it 62458 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if we can compile and link with freetype" >&5 62459 $as_echo_n "checking if we can compile and link with freetype... " >&6; } 62460 ac_ext=cpp 62461 ac_cpp='$CXXCPP $CPPFLAGS' 62462 ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5' 62463 ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' 62464 ac_compiler_gnu=$ac_cv_cxx_compiler_gnu 62465 62466 PREV_CXXCFLAGS="$CXXFLAGS" 62467 PREV_LIBS="$LIBS" 62468 PREV_CXX="$CXX" 62469 CXXFLAGS="$CXXFLAGS $FREETYPE_CFLAGS" 62470 LIBS="$LIBS $FREETYPE_LIBS" 62471 CXX="$FIXPATH $CXX" 62472 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 62473 /* end confdefs.h. */ 62474 62475 #include<ft2build.h> 62476 #include FT_FREETYPE_H 62477 int main () { 62478 FT_Init_FreeType(NULL); 62479 return 0; 62480 } 62481 62482 _ACEOF 62483 if ac_fn_cxx_try_link "$LINENO"; then : 62484 62485 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 62486 $as_echo "yes" >&6; } 62487 62488 else 62489 62490 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 62491 $as_echo "no" >&6; } 62492 { $as_echo "$as_me:${as_lineno-$LINENO}: Could not compile and link with freetype. This might be a 32/64-bit mismatch." >&5 62493 $as_echo "$as_me: Could not compile and link with freetype. This might be a 32/64-bit mismatch." >&6;} 62494 { $as_echo "$as_me:${as_lineno-$LINENO}: Using FREETYPE_CFLAGS=$FREETYPE_CFLAGS and FREETYPE_LIBS=$FREETYPE_LIBS" >&5 62495 $as_echo "$as_me: Using FREETYPE_CFLAGS=$FREETYPE_CFLAGS and FREETYPE_LIBS=$FREETYPE_LIBS" >&6;} 62496 62497 62498 # Print a helpful message on how to acquire the necessary build dependency. 62499 # freetype is the help tag: freetype, cups, alsa etc 62500 MISSING_DEPENDENCY=freetype 62501 62502 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 62503 cygwin_help $MISSING_DEPENDENCY 62504 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 62505 msys_help $MISSING_DEPENDENCY 62506 else 62507 PKGHANDLER_COMMAND= 62508 62509 case $PKGHANDLER in 62510 apt-get) 62511 apt_help $MISSING_DEPENDENCY ;; 62512 yum) 62513 yum_help $MISSING_DEPENDENCY ;; 62514 port) 62515 port_help $MISSING_DEPENDENCY ;; 62516 pkgutil) 62517 pkgutil_help $MISSING_DEPENDENCY ;; 62518 pkgadd) 62519 pkgadd_help $MISSING_DEPENDENCY ;; 62520 esac 62521 62522 if test "x$PKGHANDLER_COMMAND" != x; then 62523 HELP_MSG="You might be able to fix this by running '$PKGHANDLER_COMMAND'." 62524 fi 62525 fi 62526 62527 62528 as_fn_error $? "Can not continue without freetype. $HELP_MSG" "$LINENO" 5 62529 62530 62531 fi 62532 rm -f core conftest.err conftest.$ac_objext \ 62533 conftest$ac_exeext conftest.$ac_ext 62534 CXXCFLAGS="$PREV_CXXFLAGS" 62535 LIBS="$PREV_LIBS" 62536 CXX="$PREV_CXX" 62537 ac_ext=cpp 62538 ac_cpp='$CXXCPP $CPPFLAGS' 62539 ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5' 62540 ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' 62541 ac_compiler_gnu=$ac_cv_cxx_compiler_gnu 62542 62543 62544 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if we should bundle freetype" >&5 62545 $as_echo_n "checking if we should bundle freetype... " >&6; } 62546 if test "x$BUNDLE_FREETYPE" = xyes; then 62547 FREETYPE_BUNDLE_LIB_PATH="$FREETYPE_LIB_PATH" 62548 fi 62549 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BUNDLE_FREETYPE" >&5 62550 $as_echo "$BUNDLE_FREETYPE" >&6; } 62551 62552 fi # end freetype needed 62553 62554 62555 62556 62557 62558 62559 62560 # Check whether --with-alsa was given. 62561 if test "${with_alsa+set}" = set; then : 62562 withval=$with_alsa; 62563 fi 62564 62565 62566 # Check whether --with-alsa-include was given. 62567 if test "${with_alsa_include+set}" = set; then : 62568 withval=$with_alsa_include; 62569 fi 62570 62571 62572 # Check whether --with-alsa-lib was given. 62573 if test "${with_alsa_lib+set}" = set; then : 62574 withval=$with_alsa_lib; 62575 fi 62576 62577 62578 if test "x$NEEDS_LIB_ALSA" = xfalse; then 62579 if (test "x${with_alsa}" != x && test "x${with_alsa}" != xno) || \ 62580 (test "x${with_alsa_include}" != x && test "x${with_alsa_include}" != xno) || \ 62581 (test "x${with_alsa_lib}" != x && test "x${with_alsa_lib}" != xno); then 62582 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: alsa not used, so --with-alsa[-*] is ignored" >&5 62583 $as_echo "$as_me: WARNING: alsa not used, so --with-alsa[-*] is ignored" >&2;} 62584 fi 62585 ALSA_CFLAGS= 62586 ALSA_LIBS= 62587 else 62588 ALSA_FOUND=no 62589 62590 if test "x${with_alsa}" = xno || test "x${with_alsa_include}" = xno || test "x${with_alsa_lib}" = xno; then 62591 as_fn_error $? "It is not possible to disable the use of alsa. Remove the --without-alsa option." "$LINENO" 5 62592 fi 62593 62594 if test "x${with_alsa}" != x; then 62595 ALSA_LIBS="-L${with_alsa}/lib -lasound" 62596 ALSA_CFLAGS="-I${with_alsa}/include" 62597 ALSA_FOUND=yes 62598 fi 62599 if test "x${with_alsa_include}" != x; then 62600 ALSA_CFLAGS="-I${with_alsa_include}" 62601 ALSA_FOUND=yes 62602 fi 62603 if test "x${with_alsa_lib}" != x; then 62604 ALSA_LIBS="-L${with_alsa_lib} -lasound" 62605 ALSA_FOUND=yes 62606 fi 62607 # Do not try pkg-config if we have a sysroot set. 62608 if test "x$SYSROOT" = x; then 62609 if test "x$ALSA_FOUND" = xno; then 62610 62611 pkg_failed=no 62612 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ALSA" >&5 62613 $as_echo_n "checking for ALSA... " >&6; } 62614 62615 if test -n "$ALSA_CFLAGS"; then 62616 pkg_cv_ALSA_CFLAGS="$ALSA_CFLAGS" 62617 elif test -n "$PKG_CONFIG"; then 62618 if test -n "$PKG_CONFIG" && \ 62619 { { $as_echo "$as_me:${as_lineno-$LINENO}: \$PKG_CONFIG --exists --print-errors \"alsa\""; } >&5 62620 ($PKG_CONFIG --exists --print-errors "alsa") 2>&5 62621 ac_status=$? 62622 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 62623 test $ac_status = 0; }; then 62624 pkg_cv_ALSA_CFLAGS=`$PKG_CONFIG --cflags "alsa" 2>/dev/null` 62625 else 62626 pkg_failed=yes 62627 fi 62628 else 62629 pkg_failed=untried 62630 fi 62631 if test -n "$ALSA_LIBS"; then 62632 pkg_cv_ALSA_LIBS="$ALSA_LIBS" 62633 elif test -n "$PKG_CONFIG"; then 62634 if test -n "$PKG_CONFIG" && \ 62635 { { $as_echo "$as_me:${as_lineno-$LINENO}: \$PKG_CONFIG --exists --print-errors \"alsa\""; } >&5 62636 ($PKG_CONFIG --exists --print-errors "alsa") 2>&5 62637 ac_status=$? 62638 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 62639 test $ac_status = 0; }; then 62640 pkg_cv_ALSA_LIBS=`$PKG_CONFIG --libs "alsa" 2>/dev/null` 62641 else 62642 pkg_failed=yes 62643 fi 62644 else 62645 pkg_failed=untried 62646 fi 62647 62648 62649 62650 if test $pkg_failed = yes; then 62651 62652 if $PKG_CONFIG --atleast-pkgconfig-version 0.20; then 62653 _pkg_short_errors_supported=yes 62654 else 62655 _pkg_short_errors_supported=no 62656 fi 62657 if test $_pkg_short_errors_supported = yes; then 62658 ALSA_PKG_ERRORS=`$PKG_CONFIG --short-errors --print-errors "alsa" 2>&1` 62659 else 62660 ALSA_PKG_ERRORS=`$PKG_CONFIG --print-errors "alsa" 2>&1` 62661 fi 62662 # Put the nasty error message in config.log where it belongs 62663 echo "$ALSA_PKG_ERRORS" >&5 62664 62665 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 62666 $as_echo "no" >&6; } 62667 ALSA_FOUND=no 62668 elif test $pkg_failed = untried; then 62669 ALSA_FOUND=no 62670 else 62671 ALSA_CFLAGS=$pkg_cv_ALSA_CFLAGS 62672 ALSA_LIBS=$pkg_cv_ALSA_LIBS 62673 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 62674 $as_echo "yes" >&6; } 62675 ALSA_FOUND=yes 62676 fi 62677 fi 62678 fi 62679 if test "x$ALSA_FOUND" = xno; then 62680 for ac_header in alsa/asoundlib.h 62681 do : 62682 ac_fn_cxx_check_header_mongrel "$LINENO" "alsa/asoundlib.h" "ac_cv_header_alsa_asoundlib_h" "$ac_includes_default" 62683 if test "x$ac_cv_header_alsa_asoundlib_h" = xyes; then : 62684 cat >>confdefs.h <<_ACEOF 62685 #define HAVE_ALSA_ASOUNDLIB_H 1 62686 _ACEOF 62687 62688 ALSA_FOUND=yes 62689 ALSA_CFLAGS=-Iignoreme 62690 ALSA_LIBS=-lasound 62691 DEFAULT_ALSA=yes 62692 62693 else 62694 ALSA_FOUND=no 62695 62696 fi 62697 62698 done 62699 62700 fi 62701 if test "x$ALSA_FOUND" = xno; then 62702 62703 # Print a helpful message on how to acquire the necessary build dependency. 62704 # alsa is the help tag: freetype, cups, alsa etc 62705 MISSING_DEPENDENCY=alsa 62706 62707 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 62708 cygwin_help $MISSING_DEPENDENCY 62709 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 62710 msys_help $MISSING_DEPENDENCY 62711 else 62712 PKGHANDLER_COMMAND= 62713 62714 case $PKGHANDLER in 62715 apt-get) 62716 apt_help $MISSING_DEPENDENCY ;; 62717 yum) 62718 yum_help $MISSING_DEPENDENCY ;; 62719 port) 62720 port_help $MISSING_DEPENDENCY ;; 62721 pkgutil) 62722 pkgutil_help $MISSING_DEPENDENCY ;; 62723 pkgadd) 62724 pkgadd_help $MISSING_DEPENDENCY ;; 62725 esac 62726 62727 if test "x$PKGHANDLER_COMMAND" != x; then 62728 HELP_MSG="You might be able to fix this by running '$PKGHANDLER_COMMAND'." 62729 fi 62730 fi 62731 62732 as_fn_error $? "Could not find alsa! $HELP_MSG" "$LINENO" 5 62733 fi 62734 fi 62735 62736 62737 62738 62739 62740 62741 # Check whether --with-libffi was given. 62742 if test "${with_libffi+set}" = set; then : 62743 withval=$with_libffi; 62744 fi 62745 62746 62747 # Check whether --with-libffi-include was given. 62748 if test "${with_libffi_include+set}" = set; then : 62749 withval=$with_libffi_include; 62750 fi 62751 62752 62753 # Check whether --with-libffi-lib was given. 62754 if test "${with_libffi_lib+set}" = set; then : 62755 withval=$with_libffi_lib; 62756 fi 62757 62758 62759 if test "x$NEEDS_LIB_FFI" = xfalse; then 62760 if (test "x${with_libffi}" != x && test "x${with_libffi}" != xno) || \ 62761 (test "x${with_libffi_include}" != x && test "x${with_libffi_include}" != xno) || \ 62762 (test "x${with_libffi_lib}" != x && test "x${with_libffi_lib}" != xno); then 62763 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: libffi not used, so --with-libffi[-*] is ignored" >&5 62764 $as_echo "$as_me: WARNING: libffi not used, so --with-libffi[-*] is ignored" >&2;} 62765 fi 62766 LIBFFI_CFLAGS= 62767 LIBFFI_LIBS= 62768 else 62769 LIBFFI_FOUND=no 62770 62771 if test "x${with_libffi}" = xno || test "x${with_libffi_include}" = xno || test "x${with_libffi_lib}" = xno; then 62772 as_fn_error $? "It is not possible to disable the use of libffi. Remove the --without-libffi option." "$LINENO" 5 62773 fi 62774 62775 if test "x${with_libffi}" != x; then 62776 LIBFFI_LIBS="-L${with_libffi}/lib -lffi" 62777 LIBFFI_CFLAGS="-I${with_libffi}/include" 62778 LIBFFI_FOUND=yes 62779 fi 62780 if test "x${with_libffi_include}" != x; then 62781 LIBFFI_CFLAGS="-I${with_libffi_include}" 62782 LIBFFI_FOUND=yes 62783 fi 62784 if test "x${with_libffi_lib}" != x; then 62785 LIBFFI_LIBS="-L${with_libffi_lib} -lffi" 62786 LIBFFI_FOUND=yes 62787 fi 62788 # Do not try pkg-config if we have a sysroot set. 62789 if test "x$SYSROOT" = x; then 62790 if test "x$LIBFFI_FOUND" = xno; then 62791 # Figure out LIBFFI_CFLAGS and LIBFFI_LIBS 62792 62793 pkg_failed=no 62794 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for LIBFFI" >&5 62795 $as_echo_n "checking for LIBFFI... " >&6; } 62796 62797 if test -n "$LIBFFI_CFLAGS"; then 62798 pkg_cv_LIBFFI_CFLAGS="$LIBFFI_CFLAGS" 62799 elif test -n "$PKG_CONFIG"; then 62800 if test -n "$PKG_CONFIG" && \ 62801 { { $as_echo "$as_me:${as_lineno-$LINENO}: \$PKG_CONFIG --exists --print-errors \"libffi\""; } >&5 62802 ($PKG_CONFIG --exists --print-errors "libffi") 2>&5 62803 ac_status=$? 62804 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 62805 test $ac_status = 0; }; then 62806 pkg_cv_LIBFFI_CFLAGS=`$PKG_CONFIG --cflags "libffi" 2>/dev/null` 62807 else 62808 pkg_failed=yes 62809 fi 62810 else 62811 pkg_failed=untried 62812 fi 62813 if test -n "$LIBFFI_LIBS"; then 62814 pkg_cv_LIBFFI_LIBS="$LIBFFI_LIBS" 62815 elif test -n "$PKG_CONFIG"; then 62816 if test -n "$PKG_CONFIG" && \ 62817 { { $as_echo "$as_me:${as_lineno-$LINENO}: \$PKG_CONFIG --exists --print-errors \"libffi\""; } >&5 62818 ($PKG_CONFIG --exists --print-errors "libffi") 2>&5 62819 ac_status=$? 62820 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 62821 test $ac_status = 0; }; then 62822 pkg_cv_LIBFFI_LIBS=`$PKG_CONFIG --libs "libffi" 2>/dev/null` 62823 else 62824 pkg_failed=yes 62825 fi 62826 else 62827 pkg_failed=untried 62828 fi 62829 62830 62831 62832 if test $pkg_failed = yes; then 62833 62834 if $PKG_CONFIG --atleast-pkgconfig-version 0.20; then 62835 _pkg_short_errors_supported=yes 62836 else 62837 _pkg_short_errors_supported=no 62838 fi 62839 if test $_pkg_short_errors_supported = yes; then 62840 LIBFFI_PKG_ERRORS=`$PKG_CONFIG --short-errors --print-errors "libffi" 2>&1` 62841 else 62842 LIBFFI_PKG_ERRORS=`$PKG_CONFIG --print-errors "libffi" 2>&1` 62843 fi 62844 # Put the nasty error message in config.log where it belongs 62845 echo "$LIBFFI_PKG_ERRORS" >&5 62846 62847 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 62848 $as_echo "no" >&6; } 62849 LIBFFI_FOUND=no 62850 elif test $pkg_failed = untried; then 62851 LIBFFI_FOUND=no 62852 else 62853 LIBFFI_CFLAGS=$pkg_cv_LIBFFI_CFLAGS 62854 LIBFFI_LIBS=$pkg_cv_LIBFFI_LIBS 62855 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 62856 $as_echo "yes" >&6; } 62857 LIBFFI_FOUND=yes 62858 fi 62859 fi 62860 fi 62861 if test "x$LIBFFI_FOUND" = xno; then 62862 for ac_header in ffi.h 62863 do : 62864 ac_fn_cxx_check_header_mongrel "$LINENO" "ffi.h" "ac_cv_header_ffi_h" "$ac_includes_default" 62865 if test "x$ac_cv_header_ffi_h" = xyes; then : 62866 cat >>confdefs.h <<_ACEOF 62867 #define HAVE_FFI_H 1 62868 _ACEOF 62869 62870 LIBFFI_FOUND=yes 62871 LIBFFI_CFLAGS= 62872 LIBFFI_LIBS=-lffi 62873 62874 else 62875 LIBFFI_FOUND=no 62876 62877 fi 62878 62879 done 62880 62881 fi 62882 if test "x$LIBFFI_FOUND" = xno; then 62883 62884 # Print a helpful message on how to acquire the necessary build dependency. 62885 # ffi is the help tag: freetype, cups, alsa etc 62886 MISSING_DEPENDENCY=ffi 62887 62888 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 62889 cygwin_help $MISSING_DEPENDENCY 62890 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 62891 msys_help $MISSING_DEPENDENCY 62892 else 62893 PKGHANDLER_COMMAND= 62894 62895 case $PKGHANDLER in 62896 apt-get) 62897 apt_help $MISSING_DEPENDENCY ;; 62898 yum) 62899 yum_help $MISSING_DEPENDENCY ;; 62900 port) 62901 port_help $MISSING_DEPENDENCY ;; 62902 pkgutil) 62903 pkgutil_help $MISSING_DEPENDENCY ;; 62904 pkgadd) 62905 pkgadd_help $MISSING_DEPENDENCY ;; 62906 esac 62907 62908 if test "x$PKGHANDLER_COMMAND" != x; then 62909 HELP_MSG="You might be able to fix this by running '$PKGHANDLER_COMMAND'." 62910 fi 62911 fi 62912 62913 as_fn_error $? "Could not find libffi! $HELP_MSG" "$LINENO" 5 62914 fi 62915 62916 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if libffi works" >&5 62917 $as_echo_n "checking if libffi works... " >&6; } 62918 ac_ext=c 62919 ac_cpp='$CPP $CPPFLAGS' 62920 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5' 62921 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' 62922 ac_compiler_gnu=$ac_cv_c_compiler_gnu 62923 62924 OLD_CFLAGS="$CFLAGS" 62925 CFLAGS="$CFLAGS $LIBFFI_CFLAGS" 62926 OLD_LIBS="$LIBS" 62927 LIBS="$LIBS $LIBFFI_LIBS" 62928 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 62929 /* end confdefs.h. */ 62930 #include <ffi.h> 62931 int 62932 main () 62933 { 62934 62935 ffi_call(NULL, NULL, NULL, NULL); 62936 return 0; 62937 62938 ; 62939 return 0; 62940 } 62941 _ACEOF 62942 if ac_fn_c_try_link "$LINENO"; then : 62943 LIBFFI_WORKS=yes 62944 else 62945 LIBFFI_WORKS=no 62946 62947 fi 62948 rm -f core conftest.err conftest.$ac_objext \ 62949 conftest$ac_exeext conftest.$ac_ext 62950 CFLAGS="$OLD_CFLAGS" 62951 LIBS="$OLD_LIBS" 62952 ac_ext=cpp 62953 ac_cpp='$CXXCPP $CPPFLAGS' 62954 ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5' 62955 ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' 62956 ac_compiler_gnu=$ac_cv_cxx_compiler_gnu 62957 62958 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $LIBFFI_WORKS" >&5 62959 $as_echo "$LIBFFI_WORKS" >&6; } 62960 62961 if test "x$LIBFFI_WORKS" = xno; then 62962 62963 # Print a helpful message on how to acquire the necessary build dependency. 62964 # ffi is the help tag: freetype, cups, alsa etc 62965 MISSING_DEPENDENCY=ffi 62966 62967 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 62968 cygwin_help $MISSING_DEPENDENCY 62969 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 62970 msys_help $MISSING_DEPENDENCY 62971 else 62972 PKGHANDLER_COMMAND= 62973 62974 case $PKGHANDLER in 62975 apt-get) 62976 apt_help $MISSING_DEPENDENCY ;; 62977 yum) 62978 yum_help $MISSING_DEPENDENCY ;; 62979 port) 62980 port_help $MISSING_DEPENDENCY ;; 62981 pkgutil) 62982 pkgutil_help $MISSING_DEPENDENCY ;; 62983 pkgadd) 62984 pkgadd_help $MISSING_DEPENDENCY ;; 62985 esac 62986 62987 if test "x$PKGHANDLER_COMMAND" != x; then 62988 HELP_MSG="You might be able to fix this by running '$PKGHANDLER_COMMAND'." 62989 fi 62990 fi 62991 62992 as_fn_error $? "Found libffi but could not link and compile with it. $HELP_MSG" "$LINENO" 5 62993 fi 62994 fi 62995 62996 62997 62998 62999 63000 if [[ " $JVM_VARIANTS " =~ " zeroshark " ]] ; then 63001 # Extract the first word of "llvm-config", so it can be a program name with args. 63002 set dummy llvm-config; ac_word=$2 63003 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 63004 $as_echo_n "checking for $ac_word... " >&6; } 63005 if ${ac_cv_prog_LLVM_CONFIG+:} false; then : 63006 $as_echo_n "(cached) " >&6 63007 else 63008 if test -n "$LLVM_CONFIG"; then 63009 ac_cv_prog_LLVM_CONFIG="$LLVM_CONFIG" # Let the user override the test. 63010 else 63011 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 63012 for as_dir in $PATH 63013 do 63014 IFS=$as_save_IFS 63015 test -z "$as_dir" && as_dir=. 63016 for ac_exec_ext in '' $ac_executable_extensions; do 63017 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 63018 ac_cv_prog_LLVM_CONFIG="llvm-config" 63019 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 63020 break 2 63021 fi 63022 done 63023 done 63024 IFS=$as_save_IFS 63025 63026 fi 63027 fi 63028 LLVM_CONFIG=$ac_cv_prog_LLVM_CONFIG 63029 if test -n "$LLVM_CONFIG"; then 63030 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $LLVM_CONFIG" >&5 63031 $as_echo "$LLVM_CONFIG" >&6; } 63032 else 63033 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 63034 $as_echo "no" >&6; } 63035 fi 63036 63037 63038 63039 if test "x$LLVM_CONFIG" != xllvm-config; then 63040 as_fn_error $? "llvm-config not found in $PATH." "$LINENO" 5 63041 fi 63042 63043 llvm_components="jit mcjit engine nativecodegen native" 63044 unset LLVM_CFLAGS 63045 for flag in $("$LLVM_CONFIG" --cxxflags); do 63046 if echo "${flag}" | grep -q '^-[ID]'; then 63047 if test "${flag}" != "-D_DEBUG" ; then 63048 if test "${LLVM_CFLAGS}" != "" ; then 63049 LLVM_CFLAGS="${LLVM_CFLAGS} " 63050 fi 63051 LLVM_CFLAGS="${LLVM_CFLAGS}${flag}" 63052 fi 63053 fi 63054 done 63055 llvm_version=$("${LLVM_CONFIG}" --version | $SED 's/\.//; s/svn.*//') 63056 LLVM_CFLAGS="${LLVM_CFLAGS} -DSHARK_LLVM_VERSION=${llvm_version}" 63057 63058 unset LLVM_LDFLAGS 63059 for flag in $("${LLVM_CONFIG}" --ldflags); do 63060 if echo "${flag}" | grep -q '^-L'; then 63061 if test "${LLVM_LDFLAGS}" != ""; then 63062 LLVM_LDFLAGS="${LLVM_LDFLAGS} " 63063 fi 63064 LLVM_LDFLAGS="${LLVM_LDFLAGS}${flag}" 63065 fi 63066 done 63067 63068 unset LLVM_LIBS 63069 for flag in $("${LLVM_CONFIG}" --libs ${llvm_components}); do 63070 if echo "${flag}" | grep -q '^-l'; then 63071 if test "${LLVM_LIBS}" != ""; then 63072 LLVM_LIBS="${LLVM_LIBS} " 63073 fi 63074 LLVM_LIBS="${LLVM_LIBS}${flag}" 63075 fi 63076 done 63077 63078 # Due to https://llvm.org/bugs/show_bug.cgi?id=16902, llvm does not 63079 # always properly detect -ltinfo 63080 LLVM_LIBS="${LLVM_LIBS} -ltinfo" 63081 63082 63083 63084 63085 fi 63086 63087 63088 63089 # Check whether --with-libjpeg was given. 63090 if test "${with_libjpeg+set}" = set; then : 63091 withval=$with_libjpeg; 63092 fi 63093 63094 63095 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for which libjpeg to use" >&5 63096 $as_echo_n "checking for which libjpeg to use... " >&6; } 63097 # default is bundled 63098 DEFAULT_LIBJPEG=bundled 63099 # if user didn't specify, use DEFAULT_LIBJPEG 63100 if test "x${with_libjpeg}" = "x"; then 63101 with_libjpeg=${DEFAULT_LIBJPEG} 63102 fi 63103 { $as_echo "$as_me:${as_lineno-$LINENO}: result: ${with_libjpeg}" >&5 63104 $as_echo "${with_libjpeg}" >&6; } 63105 63106 if test "x${with_libjpeg}" = "xbundled"; then 63107 USE_EXTERNAL_LIBJPEG=false 63108 elif test "x${with_libjpeg}" = "xsystem"; then 63109 ac_fn_cxx_check_header_mongrel "$LINENO" "jpeglib.h" "ac_cv_header_jpeglib_h" "$ac_includes_default" 63110 if test "x$ac_cv_header_jpeglib_h" = xyes; then : 63111 63112 else 63113 as_fn_error $? "--with-libjpeg=system specified, but jpeglib.h not found!" "$LINENO" 5 63114 fi 63115 63116 63117 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for jpeg_CreateDecompress in -ljpeg" >&5 63118 $as_echo_n "checking for jpeg_CreateDecompress in -ljpeg... " >&6; } 63119 if ${ac_cv_lib_jpeg_jpeg_CreateDecompress+:} false; then : 63120 $as_echo_n "(cached) " >&6 63121 else 63122 ac_check_lib_save_LIBS=$LIBS 63123 LIBS="-ljpeg $LIBS" 63124 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 63125 /* end confdefs.h. */ 63126 63127 /* Override any GCC internal prototype to avoid an error. 63128 Use char because int might match the return type of a GCC 63129 builtin and then its argument prototype would still apply. */ 63130 #ifdef __cplusplus 63131 extern "C" 63132 #endif 63133 char jpeg_CreateDecompress (); 63134 int 63135 main () 63136 { 63137 return jpeg_CreateDecompress (); 63138 ; 63139 return 0; 63140 } 63141 _ACEOF 63142 if ac_fn_cxx_try_link "$LINENO"; then : 63143 ac_cv_lib_jpeg_jpeg_CreateDecompress=yes 63144 else 63145 ac_cv_lib_jpeg_jpeg_CreateDecompress=no 63146 fi 63147 rm -f core conftest.err conftest.$ac_objext \ 63148 conftest$ac_exeext conftest.$ac_ext 63149 LIBS=$ac_check_lib_save_LIBS 63150 fi 63151 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_jpeg_jpeg_CreateDecompress" >&5 63152 $as_echo "$ac_cv_lib_jpeg_jpeg_CreateDecompress" >&6; } 63153 if test "x$ac_cv_lib_jpeg_jpeg_CreateDecompress" = xyes; then : 63154 cat >>confdefs.h <<_ACEOF 63155 #define HAVE_LIBJPEG 1 63156 _ACEOF 63157 63158 LIBS="-ljpeg $LIBS" 63159 63160 else 63161 as_fn_error $? "--with-libjpeg=system specified, but no libjpeg found" "$LINENO" 5 63162 fi 63163 63164 63165 USE_EXTERNAL_LIBJPEG=true 63166 else 63167 as_fn_error $? "Invalid use of --with-libjpeg: ${with_libjpeg}, use 'system' or 'bundled'" "$LINENO" 5 63168 fi 63169 63170 63171 63172 63173 63174 # Check whether --with-giflib was given. 63175 if test "${with_giflib+set}" = set; then : 63176 withval=$with_giflib; 63177 fi 63178 63179 63180 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for which giflib to use" >&5 63181 $as_echo_n "checking for which giflib to use... " >&6; } 63182 # default is bundled 63183 DEFAULT_GIFLIB=bundled 63184 # if user didn't specify, use DEFAULT_GIFLIB 63185 if test "x${with_giflib}" = "x"; then 63186 with_giflib=${DEFAULT_GIFLIB} 63187 fi 63188 { $as_echo "$as_me:${as_lineno-$LINENO}: result: ${with_giflib}" >&5 63189 $as_echo "${with_giflib}" >&6; } 63190 63191 if test "x${with_giflib}" = "xbundled"; then 63192 USE_EXTERNAL_LIBGIF=false 63193 elif test "x${with_giflib}" = "xsystem"; then 63194 ac_fn_cxx_check_header_mongrel "$LINENO" "gif_lib.h" "ac_cv_header_gif_lib_h" "$ac_includes_default" 63195 if test "x$ac_cv_header_gif_lib_h" = xyes; then : 63196 63197 else 63198 as_fn_error $? "--with-giflib=system specified, but gif_lib.h not found!" "$LINENO" 5 63199 fi 63200 63201 63202 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for DGifGetCode in -lgif" >&5 63203 $as_echo_n "checking for DGifGetCode in -lgif... " >&6; } 63204 if ${ac_cv_lib_gif_DGifGetCode+:} false; then : 63205 $as_echo_n "(cached) " >&6 63206 else 63207 ac_check_lib_save_LIBS=$LIBS 63208 LIBS="-lgif $LIBS" 63209 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 63210 /* end confdefs.h. */ 63211 63212 /* Override any GCC internal prototype to avoid an error. 63213 Use char because int might match the return type of a GCC 63214 builtin and then its argument prototype would still apply. */ 63215 #ifdef __cplusplus 63216 extern "C" 63217 #endif 63218 char DGifGetCode (); 63219 int 63220 main () 63221 { 63222 return DGifGetCode (); 63223 ; 63224 return 0; 63225 } 63226 _ACEOF 63227 if ac_fn_cxx_try_link "$LINENO"; then : 63228 ac_cv_lib_gif_DGifGetCode=yes 63229 else 63230 ac_cv_lib_gif_DGifGetCode=no 63231 fi 63232 rm -f core conftest.err conftest.$ac_objext \ 63233 conftest$ac_exeext conftest.$ac_ext 63234 LIBS=$ac_check_lib_save_LIBS 63235 fi 63236 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_gif_DGifGetCode" >&5 63237 $as_echo "$ac_cv_lib_gif_DGifGetCode" >&6; } 63238 if test "x$ac_cv_lib_gif_DGifGetCode" = xyes; then : 63239 cat >>confdefs.h <<_ACEOF 63240 #define HAVE_LIBGIF 1 63241 _ACEOF 63242 63243 LIBS="-lgif $LIBS" 63244 63245 else 63246 as_fn_error $? "--with-giflib=system specified, but no giflib found!" "$LINENO" 5 63247 fi 63248 63249 63250 USE_EXTERNAL_LIBGIF=true 63251 else 63252 as_fn_error $? "Invalid value of --with-giflib: ${with_giflib}, use 'system' or 'bundled'" "$LINENO" 5 63253 fi 63254 63255 63256 63257 63258 63259 # Check whether --with-libpng was given. 63260 if test "${with_libpng+set}" = set; then : 63261 withval=$with_libpng; 63262 fi 63263 63264 63265 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for which libpng to use" >&5 63266 $as_echo_n "checking for which libpng to use... " >&6; } 63267 63268 # default is bundled 63269 DEFAULT_LIBPNG=bundled 63270 # if user didn't specify, use DEFAULT_LIBPNG 63271 if test "x${with_libpng}" = "x"; then 63272 with_libpng=${DEFAULT_LIBPNG} 63273 fi 63274 63275 if test "x${with_libpng}" = "xbundled"; then 63276 USE_EXTERNAL_LIBPNG=false 63277 { $as_echo "$as_me:${as_lineno-$LINENO}: result: bundled" >&5 63278 $as_echo "bundled" >&6; } 63279 elif test "x${with_libpng}" = "xsystem"; then 63280 63281 pkg_failed=no 63282 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for PNG" >&5 63283 $as_echo_n "checking for PNG... " >&6; } 63284 63285 if test -n "$PNG_CFLAGS"; then 63286 pkg_cv_PNG_CFLAGS="$PNG_CFLAGS" 63287 elif test -n "$PKG_CONFIG"; then 63288 if test -n "$PKG_CONFIG" && \ 63289 { { $as_echo "$as_me:${as_lineno-$LINENO}: \$PKG_CONFIG --exists --print-errors \"libpng\""; } >&5 63290 ($PKG_CONFIG --exists --print-errors "libpng") 2>&5 63291 ac_status=$? 63292 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 63293 test $ac_status = 0; }; then 63294 pkg_cv_PNG_CFLAGS=`$PKG_CONFIG --cflags "libpng" 2>/dev/null` 63295 else 63296 pkg_failed=yes 63297 fi 63298 else 63299 pkg_failed=untried 63300 fi 63301 if test -n "$PNG_LIBS"; then 63302 pkg_cv_PNG_LIBS="$PNG_LIBS" 63303 elif test -n "$PKG_CONFIG"; then 63304 if test -n "$PKG_CONFIG" && \ 63305 { { $as_echo "$as_me:${as_lineno-$LINENO}: \$PKG_CONFIG --exists --print-errors \"libpng\""; } >&5 63306 ($PKG_CONFIG --exists --print-errors "libpng") 2>&5 63307 ac_status=$? 63308 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 63309 test $ac_status = 0; }; then 63310 pkg_cv_PNG_LIBS=`$PKG_CONFIG --libs "libpng" 2>/dev/null` 63311 else 63312 pkg_failed=yes 63313 fi 63314 else 63315 pkg_failed=untried 63316 fi 63317 63318 63319 63320 if test $pkg_failed = yes; then 63321 63322 if $PKG_CONFIG --atleast-pkgconfig-version 0.20; then 63323 _pkg_short_errors_supported=yes 63324 else 63325 _pkg_short_errors_supported=no 63326 fi 63327 if test $_pkg_short_errors_supported = yes; then 63328 PNG_PKG_ERRORS=`$PKG_CONFIG --short-errors --print-errors "libpng" 2>&1` 63329 else 63330 PNG_PKG_ERRORS=`$PKG_CONFIG --print-errors "libpng" 2>&1` 63331 fi 63332 # Put the nasty error message in config.log where it belongs 63333 echo "$PNG_PKG_ERRORS" >&5 63334 63335 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 63336 $as_echo "no" >&6; } 63337 LIBPNG_FOUND=no 63338 elif test $pkg_failed = untried; then 63339 LIBPNG_FOUND=no 63340 else 63341 PNG_CFLAGS=$pkg_cv_PNG_CFLAGS 63342 PNG_LIBS=$pkg_cv_PNG_LIBS 63343 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 63344 $as_echo "yes" >&6; } 63345 LIBPNG_FOUND=yes 63346 fi 63347 if test "x${LIBPNG_FOUND}" = "xyes"; then 63348 USE_EXTERNAL_LIBPNG=true 63349 { $as_echo "$as_me:${as_lineno-$LINENO}: result: system" >&5 63350 $as_echo "system" >&6; } 63351 else 63352 { $as_echo "$as_me:${as_lineno-$LINENO}: result: system not found" >&5 63353 $as_echo "system not found" >&6; } 63354 as_fn_error $? "--with-libpng=system specified, but no libpng found!" "$LINENO" 5 63355 fi 63356 else 63357 as_fn_error $? "Invalid value of --with-libpng: ${with_libpng}, use 'system' or 'bundled'" "$LINENO" 5 63358 fi 63359 63360 63361 63362 63363 63364 # Check whether --with-zlib was given. 63365 if test "${with_zlib+set}" = set; then : 63366 withval=$with_zlib; 63367 fi 63368 63369 63370 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for compress in -lz" >&5 63371 $as_echo_n "checking for compress in -lz... " >&6; } 63372 if ${ac_cv_lib_z_compress+:} false; then : 63373 $as_echo_n "(cached) " >&6 63374 else 63375 ac_check_lib_save_LIBS=$LIBS 63376 LIBS="-lz $LIBS" 63377 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 63378 /* end confdefs.h. */ 63379 63380 /* Override any GCC internal prototype to avoid an error. 63381 Use char because int might match the return type of a GCC 63382 builtin and then its argument prototype would still apply. */ 63383 #ifdef __cplusplus 63384 extern "C" 63385 #endif 63386 char compress (); 63387 int 63388 main () 63389 { 63390 return compress (); 63391 ; 63392 return 0; 63393 } 63394 _ACEOF 63395 if ac_fn_cxx_try_link "$LINENO"; then : 63396 ac_cv_lib_z_compress=yes 63397 else 63398 ac_cv_lib_z_compress=no 63399 fi 63400 rm -f core conftest.err conftest.$ac_objext \ 63401 conftest$ac_exeext conftest.$ac_ext 63402 LIBS=$ac_check_lib_save_LIBS 63403 fi 63404 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_z_compress" >&5 63405 $as_echo "$ac_cv_lib_z_compress" >&6; } 63406 if test "x$ac_cv_lib_z_compress" = xyes; then : 63407 ZLIB_FOUND=yes 63408 else 63409 ZLIB_FOUND=no 63410 fi 63411 63412 63413 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for which zlib to use" >&5 63414 $as_echo_n "checking for which zlib to use... " >&6; } 63415 63416 DEFAULT_ZLIB=system 63417 if test "x$OPENJDK_TARGET_OS" = xwindows; then 63418 # On windows default is bundled...on others default is system 63419 DEFAULT_ZLIB=bundled 63420 fi 63421 63422 if test "x${ZLIB_FOUND}" != "xyes"; then 63423 # If we don't find any system...set default to bundled 63424 DEFAULT_ZLIB=bundled 63425 fi 63426 63427 # If user didn't specify, use DEFAULT_ZLIB 63428 if test "x${with_zlib}" = "x"; then 63429 with_zlib=${DEFAULT_ZLIB} 63430 fi 63431 63432 if test "x${with_zlib}" = "xbundled"; then 63433 USE_EXTERNAL_LIBZ=false 63434 { $as_echo "$as_me:${as_lineno-$LINENO}: result: bundled" >&5 63435 $as_echo "bundled" >&6; } 63436 elif test "x${with_zlib}" = "xsystem"; then 63437 if test "x${ZLIB_FOUND}" = "xyes"; then 63438 USE_EXTERNAL_LIBZ=true 63439 { $as_echo "$as_me:${as_lineno-$LINENO}: result: system" >&5 63440 $as_echo "system" >&6; } 63441 else 63442 { $as_echo "$as_me:${as_lineno-$LINENO}: result: system not found" >&5 63443 $as_echo "system not found" >&6; } 63444 as_fn_error $? "--with-zlib=system specified, but no zlib found!" "$LINENO" 5 63445 fi 63446 else 63447 as_fn_error $? "Invalid value for --with-zlib: ${with_zlib}, use 'system' or 'bundled'" "$LINENO" 5 63448 fi 63449 63450 63451 63452 63453 63454 # Check whether --with-lcms was given. 63455 if test "${with_lcms+set}" = set; then : 63456 withval=$with_lcms; 63457 fi 63458 63459 63460 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for which lcms to use" >&5 63461 $as_echo_n "checking for which lcms to use... " >&6; } 63462 63463 DEFAULT_LCMS=bundled 63464 # If user didn't specify, use DEFAULT_LCMS 63465 if test "x${with_lcms}" = "x"; then 63466 with_lcms=${DEFAULT_LCMS} 63467 fi 63468 63469 if test "x${with_lcms}" = "xbundled"; then 63470 USE_EXTERNAL_LCMS=false 63471 { $as_echo "$as_me:${as_lineno-$LINENO}: result: bundled" >&5 63472 $as_echo "bundled" >&6; } 63473 elif test "x${with_lcms}" = "xsystem"; then 63474 { $as_echo "$as_me:${as_lineno-$LINENO}: result: system" >&5 63475 $as_echo "system" >&6; } 63476 63477 pkg_failed=no 63478 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for LCMS" >&5 63479 $as_echo_n "checking for LCMS... " >&6; } 63480 63481 if test -n "$LCMS_CFLAGS"; then 63482 pkg_cv_LCMS_CFLAGS="$LCMS_CFLAGS" 63483 elif test -n "$PKG_CONFIG"; then 63484 if test -n "$PKG_CONFIG" && \ 63485 { { $as_echo "$as_me:${as_lineno-$LINENO}: \$PKG_CONFIG --exists --print-errors \"lcms2\""; } >&5 63486 ($PKG_CONFIG --exists --print-errors "lcms2") 2>&5 63487 ac_status=$? 63488 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 63489 test $ac_status = 0; }; then 63490 pkg_cv_LCMS_CFLAGS=`$PKG_CONFIG --cflags "lcms2" 2>/dev/null` 63491 else 63492 pkg_failed=yes 63493 fi 63494 else 63495 pkg_failed=untried 63496 fi 63497 if test -n "$LCMS_LIBS"; then 63498 pkg_cv_LCMS_LIBS="$LCMS_LIBS" 63499 elif test -n "$PKG_CONFIG"; then 63500 if test -n "$PKG_CONFIG" && \ 63501 { { $as_echo "$as_me:${as_lineno-$LINENO}: \$PKG_CONFIG --exists --print-errors \"lcms2\""; } >&5 63502 ($PKG_CONFIG --exists --print-errors "lcms2") 2>&5 63503 ac_status=$? 63504 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 63505 test $ac_status = 0; }; then 63506 pkg_cv_LCMS_LIBS=`$PKG_CONFIG --libs "lcms2" 2>/dev/null` 63507 else 63508 pkg_failed=yes 63509 fi 63510 else 63511 pkg_failed=untried 63512 fi 63513 63514 63515 63516 if test $pkg_failed = yes; then 63517 63518 if $PKG_CONFIG --atleast-pkgconfig-version 0.20; then 63519 _pkg_short_errors_supported=yes 63520 else 63521 _pkg_short_errors_supported=no 63522 fi 63523 if test $_pkg_short_errors_supported = yes; then 63524 LCMS_PKG_ERRORS=`$PKG_CONFIG --short-errors --print-errors "lcms2" 2>&1` 63525 else 63526 LCMS_PKG_ERRORS=`$PKG_CONFIG --print-errors "lcms2" 2>&1` 63527 fi 63528 # Put the nasty error message in config.log where it belongs 63529 echo "$LCMS_PKG_ERRORS" >&5 63530 63531 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 63532 $as_echo "no" >&6; } 63533 LCMS_FOUND=no 63534 elif test $pkg_failed = untried; then 63535 LCMS_FOUND=no 63536 else 63537 LCMS_CFLAGS=$pkg_cv_LCMS_CFLAGS 63538 LCMS_LIBS=$pkg_cv_LCMS_LIBS 63539 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 63540 $as_echo "yes" >&6; } 63541 LCMS_FOUND=yes 63542 fi 63543 if test "x${LCMS_FOUND}" = "xyes"; then 63544 USE_EXTERNAL_LCMS=true 63545 else 63546 as_fn_error $? "--with-lcms=system specified, but no lcms found!" "$LINENO" 5 63547 fi 63548 else 63549 as_fn_error $? "Invalid value for --with-lcms: ${with_lcms}, use 'system' or 'bundled'" "$LINENO" 5 63550 fi 63551 63552 63553 63554 63555 63556 63557 63558 63559 63560 63561 63562 # Setup libm (the maths library) 63563 if test "x$OPENJDK_TARGET_OS" != "xwindows"; then 63564 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for cos in -lm" >&5 63565 $as_echo_n "checking for cos in -lm... " >&6; } 63566 if ${ac_cv_lib_m_cos+:} false; then : 63567 $as_echo_n "(cached) " >&6 63568 else 63569 ac_check_lib_save_LIBS=$LIBS 63570 LIBS="-lm $LIBS" 63571 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 63572 /* end confdefs.h. */ 63573 63574 /* Override any GCC internal prototype to avoid an error. 63575 Use char because int might match the return type of a GCC 63576 builtin and then its argument prototype would still apply. */ 63577 #ifdef __cplusplus 63578 extern "C" 63579 #endif 63580 char cos (); 63581 int 63582 main () 63583 { 63584 return cos (); 63585 ; 63586 return 0; 63587 } 63588 _ACEOF 63589 if ac_fn_cxx_try_link "$LINENO"; then : 63590 ac_cv_lib_m_cos=yes 63591 else 63592 ac_cv_lib_m_cos=no 63593 fi 63594 rm -f core conftest.err conftest.$ac_objext \ 63595 conftest$ac_exeext conftest.$ac_ext 63596 LIBS=$ac_check_lib_save_LIBS 63597 fi 63598 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_m_cos" >&5 63599 $as_echo "$ac_cv_lib_m_cos" >&6; } 63600 if test "x$ac_cv_lib_m_cos" = xyes; then : 63601 cat >>confdefs.h <<_ACEOF 63602 #define HAVE_LIBM 1 63603 _ACEOF 63604 63605 LIBS="-lm $LIBS" 63606 63607 else 63608 63609 { $as_echo "$as_me:${as_lineno-$LINENO}: Maths library was not found" >&5 63610 $as_echo "$as_me: Maths library was not found" >&6;} 63611 63612 fi 63613 63614 LIBM="-lm" 63615 else 63616 LIBM="" 63617 fi 63618 63619 63620 # Setup libdl (for dynamic library loading) 63621 save_LIBS="$LIBS" 63622 LIBS="" 63623 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for dlopen in -ldl" >&5 63624 $as_echo_n "checking for dlopen in -ldl... " >&6; } 63625 if ${ac_cv_lib_dl_dlopen+:} false; then : 63626 $as_echo_n "(cached) " >&6 63627 else 63628 ac_check_lib_save_LIBS=$LIBS 63629 LIBS="-ldl $LIBS" 63630 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 63631 /* end confdefs.h. */ 63632 63633 /* Override any GCC internal prototype to avoid an error. 63634 Use char because int might match the return type of a GCC 63635 builtin and then its argument prototype would still apply. */ 63636 #ifdef __cplusplus 63637 extern "C" 63638 #endif 63639 char dlopen (); 63640 int 63641 main () 63642 { 63643 return dlopen (); 63644 ; 63645 return 0; 63646 } 63647 _ACEOF 63648 if ac_fn_cxx_try_link "$LINENO"; then : 63649 ac_cv_lib_dl_dlopen=yes 63650 else 63651 ac_cv_lib_dl_dlopen=no 63652 fi 63653 rm -f core conftest.err conftest.$ac_objext \ 63654 conftest$ac_exeext conftest.$ac_ext 63655 LIBS=$ac_check_lib_save_LIBS 63656 fi 63657 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_dl_dlopen" >&5 63658 $as_echo "$ac_cv_lib_dl_dlopen" >&6; } 63659 if test "x$ac_cv_lib_dl_dlopen" = xyes; then : 63660 cat >>confdefs.h <<_ACEOF 63661 #define HAVE_LIBDL 1 63662 _ACEOF 63663 63664 LIBS="-ldl $LIBS" 63665 63666 fi 63667 63668 LIBDL="$LIBS" 63669 63670 LIBS="$save_LIBS" 63671 63672 # Deprecated libraries, keep the flags for backwards compatibility 63673 if test "x$OPENJDK_TARGET_OS" = "xwindows"; then 63674 63675 63676 # Check whether --with-dxsdk was given. 63677 if test "${with_dxsdk+set}" = set; then : 63678 withval=$with_dxsdk; { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Option --with-dxsdk is deprecated and will be ignored." >&5 63679 $as_echo "$as_me: WARNING: Option --with-dxsdk is deprecated and will be ignored." >&2;} 63680 fi 63681 63682 63683 63684 63685 # Check whether --with-dxsdk-lib was given. 63686 if test "${with_dxsdk_lib+set}" = set; then : 63687 withval=$with_dxsdk_lib; { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Option --with-dxsdk-lib is deprecated and will be ignored." >&5 63688 $as_echo "$as_me: WARNING: Option --with-dxsdk-lib is deprecated and will be ignored." >&2;} 63689 fi 63690 63691 63692 63693 63694 # Check whether --with-dxsdk-include was given. 63695 if test "${with_dxsdk_include+set}" = set; then : 63696 withval=$with_dxsdk_include; { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Option --with-dxsdk-include is deprecated and will be ignored." >&5 63697 $as_echo "$as_me: WARNING: Option --with-dxsdk-include is deprecated and will be ignored." >&2;} 63698 fi 63699 63700 63701 fi 63702 63703 # Control if libzip can use mmap. Available for purposes of overriding. 63704 LIBZIP_CAN_USE_MMAP=true 63705 63706 63707 63708 if test "$OPENJDK_TARGET_OS" = "solaris" && test "x$BUILD_GTEST" = "xtrue"; then 63709 # Find the root of the Solaris Studio installation from the compiler path 63710 SOLARIS_STUDIO_DIR="$(dirname $CC)/.." 63711 STLPORT_LIB="$SOLARIS_STUDIO_DIR/lib/stlport4$OPENJDK_TARGET_CPU_ISADIR/libstlport.so.1" 63712 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for libstlport.so.1" >&5 63713 $as_echo_n "checking for libstlport.so.1... " >&6; } 63714 if ! test -f "$STLPORT_LIB" && test "x$OPENJDK_TARGET_CPU_ISADIR" = "x/sparcv9"; then 63715 # SS12u3 has libstlport under 'stlport4/v9' instead of 'stlport4/sparcv9' 63716 STLPORT_LIB="$SOLARIS_STUDIO_DIR/lib/stlport4/v9/libstlport.so.1" 63717 fi 63718 if test -f "$STLPORT_LIB"; then 63719 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes, $STLPORT_LIB" >&5 63720 $as_echo "yes, $STLPORT_LIB" >&6; } 63721 63722 # Only process if variable expands to non-empty 63723 63724 if test "x$STLPORT_LIB" != x; then 63725 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 63726 63727 # Input might be given as Windows format, start by converting to 63728 # unix format. 63729 path="$STLPORT_LIB" 63730 new_path=`$CYGPATH -u "$path"` 63731 63732 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 63733 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 63734 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 63735 # "foo.exe" is OK but "foo" is an error. 63736 # 63737 # This test is therefore slightly more accurate than "test -f" to check for file precense. 63738 # It is also a way to make sure we got the proper file name for the real test later on. 63739 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 63740 if test "x$test_shortpath" = x; then 63741 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of STLPORT_LIB, which resolves as \"$path\", is invalid." >&5 63742 $as_echo "$as_me: The path of STLPORT_LIB, which resolves as \"$path\", is invalid." >&6;} 63743 as_fn_error $? "Cannot locate the the path of STLPORT_LIB" "$LINENO" 5 63744 fi 63745 63746 # Call helper function which possibly converts this using DOS-style short mode. 63747 # If so, the updated path is stored in $new_path. 63748 63749 input_path="$new_path" 63750 # Check if we need to convert this using DOS-style short mode. If the path 63751 # contains just simple characters, use it. Otherwise (spaces, weird characters), 63752 # take no chances and rewrite it. 63753 # Note: m4 eats our [], so we need to use [ and ] instead. 63754 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 63755 if test "x$has_forbidden_chars" != x; then 63756 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 63757 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 63758 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 63759 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 63760 # Going to short mode and back again did indeed matter. Since short mode is 63761 # case insensitive, let's make it lowercase to improve readability. 63762 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 63763 # Now convert it back to Unix-style (cygpath) 63764 input_path=`$CYGPATH -u "$shortmode_path"` 63765 new_path="$input_path" 63766 fi 63767 fi 63768 63769 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 63770 if test "x$test_cygdrive_prefix" = x; then 63771 # As a simple fix, exclude /usr/bin since it's not a real path. 63772 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 63773 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 63774 # a path prefixed by /cygdrive for fixpath to work. 63775 new_path="$CYGWIN_ROOT_PATH$input_path" 63776 fi 63777 fi 63778 63779 63780 if test "x$path" != "x$new_path"; then 63781 STLPORT_LIB="$new_path" 63782 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting STLPORT_LIB to \"$new_path\"" >&5 63783 $as_echo "$as_me: Rewriting STLPORT_LIB to \"$new_path\"" >&6;} 63784 fi 63785 63786 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 63787 63788 path="$STLPORT_LIB" 63789 has_colon=`$ECHO $path | $GREP ^.:` 63790 new_path="$path" 63791 if test "x$has_colon" = x; then 63792 # Not in mixed or Windows style, start by that. 63793 new_path=`cmd //c echo $path` 63794 fi 63795 63796 63797 input_path="$new_path" 63798 # Check if we need to convert this using DOS-style short mode. If the path 63799 # contains just simple characters, use it. Otherwise (spaces, weird characters), 63800 # take no chances and rewrite it. 63801 # Note: m4 eats our [], so we need to use [ and ] instead. 63802 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 63803 if test "x$has_forbidden_chars" != x; then 63804 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 63805 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 63806 fi 63807 63808 63809 windows_path="$new_path" 63810 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 63811 unix_path=`$CYGPATH -u "$windows_path"` 63812 new_path="$unix_path" 63813 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 63814 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 63815 new_path="$unix_path" 63816 fi 63817 63818 if test "x$path" != "x$new_path"; then 63819 STLPORT_LIB="$new_path" 63820 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting STLPORT_LIB to \"$new_path\"" >&5 63821 $as_echo "$as_me: Rewriting STLPORT_LIB to \"$new_path\"" >&6;} 63822 fi 63823 63824 # Save the first 10 bytes of this path to the storage, so fixpath can work. 63825 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 63826 63827 else 63828 # We're on a unix platform. Hooray! :) 63829 path="$STLPORT_LIB" 63830 has_space=`$ECHO "$path" | $GREP " "` 63831 if test "x$has_space" != x; then 63832 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of STLPORT_LIB, which resolves as \"$path\", is invalid." >&5 63833 $as_echo "$as_me: The path of STLPORT_LIB, which resolves as \"$path\", is invalid." >&6;} 63834 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 63835 fi 63836 63837 # Use eval to expand a potential ~ 63838 eval path="$path" 63839 if test ! -f "$path" && test ! -d "$path"; then 63840 as_fn_error $? "The path of STLPORT_LIB, which resolves as \"$path\", is not found." "$LINENO" 5 63841 fi 63842 63843 if test -d "$path"; then 63844 STLPORT_LIB="`cd "$path"; $THEPWDCMD -L`" 63845 else 63846 dir="`$DIRNAME "$path"`" 63847 base="`$BASENAME "$path"`" 63848 STLPORT_LIB="`cd "$dir"; $THEPWDCMD -L`/$base" 63849 fi 63850 fi 63851 fi 63852 63853 else 63854 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no, not found at $STLPORT_LIB" >&5 63855 $as_echo "no, not found at $STLPORT_LIB" >&6; } 63856 as_fn_error $? "Failed to find libstlport.so.1, cannot build Hotspot gtests" "$LINENO" 5 63857 fi 63858 63859 fi 63860 63861 63862 63863 63864 63865 63866 63867 63868 63869 63870 63871 63872 63873 63874 ############################################################################### 63875 # 63876 # We need to do some final tweaking, when everything else is done. 63877 # 63878 ############################################################################### 63879 63880 63881 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if elliptic curve crypto implementation is present" >&5 63882 $as_echo_n "checking if elliptic curve crypto implementation is present... " >&6; } 63883 63884 if test -d "${SRC_ROOT}/jdk/src/jdk.crypto.ec/share/native/libsunec/impl"; then 63885 ENABLE_INTREE_EC=yes 63886 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 63887 $as_echo "yes" >&6; } 63888 else 63889 ENABLE_INTREE_EC=no 63890 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 63891 $as_echo "no" >&6; } 63892 fi 63893 63894 63895 63896 63897 # Check whether --enable-jtreg-failure-handler was given. 63898 if test "${enable_jtreg_failure_handler+set}" = set; then : 63899 enableval=$enable_jtreg_failure_handler; 63900 fi 63901 63902 63903 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if jtreg failure handler should be built" >&5 63904 $as_echo_n "checking if jtreg failure handler should be built... " >&6; } 63905 63906 if test "x$enable_jtreg_failure_handler" = "xyes"; then 63907 if test "x$JT_HOME" = "x"; then 63908 as_fn_error $? "Cannot enable jtreg failure handler without jtreg." "$LINENO" 5 63909 else 63910 BUILD_FAILURE_HANDLER=true 63911 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes, forced" >&5 63912 $as_echo "yes, forced" >&6; } 63913 fi 63914 elif test "x$enable_jtreg_failure_handler" = "xno"; then 63915 BUILD_FAILURE_HANDLER=false 63916 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no, forced" >&5 63917 $as_echo "no, forced" >&6; } 63918 elif test "x$enable_jtreg_failure_handler" = "xauto" \ 63919 || test "x$enable_jtreg_failure_handler" = "x"; then 63920 if test "x$JT_HOME" = "x"; then 63921 BUILD_FAILURE_HANDLER=false 63922 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no, missing jtreg" >&5 63923 $as_echo "no, missing jtreg" >&6; } 63924 else 63925 BUILD_FAILURE_HANDLER=true 63926 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes, jtreg present" >&5 63927 $as_echo "yes, jtreg present" >&6; } 63928 fi 63929 else 63930 as_fn_error $? "Invalid value for --enable-jtreg-failure-handler: $enable_jtreg_failure_handler" "$LINENO" 5 63931 fi 63932 63933 63934 63935 63936 # Check whether --enable-generate-classlist was given. 63937 if test "${enable_generate_classlist+set}" = set; then : 63938 enableval=$enable_generate_classlist; 63939 fi 63940 63941 63942 # Check if it's likely that it's possible to generate the classlist. Depending 63943 # on exact jvm configuration it could be possible anyway. 63944 if [[ " $JVM_VARIANTS " =~ " server " ]] || [[ " $JVM_VARIANTS " =~ " client " ]] ; then 63945 ENABLE_GENERATE_CLASSLIST_POSSIBLE="true" 63946 else 63947 ENABLE_GENERATE_CLASSLIST_POSSIBLE="false" 63948 fi 63949 63950 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if the CDS classlist generation should be enabled" >&5 63951 $as_echo_n "checking if the CDS classlist generation should be enabled... " >&6; } 63952 if test "x$enable_generate_classlist" = "xyes"; then 63953 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes, forced" >&5 63954 $as_echo "yes, forced" >&6; } 63955 ENABLE_GENERATE_CLASSLIST="true" 63956 if test "x$ENABLE_GENERATE_CLASSLIST_POSSIBLE" = "xfalse"; then 63957 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Generation of classlist might not be possible with JVM Variants $JVM_VARIANTS" >&5 63958 $as_echo "$as_me: WARNING: Generation of classlist might not be possible with JVM Variants $JVM_VARIANTS" >&2;} 63959 fi 63960 elif test "x$enable_generate_classlist" = "xno"; then 63961 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no, forced" >&5 63962 $as_echo "no, forced" >&6; } 63963 ENABLE_GENERATE_CLASSLIST="false" 63964 elif test "x$enable_generate_classlist" = "x"; then 63965 if test "x$ENABLE_GENERATE_CLASSLIST_POSSIBLE" = "xtrue"; then 63966 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 63967 $as_echo "yes" >&6; } 63968 ENABLE_GENERATE_CLASSLIST="true" 63969 else 63970 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 63971 $as_echo "no" >&6; } 63972 ENABLE_GENERATE_CLASSLIST="false" 63973 fi 63974 else 63975 as_fn_error $? "Invalid value for --enable-generate-classlist: $enable_generate_classlist" "$LINENO" 5 63976 fi 63977 63978 63979 63980 63981 ############################################################################### 63982 # 63983 # Configure parts of the build that only affect the build performance, 63984 # not the result. 63985 # 63986 ############################################################################### 63987 63988 63989 # How many cores do we have on this build system? 63990 63991 # Check whether --with-num-cores was given. 63992 if test "${with_num_cores+set}" = set; then : 63993 withval=$with_num_cores; 63994 fi 63995 63996 if test "x$with_num_cores" = x; then 63997 # The number of cores were not specified, try to probe them. 63998 63999 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for number of cores" >&5 64000 $as_echo_n "checking for number of cores... " >&6; } 64001 NUM_CORES=1 64002 FOUND_CORES=no 64003 64004 if test -f /proc/cpuinfo; then 64005 # Looks like a Linux (or cygwin) system 64006 NUM_CORES=`cat /proc/cpuinfo | grep -c processor` 64007 FOUND_CORES=yes 64008 elif test -x /usr/sbin/psrinfo; then 64009 # Looks like a Solaris system 64010 NUM_CORES=`LC_MESSAGES=C /usr/sbin/psrinfo -v | grep -c on-line` 64011 FOUND_CORES=yes 64012 elif test -x /usr/sbin/sysctl; then 64013 # Looks like a MacOSX system 64014 NUM_CORES=`/usr/sbin/sysctl -n hw.ncpu` 64015 FOUND_CORES=yes 64016 elif test "x$OPENJDK_BUILD_OS" = xaix ; then 64017 NUM_CORES=`/usr/sbin/prtconf | grep "^Number Of Processors" | awk '{ print $4 }'` 64018 FOUND_CORES=yes 64019 elif test -n "$NUMBER_OF_PROCESSORS"; then 64020 # On windows, look in the env 64021 NUM_CORES=$NUMBER_OF_PROCESSORS 64022 FOUND_CORES=yes 64023 fi 64024 64025 if test "x$FOUND_CORES" = xyes; then 64026 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $NUM_CORES" >&5 64027 $as_echo "$NUM_CORES" >&6; } 64028 else 64029 { $as_echo "$as_me:${as_lineno-$LINENO}: result: could not detect number of cores, defaulting to 1" >&5 64030 $as_echo "could not detect number of cores, defaulting to 1" >&6; } 64031 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: This will disable all parallelism from build!" >&5 64032 $as_echo "$as_me: WARNING: This will disable all parallelism from build!" >&2;} 64033 fi 64034 64035 else 64036 NUM_CORES=$with_num_cores 64037 fi 64038 64039 64040 64041 # How much memory do we have on this build system? 64042 64043 # Check whether --with-memory-size was given. 64044 if test "${with_memory_size+set}" = set; then : 64045 withval=$with_memory_size; 64046 fi 64047 64048 if test "x$with_memory_size" = x; then 64049 # The memory size was not specified, try to probe it. 64050 64051 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for memory size" >&5 64052 $as_echo_n "checking for memory size... " >&6; } 64053 # Default to 1024 MB 64054 MEMORY_SIZE=1024 64055 FOUND_MEM=no 64056 64057 if test -f /proc/meminfo; then 64058 # Looks like a Linux (or cygwin) system 64059 MEMORY_SIZE=`cat /proc/meminfo | grep MemTotal | awk '{print $2}'` 64060 MEMORY_SIZE=`expr $MEMORY_SIZE / 1024` 64061 FOUND_MEM=yes 64062 elif test -x /usr/sbin/prtconf; then 64063 # Looks like a Solaris or AIX system 64064 MEMORY_SIZE=`/usr/sbin/prtconf 2> /dev/null | grep "^Memory [Ss]ize" | awk '{ print $3 }'` 64065 FOUND_MEM=yes 64066 elif test -x /usr/sbin/sysctl; then 64067 # Looks like a MacOSX system 64068 MEMORY_SIZE=`/usr/sbin/sysctl -n hw.memsize` 64069 MEMORY_SIZE=`expr $MEMORY_SIZE / 1024 / 1024` 64070 FOUND_MEM=yes 64071 elif test "x$OPENJDK_BUILD_OS" = xwindows; then 64072 # Windows, but without cygwin 64073 MEMORY_SIZE=`wmic computersystem get totalphysicalmemory -value | grep = | cut -d "=" -f 2-` 64074 MEMORY_SIZE=`expr $MEMORY_SIZE / 1024 / 1024` 64075 FOUND_MEM=yes 64076 fi 64077 64078 if test "x$FOUND_MEM" = xyes; then 64079 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MEMORY_SIZE MB" >&5 64080 $as_echo "$MEMORY_SIZE MB" >&6; } 64081 else 64082 { $as_echo "$as_me:${as_lineno-$LINENO}: result: could not detect memory size, defaulting to $MEMORY_SIZE MB" >&5 64083 $as_echo "could not detect memory size, defaulting to $MEMORY_SIZE MB" >&6; } 64084 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: This might seriously impact build performance!" >&5 64085 $as_echo "$as_me: WARNING: This might seriously impact build performance!" >&2;} 64086 fi 64087 64088 else 64089 MEMORY_SIZE=$with_memory_size 64090 fi 64091 64092 64093 64094 # Provide a decent default number of parallel jobs for make depending on 64095 # number of cores, amount of memory and machine architecture. 64096 64097 # Check whether --with-jobs was given. 64098 if test "${with_jobs+set}" = set; then : 64099 withval=$with_jobs; 64100 fi 64101 64102 if test "x$with_jobs" = x; then 64103 # Number of jobs was not specified, calculate. 64104 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for appropriate number of jobs to run in parallel" >&5 64105 $as_echo_n "checking for appropriate number of jobs to run in parallel... " >&6; } 64106 # Approximate memory in GB. 64107 memory_gb=`expr $MEMORY_SIZE / 1024` 64108 # Pick the lowest of memory in gb and number of cores. 64109 if test "$memory_gb" -lt "$NUM_CORES"; then 64110 JOBS="$memory_gb" 64111 else 64112 JOBS="$NUM_CORES" 64113 fi 64114 if test "$JOBS" -eq "0"; then 64115 JOBS=1 64116 fi 64117 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $JOBS" >&5 64118 $as_echo "$JOBS" >&6; } 64119 else 64120 JOBS=$with_jobs 64121 fi 64122 64123 64124 64125 # The number of test jobs will be chosen automatically if TEST_JOBS is 0 64126 64127 # Check whether --with-test-jobs was given. 64128 if test "${with_test_jobs+set}" = set; then : 64129 withval=$with_test_jobs; 64130 fi 64131 64132 if test "x$with_test_jobs" = x; then 64133 TEST_JOBS=0 64134 else 64135 TEST_JOBS=$with_test_jobs 64136 fi 64137 64138 64139 64140 # Setup arguments for the boot jdk (after cores and memory have been setup) 64141 64142 ############################################################################## 64143 # 64144 # Specify jvm options for anything that is run with the Boot JDK. 64145 # Not all JVM:s accept the same arguments on the command line. 64146 # 64147 64148 # Check whether --with-boot-jdk-jvmargs was given. 64149 if test "${with_boot_jdk_jvmargs+set}" = set; then : 64150 withval=$with_boot_jdk_jvmargs; 64151 fi 64152 64153 64154 { $as_echo "$as_me:${as_lineno-$LINENO}: checking flags for boot jdk java command " >&5 64155 $as_echo_n "checking flags for boot jdk java command ... " >&6; } 64156 64157 # Disable special log output when a debug build is used as Boot JDK... 64158 64159 $ECHO "Check if jvm arg is ok: -XX:-PrintVMOptions -XX:-UnlockDiagnosticVMOptions -XX:-LogVMOutput" >&5 64160 $ECHO "Command: $JAVA -XX:-PrintVMOptions -XX:-UnlockDiagnosticVMOptions -XX:-LogVMOutput -version" >&5 64161 OUTPUT=`$JAVA -XX:-PrintVMOptions -XX:-UnlockDiagnosticVMOptions -XX:-LogVMOutput -version 2>&1` 64162 FOUND_WARN=`$ECHO "$OUTPUT" | $GREP -i warn` 64163 FOUND_VERSION=`$ECHO $OUTPUT | $GREP " version \""` 64164 if test "x$FOUND_VERSION" != x && test "x$FOUND_WARN" = x; then 64165 boot_jdk_jvmargs="$boot_jdk_jvmargs -XX:-PrintVMOptions -XX:-UnlockDiagnosticVMOptions -XX:-LogVMOutput" 64166 JVM_ARG_OK=true 64167 else 64168 $ECHO "Arg failed:" >&5 64169 $ECHO "$OUTPUT" >&5 64170 JVM_ARG_OK=false 64171 fi 64172 64173 64174 # Force en-US environment 64175 64176 $ECHO "Check if jvm arg is ok: -Duser.language=en -Duser.country=US" >&5 64177 $ECHO "Command: $JAVA -Duser.language=en -Duser.country=US -version" >&5 64178 OUTPUT=`$JAVA -Duser.language=en -Duser.country=US -version 2>&1` 64179 FOUND_WARN=`$ECHO "$OUTPUT" | $GREP -i warn` 64180 FOUND_VERSION=`$ECHO $OUTPUT | $GREP " version \""` 64181 if test "x$FOUND_VERSION" != x && test "x$FOUND_WARN" = x; then 64182 boot_jdk_jvmargs="$boot_jdk_jvmargs -Duser.language=en -Duser.country=US" 64183 JVM_ARG_OK=true 64184 else 64185 $ECHO "Arg failed:" >&5 64186 $ECHO "$OUTPUT" >&5 64187 JVM_ARG_OK=false 64188 fi 64189 64190 64191 # Apply user provided options. 64192 64193 $ECHO "Check if jvm arg is ok: $with_boot_jdk_jvmargs" >&5 64194 $ECHO "Command: $JAVA $with_boot_jdk_jvmargs -version" >&5 64195 OUTPUT=`$JAVA $with_boot_jdk_jvmargs -version 2>&1` 64196 FOUND_WARN=`$ECHO "$OUTPUT" | $GREP -i warn` 64197 FOUND_VERSION=`$ECHO $OUTPUT | $GREP " version \""` 64198 if test "x$FOUND_VERSION" != x && test "x$FOUND_WARN" = x; then 64199 boot_jdk_jvmargs="$boot_jdk_jvmargs $with_boot_jdk_jvmargs" 64200 JVM_ARG_OK=true 64201 else 64202 $ECHO "Arg failed:" >&5 64203 $ECHO "$OUTPUT" >&5 64204 JVM_ARG_OK=false 64205 fi 64206 64207 64208 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $boot_jdk_jvmargs" >&5 64209 $as_echo "$boot_jdk_jvmargs" >&6; } 64210 64211 # For now, general JAVA_FLAGS are the same as the boot jdk jvmargs 64212 JAVA_FLAGS=$boot_jdk_jvmargs 64213 64214 64215 64216 { $as_echo "$as_me:${as_lineno-$LINENO}: checking flags for boot jdk java command for big workloads" >&5 64217 $as_echo_n "checking flags for boot jdk java command for big workloads... " >&6; } 64218 64219 # Starting amount of heap memory. 64220 64221 $ECHO "Check if jvm arg is ok: -Xms64M" >&5 64222 $ECHO "Command: $JAVA -Xms64M -version" >&5 64223 OUTPUT=`$JAVA -Xms64M -version 2>&1` 64224 FOUND_WARN=`$ECHO "$OUTPUT" | $GREP -i warn` 64225 FOUND_VERSION=`$ECHO $OUTPUT | $GREP " version \""` 64226 if test "x$FOUND_VERSION" != x && test "x$FOUND_WARN" = x; then 64227 boot_jdk_jvmargs_big="$boot_jdk_jvmargs_big -Xms64M" 64228 JVM_ARG_OK=true 64229 else 64230 $ECHO "Arg failed:" >&5 64231 $ECHO "$OUTPUT" >&5 64232 JVM_ARG_OK=false 64233 fi 64234 64235 BOOTCYCLE_JVM_ARGS_BIG=-Xms64M 64236 64237 # Maximum amount of heap memory and stack size. 64238 JVM_HEAP_LIMIT_32="1024" 64239 # Running a 64 bit JVM allows for and requires a bigger heap 64240 JVM_HEAP_LIMIT_64="1600" 64241 STACK_SIZE_32=768 64242 STACK_SIZE_64=1536 64243 JVM_HEAP_LIMIT_GLOBAL=`expr $MEMORY_SIZE / 2` 64244 if test "$JVM_HEAP_LIMIT_GLOBAL" -lt "$JVM_HEAP_LIMIT_32"; then 64245 JVM_HEAP_LIMIT_32=$JVM_HEAP_LIMIT_GLOBAL 64246 fi 64247 if test "$JVM_HEAP_LIMIT_GLOBAL" -lt "$JVM_HEAP_LIMIT_64"; then 64248 JVM_HEAP_LIMIT_64=$JVM_HEAP_LIMIT_GLOBAL 64249 fi 64250 if test "$JVM_HEAP_LIMIT_GLOBAL" -lt "512"; then 64251 JVM_HEAP_LIMIT_32=512 64252 JVM_HEAP_LIMIT_64=512 64253 fi 64254 64255 if test "x$BOOT_JDK_BITS" = "x32"; then 64256 STACK_SIZE=$STACK_SIZE_32 64257 JVM_MAX_HEAP=$JVM_HEAP_LIMIT_32 64258 else 64259 STACK_SIZE=$STACK_SIZE_64 64260 JVM_MAX_HEAP=$JVM_HEAP_LIMIT_64 64261 fi 64262 64263 $ECHO "Check if jvm arg is ok: -Xmx${JVM_MAX_HEAP}M" >&5 64264 $ECHO "Command: $JAVA -Xmx${JVM_MAX_HEAP}M -version" >&5 64265 OUTPUT=`$JAVA -Xmx${JVM_MAX_HEAP}M -version 2>&1` 64266 FOUND_WARN=`$ECHO "$OUTPUT" | $GREP -i warn` 64267 FOUND_VERSION=`$ECHO $OUTPUT | $GREP " version \""` 64268 if test "x$FOUND_VERSION" != x && test "x$FOUND_WARN" = x; then 64269 boot_jdk_jvmargs_big="$boot_jdk_jvmargs_big -Xmx${JVM_MAX_HEAP}M" 64270 JVM_ARG_OK=true 64271 else 64272 $ECHO "Arg failed:" >&5 64273 $ECHO "$OUTPUT" >&5 64274 JVM_ARG_OK=false 64275 fi 64276 64277 64278 $ECHO "Check if jvm arg is ok: -XX:ThreadStackSize=$STACK_SIZE" >&5 64279 $ECHO "Command: $JAVA -XX:ThreadStackSize=$STACK_SIZE -version" >&5 64280 OUTPUT=`$JAVA -XX:ThreadStackSize=$STACK_SIZE -version 2>&1` 64281 FOUND_WARN=`$ECHO "$OUTPUT" | $GREP -i warn` 64282 FOUND_VERSION=`$ECHO $OUTPUT | $GREP " version \""` 64283 if test "x$FOUND_VERSION" != x && test "x$FOUND_WARN" = x; then 64284 boot_jdk_jvmargs_big="$boot_jdk_jvmargs_big -XX:ThreadStackSize=$STACK_SIZE" 64285 JVM_ARG_OK=true 64286 else 64287 $ECHO "Arg failed:" >&5 64288 $ECHO "$OUTPUT" >&5 64289 JVM_ARG_OK=false 64290 fi 64291 64292 64293 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $boot_jdk_jvmargs_big" >&5 64294 $as_echo "$boot_jdk_jvmargs_big" >&6; } 64295 64296 JAVA_FLAGS_BIG=$boot_jdk_jvmargs_big 64297 64298 64299 if test "x$OPENJDK_TARGET_CPU_BITS" = "x32"; then 64300 BOOTCYCLE_MAX_HEAP=$JVM_HEAP_LIMIT_32 64301 BOOTCYCLE_STACK_SIZE=$STACK_SIZE_32 64302 else 64303 BOOTCYCLE_MAX_HEAP=$JVM_HEAP_LIMIT_64 64304 BOOTCYCLE_STACK_SIZE=$STACK_SIZE_64 64305 fi 64306 BOOTCYCLE_JVM_ARGS_BIG="$BOOTCYCLE_JVM_ARGS_BIG -Xmx${BOOTCYCLE_MAX_HEAP}M" 64307 BOOTCYCLE_JVM_ARGS_BIG="$BOOTCYCLE_JVM_ARGS_BIG -XX:ThreadStackSize=$BOOTCYCLE_STACK_SIZE" 64308 { $as_echo "$as_me:${as_lineno-$LINENO}: checking flags for bootcycle boot jdk java command for big workloads" >&5 64309 $as_echo_n "checking flags for bootcycle boot jdk java command for big workloads... " >&6; } 64310 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOTCYCLE_JVM_ARGS_BIG" >&5 64311 $as_echo "$BOOTCYCLE_JVM_ARGS_BIG" >&6; } 64312 64313 64314 # By default, the main javac compilations use big 64315 JAVA_FLAGS_JAVAC="$JAVA_FLAGS_BIG" 64316 64317 64318 { $as_echo "$as_me:${as_lineno-$LINENO}: checking flags for boot jdk java command for small workloads" >&5 64319 $as_echo_n "checking flags for boot jdk java command for small workloads... " >&6; } 64320 64321 # Use serial gc for small short lived tools if possible 64322 64323 $ECHO "Check if jvm arg is ok: -XX:+UseSerialGC" >&5 64324 $ECHO "Command: $JAVA -XX:+UseSerialGC -version" >&5 64325 OUTPUT=`$JAVA -XX:+UseSerialGC -version 2>&1` 64326 FOUND_WARN=`$ECHO "$OUTPUT" | $GREP -i warn` 64327 FOUND_VERSION=`$ECHO $OUTPUT | $GREP " version \""` 64328 if test "x$FOUND_VERSION" != x && test "x$FOUND_WARN" = x; then 64329 boot_jdk_jvmargs_small="$boot_jdk_jvmargs_small -XX:+UseSerialGC" 64330 JVM_ARG_OK=true 64331 else 64332 $ECHO "Arg failed:" >&5 64333 $ECHO "$OUTPUT" >&5 64334 JVM_ARG_OK=false 64335 fi 64336 64337 64338 $ECHO "Check if jvm arg is ok: -Xms32M" >&5 64339 $ECHO "Command: $JAVA -Xms32M -version" >&5 64340 OUTPUT=`$JAVA -Xms32M -version 2>&1` 64341 FOUND_WARN=`$ECHO "$OUTPUT" | $GREP -i warn` 64342 FOUND_VERSION=`$ECHO $OUTPUT | $GREP " version \""` 64343 if test "x$FOUND_VERSION" != x && test "x$FOUND_WARN" = x; then 64344 boot_jdk_jvmargs_small="$boot_jdk_jvmargs_small -Xms32M" 64345 JVM_ARG_OK=true 64346 else 64347 $ECHO "Arg failed:" >&5 64348 $ECHO "$OUTPUT" >&5 64349 JVM_ARG_OK=false 64350 fi 64351 64352 64353 $ECHO "Check if jvm arg is ok: -Xmx512M" >&5 64354 $ECHO "Command: $JAVA -Xmx512M -version" >&5 64355 OUTPUT=`$JAVA -Xmx512M -version 2>&1` 64356 FOUND_WARN=`$ECHO "$OUTPUT" | $GREP -i warn` 64357 FOUND_VERSION=`$ECHO $OUTPUT | $GREP " version \""` 64358 if test "x$FOUND_VERSION" != x && test "x$FOUND_WARN" = x; then 64359 boot_jdk_jvmargs_small="$boot_jdk_jvmargs_small -Xmx512M" 64360 JVM_ARG_OK=true 64361 else 64362 $ECHO "Arg failed:" >&5 64363 $ECHO "$OUTPUT" >&5 64364 JVM_ARG_OK=false 64365 fi 64366 64367 64368 $ECHO "Check if jvm arg is ok: -XX:TieredStopAtLevel=1" >&5 64369 $ECHO "Command: $JAVA -XX:TieredStopAtLevel=1 -version" >&5 64370 OUTPUT=`$JAVA -XX:TieredStopAtLevel=1 -version 2>&1` 64371 FOUND_WARN=`$ECHO "$OUTPUT" | $GREP -i warn` 64372 FOUND_VERSION=`$ECHO $OUTPUT | $GREP " version \""` 64373 if test "x$FOUND_VERSION" != x && test "x$FOUND_WARN" = x; then 64374 boot_jdk_jvmargs_small="$boot_jdk_jvmargs_small -XX:TieredStopAtLevel=1" 64375 JVM_ARG_OK=true 64376 else 64377 $ECHO "Arg failed:" >&5 64378 $ECHO "$OUTPUT" >&5 64379 JVM_ARG_OK=false 64380 fi 64381 64382 64383 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $boot_jdk_jvmargs_small" >&5 64384 $as_echo "$boot_jdk_jvmargs_small" >&6; } 64385 64386 JAVA_FLAGS_SMALL=$boot_jdk_jvmargs_small 64387 64388 64389 JAVA_TOOL_FLAGS_SMALL="" 64390 for f in $JAVA_FLAGS_SMALL; do 64391 JAVA_TOOL_FLAGS_SMALL="$JAVA_TOOL_FLAGS_SMALL -J$f" 64392 done 64393 64394 64395 64396 # Setup smart javac (after cores and memory have been setup) 64397 64398 64399 # Check whether --with-sjavac-server-java was given. 64400 if test "${with_sjavac_server_java+set}" = set; then : 64401 withval=$with_sjavac_server_java; 64402 fi 64403 64404 64405 if test "x$with_sjavac_server_java" != x; then 64406 SJAVAC_SERVER_JAVA="$with_sjavac_server_java" 64407 FOUND_VERSION=`$SJAVAC_SERVER_JAVA -version 2>&1 | grep " version \""` 64408 if test "x$FOUND_VERSION" = x; then 64409 as_fn_error $? "Could not execute server java: $SJAVAC_SERVER_JAVA" "$LINENO" 5 64410 fi 64411 else 64412 SJAVAC_SERVER_JAVA="$JAVA" 64413 fi 64414 64415 64416 if test "$MEMORY_SIZE" -gt "3000"; then 64417 64418 $ECHO "Check if jvm arg is ok: -d64" >&5 64419 $ECHO "Command: $SJAVAC_SERVER_JAVA -d64 -version" >&5 64420 OUTPUT=`$SJAVAC_SERVER_JAVA -d64 -version 2>&1` 64421 FOUND_WARN=`$ECHO "$OUTPUT" | $GREP -i warn` 64422 FOUND_VERSION=`$ECHO $OUTPUT | $GREP " version \""` 64423 if test "x$FOUND_VERSION" != x && test "x$FOUND_WARN" = x; then 64424 SJAVAC_SERVER_JAVA_FLAGS="$SJAVAC_SERVER_JAVA_FLAGS -d64" 64425 JVM_ARG_OK=true 64426 else 64427 $ECHO "Arg failed:" >&5 64428 $ECHO "$OUTPUT" >&5 64429 JVM_ARG_OK=false 64430 fi 64431 64432 if test "$JVM_ARG_OK" = true; then 64433 JVM_64BIT=true 64434 JVM_ARG_OK=false 64435 fi 64436 fi 64437 64438 MX_VALUE=`expr $MEMORY_SIZE / 2` 64439 if test "$JVM_64BIT" = true; then 64440 # Set ms lower than mx since more than one instance of the server might 64441 # get launched at the same time before they figure out which instance won. 64442 MS_VALUE=512 64443 if test "$MX_VALUE" -gt "2048"; then 64444 MX_VALUE=2048 64445 fi 64446 else 64447 MS_VALUE=256 64448 if test "$MX_VALUE" -gt "1500"; then 64449 MX_VALUE=1500 64450 fi 64451 fi 64452 if test "$MX_VALUE" -lt "512"; then 64453 MX_VALUE=512 64454 fi 64455 64456 $ECHO "Check if jvm arg is ok: -Xms${MS_VALUE}M -Xmx${MX_VALUE}M" >&5 64457 $ECHO "Command: $SJAVAC_SERVER_JAVA -Xms${MS_VALUE}M -Xmx${MX_VALUE}M -version" >&5 64458 OUTPUT=`$SJAVAC_SERVER_JAVA -Xms${MS_VALUE}M -Xmx${MX_VALUE}M -version 2>&1` 64459 FOUND_WARN=`$ECHO "$OUTPUT" | $GREP -i warn` 64460 FOUND_VERSION=`$ECHO $OUTPUT | $GREP " version \""` 64461 if test "x$FOUND_VERSION" != x && test "x$FOUND_WARN" = x; then 64462 SJAVAC_SERVER_JAVA_FLAGS="$SJAVAC_SERVER_JAVA_FLAGS -Xms${MS_VALUE}M -Xmx${MX_VALUE}M" 64463 JVM_ARG_OK=true 64464 else 64465 $ECHO "Arg failed:" >&5 64466 $ECHO "$OUTPUT" >&5 64467 JVM_ARG_OK=false 64468 fi 64469 64470 64471 64472 # Check whether --enable-sjavac was given. 64473 if test "${enable_sjavac+set}" = set; then : 64474 enableval=$enable_sjavac; ENABLE_SJAVAC="${enableval}" 64475 else 64476 ENABLE_SJAVAC="no" 64477 fi 64478 64479 if test "x$JVM_ARG_OK" = "xfalse"; then 64480 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Could not set -Xms${MS_VALUE}M -Xmx${MX_VALUE}M, disabling sjavac" >&5 64481 $as_echo "$as_me: WARNING: Could not set -Xms${MS_VALUE}M -Xmx${MX_VALUE}M, disabling sjavac" >&2;} 64482 ENABLE_SJAVAC="no" 64483 fi 64484 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether to use sjavac" >&5 64485 $as_echo_n "checking whether to use sjavac... " >&6; } 64486 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ENABLE_SJAVAC" >&5 64487 $as_echo "$ENABLE_SJAVAC" >&6; } 64488 64489 64490 # Check whether --enable-javac-server was given. 64491 if test "${enable_javac_server+set}" = set; then : 64492 enableval=$enable_javac_server; ENABLE_JAVAC_SERVER="${enableval}" 64493 else 64494 ENABLE_JAVAC_SERVER="yes" 64495 fi 64496 64497 if test "x$JVM_ARG_OK" = "xfalse"; then 64498 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Could not set -Xms${MS_VALUE}M -Xmx${MX_VALUE}M, disabling javac server" >&5 64499 $as_echo "$as_me: WARNING: Could not set -Xms${MS_VALUE}M -Xmx${MX_VALUE}M, disabling javac server" >&2;} 64500 ENABLE_JAVAC_SERVER="no" 64501 fi 64502 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether to use javac server" >&5 64503 $as_echo_n "checking whether to use javac server... " >&6; } 64504 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ENABLE_JAVAC_SERVER" >&5 64505 $as_echo "$ENABLE_JAVAC_SERVER" >&6; } 64506 64507 64508 if test "x$ENABLE_JAVAC_SERVER" = "xyes" || test "x$ENABLE_SJAVAC" = "xyes"; then 64509 # When using a server javac, the small client instances do not need much 64510 # resources. 64511 JAVA_FLAGS_JAVAC="$JAVA_FLAGS_SMALL" 64512 fi 64513 64514 64515 # Setup use of icecc if requested 64516 64517 # Check whether --enable-icecc was given. 64518 if test "${enable_icecc+set}" = set; then : 64519 enableval=$enable_icecc; 64520 fi 64521 64522 64523 if test "x${enable_icecc}" = "xyes"; then 64524 64525 64526 64527 # Publish this variable in the help. 64528 64529 64530 if [ -z "${ICECC_CMD+x}" ]; then 64531 # The variable is not set by user, try to locate tool using the code snippet 64532 for ac_prog in icecc 64533 do 64534 # Extract the first word of "$ac_prog", so it can be a program name with args. 64535 set dummy $ac_prog; ac_word=$2 64536 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 64537 $as_echo_n "checking for $ac_word... " >&6; } 64538 if ${ac_cv_path_ICECC_CMD+:} false; then : 64539 $as_echo_n "(cached) " >&6 64540 else 64541 case $ICECC_CMD in 64542 [\\/]* | ?:[\\/]*) 64543 ac_cv_path_ICECC_CMD="$ICECC_CMD" # Let the user override the test with a path. 64544 ;; 64545 *) 64546 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 64547 for as_dir in $PATH 64548 do 64549 IFS=$as_save_IFS 64550 test -z "$as_dir" && as_dir=. 64551 for ac_exec_ext in '' $ac_executable_extensions; do 64552 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 64553 ac_cv_path_ICECC_CMD="$as_dir/$ac_word$ac_exec_ext" 64554 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 64555 break 2 64556 fi 64557 done 64558 done 64559 IFS=$as_save_IFS 64560 64561 ;; 64562 esac 64563 fi 64564 ICECC_CMD=$ac_cv_path_ICECC_CMD 64565 if test -n "$ICECC_CMD"; then 64566 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ICECC_CMD" >&5 64567 $as_echo "$ICECC_CMD" >&6; } 64568 else 64569 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 64570 $as_echo "no" >&6; } 64571 fi 64572 64573 64574 test -n "$ICECC_CMD" && break 64575 done 64576 64577 else 64578 # The variable is set, but is it from the command line or the environment? 64579 64580 # Try to remove the string !ICECC_CMD! from our list. 64581 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!ICECC_CMD!/} 64582 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 64583 # If it failed, the variable was not from the command line. Ignore it, 64584 # but warn the user (except for BASH, which is always set by the calling BASH). 64585 if test "xICECC_CMD" != xBASH; then 64586 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of ICECC_CMD from the environment. Use command line variables instead." >&5 64587 $as_echo "$as_me: WARNING: Ignoring value of ICECC_CMD from the environment. Use command line variables instead." >&2;} 64588 fi 64589 # Try to locate tool using the code snippet 64590 for ac_prog in icecc 64591 do 64592 # Extract the first word of "$ac_prog", so it can be a program name with args. 64593 set dummy $ac_prog; ac_word=$2 64594 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 64595 $as_echo_n "checking for $ac_word... " >&6; } 64596 if ${ac_cv_path_ICECC_CMD+:} false; then : 64597 $as_echo_n "(cached) " >&6 64598 else 64599 case $ICECC_CMD in 64600 [\\/]* | ?:[\\/]*) 64601 ac_cv_path_ICECC_CMD="$ICECC_CMD" # Let the user override the test with a path. 64602 ;; 64603 *) 64604 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 64605 for as_dir in $PATH 64606 do 64607 IFS=$as_save_IFS 64608 test -z "$as_dir" && as_dir=. 64609 for ac_exec_ext in '' $ac_executable_extensions; do 64610 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 64611 ac_cv_path_ICECC_CMD="$as_dir/$ac_word$ac_exec_ext" 64612 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 64613 break 2 64614 fi 64615 done 64616 done 64617 IFS=$as_save_IFS 64618 64619 ;; 64620 esac 64621 fi 64622 ICECC_CMD=$ac_cv_path_ICECC_CMD 64623 if test -n "$ICECC_CMD"; then 64624 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ICECC_CMD" >&5 64625 $as_echo "$ICECC_CMD" >&6; } 64626 else 64627 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 64628 $as_echo "no" >&6; } 64629 fi 64630 64631 64632 test -n "$ICECC_CMD" && break 64633 done 64634 64635 else 64636 # If it succeeded, then it was overridden by the user. We will use it 64637 # for the tool. 64638 64639 # First remove it from the list of overridden variables, so we can test 64640 # for unknown variables in the end. 64641 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 64642 64643 # Check if we try to supply an empty value 64644 if test "x$ICECC_CMD" = x; then 64645 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool ICECC_CMD= (no value)" >&5 64646 $as_echo "$as_me: Setting user supplied tool ICECC_CMD= (no value)" >&6;} 64647 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ICECC_CMD" >&5 64648 $as_echo_n "checking for ICECC_CMD... " >&6; } 64649 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 64650 $as_echo "disabled" >&6; } 64651 else 64652 # Check if the provided tool contains a complete path. 64653 tool_specified="$ICECC_CMD" 64654 tool_basename="${tool_specified##*/}" 64655 if test "x$tool_basename" = "x$tool_specified"; then 64656 # A command without a complete path is provided, search $PATH. 64657 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool ICECC_CMD=$tool_basename" >&5 64658 $as_echo "$as_me: Will search for user supplied tool ICECC_CMD=$tool_basename" >&6;} 64659 # Extract the first word of "$tool_basename", so it can be a program name with args. 64660 set dummy $tool_basename; ac_word=$2 64661 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 64662 $as_echo_n "checking for $ac_word... " >&6; } 64663 if ${ac_cv_path_ICECC_CMD+:} false; then : 64664 $as_echo_n "(cached) " >&6 64665 else 64666 case $ICECC_CMD in 64667 [\\/]* | ?:[\\/]*) 64668 ac_cv_path_ICECC_CMD="$ICECC_CMD" # Let the user override the test with a path. 64669 ;; 64670 *) 64671 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 64672 for as_dir in $PATH 64673 do 64674 IFS=$as_save_IFS 64675 test -z "$as_dir" && as_dir=. 64676 for ac_exec_ext in '' $ac_executable_extensions; do 64677 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 64678 ac_cv_path_ICECC_CMD="$as_dir/$ac_word$ac_exec_ext" 64679 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 64680 break 2 64681 fi 64682 done 64683 done 64684 IFS=$as_save_IFS 64685 64686 ;; 64687 esac 64688 fi 64689 ICECC_CMD=$ac_cv_path_ICECC_CMD 64690 if test -n "$ICECC_CMD"; then 64691 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ICECC_CMD" >&5 64692 $as_echo "$ICECC_CMD" >&6; } 64693 else 64694 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 64695 $as_echo "no" >&6; } 64696 fi 64697 64698 64699 if test "x$ICECC_CMD" = x; then 64700 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 64701 fi 64702 else 64703 # Otherwise we believe it is a complete path. Use it as it is. 64704 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool ICECC_CMD=$tool_specified" >&5 64705 $as_echo "$as_me: Will use user supplied tool ICECC_CMD=$tool_specified" >&6;} 64706 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ICECC_CMD" >&5 64707 $as_echo_n "checking for ICECC_CMD... " >&6; } 64708 if test ! -x "$tool_specified"; then 64709 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 64710 $as_echo "not found" >&6; } 64711 as_fn_error $? "User supplied tool ICECC_CMD=$tool_specified does not exist or is not executable" "$LINENO" 5 64712 fi 64713 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 64714 $as_echo "$tool_specified" >&6; } 64715 fi 64716 fi 64717 fi 64718 64719 fi 64720 64721 64722 64723 if test "x$ICECC_CMD" = x; then 64724 as_fn_error $? "Could not find required tool for ICECC_CMD" "$LINENO" 5 64725 fi 64726 64727 64728 old_path="$PATH" 64729 64730 # Look for icecc-create-env in some known places 64731 PATH="$PATH:/usr/lib/icecc:/usr/lib64/icecc" 64732 64733 64734 64735 # Publish this variable in the help. 64736 64737 64738 if [ -z "${ICECC_CREATE_ENV+x}" ]; then 64739 # The variable is not set by user, try to locate tool using the code snippet 64740 for ac_prog in icecc-create-env 64741 do 64742 # Extract the first word of "$ac_prog", so it can be a program name with args. 64743 set dummy $ac_prog; ac_word=$2 64744 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 64745 $as_echo_n "checking for $ac_word... " >&6; } 64746 if ${ac_cv_path_ICECC_CREATE_ENV+:} false; then : 64747 $as_echo_n "(cached) " >&6 64748 else 64749 case $ICECC_CREATE_ENV in 64750 [\\/]* | ?:[\\/]*) 64751 ac_cv_path_ICECC_CREATE_ENV="$ICECC_CREATE_ENV" # Let the user override the test with a path. 64752 ;; 64753 *) 64754 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 64755 for as_dir in $PATH 64756 do 64757 IFS=$as_save_IFS 64758 test -z "$as_dir" && as_dir=. 64759 for ac_exec_ext in '' $ac_executable_extensions; do 64760 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 64761 ac_cv_path_ICECC_CREATE_ENV="$as_dir/$ac_word$ac_exec_ext" 64762 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 64763 break 2 64764 fi 64765 done 64766 done 64767 IFS=$as_save_IFS 64768 64769 ;; 64770 esac 64771 fi 64772 ICECC_CREATE_ENV=$ac_cv_path_ICECC_CREATE_ENV 64773 if test -n "$ICECC_CREATE_ENV"; then 64774 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ICECC_CREATE_ENV" >&5 64775 $as_echo "$ICECC_CREATE_ENV" >&6; } 64776 else 64777 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 64778 $as_echo "no" >&6; } 64779 fi 64780 64781 64782 test -n "$ICECC_CREATE_ENV" && break 64783 done 64784 64785 else 64786 # The variable is set, but is it from the command line or the environment? 64787 64788 # Try to remove the string !ICECC_CREATE_ENV! from our list. 64789 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!ICECC_CREATE_ENV!/} 64790 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 64791 # If it failed, the variable was not from the command line. Ignore it, 64792 # but warn the user (except for BASH, which is always set by the calling BASH). 64793 if test "xICECC_CREATE_ENV" != xBASH; then 64794 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of ICECC_CREATE_ENV from the environment. Use command line variables instead." >&5 64795 $as_echo "$as_me: WARNING: Ignoring value of ICECC_CREATE_ENV from the environment. Use command line variables instead." >&2;} 64796 fi 64797 # Try to locate tool using the code snippet 64798 for ac_prog in icecc-create-env 64799 do 64800 # Extract the first word of "$ac_prog", so it can be a program name with args. 64801 set dummy $ac_prog; ac_word=$2 64802 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 64803 $as_echo_n "checking for $ac_word... " >&6; } 64804 if ${ac_cv_path_ICECC_CREATE_ENV+:} false; then : 64805 $as_echo_n "(cached) " >&6 64806 else 64807 case $ICECC_CREATE_ENV in 64808 [\\/]* | ?:[\\/]*) 64809 ac_cv_path_ICECC_CREATE_ENV="$ICECC_CREATE_ENV" # Let the user override the test with a path. 64810 ;; 64811 *) 64812 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 64813 for as_dir in $PATH 64814 do 64815 IFS=$as_save_IFS 64816 test -z "$as_dir" && as_dir=. 64817 for ac_exec_ext in '' $ac_executable_extensions; do 64818 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 64819 ac_cv_path_ICECC_CREATE_ENV="$as_dir/$ac_word$ac_exec_ext" 64820 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 64821 break 2 64822 fi 64823 done 64824 done 64825 IFS=$as_save_IFS 64826 64827 ;; 64828 esac 64829 fi 64830 ICECC_CREATE_ENV=$ac_cv_path_ICECC_CREATE_ENV 64831 if test -n "$ICECC_CREATE_ENV"; then 64832 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ICECC_CREATE_ENV" >&5 64833 $as_echo "$ICECC_CREATE_ENV" >&6; } 64834 else 64835 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 64836 $as_echo "no" >&6; } 64837 fi 64838 64839 64840 test -n "$ICECC_CREATE_ENV" && break 64841 done 64842 64843 else 64844 # If it succeeded, then it was overridden by the user. We will use it 64845 # for the tool. 64846 64847 # First remove it from the list of overridden variables, so we can test 64848 # for unknown variables in the end. 64849 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 64850 64851 # Check if we try to supply an empty value 64852 if test "x$ICECC_CREATE_ENV" = x; then 64853 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool ICECC_CREATE_ENV= (no value)" >&5 64854 $as_echo "$as_me: Setting user supplied tool ICECC_CREATE_ENV= (no value)" >&6;} 64855 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ICECC_CREATE_ENV" >&5 64856 $as_echo_n "checking for ICECC_CREATE_ENV... " >&6; } 64857 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 64858 $as_echo "disabled" >&6; } 64859 else 64860 # Check if the provided tool contains a complete path. 64861 tool_specified="$ICECC_CREATE_ENV" 64862 tool_basename="${tool_specified##*/}" 64863 if test "x$tool_basename" = "x$tool_specified"; then 64864 # A command without a complete path is provided, search $PATH. 64865 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool ICECC_CREATE_ENV=$tool_basename" >&5 64866 $as_echo "$as_me: Will search for user supplied tool ICECC_CREATE_ENV=$tool_basename" >&6;} 64867 # Extract the first word of "$tool_basename", so it can be a program name with args. 64868 set dummy $tool_basename; ac_word=$2 64869 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 64870 $as_echo_n "checking for $ac_word... " >&6; } 64871 if ${ac_cv_path_ICECC_CREATE_ENV+:} false; then : 64872 $as_echo_n "(cached) " >&6 64873 else 64874 case $ICECC_CREATE_ENV in 64875 [\\/]* | ?:[\\/]*) 64876 ac_cv_path_ICECC_CREATE_ENV="$ICECC_CREATE_ENV" # Let the user override the test with a path. 64877 ;; 64878 *) 64879 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 64880 for as_dir in $PATH 64881 do 64882 IFS=$as_save_IFS 64883 test -z "$as_dir" && as_dir=. 64884 for ac_exec_ext in '' $ac_executable_extensions; do 64885 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 64886 ac_cv_path_ICECC_CREATE_ENV="$as_dir/$ac_word$ac_exec_ext" 64887 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 64888 break 2 64889 fi 64890 done 64891 done 64892 IFS=$as_save_IFS 64893 64894 ;; 64895 esac 64896 fi 64897 ICECC_CREATE_ENV=$ac_cv_path_ICECC_CREATE_ENV 64898 if test -n "$ICECC_CREATE_ENV"; then 64899 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ICECC_CREATE_ENV" >&5 64900 $as_echo "$ICECC_CREATE_ENV" >&6; } 64901 else 64902 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 64903 $as_echo "no" >&6; } 64904 fi 64905 64906 64907 if test "x$ICECC_CREATE_ENV" = x; then 64908 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 64909 fi 64910 else 64911 # Otherwise we believe it is a complete path. Use it as it is. 64912 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool ICECC_CREATE_ENV=$tool_specified" >&5 64913 $as_echo "$as_me: Will use user supplied tool ICECC_CREATE_ENV=$tool_specified" >&6;} 64914 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ICECC_CREATE_ENV" >&5 64915 $as_echo_n "checking for ICECC_CREATE_ENV... " >&6; } 64916 if test ! -x "$tool_specified"; then 64917 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 64918 $as_echo "not found" >&6; } 64919 as_fn_error $? "User supplied tool ICECC_CREATE_ENV=$tool_specified does not exist or is not executable" "$LINENO" 5 64920 fi 64921 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 64922 $as_echo "$tool_specified" >&6; } 64923 fi 64924 fi 64925 fi 64926 64927 fi 64928 64929 64930 64931 if test "x$ICECC_CREATE_ENV" = x; then 64932 as_fn_error $? "Could not find required tool for ICECC_CREATE_ENV" "$LINENO" 5 64933 fi 64934 64935 64936 # Use icecc-create-env to create a minimal compilation environment that can 64937 # be sent to the other hosts in the icecream cluster. 64938 icecc_create_env_log="${CONFIGURESUPPORT_OUTPUTDIR}/icecc/icecc_create_env.log" 64939 ${MKDIR} -p ${CONFIGURESUPPORT_OUTPUTDIR}/icecc 64940 # Older versions of icecc does not have the --gcc parameter 64941 if ${ICECC_CREATE_ENV} | $GREP -q -e --gcc; then 64942 icecc_gcc_arg="--gcc" 64943 fi 64944 if test "x${TOOLCHAIN_TYPE}" = "xgcc"; then 64945 64946 ( cd ${CONFIGURESUPPORT_OUTPUTDIR}/icecc \ 64947 && ${ICECC_CREATE_ENV} ${icecc_gcc_arg} ${CC} ${CXX} > \ 64948 ${icecc_create_env_log} 2>&1 ) 64949 if test "$?" != "0"; then 64950 { $as_echo "$as_me:${as_lineno-$LINENO}: icecc-create-env output:" >&5 64951 $as_echo "$as_me: icecc-create-env output:" >&6;} 64952 cat \ 64953 ${icecc_create_env_log} 64954 as_fn_error $? "Failed to create icecc compiler environment" "$LINENO" 5 64955 fi 64956 64957 elif test "x$TOOLCHAIN_TYPE" = "xclang"; then 64958 # For clang, the icecc compilerwrapper is needed. It usually resides next 64959 # to icecc-create-env. 64960 64961 64962 64963 # Publish this variable in the help. 64964 64965 64966 if [ -z "${ICECC_WRAPPER+x}" ]; then 64967 # The variable is not set by user, try to locate tool using the code snippet 64968 for ac_prog in compilerwrapper 64969 do 64970 # Extract the first word of "$ac_prog", so it can be a program name with args. 64971 set dummy $ac_prog; ac_word=$2 64972 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 64973 $as_echo_n "checking for $ac_word... " >&6; } 64974 if ${ac_cv_path_ICECC_WRAPPER+:} false; then : 64975 $as_echo_n "(cached) " >&6 64976 else 64977 case $ICECC_WRAPPER in 64978 [\\/]* | ?:[\\/]*) 64979 ac_cv_path_ICECC_WRAPPER="$ICECC_WRAPPER" # Let the user override the test with a path. 64980 ;; 64981 *) 64982 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 64983 for as_dir in $PATH 64984 do 64985 IFS=$as_save_IFS 64986 test -z "$as_dir" && as_dir=. 64987 for ac_exec_ext in '' $ac_executable_extensions; do 64988 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 64989 ac_cv_path_ICECC_WRAPPER="$as_dir/$ac_word$ac_exec_ext" 64990 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 64991 break 2 64992 fi 64993 done 64994 done 64995 IFS=$as_save_IFS 64996 64997 ;; 64998 esac 64999 fi 65000 ICECC_WRAPPER=$ac_cv_path_ICECC_WRAPPER 65001 if test -n "$ICECC_WRAPPER"; then 65002 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ICECC_WRAPPER" >&5 65003 $as_echo "$ICECC_WRAPPER" >&6; } 65004 else 65005 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 65006 $as_echo "no" >&6; } 65007 fi 65008 65009 65010 test -n "$ICECC_WRAPPER" && break 65011 done 65012 65013 else 65014 # The variable is set, but is it from the command line or the environment? 65015 65016 # Try to remove the string !ICECC_WRAPPER! from our list. 65017 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!ICECC_WRAPPER!/} 65018 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 65019 # If it failed, the variable was not from the command line. Ignore it, 65020 # but warn the user (except for BASH, which is always set by the calling BASH). 65021 if test "xICECC_WRAPPER" != xBASH; then 65022 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of ICECC_WRAPPER from the environment. Use command line variables instead." >&5 65023 $as_echo "$as_me: WARNING: Ignoring value of ICECC_WRAPPER from the environment. Use command line variables instead." >&2;} 65024 fi 65025 # Try to locate tool using the code snippet 65026 for ac_prog in compilerwrapper 65027 do 65028 # Extract the first word of "$ac_prog", so it can be a program name with args. 65029 set dummy $ac_prog; ac_word=$2 65030 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 65031 $as_echo_n "checking for $ac_word... " >&6; } 65032 if ${ac_cv_path_ICECC_WRAPPER+:} false; then : 65033 $as_echo_n "(cached) " >&6 65034 else 65035 case $ICECC_WRAPPER in 65036 [\\/]* | ?:[\\/]*) 65037 ac_cv_path_ICECC_WRAPPER="$ICECC_WRAPPER" # Let the user override the test with a path. 65038 ;; 65039 *) 65040 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 65041 for as_dir in $PATH 65042 do 65043 IFS=$as_save_IFS 65044 test -z "$as_dir" && as_dir=. 65045 for ac_exec_ext in '' $ac_executable_extensions; do 65046 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 65047 ac_cv_path_ICECC_WRAPPER="$as_dir/$ac_word$ac_exec_ext" 65048 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 65049 break 2 65050 fi 65051 done 65052 done 65053 IFS=$as_save_IFS 65054 65055 ;; 65056 esac 65057 fi 65058 ICECC_WRAPPER=$ac_cv_path_ICECC_WRAPPER 65059 if test -n "$ICECC_WRAPPER"; then 65060 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ICECC_WRAPPER" >&5 65061 $as_echo "$ICECC_WRAPPER" >&6; } 65062 else 65063 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 65064 $as_echo "no" >&6; } 65065 fi 65066 65067 65068 test -n "$ICECC_WRAPPER" && break 65069 done 65070 65071 else 65072 # If it succeeded, then it was overridden by the user. We will use it 65073 # for the tool. 65074 65075 # First remove it from the list of overridden variables, so we can test 65076 # for unknown variables in the end. 65077 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 65078 65079 # Check if we try to supply an empty value 65080 if test "x$ICECC_WRAPPER" = x; then 65081 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool ICECC_WRAPPER= (no value)" >&5 65082 $as_echo "$as_me: Setting user supplied tool ICECC_WRAPPER= (no value)" >&6;} 65083 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ICECC_WRAPPER" >&5 65084 $as_echo_n "checking for ICECC_WRAPPER... " >&6; } 65085 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 65086 $as_echo "disabled" >&6; } 65087 else 65088 # Check if the provided tool contains a complete path. 65089 tool_specified="$ICECC_WRAPPER" 65090 tool_basename="${tool_specified##*/}" 65091 if test "x$tool_basename" = "x$tool_specified"; then 65092 # A command without a complete path is provided, search $PATH. 65093 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool ICECC_WRAPPER=$tool_basename" >&5 65094 $as_echo "$as_me: Will search for user supplied tool ICECC_WRAPPER=$tool_basename" >&6;} 65095 # Extract the first word of "$tool_basename", so it can be a program name with args. 65096 set dummy $tool_basename; ac_word=$2 65097 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 65098 $as_echo_n "checking for $ac_word... " >&6; } 65099 if ${ac_cv_path_ICECC_WRAPPER+:} false; then : 65100 $as_echo_n "(cached) " >&6 65101 else 65102 case $ICECC_WRAPPER in 65103 [\\/]* | ?:[\\/]*) 65104 ac_cv_path_ICECC_WRAPPER="$ICECC_WRAPPER" # Let the user override the test with a path. 65105 ;; 65106 *) 65107 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 65108 for as_dir in $PATH 65109 do 65110 IFS=$as_save_IFS 65111 test -z "$as_dir" && as_dir=. 65112 for ac_exec_ext in '' $ac_executable_extensions; do 65113 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 65114 ac_cv_path_ICECC_WRAPPER="$as_dir/$ac_word$ac_exec_ext" 65115 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 65116 break 2 65117 fi 65118 done 65119 done 65120 IFS=$as_save_IFS 65121 65122 ;; 65123 esac 65124 fi 65125 ICECC_WRAPPER=$ac_cv_path_ICECC_WRAPPER 65126 if test -n "$ICECC_WRAPPER"; then 65127 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ICECC_WRAPPER" >&5 65128 $as_echo "$ICECC_WRAPPER" >&6; } 65129 else 65130 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 65131 $as_echo "no" >&6; } 65132 fi 65133 65134 65135 if test "x$ICECC_WRAPPER" = x; then 65136 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 65137 fi 65138 else 65139 # Otherwise we believe it is a complete path. Use it as it is. 65140 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool ICECC_WRAPPER=$tool_specified" >&5 65141 $as_echo "$as_me: Will use user supplied tool ICECC_WRAPPER=$tool_specified" >&6;} 65142 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ICECC_WRAPPER" >&5 65143 $as_echo_n "checking for ICECC_WRAPPER... " >&6; } 65144 if test ! -x "$tool_specified"; then 65145 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 65146 $as_echo "not found" >&6; } 65147 as_fn_error $? "User supplied tool ICECC_WRAPPER=$tool_specified does not exist or is not executable" "$LINENO" 5 65148 fi 65149 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 65150 $as_echo "$tool_specified" >&6; } 65151 fi 65152 fi 65153 fi 65154 65155 fi 65156 65157 65158 65159 if test "x$ICECC_WRAPPER" = x; then 65160 as_fn_error $? "Could not find required tool for ICECC_WRAPPER" "$LINENO" 5 65161 fi 65162 65163 65164 65165 ( cd ${CONFIGURESUPPORT_OUTPUTDIR}/icecc \ 65166 && ${ICECC_CREATE_ENV} --clang ${CC} ${ICECC_WRAPPER} > ${icecc_create_env_log} 2>&1 ) 65167 if test "$?" != "0"; then 65168 { $as_echo "$as_me:${as_lineno-$LINENO}: icecc-create-env output:" >&5 65169 $as_echo "$as_me: icecc-create-env output:" >&6;} 65170 cat ${icecc_create_env_log} 65171 as_fn_error $? "Failed to create icecc compiler environment" "$LINENO" 5 65172 fi 65173 65174 else 65175 as_fn_error $? "Can only create icecc compiler packages for toolchain types gcc and clang" "$LINENO" 5 65176 fi 65177 PATH="$old_path" 65178 # The bundle with the compiler gets a name based on checksums. Parse log file 65179 # to find it. 65180 ICECC_ENV_BUNDLE_BASENAME="`${SED} -n '/^creating/s/creating //p' ${icecc_create_env_log}`" 65181 ICECC_ENV_BUNDLE="${CONFIGURESUPPORT_OUTPUTDIR}/icecc/${ICECC_ENV_BUNDLE_BASENAME}" 65182 if test ! -f ${ICECC_ENV_BUNDLE}; then 65183 as_fn_error $? "icecc-create-env did not produce an environment ${ICECC_ENV_BUNDLE}" "$LINENO" 5 65184 fi 65185 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for icecc build environment for target compiler" >&5 65186 $as_echo_n "checking for icecc build environment for target compiler... " >&6; } 65187 { $as_echo "$as_me:${as_lineno-$LINENO}: result: ${ICECC_ENV_BUNDLE}" >&5 65188 $as_echo "${ICECC_ENV_BUNDLE}" >&6; } 65189 ICECC="ICECC_VERSION=${ICECC_ENV_BUNDLE} ICECC_CC=${CC} ICECC_CXX=${CXX} ${ICECC_CMD}" 65190 65191 if test "x${COMPILE_TYPE}" = "xcross"; then 65192 # If cross compiling, create a separate env package for the build compiler 65193 # Assume "gcc" or "cc" is gcc and "clang" is clang. Otherwise bail. 65194 icecc_create_env_log_build="${CONFIGURESUPPORT_OUTPUTDIR}/icecc/icecc_create_env_build.log" 65195 if test "x${BUILD_CC##*/}" = "xgcc" || test "x${BUILD_CC##*/}" = "xcc"; then 65196 65197 ( cd ${CONFIGURESUPPORT_OUTPUTDIR}/icecc \ 65198 && ${ICECC_CREATE_ENV} ${icecc_gcc_arg} ${BUILD_CC} ${BUILD_CXX} > \ 65199 ${icecc_create_env_log_build} 2>&1 ) 65200 if test "$?" != "0"; then 65201 { $as_echo "$as_me:${as_lineno-$LINENO}: icecc-create-env output:" >&5 65202 $as_echo "$as_me: icecc-create-env output:" >&6;} 65203 cat \ 65204 ${icecc_create_env_log_build} 65205 as_fn_error $? "Failed to create icecc compiler environment" "$LINENO" 5 65206 fi 65207 65208 elif test "x${BUILD_CC##*/}" = "xclang"; then 65209 65210 ( cd ${CONFIGURESUPPORT_OUTPUTDIR}/icecc \ 65211 && ${ICECC_CREATE_ENV} --clang ${BUILD_CC} ${ICECC_WRAPPER} > ${icecc_create_env_log_build} 2>&1 ) 65212 if test "$?" != "0"; then 65213 { $as_echo "$as_me:${as_lineno-$LINENO}: icecc-create-env output:" >&5 65214 $as_echo "$as_me: icecc-create-env output:" >&6;} 65215 cat ${icecc_create_env_log_build} 65216 as_fn_error $? "Failed to create icecc compiler environment" "$LINENO" 5 65217 fi 65218 65219 else 65220 as_fn_error $? "Cannot create icecc compiler package for ${BUILD_CC}" "$LINENO" 5 65221 fi 65222 ICECC_ENV_BUNDLE_BASENAME="`${SED} -n '/^creating/s/creating //p' ${icecc_create_env_log_build}`" 65223 ICECC_ENV_BUNDLE="${CONFIGURESUPPORT_OUTPUTDIR}/icecc/${ICECC_ENV_BUNDLE_BASENAME}" 65224 if test ! -f ${ICECC_ENV_BUNDLE}; then 65225 as_fn_error $? "icecc-create-env did not produce an environment ${ICECC_ENV_BUNDLE}" "$LINENO" 5 65226 fi 65227 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for icecc build environment for build compiler" >&5 65228 $as_echo_n "checking for icecc build environment for build compiler... " >&6; } 65229 { $as_echo "$as_me:${as_lineno-$LINENO}: result: ${ICECC_ENV_BUNDLE}" >&5 65230 $as_echo "${ICECC_ENV_BUNDLE}" >&6; } 65231 BUILD_ICECC="ICECC_VERSION=${ICECC_ENV_BUNDLE} ICECC_CC=${BUILD_CC} \ 65232 ICECC_CXX=${BUILD_CXX} ${ICECC_CMD}" 65233 else 65234 BUILD_ICECC="${ICECC}" 65235 fi 65236 65237 65238 fi 65239 65240 65241 # Can the C/C++ compiler use precompiled headers? 65242 65243 65244 ############################################################################### 65245 # 65246 # Can the C/C++ compiler use precompiled headers? 65247 # 65248 # Check whether --enable-precompiled-headers was given. 65249 if test "${enable_precompiled_headers+set}" = set; then : 65250 enableval=$enable_precompiled_headers; ENABLE_PRECOMPH=${enable_precompiled_headers} 65251 else 65252 ENABLE_PRECOMPH=yes 65253 fi 65254 65255 65256 USE_PRECOMPILED_HEADER=1 65257 { $as_echo "$as_me:${as_lineno-$LINENO}: checking If precompiled header is enabled" >&5 65258 $as_echo_n "checking If precompiled header is enabled... " >&6; } 65259 if test "x$ENABLE_PRECOMPH" = xno; then 65260 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no, forced" >&5 65261 $as_echo "no, forced" >&6; } 65262 USE_PRECOMPILED_HEADER=0 65263 elif test "x$ICECC" != "x"; then 65264 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no, does not work effectively with icecc" >&5 65265 $as_echo "no, does not work effectively with icecc" >&6; } 65266 USE_PRECOMPILED_HEADER=0 65267 elif test "x$TOOLCHAIN_TYPE" = xsolstudio; then 65268 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no, does not work with Solaris Studio" >&5 65269 $as_echo "no, does not work with Solaris Studio" >&6; } 65270 USE_PRECOMPILED_HEADER=0 65271 elif test "x$TOOLCHAIN_TYPE" = xxlc; then 65272 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no, does not work with xlc" >&5 65273 $as_echo "no, does not work with xlc" >&6; } 65274 USE_PRECOMPILED_HEADER=0 65275 else 65276 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 65277 $as_echo "yes" >&6; } 65278 fi 65279 65280 if test "x$ENABLE_PRECOMPH" = xyes; then 65281 # Check that the compiler actually supports precomp headers. 65282 if test "x$TOOLCHAIN_TYPE" = xgcc; then 65283 { $as_echo "$as_me:${as_lineno-$LINENO}: checking that precompiled headers work" >&5 65284 $as_echo_n "checking that precompiled headers work... " >&6; } 65285 echo "int alfa();" > conftest.h 65286 $CXX -x c++-header conftest.h -o conftest.hpp.gch 2>&5 >&5 65287 if test ! -f conftest.hpp.gch; then 65288 USE_PRECOMPILED_HEADER=0 65289 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 65290 $as_echo "no" >&6; } 65291 else 65292 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 65293 $as_echo "yes" >&6; } 65294 fi 65295 $RM conftest.h conftest.hpp.gch 65296 fi 65297 fi 65298 65299 65300 65301 65302 # Setup use of ccache, if available 65303 65304 # Check whether --enable-ccache was given. 65305 if test "${enable_ccache+set}" = set; then : 65306 enableval=$enable_ccache; 65307 fi 65308 65309 65310 CCACHE= 65311 CCACHE_STATUS= 65312 { $as_echo "$as_me:${as_lineno-$LINENO}: checking is ccache enabled" >&5 65313 $as_echo_n "checking is ccache enabled... " >&6; } 65314 if test "x$enable_ccache" = xyes; then 65315 if test "x$TOOLCHAIN_TYPE" = "xgcc" -o "x$TOOLCHAIN_TYPE" = "xclang"; then 65316 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 65317 $as_echo "yes" >&6; } 65318 OLD_PATH="$PATH" 65319 if test "x$TOOLCHAIN_PATH" != x; then 65320 PATH=$TOOLCHAIN_PATH:$PATH 65321 fi 65322 65323 65324 65325 # Publish this variable in the help. 65326 65327 65328 if [ -z "${CCACHE+x}" ]; then 65329 # The variable is not set by user, try to locate tool using the code snippet 65330 for ac_prog in ccache 65331 do 65332 # Extract the first word of "$ac_prog", so it can be a program name with args. 65333 set dummy $ac_prog; ac_word=$2 65334 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 65335 $as_echo_n "checking for $ac_word... " >&6; } 65336 if ${ac_cv_path_CCACHE+:} false; then : 65337 $as_echo_n "(cached) " >&6 65338 else 65339 case $CCACHE in 65340 [\\/]* | ?:[\\/]*) 65341 ac_cv_path_CCACHE="$CCACHE" # Let the user override the test with a path. 65342 ;; 65343 *) 65344 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 65345 for as_dir in $PATH 65346 do 65347 IFS=$as_save_IFS 65348 test -z "$as_dir" && as_dir=. 65349 for ac_exec_ext in '' $ac_executable_extensions; do 65350 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 65351 ac_cv_path_CCACHE="$as_dir/$ac_word$ac_exec_ext" 65352 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 65353 break 2 65354 fi 65355 done 65356 done 65357 IFS=$as_save_IFS 65358 65359 ;; 65360 esac 65361 fi 65362 CCACHE=$ac_cv_path_CCACHE 65363 if test -n "$CCACHE"; then 65364 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CCACHE" >&5 65365 $as_echo "$CCACHE" >&6; } 65366 else 65367 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 65368 $as_echo "no" >&6; } 65369 fi 65370 65371 65372 test -n "$CCACHE" && break 65373 done 65374 65375 else 65376 # The variable is set, but is it from the command line or the environment? 65377 65378 # Try to remove the string !CCACHE! from our list. 65379 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!CCACHE!/} 65380 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 65381 # If it failed, the variable was not from the command line. Ignore it, 65382 # but warn the user (except for BASH, which is always set by the calling BASH). 65383 if test "xCCACHE" != xBASH; then 65384 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of CCACHE from the environment. Use command line variables instead." >&5 65385 $as_echo "$as_me: WARNING: Ignoring value of CCACHE from the environment. Use command line variables instead." >&2;} 65386 fi 65387 # Try to locate tool using the code snippet 65388 for ac_prog in ccache 65389 do 65390 # Extract the first word of "$ac_prog", so it can be a program name with args. 65391 set dummy $ac_prog; ac_word=$2 65392 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 65393 $as_echo_n "checking for $ac_word... " >&6; } 65394 if ${ac_cv_path_CCACHE+:} false; then : 65395 $as_echo_n "(cached) " >&6 65396 else 65397 case $CCACHE in 65398 [\\/]* | ?:[\\/]*) 65399 ac_cv_path_CCACHE="$CCACHE" # Let the user override the test with a path. 65400 ;; 65401 *) 65402 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 65403 for as_dir in $PATH 65404 do 65405 IFS=$as_save_IFS 65406 test -z "$as_dir" && as_dir=. 65407 for ac_exec_ext in '' $ac_executable_extensions; do 65408 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 65409 ac_cv_path_CCACHE="$as_dir/$ac_word$ac_exec_ext" 65410 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 65411 break 2 65412 fi 65413 done 65414 done 65415 IFS=$as_save_IFS 65416 65417 ;; 65418 esac 65419 fi 65420 CCACHE=$ac_cv_path_CCACHE 65421 if test -n "$CCACHE"; then 65422 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CCACHE" >&5 65423 $as_echo "$CCACHE" >&6; } 65424 else 65425 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 65426 $as_echo "no" >&6; } 65427 fi 65428 65429 65430 test -n "$CCACHE" && break 65431 done 65432 65433 else 65434 # If it succeeded, then it was overridden by the user. We will use it 65435 # for the tool. 65436 65437 # First remove it from the list of overridden variables, so we can test 65438 # for unknown variables in the end. 65439 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 65440 65441 # Check if we try to supply an empty value 65442 if test "x$CCACHE" = x; then 65443 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool CCACHE= (no value)" >&5 65444 $as_echo "$as_me: Setting user supplied tool CCACHE= (no value)" >&6;} 65445 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for CCACHE" >&5 65446 $as_echo_n "checking for CCACHE... " >&6; } 65447 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 65448 $as_echo "disabled" >&6; } 65449 else 65450 # Check if the provided tool contains a complete path. 65451 tool_specified="$CCACHE" 65452 tool_basename="${tool_specified##*/}" 65453 if test "x$tool_basename" = "x$tool_specified"; then 65454 # A command without a complete path is provided, search $PATH. 65455 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool CCACHE=$tool_basename" >&5 65456 $as_echo "$as_me: Will search for user supplied tool CCACHE=$tool_basename" >&6;} 65457 # Extract the first word of "$tool_basename", so it can be a program name with args. 65458 set dummy $tool_basename; ac_word=$2 65459 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 65460 $as_echo_n "checking for $ac_word... " >&6; } 65461 if ${ac_cv_path_CCACHE+:} false; then : 65462 $as_echo_n "(cached) " >&6 65463 else 65464 case $CCACHE in 65465 [\\/]* | ?:[\\/]*) 65466 ac_cv_path_CCACHE="$CCACHE" # Let the user override the test with a path. 65467 ;; 65468 *) 65469 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 65470 for as_dir in $PATH 65471 do 65472 IFS=$as_save_IFS 65473 test -z "$as_dir" && as_dir=. 65474 for ac_exec_ext in '' $ac_executable_extensions; do 65475 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 65476 ac_cv_path_CCACHE="$as_dir/$ac_word$ac_exec_ext" 65477 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 65478 break 2 65479 fi 65480 done 65481 done 65482 IFS=$as_save_IFS 65483 65484 ;; 65485 esac 65486 fi 65487 CCACHE=$ac_cv_path_CCACHE 65488 if test -n "$CCACHE"; then 65489 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CCACHE" >&5 65490 $as_echo "$CCACHE" >&6; } 65491 else 65492 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 65493 $as_echo "no" >&6; } 65494 fi 65495 65496 65497 if test "x$CCACHE" = x; then 65498 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 65499 fi 65500 else 65501 # Otherwise we believe it is a complete path. Use it as it is. 65502 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool CCACHE=$tool_specified" >&5 65503 $as_echo "$as_me: Will use user supplied tool CCACHE=$tool_specified" >&6;} 65504 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for CCACHE" >&5 65505 $as_echo_n "checking for CCACHE... " >&6; } 65506 if test ! -x "$tool_specified"; then 65507 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 65508 $as_echo "not found" >&6; } 65509 as_fn_error $? "User supplied tool CCACHE=$tool_specified does not exist or is not executable" "$LINENO" 5 65510 fi 65511 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 65512 $as_echo "$tool_specified" >&6; } 65513 fi 65514 fi 65515 fi 65516 65517 fi 65518 65519 65520 65521 if test "x$CCACHE" = x; then 65522 as_fn_error $? "Could not find required tool for CCACHE" "$LINENO" 5 65523 fi 65524 65525 65526 PATH="$OLD_PATH" 65527 CCACHE_VERSION=`$CCACHE --version | head -n1 | $SED 's/[A-Za-z ]*//'` 65528 CCACHE_STATUS="Active ($CCACHE_VERSION)" 65529 else 65530 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 65531 $as_echo "no" >&6; } 65532 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: ccache is not supported with toolchain type $TOOLCHAIN_TYPE" >&5 65533 $as_echo "$as_me: WARNING: ccache is not supported with toolchain type $TOOLCHAIN_TYPE" >&2;} 65534 fi 65535 elif test "x$enable_ccache" = xno; then 65536 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no, explicitly disabled" >&5 65537 $as_echo "no, explicitly disabled" >&6; } 65538 CCACHE_STATUS="Disabled" 65539 elif test "x$enable_ccache" = x; then 65540 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 65541 $as_echo "no" >&6; } 65542 else 65543 { $as_echo "$as_me:${as_lineno-$LINENO}: result: unknown" >&5 65544 $as_echo "unknown" >&6; } 65545 as_fn_error $? "--enable-ccache does not accept any parameters" "$LINENO" 5 65546 fi 65547 65548 65549 65550 # Check whether --with-ccache-dir was given. 65551 if test "${with_ccache_dir+set}" = set; then : 65552 withval=$with_ccache_dir; 65553 fi 65554 65555 65556 if test "x$with_ccache_dir" != x; then 65557 # When using a non home ccache directory, assume the use is to share ccache files 65558 # with other users. Thus change the umask. 65559 SET_CCACHE_DIR="CCACHE_DIR=$with_ccache_dir CCACHE_UMASK=002" 65560 if test "x$CCACHE" = x; then 65561 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: --with-ccache-dir has no meaning when ccache is not enabled" >&5 65562 $as_echo "$as_me: WARNING: --with-ccache-dir has no meaning when ccache is not enabled" >&2;} 65563 fi 65564 fi 65565 65566 if test "x$CCACHE" != x; then 65567 65568 if test "x$CCACHE" != x; then 65569 if test "x$USE_PRECOMPILED_HEADER" = "x1"; then 65570 HAS_BAD_CCACHE=`$ECHO $CCACHE_VERSION | \ 65571 $GREP -e '^1.*' -e '^2.*' -e '^3\.0.*' -e '^3\.1\.[0123]$'` 65572 if test "x$HAS_BAD_CCACHE" != "x"; then 65573 as_fn_error $? "Precompiled headers requires ccache 3.1.4 or later, found $CCACHE_VERSION" "$LINENO" 5 65574 fi 65575 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if C-compiler supports ccache precompiled headers" >&5 65576 $as_echo_n "checking if C-compiler supports ccache precompiled headers... " >&6; } 65577 CCACHE_PRECOMP_FLAG="-fpch-preprocess" 65578 PUSHED_FLAGS="$CXXFLAGS" 65579 CXXFLAGS="$CCACHE_PRECOMP_FLAG $CXXFLAGS" 65580 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 65581 /* end confdefs.h. */ 65582 65583 int 65584 main () 65585 { 65586 65587 ; 65588 return 0; 65589 } 65590 _ACEOF 65591 if ac_fn_cxx_try_compile "$LINENO"; then : 65592 CC_KNOWS_CCACHE_TRICK=yes 65593 else 65594 CC_KNOWS_CCACHE_TRICK=no 65595 fi 65596 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext 65597 CXXFLAGS="$PUSHED_FLAGS" 65598 if test "x$CC_KNOWS_CCACHE_TRICK" = xyes; then 65599 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 65600 $as_echo "yes" >&6; } 65601 CFLAGS_CCACHE="$CCACHE_PRECOMP_FLAG" 65602 65603 CCACHE_SLOPPINESS=pch_defines,time_macros 65604 else 65605 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 65606 $as_echo "no" >&6; } 65607 as_fn_error $? "Cannot use ccache with precompiled headers without compiler support for $CCACHE_PRECOMP_FLAG" "$LINENO" 5 65608 fi 65609 fi 65610 65611 CCACHE="CCACHE_COMPRESS=1 $SET_CCACHE_DIR \ 65612 CCACHE_SLOPPINESS=$CCACHE_SLOPPINESS CCACHE_BASEDIR=$TOPDIR $CCACHE" 65613 65614 if test "x$SET_CCACHE_DIR" != x; then 65615 mkdir -p $CCACHE_DIR > /dev/null 2>&1 65616 chmod a+rwxs $CCACHE_DIR > /dev/null 2>&1 65617 fi 65618 fi 65619 65620 fi 65621 65622 65623 ############################################################################### 65624 # 65625 # And now the finish... 65626 # 65627 ############################################################################### 65628 65629 # Check for some common pitfalls 65630 65631 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 65632 file_to_test="$SRC_ROOT/LICENSE" 65633 if test `$STAT -c '%a' "$file_to_test"` -lt 400; then 65634 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 65635 fi 65636 fi 65637 65638 65639 # Did user specify any unknown variables? 65640 65641 if test "x$CONFIGURE_OVERRIDDEN_VARIABLES" != x; then 65642 # Replace the separating ! with spaces before presenting for end user. 65643 unknown_variables=${CONFIGURE_OVERRIDDEN_VARIABLES//!/ } 65644 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: The following variables might be unknown to configure: $unknown_variables" >&5 65645 $as_echo "$as_me: WARNING: The following variables might be unknown to configure: $unknown_variables" >&2;} 65646 fi 65647 65648 65649 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if build directory is on local disk" >&5 65650 $as_echo_n "checking if build directory is on local disk... " >&6; } 65651 65652 # df -l lists only local disks; if the given directory is not found then 65653 # a non-zero exit code is given 65654 if test "x$DF" = x; then 65655 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 65656 # msys does not have df; use Windows "net use" instead. 65657 IS_NETWORK_DISK=`net use | grep \`pwd -W | cut -d ":" -f 1 | tr a-z A-Z\`:` 65658 if test "x$IS_NETWORK_DISK" = x; then 65659 OUTPUT_DIR_IS_LOCAL="yes" 65660 else 65661 OUTPUT_DIR_IS_LOCAL="no" 65662 fi 65663 else 65664 # No df here, say it's local 65665 OUTPUT_DIR_IS_LOCAL="yes" 65666 fi 65667 else 65668 if $DF -l $OUTPUT_ROOT > /dev/null 2>&1; then 65669 OUTPUT_DIR_IS_LOCAL="yes" 65670 else 65671 OUTPUT_DIR_IS_LOCAL="no" 65672 fi 65673 fi 65674 65675 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $OUTPUT_DIR_IS_LOCAL" >&5 65676 $as_echo "$OUTPUT_DIR_IS_LOCAL" >&6; } 65677 65678 65679 65680 # Check if the user has any old-style ALT_ variables set. 65681 FOUND_ALT_VARIABLES=`env | grep ^ALT_` 65682 65683 # Before generating output files, test if they exist. If they do, this is a reconfigure. 65684 # Since we can't properly handle the dependencies for this, warn the user about the situation 65685 if test -e $OUTPUT_ROOT/spec.gmk; then 65686 IS_RECONFIGURE=yes 65687 else 65688 IS_RECONFIGURE=no 65689 fi 65690 65691 65692 # At the end, call the custom hook. (Dummy macro if no custom sources available) 65693 65694 65695 # This needs to be done after CUSTOM_LATE_HOOK since we can setup custom features. 65696 65697 # Keep feature lists sorted and free of duplicates 65698 JVM_FEATURES_server="$($ECHO $($PRINTF '%s\n' $JVM_FEATURES_server | $SORT -u))" 65699 JVM_FEATURES_client="$($ECHO $($PRINTF '%s\n' $JVM_FEATURES_client | $SORT -u))" 65700 JVM_FEATURES_core="$($ECHO $($PRINTF '%s\n' $JVM_FEATURES_core | $SORT -u))" 65701 JVM_FEATURES_minimal="$($ECHO $($PRINTF '%s\n' $JVM_FEATURES_minimal | $SORT -u))" 65702 JVM_FEATURES_zero="$($ECHO $($PRINTF '%s\n' $JVM_FEATURES_zero | $SORT -u))" 65703 JVM_FEATURES_zeroshark="$($ECHO $($PRINTF '%s\n' $JVM_FEATURES_zeroshark | $SORT -u))" 65704 JVM_FEATURES_custom="$($ECHO $($PRINTF '%s\n' $JVM_FEATURES_custom | $SORT -u))" 65705 65706 # Validate features 65707 for variant in $JVM_VARIANTS; do 65708 { $as_echo "$as_me:${as_lineno-$LINENO}: checking JVM features for JVM variant '$variant'" >&5 65709 $as_echo_n "checking JVM features for JVM variant '$variant'... " >&6; } 65710 features_var_name=JVM_FEATURES_$variant 65711 JVM_FEATURES_TO_TEST=${!features_var_name} 65712 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $JVM_FEATURES_TO_TEST" >&5 65713 $as_echo "$JVM_FEATURES_TO_TEST" >&6; } 65714 NEEDLE=${VALID_JVM_FEATURES// /$'\n'} 65715 STACK=${JVM_FEATURES_TO_TEST// /$'\n'} 65716 INVALID_FEATURES=`$GREP -Fvx "${NEEDLE}" <<< "${STACK}"` 65717 if test "x$INVALID_FEATURES" != x; then 65718 as_fn_error $? "Invalid JVM feature(s): $INVALID_FEATURES" "$LINENO" 5 65719 fi 65720 done 65721 65722 65723 # We're messing a bit with internal autoconf variables to put the config.status 65724 # in the output directory instead of the current directory. 65725 CONFIG_STATUS="$CONFIGURESUPPORT_OUTPUTDIR/config.status" 65726 65727 # Create the actual output files. Now the main work of configure is done. 65728 cat >confcache <<\_ACEOF 65729 # This file is a shell script that caches the results of configure 65730 # tests run on this system so they can be shared between configure 65731 # scripts and configure runs, see configure's option --config-cache. 65732 # It is not useful on other systems. If it contains results you don't 65733 # want to keep, you may remove or edit it. 65734 # 65735 # config.status only pays attention to the cache file if you give it 65736 # the --recheck option to rerun configure. 65737 # 65738 # `ac_cv_env_foo' variables (set or unset) will be overridden when 65739 # loading this file, other *unset* `ac_cv_foo' will be assigned the 65740 # following values. 65741 65742 _ACEOF 65743 65744 # The following way of writing the cache mishandles newlines in values, 65745 # but we know of no workaround that is simple, portable, and efficient. 65746 # So, we kill variables containing newlines. 65747 # Ultrix sh set writes to stderr and can't be redirected directly, 65748 # and sets the high bit in the cache file unless we assign to the vars. 65749 ( 65750 for ac_var in `(set) 2>&1 | sed -n 's/^\([a-zA-Z_][a-zA-Z0-9_]*\)=.*/\1/p'`; do 65751 eval ac_val=\$$ac_var 65752 case $ac_val in #( 65753 *${as_nl}*) 65754 case $ac_var in #( 65755 *_cv_*) { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: cache variable $ac_var contains a newline" >&5 65756 $as_echo "$as_me: WARNING: cache variable $ac_var contains a newline" >&2;} ;; 65757 esac 65758 case $ac_var in #( 65759 _ | IFS | as_nl) ;; #( 65760 BASH_ARGV | BASH_SOURCE) eval $ac_var= ;; #( 65761 *) { eval $ac_var=; unset $ac_var;} ;; 65762 esac ;; 65763 esac 65764 done 65765 65766 (set) 2>&1 | 65767 case $as_nl`(ac_space=' '; set) 2>&1` in #( 65768 *${as_nl}ac_space=\ *) 65769 # `set' does not quote correctly, so add quotes: double-quote 65770 # substitution turns \\\\ into \\, and sed turns \\ into \. 65771 sed -n \ 65772 "s/'/'\\\\''/g; 65773 s/^\\([_$as_cr_alnum]*_cv_[_$as_cr_alnum]*\\)=\\(.*\\)/\\1='\\2'/p" 65774 ;; #( 65775 *) 65776 # `set' quotes correctly as required by POSIX, so do not add quotes. 65777 sed -n "/^[_$as_cr_alnum]*_cv_[_$as_cr_alnum]*=/p" 65778 ;; 65779 esac | 65780 sort 65781 ) | 65782 sed ' 65783 /^ac_cv_env_/b end 65784 t clear 65785 :clear 65786 s/^\([^=]*\)=\(.*[{}].*\)$/test "${\1+set}" = set || &/ 65787 t end 65788 s/^\([^=]*\)=\(.*\)$/\1=${\1=\2}/ 65789 :end' >>confcache 65790 if diff "$cache_file" confcache >/dev/null 2>&1; then :; else 65791 if test -w "$cache_file"; then 65792 if test "x$cache_file" != "x/dev/null"; then 65793 { $as_echo "$as_me:${as_lineno-$LINENO}: updating cache $cache_file" >&5 65794 $as_echo "$as_me: updating cache $cache_file" >&6;} 65795 if test ! -f "$cache_file" || test -h "$cache_file"; then 65796 cat confcache >"$cache_file" 65797 else 65798 case $cache_file in #( 65799 */* | ?:*) 65800 mv -f confcache "$cache_file"$$ && 65801 mv -f "$cache_file"$$ "$cache_file" ;; #( 65802 *) 65803 mv -f confcache "$cache_file" ;; 65804 esac 65805 fi 65806 fi 65807 else 65808 { $as_echo "$as_me:${as_lineno-$LINENO}: not updating unwritable cache $cache_file" >&5 65809 $as_echo "$as_me: not updating unwritable cache $cache_file" >&6;} 65810 fi 65811 fi 65812 rm -f confcache 65813 65814 test "x$prefix" = xNONE && prefix=$ac_default_prefix 65815 # Let make expand exec_prefix. 65816 test "x$exec_prefix" = xNONE && exec_prefix='${prefix}' 65817 65818 # Transform confdefs.h into DEFS. 65819 # Protect against shell expansion while executing Makefile rules. 65820 # Protect against Makefile macro expansion. 65821 # 65822 # If the first sed substitution is executed (which looks for macros that 65823 # take arguments), then branch to the quote section. Otherwise, 65824 # look for a macro that doesn't take arguments. 65825 ac_script=' 65826 :mline 65827 /\\$/{ 65828 N 65829 s,\\\n,, 65830 b mline 65831 } 65832 t clear 65833 :clear 65834 s/^[ ]*#[ ]*define[ ][ ]*\([^ (][^ (]*([^)]*)\)[ ]*\(.*\)/-D\1=\2/g 65835 t quote 65836 s/^[ ]*#[ ]*define[ ][ ]*\([^ ][^ ]*\)[ ]*\(.*\)/-D\1=\2/g 65837 t quote 65838 b any 65839 :quote 65840 s/[ `~#$^&*(){}\\|;'\''"<>?]/\\&/g 65841 s/\[/\\&/g 65842 s/\]/\\&/g 65843 s/\$/$$/g 65844 H 65845 :any 65846 ${ 65847 g 65848 s/^\n// 65849 s/\n/ /g 65850 p 65851 } 65852 ' 65853 DEFS=`sed -n "$ac_script" confdefs.h` 65854 65855 65856 ac_libobjs= 65857 ac_ltlibobjs= 65858 U= 65859 for ac_i in : $LIBOBJS; do test "x$ac_i" = x: && continue 65860 # 1. Remove the extension, and $U if already installed. 65861 ac_script='s/\$U\././;s/\.o$//;s/\.obj$//' 65862 ac_i=`$as_echo "$ac_i" | sed "$ac_script"` 65863 # 2. Prepend LIBOBJDIR. When used with automake>=1.10 LIBOBJDIR 65864 # will be set to the directory where LIBOBJS objects are built. 65865 as_fn_append ac_libobjs " \${LIBOBJDIR}$ac_i\$U.$ac_objext" 65866 as_fn_append ac_ltlibobjs " \${LIBOBJDIR}$ac_i"'$U.lo' 65867 done 65868 LIBOBJS=$ac_libobjs 65869 65870 LTLIBOBJS=$ac_ltlibobjs 65871 65872 65873 65874 : "${CONFIG_STATUS=./config.status}" 65875 ac_write_fail=0 65876 ac_clean_files_save=$ac_clean_files 65877 ac_clean_files="$ac_clean_files $CONFIG_STATUS" 65878 { $as_echo "$as_me:${as_lineno-$LINENO}: creating $CONFIG_STATUS" >&5 65879 $as_echo "$as_me: creating $CONFIG_STATUS" >&6;} 65880 as_write_fail=0 65881 cat >$CONFIG_STATUS <<_ASEOF || as_write_fail=1 65882 #! $SHELL 65883 # Generated by $as_me. 65884 # Run this file to recreate the current configuration. 65885 # Compiler output produced by configure, useful for debugging 65886 # configure, is in config.log if it exists. 65887 65888 debug=false 65889 ac_cs_recheck=false 65890 ac_cs_silent=false 65891 65892 SHELL=\${CONFIG_SHELL-$SHELL} 65893 export SHELL 65894 _ASEOF 65895 cat >>$CONFIG_STATUS <<\_ASEOF || as_write_fail=1 65896 ## -------------------- ## 65897 ## M4sh Initialization. ## 65898 ## -------------------- ## 65899 65900 # Be more Bourne compatible 65901 DUALCASE=1; export DUALCASE # for MKS sh 65902 if test -n "${ZSH_VERSION+set}" && (emulate sh) >/dev/null 2>&1; then : 65903 emulate sh 65904 NULLCMD=: 65905 # Pre-4.2 versions of Zsh do word splitting on ${1+"$@"}, which 65906 # is contrary to our usage. Disable this feature. 65907 alias -g '${1+"$@"}'='"$@"' 65908 setopt NO_GLOB_SUBST 65909 else 65910 case `(set -o) 2>/dev/null` in #( 65911 *posix*) : 65912 set -o posix ;; #( 65913 *) : 65914 ;; 65915 esac 65916 fi 65917 65918 65919 as_nl=' 65920 ' 65921 export as_nl 65922 # Printing a long string crashes Solaris 7 /usr/bin/printf. 65923 as_echo='\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\' 65924 as_echo=$as_echo$as_echo$as_echo$as_echo$as_echo 65925 as_echo=$as_echo$as_echo$as_echo$as_echo$as_echo$as_echo 65926 # Prefer a ksh shell builtin over an external printf program on Solaris, 65927 # but without wasting forks for bash or zsh. 65928 if test -z "$BASH_VERSION$ZSH_VERSION" \ 65929 && (test "X`print -r -- $as_echo`" = "X$as_echo") 2>/dev/null; then 65930 as_echo='print -r --' 65931 as_echo_n='print -rn --' 65932 elif (test "X`printf %s $as_echo`" = "X$as_echo") 2>/dev/null; then 65933 as_echo='printf %s\n' 65934 as_echo_n='printf %s' 65935 else 65936 if test "X`(/usr/ucb/echo -n -n $as_echo) 2>/dev/null`" = "X-n $as_echo"; then 65937 as_echo_body='eval /usr/ucb/echo -n "$1$as_nl"' 65938 as_echo_n='/usr/ucb/echo -n' 65939 else 65940 as_echo_body='eval expr "X$1" : "X\\(.*\\)"' 65941 as_echo_n_body='eval 65942 arg=$1; 65943 case $arg in #( 65944 *"$as_nl"*) 65945 expr "X$arg" : "X\\(.*\\)$as_nl"; 65946 arg=`expr "X$arg" : ".*$as_nl\\(.*\\)"`;; 65947 esac; 65948 expr "X$arg" : "X\\(.*\\)" | tr -d "$as_nl" 65949 ' 65950 export as_echo_n_body 65951 as_echo_n='sh -c $as_echo_n_body as_echo' 65952 fi 65953 export as_echo_body 65954 as_echo='sh -c $as_echo_body as_echo' 65955 fi 65956 65957 # The user is always right. 65958 if test "${PATH_SEPARATOR+set}" != set; then 65959 PATH_SEPARATOR=: 65960 (PATH='/bin;/bin'; FPATH=$PATH; sh -c :) >/dev/null 2>&1 && { 65961 (PATH='/bin:/bin'; FPATH=$PATH; sh -c :) >/dev/null 2>&1 || 65962 PATH_SEPARATOR=';' 65963 } 65964 fi 65965 65966 65967 # IFS 65968 # We need space, tab and new line, in precisely that order. Quoting is 65969 # there to prevent editors from complaining about space-tab. 65970 # (If _AS_PATH_WALK were called with IFS unset, it would disable word 65971 # splitting by setting IFS to empty value.) 65972 IFS=" "" $as_nl" 65973 65974 # Find who we are. Look in the path if we contain no directory separator. 65975 as_myself= 65976 case $0 in #(( 65977 *[\\/]* ) as_myself=$0 ;; 65978 *) as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 65979 for as_dir in $PATH 65980 do 65981 IFS=$as_save_IFS 65982 test -z "$as_dir" && as_dir=. 65983 test -r "$as_dir/$0" && as_myself=$as_dir/$0 && break 65984 done 65985 IFS=$as_save_IFS 65986 65987 ;; 65988 esac 65989 # We did not find ourselves, most probably we were run as `sh COMMAND' 65990 # in which case we are not to be found in the path. 65991 if test "x$as_myself" = x; then 65992 as_myself=$0 65993 fi 65994 if test ! -f "$as_myself"; then 65995 $as_echo "$as_myself: error: cannot find myself; rerun with an absolute file name" >&2 65996 exit 1 65997 fi 65998 65999 # Unset variables that we do not need and which cause bugs (e.g. in 66000 # pre-3.0 UWIN ksh). But do not cause bugs in bash 2.01; the "|| exit 1" 66001 # suppresses any "Segmentation fault" message there. '((' could 66002 # trigger a bug in pdksh 5.2.14. 66003 for as_var in BASH_ENV ENV MAIL MAILPATH 66004 do eval test x\${$as_var+set} = xset \ 66005 && ( (unset $as_var) || exit 1) >/dev/null 2>&1 && unset $as_var || : 66006 done 66007 PS1='$ ' 66008 PS2='> ' 66009 PS4='+ ' 66010 66011 # NLS nuisances. 66012 LC_ALL=C 66013 export LC_ALL 66014 LANGUAGE=C 66015 export LANGUAGE 66016 66017 # CDPATH. 66018 (unset CDPATH) >/dev/null 2>&1 && unset CDPATH 66019 66020 66021 # as_fn_error STATUS ERROR [LINENO LOG_FD] 66022 # ---------------------------------------- 66023 # Output "`basename $0`: error: ERROR" to stderr. If LINENO and LOG_FD are 66024 # provided, also output the error to LOG_FD, referencing LINENO. Then exit the 66025 # script with STATUS, using 1 if that was 0. 66026 as_fn_error () 66027 { 66028 as_status=$1; test $as_status -eq 0 && as_status=1 66029 if test "$4"; then 66030 as_lineno=${as_lineno-"$3"} as_lineno_stack=as_lineno_stack=$as_lineno_stack 66031 $as_echo "$as_me:${as_lineno-$LINENO}: error: $2" >&$4 66032 fi 66033 $as_echo "$as_me: error: $2" >&2 66034 as_fn_exit $as_status 66035 } # as_fn_error 66036 66037 66038 # as_fn_set_status STATUS 66039 # ----------------------- 66040 # Set $? to STATUS, without forking. 66041 as_fn_set_status () 66042 { 66043 return $1 66044 } # as_fn_set_status 66045 66046 # as_fn_exit STATUS 66047 # ----------------- 66048 # Exit the shell with STATUS, even in a "trap 0" or "set -e" context. 66049 as_fn_exit () 66050 { 66051 set +e 66052 as_fn_set_status $1 66053 exit $1 66054 } # as_fn_exit 66055 66056 # as_fn_unset VAR 66057 # --------------- 66058 # Portably unset VAR. 66059 as_fn_unset () 66060 { 66061 { eval $1=; unset $1;} 66062 } 66063 as_unset=as_fn_unset 66064 # as_fn_append VAR VALUE 66065 # ---------------------- 66066 # Append the text in VALUE to the end of the definition contained in VAR. Take 66067 # advantage of any shell optimizations that allow amortized linear growth over 66068 # repeated appends, instead of the typical quadratic growth present in naive 66069 # implementations. 66070 if (eval "as_var=1; as_var+=2; test x\$as_var = x12") 2>/dev/null; then : 66071 eval 'as_fn_append () 66072 { 66073 eval $1+=\$2 66074 }' 66075 else 66076 as_fn_append () 66077 { 66078 eval $1=\$$1\$2 66079 } 66080 fi # as_fn_append 66081 66082 # as_fn_arith ARG... 66083 # ------------------ 66084 # Perform arithmetic evaluation on the ARGs, and store the result in the 66085 # global $as_val. Take advantage of shells that can avoid forks. The arguments 66086 # must be portable across $(()) and expr. 66087 if (eval "test \$(( 1 + 1 )) = 2") 2>/dev/null; then : 66088 eval 'as_fn_arith () 66089 { 66090 as_val=$(( $* )) 66091 }' 66092 else 66093 as_fn_arith () 66094 { 66095 as_val=`expr "$@" || test $? -eq 1` 66096 } 66097 fi # as_fn_arith 66098 66099 66100 if expr a : '\(a\)' >/dev/null 2>&1 && 66101 test "X`expr 00001 : '.*\(...\)'`" = X001; then 66102 as_expr=expr 66103 else 66104 as_expr=false 66105 fi 66106 66107 if (basename -- /) >/dev/null 2>&1 && test "X`basename -- / 2>&1`" = "X/"; then 66108 as_basename=basename 66109 else 66110 as_basename=false 66111 fi 66112 66113 if (as_dir=`dirname -- /` && test "X$as_dir" = X/) >/dev/null 2>&1; then 66114 as_dirname=dirname 66115 else 66116 as_dirname=false 66117 fi 66118 66119 as_me=`$as_basename -- "$0" || 66120 $as_expr X/"$0" : '.*/\([^/][^/]*\)/*$' \| \ 66121 X"$0" : 'X\(//\)$' \| \ 66122 X"$0" : 'X\(/\)' \| . 2>/dev/null || 66123 $as_echo X/"$0" | 66124 sed '/^.*\/\([^/][^/]*\)\/*$/{ 66125 s//\1/ 66126 q 66127 } 66128 /^X\/\(\/\/\)$/{ 66129 s//\1/ 66130 q 66131 } 66132 /^X\/\(\/\).*/{ 66133 s//\1/ 66134 q 66135 } 66136 s/.*/./; q'` 66137 66138 # Avoid depending upon Character Ranges. 66139 as_cr_letters='abcdefghijklmnopqrstuvwxyz' 66140 as_cr_LETTERS='ABCDEFGHIJKLMNOPQRSTUVWXYZ' 66141 as_cr_Letters=$as_cr_letters$as_cr_LETTERS 66142 as_cr_digits='0123456789' 66143 as_cr_alnum=$as_cr_Letters$as_cr_digits 66144 66145 ECHO_C= ECHO_N= ECHO_T= 66146 case `echo -n x` in #((((( 66147 -n*) 66148 case `echo 'xy\c'` in 66149 *c*) ECHO_T=' ';; # ECHO_T is single tab character. 66150 xy) ECHO_C='\c';; 66151 *) echo `echo ksh88 bug on AIX 6.1` > /dev/null 66152 ECHO_T=' ';; 66153 esac;; 66154 *) 66155 ECHO_N='-n';; 66156 esac 66157 66158 rm -f conf$$ conf$$.exe conf$$.file 66159 if test -d conf$$.dir; then 66160 rm -f conf$$.dir/conf$$.file 66161 else 66162 rm -f conf$$.dir 66163 mkdir conf$$.dir 2>/dev/null 66164 fi 66165 if (echo >conf$$.file) 2>/dev/null; then 66166 if ln -s conf$$.file conf$$ 2>/dev/null; then 66167 as_ln_s='ln -s' 66168 # ... but there are two gotchas: 66169 # 1) On MSYS, both `ln -s file dir' and `ln file dir' fail. 66170 # 2) DJGPP < 2.04 has no symlinks; `ln -s' creates a wrapper executable. 66171 # In both cases, we have to default to `cp -pR'. 66172 ln -s conf$$.file conf$$.dir 2>/dev/null && test ! -f conf$$.exe || 66173 as_ln_s='cp -pR' 66174 elif ln conf$$.file conf$$ 2>/dev/null; then 66175 as_ln_s=ln 66176 else 66177 as_ln_s='cp -pR' 66178 fi 66179 else 66180 as_ln_s='cp -pR' 66181 fi 66182 rm -f conf$$ conf$$.exe conf$$.dir/conf$$.file conf$$.file 66183 rmdir conf$$.dir 2>/dev/null 66184 66185 66186 # as_fn_mkdir_p 66187 # ------------- 66188 # Create "$as_dir" as a directory, including parents if necessary. 66189 as_fn_mkdir_p () 66190 { 66191 66192 case $as_dir in #( 66193 -*) as_dir=./$as_dir;; 66194 esac 66195 test -d "$as_dir" || eval $as_mkdir_p || { 66196 as_dirs= 66197 while :; do 66198 case $as_dir in #( 66199 *\'*) as_qdir=`$as_echo "$as_dir" | sed "s/'/'\\\\\\\\''/g"`;; #'( 66200 *) as_qdir=$as_dir;; 66201 esac 66202 as_dirs="'$as_qdir' $as_dirs" 66203 as_dir=`$as_dirname -- "$as_dir" || 66204 $as_expr X"$as_dir" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \ 66205 X"$as_dir" : 'X\(//\)[^/]' \| \ 66206 X"$as_dir" : 'X\(//\)$' \| \ 66207 X"$as_dir" : 'X\(/\)' \| . 2>/dev/null || 66208 $as_echo X"$as_dir" | 66209 sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{ 66210 s//\1/ 66211 q 66212 } 66213 /^X\(\/\/\)[^/].*/{ 66214 s//\1/ 66215 q 66216 } 66217 /^X\(\/\/\)$/{ 66218 s//\1/ 66219 q 66220 } 66221 /^X\(\/\).*/{ 66222 s//\1/ 66223 q 66224 } 66225 s/.*/./; q'` 66226 test -d "$as_dir" && break 66227 done 66228 test -z "$as_dirs" || eval "mkdir $as_dirs" 66229 } || test -d "$as_dir" || as_fn_error $? "cannot create directory $as_dir" 66230 66231 66232 } # as_fn_mkdir_p 66233 if mkdir -p . 2>/dev/null; then 66234 as_mkdir_p='mkdir -p "$as_dir"' 66235 else 66236 test -d ./-p && rmdir ./-p 66237 as_mkdir_p=false 66238 fi 66239 66240 66241 # as_fn_executable_p FILE 66242 # ----------------------- 66243 # Test if FILE is an executable regular file. 66244 as_fn_executable_p () 66245 { 66246 test -f "$1" && test -x "$1" 66247 } # as_fn_executable_p 66248 as_test_x='test -x' 66249 as_executable_p=as_fn_executable_p 66250 66251 # Sed expression to map a string onto a valid CPP name. 66252 as_tr_cpp="eval sed 'y%*$as_cr_letters%P$as_cr_LETTERS%;s%[^_$as_cr_alnum]%_%g'" 66253 66254 # Sed expression to map a string onto a valid variable name. 66255 as_tr_sh="eval sed 'y%*+%pp%;s%[^_$as_cr_alnum]%_%g'" 66256 66257 66258 exec 6>&1 66259 ## ----------------------------------- ## 66260 ## Main body of $CONFIG_STATUS script. ## 66261 ## ----------------------------------- ## 66262 _ASEOF 66263 test $as_write_fail = 0 && chmod +x $CONFIG_STATUS || ac_write_fail=1 66264 66265 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1 66266 # Save the log message, to keep $0 and so on meaningful, and to 66267 # report actual input values of CONFIG_FILES etc. instead of their 66268 # values after options handling. 66269 ac_log=" 66270 This file was extended by OpenJDK $as_me jdk9, which was 66271 generated by GNU Autoconf 2.69. Invocation command line was 66272 66273 CONFIG_FILES = $CONFIG_FILES 66274 CONFIG_HEADERS = $CONFIG_HEADERS 66275 CONFIG_LINKS = $CONFIG_LINKS 66276 CONFIG_COMMANDS = $CONFIG_COMMANDS 66277 $ $0 $@ 66278 66279 on `(hostname || uname -n) 2>/dev/null | sed 1q` 66280 " 66281 66282 _ACEOF 66283 66284 case $ac_config_files in *" 66285 "*) set x $ac_config_files; shift; ac_config_files=$*;; 66286 esac 66287 66288 66289 66290 cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1 66291 # Files that config.status was made for. 66292 config_files="$ac_config_files" 66293 66294 _ACEOF 66295 66296 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1 66297 ac_cs_usage="\ 66298 \`$as_me' instantiates files and other configuration actions 66299 from templates according to the current configuration. Unless the files 66300 and actions are specified as TAGs, all are instantiated by default. 66301 66302 Usage: $0 [OPTION]... [TAG]... 66303 66304 -h, --help print this help, then exit 66305 -V, --version print version number and configuration settings, then exit 66306 --config print configuration, then exit 66307 -q, --quiet, --silent 66308 do not print progress messages 66309 -d, --debug don't remove temporary files 66310 --recheck update $as_me by reconfiguring in the same conditions 66311 --file=FILE[:TEMPLATE] 66312 instantiate the configuration file FILE 66313 66314 Configuration files: 66315 $config_files 66316 66317 Report bugs to <build-dev@openjdk.java.net>. 66318 OpenJDK home page: <http://openjdk.java.net>." 66319 66320 _ACEOF 66321 cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1 66322 ac_cs_config="`$as_echo "$ac_configure_args" | sed 's/^ //; s/[\\""\`\$]/\\\\&/g'`" 66323 ac_cs_version="\\ 66324 OpenJDK config.status jdk9 66325 configured by $0, generated by GNU Autoconf 2.69, 66326 with options \\"\$ac_cs_config\\" 66327 66328 Copyright (C) 2012 Free Software Foundation, Inc. 66329 This config.status script is free software; the Free Software Foundation 66330 gives unlimited permission to copy, distribute and modify it." 66331 66332 ac_pwd='$ac_pwd' 66333 srcdir='$srcdir' 66334 AWK='$AWK' 66335 test -n "\$AWK" || AWK=awk 66336 _ACEOF 66337 66338 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1 66339 # The default lists apply if the user does not specify any file. 66340 ac_need_defaults=: 66341 while test $# != 0 66342 do 66343 case $1 in 66344 --*=?*) 66345 ac_option=`expr "X$1" : 'X\([^=]*\)='` 66346 ac_optarg=`expr "X$1" : 'X[^=]*=\(.*\)'` 66347 ac_shift=: 66348 ;; 66349 --*=) 66350 ac_option=`expr "X$1" : 'X\([^=]*\)='` 66351 ac_optarg= 66352 ac_shift=: 66353 ;; 66354 *) 66355 ac_option=$1 66356 ac_optarg=$2 66357 ac_shift=shift 66358 ;; 66359 esac 66360 66361 case $ac_option in 66362 # Handling of the options. 66363 -recheck | --recheck | --rechec | --reche | --rech | --rec | --re | --r) 66364 ac_cs_recheck=: ;; 66365 --version | --versio | --versi | --vers | --ver | --ve | --v | -V ) 66366 $as_echo "$ac_cs_version"; exit ;; 66367 --config | --confi | --conf | --con | --co | --c ) 66368 $as_echo "$ac_cs_config"; exit ;; 66369 --debug | --debu | --deb | --de | --d | -d ) 66370 debug=: ;; 66371 --file | --fil | --fi | --f ) 66372 $ac_shift 66373 case $ac_optarg in 66374 *\'*) ac_optarg=`$as_echo "$ac_optarg" | sed "s/'/'\\\\\\\\''/g"` ;; 66375 '') as_fn_error $? "missing file argument" ;; 66376 esac 66377 as_fn_append CONFIG_FILES " '$ac_optarg'" 66378 ac_need_defaults=false;; 66379 --he | --h | --help | --hel | -h ) 66380 $as_echo "$ac_cs_usage"; exit ;; 66381 -q | -quiet | --quiet | --quie | --qui | --qu | --q \ 66382 | -silent | --silent | --silen | --sile | --sil | --si | --s) 66383 ac_cs_silent=: ;; 66384 66385 # This is an error. 66386 -*) as_fn_error $? "unrecognized option: \`$1' 66387 Try \`$0 --help' for more information." ;; 66388 66389 *) as_fn_append ac_config_targets " $1" 66390 ac_need_defaults=false ;; 66391 66392 esac 66393 shift 66394 done 66395 66396 ac_configure_extra_args= 66397 66398 if $ac_cs_silent; then 66399 exec 6>/dev/null 66400 ac_configure_extra_args="$ac_configure_extra_args --silent" 66401 fi 66402 66403 _ACEOF 66404 cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1 66405 if \$ac_cs_recheck; then 66406 set X $SHELL '$0' $ac_configure_args \$ac_configure_extra_args --no-create --no-recursion 66407 shift 66408 \$as_echo "running CONFIG_SHELL=$SHELL \$*" >&6 66409 CONFIG_SHELL='$SHELL' 66410 export CONFIG_SHELL 66411 exec "\$@" 66412 fi 66413 66414 _ACEOF 66415 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1 66416 exec 5>>config.log 66417 { 66418 echo 66419 sed 'h;s/./-/g;s/^.../## /;s/...$/ ##/;p;x;p;x' <<_ASBOX 66420 ## Running $as_me. ## 66421 _ASBOX 66422 $as_echo "$ac_log" 66423 } >&5 66424 66425 _ACEOF 66426 cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1 66427 _ACEOF 66428 66429 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1 66430 66431 # Handling of arguments. 66432 for ac_config_target in $ac_config_targets 66433 do 66434 case $ac_config_target in 66435 "$OUTPUT_ROOT/spec.gmk") CONFIG_FILES="$CONFIG_FILES $OUTPUT_ROOT/spec.gmk:$AUTOCONF_DIR/spec.gmk.in" ;; 66436 "$OUTPUT_ROOT/bootcycle-spec.gmk") CONFIG_FILES="$CONFIG_FILES $OUTPUT_ROOT/bootcycle-spec.gmk:$AUTOCONF_DIR/bootcycle-spec.gmk.in" ;; 66437 "$OUTPUT_ROOT/buildjdk-spec.gmk") CONFIG_FILES="$CONFIG_FILES $OUTPUT_ROOT/buildjdk-spec.gmk:$AUTOCONF_DIR/buildjdk-spec.gmk.in" ;; 66438 "$OUTPUT_ROOT/compare.sh") CONFIG_FILES="$CONFIG_FILES $OUTPUT_ROOT/compare.sh:$AUTOCONF_DIR/compare.sh.in" ;; 66439 "$OUTPUT_ROOT/Makefile") CONFIG_FILES="$CONFIG_FILES $OUTPUT_ROOT/Makefile:$AUTOCONF_DIR/Makefile.in" ;; 66440 66441 *) as_fn_error $? "invalid argument: \`$ac_config_target'" "$LINENO" 5;; 66442 esac 66443 done 66444 66445 66446 # If the user did not use the arguments to specify the items to instantiate, 66447 # then the envvar interface is used. Set only those that are not. 66448 # We use the long form for the default assignment because of an extremely 66449 # bizarre bug on SunOS 4.1.3. 66450 if $ac_need_defaults; then 66451 test "${CONFIG_FILES+set}" = set || CONFIG_FILES=$config_files 66452 fi 66453 66454 # Have a temporary directory for convenience. Make it in the build tree 66455 # simply because there is no reason against having it here, and in addition, 66456 # creating and moving files from /tmp can sometimes cause problems. 66457 # Hook for its removal unless debugging. 66458 # Note that there is a small window in which the directory will not be cleaned: 66459 # after its creation but before its name has been assigned to `$tmp'. 66460 $debug || 66461 { 66462 tmp= ac_tmp= 66463 trap 'exit_status=$? 66464 : "${ac_tmp:=$tmp}" 66465 { test ! -d "$ac_tmp" || rm -fr "$ac_tmp"; } && exit $exit_status 66466 ' 0 66467 trap 'as_fn_exit 1' 1 2 13 15 66468 } 66469 # Create a (secure) tmp directory for tmp files. 66470 66471 { 66472 tmp=`(umask 077 && mktemp -d "./confXXXXXX") 2>/dev/null` && 66473 test -d "$tmp" 66474 } || 66475 { 66476 tmp=./conf$$-$RANDOM 66477 (umask 077 && mkdir "$tmp") 66478 } || as_fn_error $? "cannot create a temporary directory in ." "$LINENO" 5 66479 ac_tmp=$tmp 66480 66481 # Set up the scripts for CONFIG_FILES section. 66482 # No need to generate them if there are no CONFIG_FILES. 66483 # This happens for instance with `./config.status config.h'. 66484 if test -n "$CONFIG_FILES"; then 66485 66486 66487 ac_cr=`echo X | tr X '\015'` 66488 # On cygwin, bash can eat \r inside `` if the user requested igncr. 66489 # But we know of no other shell where ac_cr would be empty at this 66490 # point, so we can use a bashism as a fallback. 66491 if test "x$ac_cr" = x; then 66492 eval ac_cr=\$\'\\r\' 66493 fi 66494 ac_cs_awk_cr=`$AWK 'BEGIN { print "a\rb" }' </dev/null 2>/dev/null` 66495 if test "$ac_cs_awk_cr" = "a${ac_cr}b"; then 66496 ac_cs_awk_cr='\\r' 66497 else 66498 ac_cs_awk_cr=$ac_cr 66499 fi 66500 66501 echo 'BEGIN {' >"$ac_tmp/subs1.awk" && 66502 _ACEOF 66503 66504 66505 { 66506 echo "cat >conf$$subs.awk <<_ACEOF" && 66507 echo "$ac_subst_vars" | sed 's/.*/&!$&$ac_delim/' && 66508 echo "_ACEOF" 66509 } >conf$$subs.sh || 66510 as_fn_error $? "could not make $CONFIG_STATUS" "$LINENO" 5 66511 ac_delim_num=`echo "$ac_subst_vars" | grep -c '^'` 66512 ac_delim='%!_!# ' 66513 for ac_last_try in false false false false false :; do 66514 . ./conf$$subs.sh || 66515 as_fn_error $? "could not make $CONFIG_STATUS" "$LINENO" 5 66516 66517 ac_delim_n=`sed -n "s/.*$ac_delim\$/X/p" conf$$subs.awk | grep -c X` 66518 if test $ac_delim_n = $ac_delim_num; then 66519 break 66520 elif $ac_last_try; then 66521 as_fn_error $? "could not make $CONFIG_STATUS" "$LINENO" 5 66522 else 66523 ac_delim="$ac_delim!$ac_delim _$ac_delim!! " 66524 fi 66525 done 66526 rm -f conf$$subs.sh 66527 66528 cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1 66529 cat >>"\$ac_tmp/subs1.awk" <<\\_ACAWK && 66530 _ACEOF 66531 sed -n ' 66532 h 66533 s/^/S["/; s/!.*/"]=/ 66534 p 66535 g 66536 s/^[^!]*!// 66537 :repl 66538 t repl 66539 s/'"$ac_delim"'$// 66540 t delim 66541 :nl 66542 h 66543 s/\(.\{148\}\)..*/\1/ 66544 t more1 66545 s/["\\]/\\&/g; s/^/"/; s/$/\\n"\\/ 66546 p 66547 n 66548 b repl 66549 :more1 66550 s/["\\]/\\&/g; s/^/"/; s/$/"\\/ 66551 p 66552 g 66553 s/.\{148\}// 66554 t nl 66555 :delim 66556 h 66557 s/\(.\{148\}\)..*/\1/ 66558 t more2 66559 s/["\\]/\\&/g; s/^/"/; s/$/"/ 66560 p 66561 b 66562 :more2 66563 s/["\\]/\\&/g; s/^/"/; s/$/"\\/ 66564 p 66565 g 66566 s/.\{148\}// 66567 t delim 66568 ' <conf$$subs.awk | sed ' 66569 /^[^""]/{ 66570 N 66571 s/\n// 66572 } 66573 ' >>$CONFIG_STATUS || ac_write_fail=1 66574 rm -f conf$$subs.awk 66575 cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1 66576 _ACAWK 66577 cat >>"\$ac_tmp/subs1.awk" <<_ACAWK && 66578 for (key in S) S_is_set[key] = 1 66579 FS = "" 66580 66581 } 66582 { 66583 line = $ 0 66584 nfields = split(line, field, "@") 66585 substed = 0 66586 len = length(field[1]) 66587 for (i = 2; i < nfields; i++) { 66588 key = field[i] 66589 keylen = length(key) 66590 if (S_is_set[key]) { 66591 value = S[key] 66592 line = substr(line, 1, len) "" value "" substr(line, len + keylen + 3) 66593 len += length(value) + length(field[++i]) 66594 substed = 1 66595 } else 66596 len += 1 + keylen 66597 } 66598 66599 print line 66600 } 66601 66602 _ACAWK 66603 _ACEOF 66604 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1 66605 if sed "s/$ac_cr//" < /dev/null > /dev/null 2>&1; then 66606 sed "s/$ac_cr\$//; s/$ac_cr/$ac_cs_awk_cr/g" 66607 else 66608 cat 66609 fi < "$ac_tmp/subs1.awk" > "$ac_tmp/subs.awk" \ 66610 || as_fn_error $? "could not setup config files machinery" "$LINENO" 5 66611 _ACEOF 66612 66613 # VPATH may cause trouble with some makes, so we remove sole $(srcdir), 66614 # ${srcdir} and @srcdir@ entries from VPATH if srcdir is ".", strip leading and 66615 # trailing colons and then remove the whole line if VPATH becomes empty 66616 # (actually we leave an empty line to preserve line numbers). 66617 if test "x$srcdir" = x.; then 66618 ac_vpsub='/^[ ]*VPATH[ ]*=[ ]*/{ 66619 h 66620 s/// 66621 s/^/:/ 66622 s/[ ]*$/:/ 66623 s/:\$(srcdir):/:/g 66624 s/:\${srcdir}:/:/g 66625 s/:@srcdir@:/:/g 66626 s/^:*// 66627 s/:*$// 66628 x 66629 s/\(=[ ]*\).*/\1/ 66630 G 66631 s/\n// 66632 s/^[^=]*=[ ]*$// 66633 }' 66634 fi 66635 66636 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1 66637 fi # test -n "$CONFIG_FILES" 66638 66639 66640 eval set X " :F $CONFIG_FILES " 66641 shift 66642 for ac_tag 66643 do 66644 case $ac_tag in 66645 :[FHLC]) ac_mode=$ac_tag; continue;; 66646 esac 66647 case $ac_mode$ac_tag in 66648 :[FHL]*:*);; 66649 :L* | :C*:*) as_fn_error $? "invalid tag \`$ac_tag'" "$LINENO" 5;; 66650 :[FH]-) ac_tag=-:-;; 66651 :[FH]*) ac_tag=$ac_tag:$ac_tag.in;; 66652 esac 66653 ac_save_IFS=$IFS 66654 IFS=: 66655 set x $ac_tag 66656 IFS=$ac_save_IFS 66657 shift 66658 ac_file=$1 66659 shift 66660 66661 case $ac_mode in 66662 :L) ac_source=$1;; 66663 :[FH]) 66664 ac_file_inputs= 66665 for ac_f 66666 do 66667 case $ac_f in 66668 -) ac_f="$ac_tmp/stdin";; 66669 *) # Look for the file first in the build tree, then in the source tree 66670 # (if the path is not absolute). The absolute path cannot be DOS-style, 66671 # because $ac_f cannot contain `:'. 66672 test -f "$ac_f" || 66673 case $ac_f in 66674 [\\/$]*) false;; 66675 *) test -f "$srcdir/$ac_f" && ac_f="$srcdir/$ac_f";; 66676 esac || 66677 as_fn_error 1 "cannot find input file: \`$ac_f'" "$LINENO" 5;; 66678 esac 66679 case $ac_f in *\'*) ac_f=`$as_echo "$ac_f" | sed "s/'/'\\\\\\\\''/g"`;; esac 66680 as_fn_append ac_file_inputs " '$ac_f'" 66681 done 66682 66683 # Let's still pretend it is `configure' which instantiates (i.e., don't 66684 # use $as_me), people would be surprised to read: 66685 # /* config.h. Generated by config.status. */ 66686 configure_input='Generated from '` 66687 $as_echo "$*" | sed 's|^[^:]*/||;s|:[^:]*/|, |g' 66688 `' by configure.' 66689 if test x"$ac_file" != x-; then 66690 configure_input="$ac_file. $configure_input" 66691 { $as_echo "$as_me:${as_lineno-$LINENO}: creating $ac_file" >&5 66692 $as_echo "$as_me: creating $ac_file" >&6;} 66693 fi 66694 # Neutralize special characters interpreted by sed in replacement strings. 66695 case $configure_input in #( 66696 *\&* | *\|* | *\\* ) 66697 ac_sed_conf_input=`$as_echo "$configure_input" | 66698 sed 's/[\\\\&|]/\\\\&/g'`;; #( 66699 *) ac_sed_conf_input=$configure_input;; 66700 esac 66701 66702 case $ac_tag in 66703 *:-:* | *:-) cat >"$ac_tmp/stdin" \ 66704 || as_fn_error $? "could not create $ac_file" "$LINENO" 5 ;; 66705 esac 66706 ;; 66707 esac 66708 66709 ac_dir=`$as_dirname -- "$ac_file" || 66710 $as_expr X"$ac_file" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \ 66711 X"$ac_file" : 'X\(//\)[^/]' \| \ 66712 X"$ac_file" : 'X\(//\)$' \| \ 66713 X"$ac_file" : 'X\(/\)' \| . 2>/dev/null || 66714 $as_echo X"$ac_file" | 66715 sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{ 66716 s//\1/ 66717 q 66718 } 66719 /^X\(\/\/\)[^/].*/{ 66720 s//\1/ 66721 q 66722 } 66723 /^X\(\/\/\)$/{ 66724 s//\1/ 66725 q 66726 } 66727 /^X\(\/\).*/{ 66728 s//\1/ 66729 q 66730 } 66731 s/.*/./; q'` 66732 as_dir="$ac_dir"; as_fn_mkdir_p 66733 ac_builddir=. 66734 66735 case "$ac_dir" in 66736 .) ac_dir_suffix= ac_top_builddir_sub=. ac_top_build_prefix= ;; 66737 *) 66738 ac_dir_suffix=/`$as_echo "$ac_dir" | sed 's|^\.[\\/]||'` 66739 # A ".." for each directory in $ac_dir_suffix. 66740 ac_top_builddir_sub=`$as_echo "$ac_dir_suffix" | sed 's|/[^\\/]*|/..|g;s|/||'` 66741 case $ac_top_builddir_sub in 66742 "") ac_top_builddir_sub=. ac_top_build_prefix= ;; 66743 *) ac_top_build_prefix=$ac_top_builddir_sub/ ;; 66744 esac ;; 66745 esac 66746 ac_abs_top_builddir=$ac_pwd 66747 ac_abs_builddir=$ac_pwd$ac_dir_suffix 66748 # for backward compatibility: 66749 ac_top_builddir=$ac_top_build_prefix 66750 66751 case $srcdir in 66752 .) # We are building in place. 66753 ac_srcdir=. 66754 ac_top_srcdir=$ac_top_builddir_sub 66755 ac_abs_top_srcdir=$ac_pwd ;; 66756 [\\/]* | ?:[\\/]* ) # Absolute name. 66757 ac_srcdir=$srcdir$ac_dir_suffix; 66758 ac_top_srcdir=$srcdir 66759 ac_abs_top_srcdir=$srcdir ;; 66760 *) # Relative name. 66761 ac_srcdir=$ac_top_build_prefix$srcdir$ac_dir_suffix 66762 ac_top_srcdir=$ac_top_build_prefix$srcdir 66763 ac_abs_top_srcdir=$ac_pwd/$srcdir ;; 66764 esac 66765 ac_abs_srcdir=$ac_abs_top_srcdir$ac_dir_suffix 66766 66767 66768 case $ac_mode in 66769 :F) 66770 # 66771 # CONFIG_FILE 66772 # 66773 66774 _ACEOF 66775 66776 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1 66777 # If the template does not know about datarootdir, expand it. 66778 # FIXME: This hack should be removed a few years after 2.60. 66779 ac_datarootdir_hack=; ac_datarootdir_seen= 66780 ac_sed_dataroot=' 66781 /datarootdir/ { 66782 p 66783 q 66784 } 66785 /@datadir@/p 66786 /@docdir@/p 66787 /@infodir@/p 66788 /@localedir@/p 66789 /@mandir@/p' 66790 case `eval "sed -n \"\$ac_sed_dataroot\" $ac_file_inputs"` in 66791 *datarootdir*) ac_datarootdir_seen=yes;; 66792 *@datadir@*|*@docdir@*|*@infodir@*|*@localedir@*|*@mandir@*) 66793 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $ac_file_inputs seems to ignore the --datarootdir setting" >&5 66794 $as_echo "$as_me: WARNING: $ac_file_inputs seems to ignore the --datarootdir setting" >&2;} 66795 _ACEOF 66796 cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1 66797 ac_datarootdir_hack=' 66798 s&@datadir@&$datadir&g 66799 s&@docdir@&$docdir&g 66800 s&@infodir@&$infodir&g 66801 s&@localedir@&$localedir&g 66802 s&@mandir@&$mandir&g 66803 s&\\\${datarootdir}&$datarootdir&g' ;; 66804 esac 66805 _ACEOF 66806 66807 # Neutralize VPATH when `$srcdir' = `.'. 66808 # Shell code in configure.ac might set extrasub. 66809 # FIXME: do we really want to maintain this feature? 66810 cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1 66811 ac_sed_extra="$ac_vpsub 66812 $extrasub 66813 _ACEOF 66814 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1 66815 :t 66816 /@[a-zA-Z_][a-zA-Z_0-9]*@/!b 66817 s|@configure_input@|$ac_sed_conf_input|;t t 66818 s&@top_builddir@&$ac_top_builddir_sub&;t t 66819 s&@top_build_prefix@&$ac_top_build_prefix&;t t 66820 s&@srcdir@&$ac_srcdir&;t t 66821 s&@abs_srcdir@&$ac_abs_srcdir&;t t 66822 s&@top_srcdir@&$ac_top_srcdir&;t t 66823 s&@abs_top_srcdir@&$ac_abs_top_srcdir&;t t 66824 s&@builddir@&$ac_builddir&;t t 66825 s&@abs_builddir@&$ac_abs_builddir&;t t 66826 s&@abs_top_builddir@&$ac_abs_top_builddir&;t t 66827 $ac_datarootdir_hack 66828 " 66829 eval sed \"\$ac_sed_extra\" "$ac_file_inputs" | $AWK -f "$ac_tmp/subs.awk" \ 66830 >$ac_tmp/out || as_fn_error $? "could not create $ac_file" "$LINENO" 5 66831 66832 test -z "$ac_datarootdir_hack$ac_datarootdir_seen" && 66833 { ac_out=`sed -n '/\${datarootdir}/p' "$ac_tmp/out"`; test -n "$ac_out"; } && 66834 { ac_out=`sed -n '/^[ ]*datarootdir[ ]*:*=/p' \ 66835 "$ac_tmp/out"`; test -z "$ac_out"; } && 66836 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $ac_file contains a reference to the variable \`datarootdir' 66837 which seems to be undefined. Please make sure it is defined" >&5 66838 $as_echo "$as_me: WARNING: $ac_file contains a reference to the variable \`datarootdir' 66839 which seems to be undefined. Please make sure it is defined" >&2;} 66840 66841 rm -f "$ac_tmp/stdin" 66842 case $ac_file in 66843 -) cat "$ac_tmp/out" && rm -f "$ac_tmp/out";; 66844 *) rm -f "$ac_file" && mv "$ac_tmp/out" "$ac_file";; 66845 esac \ 66846 || as_fn_error $? "could not create $ac_file" "$LINENO" 5 66847 ;; 66848 66849 66850 66851 esac 66852 66853 done # for ac_tag 66854 66855 66856 as_fn_exit 0 66857 _ACEOF 66858 ac_clean_files=$ac_clean_files_save 66859 66860 test $ac_write_fail = 0 || 66861 as_fn_error $? "write failure creating $CONFIG_STATUS" "$LINENO" 5 66862 66863 66864 # configure is writing to config.log, and then calls config.status. 66865 # config.status does its own redirection, appending to config.log. 66866 # Unfortunately, on DOS this fails, as config.log is still kept open 66867 # by configure, so config.status won't be able to write to it; its 66868 # output is simply discarded. So we exec the FD to /dev/null, 66869 # effectively closing config.log, so it can be properly (re)opened and 66870 # appended to by config.status. When coming back to configure, we 66871 # need to make the FD available again. 66872 if test "$no_create" != yes; then 66873 ac_cs_success=: 66874 ac_config_status_args= 66875 test "$silent" = yes && 66876 ac_config_status_args="$ac_config_status_args --quiet" 66877 exec 5>/dev/null 66878 $SHELL $CONFIG_STATUS $ac_config_status_args || ac_cs_success=false 66879 exec 5>>config.log 66880 # Use ||, not &&, to avoid exiting from the if with $? = 1, which 66881 # would make configure fail if this is the last instruction. 66882 $ac_cs_success || as_fn_exit 1 66883 fi 66884 if test -n "$ac_unrecognized_opts" && test "$enable_option_checking" != no; then 66885 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: unrecognized options: $ac_unrecognized_opts" >&5 66886 $as_echo "$as_me: WARNING: unrecognized options: $ac_unrecognized_opts" >&2;} 66887 fi 66888 66889 66890 # After AC_OUTPUT, we need to do final work 66891 66892 66893 # Try to move config.log (generated by autoconf) to the configure-support directory. 66894 if test -e ./config.log; then 66895 $MV -f ./config.log "$CONFIGURESUPPORT_OUTPUTDIR/config.log" 2> /dev/null 66896 fi 66897 66898 # Rotate our log file (configure.log) 66899 if test -e "$OUTPUT_ROOT/configure.log.old"; then 66900 $RM -f "$OUTPUT_ROOT/configure.log.old" 66901 fi 66902 if test -e "$OUTPUT_ROOT/configure.log"; then 66903 $MV -f "$OUTPUT_ROOT/configure.log" "$OUTPUT_ROOT/configure.log.old" 2> /dev/null 66904 fi 66905 66906 # Move configure.log from current directory to the build output root 66907 if test -e ./configure.log; then 66908 $MV -f ./configure.log "$OUTPUT_ROOT/configure.log" 2> /dev/null 66909 fi 66910 66911 # Make the compare script executable 66912 $CHMOD +x $OUTPUT_ROOT/compare.sh 66913 66914 66915 # Finally output some useful information to the user 66916 66917 # Finally output some useful information to the user 66918 66919 printf "\n" 66920 printf "====================================================\n" 66921 if test "x$no_create" != "xyes"; then 66922 if test "x$IS_RECONFIGURE" != "xyes"; then 66923 printf "A new configuration has been successfully created in\n%s\n" "$OUTPUT_ROOT" 66924 else 66925 printf "The existing configuration has been successfully updated in\n%s\n" "$OUTPUT_ROOT" 66926 fi 66927 else 66928 if test "x$IS_RECONFIGURE" != "xyes"; then 66929 printf "A configuration has been successfully checked but not created\n" 66930 else 66931 printf "The existing configuration has been successfully checked in\n%s\n" "$OUTPUT_ROOT" 66932 fi 66933 fi 66934 if test "x$CONFIGURE_COMMAND_LINE" != x; then 66935 printf "using configure arguments '$CONFIGURE_COMMAND_LINE'.\n" 66936 else 66937 printf "using default settings.\n" 66938 fi 66939 66940 printf "\n" 66941 printf "Configuration summary:\n" 66942 printf "* Debug level: $DEBUG_LEVEL\n" 66943 printf "* HS debug level: $HOTSPOT_DEBUG_LEVEL\n" 66944 printf "* JDK variant: $JDK_VARIANT\n" 66945 printf "* JVM variants: $JVM_VARIANTS\n" 66946 printf "* OpenJDK target: OS: $OPENJDK_TARGET_OS, CPU architecture: $OPENJDK_TARGET_CPU_ARCH, address length: $OPENJDK_TARGET_CPU_BITS\n" 66947 printf "* Version string: $VERSION_STRING ($VERSION_SHORT)\n" 66948 66949 printf "\n" 66950 printf "Tools summary:\n" 66951 if test "x$OPENJDK_BUILD_OS" = "xwindows"; then 66952 printf "* Environment: $WINDOWS_ENV_VENDOR version $WINDOWS_ENV_VERSION (root at $WINDOWS_ENV_ROOT_PATH)\n" 66953 fi 66954 printf "* Boot JDK: $BOOT_JDK_VERSION (at $BOOT_JDK)\n" 66955 if test "x$TOOLCHAIN_VERSION" != "x"; then 66956 print_version=" $TOOLCHAIN_VERSION" 66957 fi 66958 printf "* Toolchain: $TOOLCHAIN_TYPE ($TOOLCHAIN_DESCRIPTION$print_version)\n" 66959 printf "* C Compiler: Version $CC_VERSION_NUMBER (at $CC)\n" 66960 printf "* C++ Compiler: Version $CXX_VERSION_NUMBER (at $CXX)\n" 66961 66962 printf "\n" 66963 printf "Build performance summary:\n" 66964 printf "* Cores to use: $JOBS\n" 66965 printf "* Memory limit: $MEMORY_SIZE MB\n" 66966 if test "x$CCACHE_STATUS" != "x"; then 66967 printf "* ccache status: $CCACHE_STATUS\n" 66968 fi 66969 printf "\n" 66970 66971 if test "x$BUILDING_MULTIPLE_JVM_VARIANTS" = "xtrue"; then 66972 printf "NOTE: You have requested to build more than one version of the JVM, which\n" 66973 printf "will result in longer build times.\n" 66974 printf "\n" 66975 fi 66976 66977 if test "x$FOUND_ALT_VARIABLES" != "x"; then 66978 printf "WARNING: You have old-style ALT_ environment variables set.\n" 66979 printf "These are not respected, and will be ignored. It is recommended\n" 66980 printf "that you clean your environment. The following variables are set:\n" 66981 printf "$FOUND_ALT_VARIABLES\n" 66982 printf "\n" 66983 fi 66984 66985 if test "x$OUTPUT_DIR_IS_LOCAL" != "xyes"; then 66986 printf "WARNING: Your build output directory is not on a local disk.\n" 66987 printf "This will severely degrade build performance!\n" 66988 printf "It is recommended that you create an output directory on a local disk,\n" 66989 printf "and run the configure script again from that directory.\n" 66990 printf "\n" 66991 fi 66992 66993 if test "x$IS_RECONFIGURE" = "xyes" && test "x$no_create" != "xyes"; then 66994 printf "WARNING: The result of this configuration has overridden an older\n" 66995 printf "configuration. You *should* run 'make clean' to make sure you get a\n" 66996 printf "proper build. Failure to do so might result in strange build problems.\n" 66997 printf "\n" 66998 fi 66999 67000 if test "x$IS_RECONFIGURE" != "xyes" && test "x$no_create" = "xyes"; then 67001 printf "WARNING: The result of this configuration was not saved.\n" 67002 printf "You should run without '--no-create | -n' to create the configuration.\n" 67003 printf "\n" 67004 fi 67005 67006 67007 67008 # Locate config.log. 67009 if test -e "$CONFIGURESUPPORT_OUTPUTDIR/config.log"; then 67010 CONFIG_LOG_PATH="$CONFIGURESUPPORT_OUTPUTDIR" 67011 elif test -e "./config.log"; then 67012 CONFIG_LOG_PATH="." 67013 fi 67014 67015 if test -e "$CONFIG_LOG_PATH/config.log"; then 67016 $GREP '^configure:.*: WARNING:' "$CONFIG_LOG_PATH/config.log" > /dev/null 2>&1 67017 if test $? -eq 0; then 67018 printf "The following warnings were produced. Repeated here for convenience:\n" 67019 # We must quote sed expression (using []) to stop m4 from eating the []. 67020 $GREP '^configure:.*: WARNING:' "$CONFIG_LOG_PATH/config.log" | $SED -e 's/^configure:[0-9]*: //' 67021 printf "\n" 67022 fi 67023 fi 67024