1 #!/bin/bash 2 # 3 # ########################################################## 4 # ### THIS FILE IS AUTOMATICALLY GENERATED. DO NOT EDIT. ### 5 # ########################################################## 6 # 7 #! /bin/sh 8 # Guess values for system-dependent variables and create Makefiles. 9 # Generated by GNU Autoconf 2.69 for OpenJDK jdk9. 10 # 11 # Report bugs to <build-dev@openjdk.java.net>. 12 # 13 # 14 # Copyright (C) 1992-1996, 1998-2012 Free Software Foundation, Inc. 15 # 16 # 17 # This configure script is free software; the Free Software Foundation 18 # gives unlimited permission to copy, distribute and modify it. 19 ## -------------------- ## 20 ## M4sh Initialization. ## 21 ## -------------------- ## 22 23 # Be more Bourne compatible 24 DUALCASE=1; export DUALCASE # for MKS sh 25 if test -n "${ZSH_VERSION+set}" && (emulate sh) >/dev/null 2>&1; then : 26 emulate sh 27 NULLCMD=: 28 # Pre-4.2 versions of Zsh do word splitting on ${1+"$@"}, which 29 # is contrary to our usage. Disable this feature. 30 alias -g '${1+"$@"}'='"$@"' 31 setopt NO_GLOB_SUBST 32 else 33 case `(set -o) 2>/dev/null` in #( 34 *posix*) : 35 set -o posix ;; #( 36 *) : 37 ;; 38 esac 39 fi 40 41 42 as_nl=' 43 ' 44 export as_nl 45 # Printing a long string crashes Solaris 7 /usr/bin/printf. 46 as_echo='\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\' 47 as_echo=$as_echo$as_echo$as_echo$as_echo$as_echo 48 as_echo=$as_echo$as_echo$as_echo$as_echo$as_echo$as_echo 49 # Prefer a ksh shell builtin over an external printf program on Solaris, 50 # but without wasting forks for bash or zsh. 51 if test -z "$BASH_VERSION$ZSH_VERSION" \ 52 && (test "X`print -r -- $as_echo`" = "X$as_echo") 2>/dev/null; then 53 as_echo='print -r --' 54 as_echo_n='print -rn --' 55 elif (test "X`printf %s $as_echo`" = "X$as_echo") 2>/dev/null; then 56 as_echo='printf %s\n' 57 as_echo_n='printf %s' 58 else 59 if test "X`(/usr/ucb/echo -n -n $as_echo) 2>/dev/null`" = "X-n $as_echo"; then 60 as_echo_body='eval /usr/ucb/echo -n "$1$as_nl"' 61 as_echo_n='/usr/ucb/echo -n' 62 else 63 as_echo_body='eval expr "X$1" : "X\\(.*\\)"' 64 as_echo_n_body='eval 65 arg=$1; 66 case $arg in #( 67 *"$as_nl"*) 68 expr "X$arg" : "X\\(.*\\)$as_nl"; 69 arg=`expr "X$arg" : ".*$as_nl\\(.*\\)"`;; 70 esac; 71 expr "X$arg" : "X\\(.*\\)" | tr -d "$as_nl" 72 ' 73 export as_echo_n_body 74 as_echo_n='sh -c $as_echo_n_body as_echo' 75 fi 76 export as_echo_body 77 as_echo='sh -c $as_echo_body as_echo' 78 fi 79 80 # The user is always right. 81 if test "${PATH_SEPARATOR+set}" != set; then 82 PATH_SEPARATOR=: 83 (PATH='/bin;/bin'; FPATH=$PATH; sh -c :) >/dev/null 2>&1 && { 84 (PATH='/bin:/bin'; FPATH=$PATH; sh -c :) >/dev/null 2>&1 || 85 PATH_SEPARATOR=';' 86 } 87 fi 88 89 90 # IFS 91 # We need space, tab and new line, in precisely that order. Quoting is 92 # there to prevent editors from complaining about space-tab. 93 # (If _AS_PATH_WALK were called with IFS unset, it would disable word 94 # splitting by setting IFS to empty value.) 95 IFS=" "" $as_nl" 96 97 # Find who we are. Look in the path if we contain no directory separator. 98 as_myself= 99 case $0 in #(( 100 *[\\/]* ) as_myself=$0 ;; 101 *) as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 102 for as_dir in $PATH 103 do 104 IFS=$as_save_IFS 105 test -z "$as_dir" && as_dir=. 106 test -r "$as_dir/$0" && as_myself=$as_dir/$0 && break 107 done 108 IFS=$as_save_IFS 109 110 ;; 111 esac 112 # We did not find ourselves, most probably we were run as `sh COMMAND' 113 # in which case we are not to be found in the path. 114 if test "x$as_myself" = x; then 115 as_myself=$0 116 fi 117 if test ! -f "$as_myself"; then 118 $as_echo "$as_myself: error: cannot find myself; rerun with an absolute file name" >&2 119 exit 1 120 fi 121 122 # Unset variables that we do not need and which cause bugs (e.g. in 123 # pre-3.0 UWIN ksh). But do not cause bugs in bash 2.01; the "|| exit 1" 124 # suppresses any "Segmentation fault" message there. '((' could 125 # trigger a bug in pdksh 5.2.14. 126 for as_var in BASH_ENV ENV MAIL MAILPATH 127 do eval test x\${$as_var+set} = xset \ 128 && ( (unset $as_var) || exit 1) >/dev/null 2>&1 && unset $as_var || : 129 done 130 PS1='$ ' 131 PS2='> ' 132 PS4='+ ' 133 134 # NLS nuisances. 135 LC_ALL=C 136 export LC_ALL 137 LANGUAGE=C 138 export LANGUAGE 139 140 # CDPATH. 141 (unset CDPATH) >/dev/null 2>&1 && unset CDPATH 142 143 # Use a proper internal environment variable to ensure we don't fall 144 # into an infinite loop, continuously re-executing ourselves. 145 if test x"${_as_can_reexec}" != xno && test "x$CONFIG_SHELL" != x; then 146 _as_can_reexec=no; export _as_can_reexec; 147 # We cannot yet assume a decent shell, so we have to provide a 148 # neutralization value for shells without unset; and this also 149 # works around shells that cannot unset nonexistent variables. 150 # Preserve -v and -x to the replacement shell. 151 BASH_ENV=/dev/null 152 ENV=/dev/null 153 (unset BASH_ENV) >/dev/null 2>&1 && unset BASH_ENV ENV 154 case $- in # (((( 155 *v*x* | *x*v* ) as_opts=-vx ;; 156 *v* ) as_opts=-v ;; 157 *x* ) as_opts=-x ;; 158 * ) as_opts= ;; 159 esac 160 exec $CONFIG_SHELL $as_opts "$as_myself" ${1+"$@"} 161 # Admittedly, this is quite paranoid, since all the known shells bail 162 # out after a failed `exec'. 163 $as_echo "$0: could not re-execute with $CONFIG_SHELL" >&2 164 as_fn_exit 255 165 fi 166 # We don't want this to propagate to other subprocesses. 167 { _as_can_reexec=; unset _as_can_reexec;} 168 if test "x$CONFIG_SHELL" = x; then 169 as_bourne_compatible="if test -n \"\${ZSH_VERSION+set}\" && (emulate sh) >/dev/null 2>&1; then : 170 emulate sh 171 NULLCMD=: 172 # Pre-4.2 versions of Zsh do word splitting on \${1+\"\$@\"}, which 173 # is contrary to our usage. Disable this feature. 174 alias -g '\${1+\"\$@\"}'='\"\$@\"' 175 setopt NO_GLOB_SUBST 176 else 177 case \`(set -o) 2>/dev/null\` in #( 178 *posix*) : 179 set -o posix ;; #( 180 *) : 181 ;; 182 esac 183 fi 184 " 185 as_required="as_fn_return () { (exit \$1); } 186 as_fn_success () { as_fn_return 0; } 187 as_fn_failure () { as_fn_return 1; } 188 as_fn_ret_success () { return 0; } 189 as_fn_ret_failure () { return 1; } 190 191 exitcode=0 192 as_fn_success || { exitcode=1; echo as_fn_success failed.; } 193 as_fn_failure && { exitcode=1; echo as_fn_failure succeeded.; } 194 as_fn_ret_success || { exitcode=1; echo as_fn_ret_success failed.; } 195 as_fn_ret_failure && { exitcode=1; echo as_fn_ret_failure succeeded.; } 196 if ( set x; as_fn_ret_success y && test x = \"\$1\" ); then : 197 198 else 199 exitcode=1; echo positional parameters were not saved. 200 fi 201 test x\$exitcode = x0 || exit 1 202 test -x / || exit 1" 203 as_suggested=" as_lineno_1=";as_suggested=$as_suggested$LINENO;as_suggested=$as_suggested" as_lineno_1a=\$LINENO 204 as_lineno_2=";as_suggested=$as_suggested$LINENO;as_suggested=$as_suggested" as_lineno_2a=\$LINENO 205 eval 'test \"x\$as_lineno_1'\$as_run'\" != \"x\$as_lineno_2'\$as_run'\" && 206 test \"x\`expr \$as_lineno_1'\$as_run' + 1\`\" = \"x\$as_lineno_2'\$as_run'\"' || exit 1 207 test \$(( 1 + 1 )) = 2 || exit 1" 208 if (eval "$as_required") 2>/dev/null; then : 209 as_have_required=yes 210 else 211 as_have_required=no 212 fi 213 if test x$as_have_required = xyes && (eval "$as_suggested") 2>/dev/null; then : 214 215 else 216 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 217 as_found=false 218 for as_dir in /bin$PATH_SEPARATOR/usr/bin$PATH_SEPARATOR$PATH 219 do 220 IFS=$as_save_IFS 221 test -z "$as_dir" && as_dir=. 222 as_found=: 223 case $as_dir in #( 224 /*) 225 for as_base in sh bash ksh sh5; do 226 # Try only shells that exist, to save several forks. 227 as_shell=$as_dir/$as_base 228 if { test -f "$as_shell" || test -f "$as_shell.exe"; } && 229 { $as_echo "$as_bourne_compatible""$as_required" | as_run=a "$as_shell"; } 2>/dev/null; then : 230 CONFIG_SHELL=$as_shell as_have_required=yes 231 if { $as_echo "$as_bourne_compatible""$as_suggested" | as_run=a "$as_shell"; } 2>/dev/null; then : 232 break 2 233 fi 234 fi 235 done;; 236 esac 237 as_found=false 238 done 239 $as_found || { if { test -f "$SHELL" || test -f "$SHELL.exe"; } && 240 { $as_echo "$as_bourne_compatible""$as_required" | as_run=a "$SHELL"; } 2>/dev/null; then : 241 CONFIG_SHELL=$SHELL as_have_required=yes 242 fi; } 243 IFS=$as_save_IFS 244 245 246 if test "x$CONFIG_SHELL" != x; then : 247 export CONFIG_SHELL 248 # We cannot yet assume a decent shell, so we have to provide a 249 # neutralization value for shells without unset; and this also 250 # works around shells that cannot unset nonexistent variables. 251 # Preserve -v and -x to the replacement shell. 252 BASH_ENV=/dev/null 253 ENV=/dev/null 254 (unset BASH_ENV) >/dev/null 2>&1 && unset BASH_ENV ENV 255 case $- in # (((( 256 *v*x* | *x*v* ) as_opts=-vx ;; 257 *v* ) as_opts=-v ;; 258 *x* ) as_opts=-x ;; 259 * ) as_opts= ;; 260 esac 261 exec $CONFIG_SHELL $as_opts "$as_myself" ${1+"$@"} 262 # Admittedly, this is quite paranoid, since all the known shells bail 263 # out after a failed `exec'. 264 $as_echo "$0: could not re-execute with $CONFIG_SHELL" >&2 265 exit 255 266 fi 267 268 if test x$as_have_required = xno; then : 269 $as_echo "$0: This script requires a shell more modern than all" 270 $as_echo "$0: the shells that I found on your system." 271 if test x${ZSH_VERSION+set} = xset ; then 272 $as_echo "$0: In particular, zsh $ZSH_VERSION has bugs and should" 273 $as_echo "$0: be upgraded to zsh 4.3.4 or later." 274 else 275 $as_echo "$0: Please tell bug-autoconf@gnu.org and 276 $0: build-dev@openjdk.java.net about your system, including 277 $0: any error possibly output before this message. Then 278 $0: install a modern shell, or manually run the script 279 $0: under such a shell if you do have one." 280 fi 281 exit 1 282 fi 283 fi 284 fi 285 SHELL=${CONFIG_SHELL-/bin/sh} 286 export SHELL 287 # Unset more variables known to interfere with behavior of common tools. 288 CLICOLOR_FORCE= GREP_OPTIONS= 289 unset CLICOLOR_FORCE GREP_OPTIONS 290 291 ## --------------------- ## 292 ## M4sh Shell Functions. ## 293 ## --------------------- ## 294 # as_fn_unset VAR 295 # --------------- 296 # Portably unset VAR. 297 as_fn_unset () 298 { 299 { eval $1=; unset $1;} 300 } 301 as_unset=as_fn_unset 302 303 # as_fn_set_status STATUS 304 # ----------------------- 305 # Set $? to STATUS, without forking. 306 as_fn_set_status () 307 { 308 return $1 309 } # as_fn_set_status 310 311 # as_fn_exit STATUS 312 # ----------------- 313 # Exit the shell with STATUS, even in a "trap 0" or "set -e" context. 314 as_fn_exit () 315 { 316 set +e 317 as_fn_set_status $1 318 exit $1 319 } # as_fn_exit 320 321 # as_fn_mkdir_p 322 # ------------- 323 # Create "$as_dir" as a directory, including parents if necessary. 324 as_fn_mkdir_p () 325 { 326 327 case $as_dir in #( 328 -*) as_dir=./$as_dir;; 329 esac 330 test -d "$as_dir" || eval $as_mkdir_p || { 331 as_dirs= 332 while :; do 333 case $as_dir in #( 334 *\'*) as_qdir=`$as_echo "$as_dir" | sed "s/'/'\\\\\\\\''/g"`;; #'( 335 *) as_qdir=$as_dir;; 336 esac 337 as_dirs="'$as_qdir' $as_dirs" 338 as_dir=`$as_dirname -- "$as_dir" || 339 $as_expr X"$as_dir" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \ 340 X"$as_dir" : 'X\(//\)[^/]' \| \ 341 X"$as_dir" : 'X\(//\)$' \| \ 342 X"$as_dir" : 'X\(/\)' \| . 2>/dev/null || 343 $as_echo X"$as_dir" | 344 sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{ 345 s//\1/ 346 q 347 } 348 /^X\(\/\/\)[^/].*/{ 349 s//\1/ 350 q 351 } 352 /^X\(\/\/\)$/{ 353 s//\1/ 354 q 355 } 356 /^X\(\/\).*/{ 357 s//\1/ 358 q 359 } 360 s/.*/./; q'` 361 test -d "$as_dir" && break 362 done 363 test -z "$as_dirs" || eval "mkdir $as_dirs" 364 } || test -d "$as_dir" || as_fn_error $? "cannot create directory $as_dir" 365 366 367 } # as_fn_mkdir_p 368 369 # as_fn_executable_p FILE 370 # ----------------------- 371 # Test if FILE is an executable regular file. 372 as_fn_executable_p () 373 { 374 test -f "$1" && test -x "$1" 375 } # as_fn_executable_p 376 # as_fn_append VAR VALUE 377 # ---------------------- 378 # Append the text in VALUE to the end of the definition contained in VAR. Take 379 # advantage of any shell optimizations that allow amortized linear growth over 380 # repeated appends, instead of the typical quadratic growth present in naive 381 # implementations. 382 if (eval "as_var=1; as_var+=2; test x\$as_var = x12") 2>/dev/null; then : 383 eval 'as_fn_append () 384 { 385 eval $1+=\$2 386 }' 387 else 388 as_fn_append () 389 { 390 eval $1=\$$1\$2 391 } 392 fi # as_fn_append 393 394 # as_fn_arith ARG... 395 # ------------------ 396 # Perform arithmetic evaluation on the ARGs, and store the result in the 397 # global $as_val. Take advantage of shells that can avoid forks. The arguments 398 # must be portable across $(()) and expr. 399 if (eval "test \$(( 1 + 1 )) = 2") 2>/dev/null; then : 400 eval 'as_fn_arith () 401 { 402 as_val=$(( $* )) 403 }' 404 else 405 as_fn_arith () 406 { 407 as_val=`expr "$@" || test $? -eq 1` 408 } 409 fi # as_fn_arith 410 411 412 # as_fn_error STATUS ERROR [LINENO LOG_FD] 413 # ---------------------------------------- 414 # Output "`basename $0`: error: ERROR" to stderr. If LINENO and LOG_FD are 415 # provided, also output the error to LOG_FD, referencing LINENO. Then exit the 416 # script with STATUS, using 1 if that was 0. 417 as_fn_error () 418 { 419 as_status=$1; test $as_status -eq 0 && as_status=1 420 if test "$4"; then 421 as_lineno=${as_lineno-"$3"} as_lineno_stack=as_lineno_stack=$as_lineno_stack 422 $as_echo "$as_me:${as_lineno-$LINENO}: error: $2" >&$4 423 fi 424 $as_echo "$as_me: error: $2" >&2 425 as_fn_exit $as_status 426 } # as_fn_error 427 428 if expr a : '\(a\)' >/dev/null 2>&1 && 429 test "X`expr 00001 : '.*\(...\)'`" = X001; then 430 as_expr=expr 431 else 432 as_expr=false 433 fi 434 435 if (basename -- /) >/dev/null 2>&1 && test "X`basename -- / 2>&1`" = "X/"; then 436 as_basename=basename 437 else 438 as_basename=false 439 fi 440 441 if (as_dir=`dirname -- /` && test "X$as_dir" = X/) >/dev/null 2>&1; then 442 as_dirname=dirname 443 else 444 as_dirname=false 445 fi 446 447 as_me=`$as_basename -- "$0" || 448 $as_expr X/"$0" : '.*/\([^/][^/]*\)/*$' \| \ 449 X"$0" : 'X\(//\)$' \| \ 450 X"$0" : 'X\(/\)' \| . 2>/dev/null || 451 $as_echo X/"$0" | 452 sed '/^.*\/\([^/][^/]*\)\/*$/{ 453 s//\1/ 454 q 455 } 456 /^X\/\(\/\/\)$/{ 457 s//\1/ 458 q 459 } 460 /^X\/\(\/\).*/{ 461 s//\1/ 462 q 463 } 464 s/.*/./; q'` 465 466 # Avoid depending upon Character Ranges. 467 as_cr_letters='abcdefghijklmnopqrstuvwxyz' 468 as_cr_LETTERS='ABCDEFGHIJKLMNOPQRSTUVWXYZ' 469 as_cr_Letters=$as_cr_letters$as_cr_LETTERS 470 as_cr_digits='0123456789' 471 as_cr_alnum=$as_cr_Letters$as_cr_digits 472 473 474 as_lineno_1=$LINENO as_lineno_1a=$LINENO 475 as_lineno_2=$LINENO as_lineno_2a=$LINENO 476 eval 'test "x$as_lineno_1'$as_run'" != "x$as_lineno_2'$as_run'" && 477 test "x`expr $as_lineno_1'$as_run' + 1`" = "x$as_lineno_2'$as_run'"' || { 478 # Blame Lee E. McMahon (1931-1989) for sed's syntax. :-) 479 sed -n ' 480 p 481 /[$]LINENO/= 482 ' <$as_myself | 483 sed ' 484 s/[$]LINENO.*/&-/ 485 t lineno 486 b 487 :lineno 488 N 489 :loop 490 s/[$]LINENO\([^'$as_cr_alnum'_].*\n\)\(.*\)/\2\1\2/ 491 t loop 492 s/-\n.*// 493 ' >$as_me.lineno && 494 chmod +x "$as_me.lineno" || 495 { $as_echo "$as_me: error: cannot create $as_me.lineno; rerun with a POSIX shell" >&2; as_fn_exit 1; } 496 497 # If we had to re-execute with $CONFIG_SHELL, we're ensured to have 498 # already done that, so ensure we don't try to do so again and fall 499 # in an infinite loop. This has already happened in practice. 500 _as_can_reexec=no; export _as_can_reexec 501 # Don't try to exec as it changes $[0], causing all sort of problems 502 # (the dirname of $[0] is not the place where we might find the 503 # original and so on. Autoconf is especially sensitive to this). 504 . "./$as_me.lineno" 505 # Exit status is that of the last command. 506 exit 507 } 508 509 ECHO_C= ECHO_N= ECHO_T= 510 case `echo -n x` in #((((( 511 -n*) 512 case `echo 'xy\c'` in 513 *c*) ECHO_T=' ';; # ECHO_T is single tab character. 514 xy) ECHO_C='\c';; 515 *) echo `echo ksh88 bug on AIX 6.1` > /dev/null 516 ECHO_T=' ';; 517 esac;; 518 *) 519 ECHO_N='-n';; 520 esac 521 522 rm -f conf$$ conf$$.exe conf$$.file 523 if test -d conf$$.dir; then 524 rm -f conf$$.dir/conf$$.file 525 else 526 rm -f conf$$.dir 527 mkdir conf$$.dir 2>/dev/null 528 fi 529 if (echo >conf$$.file) 2>/dev/null; then 530 if ln -s conf$$.file conf$$ 2>/dev/null; then 531 as_ln_s='ln -s' 532 # ... but there are two gotchas: 533 # 1) On MSYS, both `ln -s file dir' and `ln file dir' fail. 534 # 2) DJGPP < 2.04 has no symlinks; `ln -s' creates a wrapper executable. 535 # In both cases, we have to default to `cp -pR'. 536 ln -s conf$$.file conf$$.dir 2>/dev/null && test ! -f conf$$.exe || 537 as_ln_s='cp -pR' 538 elif ln conf$$.file conf$$ 2>/dev/null; then 539 as_ln_s=ln 540 else 541 as_ln_s='cp -pR' 542 fi 543 else 544 as_ln_s='cp -pR' 545 fi 546 rm -f conf$$ conf$$.exe conf$$.dir/conf$$.file conf$$.file 547 rmdir conf$$.dir 2>/dev/null 548 549 if mkdir -p . 2>/dev/null; then 550 as_mkdir_p='mkdir -p "$as_dir"' 551 else 552 test -d ./-p && rmdir ./-p 553 as_mkdir_p=false 554 fi 555 556 as_test_x='test -x' 557 as_executable_p=as_fn_executable_p 558 559 # Sed expression to map a string onto a valid CPP name. 560 as_tr_cpp="eval sed 'y%*$as_cr_letters%P$as_cr_LETTERS%;s%[^_$as_cr_alnum]%_%g'" 561 562 # Sed expression to map a string onto a valid variable name. 563 as_tr_sh="eval sed 'y%*+%pp%;s%[^_$as_cr_alnum]%_%g'" 564 565 566 test -n "$DJDIR" || exec 7<&0 </dev/null 567 exec 6>&1 568 569 # Name of the host. 570 # hostname on some systems (SVR3.2, old GNU/Linux) returns a bogus exit status, 571 # so uname gets run too. 572 ac_hostname=`(hostname || uname -n) 2>/dev/null | sed 1q` 573 574 # 575 # Initializations. 576 # 577 ac_default_prefix=/usr/local 578 ac_clean_files= 579 ac_config_libobj_dir=. 580 LIBOBJS= 581 cross_compiling=no 582 subdirs= 583 MFLAGS= 584 MAKEFLAGS= 585 586 # Identity of this package. 587 PACKAGE_NAME='OpenJDK' 588 PACKAGE_TARNAME='openjdk' 589 PACKAGE_VERSION='jdk9' 590 PACKAGE_STRING='OpenJDK jdk9' 591 PACKAGE_BUGREPORT='build-dev@openjdk.java.net' 592 PACKAGE_URL='http://openjdk.java.net' 593 594 # Factoring default headers for most tests. 595 ac_includes_default="\ 596 #include <stdio.h> 597 #ifdef HAVE_SYS_TYPES_H 598 # include <sys/types.h> 599 #endif 600 #ifdef HAVE_SYS_STAT_H 601 # include <sys/stat.h> 602 #endif 603 #ifdef STDC_HEADERS 604 # include <stdlib.h> 605 # include <stddef.h> 606 #else 607 # ifdef HAVE_STDLIB_H 608 # include <stdlib.h> 609 # endif 610 #endif 611 #ifdef HAVE_STRING_H 612 # if !defined STDC_HEADERS && defined HAVE_MEMORY_H 613 # include <memory.h> 614 # endif 615 # include <string.h> 616 #endif 617 #ifdef HAVE_STRINGS_H 618 # include <strings.h> 619 #endif 620 #ifdef HAVE_INTTYPES_H 621 # include <inttypes.h> 622 #endif 623 #ifdef HAVE_STDINT_H 624 # include <stdint.h> 625 #endif 626 #ifdef HAVE_UNISTD_H 627 # include <unistd.h> 628 #endif" 629 630 ac_subst_vars='LTLIBOBJS 631 LIBOBJS 632 CFLAGS_CCACHE 633 CCACHE 634 USE_PRECOMPILED_HEADER 635 BUILD_ICECC 636 ICECC 637 ICECC_WRAPPER 638 ICECC_CREATE_ENV 639 ICECC_CMD 640 ENABLE_JAVAC_SERVER 641 ENABLE_SJAVAC 642 SJAVAC_SERVER_JAVA_FLAGS 643 SJAVAC_SERVER_JAVA 644 JAVA_TOOL_FLAGS_SMALL 645 JAVA_FLAGS_SMALL 646 JAVA_FLAGS_JAVAC 647 BOOTCYCLE_JVM_ARGS_BIG 648 JAVA_FLAGS_BIG 649 JAVA_FLAGS 650 TEST_JOBS 651 JOBS 652 MEMORY_SIZE 653 NUM_CORES 654 ENABLE_GENERATE_CLASSLIST 655 BUILD_FAILURE_HANDLER 656 ENABLE_INTREE_EC 657 VALID_JVM_FEATURES 658 JVM_FEATURES_custom 659 JVM_FEATURES_zero 660 JVM_FEATURES_minimal 661 JVM_FEATURES_core 662 JVM_FEATURES_client 663 JVM_FEATURES_server 664 INCLUDE_GRAAL 665 STLPORT_LIB 666 LIBZIP_CAN_USE_MMAP 667 LIBDL 668 LIBM 669 USE_EXTERNAL_LCMS 670 LCMS_LIBS 671 LCMS_CFLAGS 672 USE_EXTERNAL_LIBZ 673 USE_EXTERNAL_LIBPNG 674 PNG_LIBS 675 PNG_CFLAGS 676 USE_EXTERNAL_LIBGIF 677 USE_EXTERNAL_LIBJPEG 678 LIBFFI_LIB_FILE 679 ENABLE_LIBFFI_BUNDLING 680 LIBFFI_LIBS 681 LIBFFI_CFLAGS 682 ALSA_LIBS 683 ALSA_CFLAGS 684 FREETYPE_LICENSE 685 FREETYPE_BUNDLE_LIB_PATH 686 FREETYPE_LIBS 687 FREETYPE_CFLAGS 688 FONTCONFIG_CFLAGS 689 CUPS_CFLAGS 690 X_EXTRA_LIBS 691 X_LIBS 692 X_PRE_LIBS 693 X_CFLAGS 694 XMKMF 695 MSVCP_DLL 696 MSVCR_DLL 697 LIBCXX 698 FIXPATH_DETACH_FLAG 699 FIXPATH 700 BUILD_GTEST 701 ENABLE_CDS 702 ENABLE_AOT 703 ASAN_ENABLED 704 GCOV_ENABLED 705 ZIP_EXTERNAL_DEBUG_SYMBOLS 706 COPY_DEBUG_SYMBOLS 707 COMPILE_WITH_DEBUG_SYMBOLS 708 CFLAGS_WARNINGS_ARE_ERRORS 709 BUILD_CC_DISABLE_WARNING_PREFIX 710 DISABLE_WARNING_PREFIX 711 WARNINGS_AS_ERRORS 712 COMPILER_SUPPORTS_TARGET_BITS_FLAG 713 LDFLAGS_TESTEXE 714 LDFLAGS_TESTLIB 715 CXXFLAGS_TESTEXE 716 CXXFLAGS_TESTLIB 717 CFLAGS_TESTEXE 718 CFLAGS_TESTLIB 719 OPENJDK_BUILD_JVM_LIBS 720 OPENJDK_BUILD_JVM_ASFLAGS 721 OPENJDK_BUILD_JVM_LDFLAGS 722 OPENJDK_BUILD_JVM_CFLAGS 723 OPENJDK_BUILD_LDFLAGS_NO_EXEC_STACK 724 OPENJDK_BUILD_LDFLAGS_HASH_STYLE 725 OPENJDK_BUILD_LDFLAGS_CXX_JDK 726 OPENJDK_BUILD_JDKEXE_LIBS 727 OPENJDK_BUILD_JDKLIB_LIBS 728 OPENJDK_BUILD_LDFLAGS_JDKEXE 729 OPENJDK_BUILD_LDFLAGS_JDKLIB 730 OPENJDK_BUILD_CXXFLAGS_JDKEXE 731 OPENJDK_BUILD_CXXFLAGS_JDKLIB 732 OPENJDK_BUILD_CFLAGS_JDKEXE 733 OPENJDK_BUILD_CFLAGS_JDKLIB 734 OPENJDK_BUILD_CXXSTD_CXXFLAG 735 JVM_LIBS 736 JVM_ASFLAGS 737 JVM_LDFLAGS 738 JVM_CFLAGS 739 LDFLAGS_NO_EXEC_STACK 740 LDFLAGS_HASH_STYLE 741 LDFLAGS_CXX_JDK 742 JDKEXE_LIBS 743 JDKLIB_LIBS 744 LDFLAGS_JDKEXE 745 LDFLAGS_JDKLIB 746 CXXFLAGS_JDKEXE 747 CXXFLAGS_JDKLIB 748 CFLAGS_JDKEXE 749 CFLAGS_JDKLIB 750 MACOSX_VERSION_MAX 751 MACOSX_VERSION_MIN 752 CXXSTD_CXXFLAG 753 JDK_ARCH_ABI_PROP_NAME 754 CXX_O_FLAG_SIZE 755 CXX_O_FLAG_NONE 756 CXX_O_FLAG_DEBUG 757 CXX_O_FLAG_NORM 758 CXX_O_FLAG_HI 759 CXX_O_FLAG_HIGHEST 760 CXX_O_FLAG_HIGHEST_JVM 761 C_O_FLAG_SIZE 762 C_O_FLAG_NONE 763 C_O_FLAG_DEBUG 764 C_O_FLAG_NORM 765 C_O_FLAG_HI 766 C_O_FLAG_HIGHEST 767 C_O_FLAG_HIGHEST_JVM 768 JVM_CFLAGS_SYMBOLS 769 CXXFLAGS_DEBUG_SYMBOLS 770 CFLAGS_DEBUG_SYMBOLS 771 CXX_FLAG_DEPS 772 C_FLAG_DEPS 773 SHARED_LIBRARY_FLAGS 774 SET_SHARED_LIBRARY_MAPFILE 775 SET_SHARED_LIBRARY_NAME 776 SET_SHARED_LIBRARY_ORIGIN 777 SET_EXECUTABLE_ORIGIN 778 CXX_FLAG_REORDER 779 C_FLAG_REORDER 780 JVM_RCFLAGS 781 RC_FLAGS 782 AR_OUT_OPTION 783 LD_OUT_OPTION 784 EXE_OUT_OPTION 785 CC_OUT_OPTION 786 STRIPFLAGS 787 ARFLAGS 788 COMPILER_BINDCMD_FILE_FLAG 789 COMPILER_COMMAND_FILE_FLAG 790 COMPILER_TARGET_BITS_FLAG 791 JIB_JAR 792 JT_HOME 793 JTREGEXE 794 HOTSPOT_TOOLCHAIN_TYPE 795 USING_BROKEN_SUSE_LD 796 PACKAGE_PATH 797 BUILD_AS 798 BUILD_LDCXX 799 BUILD_LD 800 BUILD_STRIP 801 BUILD_OBJCOPY 802 BUILD_AR 803 BUILD_NM 804 BUILD_CXX 805 BUILD_CC 806 BUILD_SYSROOT_LDFLAGS 807 BUILD_SYSROOT_CFLAGS 808 ac_ct_OBJDUMP 809 OBJDUMP 810 ac_ct_OBJCOPY 811 OBJCOPY 812 ac_ct_NM 813 ac_ct_STRIP 814 GNM 815 NM 816 STRIP 817 MSBUILD 818 DUMPBIN 819 RC 820 MT 821 INSTALL_NAME_TOOL 822 OTOOL 823 LIPO 824 ac_ct_AR 825 AR 826 AS 827 LDCXX 828 LD 829 CXXCPP 830 CPP 831 CXX_VERSION_NUMBER 832 CC_VERSION_NUMBER 833 ac_ct_CXX 834 CXXFLAGS 835 CXX 836 TOOLCHAIN_PATH_CXX 837 POTENTIAL_CXX 838 OBJEXT 839 EXEEXT 840 ac_ct_CC 841 CPPFLAGS 842 LDFLAGS 843 CFLAGS 844 CC 845 TOOLCHAIN_PATH_CC 846 POTENTIAL_CC 847 TOOLCHAIN_VERSION 848 VS_LIB 849 VS_INCLUDE 850 VS_PATH 851 CYGWIN_LINK 852 SYSROOT_LDFLAGS 853 SYSROOT_CFLAGS 854 EXTRA_LDFLAGS 855 EXTRA_CXXFLAGS 856 EXTRA_CFLAGS 857 EXE_SUFFIX 858 OBJ_SUFFIX 859 STATIC_LIBRARY 860 SHARED_LIBRARY 861 STATIC_LIBRARY_SUFFIX 862 SHARED_LIBRARY_SUFFIX 863 LIBRARY_PREFIX 864 TOOLCHAIN_TYPE 865 STATIC_BUILD 866 IMPORT_MODULES_MAKE 867 IMPORT_MODULES_SRC 868 IMPORT_MODULES_MAN 869 IMPORT_MODULES_LEGAL 870 IMPORT_MODULES_CONF 871 IMPORT_MODULES_LIBS 872 IMPORT_MODULES_CMDS 873 IMPORT_MODULES_CLASSES 874 EXTERNAL_BUILDJDK 875 BUILD_JDK 876 CREATE_BUILDJDK 877 JLINK 878 JMOD 879 JAVAC_FLAGS 880 BOOT_JDK_SOURCETARGET 881 JARSIGNER 882 JAR 883 JAVADOC 884 JAVAH 885 JAVAC 886 JAVA 887 BOOT_JDK 888 JAVA_CHECK 889 JAVAC_CHECK 890 VERSION_CLASSFILE_MINOR 891 VERSION_CLASSFILE_MAJOR 892 VENDOR_VERSION_STRING 893 VERSION_DATE 894 VERSION_IS_GA 895 VERSION_SHORT 896 VERSION_STRING 897 VERSION_NUMBER_FOUR_POSITIONS 898 VERSION_NUMBER 899 VERSION_OPT 900 VERSION_BUILD 901 VERSION_PRE 902 VERSION_PATCH 903 VERSION_UPDATE 904 VERSION_INTERIM 905 VERSION_FEATURE 906 MACOSX_BUNDLE_ID_BASE 907 MACOSX_BUNDLE_NAME_BASE 908 HOTSPOT_VM_DISTRO 909 COMPANY_NAME 910 JDK_RC_PLATFORM_NAME 911 PRODUCT_SUFFIX 912 PRODUCT_NAME 913 LAUNCHER_NAME 914 JLINK_KEEP_PACKAGED_MODULES 915 COPYRIGHT_YEAR 916 COMPRESS_JARS 917 INCLUDE_SA 918 UNLIMITED_CRYPTO 919 CACERTS_FILE 920 ENABLE_FULL_DOCS 921 ENABLE_HEADLESS_ONLY 922 DEFAULT_MAKE_TARGET 923 OS_VERSION_MICRO 924 OS_VERSION_MINOR 925 OS_VERSION_MAJOR 926 PKG_CONFIG 927 BASH_ARGS 928 SETFILE 929 CODESIGN 930 XATTR 931 DSYMUTIL 932 IS_GNU_TIME 933 PATCH 934 DTRACE 935 FLOCK 936 TIME 937 STAT 938 HG 939 DOT 940 READELF 941 LDD 942 ZIPEXE 943 UNZIP 944 TAR_SUPPORTS_TRANSFORM 945 TAR_INCLUDE_PARAM 946 TAR_CREATE_EXTRA_PARAM 947 TAR_TYPE 948 FIND_DELETE 949 OUTPUT_SYNC 950 OUTPUT_SYNC_SUPPORTED 951 CHECK_TOOLSDIR_MAKE 952 CHECK_TOOLSDIR_GMAKE 953 CHECK_MAKE 954 CHECK_GMAKE 955 MAKE 956 PKGHANDLER 957 CONFIGURESUPPORT_OUTPUTDIR 958 OUTPUTDIR 959 CONF_NAME 960 SPEC 961 SDKROOT 962 XCODEBUILD 963 DEVKIT_LIB_DIR 964 JVM_VARIANT_MAIN 965 VALID_JVM_VARIANTS 966 JVM_VARIANTS 967 DEBUG_LEVEL 968 HOTSPOT_DEBUG_LEVEL 969 JDK_VARIANT 970 USERNAME 971 TOPDIR 972 PATH_SEP 973 OPENJDK_BUILD_OS_INCLUDE_SUBDIR 974 HOTSPOT_BUILD_CPU_DEFINE 975 HOTSPOT_BUILD_CPU_ARCH 976 HOTSPOT_BUILD_CPU 977 HOTSPOT_BUILD_OS_TYPE 978 HOTSPOT_BUILD_OS 979 OPENJDK_BUILD_BUNDLE_PLATFORM 980 OPENJDK_BUILD_CPU_OSARCH 981 OPENJDK_BUILD_CPU_ISADIR 982 OPENJDK_BUILD_CPU_LEGACY_LIB 983 OPENJDK_BUILD_CPU_LEGACY 984 OPENJDK_TARGET_OS_INCLUDE_SUBDIR 985 HOTSPOT_TARGET_CPU_DEFINE 986 HOTSPOT_TARGET_CPU_ARCH 987 HOTSPOT_TARGET_CPU 988 HOTSPOT_TARGET_OS_TYPE 989 HOTSPOT_TARGET_OS 990 DEFINE_CROSS_COMPILE_ARCH 991 OPENJDK_TARGET_BUNDLE_PLATFORM 992 OPENJDK_TARGET_CPU_OSARCH 993 OPENJDK_TARGET_CPU_ISADIR 994 OPENJDK_TARGET_CPU_LEGACY_LIB 995 OPENJDK_TARGET_CPU_LEGACY 996 RELEASE_FILE_OS_ARCH 997 RELEASE_FILE_OS_NAME 998 OPENJDK_MODULE_TARGET_PLATFORM 999 COMPILE_TYPE 1000 OPENJDK_TARGET_CPU_ENDIAN 1001 OPENJDK_TARGET_CPU_BITS 1002 OPENJDK_TARGET_CPU_ARCH 1003 OPENJDK_TARGET_CPU 1004 OPENJDK_TARGET_OS_ENV 1005 OPENJDK_TARGET_OS_TYPE 1006 OPENJDK_TARGET_OS 1007 OPENJDK_BUILD_CPU_ENDIAN 1008 OPENJDK_BUILD_CPU_BITS 1009 OPENJDK_BUILD_CPU_ARCH 1010 OPENJDK_BUILD_CPU 1011 OPENJDK_BUILD_OS_ENV 1012 OPENJDK_BUILD_OS_TYPE 1013 OPENJDK_BUILD_OS 1014 OPENJDK_BUILD_AUTOCONF_NAME 1015 OPENJDK_TARGET_AUTOCONF_NAME 1016 target_os 1017 target_vendor 1018 target_cpu 1019 target 1020 host_os 1021 host_vendor 1022 host_cpu 1023 host 1024 build_os 1025 build_vendor 1026 build_cpu 1027 build 1028 PANDOC 1029 NICE 1030 CPIO 1031 DF 1032 READLINK 1033 CYGPATH 1034 SED 1035 FGREP 1036 EGREP 1037 GREP 1038 AWK 1039 XARGS 1040 WHICH 1041 WC 1042 UNIQ 1043 UNAME 1044 TR 1045 TOUCH 1046 TEE 1047 TAR 1048 TAIL 1049 SORT 1050 SH 1051 RMDIR 1052 RM 1053 PRINTF 1054 NAWK 1055 MV 1056 MKTEMP 1057 MKDIR 1058 LS 1059 LN 1060 GZIP 1061 GUNZIP 1062 HEAD 1063 FIND 1064 FILE 1065 EXPR 1066 ECHO 1067 DIRNAME 1068 DIFF 1069 DATE 1070 CUT 1071 CP 1072 COMM 1073 CMP 1074 CHMOD 1075 CAT 1076 BASH 1077 BASENAME 1078 DATE_WHEN_CONFIGURED 1079 ORIGINAL_PATH 1080 CONFIGURE_COMMAND_LINE 1081 target_alias 1082 host_alias 1083 build_alias 1084 LIBS 1085 ECHO_T 1086 ECHO_N 1087 ECHO_C 1088 DEFS 1089 mandir 1090 localedir 1091 libdir 1092 psdir 1093 pdfdir 1094 dvidir 1095 htmldir 1096 infodir 1097 docdir 1098 oldincludedir 1099 includedir 1100 localstatedir 1101 sharedstatedir 1102 sysconfdir 1103 datadir 1104 datarootdir 1105 libexecdir 1106 sbindir 1107 bindir 1108 program_transform_name 1109 prefix 1110 exec_prefix 1111 PACKAGE_URL 1112 PACKAGE_BUGREPORT 1113 PACKAGE_STRING 1114 PACKAGE_VERSION 1115 PACKAGE_TARNAME 1116 PACKAGE_NAME 1117 PATH_SEPARATOR 1118 SHELL' 1119 ac_subst_files='' 1120 ac_user_opts=' 1121 enable_option_checking 1122 with_target_bits 1123 enable_openjdk_only 1124 with_custom_make_dir 1125 with_jdk_variant 1126 enable_debug 1127 with_debug_level 1128 with_jvm_variants 1129 with_cpu_port 1130 with_devkit 1131 with_sys_root 1132 with_sysroot 1133 with_tools_dir 1134 with_toolchain_path 1135 with_extra_path 1136 with_sdk_name 1137 with_conf_name 1138 with_output_sync 1139 with_default_make_target 1140 enable_headless_only 1141 enable_full_docs 1142 with_cacerts_file 1143 enable_unlimited_crypto 1144 with_copyright_year 1145 enable_keep_packaged_modules 1146 with_milestone 1147 with_update_version 1148 with_user_release_suffix 1149 with_build_number 1150 with_version_major 1151 with_version_minor 1152 with_version_security 1153 with_version_string 1154 with_version_pre 1155 with_version_opt 1156 with_version_build 1157 with_version_feature 1158 with_version_interim 1159 with_version_update 1160 with_version_patch 1161 with_version_date 1162 with_vendor_version_string 1163 with_boot_jdk 1164 with_build_jdk 1165 with_import_modules 1166 enable_static_build 1167 with_toolchain_type 1168 with_extra_cflags 1169 with_extra_cxxflags 1170 with_extra_ldflags 1171 with_toolchain_version 1172 with_build_devkit 1173 with_jtreg 1174 with_jib 1175 with_abi_profile 1176 with_macosx_version_max 1177 enable_warnings_as_errors 1178 with_native_debug_symbols 1179 enable_debug_symbols 1180 enable_zip_debug_info 1181 enable_native_coverage 1182 enable_asan 1183 enable_dtrace 1184 enable_aot 1185 enable_cds 1186 enable_hotspot_gtest 1187 with_stdc__lib 1188 with_msvcr_dll 1189 with_msvcp_dll 1190 with_x 1191 with_cups 1192 with_cups_include 1193 with_fontconfig 1194 with_fontconfig_include 1195 with_freetype 1196 with_freetype_include 1197 with_freetype_lib 1198 with_freetype_src 1199 enable_freetype_bundling 1200 with_freetype_license 1201 with_alsa 1202 with_alsa_include 1203 with_alsa_lib 1204 with_libffi 1205 with_libffi_include 1206 with_libffi_lib 1207 enable_libffi_bundling 1208 with_libjpeg 1209 with_giflib 1210 with_libpng 1211 with_zlib 1212 with_lcms 1213 with_dxsdk 1214 with_dxsdk_lib 1215 with_dxsdk_include 1216 with_jvm_features 1217 with_jvm_interpreter 1218 enable_jtreg_failure_handler 1219 enable_generate_classlist 1220 with_num_cores 1221 with_memory_size 1222 with_jobs 1223 with_test_jobs 1224 with_boot_jdk_jvmargs 1225 with_sjavac_server_java 1226 enable_sjavac 1227 enable_javac_server 1228 enable_icecc 1229 enable_precompiled_headers 1230 enable_ccache 1231 with_ccache_dir 1232 ' 1233 ac_precious_vars='build_alias 1234 host_alias 1235 target_alias 1236 BASENAME 1237 BASH 1238 CAT 1239 CHMOD 1240 CMP 1241 COMM 1242 CP 1243 CUT 1244 DATE 1245 DIFF 1246 DIRNAME 1247 ECHO 1248 EXPR 1249 FILE 1250 FIND 1251 HEAD 1252 GUNZIP 1253 GZIP 1254 LN 1255 LS 1256 MKDIR 1257 MKTEMP 1258 MV 1259 NAWK 1260 PRINTF 1261 RM 1262 RMDIR 1263 SH 1264 SORT 1265 TAIL 1266 TAR 1267 TEE 1268 TOUCH 1269 TR 1270 UNAME 1271 UNIQ 1272 WC 1273 WHICH 1274 XARGS 1275 AWK 1276 GREP 1277 EGREP 1278 FGREP 1279 SED 1280 CYGPATH 1281 READLINK 1282 DF 1283 CPIO 1284 NICE 1285 PANDOC 1286 MAKE 1287 UNZIP 1288 ZIPEXE 1289 LDD 1290 READELF 1291 DOT 1292 HG 1293 STAT 1294 TIME 1295 FLOCK 1296 DTRACE 1297 PATCH 1298 DSYMUTIL 1299 XATTR 1300 CODESIGN 1301 SETFILE 1302 PKG_CONFIG 1303 JAVA 1304 JAVAC 1305 JAVAH 1306 JAVADOC 1307 JAR 1308 JARSIGNER 1309 CC 1310 CFLAGS 1311 LDFLAGS 1312 LIBS 1313 CPPFLAGS 1314 CXX 1315 CXXFLAGS 1316 CCC 1317 CPP 1318 CXXCPP 1319 AS 1320 AR 1321 LIPO 1322 OTOOL 1323 INSTALL_NAME_TOOL 1324 STRIP 1325 NM 1326 GNM 1327 OBJCOPY 1328 OBJDUMP 1329 BUILD_CC 1330 BUILD_CXX 1331 BUILD_NM 1332 BUILD_AR 1333 BUILD_OBJCOPY 1334 BUILD_STRIP 1335 JTREGEXE 1336 XMKMF 1337 FREETYPE_CFLAGS 1338 FREETYPE_LIBS 1339 ALSA_CFLAGS 1340 ALSA_LIBS 1341 LIBFFI_CFLAGS 1342 LIBFFI_LIBS 1343 PNG_CFLAGS 1344 PNG_LIBS 1345 LCMS_CFLAGS 1346 LCMS_LIBS 1347 ICECC_CMD 1348 ICECC_CREATE_ENV 1349 ICECC_WRAPPER 1350 CCACHE' 1351 1352 1353 # Initialize some variables set by options. 1354 ac_init_help= 1355 ac_init_version=false 1356 ac_unrecognized_opts= 1357 ac_unrecognized_sep= 1358 # The variables have the same names as the options, with 1359 # dashes changed to underlines. 1360 cache_file=/dev/null 1361 exec_prefix=NONE 1362 no_create= 1363 no_recursion= 1364 prefix=NONE 1365 program_prefix=NONE 1366 program_suffix=NONE 1367 program_transform_name=s,x,x, 1368 silent= 1369 site= 1370 srcdir= 1371 verbose= 1372 x_includes=NONE 1373 x_libraries=NONE 1374 1375 # Installation directory options. 1376 # These are left unexpanded so users can "make install exec_prefix=/foo" 1377 # and all the variables that are supposed to be based on exec_prefix 1378 # by default will actually change. 1379 # Use braces instead of parens because sh, perl, etc. also accept them. 1380 # (The list follows the same order as the GNU Coding Standards.) 1381 bindir='${exec_prefix}/bin' 1382 sbindir='${exec_prefix}/sbin' 1383 libexecdir='${exec_prefix}/libexec' 1384 datarootdir='${prefix}/share' 1385 datadir='${datarootdir}' 1386 sysconfdir='${prefix}/etc' 1387 sharedstatedir='${prefix}/com' 1388 localstatedir='${prefix}/var' 1389 includedir='${prefix}/include' 1390 oldincludedir='/usr/include' 1391 docdir='${datarootdir}/doc/${PACKAGE_TARNAME}' 1392 infodir='${datarootdir}/info' 1393 htmldir='${docdir}' 1394 dvidir='${docdir}' 1395 pdfdir='${docdir}' 1396 psdir='${docdir}' 1397 libdir='${exec_prefix}/lib' 1398 localedir='${datarootdir}/locale' 1399 mandir='${datarootdir}/man' 1400 1401 ac_prev= 1402 ac_dashdash= 1403 for ac_option 1404 do 1405 # If the previous option needs an argument, assign it. 1406 if test -n "$ac_prev"; then 1407 eval $ac_prev=\$ac_option 1408 ac_prev= 1409 continue 1410 fi 1411 1412 case $ac_option in 1413 *=?*) ac_optarg=`expr "X$ac_option" : '[^=]*=\(.*\)'` ;; 1414 *=) ac_optarg= ;; 1415 *) ac_optarg=yes ;; 1416 esac 1417 1418 # Accept the important Cygnus configure options, so we can diagnose typos. 1419 1420 case $ac_dashdash$ac_option in 1421 --) 1422 ac_dashdash=yes ;; 1423 1424 -bindir | --bindir | --bindi | --bind | --bin | --bi) 1425 ac_prev=bindir ;; 1426 -bindir=* | --bindir=* | --bindi=* | --bind=* | --bin=* | --bi=*) 1427 bindir=$ac_optarg ;; 1428 1429 -build | --build | --buil | --bui | --bu) 1430 ac_prev=build_alias ;; 1431 -build=* | --build=* | --buil=* | --bui=* | --bu=*) 1432 build_alias=$ac_optarg ;; 1433 1434 -cache-file | --cache-file | --cache-fil | --cache-fi \ 1435 | --cache-f | --cache- | --cache | --cach | --cac | --ca | --c) 1436 ac_prev=cache_file ;; 1437 -cache-file=* | --cache-file=* | --cache-fil=* | --cache-fi=* \ 1438 | --cache-f=* | --cache-=* | --cache=* | --cach=* | --cac=* | --ca=* | --c=*) 1439 cache_file=$ac_optarg ;; 1440 1441 --config-cache | -C) 1442 cache_file=config.cache ;; 1443 1444 -datadir | --datadir | --datadi | --datad) 1445 ac_prev=datadir ;; 1446 -datadir=* | --datadir=* | --datadi=* | --datad=*) 1447 datadir=$ac_optarg ;; 1448 1449 -datarootdir | --datarootdir | --datarootdi | --datarootd | --dataroot \ 1450 | --dataroo | --dataro | --datar) 1451 ac_prev=datarootdir ;; 1452 -datarootdir=* | --datarootdir=* | --datarootdi=* | --datarootd=* \ 1453 | --dataroot=* | --dataroo=* | --dataro=* | --datar=*) 1454 datarootdir=$ac_optarg ;; 1455 1456 -disable-* | --disable-*) 1457 ac_useropt=`expr "x$ac_option" : 'x-*disable-\(.*\)'` 1458 # Reject names that are not valid shell variable names. 1459 expr "x$ac_useropt" : ".*[^-+._$as_cr_alnum]" >/dev/null && 1460 as_fn_error $? "invalid feature name: $ac_useropt" 1461 ac_useropt_orig=$ac_useropt 1462 ac_useropt=`$as_echo "$ac_useropt" | sed 's/[-+.]/_/g'` 1463 case $ac_user_opts in 1464 *" 1465 "enable_$ac_useropt" 1466 "*) ;; 1467 *) ac_unrecognized_opts="$ac_unrecognized_opts$ac_unrecognized_sep--disable-$ac_useropt_orig" 1468 ac_unrecognized_sep=', ';; 1469 esac 1470 eval enable_$ac_useropt=no ;; 1471 1472 -docdir | --docdir | --docdi | --doc | --do) 1473 ac_prev=docdir ;; 1474 -docdir=* | --docdir=* | --docdi=* | --doc=* | --do=*) 1475 docdir=$ac_optarg ;; 1476 1477 -dvidir | --dvidir | --dvidi | --dvid | --dvi | --dv) 1478 ac_prev=dvidir ;; 1479 -dvidir=* | --dvidir=* | --dvidi=* | --dvid=* | --dvi=* | --dv=*) 1480 dvidir=$ac_optarg ;; 1481 1482 -enable-* | --enable-*) 1483 ac_useropt=`expr "x$ac_option" : 'x-*enable-\([^=]*\)'` 1484 # Reject names that are not valid shell variable names. 1485 expr "x$ac_useropt" : ".*[^-+._$as_cr_alnum]" >/dev/null && 1486 as_fn_error $? "invalid feature name: $ac_useropt" 1487 ac_useropt_orig=$ac_useropt 1488 ac_useropt=`$as_echo "$ac_useropt" | sed 's/[-+.]/_/g'` 1489 case $ac_user_opts in 1490 *" 1491 "enable_$ac_useropt" 1492 "*) ;; 1493 *) ac_unrecognized_opts="$ac_unrecognized_opts$ac_unrecognized_sep--enable-$ac_useropt_orig" 1494 ac_unrecognized_sep=', ';; 1495 esac 1496 eval enable_$ac_useropt=\$ac_optarg ;; 1497 1498 -exec-prefix | --exec_prefix | --exec-prefix | --exec-prefi \ 1499 | --exec-pref | --exec-pre | --exec-pr | --exec-p | --exec- \ 1500 | --exec | --exe | --ex) 1501 ac_prev=exec_prefix ;; 1502 -exec-prefix=* | --exec_prefix=* | --exec-prefix=* | --exec-prefi=* \ 1503 | --exec-pref=* | --exec-pre=* | --exec-pr=* | --exec-p=* | --exec-=* \ 1504 | --exec=* | --exe=* | --ex=*) 1505 exec_prefix=$ac_optarg ;; 1506 1507 -gas | --gas | --ga | --g) 1508 # Obsolete; use --with-gas. 1509 with_gas=yes ;; 1510 1511 -help | --help | --hel | --he | -h) 1512 ac_init_help=long ;; 1513 -help=r* | --help=r* | --hel=r* | --he=r* | -hr*) 1514 ac_init_help=recursive ;; 1515 -help=s* | --help=s* | --hel=s* | --he=s* | -hs*) 1516 ac_init_help=short ;; 1517 1518 -host | --host | --hos | --ho) 1519 ac_prev=host_alias ;; 1520 -host=* | --host=* | --hos=* | --ho=*) 1521 host_alias=$ac_optarg ;; 1522 1523 -htmldir | --htmldir | --htmldi | --htmld | --html | --htm | --ht) 1524 ac_prev=htmldir ;; 1525 -htmldir=* | --htmldir=* | --htmldi=* | --htmld=* | --html=* | --htm=* \ 1526 | --ht=*) 1527 htmldir=$ac_optarg ;; 1528 1529 -includedir | --includedir | --includedi | --included | --include \ 1530 | --includ | --inclu | --incl | --inc) 1531 ac_prev=includedir ;; 1532 -includedir=* | --includedir=* | --includedi=* | --included=* | --include=* \ 1533 | --includ=* | --inclu=* | --incl=* | --inc=*) 1534 includedir=$ac_optarg ;; 1535 1536 -infodir | --infodir | --infodi | --infod | --info | --inf) 1537 ac_prev=infodir ;; 1538 -infodir=* | --infodir=* | --infodi=* | --infod=* | --info=* | --inf=*) 1539 infodir=$ac_optarg ;; 1540 1541 -libdir | --libdir | --libdi | --libd) 1542 ac_prev=libdir ;; 1543 -libdir=* | --libdir=* | --libdi=* | --libd=*) 1544 libdir=$ac_optarg ;; 1545 1546 -libexecdir | --libexecdir | --libexecdi | --libexecd | --libexec \ 1547 | --libexe | --libex | --libe) 1548 ac_prev=libexecdir ;; 1549 -libexecdir=* | --libexecdir=* | --libexecdi=* | --libexecd=* | --libexec=* \ 1550 | --libexe=* | --libex=* | --libe=*) 1551 libexecdir=$ac_optarg ;; 1552 1553 -localedir | --localedir | --localedi | --localed | --locale) 1554 ac_prev=localedir ;; 1555 -localedir=* | --localedir=* | --localedi=* | --localed=* | --locale=*) 1556 localedir=$ac_optarg ;; 1557 1558 -localstatedir | --localstatedir | --localstatedi | --localstated \ 1559 | --localstate | --localstat | --localsta | --localst | --locals) 1560 ac_prev=localstatedir ;; 1561 -localstatedir=* | --localstatedir=* | --localstatedi=* | --localstated=* \ 1562 | --localstate=* | --localstat=* | --localsta=* | --localst=* | --locals=*) 1563 localstatedir=$ac_optarg ;; 1564 1565 -mandir | --mandir | --mandi | --mand | --man | --ma | --m) 1566 ac_prev=mandir ;; 1567 -mandir=* | --mandir=* | --mandi=* | --mand=* | --man=* | --ma=* | --m=*) 1568 mandir=$ac_optarg ;; 1569 1570 -nfp | --nfp | --nf) 1571 # Obsolete; use --without-fp. 1572 with_fp=no ;; 1573 1574 -no-create | --no-create | --no-creat | --no-crea | --no-cre \ 1575 | --no-cr | --no-c | -n) 1576 no_create=yes ;; 1577 1578 -no-recursion | --no-recursion | --no-recursio | --no-recursi \ 1579 | --no-recurs | --no-recur | --no-recu | --no-rec | --no-re | --no-r) 1580 no_recursion=yes ;; 1581 1582 -oldincludedir | --oldincludedir | --oldincludedi | --oldincluded \ 1583 | --oldinclude | --oldinclud | --oldinclu | --oldincl | --oldinc \ 1584 | --oldin | --oldi | --old | --ol | --o) 1585 ac_prev=oldincludedir ;; 1586 -oldincludedir=* | --oldincludedir=* | --oldincludedi=* | --oldincluded=* \ 1587 | --oldinclude=* | --oldinclud=* | --oldinclu=* | --oldincl=* | --oldinc=* \ 1588 | --oldin=* | --oldi=* | --old=* | --ol=* | --o=*) 1589 oldincludedir=$ac_optarg ;; 1590 1591 -prefix | --prefix | --prefi | --pref | --pre | --pr | --p) 1592 ac_prev=prefix ;; 1593 -prefix=* | --prefix=* | --prefi=* | --pref=* | --pre=* | --pr=* | --p=*) 1594 prefix=$ac_optarg ;; 1595 1596 -program-prefix | --program-prefix | --program-prefi | --program-pref \ 1597 | --program-pre | --program-pr | --program-p) 1598 ac_prev=program_prefix ;; 1599 -program-prefix=* | --program-prefix=* | --program-prefi=* \ 1600 | --program-pref=* | --program-pre=* | --program-pr=* | --program-p=*) 1601 program_prefix=$ac_optarg ;; 1602 1603 -program-suffix | --program-suffix | --program-suffi | --program-suff \ 1604 | --program-suf | --program-su | --program-s) 1605 ac_prev=program_suffix ;; 1606 -program-suffix=* | --program-suffix=* | --program-suffi=* \ 1607 | --program-suff=* | --program-suf=* | --program-su=* | --program-s=*) 1608 program_suffix=$ac_optarg ;; 1609 1610 -program-transform-name | --program-transform-name \ 1611 | --program-transform-nam | --program-transform-na \ 1612 | --program-transform-n | --program-transform- \ 1613 | --program-transform | --program-transfor \ 1614 | --program-transfo | --program-transf \ 1615 | --program-trans | --program-tran \ 1616 | --progr-tra | --program-tr | --program-t) 1617 ac_prev=program_transform_name ;; 1618 -program-transform-name=* | --program-transform-name=* \ 1619 | --program-transform-nam=* | --program-transform-na=* \ 1620 | --program-transform-n=* | --program-transform-=* \ 1621 | --program-transform=* | --program-transfor=* \ 1622 | --program-transfo=* | --program-transf=* \ 1623 | --program-trans=* | --program-tran=* \ 1624 | --progr-tra=* | --program-tr=* | --program-t=*) 1625 program_transform_name=$ac_optarg ;; 1626 1627 -pdfdir | --pdfdir | --pdfdi | --pdfd | --pdf | --pd) 1628 ac_prev=pdfdir ;; 1629 -pdfdir=* | --pdfdir=* | --pdfdi=* | --pdfd=* | --pdf=* | --pd=*) 1630 pdfdir=$ac_optarg ;; 1631 1632 -psdir | --psdir | --psdi | --psd | --ps) 1633 ac_prev=psdir ;; 1634 -psdir=* | --psdir=* | --psdi=* | --psd=* | --ps=*) 1635 psdir=$ac_optarg ;; 1636 1637 -q | -quiet | --quiet | --quie | --qui | --qu | --q \ 1638 | -silent | --silent | --silen | --sile | --sil) 1639 silent=yes ;; 1640 1641 -sbindir | --sbindir | --sbindi | --sbind | --sbin | --sbi | --sb) 1642 ac_prev=sbindir ;; 1643 -sbindir=* | --sbindir=* | --sbindi=* | --sbind=* | --sbin=* \ 1644 | --sbi=* | --sb=*) 1645 sbindir=$ac_optarg ;; 1646 1647 -sharedstatedir | --sharedstatedir | --sharedstatedi \ 1648 | --sharedstated | --sharedstate | --sharedstat | --sharedsta \ 1649 | --sharedst | --shareds | --shared | --share | --shar \ 1650 | --sha | --sh) 1651 ac_prev=sharedstatedir ;; 1652 -sharedstatedir=* | --sharedstatedir=* | --sharedstatedi=* \ 1653 | --sharedstated=* | --sharedstate=* | --sharedstat=* | --sharedsta=* \ 1654 | --sharedst=* | --shareds=* | --shared=* | --share=* | --shar=* \ 1655 | --sha=* | --sh=*) 1656 sharedstatedir=$ac_optarg ;; 1657 1658 -site | --site | --sit) 1659 ac_prev=site ;; 1660 -site=* | --site=* | --sit=*) 1661 site=$ac_optarg ;; 1662 1663 -srcdir | --srcdir | --srcdi | --srcd | --src | --sr) 1664 ac_prev=srcdir ;; 1665 -srcdir=* | --srcdir=* | --srcdi=* | --srcd=* | --src=* | --sr=*) 1666 srcdir=$ac_optarg ;; 1667 1668 -sysconfdir | --sysconfdir | --sysconfdi | --sysconfd | --sysconf \ 1669 | --syscon | --sysco | --sysc | --sys | --sy) 1670 ac_prev=sysconfdir ;; 1671 -sysconfdir=* | --sysconfdir=* | --sysconfdi=* | --sysconfd=* | --sysconf=* \ 1672 | --syscon=* | --sysco=* | --sysc=* | --sys=* | --sy=*) 1673 sysconfdir=$ac_optarg ;; 1674 1675 -target | --target | --targe | --targ | --tar | --ta | --t) 1676 ac_prev=target_alias ;; 1677 -target=* | --target=* | --targe=* | --targ=* | --tar=* | --ta=* | --t=*) 1678 target_alias=$ac_optarg ;; 1679 1680 -v | -verbose | --verbose | --verbos | --verbo | --verb) 1681 verbose=yes ;; 1682 1683 -version | --version | --versio | --versi | --vers | -V) 1684 ac_init_version=: ;; 1685 1686 -with-* | --with-*) 1687 ac_useropt=`expr "x$ac_option" : 'x-*with-\([^=]*\)'` 1688 # Reject names that are not valid shell variable names. 1689 expr "x$ac_useropt" : ".*[^-+._$as_cr_alnum]" >/dev/null && 1690 as_fn_error $? "invalid package name: $ac_useropt" 1691 ac_useropt_orig=$ac_useropt 1692 ac_useropt=`$as_echo "$ac_useropt" | sed 's/[-+.]/_/g'` 1693 case $ac_user_opts in 1694 *" 1695 "with_$ac_useropt" 1696 "*) ;; 1697 *) ac_unrecognized_opts="$ac_unrecognized_opts$ac_unrecognized_sep--with-$ac_useropt_orig" 1698 ac_unrecognized_sep=', ';; 1699 esac 1700 eval with_$ac_useropt=\$ac_optarg ;; 1701 1702 -without-* | --without-*) 1703 ac_useropt=`expr "x$ac_option" : 'x-*without-\(.*\)'` 1704 # Reject names that are not valid shell variable names. 1705 expr "x$ac_useropt" : ".*[^-+._$as_cr_alnum]" >/dev/null && 1706 as_fn_error $? "invalid package name: $ac_useropt" 1707 ac_useropt_orig=$ac_useropt 1708 ac_useropt=`$as_echo "$ac_useropt" | sed 's/[-+.]/_/g'` 1709 case $ac_user_opts in 1710 *" 1711 "with_$ac_useropt" 1712 "*) ;; 1713 *) ac_unrecognized_opts="$ac_unrecognized_opts$ac_unrecognized_sep--without-$ac_useropt_orig" 1714 ac_unrecognized_sep=', ';; 1715 esac 1716 eval with_$ac_useropt=no ;; 1717 1718 --x) 1719 # Obsolete; use --with-x. 1720 with_x=yes ;; 1721 1722 -x-includes | --x-includes | --x-include | --x-includ | --x-inclu \ 1723 | --x-incl | --x-inc | --x-in | --x-i) 1724 ac_prev=x_includes ;; 1725 -x-includes=* | --x-includes=* | --x-include=* | --x-includ=* | --x-inclu=* \ 1726 | --x-incl=* | --x-inc=* | --x-in=* | --x-i=*) 1727 x_includes=$ac_optarg ;; 1728 1729 -x-libraries | --x-libraries | --x-librarie | --x-librari \ 1730 | --x-librar | --x-libra | --x-libr | --x-lib | --x-li | --x-l) 1731 ac_prev=x_libraries ;; 1732 -x-libraries=* | --x-libraries=* | --x-librarie=* | --x-librari=* \ 1733 | --x-librar=* | --x-libra=* | --x-libr=* | --x-lib=* | --x-li=* | --x-l=*) 1734 x_libraries=$ac_optarg ;; 1735 1736 -*) as_fn_error $? "unrecognized option: \`$ac_option' 1737 Try \`$0 --help' for more information" 1738 ;; 1739 1740 *=*) 1741 ac_envvar=`expr "x$ac_option" : 'x\([^=]*\)='` 1742 # Reject names that are not valid shell variable names. 1743 case $ac_envvar in #( 1744 '' | [0-9]* | *[!_$as_cr_alnum]* ) 1745 as_fn_error $? "invalid variable name: \`$ac_envvar'" ;; 1746 esac 1747 eval $ac_envvar=\$ac_optarg 1748 export $ac_envvar ;; 1749 1750 *) 1751 # FIXME: should be removed in autoconf 3.0. 1752 $as_echo "$as_me: WARNING: you should use --build, --host, --target" >&2 1753 expr "x$ac_option" : ".*[^-._$as_cr_alnum]" >/dev/null && 1754 $as_echo "$as_me: WARNING: invalid host type: $ac_option" >&2 1755 : "${build_alias=$ac_option} ${host_alias=$ac_option} ${target_alias=$ac_option}" 1756 ;; 1757 1758 esac 1759 done 1760 1761 if test -n "$ac_prev"; then 1762 ac_option=--`echo $ac_prev | sed 's/_/-/g'` 1763 as_fn_error $? "missing argument to $ac_option" 1764 fi 1765 1766 if test -n "$ac_unrecognized_opts"; then 1767 case $enable_option_checking in 1768 no) ;; 1769 fatal) as_fn_error $? "unrecognized options: $ac_unrecognized_opts" ;; 1770 *) $as_echo "$as_me: WARNING: unrecognized options: $ac_unrecognized_opts" >&2 ;; 1771 esac 1772 fi 1773 1774 # Check all directory arguments for consistency. 1775 for ac_var in exec_prefix prefix bindir sbindir libexecdir datarootdir \ 1776 datadir sysconfdir sharedstatedir localstatedir includedir \ 1777 oldincludedir docdir infodir htmldir dvidir pdfdir psdir \ 1778 libdir localedir mandir 1779 do 1780 eval ac_val=\$$ac_var 1781 # Remove trailing slashes. 1782 case $ac_val in 1783 */ ) 1784 ac_val=`expr "X$ac_val" : 'X\(.*[^/]\)' \| "X$ac_val" : 'X\(.*\)'` 1785 eval $ac_var=\$ac_val;; 1786 esac 1787 # Be sure to have absolute directory names. 1788 case $ac_val in 1789 [\\/$]* | ?:[\\/]* ) continue;; 1790 NONE | '' ) case $ac_var in *prefix ) continue;; esac;; 1791 esac 1792 as_fn_error $? "expected an absolute directory name for --$ac_var: $ac_val" 1793 done 1794 1795 # There might be people who depend on the old broken behavior: `$host' 1796 # used to hold the argument of --host etc. 1797 # FIXME: To remove some day. 1798 build=$build_alias 1799 host=$host_alias 1800 target=$target_alias 1801 1802 # FIXME: To remove some day. 1803 if test "x$host_alias" != x; then 1804 if test "x$build_alias" = x; then 1805 cross_compiling=maybe 1806 elif test "x$build_alias" != "x$host_alias"; then 1807 cross_compiling=yes 1808 fi 1809 fi 1810 1811 ac_tool_prefix= 1812 test -n "$host_alias" && ac_tool_prefix=$host_alias- 1813 1814 test "$silent" = yes && exec 6>/dev/null 1815 1816 1817 ac_pwd=`pwd` && test -n "$ac_pwd" && 1818 ac_ls_di=`ls -di .` && 1819 ac_pwd_ls_di=`cd "$ac_pwd" && ls -di .` || 1820 as_fn_error $? "working directory cannot be determined" 1821 test "X$ac_ls_di" = "X$ac_pwd_ls_di" || 1822 as_fn_error $? "pwd does not report name of working directory" 1823 1824 1825 # Find the source files, if location was not specified. 1826 if test -z "$srcdir"; then 1827 ac_srcdir_defaulted=yes 1828 # Try the directory containing this script, then the parent directory. 1829 ac_confdir=`$as_dirname -- "$as_myself" || 1830 $as_expr X"$as_myself" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \ 1831 X"$as_myself" : 'X\(//\)[^/]' \| \ 1832 X"$as_myself" : 'X\(//\)$' \| \ 1833 X"$as_myself" : 'X\(/\)' \| . 2>/dev/null || 1834 $as_echo X"$as_myself" | 1835 sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{ 1836 s//\1/ 1837 q 1838 } 1839 /^X\(\/\/\)[^/].*/{ 1840 s//\1/ 1841 q 1842 } 1843 /^X\(\/\/\)$/{ 1844 s//\1/ 1845 q 1846 } 1847 /^X\(\/\).*/{ 1848 s//\1/ 1849 q 1850 } 1851 s/.*/./; q'` 1852 srcdir=$ac_confdir 1853 if test ! -r "$srcdir/$ac_unique_file"; then 1854 srcdir=.. 1855 fi 1856 else 1857 ac_srcdir_defaulted=no 1858 fi 1859 if test ! -r "$srcdir/$ac_unique_file"; then 1860 test "$ac_srcdir_defaulted" = yes && srcdir="$ac_confdir or .." 1861 as_fn_error $? "cannot find sources ($ac_unique_file) in $srcdir" 1862 fi 1863 ac_msg="sources are in $srcdir, but \`cd $srcdir' does not work" 1864 ac_abs_confdir=`( 1865 cd "$srcdir" && test -r "./$ac_unique_file" || as_fn_error $? "$ac_msg" 1866 pwd)` 1867 # When building in place, set srcdir=. 1868 if test "$ac_abs_confdir" = "$ac_pwd"; then 1869 srcdir=. 1870 fi 1871 # Remove unnecessary trailing slashes from srcdir. 1872 # Double slashes in file names in object file debugging info 1873 # mess up M-x gdb in Emacs. 1874 case $srcdir in 1875 */) srcdir=`expr "X$srcdir" : 'X\(.*[^/]\)' \| "X$srcdir" : 'X\(.*\)'`;; 1876 esac 1877 for ac_var in $ac_precious_vars; do 1878 eval ac_env_${ac_var}_set=\${${ac_var}+set} 1879 eval ac_env_${ac_var}_value=\$${ac_var} 1880 eval ac_cv_env_${ac_var}_set=\${${ac_var}+set} 1881 eval ac_cv_env_${ac_var}_value=\$${ac_var} 1882 done 1883 1884 # 1885 # Report the --help message. 1886 # 1887 if test "$ac_init_help" = "long"; then 1888 # Omit some internal or obsolete options to make the list less imposing. 1889 # This message is too long to be a string in the A/UX 3.1 sh. 1890 cat <<_ACEOF 1891 \`configure' configures OpenJDK jdk9 to adapt to many kinds of systems. 1892 1893 Usage: $0 [OPTION]... [VAR=VALUE]... 1894 1895 To assign environment variables (e.g., CC, CFLAGS...), specify them as 1896 VAR=VALUE. See below for descriptions of some of the useful variables. 1897 1898 Defaults for the options are specified in brackets. 1899 1900 Configuration: 1901 -h, --help display this help and exit 1902 --help=short display options specific to this package 1903 --help=recursive display the short help of all the included packages 1904 -V, --version display version information and exit 1905 -q, --quiet, --silent do not print \`checking ...' messages 1906 --cache-file=FILE cache test results in FILE [disabled] 1907 -C, --config-cache alias for \`--cache-file=config.cache' 1908 -n, --no-create do not create output files 1909 --srcdir=DIR find the sources in DIR [configure dir or \`..'] 1910 1911 Installation directories: 1912 --prefix=PREFIX install architecture-independent files in PREFIX 1913 [$ac_default_prefix] 1914 --exec-prefix=EPREFIX install architecture-dependent files in EPREFIX 1915 [PREFIX] 1916 1917 By default, \`make install' will install all the files in 1918 \`$ac_default_prefix/bin', \`$ac_default_prefix/lib' etc. You can specify 1919 an installation prefix other than \`$ac_default_prefix' using \`--prefix', 1920 for instance \`--prefix=\$HOME'. 1921 1922 For better control, use the options below. 1923 1924 Fine tuning of the installation directories: 1925 --bindir=DIR user executables [EPREFIX/bin] 1926 --sbindir=DIR system admin executables [EPREFIX/sbin] 1927 --libexecdir=DIR program executables [EPREFIX/libexec] 1928 --sysconfdir=DIR read-only single-machine data [PREFIX/etc] 1929 --sharedstatedir=DIR modifiable architecture-independent data [PREFIX/com] 1930 --localstatedir=DIR modifiable single-machine data [PREFIX/var] 1931 --libdir=DIR object code libraries [EPREFIX/lib] 1932 --includedir=DIR C header files [PREFIX/include] 1933 --oldincludedir=DIR C header files for non-gcc [/usr/include] 1934 --datarootdir=DIR read-only arch.-independent data root [PREFIX/share] 1935 --datadir=DIR read-only architecture-independent data [DATAROOTDIR] 1936 --infodir=DIR info documentation [DATAROOTDIR/info] 1937 --localedir=DIR locale-dependent data [DATAROOTDIR/locale] 1938 --mandir=DIR man documentation [DATAROOTDIR/man] 1939 --docdir=DIR documentation root [DATAROOTDIR/doc/openjdk] 1940 --htmldir=DIR html documentation [DOCDIR] 1941 --dvidir=DIR dvi documentation [DOCDIR] 1942 --pdfdir=DIR pdf documentation [DOCDIR] 1943 --psdir=DIR ps documentation [DOCDIR] 1944 _ACEOF 1945 1946 cat <<\_ACEOF 1947 1948 X features: 1949 --x-includes=DIR X include files are in DIR 1950 --x-libraries=DIR X library files are in DIR 1951 1952 System types: 1953 --build=BUILD configure for building on BUILD [guessed] 1954 --host=HOST cross-compile to build programs to run on HOST [BUILD] 1955 --target=TARGET configure for building compilers for TARGET [HOST] 1956 _ACEOF 1957 fi 1958 1959 if test -n "$ac_init_help"; then 1960 case $ac_init_help in 1961 short | recursive ) echo "Configuration of OpenJDK jdk9:";; 1962 esac 1963 cat <<\_ACEOF 1964 1965 Optional Features: 1966 --disable-option-checking ignore unrecognized --enable/--with options 1967 --disable-FEATURE do not include FEATURE (same as --enable-FEATURE=no) 1968 --enable-FEATURE[=ARG] include FEATURE [ARG=yes] 1969 --enable-openjdk-only suppress building custom source even if present 1970 [disabled] 1971 --enable-debug set the debug level to fastdebug (shorthand for 1972 --with-debug-level=fastdebug) [disabled] 1973 --enable-headless-only only build headless (no GUI) support [disabled] 1974 --enable-full-docs build complete documentation [enabled if all tools 1975 found] 1976 --disable-unlimited-crypto 1977 Disable unlimited crypto policy [enabled] 1978 --disable-keep-packaged-modules 1979 Do not keep packaged modules in jdk image [enable] 1980 --enable-static-build enable static library build [disabled] 1981 --disable-warnings-as-errors 1982 do not consider native warnings to be an error 1983 [enabled] 1984 --enable-debug-symbols Deprecated. Option is kept for backwards 1985 compatibility and is ignored 1986 --enable-zip-debug-info Deprecated. Option is kept for backwards 1987 compatibility and is ignored 1988 --enable-native-coverage 1989 enable native compilation with code coverage 1990 data[disabled] 1991 --enable-asan enable AddressSanitizer if possible [disabled] 1992 --enable-dtrace[=yes/no/auto] 1993 enable dtrace. Default is auto, where dtrace is 1994 enabled if all dependencies are present. 1995 --enable-aot[=yes/no/auto] 1996 enable ahead of time compilation feature. Default is 1997 auto, where aot is enabled if all dependencies are 1998 present. 1999 --enable-cds[=yes/no] enable class data sharing feature in non-minimal VM. 2000 Default is yes. 2001 --disable-hotspot-gtest Disables building of the Hotspot unit tests 2002 [enabled] 2003 --disable-freetype-bundling 2004 disable bundling of the freetype library with the 2005 build result [enabled on Windows or when using 2006 --with-freetype, disabled otherwise] 2007 --enable-libffi-bundling 2008 enable bundling of libffi.so to make the built JDK 2009 runnable on more systems 2010 --enable-jtreg-failure-handler 2011 forces build of the jtreg failure handler to be 2012 enabled, missing dependencies become fatal errors. 2013 Default is auto, where the failure handler is built 2014 if all dependencies are present and otherwise just 2015 disabled. 2016 --disable-generate-classlist 2017 forces enabling or disabling of the generation of a 2018 CDS classlist at build time. Default is to generate 2019 it when either the server or client JVMs are built 2020 and enable-cds is true. 2021 --enable-sjavac use sjavac to do fast incremental compiles 2022 [disabled] 2023 --disable-javac-server disable javac server [enabled] 2024 --enable-icecc enable distribted compilation of native code using 2025 icecc/icecream [disabled] 2026 --disable-precompiled-headers 2027 disable using precompiled headers when compiling C++ 2028 [enabled] 2029 --enable-ccache enable using ccache to speed up recompilations 2030 [disabled] 2031 2032 Optional Packages: 2033 --with-PACKAGE[=ARG] use PACKAGE [ARG=yes] 2034 --without-PACKAGE do not use PACKAGE (same as --with-PACKAGE=no) 2035 --with-target-bits build 32-bit or 64-bit binaries (for platforms that 2036 support it), e.g. --with-target-bits=32 [guessed] 2037 --with-custom-make-dir Deprecated. Option is kept for backwards 2038 compatibility and is ignored 2039 --with-jdk-variant JDK variant to build (normal) [normal] 2040 --with-debug-level set the debug level (release, fastdebug, slowdebug, 2041 optimized) [release] 2042 --with-jvm-variants JVM variants (separated by commas) to build 2043 (server,client,minimal,core,zero,custom) [server] 2044 --with-cpu-port specify sources to use for Hotspot 64-bit ARM port 2045 (arm64,aarch64) [aarch64] 2046 --with-devkit use this devkit for compilers, tools and resources 2047 --with-sys-root alias for --with-sysroot for backwards compatability 2048 --with-sysroot use this directory as sysroot 2049 --with-tools-dir alias for --with-toolchain-path for backwards 2050 compatibility 2051 --with-toolchain-path prepend these directories when searching for 2052 toolchain binaries (compilers etc) 2053 --with-extra-path prepend these directories to the default path 2054 --with-sdk-name use the platform SDK of the given name. [macosx] 2055 --with-conf-name use this as the name of the configuration [generated 2056 from important configuration options] 2057 --with-output-sync set make output sync type if supported by make. 2058 [recurse] 2059 --with-default-make-target 2060 set the default make target [exploded-image] 2061 --with-cacerts-file specify alternative cacerts file 2062 --with-copyright-year Set copyright year value for build [current year] 2063 --with-milestone Deprecated. Option is kept for backwards 2064 compatibility and is ignored 2065 --with-update-version Deprecated. Option is kept for backwards 2066 compatibility and is ignored 2067 --with-user-release-suffix 2068 Deprecated. Option is kept for backwards 2069 compatibility and is ignored 2070 --with-build-number Deprecated. Option is kept for backwards 2071 compatibility and is ignored 2072 --with-version-major Deprecated. Option is kept for backwards 2073 compatibility and is ignored 2074 --with-version-minor Deprecated. Option is kept for backwards 2075 compatibility and is ignored 2076 --with-version-security Deprecated. Option is kept for backwards 2077 compatibility and is ignored 2078 --with-version-string Set version string [calculated] 2079 --with-version-pre Set the base part of the version 'PRE' field 2080 (pre-release identifier) ['internal'] 2081 --with-version-opt Set version 'OPT' field (build metadata) 2082 [<timestamp>.<user>.<dirname>] 2083 --with-version-build Set version 'BUILD' field (build number) [not 2084 specified] 2085 --with-version-feature Set version 'FEATURE' field (first number) [current 2086 source value] 2087 --with-version-interim Set version 'INTERIM' field (second number) [current 2088 source value] 2089 --with-version-update Set version 'UPDATE' field (third number) [current 2090 source value] 2091 --with-version-patch Set version 'PATCH' field (fourth number) [not 2092 specified] 2093 --with-version-date Set version date [current source value] 2094 --with-vendor-version-string 2095 Set vendor version string [not specified] 2096 --with-boot-jdk path to Boot JDK (used to bootstrap build) [probed] 2097 --with-build-jdk path to JDK of same version as is being built[the 2098 newly built JDK] 2099 --with-import-modules import a set of prebuilt modules either as a zip 2100 file or an exploded directory 2101 --with-toolchain-type the toolchain type (or family) to use, use '--help' 2102 to show possible values [platform dependent] 2103 --with-extra-cflags extra flags to be used when compiling jdk c-files 2104 --with-extra-cxxflags extra flags to be used when compiling jdk c++-files 2105 --with-extra-ldflags extra flags to be used when linking jdk 2106 --with-toolchain-version 2107 the version of the toolchain to look for, use 2108 '--help' to show possible values [platform 2109 dependent] 2110 --with-build-devkit Devkit to use for the build platform toolchain 2111 --with-jtreg Regression Test Harness [probed] 2112 --with-jib Jib dependency management tool [not used] 2113 --with-abi-profile specify ABI profile for ARM builds 2114 (arm-vfp-sflt,arm-vfp-hflt,arm-sflt, 2115 armv5-vfp-sflt,armv6-vfp-hflt,arm64,aarch64) 2116 [toolchain dependent] 2117 --with-macosx-version-max 2118 error on use of newer functionality. [macosx] 2119 --with-native-debug-symbols 2120 set the native debug symbol configuration (none, 2121 internal, external, zipped) [varying] 2122 --with-stdc++lib=<static>,<dynamic>,<default> 2123 force linking of the C++ runtime on Linux to either 2124 static or dynamic, default is static with dynamic as 2125 fallback 2126 --with-msvcr-dll path to microsoft C runtime dll (msvcr*.dll) 2127 (Windows only) [probed] 2128 --with-msvcp-dll path to microsoft C++ runtime dll (msvcp*.dll) 2129 (Windows only) [probed] 2130 --with-x use the X Window System 2131 --with-cups specify prefix directory for the cups package 2132 (expecting the headers under PATH/include) 2133 --with-cups-include specify directory for the cups include files 2134 --with-fontconfig specify prefix directory for the fontconfig package 2135 (expecting the headers under PATH/include) 2136 --with-fontconfig-include 2137 specify directory for the fontconfig include files 2138 --with-freetype specify prefix directory for the freetype package 2139 (expecting the libraries under PATH/lib and the 2140 headers under PATH/include) 2141 --with-freetype-include specify directory for the freetype include files 2142 --with-freetype-lib specify directory for the freetype library 2143 --with-freetype-src specify directory with freetype sources to 2144 automatically build the library (experimental, 2145 Windows-only) 2146 --with-freetype-license if bundling freetype, also bundle this license file 2147 --with-alsa specify prefix directory for the alsa package 2148 (expecting the libraries under PATH/lib and the 2149 headers under PATH/include) 2150 --with-alsa-include specify directory for the alsa include files 2151 --with-alsa-lib specify directory for the alsa library 2152 --with-libffi specify prefix directory for the libffi package 2153 (expecting the libraries under PATH/lib and the 2154 headers under PATH/include) 2155 --with-libffi-include specify directory for the libffi include files 2156 --with-libffi-lib specify directory for the libffi library 2157 --with-libjpeg use libjpeg from build system or OpenJDK source 2158 (system, bundled) [bundled] 2159 --with-giflib use giflib from build system or OpenJDK source 2160 (system, bundled) [bundled] 2161 --with-libpng use libpng from build system or OpenJDK source 2162 (system, bundled) [bundled] 2163 --with-zlib use zlib from build system or OpenJDK source 2164 (system, bundled) [bundled] 2165 --with-lcms use lcms2 from build system or OpenJDK source 2166 (system, bundled) [bundled] 2167 --with-dxsdk Deprecated. Option is kept for backwards 2168 compatibility and is ignored 2169 --with-dxsdk-lib Deprecated. Option is kept for backwards 2170 compatibility and is ignored 2171 --with-dxsdk-include Deprecated. Option is kept for backwards 2172 compatibility and is ignored 2173 --with-jvm-features additional JVM features to enable (separated by 2174 comma), use '--help' to show possible values [none] 2175 --with-jvm-interpreter Deprecated. Option is kept for backwards 2176 compatibility and is ignored 2177 --with-num-cores number of cores in the build system, e.g. 2178 --with-num-cores=8 [probed] 2179 --with-memory-size memory (in MB) available in the build system, e.g. 2180 --with-memory-size=1024 [probed] 2181 --with-jobs number of parallel jobs to let make run [calculated 2182 based on cores and memory] 2183 --with-test-jobs number of parallel tests jobs to run [based on build 2184 jobs] 2185 --with-boot-jdk-jvmargs specify JVM arguments to be passed to all java 2186 invocations of boot JDK, overriding the default 2187 values, e.g --with-boot-jdk-jvmargs="-Xmx8G 2188 -enableassertions" 2189 --with-sjavac-server-java 2190 use this java binary for running the sjavac 2191 background server [Boot JDK java] 2192 --with-ccache-dir where to store ccache files [~/.ccache] 2193 2194 Some influential environment variables: 2195 BASENAME Override default value for BASENAME 2196 BASH Override default value for BASH 2197 CAT Override default value for CAT 2198 CHMOD Override default value for CHMOD 2199 CMP Override default value for CMP 2200 COMM Override default value for COMM 2201 CP Override default value for CP 2202 CUT Override default value for CUT 2203 DATE Override default value for DATE 2204 DIFF Override default value for DIFF 2205 DIRNAME Override default value for DIRNAME 2206 ECHO Override default value for ECHO 2207 EXPR Override default value for EXPR 2208 FILE Override default value for FILE 2209 FIND Override default value for FIND 2210 HEAD Override default value for HEAD 2211 GUNZIP Override default value for GUNZIP 2212 GZIP Override default value for GZIP 2213 LN Override default value for LN 2214 LS Override default value for LS 2215 MKDIR Override default value for MKDIR 2216 MKTEMP Override default value for MKTEMP 2217 MV Override default value for MV 2218 NAWK Override default value for NAWK 2219 PRINTF Override default value for PRINTF 2220 RM Override default value for RM 2221 RMDIR Override default value for RMDIR 2222 SH Override default value for SH 2223 SORT Override default value for SORT 2224 TAIL Override default value for TAIL 2225 TAR Override default value for TAR 2226 TEE Override default value for TEE 2227 TOUCH Override default value for TOUCH 2228 TR Override default value for TR 2229 UNAME Override default value for UNAME 2230 UNIQ Override default value for UNIQ 2231 WC Override default value for WC 2232 WHICH Override default value for WHICH 2233 XARGS Override default value for XARGS 2234 AWK Override default value for AWK 2235 GREP Override default value for GREP 2236 EGREP Override default value for EGREP 2237 FGREP Override default value for FGREP 2238 SED Override default value for SED 2239 CYGPATH Override default value for CYGPATH 2240 READLINK Override default value for READLINK 2241 DF Override default value for DF 2242 CPIO Override default value for CPIO 2243 NICE Override default value for NICE 2244 PANDOC Override default value for PANDOC 2245 MAKE Override default value for MAKE 2246 UNZIP Override default value for UNZIP 2247 ZIPEXE Override default value for ZIPEXE 2248 LDD Override default value for LDD 2249 READELF Override default value for READELF 2250 DOT Override default value for DOT 2251 HG Override default value for HG 2252 STAT Override default value for STAT 2253 TIME Override default value for TIME 2254 FLOCK Override default value for FLOCK 2255 DTRACE Override default value for DTRACE 2256 PATCH Override default value for PATCH 2257 DSYMUTIL Override default value for DSYMUTIL 2258 XATTR Override default value for XATTR 2259 CODESIGN Override default value for CODESIGN 2260 SETFILE Override default value for SETFILE 2261 PKG_CONFIG path to pkg-config utility 2262 JAVA Override default value for JAVA 2263 JAVAC Override default value for JAVAC 2264 JAVAH Override default value for JAVAH 2265 JAVADOC Override default value for JAVADOC 2266 JAR Override default value for JAR 2267 JARSIGNER Override default value for JARSIGNER 2268 CC C compiler command 2269 CFLAGS C compiler flags 2270 LDFLAGS linker flags, e.g. -L<lib dir> if you have libraries in a 2271 nonstandard directory <lib dir> 2272 LIBS libraries to pass to the linker, e.g. -l<library> 2273 CPPFLAGS (Objective) C/C++ preprocessor flags, e.g. -I<include dir> if 2274 you have headers in a nonstandard directory <include dir> 2275 CXX C++ compiler command 2276 CXXFLAGS C++ compiler flags 2277 CPP C preprocessor 2278 CXXCPP C++ preprocessor 2279 AS Override default value for AS 2280 AR Override default value for AR 2281 LIPO Override default value for LIPO 2282 OTOOL Override default value for OTOOL 2283 INSTALL_NAME_TOOL 2284 Override default value for INSTALL_NAME_TOOL 2285 STRIP Override default value for STRIP 2286 NM Override default value for NM 2287 GNM Override default value for GNM 2288 OBJCOPY Override default value for OBJCOPY 2289 OBJDUMP Override default value for OBJDUMP 2290 BUILD_CC Override default value for BUILD_CC 2291 BUILD_CXX Override default value for BUILD_CXX 2292 BUILD_NM Override default value for BUILD_NM 2293 BUILD_AR Override default value for BUILD_AR 2294 BUILD_OBJCOPY 2295 Override default value for BUILD_OBJCOPY 2296 BUILD_STRIP Override default value for BUILD_STRIP 2297 JTREGEXE Override default value for JTREGEXE 2298 XMKMF Path to xmkmf, Makefile generator for X Window System 2299 FREETYPE_CFLAGS 2300 C compiler flags for FREETYPE, overriding pkg-config 2301 FREETYPE_LIBS 2302 linker flags for FREETYPE, overriding pkg-config 2303 ALSA_CFLAGS C compiler flags for ALSA, overriding pkg-config 2304 ALSA_LIBS linker flags for ALSA, overriding pkg-config 2305 LIBFFI_CFLAGS 2306 C compiler flags for LIBFFI, overriding pkg-config 2307 LIBFFI_LIBS linker flags for LIBFFI, overriding pkg-config 2308 PNG_CFLAGS C compiler flags for PNG, overriding pkg-config 2309 PNG_LIBS linker flags for PNG, overriding pkg-config 2310 LCMS_CFLAGS C compiler flags for LCMS, overriding pkg-config 2311 LCMS_LIBS linker flags for LCMS, overriding pkg-config 2312 ICECC_CMD Override default value for ICECC_CMD 2313 ICECC_CREATE_ENV 2314 Override default value for ICECC_CREATE_ENV 2315 ICECC_WRAPPER 2316 Override default value for ICECC_WRAPPER 2317 CCACHE Override default value for CCACHE 2318 2319 Use these variables to override the choices made by `configure' or to help 2320 it to find libraries and programs with nonstandard names/locations. 2321 2322 Report bugs to <build-dev@openjdk.java.net>. 2323 OpenJDK home page: <http://openjdk.java.net>. 2324 _ACEOF 2325 ac_status=$? 2326 fi 2327 2328 if test "$ac_init_help" = "recursive"; then 2329 # If there are subdirs, report their specific --help. 2330 for ac_dir in : $ac_subdirs_all; do test "x$ac_dir" = x: && continue 2331 test -d "$ac_dir" || 2332 { cd "$srcdir" && ac_pwd=`pwd` && srcdir=. && test -d "$ac_dir"; } || 2333 continue 2334 ac_builddir=. 2335 2336 case "$ac_dir" in 2337 .) ac_dir_suffix= ac_top_builddir_sub=. ac_top_build_prefix= ;; 2338 *) 2339 ac_dir_suffix=/`$as_echo "$ac_dir" | sed 's|^\.[\\/]||'` 2340 # A ".." for each directory in $ac_dir_suffix. 2341 ac_top_builddir_sub=`$as_echo "$ac_dir_suffix" | sed 's|/[^\\/]*|/..|g;s|/||'` 2342 case $ac_top_builddir_sub in 2343 "") ac_top_builddir_sub=. ac_top_build_prefix= ;; 2344 *) ac_top_build_prefix=$ac_top_builddir_sub/ ;; 2345 esac ;; 2346 esac 2347 ac_abs_top_builddir=$ac_pwd 2348 ac_abs_builddir=$ac_pwd$ac_dir_suffix 2349 # for backward compatibility: 2350 ac_top_builddir=$ac_top_build_prefix 2351 2352 case $srcdir in 2353 .) # We are building in place. 2354 ac_srcdir=. 2355 ac_top_srcdir=$ac_top_builddir_sub 2356 ac_abs_top_srcdir=$ac_pwd ;; 2357 [\\/]* | ?:[\\/]* ) # Absolute name. 2358 ac_srcdir=$srcdir$ac_dir_suffix; 2359 ac_top_srcdir=$srcdir 2360 ac_abs_top_srcdir=$srcdir ;; 2361 *) # Relative name. 2362 ac_srcdir=$ac_top_build_prefix$srcdir$ac_dir_suffix 2363 ac_top_srcdir=$ac_top_build_prefix$srcdir 2364 ac_abs_top_srcdir=$ac_pwd/$srcdir ;; 2365 esac 2366 ac_abs_srcdir=$ac_abs_top_srcdir$ac_dir_suffix 2367 2368 cd "$ac_dir" || { ac_status=$?; continue; } 2369 # Check for guested configure. 2370 if test -f "$ac_srcdir/configure.gnu"; then 2371 echo && 2372 $SHELL "$ac_srcdir/configure.gnu" --help=recursive 2373 elif test -f "$ac_srcdir/configure"; then 2374 echo && 2375 $SHELL "$ac_srcdir/configure" --help=recursive 2376 else 2377 $as_echo "$as_me: WARNING: no configuration information is in $ac_dir" >&2 2378 fi || ac_status=$? 2379 cd "$ac_pwd" || { ac_status=$?; break; } 2380 done 2381 fi 2382 2383 test -n "$ac_init_help" && exit $ac_status 2384 if $ac_init_version; then 2385 cat <<\_ACEOF 2386 OpenJDK configure jdk9 2387 generated by GNU Autoconf 2.69 2388 2389 Copyright (C) 2012 Free Software Foundation, Inc. 2390 This configure script is free software; the Free Software Foundation 2391 gives unlimited permission to copy, distribute and modify it. 2392 _ACEOF 2393 exit 2394 fi 2395 2396 ## ------------------------ ## 2397 ## Autoconf initialization. ## 2398 ## ------------------------ ## 2399 2400 # ac_fn_c_try_compile LINENO 2401 # -------------------------- 2402 # Try to compile conftest.$ac_ext, and return whether this succeeded. 2403 ac_fn_c_try_compile () 2404 { 2405 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack 2406 rm -f conftest.$ac_objext 2407 if { { ac_try="$ac_compile" 2408 case "(($ac_try" in 2409 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; 2410 *) ac_try_echo=$ac_try;; 2411 esac 2412 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\"" 2413 $as_echo "$ac_try_echo"; } >&5 2414 (eval "$ac_compile") 2>conftest.err 2415 ac_status=$? 2416 if test -s conftest.err; then 2417 grep -v '^ *+' conftest.err >conftest.er1 2418 cat conftest.er1 >&5 2419 mv -f conftest.er1 conftest.err 2420 fi 2421 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 2422 test $ac_status = 0; } && { 2423 test -z "$ac_c_werror_flag" || 2424 test ! -s conftest.err 2425 } && test -s conftest.$ac_objext; then : 2426 ac_retval=0 2427 else 2428 $as_echo "$as_me: failed program was:" >&5 2429 sed 's/^/| /' conftest.$ac_ext >&5 2430 2431 ac_retval=1 2432 fi 2433 eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno 2434 as_fn_set_status $ac_retval 2435 2436 } # ac_fn_c_try_compile 2437 2438 # ac_fn_cxx_try_compile LINENO 2439 # ---------------------------- 2440 # Try to compile conftest.$ac_ext, and return whether this succeeded. 2441 ac_fn_cxx_try_compile () 2442 { 2443 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack 2444 rm -f conftest.$ac_objext 2445 if { { ac_try="$ac_compile" 2446 case "(($ac_try" in 2447 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; 2448 *) ac_try_echo=$ac_try;; 2449 esac 2450 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\"" 2451 $as_echo "$ac_try_echo"; } >&5 2452 (eval "$ac_compile") 2>conftest.err 2453 ac_status=$? 2454 if test -s conftest.err; then 2455 grep -v '^ *+' conftest.err >conftest.er1 2456 cat conftest.er1 >&5 2457 mv -f conftest.er1 conftest.err 2458 fi 2459 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 2460 test $ac_status = 0; } && { 2461 test -z "$ac_cxx_werror_flag" || 2462 test ! -s conftest.err 2463 } && test -s conftest.$ac_objext; then : 2464 ac_retval=0 2465 else 2466 $as_echo "$as_me: failed program was:" >&5 2467 sed 's/^/| /' conftest.$ac_ext >&5 2468 2469 ac_retval=1 2470 fi 2471 eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno 2472 as_fn_set_status $ac_retval 2473 2474 } # ac_fn_cxx_try_compile 2475 2476 # ac_fn_c_try_cpp LINENO 2477 # ---------------------- 2478 # Try to preprocess conftest.$ac_ext, and return whether this succeeded. 2479 ac_fn_c_try_cpp () 2480 { 2481 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack 2482 if { { ac_try="$ac_cpp conftest.$ac_ext" 2483 case "(($ac_try" in 2484 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; 2485 *) ac_try_echo=$ac_try;; 2486 esac 2487 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\"" 2488 $as_echo "$ac_try_echo"; } >&5 2489 (eval "$ac_cpp conftest.$ac_ext") 2>conftest.err 2490 ac_status=$? 2491 if test -s conftest.err; then 2492 grep -v '^ *+' conftest.err >conftest.er1 2493 cat conftest.er1 >&5 2494 mv -f conftest.er1 conftest.err 2495 fi 2496 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 2497 test $ac_status = 0; } > conftest.i && { 2498 test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" || 2499 test ! -s conftest.err 2500 }; then : 2501 ac_retval=0 2502 else 2503 $as_echo "$as_me: failed program was:" >&5 2504 sed 's/^/| /' conftest.$ac_ext >&5 2505 2506 ac_retval=1 2507 fi 2508 eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno 2509 as_fn_set_status $ac_retval 2510 2511 } # ac_fn_c_try_cpp 2512 2513 # ac_fn_cxx_try_cpp LINENO 2514 # ------------------------ 2515 # Try to preprocess conftest.$ac_ext, and return whether this succeeded. 2516 ac_fn_cxx_try_cpp () 2517 { 2518 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack 2519 if { { ac_try="$ac_cpp conftest.$ac_ext" 2520 case "(($ac_try" in 2521 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; 2522 *) ac_try_echo=$ac_try;; 2523 esac 2524 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\"" 2525 $as_echo "$ac_try_echo"; } >&5 2526 (eval "$ac_cpp conftest.$ac_ext") 2>conftest.err 2527 ac_status=$? 2528 if test -s conftest.err; then 2529 grep -v '^ *+' conftest.err >conftest.er1 2530 cat conftest.er1 >&5 2531 mv -f conftest.er1 conftest.err 2532 fi 2533 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 2534 test $ac_status = 0; } > conftest.i && { 2535 test -z "$ac_cxx_preproc_warn_flag$ac_cxx_werror_flag" || 2536 test ! -s conftest.err 2537 }; then : 2538 ac_retval=0 2539 else 2540 $as_echo "$as_me: failed program was:" >&5 2541 sed 's/^/| /' conftest.$ac_ext >&5 2542 2543 ac_retval=1 2544 fi 2545 eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno 2546 as_fn_set_status $ac_retval 2547 2548 } # ac_fn_cxx_try_cpp 2549 2550 # ac_fn_c_try_link LINENO 2551 # ----------------------- 2552 # Try to link conftest.$ac_ext, and return whether this succeeded. 2553 ac_fn_c_try_link () 2554 { 2555 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack 2556 rm -f conftest.$ac_objext conftest$ac_exeext 2557 if { { ac_try="$ac_link" 2558 case "(($ac_try" in 2559 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; 2560 *) ac_try_echo=$ac_try;; 2561 esac 2562 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\"" 2563 $as_echo "$ac_try_echo"; } >&5 2564 (eval "$ac_link") 2>conftest.err 2565 ac_status=$? 2566 if test -s conftest.err; then 2567 grep -v '^ *+' conftest.err >conftest.er1 2568 cat conftest.er1 >&5 2569 mv -f conftest.er1 conftest.err 2570 fi 2571 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 2572 test $ac_status = 0; } && { 2573 test -z "$ac_c_werror_flag" || 2574 test ! -s conftest.err 2575 } && test -s conftest$ac_exeext && { 2576 test "$cross_compiling" = yes || 2577 test -x conftest$ac_exeext 2578 }; then : 2579 ac_retval=0 2580 else 2581 $as_echo "$as_me: failed program was:" >&5 2582 sed 's/^/| /' conftest.$ac_ext >&5 2583 2584 ac_retval=1 2585 fi 2586 # Delete the IPA/IPO (Inter Procedural Analysis/Optimization) information 2587 # created by the PGI compiler (conftest_ipa8_conftest.oo), as it would 2588 # interfere with the next link command; also delete a directory that is 2589 # left behind by Apple's compiler. We do this before executing the actions. 2590 rm -rf conftest.dSYM conftest_ipa8_conftest.oo 2591 eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno 2592 as_fn_set_status $ac_retval 2593 2594 } # ac_fn_c_try_link 2595 2596 # ac_fn_cxx_check_header_mongrel LINENO HEADER VAR INCLUDES 2597 # --------------------------------------------------------- 2598 # Tests whether HEADER exists, giving a warning if it cannot be compiled using 2599 # the include files in INCLUDES and setting the cache variable VAR 2600 # accordingly. 2601 ac_fn_cxx_check_header_mongrel () 2602 { 2603 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack 2604 if eval \${$3+:} false; then : 2605 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5 2606 $as_echo_n "checking for $2... " >&6; } 2607 if eval \${$3+:} false; then : 2608 $as_echo_n "(cached) " >&6 2609 fi 2610 eval ac_res=\$$3 2611 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5 2612 $as_echo "$ac_res" >&6; } 2613 else 2614 # Is the header compilable? 2615 { $as_echo "$as_me:${as_lineno-$LINENO}: checking $2 usability" >&5 2616 $as_echo_n "checking $2 usability... " >&6; } 2617 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 2618 /* end confdefs.h. */ 2619 $4 2620 #include <$2> 2621 _ACEOF 2622 if ac_fn_cxx_try_compile "$LINENO"; then : 2623 ac_header_compiler=yes 2624 else 2625 ac_header_compiler=no 2626 fi 2627 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext 2628 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_header_compiler" >&5 2629 $as_echo "$ac_header_compiler" >&6; } 2630 2631 # Is the header present? 2632 { $as_echo "$as_me:${as_lineno-$LINENO}: checking $2 presence" >&5 2633 $as_echo_n "checking $2 presence... " >&6; } 2634 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 2635 /* end confdefs.h. */ 2636 #include <$2> 2637 _ACEOF 2638 if ac_fn_cxx_try_cpp "$LINENO"; then : 2639 ac_header_preproc=yes 2640 else 2641 ac_header_preproc=no 2642 fi 2643 rm -f conftest.err conftest.i conftest.$ac_ext 2644 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_header_preproc" >&5 2645 $as_echo "$ac_header_preproc" >&6; } 2646 2647 # So? What about this header? 2648 case $ac_header_compiler:$ac_header_preproc:$ac_cxx_preproc_warn_flag in #(( 2649 yes:no: ) 2650 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: accepted by the compiler, rejected by the preprocessor!" >&5 2651 $as_echo "$as_me: WARNING: $2: accepted by the compiler, rejected by the preprocessor!" >&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 ;; 2655 no:yes:* ) 2656 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: present but cannot be compiled" >&5 2657 $as_echo "$as_me: WARNING: $2: present but cannot be compiled" >&2;} 2658 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: check for missing prerequisite headers?" >&5 2659 $as_echo "$as_me: WARNING: $2: check for missing prerequisite headers?" >&2;} 2660 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: see the Autoconf documentation" >&5 2661 $as_echo "$as_me: WARNING: $2: see the Autoconf documentation" >&2;} 2662 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: section \"Present But Cannot Be Compiled\"" >&5 2663 $as_echo "$as_me: WARNING: $2: section \"Present But Cannot Be Compiled\"" >&2;} 2664 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: proceeding with the compiler's result" >&5 2665 $as_echo "$as_me: WARNING: $2: proceeding with the compiler's result" >&2;} 2666 ( $as_echo "## ----------------------------------------- ## 2667 ## Report this to build-dev@openjdk.java.net ## 2668 ## ----------------------------------------- ##" 2669 ) | sed "s/^/$as_me: WARNING: /" >&2 2670 ;; 2671 esac 2672 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5 2673 $as_echo_n "checking for $2... " >&6; } 2674 if eval \${$3+:} false; then : 2675 $as_echo_n "(cached) " >&6 2676 else 2677 eval "$3=\$ac_header_compiler" 2678 fi 2679 eval ac_res=\$$3 2680 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5 2681 $as_echo "$ac_res" >&6; } 2682 fi 2683 eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno 2684 2685 } # ac_fn_cxx_check_header_mongrel 2686 2687 # ac_fn_cxx_try_run LINENO 2688 # ------------------------ 2689 # Try to link conftest.$ac_ext, and return whether this succeeded. Assumes 2690 # that executables *can* be run. 2691 ac_fn_cxx_try_run () 2692 { 2693 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack 2694 if { { ac_try="$ac_link" 2695 case "(($ac_try" in 2696 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; 2697 *) ac_try_echo=$ac_try;; 2698 esac 2699 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\"" 2700 $as_echo "$ac_try_echo"; } >&5 2701 (eval "$ac_link") 2>&5 2702 ac_status=$? 2703 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 2704 test $ac_status = 0; } && { ac_try='./conftest$ac_exeext' 2705 { { case "(($ac_try" in 2706 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; 2707 *) ac_try_echo=$ac_try;; 2708 esac 2709 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\"" 2710 $as_echo "$ac_try_echo"; } >&5 2711 (eval "$ac_try") 2>&5 2712 ac_status=$? 2713 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 2714 test $ac_status = 0; }; }; then : 2715 ac_retval=0 2716 else 2717 $as_echo "$as_me: program exited with status $ac_status" >&5 2718 $as_echo "$as_me: failed program was:" >&5 2719 sed 's/^/| /' conftest.$ac_ext >&5 2720 2721 ac_retval=$ac_status 2722 fi 2723 rm -rf conftest.dSYM conftest_ipa8_conftest.oo 2724 eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno 2725 as_fn_set_status $ac_retval 2726 2727 } # ac_fn_cxx_try_run 2728 2729 # ac_fn_cxx_check_header_compile LINENO HEADER VAR INCLUDES 2730 # --------------------------------------------------------- 2731 # Tests whether HEADER exists and can be compiled using the include files in 2732 # INCLUDES, setting the cache variable VAR accordingly. 2733 ac_fn_cxx_check_header_compile () 2734 { 2735 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack 2736 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5 2737 $as_echo_n "checking for $2... " >&6; } 2738 if eval \${$3+:} false; then : 2739 $as_echo_n "(cached) " >&6 2740 else 2741 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 2742 /* end confdefs.h. */ 2743 $4 2744 #include <$2> 2745 _ACEOF 2746 if ac_fn_cxx_try_compile "$LINENO"; then : 2747 eval "$3=yes" 2748 else 2749 eval "$3=no" 2750 fi 2751 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext 2752 fi 2753 eval ac_res=\$$3 2754 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5 2755 $as_echo "$ac_res" >&6; } 2756 eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno 2757 2758 } # ac_fn_cxx_check_header_compile 2759 2760 # ac_fn_cxx_compute_int LINENO EXPR VAR INCLUDES 2761 # ---------------------------------------------- 2762 # Tries to find the compile-time value of EXPR in a program that includes 2763 # INCLUDES, setting VAR accordingly. Returns whether the value could be 2764 # computed 2765 ac_fn_cxx_compute_int () 2766 { 2767 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack 2768 if test "$cross_compiling" = yes; then 2769 # Depending upon the size, compute the lo and hi bounds. 2770 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 2771 /* end confdefs.h. */ 2772 $4 2773 int 2774 main () 2775 { 2776 static int test_array [1 - 2 * !(($2) >= 0)]; 2777 test_array [0] = 0; 2778 return test_array [0]; 2779 2780 ; 2781 return 0; 2782 } 2783 _ACEOF 2784 if ac_fn_cxx_try_compile "$LINENO"; then : 2785 ac_lo=0 ac_mid=0 2786 while :; do 2787 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 2788 /* end confdefs.h. */ 2789 $4 2790 int 2791 main () 2792 { 2793 static int test_array [1 - 2 * !(($2) <= $ac_mid)]; 2794 test_array [0] = 0; 2795 return test_array [0]; 2796 2797 ; 2798 return 0; 2799 } 2800 _ACEOF 2801 if ac_fn_cxx_try_compile "$LINENO"; then : 2802 ac_hi=$ac_mid; break 2803 else 2804 as_fn_arith $ac_mid + 1 && ac_lo=$as_val 2805 if test $ac_lo -le $ac_mid; then 2806 ac_lo= ac_hi= 2807 break 2808 fi 2809 as_fn_arith 2 '*' $ac_mid + 1 && ac_mid=$as_val 2810 fi 2811 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext 2812 done 2813 else 2814 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 2815 /* end confdefs.h. */ 2816 $4 2817 int 2818 main () 2819 { 2820 static int test_array [1 - 2 * !(($2) < 0)]; 2821 test_array [0] = 0; 2822 return test_array [0]; 2823 2824 ; 2825 return 0; 2826 } 2827 _ACEOF 2828 if ac_fn_cxx_try_compile "$LINENO"; then : 2829 ac_hi=-1 ac_mid=-1 2830 while :; do 2831 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 2832 /* end confdefs.h. */ 2833 $4 2834 int 2835 main () 2836 { 2837 static int test_array [1 - 2 * !(($2) >= $ac_mid)]; 2838 test_array [0] = 0; 2839 return test_array [0]; 2840 2841 ; 2842 return 0; 2843 } 2844 _ACEOF 2845 if ac_fn_cxx_try_compile "$LINENO"; then : 2846 ac_lo=$ac_mid; break 2847 else 2848 as_fn_arith '(' $ac_mid ')' - 1 && ac_hi=$as_val 2849 if test $ac_mid -le $ac_hi; then 2850 ac_lo= ac_hi= 2851 break 2852 fi 2853 as_fn_arith 2 '*' $ac_mid && ac_mid=$as_val 2854 fi 2855 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext 2856 done 2857 else 2858 ac_lo= ac_hi= 2859 fi 2860 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext 2861 fi 2862 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext 2863 # Binary search between lo and hi bounds. 2864 while test "x$ac_lo" != "x$ac_hi"; do 2865 as_fn_arith '(' $ac_hi - $ac_lo ')' / 2 + $ac_lo && ac_mid=$as_val 2866 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 2867 /* end confdefs.h. */ 2868 $4 2869 int 2870 main () 2871 { 2872 static int test_array [1 - 2 * !(($2) <= $ac_mid)]; 2873 test_array [0] = 0; 2874 return test_array [0]; 2875 2876 ; 2877 return 0; 2878 } 2879 _ACEOF 2880 if ac_fn_cxx_try_compile "$LINENO"; then : 2881 ac_hi=$ac_mid 2882 else 2883 as_fn_arith '(' $ac_mid ')' + 1 && ac_lo=$as_val 2884 fi 2885 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext 2886 done 2887 case $ac_lo in #(( 2888 ?*) eval "$3=\$ac_lo"; ac_retval=0 ;; 2889 '') ac_retval=1 ;; 2890 esac 2891 else 2892 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 2893 /* end confdefs.h. */ 2894 $4 2895 static long int longval () { return $2; } 2896 static unsigned long int ulongval () { return $2; } 2897 #include <stdio.h> 2898 #include <stdlib.h> 2899 int 2900 main () 2901 { 2902 2903 FILE *f = fopen ("conftest.val", "w"); 2904 if (! f) 2905 return 1; 2906 if (($2) < 0) 2907 { 2908 long int i = longval (); 2909 if (i != ($2)) 2910 return 1; 2911 fprintf (f, "%ld", i); 2912 } 2913 else 2914 { 2915 unsigned long int i = ulongval (); 2916 if (i != ($2)) 2917 return 1; 2918 fprintf (f, "%lu", i); 2919 } 2920 /* Do not output a trailing newline, as this causes \r\n confusion 2921 on some platforms. */ 2922 return ferror (f) || fclose (f) != 0; 2923 2924 ; 2925 return 0; 2926 } 2927 _ACEOF 2928 if ac_fn_cxx_try_run "$LINENO"; then : 2929 echo >>conftest.val; read $3 <conftest.val; ac_retval=0 2930 else 2931 ac_retval=1 2932 fi 2933 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \ 2934 conftest.$ac_objext conftest.beam conftest.$ac_ext 2935 rm -f conftest.val 2936 2937 fi 2938 eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno 2939 as_fn_set_status $ac_retval 2940 2941 } # ac_fn_cxx_compute_int 2942 2943 # ac_fn_cxx_try_link LINENO 2944 # ------------------------- 2945 # Try to link conftest.$ac_ext, and return whether this succeeded. 2946 ac_fn_cxx_try_link () 2947 { 2948 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack 2949 rm -f conftest.$ac_objext conftest$ac_exeext 2950 if { { ac_try="$ac_link" 2951 case "(($ac_try" in 2952 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; 2953 *) ac_try_echo=$ac_try;; 2954 esac 2955 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\"" 2956 $as_echo "$ac_try_echo"; } >&5 2957 (eval "$ac_link") 2>conftest.err 2958 ac_status=$? 2959 if test -s conftest.err; then 2960 grep -v '^ *+' conftest.err >conftest.er1 2961 cat conftest.er1 >&5 2962 mv -f conftest.er1 conftest.err 2963 fi 2964 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 2965 test $ac_status = 0; } && { 2966 test -z "$ac_cxx_werror_flag" || 2967 test ! -s conftest.err 2968 } && test -s conftest$ac_exeext && { 2969 test "$cross_compiling" = yes || 2970 test -x conftest$ac_exeext 2971 }; then : 2972 ac_retval=0 2973 else 2974 $as_echo "$as_me: failed program was:" >&5 2975 sed 's/^/| /' conftest.$ac_ext >&5 2976 2977 ac_retval=1 2978 fi 2979 # Delete the IPA/IPO (Inter Procedural Analysis/Optimization) information 2980 # created by the PGI compiler (conftest_ipa8_conftest.oo), as it would 2981 # interfere with the next link command; also delete a directory that is 2982 # left behind by Apple's compiler. We do this before executing the actions. 2983 rm -rf conftest.dSYM conftest_ipa8_conftest.oo 2984 eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno 2985 as_fn_set_status $ac_retval 2986 2987 } # ac_fn_cxx_try_link 2988 2989 # ac_fn_cxx_check_func LINENO FUNC VAR 2990 # ------------------------------------ 2991 # Tests whether FUNC exists, setting the cache variable VAR accordingly 2992 ac_fn_cxx_check_func () 2993 { 2994 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack 2995 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5 2996 $as_echo_n "checking for $2... " >&6; } 2997 if eval \${$3+:} false; then : 2998 $as_echo_n "(cached) " >&6 2999 else 3000 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 3001 /* end confdefs.h. */ 3002 /* Define $2 to an innocuous variant, in case <limits.h> declares $2. 3003 For example, HP-UX 11i <limits.h> declares gettimeofday. */ 3004 #define $2 innocuous_$2 3005 3006 /* System header to define __stub macros and hopefully few prototypes, 3007 which can conflict with char $2 (); below. 3008 Prefer <limits.h> to <assert.h> if __STDC__ is defined, since 3009 <limits.h> exists even on freestanding compilers. */ 3010 3011 #ifdef __STDC__ 3012 # include <limits.h> 3013 #else 3014 # include <assert.h> 3015 #endif 3016 3017 #undef $2 3018 3019 /* Override any GCC internal prototype to avoid an error. 3020 Use char because int might match the return type of a GCC 3021 builtin and then its argument prototype would still apply. */ 3022 #ifdef __cplusplus 3023 extern "C" 3024 #endif 3025 char $2 (); 3026 /* The GNU C library defines this for functions which it implements 3027 to always fail with ENOSYS. Some functions are actually named 3028 something starting with __ and the normal name is an alias. */ 3029 #if defined __stub_$2 || defined __stub___$2 3030 choke me 3031 #endif 3032 3033 int 3034 main () 3035 { 3036 return $2 (); 3037 ; 3038 return 0; 3039 } 3040 _ACEOF 3041 if ac_fn_cxx_try_link "$LINENO"; then : 3042 eval "$3=yes" 3043 else 3044 eval "$3=no" 3045 fi 3046 rm -f core conftest.err conftest.$ac_objext \ 3047 conftest$ac_exeext conftest.$ac_ext 3048 fi 3049 eval ac_res=\$$3 3050 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5 3051 $as_echo "$ac_res" >&6; } 3052 eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno 3053 3054 } # ac_fn_cxx_check_func 3055 3056 # ac_fn_c_check_header_compile LINENO HEADER VAR INCLUDES 3057 # ------------------------------------------------------- 3058 # Tests whether HEADER exists and can be compiled using the include files in 3059 # INCLUDES, setting the cache variable VAR accordingly. 3060 ac_fn_c_check_header_compile () 3061 { 3062 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack 3063 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5 3064 $as_echo_n "checking for $2... " >&6; } 3065 if eval \${$3+:} false; then : 3066 $as_echo_n "(cached) " >&6 3067 else 3068 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 3069 /* end confdefs.h. */ 3070 $4 3071 #include <$2> 3072 _ACEOF 3073 if ac_fn_c_try_compile "$LINENO"; then : 3074 eval "$3=yes" 3075 else 3076 eval "$3=no" 3077 fi 3078 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext 3079 fi 3080 eval ac_res=\$$3 3081 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5 3082 $as_echo "$ac_res" >&6; } 3083 eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno 3084 3085 } # ac_fn_c_check_header_compile 3086 cat >config.log <<_ACEOF 3087 This file contains any messages produced by compilers while 3088 running configure, to aid debugging if configure makes a mistake. 3089 3090 It was created by OpenJDK $as_me jdk9, which was 3091 generated by GNU Autoconf 2.69. Invocation command line was 3092 3093 $ $0 $@ 3094 3095 _ACEOF 3096 exec 5>>config.log 3097 { 3098 cat <<_ASUNAME 3099 ## --------- ## 3100 ## Platform. ## 3101 ## --------- ## 3102 3103 hostname = `(hostname || uname -n) 2>/dev/null | sed 1q` 3104 uname -m = `(uname -m) 2>/dev/null || echo unknown` 3105 uname -r = `(uname -r) 2>/dev/null || echo unknown` 3106 uname -s = `(uname -s) 2>/dev/null || echo unknown` 3107 uname -v = `(uname -v) 2>/dev/null || echo unknown` 3108 3109 /usr/bin/uname -p = `(/usr/bin/uname -p) 2>/dev/null || echo unknown` 3110 /bin/uname -X = `(/bin/uname -X) 2>/dev/null || echo unknown` 3111 3112 /bin/arch = `(/bin/arch) 2>/dev/null || echo unknown` 3113 /usr/bin/arch -k = `(/usr/bin/arch -k) 2>/dev/null || echo unknown` 3114 /usr/convex/getsysinfo = `(/usr/convex/getsysinfo) 2>/dev/null || echo unknown` 3115 /usr/bin/hostinfo = `(/usr/bin/hostinfo) 2>/dev/null || echo unknown` 3116 /bin/machine = `(/bin/machine) 2>/dev/null || echo unknown` 3117 /usr/bin/oslevel = `(/usr/bin/oslevel) 2>/dev/null || echo unknown` 3118 /bin/universe = `(/bin/universe) 2>/dev/null || echo unknown` 3119 3120 _ASUNAME 3121 3122 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 3123 for as_dir in $PATH 3124 do 3125 IFS=$as_save_IFS 3126 test -z "$as_dir" && as_dir=. 3127 $as_echo "PATH: $as_dir" 3128 done 3129 IFS=$as_save_IFS 3130 3131 } >&5 3132 3133 cat >&5 <<_ACEOF 3134 3135 3136 ## ----------- ## 3137 ## Core tests. ## 3138 ## ----------- ## 3139 3140 _ACEOF 3141 3142 3143 # Keep a trace of the command line. 3144 # Strip out --no-create and --no-recursion so they do not pile up. 3145 # Strip out --silent because we don't want to record it for future runs. 3146 # Also quote any args containing shell meta-characters. 3147 # Make two passes to allow for proper duplicate-argument suppression. 3148 ac_configure_args= 3149 ac_configure_args0= 3150 ac_configure_args1= 3151 ac_must_keep_next=false 3152 for ac_pass in 1 2 3153 do 3154 for ac_arg 3155 do 3156 case $ac_arg in 3157 -no-create | --no-c* | -n | -no-recursion | --no-r*) continue ;; 3158 -q | -quiet | --quiet | --quie | --qui | --qu | --q \ 3159 | -silent | --silent | --silen | --sile | --sil) 3160 continue ;; 3161 *\'*) 3162 ac_arg=`$as_echo "$ac_arg" | sed "s/'/'\\\\\\\\''/g"` ;; 3163 esac 3164 case $ac_pass in 3165 1) as_fn_append ac_configure_args0 " '$ac_arg'" ;; 3166 2) 3167 as_fn_append ac_configure_args1 " '$ac_arg'" 3168 if test $ac_must_keep_next = true; then 3169 ac_must_keep_next=false # Got value, back to normal. 3170 else 3171 case $ac_arg in 3172 *=* | --config-cache | -C | -disable-* | --disable-* \ 3173 | -enable-* | --enable-* | -gas | --g* | -nfp | --nf* \ 3174 | -q | -quiet | --q* | -silent | --sil* | -v | -verb* \ 3175 | -with-* | --with-* | -without-* | --without-* | --x) 3176 case "$ac_configure_args0 " in 3177 "$ac_configure_args1"*" '$ac_arg' "* ) continue ;; 3178 esac 3179 ;; 3180 -* ) ac_must_keep_next=true ;; 3181 esac 3182 fi 3183 as_fn_append ac_configure_args " '$ac_arg'" 3184 ;; 3185 esac 3186 done 3187 done 3188 { ac_configure_args0=; unset ac_configure_args0;} 3189 { ac_configure_args1=; unset ac_configure_args1;} 3190 3191 # When interrupted or exit'd, cleanup temporary files, and complete 3192 # config.log. We remove comments because anyway the quotes in there 3193 # would cause problems or look ugly. 3194 # WARNING: Use '\'' to represent an apostrophe within the trap. 3195 # WARNING: Do not start the trap code with a newline, due to a FreeBSD 4.0 bug. 3196 trap 'exit_status=$? 3197 # Save into config.log some information that might help in debugging. 3198 { 3199 echo 3200 3201 $as_echo "## ---------------- ## 3202 ## Cache variables. ## 3203 ## ---------------- ##" 3204 echo 3205 # The following way of writing the cache mishandles newlines in values, 3206 ( 3207 for ac_var in `(set) 2>&1 | sed -n '\''s/^\([a-zA-Z_][a-zA-Z0-9_]*\)=.*/\1/p'\''`; do 3208 eval ac_val=\$$ac_var 3209 case $ac_val in #( 3210 *${as_nl}*) 3211 case $ac_var in #( 3212 *_cv_*) { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: cache variable $ac_var contains a newline" >&5 3213 $as_echo "$as_me: WARNING: cache variable $ac_var contains a newline" >&2;} ;; 3214 esac 3215 case $ac_var in #( 3216 _ | IFS | as_nl) ;; #( 3217 BASH_ARGV | BASH_SOURCE) eval $ac_var= ;; #( 3218 *) { eval $ac_var=; unset $ac_var;} ;; 3219 esac ;; 3220 esac 3221 done 3222 (set) 2>&1 | 3223 case $as_nl`(ac_space='\'' '\''; set) 2>&1` in #( 3224 *${as_nl}ac_space=\ *) 3225 sed -n \ 3226 "s/'\''/'\''\\\\'\'''\''/g; 3227 s/^\\([_$as_cr_alnum]*_cv_[_$as_cr_alnum]*\\)=\\(.*\\)/\\1='\''\\2'\''/p" 3228 ;; #( 3229 *) 3230 sed -n "/^[_$as_cr_alnum]*_cv_[_$as_cr_alnum]*=/p" 3231 ;; 3232 esac | 3233 sort 3234 ) 3235 echo 3236 3237 $as_echo "## ----------------- ## 3238 ## Output variables. ## 3239 ## ----------------- ##" 3240 echo 3241 for ac_var in $ac_subst_vars 3242 do 3243 eval ac_val=\$$ac_var 3244 case $ac_val in 3245 *\'\''*) ac_val=`$as_echo "$ac_val" | sed "s/'\''/'\''\\\\\\\\'\'''\''/g"`;; 3246 esac 3247 $as_echo "$ac_var='\''$ac_val'\''" 3248 done | sort 3249 echo 3250 3251 if test -n "$ac_subst_files"; then 3252 $as_echo "## ------------------- ## 3253 ## File substitutions. ## 3254 ## ------------------- ##" 3255 echo 3256 for ac_var in $ac_subst_files 3257 do 3258 eval ac_val=\$$ac_var 3259 case $ac_val in 3260 *\'\''*) ac_val=`$as_echo "$ac_val" | sed "s/'\''/'\''\\\\\\\\'\'''\''/g"`;; 3261 esac 3262 $as_echo "$ac_var='\''$ac_val'\''" 3263 done | sort 3264 echo 3265 fi 3266 3267 if test -s confdefs.h; then 3268 $as_echo "## ----------- ## 3269 ## confdefs.h. ## 3270 ## ----------- ##" 3271 echo 3272 cat confdefs.h 3273 echo 3274 fi 3275 test "$ac_signal" != 0 && 3276 $as_echo "$as_me: caught signal $ac_signal" 3277 $as_echo "$as_me: exit $exit_status" 3278 } >&5 3279 rm -f core *.core core.conftest.* && 3280 rm -f -r conftest* confdefs* conf$$* $ac_clean_files && 3281 exit $exit_status 3282 ' 0 3283 for ac_signal in 1 2 13 15; do 3284 trap 'ac_signal='$ac_signal'; as_fn_exit 1' $ac_signal 3285 done 3286 ac_signal=0 3287 3288 # confdefs.h avoids OS command line length limits that DEFS can exceed. 3289 rm -f -r conftest* confdefs.h 3290 3291 $as_echo "/* confdefs.h */" > confdefs.h 3292 3293 # Predefined preprocessor variables. 3294 3295 cat >>confdefs.h <<_ACEOF 3296 #define PACKAGE_NAME "$PACKAGE_NAME" 3297 _ACEOF 3298 3299 cat >>confdefs.h <<_ACEOF 3300 #define PACKAGE_TARNAME "$PACKAGE_TARNAME" 3301 _ACEOF 3302 3303 cat >>confdefs.h <<_ACEOF 3304 #define PACKAGE_VERSION "$PACKAGE_VERSION" 3305 _ACEOF 3306 3307 cat >>confdefs.h <<_ACEOF 3308 #define PACKAGE_STRING "$PACKAGE_STRING" 3309 _ACEOF 3310 3311 cat >>confdefs.h <<_ACEOF 3312 #define PACKAGE_BUGREPORT "$PACKAGE_BUGREPORT" 3313 _ACEOF 3314 3315 cat >>confdefs.h <<_ACEOF 3316 #define PACKAGE_URL "$PACKAGE_URL" 3317 _ACEOF 3318 3319 3320 # Let the site file select an alternate cache file if it wants to. 3321 # Prefer an explicitly selected file to automatically selected ones. 3322 ac_site_file1=NONE 3323 ac_site_file2=NONE 3324 if test -n "$CONFIG_SITE"; then 3325 # We do not want a PATH search for config.site. 3326 case $CONFIG_SITE in #(( 3327 -*) ac_site_file1=./$CONFIG_SITE;; 3328 */*) ac_site_file1=$CONFIG_SITE;; 3329 *) ac_site_file1=./$CONFIG_SITE;; 3330 esac 3331 elif test "x$prefix" != xNONE; then 3332 ac_site_file1=$prefix/share/config.site 3333 ac_site_file2=$prefix/etc/config.site 3334 else 3335 ac_site_file1=$ac_default_prefix/share/config.site 3336 ac_site_file2=$ac_default_prefix/etc/config.site 3337 fi 3338 for ac_site_file in "$ac_site_file1" "$ac_site_file2" 3339 do 3340 test "x$ac_site_file" = xNONE && continue 3341 if test /dev/null != "$ac_site_file" && test -r "$ac_site_file"; then 3342 { $as_echo "$as_me:${as_lineno-$LINENO}: loading site script $ac_site_file" >&5 3343 $as_echo "$as_me: loading site script $ac_site_file" >&6;} 3344 sed 's/^/| /' "$ac_site_file" >&5 3345 . "$ac_site_file" \ 3346 || { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 3347 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;} 3348 as_fn_error $? "failed to load site script $ac_site_file 3349 See \`config.log' for more details" "$LINENO" 5; } 3350 fi 3351 done 3352 3353 if test -r "$cache_file"; then 3354 # Some versions of bash will fail to source /dev/null (special files 3355 # actually), so we avoid doing that. DJGPP emulates it as a regular file. 3356 if test /dev/null != "$cache_file" && test -f "$cache_file"; then 3357 { $as_echo "$as_me:${as_lineno-$LINENO}: loading cache $cache_file" >&5 3358 $as_echo "$as_me: loading cache $cache_file" >&6;} 3359 case $cache_file in 3360 [\\/]* | ?:[\\/]* ) . "$cache_file";; 3361 *) . "./$cache_file";; 3362 esac 3363 fi 3364 else 3365 { $as_echo "$as_me:${as_lineno-$LINENO}: creating cache $cache_file" >&5 3366 $as_echo "$as_me: creating cache $cache_file" >&6;} 3367 >$cache_file 3368 fi 3369 3370 # Check that the precious variables saved in the cache have kept the same 3371 # value. 3372 ac_cache_corrupted=false 3373 for ac_var in $ac_precious_vars; do 3374 eval ac_old_set=\$ac_cv_env_${ac_var}_set 3375 eval ac_new_set=\$ac_env_${ac_var}_set 3376 eval ac_old_val=\$ac_cv_env_${ac_var}_value 3377 eval ac_new_val=\$ac_env_${ac_var}_value 3378 case $ac_old_set,$ac_new_set in 3379 set,) 3380 { $as_echo "$as_me:${as_lineno-$LINENO}: error: \`$ac_var' was set to \`$ac_old_val' in the previous run" >&5 3381 $as_echo "$as_me: error: \`$ac_var' was set to \`$ac_old_val' in the previous run" >&2;} 3382 ac_cache_corrupted=: ;; 3383 ,set) 3384 { $as_echo "$as_me:${as_lineno-$LINENO}: error: \`$ac_var' was not set in the previous run" >&5 3385 $as_echo "$as_me: error: \`$ac_var' was not set in the previous run" >&2;} 3386 ac_cache_corrupted=: ;; 3387 ,);; 3388 *) 3389 if test "x$ac_old_val" != "x$ac_new_val"; then 3390 # differences in whitespace do not lead to failure. 3391 ac_old_val_w=`echo x $ac_old_val` 3392 ac_new_val_w=`echo x $ac_new_val` 3393 if test "$ac_old_val_w" != "$ac_new_val_w"; then 3394 { $as_echo "$as_me:${as_lineno-$LINENO}: error: \`$ac_var' has changed since the previous run:" >&5 3395 $as_echo "$as_me: error: \`$ac_var' has changed since the previous run:" >&2;} 3396 ac_cache_corrupted=: 3397 else 3398 { $as_echo "$as_me:${as_lineno-$LINENO}: warning: ignoring whitespace changes in \`$ac_var' since the previous run:" >&5 3399 $as_echo "$as_me: warning: ignoring whitespace changes in \`$ac_var' since the previous run:" >&2;} 3400 eval $ac_var=\$ac_old_val 3401 fi 3402 { $as_echo "$as_me:${as_lineno-$LINENO}: former value: \`$ac_old_val'" >&5 3403 $as_echo "$as_me: former value: \`$ac_old_val'" >&2;} 3404 { $as_echo "$as_me:${as_lineno-$LINENO}: current value: \`$ac_new_val'" >&5 3405 $as_echo "$as_me: current value: \`$ac_new_val'" >&2;} 3406 fi;; 3407 esac 3408 # Pass precious variables to config.status. 3409 if test "$ac_new_set" = set; then 3410 case $ac_new_val in 3411 *\'*) ac_arg=$ac_var=`$as_echo "$ac_new_val" | sed "s/'/'\\\\\\\\''/g"` ;; 3412 *) ac_arg=$ac_var=$ac_new_val ;; 3413 esac 3414 case " $ac_configure_args " in 3415 *" '$ac_arg' "*) ;; # Avoid dups. Use of quotes ensures accuracy. 3416 *) as_fn_append ac_configure_args " '$ac_arg'" ;; 3417 esac 3418 fi 3419 done 3420 if $ac_cache_corrupted; then 3421 { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 3422 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;} 3423 { $as_echo "$as_me:${as_lineno-$LINENO}: error: changes in the environment can compromise the build" >&5 3424 $as_echo "$as_me: error: changes in the environment can compromise the build" >&2;} 3425 as_fn_error $? "run \`make distclean' and/or \`rm $cache_file' and start over" "$LINENO" 5 3426 fi 3427 ## -------------------- ## 3428 ## Main body of script. ## 3429 ## -------------------- ## 3430 3431 ac_ext=c 3432 ac_cpp='$CPP $CPPFLAGS' 3433 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5' 3434 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' 3435 ac_compiler_gnu=$ac_cv_c_compiler_gnu 3436 3437 3438 3439 ac_aux_dir= 3440 for ac_dir in $TOPDIR/make/autoconf/build-aux "$srcdir"/$TOPDIR/make/autoconf/build-aux; do 3441 if test -f "$ac_dir/install-sh"; then 3442 ac_aux_dir=$ac_dir 3443 ac_install_sh="$ac_aux_dir/install-sh -c" 3444 break 3445 elif test -f "$ac_dir/install.sh"; then 3446 ac_aux_dir=$ac_dir 3447 ac_install_sh="$ac_aux_dir/install.sh -c" 3448 break 3449 elif test -f "$ac_dir/shtool"; then 3450 ac_aux_dir=$ac_dir 3451 ac_install_sh="$ac_aux_dir/shtool install -c" 3452 break 3453 fi 3454 done 3455 if test -z "$ac_aux_dir"; then 3456 as_fn_error $? "cannot find install-sh, install.sh, or shtool in $TOPDIR/make/autoconf/build-aux \"$srcdir\"/$TOPDIR/make/autoconf/build-aux" "$LINENO" 5 3457 fi 3458 3459 # These three variables are undocumented and unsupported, 3460 # and are intended to be withdrawn in a future Autoconf release. 3461 # They can cause serious problems if a builder's source tree is in a directory 3462 # whose full name contains unusual characters. 3463 ac_config_guess="$SHELL $ac_aux_dir/config.guess" # Please don't use this var. 3464 ac_config_sub="$SHELL $ac_aux_dir/config.sub" # Please don't use this var. 3465 ac_configure="$SHELL $ac_aux_dir/configure" # Please don't use this var. 3466 3467 3468 # pkg.m4 - Macros to locate and utilise pkg-config. -*- Autoconf -*- 3469 3470 # 3471 # Copyright (c) 2012, 2013, Oracle and/or its affiliates. All rights reserved. 3472 # DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. 3473 # 3474 # This code is free software; you can redistribute it and/or modify it 3475 # under the terms of the GNU General Public License version 2 only, as 3476 # published by the Free Software Foundation. Oracle designates this 3477 # particular file as subject to the "Classpath" exception as provided 3478 # by Oracle in the LICENSE file that accompanied this code. 3479 # 3480 # This code is distributed in the hope that it will be useful, but WITHOUT 3481 # ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or 3482 # FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License 3483 # version 2 for more details (a copy is included in the LICENSE file that 3484 # accompanied this code). 3485 # 3486 # You should have received a copy of the GNU General Public License version 3487 # 2 along with this work; if not, write to the Free Software Foundation, 3488 # Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. 3489 # 3490 # Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA 3491 # or visit www.oracle.com if you need additional information or have any 3492 # questions. 3493 # 3494 3495 # 3496 # Copyright © 2004 Scott James Remnant <scott@netsplit.com>. 3497 # 3498 # This program is free software; you can redistribute it and/or modify 3499 # it under the terms of the GNU General Public License as published by 3500 # the Free Software Foundation; either version 2 of the License, or 3501 # (at your option) any later version. 3502 # 3503 # This program is distributed in the hope that it will be useful, but 3504 # WITHOUT ANY WARRANTY; without even the implied warranty of 3505 # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU 3506 # General Public License for more details. 3507 # 3508 # You should have received a copy of the GNU General Public License 3509 # along with this program; if not, write to the Free Software 3510 # Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. 3511 # 3512 # As a special exception to the GNU General Public License, if you 3513 # distribute this file as part of a program that contains a 3514 # configuration script generated by Autoconf, you may include it under 3515 # the same distribution terms that you use for the rest of that program. 3516 3517 # PKG_PROG_PKG_CONFIG([MIN-VERSION]) 3518 # ---------------------------------- 3519 # PKG_PROG_PKG_CONFIG 3520 3521 # PKG_CHECK_EXISTS(MODULES, [ACTION-IF-FOUND], [ACTION-IF-NOT-FOUND]) 3522 # 3523 # Check to see whether a particular set of modules exists. Similar 3524 # to PKG_CHECK_MODULES(), but does not set variables or print errors. 3525 # 3526 # 3527 # Similar to PKG_CHECK_MODULES, make sure that the first instance of 3528 # this or PKG_CHECK_MODULES is called, or make sure to call 3529 # PKG_CHECK_EXISTS manually 3530 # -------------------------------------------------------------- 3531 3532 3533 3534 # _PKG_CONFIG([VARIABLE], [COMMAND], [MODULES]) 3535 # --------------------------------------------- 3536 # _PKG_CONFIG 3537 3538 # _PKG_SHORT_ERRORS_SUPPORTED 3539 # ----------------------------- 3540 # _PKG_SHORT_ERRORS_SUPPORTED 3541 3542 3543 # PKG_CHECK_MODULES(VARIABLE-PREFIX, MODULES, [ACTION-IF-FOUND], 3544 # [ACTION-IF-NOT-FOUND]) 3545 # 3546 # 3547 # Note that if there is a possibility the first call to 3548 # PKG_CHECK_MODULES might not happen, you should be sure to include an 3549 # explicit call to PKG_PROG_PKG_CONFIG in your configure.ac 3550 # 3551 # 3552 # -------------------------------------------------------------- 3553 # PKG_CHECK_MODULES 3554 3555 3556 # Include these first... 3557 # 3558 # Copyright (c) 2011, 2017, Oracle and/or its affiliates. All rights reserved. 3559 # DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. 3560 # 3561 # This code is free software; you can redistribute it and/or modify it 3562 # under the terms of the GNU General Public License version 2 only, as 3563 # published by the Free Software Foundation. Oracle designates this 3564 # particular file as subject to the "Classpath" exception as provided 3565 # by Oracle in the LICENSE file that accompanied this code. 3566 # 3567 # This code is distributed in the hope that it will be useful, but WITHOUT 3568 # ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or 3569 # FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License 3570 # version 2 for more details (a copy is included in the LICENSE file that 3571 # accompanied this code). 3572 # 3573 # You should have received a copy of the GNU General Public License version 3574 # 2 along with this work; if not, write to the Free Software Foundation, 3575 # Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. 3576 # 3577 # Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA 3578 # or visit www.oracle.com if you need additional information or have any 3579 # questions. 3580 # 3581 3582 # Create a function/macro that takes a series of named arguments. The call is 3583 # similar to AC_DEFUN, but the setup of the function looks like this: 3584 # BASIC_DEFUN_NAMED([MYFUNC], [FOO *BAR], [$@], [ 3585 # ... do something 3586 # AC_MSG_NOTICE([Value of BAR is ARG_BAR]) 3587 # ]) 3588 # A star (*) in front of a named argument means that it is required and it's 3589 # presence will be verified. To pass e.g. the first value as a normal indexed 3590 # argument, use [m4_shift($@)] as the third argument instead of [$@]. These 3591 # arguments are referenced in the function by their name prefixed by ARG_, e.g. 3592 # "ARG_FOO". 3593 # 3594 # The generated function can be called like this: 3595 # MYFUNC(FOO: [foo-val], 3596 # BAR: [ 3597 # $ECHO hello world 3598 # ]) 3599 # Note that the argument value must start on the same line as the argument name. 3600 # 3601 # Argument 1: Name of the function to define 3602 # Argument 2: List of legal named arguments, with a * prefix for required arguments 3603 # Argument 3: Argument array to treat as named, typically $@ 3604 # Argument 4: The main function body 3605 3606 3607 # Test if $1 is a valid argument to $3 (often is $JAVA passed as $3) 3608 # If so, then append $1 to $2 \ 3609 # Also set JVM_ARG_OK to true/false depending on outcome. 3610 3611 3612 # Appends a string to a path variable, only adding the : when needed. 3613 3614 3615 # Prepends a string to a path variable, only adding the : when needed. 3616 3617 3618 # This will make sure the given variable points to a full and proper 3619 # path. This means: 3620 # 1) There will be no spaces in the path. On unix platforms, 3621 # spaces in the path will result in an error. On Windows, 3622 # the path will be rewritten using short-style to be space-free. 3623 # 2) The path will be absolute, and it will be in unix-style (on 3624 # cygwin). 3625 # $1: The name of the variable to fix 3626 3627 3628 # This will make sure the given variable points to a executable 3629 # with a full and proper path. This means: 3630 # 1) There will be no spaces in the path. On unix platforms, 3631 # spaces in the path will result in an error. On Windows, 3632 # the path will be rewritten using short-style to be space-free. 3633 # 2) The path will be absolute, and it will be in unix-style (on 3634 # cygwin). 3635 # Any arguments given to the executable is preserved. 3636 # If the input variable does not have a directory specification, then 3637 # it need to be in the PATH. 3638 # $1: The name of the variable to fix 3639 3640 3641 3642 3643 # Register a --with argument but mark it as deprecated 3644 # $1: The name of the with argument to deprecate, not including --with- 3645 3646 3647 # Register a --enable argument but mark it as deprecated 3648 # $1: The name of the with argument to deprecate, not including --enable- 3649 # $2: The name of the argument to deprecate, in shell variable style (i.e. with _ instead of -) 3650 # $3: Messages to user. 3651 3652 3653 3654 3655 # Test that variable $1 denoting a program is not empty. If empty, exit with an error. 3656 # $1: variable to check 3657 3658 3659 # Check that there are no unprocessed overridden variables left. 3660 # If so, they are an incorrect argument and we will exit with an error. 3661 3662 3663 # Setup a tool for the given variable. If correctly specified by the user, 3664 # use that value, otherwise search for the tool using the supplied code snippet. 3665 # $1: variable to set 3666 # $2: code snippet to call to look for the tool 3667 # $3: code snippet to call if variable was used to find tool 3668 3669 3670 # Call BASIC_SETUP_TOOL with AC_PATH_PROGS to locate the tool 3671 # $1: variable to set 3672 # $2: executable name (or list of names) to look for 3673 # $3: [path] 3674 3675 3676 # Call BASIC_SETUP_TOOL with AC_CHECK_TOOLS to locate the tool 3677 # $1: variable to set 3678 # $2: executable name (or list of names) to look for 3679 3680 3681 # Like BASIC_PATH_PROGS but fails if no tool was found. 3682 # $1: variable to set 3683 # $2: executable name (or list of names) to look for 3684 # $3: [path] 3685 3686 3687 # Like BASIC_SETUP_TOOL but fails if no tool was found. 3688 # $1: variable to set 3689 # $2: autoconf macro to call to look for the special tool 3690 3691 3692 # Setup the most fundamental tools that relies on not much else to set up, 3693 # but is used by much of the early bootstrap code. 3694 3695 3696 # Setup basic configuration paths, and platform-specific stuff related to PATHs. 3697 3698 3699 # Evaluates platform specific overrides for devkit variables. 3700 # $1: Name of variable 3701 3702 3703 3704 3705 3706 3707 #%%% Simple tools %%% 3708 3709 # Check if we have found a usable version of make 3710 # $1: the path to a potential make binary (or empty) 3711 # $2: the description on how we found this 3712 3713 3714 3715 3716 # Goes looking for a usable version of GNU make. 3717 3718 3719 3720 3721 3722 3723 3724 3725 3726 3727 # Check if build directory is on local disk. If not possible to determine, 3728 # we prefer to claim it's local. 3729 # Argument 1: directory to test 3730 # Argument 2: what to do if it is on local disk 3731 # Argument 3: what to do otherwise (remote disk or failure) 3732 3733 3734 # Check that source files have basic read permissions set. This might 3735 # not be the case in cygwin in certain conditions. 3736 3737 3738 3739 3740 # Check for support for specific options in bash 3741 3742 3743 ################################################################################ 3744 # 3745 # Default make target 3746 # 3747 3748 3749 # Code to run after AC_OUTPUT 3750 3751 3752 # 3753 # Copyright (c) 2011, 2016, Oracle and/or its affiliates. All rights reserved. 3754 # DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. 3755 # 3756 # This code is free software; you can redistribute it and/or modify it 3757 # under the terms of the GNU General Public License version 2 only, as 3758 # published by the Free Software Foundation. Oracle designates this 3759 # particular file as subject to the "Classpath" exception as provided 3760 # by Oracle in the LICENSE file that accompanied this code. 3761 # 3762 # This code is distributed in the hope that it will be useful, but WITHOUT 3763 # ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or 3764 # FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License 3765 # version 2 for more details (a copy is included in the LICENSE file that 3766 # accompanied this code). 3767 # 3768 # You should have received a copy of the GNU General Public License version 3769 # 2 along with this work; if not, write to the Free Software Foundation, 3770 # Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. 3771 # 3772 # Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA 3773 # or visit www.oracle.com if you need additional information or have any 3774 # questions. 3775 # 3776 3777 3778 3779 3780 3781 # Helper function which possibly converts a path using DOS-style short mode. 3782 # If so, the updated path is stored in $new_path. 3783 # $1: The path to check 3784 3785 3786 # Helper function which possibly converts a path using DOS-style short mode. 3787 # If so, the updated path is stored in $new_path. 3788 # $1: The path to check 3789 3790 3791 # FIXME: The BASIC_FIXUP_*_CYGWIN/MSYS is most likely too convoluted 3792 # and could probably be heavily simplified. However, all changes in this 3793 # area tend to need lot of testing in different scenarios, and in lack of 3794 # proper unit testing, cleaning this up has not been deemed worth the effort 3795 # at the moment. 3796 3797 3798 3799 3800 3801 3802 3803 3804 3805 # Setup basic configuration paths, and platform-specific stuff related to PATHs. 3806 3807 3808 3809 3810 # ... then the rest 3811 # 3812 # Copyright (c) 2011, 2017, Oracle and/or its affiliates. All rights reserved. 3813 # DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. 3814 # 3815 # This code is free software; you can redistribute it and/or modify it 3816 # under the terms of the GNU General Public License version 2 only, as 3817 # published by the Free Software Foundation. Oracle designates this 3818 # particular file as subject to the "Classpath" exception as provided 3819 # by Oracle in the LICENSE file that accompanied this code. 3820 # 3821 # This code is distributed in the hope that it will be useful, but WITHOUT 3822 # ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or 3823 # FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License 3824 # version 2 for more details (a copy is included in the LICENSE file that 3825 # accompanied this code). 3826 # 3827 # You should have received a copy of the GNU General Public License version 3828 # 2 along with this work; if not, write to the Free Software Foundation, 3829 # Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. 3830 # 3831 # Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA 3832 # or visit www.oracle.com if you need additional information or have any 3833 # questions. 3834 # 3835 3836 ######################################################################## 3837 # This file handles detection of the Boot JDK. The Boot JDK detection 3838 # process has been developed as a response to solve a complex real-world 3839 # problem. Initially, it was simple, but it has grown as platform after 3840 # platform, idiosyncracy after idiosyncracy has been supported. 3841 # 3842 # The basic idea is this: 3843 # 1) You need an acceptable *) JDK to use as a Boot JDK 3844 # 2) There are several ways to locate a JDK, that are mostly platform 3845 # dependent **) 3846 # 3) You can have multiple JDKs installed 3847 # 4) If possible, configure should try to dig out an acceptable JDK 3848 # automatically, without having to resort to command-line options 3849 # 3850 # *) acceptable means e.g. JDK7 for building JDK8, a complete JDK (with 3851 # javac) and not a JRE, etc. 3852 # 3853 # **) On Windows we typically use a well-known path. 3854 # On MacOSX we typically use the tool java_home. 3855 # On Linux we typically find javac in the $PATH, and then follow a 3856 # chain of symlinks that often ends up in a real JDK. 3857 # 3858 # This leads to the code where we check in different ways to locate a 3859 # JDK, and if one is found, check if it is acceptable. If not, we print 3860 # our reasons for rejecting it (useful when debugging non-working 3861 # configure situations) and continue checking the next one. 3862 ######################################################################## 3863 3864 # Execute the check given as argument, and verify the result 3865 # If the Boot JDK was previously found, do nothing 3866 # $1 A command line (typically autoconf macro) to execute 3867 3868 3869 # Test: Is bootjdk explicitly set by command line arguments? 3870 3871 3872 # Test: Is $JAVA_HOME set? 3873 3874 3875 # Test: Is there a java or javac in the PATH, which is a symlink to the JDK? 3876 3877 3878 # Test: Is there a /usr/libexec/java_home? (Typically on MacOSX) 3879 # $1: Argument to the java_home binary (optional) 3880 3881 3882 # Test: On MacOS X, can we find a boot jdk using /usr/libexec/java_home? 3883 3884 3885 # Look for a jdk in the given path. If there are multiple, try to select the newest. 3886 # If found, set BOOT_JDK and BOOT_JDK_FOUND. 3887 # $1 = Path to directory containing jdk installations. 3888 # $2 = String to append to the found JDK directory to get the proper JDK home 3889 3890 3891 # Call BOOTJDK_FIND_BEST_JDK_IN_DIRECTORY, but use the given 3892 # environmental variable as base for where to look. 3893 # $1 Name of an environmal variable, assumed to point to the Program Files directory. 3894 3895 3896 # Test: Is there a JDK installed in default, well-known locations? 3897 3898 3899 # Check that a command-line tool in the Boot JDK is correct 3900 # $1 = name of variable to assign 3901 # $2 = name of binary 3902 3903 3904 ############################################################################### 3905 # 3906 # We need a Boot JDK to bootstrap the build. 3907 # 3908 3909 3910 3911 3912 3913 # BUILD_JDK: the location of the latest JDK that can run 3914 # on the host system and supports the target class file version 3915 # generated in this JDK build. This variable should only be 3916 # used after the launchers are built. 3917 # 3918 3919 # Execute the check given as argument, and verify the result. 3920 # If the JDK was previously found, do nothing. 3921 # $1 A command line (typically autoconf macro) to execute 3922 3923 3924 # By default the BUILD_JDK is the JDK_OUTPUTDIR. If the target architecture 3925 # is different than the host system doing the build (e.g. cross-compilation), 3926 # a special BUILD_JDK is built as part of the build process. An external 3927 # prebuilt BUILD_JDK can also be supplied. 3928 3929 3930 # 3931 # Copyright (c) 2011, 2016, Oracle and/or its affiliates. All rights reserved. 3932 # DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. 3933 # 3934 # This code is free software; you can redistribute it and/or modify it 3935 # under the terms of the GNU General Public License version 2 only, as 3936 # published by the Free Software Foundation. Oracle designates this 3937 # particular file as subject to the "Classpath" exception as provided 3938 # by Oracle in the LICENSE file that accompanied this code. 3939 # 3940 # This code is distributed in the hope that it will be useful, but WITHOUT 3941 # ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or 3942 # FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License 3943 # version 2 for more details (a copy is included in the LICENSE file that 3944 # accompanied this code). 3945 # 3946 # You should have received a copy of the GNU General Public License version 3947 # 2 along with this work; if not, write to the Free Software Foundation, 3948 # Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. 3949 # 3950 # Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA 3951 # or visit www.oracle.com if you need additional information or have any 3952 # questions. 3953 # 3954 3955 3956 3957 3958 3959 3960 3961 3962 3963 3964 3965 3966 3967 3968 3969 3970 3971 ################################################################################ 3972 # 3973 # Runs icecc-create-env once and prints the error if it fails 3974 # 3975 # $1: arguments to icecc-create-env 3976 # $2: log file 3977 # 3978 3979 3980 ################################################################################ 3981 # 3982 # Optionally enable distributed compilation of native code using icecc/icecream 3983 # 3984 3985 3986 3987 3988 3989 3990 3991 # 3992 # Copyright (c) 2011, 2017, Oracle and/or its affiliates. All rights reserved. 3993 # DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. 3994 # 3995 # This code is free software; you can redistribute it and/or modify it 3996 # under the terms of the GNU General Public License version 2 only, as 3997 # published by the Free Software Foundation. Oracle designates this 3998 # particular file as subject to the "Classpath" exception as provided 3999 # by Oracle in the LICENSE file that accompanied this code. 4000 # 4001 # This code is distributed in the hope that it will be useful, but WITHOUT 4002 # ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or 4003 # FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License 4004 # version 2 for more details (a copy is included in the LICENSE file that 4005 # accompanied this code). 4006 # 4007 # You should have received a copy of the GNU General Public License version 4008 # 2 along with this work; if not, write to the Free Software Foundation, 4009 # Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. 4010 # 4011 # Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA 4012 # or visit www.oracle.com if you need additional information or have any 4013 # questions. 4014 # 4015 4016 ################################################################################ 4017 # 4018 # Setup ABI profile (for arm) 4019 # 4020 4021 4022 # Reset the global CFLAGS/LDFLAGS variables and initialize them with the 4023 # corresponding configure arguments instead 4024 4025 4026 # Setup the sysroot flags and add them to global CFLAGS and LDFLAGS so 4027 # that configure can use them while detecting compilers. 4028 # TOOLCHAIN_TYPE is available here. 4029 # Param 1 - Optional prefix to all variables. (e.g BUILD_) 4030 4031 4032 4033 4034 4035 4036 # Documentation on common flags used for solstudio in HIGHEST. 4037 # 4038 # WARNING: Use of OPTIMIZATION_LEVEL=HIGHEST in your Makefile needs to be 4039 # done with care, there are some assumptions below that need to 4040 # be understood about the use of pointers, and IEEE behavior. 4041 # 4042 # -fns: Use non-standard floating point mode (not IEEE 754) 4043 # -fsimple: Do some simplification of floating point arithmetic (not IEEE 754) 4044 # -fsingle: Use single precision floating point with 'float' 4045 # -xalias_level=basic: Assume memory references via basic pointer types do not alias 4046 # (Source with excessing pointer casting and data access with mixed 4047 # pointer types are not recommended) 4048 # -xbuiltin=%all: Use intrinsic or inline versions for math/std functions 4049 # (If you expect perfect errno behavior, do not use this) 4050 # -xdepend: Loop data dependency optimizations (need -xO3 or higher) 4051 # -xrestrict: Pointer parameters to functions do not overlap 4052 # (Similar to -xalias_level=basic usage, but less obvious sometimes. 4053 # If you pass in multiple pointers to the same data, do not use this) 4054 # -xlibmil: Inline some library routines 4055 # (If you expect perfect errno behavior, do not use this) 4056 # -xlibmopt: Use optimized math routines (CURRENTLY DISABLED) 4057 # (If you expect perfect errno behavior, do not use this) 4058 # Can cause undefined external on Solaris 8 X86 on __sincos, removing for now 4059 4060 # FIXME: this will never happen since sparc != sparcv9, ie 32 bit, which we don't build anymore. 4061 # Bug? 4062 #if test "x$OPENJDK_TARGET_CPU" = xsparc; then 4063 # CFLAGS_JDK="${CFLAGS_JDK} -xmemalign=4s" 4064 # CXXFLAGS_JDK="${CXXFLAGS_JDK} -xmemalign=4s" 4065 #fi 4066 4067 4068 4069 4070 4071 4072 ################################################################################ 4073 # $1 - Either BUILD or TARGET to pick the correct OS/CPU variables to check 4074 # conditionals against. 4075 # $2 - Optional prefix for each variable defined. 4076 4077 4078 # FLAGS_C_COMPILER_CHECK_ARGUMENTS(ARGUMENT: [ARGUMENT], IF_TRUE: [RUN-IF-TRUE], 4079 # IF_FALSE: [RUN-IF-FALSE]) 4080 # ------------------------------------------------------------ 4081 # Check that the C compiler supports an argument 4082 4083 4084 4085 4086 # FLAGS_CXX_COMPILER_CHECK_ARGUMENTS(ARGUMENT: [ARGUMENT], IF_TRUE: [RUN-IF-TRUE], 4087 # IF_FALSE: [RUN-IF-FALSE]) 4088 # ------------------------------------------------------------ 4089 # Check that the C++ compiler supports an argument 4090 4091 4092 4093 4094 # FLAGS_COMPILER_CHECK_ARGUMENTS(ARGUMENT: [ARGUMENT], IF_TRUE: [RUN-IF-TRUE], 4095 # IF_FALSE: [RUN-IF-FALSE]) 4096 # ------------------------------------------------------------ 4097 # Check that the C and C++ compilers support an argument 4098 4099 4100 4101 4102 # FLAGS_LINKER_CHECK_ARGUMENTS(ARGUMENT: [ARGUMENT], IF_TRUE: [RUN-IF-TRUE], 4103 # IF_FALSE: [RUN-IF-FALSE]) 4104 # ------------------------------------------------------------ 4105 # Check that the linker support an argument 4106 4107 4108 4109 4110 4111 4112 # FLAGS_SETUP_GCC6_COMPILER_FLAGS([PREFIX]) 4113 # Arguments: 4114 # $1 - Optional prefix for each variable defined. 4115 4116 4117 # 4118 # Copyright (c) 2011, 2017, Oracle and/or its affiliates. All rights reserved. 4119 # DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. 4120 # 4121 # This code is free software; you can redistribute it and/or modify it 4122 # under the terms of the GNU General Public License version 2 only, as 4123 # published by the Free Software Foundation. Oracle designates this 4124 # particular file as subject to the "Classpath" exception as provided 4125 # by Oracle in the LICENSE file that accompanied this code. 4126 # 4127 # This code is distributed in the hope that it will be useful, but WITHOUT 4128 # ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or 4129 # FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License 4130 # version 2 for more details (a copy is included in the LICENSE file that 4131 # accompanied this code). 4132 # 4133 # You should have received a copy of the GNU General Public License version 4134 # 2 along with this work; if not, write to the Free Software Foundation, 4135 # Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. 4136 # 4137 # Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA 4138 # or visit www.oracle.com if you need additional information or have any 4139 # questions. 4140 # 4141 4142 4143 4144 4145 4146 cygwin_help() { 4147 case $1 in 4148 unzip) 4149 PKGHANDLER_COMMAND="( cd <location of cygwin setup.exe> && cmd /c setup -q -P unzip )" 4150 HELP_MSG="You might be able to fix this by running '$PKGHANDLER_COMMAND'." 4151 ;; 4152 zip) 4153 PKGHANDLER_COMMAND="( cd <location of cygwin setup.exe> && cmd /c setup -q -P zip )" 4154 HELP_MSG="You might be able to fix this by running '$PKGHANDLER_COMMAND'." 4155 ;; 4156 make) 4157 PKGHANDLER_COMMAND="( cd <location of cygwin setup.exe> && cmd /c setup -q -P make )" 4158 HELP_MSG="You might be able to fix this by running '$PKGHANDLER_COMMAND'." 4159 ;; 4160 freetype) 4161 HELP_MSG=" 4162 The freetype library can now be build during the configure process. 4163 Download the freetype sources and unpack them into an arbitrary directory: 4164 4165 wget http://download.savannah.gnu.org/releases/freetype/freetype-2.5.3.tar.gz 4166 tar -xzf freetype-2.5.3.tar.gz 4167 4168 Then run configure with '--with-freetype-src=<freetype_src>'. This will 4169 automatically build the freetype library into '<freetype_src>/lib64' for 64-bit 4170 builds or into '<freetype_src>/lib32' for 32-bit builds. 4171 Afterwards you can always use '--with-freetype-include=<freetype_src>/include' 4172 and '--with-freetype-lib=<freetype_src>/lib32|64' for other builds. 4173 4174 Alternatively you can unpack the sources like this to use the default directory: 4175 4176 tar --one-top-level=$HOME/freetype --strip-components=1 -xzf freetype-2.5.3.tar.gz" 4177 ;; 4178 esac 4179 } 4180 4181 msys_help() { 4182 PKGHANDLER_COMMAND="" 4183 } 4184 4185 apt_help() { 4186 case $1 in 4187 reduced) 4188 PKGHANDLER_COMMAND="sudo apt-get install gcc-multilib g++-multilib" ;; 4189 devkit) 4190 PKGHANDLER_COMMAND="sudo apt-get install build-essential" ;; 4191 openjdk) 4192 PKGHANDLER_COMMAND="sudo apt-get install openjdk-8-jdk" ;; 4193 alsa) 4194 PKGHANDLER_COMMAND="sudo apt-get install libasound2-dev" ;; 4195 cups) 4196 PKGHANDLER_COMMAND="sudo apt-get install libcups2-dev" ;; 4197 fontconfig) 4198 PKGHANDLER_COMMAND="sudo apt-get install libfontconfig1-dev" ;; 4199 freetype) 4200 PKGHANDLER_COMMAND="sudo apt-get install libfreetype6-dev" ;; 4201 ffi) 4202 PKGHANDLER_COMMAND="sudo apt-get install libffi-dev" ;; 4203 x11) 4204 PKGHANDLER_COMMAND="sudo apt-get install libx11-dev libxext-dev libxrender-dev libxtst-dev libxt-dev" ;; 4205 ccache) 4206 PKGHANDLER_COMMAND="sudo apt-get install ccache" ;; 4207 dtrace) 4208 PKGHANDLER_COMMAND="sudo apt-get install systemtap-sdt-dev" ;; 4209 esac 4210 } 4211 4212 yum_help() { 4213 case $1 in 4214 devkit) 4215 PKGHANDLER_COMMAND="sudo yum groupinstall \"Development Tools\"" ;; 4216 openjdk) 4217 PKGHANDLER_COMMAND="sudo yum install java-1.8.0-openjdk-devel" ;; 4218 alsa) 4219 PKGHANDLER_COMMAND="sudo yum install alsa-lib-devel" ;; 4220 cups) 4221 PKGHANDLER_COMMAND="sudo yum install cups-devel" ;; 4222 fontconfig) 4223 PKGHANDLER_COMMAND="sudo yum install fontconfig-devel" ;; 4224 freetype) 4225 PKGHANDLER_COMMAND="sudo yum install freetype-devel" ;; 4226 x11) 4227 PKGHANDLER_COMMAND="sudo yum install libXtst-devel libXt-devel libXrender-devel libXi-devel" ;; 4228 ccache) 4229 PKGHANDLER_COMMAND="sudo yum install ccache" ;; 4230 esac 4231 } 4232 4233 brew_help() { 4234 case $1 in 4235 openjdk) 4236 PKGHANDLER_COMMAND="brew cask install java" ;; 4237 freetype) 4238 PKGHANDLER_COMMAND="brew install freetype" ;; 4239 ccache) 4240 PKGHANDLER_COMMAND="brew install ccache" ;; 4241 esac 4242 } 4243 4244 port_help() { 4245 PKGHANDLER_COMMAND="" 4246 } 4247 4248 pkgutil_help() { 4249 PKGHANDLER_COMMAND="" 4250 } 4251 4252 pkgadd_help() { 4253 PKGHANDLER_COMMAND="" 4254 } 4255 4256 # This function will check if we're called from the "configure" wrapper while 4257 # printing --help. If so, we will print out additional information that can 4258 # only be extracted within the autoconf script, and then exit. This must be 4259 # called at the very beginning in configure.ac. 4260 4261 4262 4263 4264 4265 4266 # 4267 # Copyright (c) 2011, 2017, Oracle and/or its affiliates. All rights reserved. 4268 # DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. 4269 # 4270 # This code is free software; you can redistribute it and/or modify it 4271 # under the terms of the GNU General Public License version 2 only, as 4272 # published by the Free Software Foundation. Oracle designates this 4273 # particular file as subject to the "Classpath" exception as provided 4274 # by Oracle in the LICENSE file that accompanied this code. 4275 # 4276 # This code is distributed in the hope that it will be useful, but WITHOUT 4277 # ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or 4278 # FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License 4279 # version 2 for more details (a copy is included in the LICENSE file that 4280 # accompanied this code). 4281 # 4282 # You should have received a copy of the GNU General Public License version 4283 # 2 along with this work; if not, write to the Free Software Foundation, 4284 # Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. 4285 # 4286 # Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA 4287 # or visit www.oracle.com if you need additional information or have any 4288 # questions. 4289 # 4290 4291 # All valid JVM features, regardless of platform 4292 VALID_JVM_FEATURES="compiler1 compiler2 zero minimal dtrace jvmti jvmci \ 4293 graal vm-structs jni-check services management all-gcs nmt cds \ 4294 static-build link-time-opt aot" 4295 4296 # All valid JVM variants 4297 VALID_JVM_VARIANTS="server client minimal core zero custom" 4298 4299 ############################################################################### 4300 # Check if the specified JVM variant should be built. To be used in shell if 4301 # constructs, like this: 4302 # if HOTSPOT_CHECK_JVM_VARIANT(server); then 4303 # 4304 # Only valid to use after HOTSPOT_SETUP_JVM_VARIANTS has setup variants. 4305 4306 # Definition kept in one line to allow inlining in if statements. 4307 # Additional [] needed to keep m4 from mangling shell constructs. 4308 4309 4310 ############################################################################### 4311 # Check if the specified JVM features are explicitly enabled. To be used in 4312 # shell if constructs, like this: 4313 # if HOTSPOT_CHECK_JVM_FEATURE(jvmti); then 4314 # 4315 # Only valid to use after HOTSPOT_SETUP_JVM_FEATURES has setup features. 4316 4317 # Definition kept in one line to allow inlining in if statements. 4318 # Additional [] needed to keep m4 from mangling shell constructs. 4319 4320 4321 ############################################################################### 4322 # Check which variants of the JVM that we want to build. Available variants are: 4323 # server: normal interpreter, and a tiered C1/C2 compiler 4324 # client: normal interpreter, and C1 (no C2 compiler) 4325 # minimal: reduced form of client with optional features stripped out 4326 # core: normal interpreter only, no compiler 4327 # zero: C++ based interpreter only, no compiler 4328 # custom: baseline JVM with no default features 4329 # 4330 4331 4332 ############################################################################### 4333 # Check if dtrace should be enabled and has all prerequisites present. 4334 # 4335 4336 4337 ################################################################################ 4338 # Check if AOT should be enabled 4339 # 4340 4341 4342 ################################################################################ 4343 # Allow to disable CDS 4344 # 4345 4346 4347 ############################################################################### 4348 # Set up all JVM features for each JVM variant. 4349 # 4350 4351 4352 ############################################################################### 4353 # Validate JVM features once all setup is complete, including custom setup. 4354 # 4355 4356 4357 ################################################################################ 4358 # 4359 # Specify which sources will be used to build the 64-bit ARM port 4360 # 4361 # --with-cpu-port=arm64 will use hotspot/src/cpu/arm 4362 # --with-cpu-port=aarch64 will use hotspot/src/cpu/aarch64 4363 # 4364 4365 4366 4367 ################################################################################ 4368 # Check if gtest should be built 4369 # 4370 4371 4372 # 4373 # Copyright (c) 2011, 2017, Oracle and/or its affiliates. All rights reserved. 4374 # DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. 4375 # 4376 # This code is free software; you can redistribute it and/or modify it 4377 # under the terms of the GNU General Public License version 2 only, as 4378 # published by the Free Software Foundation. Oracle designates this 4379 # particular file as subject to the "Classpath" exception as provided 4380 # by Oracle in the LICENSE file that accompanied this code. 4381 # 4382 # This code is distributed in the hope that it will be useful, but WITHOUT 4383 # ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or 4384 # FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License 4385 # version 2 for more details (a copy is included in the LICENSE file that 4386 # accompanied this code). 4387 # 4388 # You should have received a copy of the GNU General Public License version 4389 # 2 along with this work; if not, write to the Free Software Foundation, 4390 # Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. 4391 # 4392 # Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA 4393 # or visit www.oracle.com if you need additional information or have any 4394 # questions. 4395 # 4396 4397 ############################################################################### 4398 # Check which variant of the JDK that we want to build. 4399 # Currently we have: 4400 # normal: standard edition 4401 # but the custom make system may add other variants 4402 # 4403 # Effectively the JDK variant gives a name to a specific set of 4404 # modules to compile into the JDK. 4405 4406 4407 ############################################################################### 4408 # Set the debug level 4409 # release: no debug information, all optimizations, no asserts. 4410 # optimized: no debug information, all optimizations, no asserts, HotSpot target is 'optimized'. 4411 # fastdebug: debug information (-g), all optimizations, all asserts 4412 # slowdebug: debug information (-g), no optimizations, all asserts 4413 4414 4415 ############################################################################### 4416 # 4417 # Should we build only OpenJDK even if closed sources are present? 4418 # 4419 4420 4421 4422 4423 ############################################################################### 4424 # 4425 # Enable or disable the elliptic curve crypto implementation 4426 # 4427 4428 4429 4430 4431 ################################################################################ 4432 # 4433 # Gcov coverage data for hotspot 4434 # 4435 4436 4437 ############################################################################### 4438 # 4439 # AddressSanitizer 4440 # 4441 4442 4443 ################################################################################ 4444 # 4445 # Static build support. When enabled will generate static 4446 # libraries instead of shared libraries for all JDK libs. 4447 # 4448 4449 4450 ################################################################################ 4451 # 4452 # jlink options. 4453 # We always keep packaged modules in JDK image. 4454 # 4455 4456 4457 ################################################################################ 4458 # 4459 # Check if building of the jtreg failure handler should be enabled. 4460 # 4461 4462 4463 ################################################################################ 4464 # 4465 # Enable or disable generation of the classlist at build time 4466 # 4467 4468 4469 # 4470 # Copyright (c) 2015, 2017, Oracle and/or its affiliates. All rights reserved. 4471 # DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. 4472 # 4473 # This code is free software; you can redistribute it and/or modify it 4474 # under the terms of the GNU General Public License version 2 only, as 4475 # published by the Free Software Foundation. Oracle designates this 4476 # particular file as subject to the "Classpath" exception as provided 4477 # by Oracle in the LICENSE file that accompanied this code. 4478 # 4479 # This code is distributed in the hope that it will be useful, but WITHOUT 4480 # ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or 4481 # FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License 4482 # version 2 for more details (a copy is included in the LICENSE file that 4483 # accompanied this code). 4484 # 4485 # You should have received a copy of the GNU General Public License version 4486 # 2 along with this work; if not, write to the Free Software Foundation, 4487 # Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. 4488 # 4489 # Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA 4490 # or visit www.oracle.com if you need additional information or have any 4491 # questions. 4492 # 4493 4494 ############################################################################### 4495 # 4496 # Setup version numbers 4497 # 4498 4499 # Verify that a given string represents a valid version number, and assign it 4500 # to a variable. 4501 4502 # Argument 1: the variable to assign to 4503 # Argument 2: the value given by the user 4504 4505 4506 4507 4508 # 4509 # Copyright (c) 2011, 2017, Oracle and/or its affiliates. All rights reserved. 4510 # DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. 4511 # 4512 # This code is free software; you can redistribute it and/or modify it 4513 # under the terms of the GNU General Public License version 2 only, as 4514 # published by the Free Software Foundation. Oracle designates this 4515 # particular file as subject to the "Classpath" exception as provided 4516 # by Oracle in the LICENSE file that accompanied this code. 4517 # 4518 # This code is distributed in the hope that it will be useful, but WITHOUT 4519 # ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or 4520 # FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License 4521 # version 2 for more details (a copy is included in the LICENSE file that 4522 # accompanied this code). 4523 # 4524 # You should have received a copy of the GNU General Public License version 4525 # 2 along with this work; if not, write to the Free Software Foundation, 4526 # Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. 4527 # 4528 # Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA 4529 # or visit www.oracle.com if you need additional information or have any 4530 # questions. 4531 # 4532 4533 # Major library component reside in separate files. 4534 # 4535 # Copyright (c) 2011, 2015, Oracle and/or its affiliates. All rights reserved. 4536 # DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. 4537 # 4538 # This code is free software; you can redistribute it and/or modify it 4539 # under the terms of the GNU General Public License version 2 only, as 4540 # published by the Free Software Foundation. Oracle designates this 4541 # particular file as subject to the "Classpath" exception as provided 4542 # by Oracle in the LICENSE file that accompanied this code. 4543 # 4544 # This code is distributed in the hope that it will be useful, but WITHOUT 4545 # ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or 4546 # FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License 4547 # version 2 for more details (a copy is included in the LICENSE file that 4548 # accompanied this code). 4549 # 4550 # You should have received a copy of the GNU General Public License version 4551 # 2 along with this work; if not, write to the Free Software Foundation, 4552 # Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. 4553 # 4554 # Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA 4555 # or visit www.oracle.com if you need additional information or have any 4556 # questions. 4557 # 4558 4559 ################################################################################ 4560 # Setup alsa (Advanced Linux Sound Architecture) 4561 ################################################################################ 4562 4563 4564 # 4565 # Copyright (c) 2011, 2017, Oracle and/or its affiliates. All rights reserved. 4566 # DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. 4567 # 4568 # This code is free software; you can redistribute it and/or modify it 4569 # under the terms of the GNU General Public License version 2 only, as 4570 # published by the Free Software Foundation. Oracle designates this 4571 # particular file as subject to the "Classpath" exception as provided 4572 # by Oracle in the LICENSE file that accompanied this code. 4573 # 4574 # This code is distributed in the hope that it will be useful, but WITHOUT 4575 # ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or 4576 # FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License 4577 # version 2 for more details (a copy is included in the LICENSE file that 4578 # accompanied this code). 4579 # 4580 # You should have received a copy of the GNU General Public License version 4581 # 2 along with this work; if not, write to the Free Software Foundation, 4582 # Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. 4583 # 4584 # Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA 4585 # or visit www.oracle.com if you need additional information or have any 4586 # questions. 4587 # 4588 4589 ################################################################################ 4590 # Setup bundled libraries. 4591 # 4592 # For libjpeg, giflib, libpng, lcms2 and zlib, the source is present in the 4593 # OpenJDK repository. Default is to use these libraries as bundled, but they 4594 # might be replaced by en external version by the user. 4595 ################################################################################ 4596 4597 4598 ################################################################################ 4599 # Setup libjpeg 4600 ################################################################################ 4601 4602 4603 ################################################################################ 4604 # Setup giflib 4605 ################################################################################ 4606 4607 4608 ################################################################################ 4609 # Setup libpng 4610 ################################################################################ 4611 4612 4613 ################################################################################ 4614 # Setup zlib 4615 ################################################################################ 4616 4617 4618 ################################################################################ 4619 # Setup lcms (Little CMS) 4620 ################################################################################ 4621 4622 4623 # 4624 # Copyright (c) 2011, 2016, Oracle and/or its affiliates. All rights reserved. 4625 # DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. 4626 # 4627 # This code is free software; you can redistribute it and/or modify it 4628 # under the terms of the GNU General Public License version 2 only, as 4629 # published by the Free Software Foundation. Oracle designates this 4630 # particular file as subject to the "Classpath" exception as provided 4631 # by Oracle in the LICENSE file that accompanied this code. 4632 # 4633 # This code is distributed in the hope that it will be useful, but WITHOUT 4634 # ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or 4635 # FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License 4636 # version 2 for more details (a copy is included in the LICENSE file that 4637 # accompanied this code). 4638 # 4639 # You should have received a copy of the GNU General Public License version 4640 # 2 along with this work; if not, write to the Free Software Foundation, 4641 # Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. 4642 # 4643 # Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA 4644 # or visit www.oracle.com if you need additional information or have any 4645 # questions. 4646 # 4647 4648 ################################################################################ 4649 # Setup cups (Common Unix Printing System) 4650 ################################################################################ 4651 4652 4653 # 4654 # Copyright (c) 2015, Oracle and/or its affiliates. All rights reserved. 4655 # DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. 4656 # 4657 # This code is free software; you can redistribute it and/or modify it 4658 # under the terms of the GNU General Public License version 2 only, as 4659 # published by the Free Software Foundation. Oracle designates this 4660 # particular file as subject to the "Classpath" exception as provided 4661 # by Oracle in the LICENSE file that accompanied this code. 4662 # 4663 # This code is distributed in the hope that it will be useful, but WITHOUT 4664 # ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or 4665 # FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License 4666 # version 2 for more details (a copy is included in the LICENSE file that 4667 # accompanied this code). 4668 # 4669 # You should have received a copy of the GNU General Public License version 4670 # 2 along with this work; if not, write to the Free Software Foundation, 4671 # Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. 4672 # 4673 # Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA 4674 # or visit www.oracle.com if you need additional information or have any 4675 # questions. 4676 # 4677 4678 ################################################################################ 4679 # Setup libffi (Foreign Function Interface) 4680 ################################################################################ 4681 4682 4683 # 4684 # Copyright (c) 2011, 2017, Oracle and/or its affiliates. All rights reserved. 4685 # DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. 4686 # 4687 # This code is free software; you can redistribute it and/or modify it 4688 # under the terms of the GNU General Public License version 2 only, as 4689 # published by the Free Software Foundation. Oracle designates this 4690 # particular file as subject to the "Classpath" exception as provided 4691 # by Oracle in the LICENSE file that accompanied this code. 4692 # 4693 # This code is distributed in the hope that it will be useful, but WITHOUT 4694 # ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or 4695 # FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License 4696 # version 2 for more details (a copy is included in the LICENSE file that 4697 # accompanied this code). 4698 # 4699 # You should have received a copy of the GNU General Public License version 4700 # 2 along with this work; if not, write to the Free Software Foundation, 4701 # Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. 4702 # 4703 # Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA 4704 # or visit www.oracle.com if you need additional information or have any 4705 # questions. 4706 # 4707 4708 ################################################################################ 4709 # Build the freetype lib from source 4710 ################################################################################ 4711 4712 4713 ################################################################################ 4714 # Check if a potential freeype library match is correct and usable 4715 ################################################################################ 4716 4717 4718 ################################################################################ 4719 # Setup freetype (The FreeType2 font rendering library) 4720 ################################################################################ 4721 4722 4723 # 4724 # Copyright (c) 2011, 2016, Oracle and/or its affiliates. All rights reserved. 4725 # DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. 4726 # 4727 # This code is free software; you can redistribute it and/or modify it 4728 # under the terms of the GNU General Public License version 2 only, as 4729 # published by the Free Software Foundation. Oracle designates this 4730 # particular file as subject to the "Classpath" exception as provided 4731 # by Oracle in the LICENSE file that accompanied this code. 4732 # 4733 # This code is distributed in the hope that it will be useful, but WITHOUT 4734 # ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or 4735 # FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License 4736 # version 2 for more details (a copy is included in the LICENSE file that 4737 # accompanied this code). 4738 # 4739 # You should have received a copy of the GNU General Public License version 4740 # 2 along with this work; if not, write to the Free Software Foundation, 4741 # Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. 4742 # 4743 # Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA 4744 # or visit www.oracle.com if you need additional information or have any 4745 # questions. 4746 # 4747 4748 ################################################################################ 4749 # Setup the standard C/C++ runtime libraries. 4750 # 4751 # Most importantly, determine if stdc++ should be linked statically or 4752 # dynamically. 4753 ################################################################################ 4754 4755 4756 # 4757 # Copyright (c) 2011, 2015, Oracle and/or its affiliates. All rights reserved. 4758 # DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. 4759 # 4760 # This code is free software; you can redistribute it and/or modify it 4761 # under the terms of the GNU General Public License version 2 only, as 4762 # published by the Free Software Foundation. Oracle designates this 4763 # particular file as subject to the "Classpath" exception as provided 4764 # by Oracle in the LICENSE file that accompanied this code. 4765 # 4766 # This code is distributed in the hope that it will be useful, but WITHOUT 4767 # ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or 4768 # FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License 4769 # version 2 for more details (a copy is included in the LICENSE file that 4770 # accompanied this code). 4771 # 4772 # You should have received a copy of the GNU General Public License version 4773 # 2 along with this work; if not, write to the Free Software Foundation, 4774 # Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. 4775 # 4776 # Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA 4777 # or visit www.oracle.com if you need additional information or have any 4778 # questions. 4779 # 4780 4781 ################################################################################ 4782 # Setup X11 Windows system 4783 ################################################################################ 4784 4785 4786 # 4787 # Copyright (c) 2017, Oracle and/or its affiliates. All rights reserved. 4788 # DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. 4789 # 4790 # This code is free software; you can redistribute it and/or modify it 4791 # under the terms of the GNU General Public License version 2 only, as 4792 # published by the Free Software Foundation. Oracle designates this 4793 # particular file as subject to the "Classpath" exception as provided 4794 # by Oracle in the LICENSE file that accompanied this code. 4795 # 4796 # This code is distributed in the hope that it will be useful, but WITHOUT 4797 # ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or 4798 # FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License 4799 # version 2 for more details (a copy is included in the LICENSE file that 4800 # accompanied this code). 4801 # 4802 # You should have received a copy of the GNU General Public License version 4803 # 2 along with this work; if not, write to the Free Software Foundation, 4804 # Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. 4805 # 4806 # Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA 4807 # or visit www.oracle.com if you need additional information or have any 4808 # questions. 4809 # 4810 4811 ################################################################################ 4812 # Setup fontconfig 4813 ################################################################################ 4814 4815 4816 4817 ################################################################################ 4818 # Determine which libraries are needed for this configuration 4819 ################################################################################ 4820 4821 4822 ################################################################################ 4823 # Parse library options, and setup needed libraries 4824 ################################################################################ 4825 4826 4827 ################################################################################ 4828 # Setup various libraries, typically small system libraries 4829 ################################################################################ 4830 4831 4832 ################################################################################ 4833 # libstlport.so.1 is needed for running gtest on Solaris. Find it to 4834 # redistribute it in the test image. 4835 ################################################################################ 4836 4837 4838 4839 # 4840 # Copyright (c) 2011, 2017, Oracle and/or its affiliates. All rights reserved. 4841 # DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. 4842 # 4843 # This code is free software; you can redistribute it and/or modify it 4844 # under the terms of the GNU General Public License version 2 only, as 4845 # published by the Free Software Foundation. Oracle designates this 4846 # particular file as subject to the "Classpath" exception as provided 4847 # by Oracle in the LICENSE file that accompanied this code. 4848 # 4849 # This code is distributed in the hope that it will be useful, but WITHOUT 4850 # ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or 4851 # FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License 4852 # version 2 for more details (a copy is included in the LICENSE file that 4853 # accompanied this code). 4854 # 4855 # You should have received a copy of the GNU General Public License version 4856 # 2 along with this work; if not, write to the Free Software Foundation, 4857 # Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. 4858 # 4859 # Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA 4860 # or visit www.oracle.com if you need additional information or have any 4861 # questions. 4862 # 4863 4864 # Support macro for PLATFORM_EXTRACT_TARGET_AND_BUILD. 4865 # Converts autoconf style CPU name to OpenJDK style, into 4866 # VAR_CPU, VAR_CPU_ARCH, VAR_CPU_BITS and VAR_CPU_ENDIAN. 4867 4868 4869 # Support macro for PLATFORM_EXTRACT_TARGET_AND_BUILD. 4870 # Converts autoconf style OS name to OpenJDK style, into 4871 # VAR_OS, VAR_OS_TYPE and VAR_OS_ENV. 4872 4873 4874 # Expects $host_os $host_cpu $build_os and $build_cpu 4875 # and $with_target_bits to have been setup! 4876 # 4877 # Translate the standard triplet(quadruplet) definition 4878 # of the target/build system into OPENJDK_TARGET_OS, OPENJDK_TARGET_CPU, 4879 # OPENJDK_BUILD_OS, etc. 4880 4881 4882 # Check if a reduced build (32-bit on 64-bit platforms) is requested, and modify behaviour 4883 # accordingly. Must be done after setting up build and target system, but before 4884 # doing anything else with these values. 4885 4886 4887 # Setup the legacy variables, for controlling the old makefiles. 4888 # 4889 4890 4891 # $1 - Either TARGET or BUILD to setup the variables for. 4892 4893 4894 4895 4896 4897 4898 #%%% Build and target systems %%% 4899 4900 4901 4902 4903 # Support macro for PLATFORM_SETUP_OPENJDK_TARGET_BITS. 4904 # Add -mX to various FLAGS variables. 4905 4906 4907 4908 4909 4910 4911 # 4912 # Copyright (c) 2011, 2017, Oracle and/or its affiliates. All rights reserved. 4913 # DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. 4914 # 4915 # This code is free software; you can redistribute it and/or modify it 4916 # under the terms of the GNU General Public License version 2 only, as 4917 # published by the Free Software Foundation. Oracle designates this 4918 # particular file as subject to the "Classpath" exception as provided 4919 # by Oracle in the LICENSE file that accompanied this code. 4920 # 4921 # This code is distributed in the hope that it will be useful, but WITHOUT 4922 # ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or 4923 # FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License 4924 # version 2 for more details (a copy is included in the LICENSE file that 4925 # accompanied this code). 4926 # 4927 # You should have received a copy of the GNU General Public License version 4928 # 2 along with this work; if not, write to the Free Software Foundation, 4929 # Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. 4930 # 4931 # Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA 4932 # or visit www.oracle.com if you need additional information or have any 4933 # questions. 4934 # 4935 4936 4937 4938 ################################################################################ 4939 # Define a mechanism for importing extra prebuilt modules 4940 # 4941 4942 4943 4944 # 4945 # Copyright (c) 2011, 2017, Oracle and/or its affiliates. All rights reserved. 4946 # DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. 4947 # 4948 # This code is free software; you can redistribute it and/or modify it 4949 # under the terms of the GNU General Public License version 2 only, as 4950 # published by the Free Software Foundation. Oracle designates this 4951 # particular file as subject to the "Classpath" exception as provided 4952 # by Oracle in the LICENSE file that accompanied this code. 4953 # 4954 # This code is distributed in the hope that it will be useful, but WITHOUT 4955 # ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or 4956 # FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License 4957 # version 2 for more details (a copy is included in the LICENSE file that 4958 # accompanied this code). 4959 # 4960 # You should have received a copy of the GNU General Public License version 4961 # 2 along with this work; if not, write to the Free Software Foundation, 4962 # Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. 4963 # 4964 # Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA 4965 # or visit www.oracle.com if you need additional information or have any 4966 # questions. 4967 # 4968 4969 ######################################################################## 4970 # This file is responsible for detecting, verifying and setting up the 4971 # toolchain, i.e. the compiler, linker and related utilities. It will setup 4972 # proper paths to the binaries, but it will not setup any flags. 4973 # 4974 # The binaries used is determined by the toolchain type, which is the family of 4975 # compilers and related tools that are used. 4976 ######################################################################## 4977 4978 4979 # All valid toolchains, regardless of platform (used by help.m4) 4980 VALID_TOOLCHAINS_all="gcc clang solstudio xlc microsoft" 4981 4982 # These toolchains are valid on different platforms 4983 VALID_TOOLCHAINS_linux="gcc clang" 4984 VALID_TOOLCHAINS_solaris="solstudio" 4985 VALID_TOOLCHAINS_macosx="gcc clang" 4986 VALID_TOOLCHAINS_aix="xlc" 4987 VALID_TOOLCHAINS_windows="microsoft" 4988 4989 # Toolchain descriptions 4990 TOOLCHAIN_DESCRIPTION_clang="clang/LLVM" 4991 TOOLCHAIN_DESCRIPTION_gcc="GNU Compiler Collection" 4992 TOOLCHAIN_DESCRIPTION_microsoft="Microsoft Visual Studio" 4993 TOOLCHAIN_DESCRIPTION_solstudio="Oracle Solaris Studio" 4994 TOOLCHAIN_DESCRIPTION_xlc="IBM XL C/C++" 4995 4996 # Minimum supported versions, empty means unspecified 4997 TOOLCHAIN_MINIMUM_VERSION_clang="3.2" 4998 TOOLCHAIN_MINIMUM_VERSION_gcc="4.7" 4999 TOOLCHAIN_MINIMUM_VERSION_microsoft="16.00.30319.01" # VS2010 5000 TOOLCHAIN_MINIMUM_VERSION_solstudio="5.13" 5001 TOOLCHAIN_MINIMUM_VERSION_xlc="" 5002 5003 # Prepare the system so that TOOLCHAIN_CHECK_COMPILER_VERSION can be called. 5004 # Must have CC_VERSION_NUMBER and CXX_VERSION_NUMBER. 5005 # $1 - optional variable prefix for compiler and version variables (BUILD_) 5006 # $2 - optional variable prefix for comparable variable (OPENJDK_BUILD_) 5007 5008 5009 # Check if the configured compiler (C and C++) is of a specific version or 5010 # newer. TOOLCHAIN_PREPARE_FOR_VERSION_COMPARISONS must have been called before. 5011 # 5012 # Arguments: 5013 # VERSION: The version string to check against the found version 5014 # IF_AT_LEAST: block to run if the compiler is at least this version (>=) 5015 # IF_OLDER_THAN: block to run if the compiler is older than this version (<) 5016 # PREFIX: Optional variable prefix for compiler to compare version for (OPENJDK_BUILD_) 5017 5018 5019 5020 5021 # Setup a number of variables describing how native output files are 5022 # named on this platform/toolchain. 5023 5024 5025 # Determine which toolchain type to use, and make sure it is valid for this 5026 # platform. Setup various information about the selected toolchain. 5027 5028 5029 # Before we start detecting the toolchain executables, we might need some 5030 # special setup, e.g. additional paths etc. 5031 5032 5033 # Restore path, etc 5034 5035 5036 # Check if a compiler is of the toolchain type we expect, and save the version 5037 # information from it. If the compiler does not match the expected type, 5038 # this function will abort using AC_MSG_ERROR. If it matches, the version will 5039 # be stored in CC_VERSION_NUMBER/CXX_VERSION_NUMBER (as a dotted number), and 5040 # the full version string in CC_VERSION_STRING/CXX_VERSION_STRING. 5041 # 5042 # $1 = compiler to test (CC or CXX) 5043 # $2 = human readable name of compiler (C or C++) 5044 5045 5046 # Try to locate the given C or C++ compiler in the path, or otherwise. 5047 # 5048 # $1 = compiler to test (CC or CXX) 5049 # $2 = human readable name of compiler (C or C++) 5050 # $3 = compiler name to search for 5051 5052 5053 # Detect the core components of the toolchain, i.e. the compilers (CC and CXX), 5054 # preprocessor (CPP and CXXCPP), the linker (LD), the assembler (AS) and the 5055 # archiver (AR). Verify that the compilers are correct according to the 5056 # toolchain type. 5057 5058 5059 # Setup additional tools that is considered a part of the toolchain, but not the 5060 # core part. Many of these are highly platform-specific and do not exist, 5061 # and/or are not needed on all platforms. 5062 5063 5064 # Setup the build tools (i.e, the compiler and linker used to build programs 5065 # that should be run on the build platform, not the target platform, as a build 5066 # helper). Since the non-cross-compile case uses the normal, target compilers 5067 # for this, we can only do this after these have been setup. 5068 5069 5070 # Do some additional checks on the detected tools. 5071 5072 5073 # Setup the JTReg Regression Test Harness. 5074 5075 5076 # Setup the JIB dependency resolver 5077 5078 5079 # 5080 # Copyright (c) 2011, 2012, Oracle and/or its affiliates. All rights reserved. 5081 # DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. 5082 # 5083 # This code is free software; you can redistribute it and/or modify it 5084 # under the terms of the GNU General Public License version 2 only, as 5085 # published by the Free Software Foundation. Oracle designates this 5086 # particular file as subject to the "Classpath" exception as provided 5087 # by Oracle in the LICENSE file that accompanied this code. 5088 # 5089 # This code is distributed in the hope that it will be useful, but WITHOUT 5090 # ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or 5091 # FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License 5092 # version 2 for more details (a copy is included in the LICENSE file that 5093 # accompanied this code). 5094 # 5095 # You should have received a copy of the GNU General Public License version 5096 # 2 along with this work; if not, write to the Free Software Foundation, 5097 # Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. 5098 # 5099 # Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA 5100 # or visit www.oracle.com if you need additional information or have any 5101 # questions. 5102 # 5103 5104 ################################################################################ 5105 # The order of these defines the priority by which we try to find them. 5106 VALID_VS_VERSIONS="2013 2012 2010" 5107 5108 VS_DESCRIPTION_2010="Microsoft Visual Studio 2010" 5109 VS_VERSION_INTERNAL_2010=100 5110 VS_MSVCR_2010=msvcr100.dll 5111 # We don't use msvcp on Visual Studio 2010 5112 #VS_MSVCP_2010=msvcp100.dll 5113 VS_ENVVAR_2010="VS100COMNTOOLS" 5114 VS_VS_INSTALLDIR_2010="Microsoft Visual Studio 10.0" 5115 VS_SDK_INSTALLDIR_2010="Microsoft SDKs/Windows/v7.1" 5116 VS_VS_PLATFORM_NAME_2010="v100" 5117 VS_SDK_PLATFORM_NAME_2010="Windows7.1SDK" 5118 5119 VS_DESCRIPTION_2012="Microsoft Visual Studio 2012" 5120 VS_VERSION_INTERNAL_2012=110 5121 VS_MSVCR_2012=msvcr110.dll 5122 VS_MSVCP_2012=msvcp110.dll 5123 VS_ENVVAR_2012="VS110COMNTOOLS" 5124 VS_VS_INSTALLDIR_2012="Microsoft Visual Studio 11.0" 5125 VS_SDK_INSTALLDIR_2012= 5126 VS_VS_PLATFORM_NAME_2012="v110" 5127 VS_SDK_PLATFORM_NAME_2012= 5128 5129 VS_DESCRIPTION_2013="Microsoft Visual Studio 2013" 5130 VS_VERSION_INTERNAL_2013=120 5131 VS_MSVCR_2013=msvcr120.dll 5132 VS_MSVCP_2013=msvcp120.dll 5133 VS_ENVVAR_2013="VS120COMNTOOLS" 5134 VS_VS_INSTALLDIR_2013="Microsoft Visual Studio 12.0" 5135 VS_SDK_INSTALLDIR_2013= 5136 VS_VS_PLATFORM_NAME_2013="v120" 5137 VS_SDK_PLATFORM_NAME_2013= 5138 5139 ################################################################################ 5140 5141 5142 5143 ################################################################################ 5144 5145 5146 5147 ################################################################################ 5148 # Finds the bat or cmd file in Visual Studio or the SDK that sets up a proper 5149 # build environment and assigns it to VS_ENV_CMD 5150 5151 5152 ################################################################################ 5153 5154 5155 5156 ################################################################################ 5157 # Check if the VS env variables were setup prior to running configure. 5158 # If not, then find vcvarsall.bat and run it automatically, and integrate 5159 # the set env variables into the spec file. 5160 5161 5162 5163 5164 5165 5166 5167 5168 5169 5170 5171 5172 5173 5174 # This line needs to be here, verbatim, after all includes and the dummy hook 5175 # definitions. It is replaced with custom functionality when building 5176 # custom sources. 5177 #CUSTOM_AUTOCONF_INCLUDE 5178 5179 # Do not change or remove the following line, it is needed for consistency checks: 5180 DATE_WHEN_GENERATED=1515008134 5181 5182 ############################################################################### 5183 # 5184 # Initialization / Boot-strapping 5185 # 5186 # The bootstrapping process needs to solve the "chicken or the egg" problem, 5187 # thus it jumps back and forth, each time gaining something needed later on. 5188 # 5189 ############################################################################### 5190 5191 # If we are requested to print additional help, do that and then exit. 5192 # This must be the very first call. 5193 5194 if test "x$CONFIGURE_PRINT_ADDITIONAL_HELP" != x; then 5195 5196 # Print available toolchains 5197 $PRINTF "The following toolchains are available as arguments to --with-toolchain-type.\n" 5198 $PRINTF "Which are valid to use depends on the build platform.\n" 5199 for toolchain in $VALID_TOOLCHAINS_all; do 5200 # Use indirect variable referencing 5201 toolchain_var_name=TOOLCHAIN_DESCRIPTION_$toolchain 5202 TOOLCHAIN_DESCRIPTION=${!toolchain_var_name} 5203 $PRINTF " %-10s %s\n" $toolchain "$TOOLCHAIN_DESCRIPTION" 5204 done 5205 $PRINTF "\n" 5206 5207 # Print available jvm features 5208 $PRINTF "The following JVM features are available as arguments to --with-jvm-features.\n" 5209 $PRINTF "Which are valid to use depends on the target platform.\n " 5210 $PRINTF "%s " $VALID_JVM_FEATURES 5211 $PRINTF "\n" 5212 5213 # And now exit directly 5214 exit 0 5215 fi 5216 5217 5218 # Basic initialization that must happen first of all in the normal process. 5219 5220 # Save the original command line. This is passed to us by the wrapper configure script. 5221 5222 # Save the path variable before it gets changed 5223 ORIGINAL_PATH="$PATH" 5224 5225 DATE_WHEN_CONFIGURED=`LANG=C date` 5226 5227 { $as_echo "$as_me:${as_lineno-$LINENO}: Configuration created at $DATE_WHEN_CONFIGURED." >&5 5228 $as_echo "$as_me: Configuration created at $DATE_WHEN_CONFIGURED." >&6;} 5229 { $as_echo "$as_me:${as_lineno-$LINENO}: configure script generated at timestamp $DATE_WHEN_GENERATED." >&5 5230 $as_echo "$as_me: configure script generated at timestamp $DATE_WHEN_GENERATED." >&6;} 5231 5232 5233 # Start with tools that do not need have cross compilation support 5234 # and can be expected to be found in the default PATH. These tools are 5235 # used by configure. 5236 5237 # First are all the simple required tools. 5238 5239 5240 5241 # Publish this variable in the help. 5242 5243 5244 if [ -z "${BASENAME+x}" ]; then 5245 # The variable is not set by user, try to locate tool using the code snippet 5246 for ac_prog in basename 5247 do 5248 # Extract the first word of "$ac_prog", so it can be a program name with args. 5249 set dummy $ac_prog; ac_word=$2 5250 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 5251 $as_echo_n "checking for $ac_word... " >&6; } 5252 if ${ac_cv_path_BASENAME+:} false; then : 5253 $as_echo_n "(cached) " >&6 5254 else 5255 case $BASENAME in 5256 [\\/]* | ?:[\\/]*) 5257 ac_cv_path_BASENAME="$BASENAME" # Let the user override the test with a path. 5258 ;; 5259 *) 5260 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 5261 for as_dir in $PATH 5262 do 5263 IFS=$as_save_IFS 5264 test -z "$as_dir" && as_dir=. 5265 for ac_exec_ext in '' $ac_executable_extensions; do 5266 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 5267 ac_cv_path_BASENAME="$as_dir/$ac_word$ac_exec_ext" 5268 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 5269 break 2 5270 fi 5271 done 5272 done 5273 IFS=$as_save_IFS 5274 5275 ;; 5276 esac 5277 fi 5278 BASENAME=$ac_cv_path_BASENAME 5279 if test -n "$BASENAME"; then 5280 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BASENAME" >&5 5281 $as_echo "$BASENAME" >&6; } 5282 else 5283 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 5284 $as_echo "no" >&6; } 5285 fi 5286 5287 5288 test -n "$BASENAME" && break 5289 done 5290 5291 else 5292 # The variable is set, but is it from the command line or the environment? 5293 5294 # Try to remove the string !BASENAME! from our list. 5295 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!BASENAME!/} 5296 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 5297 # If it failed, the variable was not from the command line. Ignore it, 5298 # but warn the user (except for BASH, which is always set by the calling BASH). 5299 if test "xBASENAME" != xBASH; then 5300 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of BASENAME from the environment. Use command line variables instead." >&5 5301 $as_echo "$as_me: WARNING: Ignoring value of BASENAME from the environment. Use command line variables instead." >&2;} 5302 fi 5303 # Try to locate tool using the code snippet 5304 for ac_prog in basename 5305 do 5306 # Extract the first word of "$ac_prog", so it can be a program name with args. 5307 set dummy $ac_prog; ac_word=$2 5308 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 5309 $as_echo_n "checking for $ac_word... " >&6; } 5310 if ${ac_cv_path_BASENAME+:} false; then : 5311 $as_echo_n "(cached) " >&6 5312 else 5313 case $BASENAME in 5314 [\\/]* | ?:[\\/]*) 5315 ac_cv_path_BASENAME="$BASENAME" # Let the user override the test with a path. 5316 ;; 5317 *) 5318 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 5319 for as_dir in $PATH 5320 do 5321 IFS=$as_save_IFS 5322 test -z "$as_dir" && as_dir=. 5323 for ac_exec_ext in '' $ac_executable_extensions; do 5324 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 5325 ac_cv_path_BASENAME="$as_dir/$ac_word$ac_exec_ext" 5326 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 5327 break 2 5328 fi 5329 done 5330 done 5331 IFS=$as_save_IFS 5332 5333 ;; 5334 esac 5335 fi 5336 BASENAME=$ac_cv_path_BASENAME 5337 if test -n "$BASENAME"; then 5338 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BASENAME" >&5 5339 $as_echo "$BASENAME" >&6; } 5340 else 5341 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 5342 $as_echo "no" >&6; } 5343 fi 5344 5345 5346 test -n "$BASENAME" && break 5347 done 5348 5349 else 5350 # If it succeeded, then it was overridden by the user. We will use it 5351 # for the tool. 5352 5353 # First remove it from the list of overridden variables, so we can test 5354 # for unknown variables in the end. 5355 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 5356 5357 # Check if we try to supply an empty value 5358 if test "x$BASENAME" = x; then 5359 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool BASENAME= (no value)" >&5 5360 $as_echo "$as_me: Setting user supplied tool BASENAME= (no value)" >&6;} 5361 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for BASENAME" >&5 5362 $as_echo_n "checking for BASENAME... " >&6; } 5363 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 5364 $as_echo "disabled" >&6; } 5365 else 5366 # Check if the provided tool contains a complete path. 5367 tool_specified="$BASENAME" 5368 tool_basename="${tool_specified##*/}" 5369 if test "x$tool_basename" = "x$tool_specified"; then 5370 # A command without a complete path is provided, search $PATH. 5371 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool BASENAME=$tool_basename" >&5 5372 $as_echo "$as_me: Will search for user supplied tool BASENAME=$tool_basename" >&6;} 5373 # Extract the first word of "$tool_basename", so it can be a program name with args. 5374 set dummy $tool_basename; ac_word=$2 5375 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 5376 $as_echo_n "checking for $ac_word... " >&6; } 5377 if ${ac_cv_path_BASENAME+:} false; then : 5378 $as_echo_n "(cached) " >&6 5379 else 5380 case $BASENAME in 5381 [\\/]* | ?:[\\/]*) 5382 ac_cv_path_BASENAME="$BASENAME" # Let the user override the test with a path. 5383 ;; 5384 *) 5385 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 5386 for as_dir in $PATH 5387 do 5388 IFS=$as_save_IFS 5389 test -z "$as_dir" && as_dir=. 5390 for ac_exec_ext in '' $ac_executable_extensions; do 5391 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 5392 ac_cv_path_BASENAME="$as_dir/$ac_word$ac_exec_ext" 5393 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 5394 break 2 5395 fi 5396 done 5397 done 5398 IFS=$as_save_IFS 5399 5400 ;; 5401 esac 5402 fi 5403 BASENAME=$ac_cv_path_BASENAME 5404 if test -n "$BASENAME"; then 5405 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BASENAME" >&5 5406 $as_echo "$BASENAME" >&6; } 5407 else 5408 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 5409 $as_echo "no" >&6; } 5410 fi 5411 5412 5413 if test "x$BASENAME" = x; then 5414 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 5415 fi 5416 else 5417 # Otherwise we believe it is a complete path. Use it as it is. 5418 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool BASENAME=$tool_specified" >&5 5419 $as_echo "$as_me: Will use user supplied tool BASENAME=$tool_specified" >&6;} 5420 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for BASENAME" >&5 5421 $as_echo_n "checking for BASENAME... " >&6; } 5422 if test ! -x "$tool_specified"; then 5423 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 5424 $as_echo "not found" >&6; } 5425 as_fn_error $? "User supplied tool BASENAME=$tool_specified does not exist or is not executable" "$LINENO" 5 5426 fi 5427 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 5428 $as_echo "$tool_specified" >&6; } 5429 fi 5430 fi 5431 fi 5432 5433 fi 5434 5435 5436 5437 if test "x$BASENAME" = x; then 5438 as_fn_error $? "Could not find required tool for BASENAME" "$LINENO" 5 5439 fi 5440 5441 5442 5443 5444 5445 # Publish this variable in the help. 5446 5447 5448 if [ -z "${BASH+x}" ]; then 5449 # The variable is not set by user, try to locate tool using the code snippet 5450 for ac_prog in bash 5451 do 5452 # Extract the first word of "$ac_prog", so it can be a program name with args. 5453 set dummy $ac_prog; ac_word=$2 5454 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 5455 $as_echo_n "checking for $ac_word... " >&6; } 5456 if ${ac_cv_path_BASH+:} false; then : 5457 $as_echo_n "(cached) " >&6 5458 else 5459 case $BASH in 5460 [\\/]* | ?:[\\/]*) 5461 ac_cv_path_BASH="$BASH" # Let the user override the test with a path. 5462 ;; 5463 *) 5464 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 5465 for as_dir in $PATH 5466 do 5467 IFS=$as_save_IFS 5468 test -z "$as_dir" && as_dir=. 5469 for ac_exec_ext in '' $ac_executable_extensions; do 5470 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 5471 ac_cv_path_BASH="$as_dir/$ac_word$ac_exec_ext" 5472 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 5473 break 2 5474 fi 5475 done 5476 done 5477 IFS=$as_save_IFS 5478 5479 ;; 5480 esac 5481 fi 5482 BASH=$ac_cv_path_BASH 5483 if test -n "$BASH"; then 5484 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BASH" >&5 5485 $as_echo "$BASH" >&6; } 5486 else 5487 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 5488 $as_echo "no" >&6; } 5489 fi 5490 5491 5492 test -n "$BASH" && break 5493 done 5494 5495 else 5496 # The variable is set, but is it from the command line or the environment? 5497 5498 # Try to remove the string !BASH! from our list. 5499 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!BASH!/} 5500 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 5501 # If it failed, the variable was not from the command line. Ignore it, 5502 # but warn the user (except for BASH, which is always set by the calling BASH). 5503 if test "xBASH" != xBASH; then 5504 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of BASH from the environment. Use command line variables instead." >&5 5505 $as_echo "$as_me: WARNING: Ignoring value of BASH from the environment. Use command line variables instead." >&2;} 5506 fi 5507 # Try to locate tool using the code snippet 5508 for ac_prog in bash 5509 do 5510 # Extract the first word of "$ac_prog", so it can be a program name with args. 5511 set dummy $ac_prog; ac_word=$2 5512 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 5513 $as_echo_n "checking for $ac_word... " >&6; } 5514 if ${ac_cv_path_BASH+:} false; then : 5515 $as_echo_n "(cached) " >&6 5516 else 5517 case $BASH in 5518 [\\/]* | ?:[\\/]*) 5519 ac_cv_path_BASH="$BASH" # Let the user override the test with a path. 5520 ;; 5521 *) 5522 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 5523 for as_dir in $PATH 5524 do 5525 IFS=$as_save_IFS 5526 test -z "$as_dir" && as_dir=. 5527 for ac_exec_ext in '' $ac_executable_extensions; do 5528 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 5529 ac_cv_path_BASH="$as_dir/$ac_word$ac_exec_ext" 5530 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 5531 break 2 5532 fi 5533 done 5534 done 5535 IFS=$as_save_IFS 5536 5537 ;; 5538 esac 5539 fi 5540 BASH=$ac_cv_path_BASH 5541 if test -n "$BASH"; then 5542 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BASH" >&5 5543 $as_echo "$BASH" >&6; } 5544 else 5545 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 5546 $as_echo "no" >&6; } 5547 fi 5548 5549 5550 test -n "$BASH" && break 5551 done 5552 5553 else 5554 # If it succeeded, then it was overridden by the user. We will use it 5555 # for the tool. 5556 5557 # First remove it from the list of overridden variables, so we can test 5558 # for unknown variables in the end. 5559 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 5560 5561 # Check if we try to supply an empty value 5562 if test "x$BASH" = x; then 5563 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool BASH= (no value)" >&5 5564 $as_echo "$as_me: Setting user supplied tool BASH= (no value)" >&6;} 5565 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for BASH" >&5 5566 $as_echo_n "checking for BASH... " >&6; } 5567 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 5568 $as_echo "disabled" >&6; } 5569 else 5570 # Check if the provided tool contains a complete path. 5571 tool_specified="$BASH" 5572 tool_basename="${tool_specified##*/}" 5573 if test "x$tool_basename" = "x$tool_specified"; then 5574 # A command without a complete path is provided, search $PATH. 5575 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool BASH=$tool_basename" >&5 5576 $as_echo "$as_me: Will search for user supplied tool BASH=$tool_basename" >&6;} 5577 # Extract the first word of "$tool_basename", so it can be a program name with args. 5578 set dummy $tool_basename; ac_word=$2 5579 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 5580 $as_echo_n "checking for $ac_word... " >&6; } 5581 if ${ac_cv_path_BASH+:} false; then : 5582 $as_echo_n "(cached) " >&6 5583 else 5584 case $BASH in 5585 [\\/]* | ?:[\\/]*) 5586 ac_cv_path_BASH="$BASH" # Let the user override the test with a path. 5587 ;; 5588 *) 5589 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 5590 for as_dir in $PATH 5591 do 5592 IFS=$as_save_IFS 5593 test -z "$as_dir" && as_dir=. 5594 for ac_exec_ext in '' $ac_executable_extensions; do 5595 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 5596 ac_cv_path_BASH="$as_dir/$ac_word$ac_exec_ext" 5597 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 5598 break 2 5599 fi 5600 done 5601 done 5602 IFS=$as_save_IFS 5603 5604 ;; 5605 esac 5606 fi 5607 BASH=$ac_cv_path_BASH 5608 if test -n "$BASH"; then 5609 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BASH" >&5 5610 $as_echo "$BASH" >&6; } 5611 else 5612 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 5613 $as_echo "no" >&6; } 5614 fi 5615 5616 5617 if test "x$BASH" = x; then 5618 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 5619 fi 5620 else 5621 # Otherwise we believe it is a complete path. Use it as it is. 5622 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool BASH=$tool_specified" >&5 5623 $as_echo "$as_me: Will use user supplied tool BASH=$tool_specified" >&6;} 5624 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for BASH" >&5 5625 $as_echo_n "checking for BASH... " >&6; } 5626 if test ! -x "$tool_specified"; then 5627 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 5628 $as_echo "not found" >&6; } 5629 as_fn_error $? "User supplied tool BASH=$tool_specified does not exist or is not executable" "$LINENO" 5 5630 fi 5631 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 5632 $as_echo "$tool_specified" >&6; } 5633 fi 5634 fi 5635 fi 5636 5637 fi 5638 5639 5640 5641 if test "x$BASH" = x; then 5642 as_fn_error $? "Could not find required tool for BASH" "$LINENO" 5 5643 fi 5644 5645 5646 5647 5648 5649 # Publish this variable in the help. 5650 5651 5652 if [ -z "${CAT+x}" ]; then 5653 # The variable is not set by user, try to locate tool using the code snippet 5654 for ac_prog in cat 5655 do 5656 # Extract the first word of "$ac_prog", so it can be a program name with args. 5657 set dummy $ac_prog; ac_word=$2 5658 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 5659 $as_echo_n "checking for $ac_word... " >&6; } 5660 if ${ac_cv_path_CAT+:} false; then : 5661 $as_echo_n "(cached) " >&6 5662 else 5663 case $CAT in 5664 [\\/]* | ?:[\\/]*) 5665 ac_cv_path_CAT="$CAT" # Let the user override the test with a path. 5666 ;; 5667 *) 5668 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 5669 for as_dir in $PATH 5670 do 5671 IFS=$as_save_IFS 5672 test -z "$as_dir" && as_dir=. 5673 for ac_exec_ext in '' $ac_executable_extensions; do 5674 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 5675 ac_cv_path_CAT="$as_dir/$ac_word$ac_exec_ext" 5676 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 5677 break 2 5678 fi 5679 done 5680 done 5681 IFS=$as_save_IFS 5682 5683 ;; 5684 esac 5685 fi 5686 CAT=$ac_cv_path_CAT 5687 if test -n "$CAT"; then 5688 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CAT" >&5 5689 $as_echo "$CAT" >&6; } 5690 else 5691 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 5692 $as_echo "no" >&6; } 5693 fi 5694 5695 5696 test -n "$CAT" && break 5697 done 5698 5699 else 5700 # The variable is set, but is it from the command line or the environment? 5701 5702 # Try to remove the string !CAT! from our list. 5703 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!CAT!/} 5704 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 5705 # If it failed, the variable was not from the command line. Ignore it, 5706 # but warn the user (except for BASH, which is always set by the calling BASH). 5707 if test "xCAT" != xBASH; then 5708 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of CAT from the environment. Use command line variables instead." >&5 5709 $as_echo "$as_me: WARNING: Ignoring value of CAT from the environment. Use command line variables instead." >&2;} 5710 fi 5711 # Try to locate tool using the code snippet 5712 for ac_prog in cat 5713 do 5714 # Extract the first word of "$ac_prog", so it can be a program name with args. 5715 set dummy $ac_prog; ac_word=$2 5716 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 5717 $as_echo_n "checking for $ac_word... " >&6; } 5718 if ${ac_cv_path_CAT+:} false; then : 5719 $as_echo_n "(cached) " >&6 5720 else 5721 case $CAT in 5722 [\\/]* | ?:[\\/]*) 5723 ac_cv_path_CAT="$CAT" # Let the user override the test with a path. 5724 ;; 5725 *) 5726 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 5727 for as_dir in $PATH 5728 do 5729 IFS=$as_save_IFS 5730 test -z "$as_dir" && as_dir=. 5731 for ac_exec_ext in '' $ac_executable_extensions; do 5732 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 5733 ac_cv_path_CAT="$as_dir/$ac_word$ac_exec_ext" 5734 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 5735 break 2 5736 fi 5737 done 5738 done 5739 IFS=$as_save_IFS 5740 5741 ;; 5742 esac 5743 fi 5744 CAT=$ac_cv_path_CAT 5745 if test -n "$CAT"; then 5746 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CAT" >&5 5747 $as_echo "$CAT" >&6; } 5748 else 5749 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 5750 $as_echo "no" >&6; } 5751 fi 5752 5753 5754 test -n "$CAT" && break 5755 done 5756 5757 else 5758 # If it succeeded, then it was overridden by the user. We will use it 5759 # for the tool. 5760 5761 # First remove it from the list of overridden variables, so we can test 5762 # for unknown variables in the end. 5763 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 5764 5765 # Check if we try to supply an empty value 5766 if test "x$CAT" = x; then 5767 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool CAT= (no value)" >&5 5768 $as_echo "$as_me: Setting user supplied tool CAT= (no value)" >&6;} 5769 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for CAT" >&5 5770 $as_echo_n "checking for CAT... " >&6; } 5771 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 5772 $as_echo "disabled" >&6; } 5773 else 5774 # Check if the provided tool contains a complete path. 5775 tool_specified="$CAT" 5776 tool_basename="${tool_specified##*/}" 5777 if test "x$tool_basename" = "x$tool_specified"; then 5778 # A command without a complete path is provided, search $PATH. 5779 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool CAT=$tool_basename" >&5 5780 $as_echo "$as_me: Will search for user supplied tool CAT=$tool_basename" >&6;} 5781 # Extract the first word of "$tool_basename", so it can be a program name with args. 5782 set dummy $tool_basename; ac_word=$2 5783 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 5784 $as_echo_n "checking for $ac_word... " >&6; } 5785 if ${ac_cv_path_CAT+:} false; then : 5786 $as_echo_n "(cached) " >&6 5787 else 5788 case $CAT in 5789 [\\/]* | ?:[\\/]*) 5790 ac_cv_path_CAT="$CAT" # Let the user override the test with a path. 5791 ;; 5792 *) 5793 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 5794 for as_dir in $PATH 5795 do 5796 IFS=$as_save_IFS 5797 test -z "$as_dir" && as_dir=. 5798 for ac_exec_ext in '' $ac_executable_extensions; do 5799 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 5800 ac_cv_path_CAT="$as_dir/$ac_word$ac_exec_ext" 5801 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 5802 break 2 5803 fi 5804 done 5805 done 5806 IFS=$as_save_IFS 5807 5808 ;; 5809 esac 5810 fi 5811 CAT=$ac_cv_path_CAT 5812 if test -n "$CAT"; then 5813 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CAT" >&5 5814 $as_echo "$CAT" >&6; } 5815 else 5816 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 5817 $as_echo "no" >&6; } 5818 fi 5819 5820 5821 if test "x$CAT" = x; then 5822 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 5823 fi 5824 else 5825 # Otherwise we believe it is a complete path. Use it as it is. 5826 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool CAT=$tool_specified" >&5 5827 $as_echo "$as_me: Will use user supplied tool CAT=$tool_specified" >&6;} 5828 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for CAT" >&5 5829 $as_echo_n "checking for CAT... " >&6; } 5830 if test ! -x "$tool_specified"; then 5831 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 5832 $as_echo "not found" >&6; } 5833 as_fn_error $? "User supplied tool CAT=$tool_specified does not exist or is not executable" "$LINENO" 5 5834 fi 5835 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 5836 $as_echo "$tool_specified" >&6; } 5837 fi 5838 fi 5839 fi 5840 5841 fi 5842 5843 5844 5845 if test "x$CAT" = x; then 5846 as_fn_error $? "Could not find required tool for CAT" "$LINENO" 5 5847 fi 5848 5849 5850 5851 5852 5853 # Publish this variable in the help. 5854 5855 5856 if [ -z "${CHMOD+x}" ]; then 5857 # The variable is not set by user, try to locate tool using the code snippet 5858 for ac_prog in chmod 5859 do 5860 # Extract the first word of "$ac_prog", so it can be a program name with args. 5861 set dummy $ac_prog; ac_word=$2 5862 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 5863 $as_echo_n "checking for $ac_word... " >&6; } 5864 if ${ac_cv_path_CHMOD+:} false; then : 5865 $as_echo_n "(cached) " >&6 5866 else 5867 case $CHMOD in 5868 [\\/]* | ?:[\\/]*) 5869 ac_cv_path_CHMOD="$CHMOD" # Let the user override the test with a path. 5870 ;; 5871 *) 5872 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 5873 for as_dir in $PATH 5874 do 5875 IFS=$as_save_IFS 5876 test -z "$as_dir" && as_dir=. 5877 for ac_exec_ext in '' $ac_executable_extensions; do 5878 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 5879 ac_cv_path_CHMOD="$as_dir/$ac_word$ac_exec_ext" 5880 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 5881 break 2 5882 fi 5883 done 5884 done 5885 IFS=$as_save_IFS 5886 5887 ;; 5888 esac 5889 fi 5890 CHMOD=$ac_cv_path_CHMOD 5891 if test -n "$CHMOD"; then 5892 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CHMOD" >&5 5893 $as_echo "$CHMOD" >&6; } 5894 else 5895 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 5896 $as_echo "no" >&6; } 5897 fi 5898 5899 5900 test -n "$CHMOD" && break 5901 done 5902 5903 else 5904 # The variable is set, but is it from the command line or the environment? 5905 5906 # Try to remove the string !CHMOD! from our list. 5907 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!CHMOD!/} 5908 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 5909 # If it failed, the variable was not from the command line. Ignore it, 5910 # but warn the user (except for BASH, which is always set by the calling BASH). 5911 if test "xCHMOD" != xBASH; then 5912 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of CHMOD from the environment. Use command line variables instead." >&5 5913 $as_echo "$as_me: WARNING: Ignoring value of CHMOD from the environment. Use command line variables instead." >&2;} 5914 fi 5915 # Try to locate tool using the code snippet 5916 for ac_prog in chmod 5917 do 5918 # Extract the first word of "$ac_prog", so it can be a program name with args. 5919 set dummy $ac_prog; ac_word=$2 5920 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 5921 $as_echo_n "checking for $ac_word... " >&6; } 5922 if ${ac_cv_path_CHMOD+:} false; then : 5923 $as_echo_n "(cached) " >&6 5924 else 5925 case $CHMOD in 5926 [\\/]* | ?:[\\/]*) 5927 ac_cv_path_CHMOD="$CHMOD" # Let the user override the test with a path. 5928 ;; 5929 *) 5930 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 5931 for as_dir in $PATH 5932 do 5933 IFS=$as_save_IFS 5934 test -z "$as_dir" && as_dir=. 5935 for ac_exec_ext in '' $ac_executable_extensions; do 5936 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 5937 ac_cv_path_CHMOD="$as_dir/$ac_word$ac_exec_ext" 5938 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 5939 break 2 5940 fi 5941 done 5942 done 5943 IFS=$as_save_IFS 5944 5945 ;; 5946 esac 5947 fi 5948 CHMOD=$ac_cv_path_CHMOD 5949 if test -n "$CHMOD"; then 5950 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CHMOD" >&5 5951 $as_echo "$CHMOD" >&6; } 5952 else 5953 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 5954 $as_echo "no" >&6; } 5955 fi 5956 5957 5958 test -n "$CHMOD" && break 5959 done 5960 5961 else 5962 # If it succeeded, then it was overridden by the user. We will use it 5963 # for the tool. 5964 5965 # First remove it from the list of overridden variables, so we can test 5966 # for unknown variables in the end. 5967 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 5968 5969 # Check if we try to supply an empty value 5970 if test "x$CHMOD" = x; then 5971 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool CHMOD= (no value)" >&5 5972 $as_echo "$as_me: Setting user supplied tool CHMOD= (no value)" >&6;} 5973 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for CHMOD" >&5 5974 $as_echo_n "checking for CHMOD... " >&6; } 5975 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 5976 $as_echo "disabled" >&6; } 5977 else 5978 # Check if the provided tool contains a complete path. 5979 tool_specified="$CHMOD" 5980 tool_basename="${tool_specified##*/}" 5981 if test "x$tool_basename" = "x$tool_specified"; then 5982 # A command without a complete path is provided, search $PATH. 5983 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool CHMOD=$tool_basename" >&5 5984 $as_echo "$as_me: Will search for user supplied tool CHMOD=$tool_basename" >&6;} 5985 # Extract the first word of "$tool_basename", so it can be a program name with args. 5986 set dummy $tool_basename; ac_word=$2 5987 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 5988 $as_echo_n "checking for $ac_word... " >&6; } 5989 if ${ac_cv_path_CHMOD+:} false; then : 5990 $as_echo_n "(cached) " >&6 5991 else 5992 case $CHMOD in 5993 [\\/]* | ?:[\\/]*) 5994 ac_cv_path_CHMOD="$CHMOD" # Let the user override the test with a path. 5995 ;; 5996 *) 5997 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 5998 for as_dir in $PATH 5999 do 6000 IFS=$as_save_IFS 6001 test -z "$as_dir" && as_dir=. 6002 for ac_exec_ext in '' $ac_executable_extensions; do 6003 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 6004 ac_cv_path_CHMOD="$as_dir/$ac_word$ac_exec_ext" 6005 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 6006 break 2 6007 fi 6008 done 6009 done 6010 IFS=$as_save_IFS 6011 6012 ;; 6013 esac 6014 fi 6015 CHMOD=$ac_cv_path_CHMOD 6016 if test -n "$CHMOD"; then 6017 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CHMOD" >&5 6018 $as_echo "$CHMOD" >&6; } 6019 else 6020 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 6021 $as_echo "no" >&6; } 6022 fi 6023 6024 6025 if test "x$CHMOD" = x; then 6026 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 6027 fi 6028 else 6029 # Otherwise we believe it is a complete path. Use it as it is. 6030 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool CHMOD=$tool_specified" >&5 6031 $as_echo "$as_me: Will use user supplied tool CHMOD=$tool_specified" >&6;} 6032 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for CHMOD" >&5 6033 $as_echo_n "checking for CHMOD... " >&6; } 6034 if test ! -x "$tool_specified"; then 6035 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 6036 $as_echo "not found" >&6; } 6037 as_fn_error $? "User supplied tool CHMOD=$tool_specified does not exist or is not executable" "$LINENO" 5 6038 fi 6039 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 6040 $as_echo "$tool_specified" >&6; } 6041 fi 6042 fi 6043 fi 6044 6045 fi 6046 6047 6048 6049 if test "x$CHMOD" = x; then 6050 as_fn_error $? "Could not find required tool for CHMOD" "$LINENO" 5 6051 fi 6052 6053 6054 6055 6056 6057 # Publish this variable in the help. 6058 6059 6060 if [ -z "${CMP+x}" ]; then 6061 # The variable is not set by user, try to locate tool using the code snippet 6062 for ac_prog in cmp 6063 do 6064 # Extract the first word of "$ac_prog", so it can be a program name with args. 6065 set dummy $ac_prog; ac_word=$2 6066 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 6067 $as_echo_n "checking for $ac_word... " >&6; } 6068 if ${ac_cv_path_CMP+:} false; then : 6069 $as_echo_n "(cached) " >&6 6070 else 6071 case $CMP in 6072 [\\/]* | ?:[\\/]*) 6073 ac_cv_path_CMP="$CMP" # Let the user override the test with a path. 6074 ;; 6075 *) 6076 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 6077 for as_dir in $PATH 6078 do 6079 IFS=$as_save_IFS 6080 test -z "$as_dir" && as_dir=. 6081 for ac_exec_ext in '' $ac_executable_extensions; do 6082 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 6083 ac_cv_path_CMP="$as_dir/$ac_word$ac_exec_ext" 6084 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 6085 break 2 6086 fi 6087 done 6088 done 6089 IFS=$as_save_IFS 6090 6091 ;; 6092 esac 6093 fi 6094 CMP=$ac_cv_path_CMP 6095 if test -n "$CMP"; then 6096 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CMP" >&5 6097 $as_echo "$CMP" >&6; } 6098 else 6099 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 6100 $as_echo "no" >&6; } 6101 fi 6102 6103 6104 test -n "$CMP" && break 6105 done 6106 6107 else 6108 # The variable is set, but is it from the command line or the environment? 6109 6110 # Try to remove the string !CMP! from our list. 6111 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!CMP!/} 6112 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 6113 # If it failed, the variable was not from the command line. Ignore it, 6114 # but warn the user (except for BASH, which is always set by the calling BASH). 6115 if test "xCMP" != xBASH; then 6116 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of CMP from the environment. Use command line variables instead." >&5 6117 $as_echo "$as_me: WARNING: Ignoring value of CMP from the environment. Use command line variables instead." >&2;} 6118 fi 6119 # Try to locate tool using the code snippet 6120 for ac_prog in cmp 6121 do 6122 # Extract the first word of "$ac_prog", so it can be a program name with args. 6123 set dummy $ac_prog; ac_word=$2 6124 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 6125 $as_echo_n "checking for $ac_word... " >&6; } 6126 if ${ac_cv_path_CMP+:} false; then : 6127 $as_echo_n "(cached) " >&6 6128 else 6129 case $CMP in 6130 [\\/]* | ?:[\\/]*) 6131 ac_cv_path_CMP="$CMP" # Let the user override the test with a path. 6132 ;; 6133 *) 6134 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 6135 for as_dir in $PATH 6136 do 6137 IFS=$as_save_IFS 6138 test -z "$as_dir" && as_dir=. 6139 for ac_exec_ext in '' $ac_executable_extensions; do 6140 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 6141 ac_cv_path_CMP="$as_dir/$ac_word$ac_exec_ext" 6142 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 6143 break 2 6144 fi 6145 done 6146 done 6147 IFS=$as_save_IFS 6148 6149 ;; 6150 esac 6151 fi 6152 CMP=$ac_cv_path_CMP 6153 if test -n "$CMP"; then 6154 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CMP" >&5 6155 $as_echo "$CMP" >&6; } 6156 else 6157 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 6158 $as_echo "no" >&6; } 6159 fi 6160 6161 6162 test -n "$CMP" && break 6163 done 6164 6165 else 6166 # If it succeeded, then it was overridden by the user. We will use it 6167 # for the tool. 6168 6169 # First remove it from the list of overridden variables, so we can test 6170 # for unknown variables in the end. 6171 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 6172 6173 # Check if we try to supply an empty value 6174 if test "x$CMP" = x; then 6175 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool CMP= (no value)" >&5 6176 $as_echo "$as_me: Setting user supplied tool CMP= (no value)" >&6;} 6177 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for CMP" >&5 6178 $as_echo_n "checking for CMP... " >&6; } 6179 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 6180 $as_echo "disabled" >&6; } 6181 else 6182 # Check if the provided tool contains a complete path. 6183 tool_specified="$CMP" 6184 tool_basename="${tool_specified##*/}" 6185 if test "x$tool_basename" = "x$tool_specified"; then 6186 # A command without a complete path is provided, search $PATH. 6187 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool CMP=$tool_basename" >&5 6188 $as_echo "$as_me: Will search for user supplied tool CMP=$tool_basename" >&6;} 6189 # Extract the first word of "$tool_basename", so it can be a program name with args. 6190 set dummy $tool_basename; ac_word=$2 6191 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 6192 $as_echo_n "checking for $ac_word... " >&6; } 6193 if ${ac_cv_path_CMP+:} false; then : 6194 $as_echo_n "(cached) " >&6 6195 else 6196 case $CMP in 6197 [\\/]* | ?:[\\/]*) 6198 ac_cv_path_CMP="$CMP" # Let the user override the test with a path. 6199 ;; 6200 *) 6201 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 6202 for as_dir in $PATH 6203 do 6204 IFS=$as_save_IFS 6205 test -z "$as_dir" && as_dir=. 6206 for ac_exec_ext in '' $ac_executable_extensions; do 6207 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 6208 ac_cv_path_CMP="$as_dir/$ac_word$ac_exec_ext" 6209 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 6210 break 2 6211 fi 6212 done 6213 done 6214 IFS=$as_save_IFS 6215 6216 ;; 6217 esac 6218 fi 6219 CMP=$ac_cv_path_CMP 6220 if test -n "$CMP"; then 6221 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CMP" >&5 6222 $as_echo "$CMP" >&6; } 6223 else 6224 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 6225 $as_echo "no" >&6; } 6226 fi 6227 6228 6229 if test "x$CMP" = x; then 6230 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 6231 fi 6232 else 6233 # Otherwise we believe it is a complete path. Use it as it is. 6234 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool CMP=$tool_specified" >&5 6235 $as_echo "$as_me: Will use user supplied tool CMP=$tool_specified" >&6;} 6236 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for CMP" >&5 6237 $as_echo_n "checking for CMP... " >&6; } 6238 if test ! -x "$tool_specified"; then 6239 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 6240 $as_echo "not found" >&6; } 6241 as_fn_error $? "User supplied tool CMP=$tool_specified does not exist or is not executable" "$LINENO" 5 6242 fi 6243 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 6244 $as_echo "$tool_specified" >&6; } 6245 fi 6246 fi 6247 fi 6248 6249 fi 6250 6251 6252 6253 if test "x$CMP" = x; then 6254 as_fn_error $? "Could not find required tool for CMP" "$LINENO" 5 6255 fi 6256 6257 6258 6259 6260 6261 # Publish this variable in the help. 6262 6263 6264 if [ -z "${COMM+x}" ]; then 6265 # The variable is not set by user, try to locate tool using the code snippet 6266 for ac_prog in comm 6267 do 6268 # Extract the first word of "$ac_prog", so it can be a program name with args. 6269 set dummy $ac_prog; ac_word=$2 6270 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 6271 $as_echo_n "checking for $ac_word... " >&6; } 6272 if ${ac_cv_path_COMM+:} false; then : 6273 $as_echo_n "(cached) " >&6 6274 else 6275 case $COMM in 6276 [\\/]* | ?:[\\/]*) 6277 ac_cv_path_COMM="$COMM" # Let the user override the test with a path. 6278 ;; 6279 *) 6280 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 6281 for as_dir in $PATH 6282 do 6283 IFS=$as_save_IFS 6284 test -z "$as_dir" && as_dir=. 6285 for ac_exec_ext in '' $ac_executable_extensions; do 6286 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 6287 ac_cv_path_COMM="$as_dir/$ac_word$ac_exec_ext" 6288 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 6289 break 2 6290 fi 6291 done 6292 done 6293 IFS=$as_save_IFS 6294 6295 ;; 6296 esac 6297 fi 6298 COMM=$ac_cv_path_COMM 6299 if test -n "$COMM"; then 6300 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $COMM" >&5 6301 $as_echo "$COMM" >&6; } 6302 else 6303 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 6304 $as_echo "no" >&6; } 6305 fi 6306 6307 6308 test -n "$COMM" && break 6309 done 6310 6311 else 6312 # The variable is set, but is it from the command line or the environment? 6313 6314 # Try to remove the string !COMM! from our list. 6315 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!COMM!/} 6316 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 6317 # If it failed, the variable was not from the command line. Ignore it, 6318 # but warn the user (except for BASH, which is always set by the calling BASH). 6319 if test "xCOMM" != xBASH; then 6320 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of COMM from the environment. Use command line variables instead." >&5 6321 $as_echo "$as_me: WARNING: Ignoring value of COMM from the environment. Use command line variables instead." >&2;} 6322 fi 6323 # Try to locate tool using the code snippet 6324 for ac_prog in comm 6325 do 6326 # Extract the first word of "$ac_prog", so it can be a program name with args. 6327 set dummy $ac_prog; ac_word=$2 6328 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 6329 $as_echo_n "checking for $ac_word... " >&6; } 6330 if ${ac_cv_path_COMM+:} false; then : 6331 $as_echo_n "(cached) " >&6 6332 else 6333 case $COMM in 6334 [\\/]* | ?:[\\/]*) 6335 ac_cv_path_COMM="$COMM" # Let the user override the test with a path. 6336 ;; 6337 *) 6338 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 6339 for as_dir in $PATH 6340 do 6341 IFS=$as_save_IFS 6342 test -z "$as_dir" && as_dir=. 6343 for ac_exec_ext in '' $ac_executable_extensions; do 6344 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 6345 ac_cv_path_COMM="$as_dir/$ac_word$ac_exec_ext" 6346 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 6347 break 2 6348 fi 6349 done 6350 done 6351 IFS=$as_save_IFS 6352 6353 ;; 6354 esac 6355 fi 6356 COMM=$ac_cv_path_COMM 6357 if test -n "$COMM"; then 6358 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $COMM" >&5 6359 $as_echo "$COMM" >&6; } 6360 else 6361 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 6362 $as_echo "no" >&6; } 6363 fi 6364 6365 6366 test -n "$COMM" && break 6367 done 6368 6369 else 6370 # If it succeeded, then it was overridden by the user. We will use it 6371 # for the tool. 6372 6373 # First remove it from the list of overridden variables, so we can test 6374 # for unknown variables in the end. 6375 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 6376 6377 # Check if we try to supply an empty value 6378 if test "x$COMM" = x; then 6379 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool COMM= (no value)" >&5 6380 $as_echo "$as_me: Setting user supplied tool COMM= (no value)" >&6;} 6381 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for COMM" >&5 6382 $as_echo_n "checking for COMM... " >&6; } 6383 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 6384 $as_echo "disabled" >&6; } 6385 else 6386 # Check if the provided tool contains a complete path. 6387 tool_specified="$COMM" 6388 tool_basename="${tool_specified##*/}" 6389 if test "x$tool_basename" = "x$tool_specified"; then 6390 # A command without a complete path is provided, search $PATH. 6391 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool COMM=$tool_basename" >&5 6392 $as_echo "$as_me: Will search for user supplied tool COMM=$tool_basename" >&6;} 6393 # Extract the first word of "$tool_basename", so it can be a program name with args. 6394 set dummy $tool_basename; ac_word=$2 6395 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 6396 $as_echo_n "checking for $ac_word... " >&6; } 6397 if ${ac_cv_path_COMM+:} false; then : 6398 $as_echo_n "(cached) " >&6 6399 else 6400 case $COMM in 6401 [\\/]* | ?:[\\/]*) 6402 ac_cv_path_COMM="$COMM" # Let the user override the test with a path. 6403 ;; 6404 *) 6405 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 6406 for as_dir in $PATH 6407 do 6408 IFS=$as_save_IFS 6409 test -z "$as_dir" && as_dir=. 6410 for ac_exec_ext in '' $ac_executable_extensions; do 6411 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 6412 ac_cv_path_COMM="$as_dir/$ac_word$ac_exec_ext" 6413 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 6414 break 2 6415 fi 6416 done 6417 done 6418 IFS=$as_save_IFS 6419 6420 ;; 6421 esac 6422 fi 6423 COMM=$ac_cv_path_COMM 6424 if test -n "$COMM"; then 6425 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $COMM" >&5 6426 $as_echo "$COMM" >&6; } 6427 else 6428 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 6429 $as_echo "no" >&6; } 6430 fi 6431 6432 6433 if test "x$COMM" = x; then 6434 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 6435 fi 6436 else 6437 # Otherwise we believe it is a complete path. Use it as it is. 6438 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool COMM=$tool_specified" >&5 6439 $as_echo "$as_me: Will use user supplied tool COMM=$tool_specified" >&6;} 6440 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for COMM" >&5 6441 $as_echo_n "checking for COMM... " >&6; } 6442 if test ! -x "$tool_specified"; then 6443 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 6444 $as_echo "not found" >&6; } 6445 as_fn_error $? "User supplied tool COMM=$tool_specified does not exist or is not executable" "$LINENO" 5 6446 fi 6447 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 6448 $as_echo "$tool_specified" >&6; } 6449 fi 6450 fi 6451 fi 6452 6453 fi 6454 6455 6456 6457 if test "x$COMM" = x; then 6458 as_fn_error $? "Could not find required tool for COMM" "$LINENO" 5 6459 fi 6460 6461 6462 6463 6464 6465 # Publish this variable in the help. 6466 6467 6468 if [ -z "${CP+x}" ]; then 6469 # The variable is not set by user, try to locate tool using the code snippet 6470 for ac_prog in cp 6471 do 6472 # Extract the first word of "$ac_prog", so it can be a program name with args. 6473 set dummy $ac_prog; ac_word=$2 6474 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 6475 $as_echo_n "checking for $ac_word... " >&6; } 6476 if ${ac_cv_path_CP+:} false; then : 6477 $as_echo_n "(cached) " >&6 6478 else 6479 case $CP in 6480 [\\/]* | ?:[\\/]*) 6481 ac_cv_path_CP="$CP" # Let the user override the test with a path. 6482 ;; 6483 *) 6484 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 6485 for as_dir in $PATH 6486 do 6487 IFS=$as_save_IFS 6488 test -z "$as_dir" && as_dir=. 6489 for ac_exec_ext in '' $ac_executable_extensions; do 6490 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 6491 ac_cv_path_CP="$as_dir/$ac_word$ac_exec_ext" 6492 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 6493 break 2 6494 fi 6495 done 6496 done 6497 IFS=$as_save_IFS 6498 6499 ;; 6500 esac 6501 fi 6502 CP=$ac_cv_path_CP 6503 if test -n "$CP"; then 6504 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CP" >&5 6505 $as_echo "$CP" >&6; } 6506 else 6507 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 6508 $as_echo "no" >&6; } 6509 fi 6510 6511 6512 test -n "$CP" && break 6513 done 6514 6515 else 6516 # The variable is set, but is it from the command line or the environment? 6517 6518 # Try to remove the string !CP! from our list. 6519 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!CP!/} 6520 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 6521 # If it failed, the variable was not from the command line. Ignore it, 6522 # but warn the user (except for BASH, which is always set by the calling BASH). 6523 if test "xCP" != xBASH; then 6524 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of CP from the environment. Use command line variables instead." >&5 6525 $as_echo "$as_me: WARNING: Ignoring value of CP from the environment. Use command line variables instead." >&2;} 6526 fi 6527 # Try to locate tool using the code snippet 6528 for ac_prog in cp 6529 do 6530 # Extract the first word of "$ac_prog", so it can be a program name with args. 6531 set dummy $ac_prog; ac_word=$2 6532 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 6533 $as_echo_n "checking for $ac_word... " >&6; } 6534 if ${ac_cv_path_CP+:} false; then : 6535 $as_echo_n "(cached) " >&6 6536 else 6537 case $CP in 6538 [\\/]* | ?:[\\/]*) 6539 ac_cv_path_CP="$CP" # Let the user override the test with a path. 6540 ;; 6541 *) 6542 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 6543 for as_dir in $PATH 6544 do 6545 IFS=$as_save_IFS 6546 test -z "$as_dir" && as_dir=. 6547 for ac_exec_ext in '' $ac_executable_extensions; do 6548 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 6549 ac_cv_path_CP="$as_dir/$ac_word$ac_exec_ext" 6550 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 6551 break 2 6552 fi 6553 done 6554 done 6555 IFS=$as_save_IFS 6556 6557 ;; 6558 esac 6559 fi 6560 CP=$ac_cv_path_CP 6561 if test -n "$CP"; then 6562 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CP" >&5 6563 $as_echo "$CP" >&6; } 6564 else 6565 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 6566 $as_echo "no" >&6; } 6567 fi 6568 6569 6570 test -n "$CP" && break 6571 done 6572 6573 else 6574 # If it succeeded, then it was overridden by the user. We will use it 6575 # for the tool. 6576 6577 # First remove it from the list of overridden variables, so we can test 6578 # for unknown variables in the end. 6579 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 6580 6581 # Check if we try to supply an empty value 6582 if test "x$CP" = x; then 6583 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool CP= (no value)" >&5 6584 $as_echo "$as_me: Setting user supplied tool CP= (no value)" >&6;} 6585 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for CP" >&5 6586 $as_echo_n "checking for CP... " >&6; } 6587 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 6588 $as_echo "disabled" >&6; } 6589 else 6590 # Check if the provided tool contains a complete path. 6591 tool_specified="$CP" 6592 tool_basename="${tool_specified##*/}" 6593 if test "x$tool_basename" = "x$tool_specified"; then 6594 # A command without a complete path is provided, search $PATH. 6595 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool CP=$tool_basename" >&5 6596 $as_echo "$as_me: Will search for user supplied tool CP=$tool_basename" >&6;} 6597 # Extract the first word of "$tool_basename", so it can be a program name with args. 6598 set dummy $tool_basename; ac_word=$2 6599 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 6600 $as_echo_n "checking for $ac_word... " >&6; } 6601 if ${ac_cv_path_CP+:} false; then : 6602 $as_echo_n "(cached) " >&6 6603 else 6604 case $CP in 6605 [\\/]* | ?:[\\/]*) 6606 ac_cv_path_CP="$CP" # Let the user override the test with a path. 6607 ;; 6608 *) 6609 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 6610 for as_dir in $PATH 6611 do 6612 IFS=$as_save_IFS 6613 test -z "$as_dir" && as_dir=. 6614 for ac_exec_ext in '' $ac_executable_extensions; do 6615 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 6616 ac_cv_path_CP="$as_dir/$ac_word$ac_exec_ext" 6617 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 6618 break 2 6619 fi 6620 done 6621 done 6622 IFS=$as_save_IFS 6623 6624 ;; 6625 esac 6626 fi 6627 CP=$ac_cv_path_CP 6628 if test -n "$CP"; then 6629 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CP" >&5 6630 $as_echo "$CP" >&6; } 6631 else 6632 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 6633 $as_echo "no" >&6; } 6634 fi 6635 6636 6637 if test "x$CP" = x; then 6638 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 6639 fi 6640 else 6641 # Otherwise we believe it is a complete path. Use it as it is. 6642 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool CP=$tool_specified" >&5 6643 $as_echo "$as_me: Will use user supplied tool CP=$tool_specified" >&6;} 6644 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for CP" >&5 6645 $as_echo_n "checking for CP... " >&6; } 6646 if test ! -x "$tool_specified"; then 6647 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 6648 $as_echo "not found" >&6; } 6649 as_fn_error $? "User supplied tool CP=$tool_specified does not exist or is not executable" "$LINENO" 5 6650 fi 6651 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 6652 $as_echo "$tool_specified" >&6; } 6653 fi 6654 fi 6655 fi 6656 6657 fi 6658 6659 6660 6661 if test "x$CP" = x; then 6662 as_fn_error $? "Could not find required tool for CP" "$LINENO" 5 6663 fi 6664 6665 6666 6667 6668 6669 # Publish this variable in the help. 6670 6671 6672 if [ -z "${CUT+x}" ]; then 6673 # The variable is not set by user, try to locate tool using the code snippet 6674 for ac_prog in cut 6675 do 6676 # Extract the first word of "$ac_prog", so it can be a program name with args. 6677 set dummy $ac_prog; ac_word=$2 6678 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 6679 $as_echo_n "checking for $ac_word... " >&6; } 6680 if ${ac_cv_path_CUT+:} false; then : 6681 $as_echo_n "(cached) " >&6 6682 else 6683 case $CUT in 6684 [\\/]* | ?:[\\/]*) 6685 ac_cv_path_CUT="$CUT" # Let the user override the test with a path. 6686 ;; 6687 *) 6688 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 6689 for as_dir in $PATH 6690 do 6691 IFS=$as_save_IFS 6692 test -z "$as_dir" && as_dir=. 6693 for ac_exec_ext in '' $ac_executable_extensions; do 6694 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 6695 ac_cv_path_CUT="$as_dir/$ac_word$ac_exec_ext" 6696 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 6697 break 2 6698 fi 6699 done 6700 done 6701 IFS=$as_save_IFS 6702 6703 ;; 6704 esac 6705 fi 6706 CUT=$ac_cv_path_CUT 6707 if test -n "$CUT"; then 6708 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CUT" >&5 6709 $as_echo "$CUT" >&6; } 6710 else 6711 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 6712 $as_echo "no" >&6; } 6713 fi 6714 6715 6716 test -n "$CUT" && break 6717 done 6718 6719 else 6720 # The variable is set, but is it from the command line or the environment? 6721 6722 # Try to remove the string !CUT! from our list. 6723 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!CUT!/} 6724 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 6725 # If it failed, the variable was not from the command line. Ignore it, 6726 # but warn the user (except for BASH, which is always set by the calling BASH). 6727 if test "xCUT" != xBASH; then 6728 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of CUT from the environment. Use command line variables instead." >&5 6729 $as_echo "$as_me: WARNING: Ignoring value of CUT from the environment. Use command line variables instead." >&2;} 6730 fi 6731 # Try to locate tool using the code snippet 6732 for ac_prog in cut 6733 do 6734 # Extract the first word of "$ac_prog", so it can be a program name with args. 6735 set dummy $ac_prog; ac_word=$2 6736 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 6737 $as_echo_n "checking for $ac_word... " >&6; } 6738 if ${ac_cv_path_CUT+:} false; then : 6739 $as_echo_n "(cached) " >&6 6740 else 6741 case $CUT in 6742 [\\/]* | ?:[\\/]*) 6743 ac_cv_path_CUT="$CUT" # Let the user override the test with a path. 6744 ;; 6745 *) 6746 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 6747 for as_dir in $PATH 6748 do 6749 IFS=$as_save_IFS 6750 test -z "$as_dir" && as_dir=. 6751 for ac_exec_ext in '' $ac_executable_extensions; do 6752 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 6753 ac_cv_path_CUT="$as_dir/$ac_word$ac_exec_ext" 6754 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 6755 break 2 6756 fi 6757 done 6758 done 6759 IFS=$as_save_IFS 6760 6761 ;; 6762 esac 6763 fi 6764 CUT=$ac_cv_path_CUT 6765 if test -n "$CUT"; then 6766 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CUT" >&5 6767 $as_echo "$CUT" >&6; } 6768 else 6769 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 6770 $as_echo "no" >&6; } 6771 fi 6772 6773 6774 test -n "$CUT" && break 6775 done 6776 6777 else 6778 # If it succeeded, then it was overridden by the user. We will use it 6779 # for the tool. 6780 6781 # First remove it from the list of overridden variables, so we can test 6782 # for unknown variables in the end. 6783 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 6784 6785 # Check if we try to supply an empty value 6786 if test "x$CUT" = x; then 6787 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool CUT= (no value)" >&5 6788 $as_echo "$as_me: Setting user supplied tool CUT= (no value)" >&6;} 6789 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for CUT" >&5 6790 $as_echo_n "checking for CUT... " >&6; } 6791 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 6792 $as_echo "disabled" >&6; } 6793 else 6794 # Check if the provided tool contains a complete path. 6795 tool_specified="$CUT" 6796 tool_basename="${tool_specified##*/}" 6797 if test "x$tool_basename" = "x$tool_specified"; then 6798 # A command without a complete path is provided, search $PATH. 6799 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool CUT=$tool_basename" >&5 6800 $as_echo "$as_me: Will search for user supplied tool CUT=$tool_basename" >&6;} 6801 # Extract the first word of "$tool_basename", so it can be a program name with args. 6802 set dummy $tool_basename; ac_word=$2 6803 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 6804 $as_echo_n "checking for $ac_word... " >&6; } 6805 if ${ac_cv_path_CUT+:} false; then : 6806 $as_echo_n "(cached) " >&6 6807 else 6808 case $CUT in 6809 [\\/]* | ?:[\\/]*) 6810 ac_cv_path_CUT="$CUT" # Let the user override the test with a path. 6811 ;; 6812 *) 6813 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 6814 for as_dir in $PATH 6815 do 6816 IFS=$as_save_IFS 6817 test -z "$as_dir" && as_dir=. 6818 for ac_exec_ext in '' $ac_executable_extensions; do 6819 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 6820 ac_cv_path_CUT="$as_dir/$ac_word$ac_exec_ext" 6821 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 6822 break 2 6823 fi 6824 done 6825 done 6826 IFS=$as_save_IFS 6827 6828 ;; 6829 esac 6830 fi 6831 CUT=$ac_cv_path_CUT 6832 if test -n "$CUT"; then 6833 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CUT" >&5 6834 $as_echo "$CUT" >&6; } 6835 else 6836 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 6837 $as_echo "no" >&6; } 6838 fi 6839 6840 6841 if test "x$CUT" = x; then 6842 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 6843 fi 6844 else 6845 # Otherwise we believe it is a complete path. Use it as it is. 6846 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool CUT=$tool_specified" >&5 6847 $as_echo "$as_me: Will use user supplied tool CUT=$tool_specified" >&6;} 6848 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for CUT" >&5 6849 $as_echo_n "checking for CUT... " >&6; } 6850 if test ! -x "$tool_specified"; then 6851 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 6852 $as_echo "not found" >&6; } 6853 as_fn_error $? "User supplied tool CUT=$tool_specified does not exist or is not executable" "$LINENO" 5 6854 fi 6855 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 6856 $as_echo "$tool_specified" >&6; } 6857 fi 6858 fi 6859 fi 6860 6861 fi 6862 6863 6864 6865 if test "x$CUT" = x; then 6866 as_fn_error $? "Could not find required tool for CUT" "$LINENO" 5 6867 fi 6868 6869 6870 6871 6872 6873 # Publish this variable in the help. 6874 6875 6876 if [ -z "${DATE+x}" ]; then 6877 # The variable is not set by user, try to locate tool using the code snippet 6878 for ac_prog in date 6879 do 6880 # Extract the first word of "$ac_prog", so it can be a program name with args. 6881 set dummy $ac_prog; ac_word=$2 6882 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 6883 $as_echo_n "checking for $ac_word... " >&6; } 6884 if ${ac_cv_path_DATE+:} false; then : 6885 $as_echo_n "(cached) " >&6 6886 else 6887 case $DATE in 6888 [\\/]* | ?:[\\/]*) 6889 ac_cv_path_DATE="$DATE" # Let the user override the test with a path. 6890 ;; 6891 *) 6892 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 6893 for as_dir in $PATH 6894 do 6895 IFS=$as_save_IFS 6896 test -z "$as_dir" && as_dir=. 6897 for ac_exec_ext in '' $ac_executable_extensions; do 6898 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 6899 ac_cv_path_DATE="$as_dir/$ac_word$ac_exec_ext" 6900 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 6901 break 2 6902 fi 6903 done 6904 done 6905 IFS=$as_save_IFS 6906 6907 ;; 6908 esac 6909 fi 6910 DATE=$ac_cv_path_DATE 6911 if test -n "$DATE"; then 6912 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $DATE" >&5 6913 $as_echo "$DATE" >&6; } 6914 else 6915 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 6916 $as_echo "no" >&6; } 6917 fi 6918 6919 6920 test -n "$DATE" && break 6921 done 6922 6923 else 6924 # The variable is set, but is it from the command line or the environment? 6925 6926 # Try to remove the string !DATE! from our list. 6927 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!DATE!/} 6928 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 6929 # If it failed, the variable was not from the command line. Ignore it, 6930 # but warn the user (except for BASH, which is always set by the calling BASH). 6931 if test "xDATE" != xBASH; then 6932 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of DATE from the environment. Use command line variables instead." >&5 6933 $as_echo "$as_me: WARNING: Ignoring value of DATE from the environment. Use command line variables instead." >&2;} 6934 fi 6935 # Try to locate tool using the code snippet 6936 for ac_prog in date 6937 do 6938 # Extract the first word of "$ac_prog", so it can be a program name with args. 6939 set dummy $ac_prog; ac_word=$2 6940 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 6941 $as_echo_n "checking for $ac_word... " >&6; } 6942 if ${ac_cv_path_DATE+:} false; then : 6943 $as_echo_n "(cached) " >&6 6944 else 6945 case $DATE in 6946 [\\/]* | ?:[\\/]*) 6947 ac_cv_path_DATE="$DATE" # Let the user override the test with a path. 6948 ;; 6949 *) 6950 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 6951 for as_dir in $PATH 6952 do 6953 IFS=$as_save_IFS 6954 test -z "$as_dir" && as_dir=. 6955 for ac_exec_ext in '' $ac_executable_extensions; do 6956 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 6957 ac_cv_path_DATE="$as_dir/$ac_word$ac_exec_ext" 6958 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 6959 break 2 6960 fi 6961 done 6962 done 6963 IFS=$as_save_IFS 6964 6965 ;; 6966 esac 6967 fi 6968 DATE=$ac_cv_path_DATE 6969 if test -n "$DATE"; then 6970 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $DATE" >&5 6971 $as_echo "$DATE" >&6; } 6972 else 6973 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 6974 $as_echo "no" >&6; } 6975 fi 6976 6977 6978 test -n "$DATE" && break 6979 done 6980 6981 else 6982 # If it succeeded, then it was overridden by the user. We will use it 6983 # for the tool. 6984 6985 # First remove it from the list of overridden variables, so we can test 6986 # for unknown variables in the end. 6987 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 6988 6989 # Check if we try to supply an empty value 6990 if test "x$DATE" = x; then 6991 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool DATE= (no value)" >&5 6992 $as_echo "$as_me: Setting user supplied tool DATE= (no value)" >&6;} 6993 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for DATE" >&5 6994 $as_echo_n "checking for DATE... " >&6; } 6995 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 6996 $as_echo "disabled" >&6; } 6997 else 6998 # Check if the provided tool contains a complete path. 6999 tool_specified="$DATE" 7000 tool_basename="${tool_specified##*/}" 7001 if test "x$tool_basename" = "x$tool_specified"; then 7002 # A command without a complete path is provided, search $PATH. 7003 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool DATE=$tool_basename" >&5 7004 $as_echo "$as_me: Will search for user supplied tool DATE=$tool_basename" >&6;} 7005 # Extract the first word of "$tool_basename", so it can be a program name with args. 7006 set dummy $tool_basename; ac_word=$2 7007 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 7008 $as_echo_n "checking for $ac_word... " >&6; } 7009 if ${ac_cv_path_DATE+:} false; then : 7010 $as_echo_n "(cached) " >&6 7011 else 7012 case $DATE in 7013 [\\/]* | ?:[\\/]*) 7014 ac_cv_path_DATE="$DATE" # Let the user override the test with a path. 7015 ;; 7016 *) 7017 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 7018 for as_dir in $PATH 7019 do 7020 IFS=$as_save_IFS 7021 test -z "$as_dir" && as_dir=. 7022 for ac_exec_ext in '' $ac_executable_extensions; do 7023 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 7024 ac_cv_path_DATE="$as_dir/$ac_word$ac_exec_ext" 7025 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 7026 break 2 7027 fi 7028 done 7029 done 7030 IFS=$as_save_IFS 7031 7032 ;; 7033 esac 7034 fi 7035 DATE=$ac_cv_path_DATE 7036 if test -n "$DATE"; then 7037 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $DATE" >&5 7038 $as_echo "$DATE" >&6; } 7039 else 7040 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 7041 $as_echo "no" >&6; } 7042 fi 7043 7044 7045 if test "x$DATE" = x; then 7046 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 7047 fi 7048 else 7049 # Otherwise we believe it is a complete path. Use it as it is. 7050 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool DATE=$tool_specified" >&5 7051 $as_echo "$as_me: Will use user supplied tool DATE=$tool_specified" >&6;} 7052 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for DATE" >&5 7053 $as_echo_n "checking for DATE... " >&6; } 7054 if test ! -x "$tool_specified"; then 7055 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 7056 $as_echo "not found" >&6; } 7057 as_fn_error $? "User supplied tool DATE=$tool_specified does not exist or is not executable" "$LINENO" 5 7058 fi 7059 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 7060 $as_echo "$tool_specified" >&6; } 7061 fi 7062 fi 7063 fi 7064 7065 fi 7066 7067 7068 7069 if test "x$DATE" = x; then 7070 as_fn_error $? "Could not find required tool for DATE" "$LINENO" 5 7071 fi 7072 7073 7074 7075 7076 7077 # Publish this variable in the help. 7078 7079 7080 if [ -z "${DIFF+x}" ]; then 7081 # The variable is not set by user, try to locate tool using the code snippet 7082 for ac_prog in gdiff diff 7083 do 7084 # Extract the first word of "$ac_prog", so it can be a program name with args. 7085 set dummy $ac_prog; ac_word=$2 7086 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 7087 $as_echo_n "checking for $ac_word... " >&6; } 7088 if ${ac_cv_path_DIFF+:} false; then : 7089 $as_echo_n "(cached) " >&6 7090 else 7091 case $DIFF in 7092 [\\/]* | ?:[\\/]*) 7093 ac_cv_path_DIFF="$DIFF" # Let the user override the test with a path. 7094 ;; 7095 *) 7096 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 7097 for as_dir in $PATH 7098 do 7099 IFS=$as_save_IFS 7100 test -z "$as_dir" && as_dir=. 7101 for ac_exec_ext in '' $ac_executable_extensions; do 7102 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 7103 ac_cv_path_DIFF="$as_dir/$ac_word$ac_exec_ext" 7104 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 7105 break 2 7106 fi 7107 done 7108 done 7109 IFS=$as_save_IFS 7110 7111 ;; 7112 esac 7113 fi 7114 DIFF=$ac_cv_path_DIFF 7115 if test -n "$DIFF"; then 7116 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $DIFF" >&5 7117 $as_echo "$DIFF" >&6; } 7118 else 7119 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 7120 $as_echo "no" >&6; } 7121 fi 7122 7123 7124 test -n "$DIFF" && break 7125 done 7126 7127 else 7128 # The variable is set, but is it from the command line or the environment? 7129 7130 # Try to remove the string !DIFF! from our list. 7131 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!DIFF!/} 7132 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 7133 # If it failed, the variable was not from the command line. Ignore it, 7134 # but warn the user (except for BASH, which is always set by the calling BASH). 7135 if test "xDIFF" != xBASH; then 7136 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of DIFF from the environment. Use command line variables instead." >&5 7137 $as_echo "$as_me: WARNING: Ignoring value of DIFF from the environment. Use command line variables instead." >&2;} 7138 fi 7139 # Try to locate tool using the code snippet 7140 for ac_prog in gdiff diff 7141 do 7142 # Extract the first word of "$ac_prog", so it can be a program name with args. 7143 set dummy $ac_prog; ac_word=$2 7144 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 7145 $as_echo_n "checking for $ac_word... " >&6; } 7146 if ${ac_cv_path_DIFF+:} false; then : 7147 $as_echo_n "(cached) " >&6 7148 else 7149 case $DIFF in 7150 [\\/]* | ?:[\\/]*) 7151 ac_cv_path_DIFF="$DIFF" # Let the user override the test with a path. 7152 ;; 7153 *) 7154 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 7155 for as_dir in $PATH 7156 do 7157 IFS=$as_save_IFS 7158 test -z "$as_dir" && as_dir=. 7159 for ac_exec_ext in '' $ac_executable_extensions; do 7160 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 7161 ac_cv_path_DIFF="$as_dir/$ac_word$ac_exec_ext" 7162 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 7163 break 2 7164 fi 7165 done 7166 done 7167 IFS=$as_save_IFS 7168 7169 ;; 7170 esac 7171 fi 7172 DIFF=$ac_cv_path_DIFF 7173 if test -n "$DIFF"; then 7174 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $DIFF" >&5 7175 $as_echo "$DIFF" >&6; } 7176 else 7177 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 7178 $as_echo "no" >&6; } 7179 fi 7180 7181 7182 test -n "$DIFF" && break 7183 done 7184 7185 else 7186 # If it succeeded, then it was overridden by the user. We will use it 7187 # for the tool. 7188 7189 # First remove it from the list of overridden variables, so we can test 7190 # for unknown variables in the end. 7191 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 7192 7193 # Check if we try to supply an empty value 7194 if test "x$DIFF" = x; then 7195 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool DIFF= (no value)" >&5 7196 $as_echo "$as_me: Setting user supplied tool DIFF= (no value)" >&6;} 7197 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for DIFF" >&5 7198 $as_echo_n "checking for DIFF... " >&6; } 7199 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 7200 $as_echo "disabled" >&6; } 7201 else 7202 # Check if the provided tool contains a complete path. 7203 tool_specified="$DIFF" 7204 tool_basename="${tool_specified##*/}" 7205 if test "x$tool_basename" = "x$tool_specified"; then 7206 # A command without a complete path is provided, search $PATH. 7207 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool DIFF=$tool_basename" >&5 7208 $as_echo "$as_me: Will search for user supplied tool DIFF=$tool_basename" >&6;} 7209 # Extract the first word of "$tool_basename", so it can be a program name with args. 7210 set dummy $tool_basename; ac_word=$2 7211 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 7212 $as_echo_n "checking for $ac_word... " >&6; } 7213 if ${ac_cv_path_DIFF+:} false; then : 7214 $as_echo_n "(cached) " >&6 7215 else 7216 case $DIFF in 7217 [\\/]* | ?:[\\/]*) 7218 ac_cv_path_DIFF="$DIFF" # Let the user override the test with a path. 7219 ;; 7220 *) 7221 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 7222 for as_dir in $PATH 7223 do 7224 IFS=$as_save_IFS 7225 test -z "$as_dir" && as_dir=. 7226 for ac_exec_ext in '' $ac_executable_extensions; do 7227 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 7228 ac_cv_path_DIFF="$as_dir/$ac_word$ac_exec_ext" 7229 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 7230 break 2 7231 fi 7232 done 7233 done 7234 IFS=$as_save_IFS 7235 7236 ;; 7237 esac 7238 fi 7239 DIFF=$ac_cv_path_DIFF 7240 if test -n "$DIFF"; then 7241 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $DIFF" >&5 7242 $as_echo "$DIFF" >&6; } 7243 else 7244 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 7245 $as_echo "no" >&6; } 7246 fi 7247 7248 7249 if test "x$DIFF" = x; then 7250 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 7251 fi 7252 else 7253 # Otherwise we believe it is a complete path. Use it as it is. 7254 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool DIFF=$tool_specified" >&5 7255 $as_echo "$as_me: Will use user supplied tool DIFF=$tool_specified" >&6;} 7256 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for DIFF" >&5 7257 $as_echo_n "checking for DIFF... " >&6; } 7258 if test ! -x "$tool_specified"; then 7259 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 7260 $as_echo "not found" >&6; } 7261 as_fn_error $? "User supplied tool DIFF=$tool_specified does not exist or is not executable" "$LINENO" 5 7262 fi 7263 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 7264 $as_echo "$tool_specified" >&6; } 7265 fi 7266 fi 7267 fi 7268 7269 fi 7270 7271 7272 7273 if test "x$DIFF" = x; then 7274 as_fn_error $? "Could not find required tool for DIFF" "$LINENO" 5 7275 fi 7276 7277 7278 7279 7280 7281 # Publish this variable in the help. 7282 7283 7284 if [ -z "${DIRNAME+x}" ]; then 7285 # The variable is not set by user, try to locate tool using the code snippet 7286 for ac_prog in dirname 7287 do 7288 # Extract the first word of "$ac_prog", so it can be a program name with args. 7289 set dummy $ac_prog; ac_word=$2 7290 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 7291 $as_echo_n "checking for $ac_word... " >&6; } 7292 if ${ac_cv_path_DIRNAME+:} false; then : 7293 $as_echo_n "(cached) " >&6 7294 else 7295 case $DIRNAME in 7296 [\\/]* | ?:[\\/]*) 7297 ac_cv_path_DIRNAME="$DIRNAME" # Let the user override the test with a path. 7298 ;; 7299 *) 7300 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 7301 for as_dir in $PATH 7302 do 7303 IFS=$as_save_IFS 7304 test -z "$as_dir" && as_dir=. 7305 for ac_exec_ext in '' $ac_executable_extensions; do 7306 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 7307 ac_cv_path_DIRNAME="$as_dir/$ac_word$ac_exec_ext" 7308 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 7309 break 2 7310 fi 7311 done 7312 done 7313 IFS=$as_save_IFS 7314 7315 ;; 7316 esac 7317 fi 7318 DIRNAME=$ac_cv_path_DIRNAME 7319 if test -n "$DIRNAME"; then 7320 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $DIRNAME" >&5 7321 $as_echo "$DIRNAME" >&6; } 7322 else 7323 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 7324 $as_echo "no" >&6; } 7325 fi 7326 7327 7328 test -n "$DIRNAME" && break 7329 done 7330 7331 else 7332 # The variable is set, but is it from the command line or the environment? 7333 7334 # Try to remove the string !DIRNAME! from our list. 7335 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!DIRNAME!/} 7336 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 7337 # If it failed, the variable was not from the command line. Ignore it, 7338 # but warn the user (except for BASH, which is always set by the calling BASH). 7339 if test "xDIRNAME" != xBASH; then 7340 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of DIRNAME from the environment. Use command line variables instead." >&5 7341 $as_echo "$as_me: WARNING: Ignoring value of DIRNAME from the environment. Use command line variables instead." >&2;} 7342 fi 7343 # Try to locate tool using the code snippet 7344 for ac_prog in dirname 7345 do 7346 # Extract the first word of "$ac_prog", so it can be a program name with args. 7347 set dummy $ac_prog; ac_word=$2 7348 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 7349 $as_echo_n "checking for $ac_word... " >&6; } 7350 if ${ac_cv_path_DIRNAME+:} false; then : 7351 $as_echo_n "(cached) " >&6 7352 else 7353 case $DIRNAME in 7354 [\\/]* | ?:[\\/]*) 7355 ac_cv_path_DIRNAME="$DIRNAME" # Let the user override the test with a path. 7356 ;; 7357 *) 7358 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 7359 for as_dir in $PATH 7360 do 7361 IFS=$as_save_IFS 7362 test -z "$as_dir" && as_dir=. 7363 for ac_exec_ext in '' $ac_executable_extensions; do 7364 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 7365 ac_cv_path_DIRNAME="$as_dir/$ac_word$ac_exec_ext" 7366 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 7367 break 2 7368 fi 7369 done 7370 done 7371 IFS=$as_save_IFS 7372 7373 ;; 7374 esac 7375 fi 7376 DIRNAME=$ac_cv_path_DIRNAME 7377 if test -n "$DIRNAME"; then 7378 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $DIRNAME" >&5 7379 $as_echo "$DIRNAME" >&6; } 7380 else 7381 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 7382 $as_echo "no" >&6; } 7383 fi 7384 7385 7386 test -n "$DIRNAME" && break 7387 done 7388 7389 else 7390 # If it succeeded, then it was overridden by the user. We will use it 7391 # for the tool. 7392 7393 # First remove it from the list of overridden variables, so we can test 7394 # for unknown variables in the end. 7395 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 7396 7397 # Check if we try to supply an empty value 7398 if test "x$DIRNAME" = x; then 7399 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool DIRNAME= (no value)" >&5 7400 $as_echo "$as_me: Setting user supplied tool DIRNAME= (no value)" >&6;} 7401 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for DIRNAME" >&5 7402 $as_echo_n "checking for DIRNAME... " >&6; } 7403 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 7404 $as_echo "disabled" >&6; } 7405 else 7406 # Check if the provided tool contains a complete path. 7407 tool_specified="$DIRNAME" 7408 tool_basename="${tool_specified##*/}" 7409 if test "x$tool_basename" = "x$tool_specified"; then 7410 # A command without a complete path is provided, search $PATH. 7411 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool DIRNAME=$tool_basename" >&5 7412 $as_echo "$as_me: Will search for user supplied tool DIRNAME=$tool_basename" >&6;} 7413 # Extract the first word of "$tool_basename", so it can be a program name with args. 7414 set dummy $tool_basename; ac_word=$2 7415 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 7416 $as_echo_n "checking for $ac_word... " >&6; } 7417 if ${ac_cv_path_DIRNAME+:} false; then : 7418 $as_echo_n "(cached) " >&6 7419 else 7420 case $DIRNAME in 7421 [\\/]* | ?:[\\/]*) 7422 ac_cv_path_DIRNAME="$DIRNAME" # Let the user override the test with a path. 7423 ;; 7424 *) 7425 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 7426 for as_dir in $PATH 7427 do 7428 IFS=$as_save_IFS 7429 test -z "$as_dir" && as_dir=. 7430 for ac_exec_ext in '' $ac_executable_extensions; do 7431 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 7432 ac_cv_path_DIRNAME="$as_dir/$ac_word$ac_exec_ext" 7433 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 7434 break 2 7435 fi 7436 done 7437 done 7438 IFS=$as_save_IFS 7439 7440 ;; 7441 esac 7442 fi 7443 DIRNAME=$ac_cv_path_DIRNAME 7444 if test -n "$DIRNAME"; then 7445 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $DIRNAME" >&5 7446 $as_echo "$DIRNAME" >&6; } 7447 else 7448 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 7449 $as_echo "no" >&6; } 7450 fi 7451 7452 7453 if test "x$DIRNAME" = x; then 7454 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 7455 fi 7456 else 7457 # Otherwise we believe it is a complete path. Use it as it is. 7458 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool DIRNAME=$tool_specified" >&5 7459 $as_echo "$as_me: Will use user supplied tool DIRNAME=$tool_specified" >&6;} 7460 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for DIRNAME" >&5 7461 $as_echo_n "checking for DIRNAME... " >&6; } 7462 if test ! -x "$tool_specified"; then 7463 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 7464 $as_echo "not found" >&6; } 7465 as_fn_error $? "User supplied tool DIRNAME=$tool_specified does not exist or is not executable" "$LINENO" 5 7466 fi 7467 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 7468 $as_echo "$tool_specified" >&6; } 7469 fi 7470 fi 7471 fi 7472 7473 fi 7474 7475 7476 7477 if test "x$DIRNAME" = x; then 7478 as_fn_error $? "Could not find required tool for DIRNAME" "$LINENO" 5 7479 fi 7480 7481 7482 7483 7484 7485 # Publish this variable in the help. 7486 7487 7488 if [ -z "${ECHO+x}" ]; then 7489 # The variable is not set by user, try to locate tool using the code snippet 7490 for ac_prog in echo 7491 do 7492 # Extract the first word of "$ac_prog", so it can be a program name with args. 7493 set dummy $ac_prog; ac_word=$2 7494 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 7495 $as_echo_n "checking for $ac_word... " >&6; } 7496 if ${ac_cv_path_ECHO+:} false; then : 7497 $as_echo_n "(cached) " >&6 7498 else 7499 case $ECHO in 7500 [\\/]* | ?:[\\/]*) 7501 ac_cv_path_ECHO="$ECHO" # Let the user override the test with a path. 7502 ;; 7503 *) 7504 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 7505 for as_dir in $PATH 7506 do 7507 IFS=$as_save_IFS 7508 test -z "$as_dir" && as_dir=. 7509 for ac_exec_ext in '' $ac_executable_extensions; do 7510 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 7511 ac_cv_path_ECHO="$as_dir/$ac_word$ac_exec_ext" 7512 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 7513 break 2 7514 fi 7515 done 7516 done 7517 IFS=$as_save_IFS 7518 7519 ;; 7520 esac 7521 fi 7522 ECHO=$ac_cv_path_ECHO 7523 if test -n "$ECHO"; then 7524 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ECHO" >&5 7525 $as_echo "$ECHO" >&6; } 7526 else 7527 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 7528 $as_echo "no" >&6; } 7529 fi 7530 7531 7532 test -n "$ECHO" && break 7533 done 7534 7535 else 7536 # The variable is set, but is it from the command line or the environment? 7537 7538 # Try to remove the string !ECHO! from our list. 7539 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!ECHO!/} 7540 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 7541 # If it failed, the variable was not from the command line. Ignore it, 7542 # but warn the user (except for BASH, which is always set by the calling BASH). 7543 if test "xECHO" != xBASH; then 7544 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of ECHO from the environment. Use command line variables instead." >&5 7545 $as_echo "$as_me: WARNING: Ignoring value of ECHO from the environment. Use command line variables instead." >&2;} 7546 fi 7547 # Try to locate tool using the code snippet 7548 for ac_prog in echo 7549 do 7550 # Extract the first word of "$ac_prog", so it can be a program name with args. 7551 set dummy $ac_prog; ac_word=$2 7552 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 7553 $as_echo_n "checking for $ac_word... " >&6; } 7554 if ${ac_cv_path_ECHO+:} false; then : 7555 $as_echo_n "(cached) " >&6 7556 else 7557 case $ECHO in 7558 [\\/]* | ?:[\\/]*) 7559 ac_cv_path_ECHO="$ECHO" # Let the user override the test with a path. 7560 ;; 7561 *) 7562 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 7563 for as_dir in $PATH 7564 do 7565 IFS=$as_save_IFS 7566 test -z "$as_dir" && as_dir=. 7567 for ac_exec_ext in '' $ac_executable_extensions; do 7568 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 7569 ac_cv_path_ECHO="$as_dir/$ac_word$ac_exec_ext" 7570 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 7571 break 2 7572 fi 7573 done 7574 done 7575 IFS=$as_save_IFS 7576 7577 ;; 7578 esac 7579 fi 7580 ECHO=$ac_cv_path_ECHO 7581 if test -n "$ECHO"; then 7582 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ECHO" >&5 7583 $as_echo "$ECHO" >&6; } 7584 else 7585 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 7586 $as_echo "no" >&6; } 7587 fi 7588 7589 7590 test -n "$ECHO" && break 7591 done 7592 7593 else 7594 # If it succeeded, then it was overridden by the user. We will use it 7595 # for the tool. 7596 7597 # First remove it from the list of overridden variables, so we can test 7598 # for unknown variables in the end. 7599 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 7600 7601 # Check if we try to supply an empty value 7602 if test "x$ECHO" = x; then 7603 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool ECHO= (no value)" >&5 7604 $as_echo "$as_me: Setting user supplied tool ECHO= (no value)" >&6;} 7605 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ECHO" >&5 7606 $as_echo_n "checking for ECHO... " >&6; } 7607 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 7608 $as_echo "disabled" >&6; } 7609 else 7610 # Check if the provided tool contains a complete path. 7611 tool_specified="$ECHO" 7612 tool_basename="${tool_specified##*/}" 7613 if test "x$tool_basename" = "x$tool_specified"; then 7614 # A command without a complete path is provided, search $PATH. 7615 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool ECHO=$tool_basename" >&5 7616 $as_echo "$as_me: Will search for user supplied tool ECHO=$tool_basename" >&6;} 7617 # Extract the first word of "$tool_basename", so it can be a program name with args. 7618 set dummy $tool_basename; ac_word=$2 7619 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 7620 $as_echo_n "checking for $ac_word... " >&6; } 7621 if ${ac_cv_path_ECHO+:} false; then : 7622 $as_echo_n "(cached) " >&6 7623 else 7624 case $ECHO in 7625 [\\/]* | ?:[\\/]*) 7626 ac_cv_path_ECHO="$ECHO" # Let the user override the test with a path. 7627 ;; 7628 *) 7629 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 7630 for as_dir in $PATH 7631 do 7632 IFS=$as_save_IFS 7633 test -z "$as_dir" && as_dir=. 7634 for ac_exec_ext in '' $ac_executable_extensions; do 7635 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 7636 ac_cv_path_ECHO="$as_dir/$ac_word$ac_exec_ext" 7637 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 7638 break 2 7639 fi 7640 done 7641 done 7642 IFS=$as_save_IFS 7643 7644 ;; 7645 esac 7646 fi 7647 ECHO=$ac_cv_path_ECHO 7648 if test -n "$ECHO"; then 7649 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ECHO" >&5 7650 $as_echo "$ECHO" >&6; } 7651 else 7652 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 7653 $as_echo "no" >&6; } 7654 fi 7655 7656 7657 if test "x$ECHO" = x; then 7658 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 7659 fi 7660 else 7661 # Otherwise we believe it is a complete path. Use it as it is. 7662 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool ECHO=$tool_specified" >&5 7663 $as_echo "$as_me: Will use user supplied tool ECHO=$tool_specified" >&6;} 7664 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ECHO" >&5 7665 $as_echo_n "checking for ECHO... " >&6; } 7666 if test ! -x "$tool_specified"; then 7667 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 7668 $as_echo "not found" >&6; } 7669 as_fn_error $? "User supplied tool ECHO=$tool_specified does not exist or is not executable" "$LINENO" 5 7670 fi 7671 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 7672 $as_echo "$tool_specified" >&6; } 7673 fi 7674 fi 7675 fi 7676 7677 fi 7678 7679 7680 7681 if test "x$ECHO" = x; then 7682 as_fn_error $? "Could not find required tool for ECHO" "$LINENO" 5 7683 fi 7684 7685 7686 7687 7688 7689 # Publish this variable in the help. 7690 7691 7692 if [ -z "${EXPR+x}" ]; then 7693 # The variable is not set by user, try to locate tool using the code snippet 7694 for ac_prog in expr 7695 do 7696 # Extract the first word of "$ac_prog", so it can be a program name with args. 7697 set dummy $ac_prog; ac_word=$2 7698 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 7699 $as_echo_n "checking for $ac_word... " >&6; } 7700 if ${ac_cv_path_EXPR+:} false; then : 7701 $as_echo_n "(cached) " >&6 7702 else 7703 case $EXPR in 7704 [\\/]* | ?:[\\/]*) 7705 ac_cv_path_EXPR="$EXPR" # Let the user override the test with a path. 7706 ;; 7707 *) 7708 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 7709 for as_dir in $PATH 7710 do 7711 IFS=$as_save_IFS 7712 test -z "$as_dir" && as_dir=. 7713 for ac_exec_ext in '' $ac_executable_extensions; do 7714 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 7715 ac_cv_path_EXPR="$as_dir/$ac_word$ac_exec_ext" 7716 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 7717 break 2 7718 fi 7719 done 7720 done 7721 IFS=$as_save_IFS 7722 7723 ;; 7724 esac 7725 fi 7726 EXPR=$ac_cv_path_EXPR 7727 if test -n "$EXPR"; then 7728 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $EXPR" >&5 7729 $as_echo "$EXPR" >&6; } 7730 else 7731 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 7732 $as_echo "no" >&6; } 7733 fi 7734 7735 7736 test -n "$EXPR" && break 7737 done 7738 7739 else 7740 # The variable is set, but is it from the command line or the environment? 7741 7742 # Try to remove the string !EXPR! from our list. 7743 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!EXPR!/} 7744 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 7745 # If it failed, the variable was not from the command line. Ignore it, 7746 # but warn the user (except for BASH, which is always set by the calling BASH). 7747 if test "xEXPR" != xBASH; then 7748 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of EXPR from the environment. Use command line variables instead." >&5 7749 $as_echo "$as_me: WARNING: Ignoring value of EXPR from the environment. Use command line variables instead." >&2;} 7750 fi 7751 # Try to locate tool using the code snippet 7752 for ac_prog in expr 7753 do 7754 # Extract the first word of "$ac_prog", so it can be a program name with args. 7755 set dummy $ac_prog; ac_word=$2 7756 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 7757 $as_echo_n "checking for $ac_word... " >&6; } 7758 if ${ac_cv_path_EXPR+:} false; then : 7759 $as_echo_n "(cached) " >&6 7760 else 7761 case $EXPR in 7762 [\\/]* | ?:[\\/]*) 7763 ac_cv_path_EXPR="$EXPR" # Let the user override the test with a path. 7764 ;; 7765 *) 7766 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 7767 for as_dir in $PATH 7768 do 7769 IFS=$as_save_IFS 7770 test -z "$as_dir" && as_dir=. 7771 for ac_exec_ext in '' $ac_executable_extensions; do 7772 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 7773 ac_cv_path_EXPR="$as_dir/$ac_word$ac_exec_ext" 7774 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 7775 break 2 7776 fi 7777 done 7778 done 7779 IFS=$as_save_IFS 7780 7781 ;; 7782 esac 7783 fi 7784 EXPR=$ac_cv_path_EXPR 7785 if test -n "$EXPR"; then 7786 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $EXPR" >&5 7787 $as_echo "$EXPR" >&6; } 7788 else 7789 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 7790 $as_echo "no" >&6; } 7791 fi 7792 7793 7794 test -n "$EXPR" && break 7795 done 7796 7797 else 7798 # If it succeeded, then it was overridden by the user. We will use it 7799 # for the tool. 7800 7801 # First remove it from the list of overridden variables, so we can test 7802 # for unknown variables in the end. 7803 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 7804 7805 # Check if we try to supply an empty value 7806 if test "x$EXPR" = x; then 7807 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool EXPR= (no value)" >&5 7808 $as_echo "$as_me: Setting user supplied tool EXPR= (no value)" >&6;} 7809 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for EXPR" >&5 7810 $as_echo_n "checking for EXPR... " >&6; } 7811 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 7812 $as_echo "disabled" >&6; } 7813 else 7814 # Check if the provided tool contains a complete path. 7815 tool_specified="$EXPR" 7816 tool_basename="${tool_specified##*/}" 7817 if test "x$tool_basename" = "x$tool_specified"; then 7818 # A command without a complete path is provided, search $PATH. 7819 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool EXPR=$tool_basename" >&5 7820 $as_echo "$as_me: Will search for user supplied tool EXPR=$tool_basename" >&6;} 7821 # Extract the first word of "$tool_basename", so it can be a program name with args. 7822 set dummy $tool_basename; ac_word=$2 7823 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 7824 $as_echo_n "checking for $ac_word... " >&6; } 7825 if ${ac_cv_path_EXPR+:} false; then : 7826 $as_echo_n "(cached) " >&6 7827 else 7828 case $EXPR in 7829 [\\/]* | ?:[\\/]*) 7830 ac_cv_path_EXPR="$EXPR" # Let the user override the test with a path. 7831 ;; 7832 *) 7833 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 7834 for as_dir in $PATH 7835 do 7836 IFS=$as_save_IFS 7837 test -z "$as_dir" && as_dir=. 7838 for ac_exec_ext in '' $ac_executable_extensions; do 7839 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 7840 ac_cv_path_EXPR="$as_dir/$ac_word$ac_exec_ext" 7841 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 7842 break 2 7843 fi 7844 done 7845 done 7846 IFS=$as_save_IFS 7847 7848 ;; 7849 esac 7850 fi 7851 EXPR=$ac_cv_path_EXPR 7852 if test -n "$EXPR"; then 7853 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $EXPR" >&5 7854 $as_echo "$EXPR" >&6; } 7855 else 7856 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 7857 $as_echo "no" >&6; } 7858 fi 7859 7860 7861 if test "x$EXPR" = x; then 7862 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 7863 fi 7864 else 7865 # Otherwise we believe it is a complete path. Use it as it is. 7866 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool EXPR=$tool_specified" >&5 7867 $as_echo "$as_me: Will use user supplied tool EXPR=$tool_specified" >&6;} 7868 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for EXPR" >&5 7869 $as_echo_n "checking for EXPR... " >&6; } 7870 if test ! -x "$tool_specified"; then 7871 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 7872 $as_echo "not found" >&6; } 7873 as_fn_error $? "User supplied tool EXPR=$tool_specified does not exist or is not executable" "$LINENO" 5 7874 fi 7875 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 7876 $as_echo "$tool_specified" >&6; } 7877 fi 7878 fi 7879 fi 7880 7881 fi 7882 7883 7884 7885 if test "x$EXPR" = x; then 7886 as_fn_error $? "Could not find required tool for EXPR" "$LINENO" 5 7887 fi 7888 7889 7890 7891 7892 7893 # Publish this variable in the help. 7894 7895 7896 if [ -z "${FILE+x}" ]; then 7897 # The variable is not set by user, try to locate tool using the code snippet 7898 for ac_prog in file 7899 do 7900 # Extract the first word of "$ac_prog", so it can be a program name with args. 7901 set dummy $ac_prog; ac_word=$2 7902 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 7903 $as_echo_n "checking for $ac_word... " >&6; } 7904 if ${ac_cv_path_FILE+:} false; then : 7905 $as_echo_n "(cached) " >&6 7906 else 7907 case $FILE in 7908 [\\/]* | ?:[\\/]*) 7909 ac_cv_path_FILE="$FILE" # Let the user override the test with a path. 7910 ;; 7911 *) 7912 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 7913 for as_dir in $PATH 7914 do 7915 IFS=$as_save_IFS 7916 test -z "$as_dir" && as_dir=. 7917 for ac_exec_ext in '' $ac_executable_extensions; do 7918 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 7919 ac_cv_path_FILE="$as_dir/$ac_word$ac_exec_ext" 7920 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 7921 break 2 7922 fi 7923 done 7924 done 7925 IFS=$as_save_IFS 7926 7927 ;; 7928 esac 7929 fi 7930 FILE=$ac_cv_path_FILE 7931 if test -n "$FILE"; then 7932 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $FILE" >&5 7933 $as_echo "$FILE" >&6; } 7934 else 7935 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 7936 $as_echo "no" >&6; } 7937 fi 7938 7939 7940 test -n "$FILE" && break 7941 done 7942 7943 else 7944 # The variable is set, but is it from the command line or the environment? 7945 7946 # Try to remove the string !FILE! from our list. 7947 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!FILE!/} 7948 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 7949 # If it failed, the variable was not from the command line. Ignore it, 7950 # but warn the user (except for BASH, which is always set by the calling BASH). 7951 if test "xFILE" != xBASH; then 7952 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of FILE from the environment. Use command line variables instead." >&5 7953 $as_echo "$as_me: WARNING: Ignoring value of FILE from the environment. Use command line variables instead." >&2;} 7954 fi 7955 # Try to locate tool using the code snippet 7956 for ac_prog in file 7957 do 7958 # Extract the first word of "$ac_prog", so it can be a program name with args. 7959 set dummy $ac_prog; ac_word=$2 7960 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 7961 $as_echo_n "checking for $ac_word... " >&6; } 7962 if ${ac_cv_path_FILE+:} false; then : 7963 $as_echo_n "(cached) " >&6 7964 else 7965 case $FILE in 7966 [\\/]* | ?:[\\/]*) 7967 ac_cv_path_FILE="$FILE" # Let the user override the test with a path. 7968 ;; 7969 *) 7970 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 7971 for as_dir in $PATH 7972 do 7973 IFS=$as_save_IFS 7974 test -z "$as_dir" && as_dir=. 7975 for ac_exec_ext in '' $ac_executable_extensions; do 7976 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 7977 ac_cv_path_FILE="$as_dir/$ac_word$ac_exec_ext" 7978 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 7979 break 2 7980 fi 7981 done 7982 done 7983 IFS=$as_save_IFS 7984 7985 ;; 7986 esac 7987 fi 7988 FILE=$ac_cv_path_FILE 7989 if test -n "$FILE"; then 7990 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $FILE" >&5 7991 $as_echo "$FILE" >&6; } 7992 else 7993 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 7994 $as_echo "no" >&6; } 7995 fi 7996 7997 7998 test -n "$FILE" && break 7999 done 8000 8001 else 8002 # If it succeeded, then it was overridden by the user. We will use it 8003 # for the tool. 8004 8005 # First remove it from the list of overridden variables, so we can test 8006 # for unknown variables in the end. 8007 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 8008 8009 # Check if we try to supply an empty value 8010 if test "x$FILE" = x; then 8011 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool FILE= (no value)" >&5 8012 $as_echo "$as_me: Setting user supplied tool FILE= (no value)" >&6;} 8013 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for FILE" >&5 8014 $as_echo_n "checking for FILE... " >&6; } 8015 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 8016 $as_echo "disabled" >&6; } 8017 else 8018 # Check if the provided tool contains a complete path. 8019 tool_specified="$FILE" 8020 tool_basename="${tool_specified##*/}" 8021 if test "x$tool_basename" = "x$tool_specified"; then 8022 # A command without a complete path is provided, search $PATH. 8023 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool FILE=$tool_basename" >&5 8024 $as_echo "$as_me: Will search for user supplied tool FILE=$tool_basename" >&6;} 8025 # Extract the first word of "$tool_basename", so it can be a program name with args. 8026 set dummy $tool_basename; ac_word=$2 8027 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 8028 $as_echo_n "checking for $ac_word... " >&6; } 8029 if ${ac_cv_path_FILE+:} false; then : 8030 $as_echo_n "(cached) " >&6 8031 else 8032 case $FILE in 8033 [\\/]* | ?:[\\/]*) 8034 ac_cv_path_FILE="$FILE" # Let the user override the test with a path. 8035 ;; 8036 *) 8037 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 8038 for as_dir in $PATH 8039 do 8040 IFS=$as_save_IFS 8041 test -z "$as_dir" && as_dir=. 8042 for ac_exec_ext in '' $ac_executable_extensions; do 8043 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 8044 ac_cv_path_FILE="$as_dir/$ac_word$ac_exec_ext" 8045 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 8046 break 2 8047 fi 8048 done 8049 done 8050 IFS=$as_save_IFS 8051 8052 ;; 8053 esac 8054 fi 8055 FILE=$ac_cv_path_FILE 8056 if test -n "$FILE"; then 8057 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $FILE" >&5 8058 $as_echo "$FILE" >&6; } 8059 else 8060 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 8061 $as_echo "no" >&6; } 8062 fi 8063 8064 8065 if test "x$FILE" = x; then 8066 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 8067 fi 8068 else 8069 # Otherwise we believe it is a complete path. Use it as it is. 8070 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool FILE=$tool_specified" >&5 8071 $as_echo "$as_me: Will use user supplied tool FILE=$tool_specified" >&6;} 8072 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for FILE" >&5 8073 $as_echo_n "checking for FILE... " >&6; } 8074 if test ! -x "$tool_specified"; then 8075 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 8076 $as_echo "not found" >&6; } 8077 as_fn_error $? "User supplied tool FILE=$tool_specified does not exist or is not executable" "$LINENO" 5 8078 fi 8079 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 8080 $as_echo "$tool_specified" >&6; } 8081 fi 8082 fi 8083 fi 8084 8085 fi 8086 8087 8088 8089 if test "x$FILE" = x; then 8090 as_fn_error $? "Could not find required tool for FILE" "$LINENO" 5 8091 fi 8092 8093 8094 8095 8096 8097 # Publish this variable in the help. 8098 8099 8100 if [ -z "${FIND+x}" ]; then 8101 # The variable is not set by user, try to locate tool using the code snippet 8102 for ac_prog in find 8103 do 8104 # Extract the first word of "$ac_prog", so it can be a program name with args. 8105 set dummy $ac_prog; ac_word=$2 8106 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 8107 $as_echo_n "checking for $ac_word... " >&6; } 8108 if ${ac_cv_path_FIND+:} false; then : 8109 $as_echo_n "(cached) " >&6 8110 else 8111 case $FIND in 8112 [\\/]* | ?:[\\/]*) 8113 ac_cv_path_FIND="$FIND" # Let the user override the test with a path. 8114 ;; 8115 *) 8116 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 8117 for as_dir in $PATH 8118 do 8119 IFS=$as_save_IFS 8120 test -z "$as_dir" && as_dir=. 8121 for ac_exec_ext in '' $ac_executable_extensions; do 8122 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 8123 ac_cv_path_FIND="$as_dir/$ac_word$ac_exec_ext" 8124 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 8125 break 2 8126 fi 8127 done 8128 done 8129 IFS=$as_save_IFS 8130 8131 ;; 8132 esac 8133 fi 8134 FIND=$ac_cv_path_FIND 8135 if test -n "$FIND"; then 8136 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $FIND" >&5 8137 $as_echo "$FIND" >&6; } 8138 else 8139 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 8140 $as_echo "no" >&6; } 8141 fi 8142 8143 8144 test -n "$FIND" && break 8145 done 8146 8147 else 8148 # The variable is set, but is it from the command line or the environment? 8149 8150 # Try to remove the string !FIND! from our list. 8151 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!FIND!/} 8152 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 8153 # If it failed, the variable was not from the command line. Ignore it, 8154 # but warn the user (except for BASH, which is always set by the calling BASH). 8155 if test "xFIND" != xBASH; then 8156 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of FIND from the environment. Use command line variables instead." >&5 8157 $as_echo "$as_me: WARNING: Ignoring value of FIND from the environment. Use command line variables instead." >&2;} 8158 fi 8159 # Try to locate tool using the code snippet 8160 for ac_prog in find 8161 do 8162 # Extract the first word of "$ac_prog", so it can be a program name with args. 8163 set dummy $ac_prog; ac_word=$2 8164 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 8165 $as_echo_n "checking for $ac_word... " >&6; } 8166 if ${ac_cv_path_FIND+:} false; then : 8167 $as_echo_n "(cached) " >&6 8168 else 8169 case $FIND in 8170 [\\/]* | ?:[\\/]*) 8171 ac_cv_path_FIND="$FIND" # Let the user override the test with a path. 8172 ;; 8173 *) 8174 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 8175 for as_dir in $PATH 8176 do 8177 IFS=$as_save_IFS 8178 test -z "$as_dir" && as_dir=. 8179 for ac_exec_ext in '' $ac_executable_extensions; do 8180 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 8181 ac_cv_path_FIND="$as_dir/$ac_word$ac_exec_ext" 8182 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 8183 break 2 8184 fi 8185 done 8186 done 8187 IFS=$as_save_IFS 8188 8189 ;; 8190 esac 8191 fi 8192 FIND=$ac_cv_path_FIND 8193 if test -n "$FIND"; then 8194 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $FIND" >&5 8195 $as_echo "$FIND" >&6; } 8196 else 8197 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 8198 $as_echo "no" >&6; } 8199 fi 8200 8201 8202 test -n "$FIND" && break 8203 done 8204 8205 else 8206 # If it succeeded, then it was overridden by the user. We will use it 8207 # for the tool. 8208 8209 # First remove it from the list of overridden variables, so we can test 8210 # for unknown variables in the end. 8211 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 8212 8213 # Check if we try to supply an empty value 8214 if test "x$FIND" = x; then 8215 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool FIND= (no value)" >&5 8216 $as_echo "$as_me: Setting user supplied tool FIND= (no value)" >&6;} 8217 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for FIND" >&5 8218 $as_echo_n "checking for FIND... " >&6; } 8219 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 8220 $as_echo "disabled" >&6; } 8221 else 8222 # Check if the provided tool contains a complete path. 8223 tool_specified="$FIND" 8224 tool_basename="${tool_specified##*/}" 8225 if test "x$tool_basename" = "x$tool_specified"; then 8226 # A command without a complete path is provided, search $PATH. 8227 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool FIND=$tool_basename" >&5 8228 $as_echo "$as_me: Will search for user supplied tool FIND=$tool_basename" >&6;} 8229 # Extract the first word of "$tool_basename", so it can be a program name with args. 8230 set dummy $tool_basename; ac_word=$2 8231 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 8232 $as_echo_n "checking for $ac_word... " >&6; } 8233 if ${ac_cv_path_FIND+:} false; then : 8234 $as_echo_n "(cached) " >&6 8235 else 8236 case $FIND in 8237 [\\/]* | ?:[\\/]*) 8238 ac_cv_path_FIND="$FIND" # Let the user override the test with a path. 8239 ;; 8240 *) 8241 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 8242 for as_dir in $PATH 8243 do 8244 IFS=$as_save_IFS 8245 test -z "$as_dir" && as_dir=. 8246 for ac_exec_ext in '' $ac_executable_extensions; do 8247 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 8248 ac_cv_path_FIND="$as_dir/$ac_word$ac_exec_ext" 8249 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 8250 break 2 8251 fi 8252 done 8253 done 8254 IFS=$as_save_IFS 8255 8256 ;; 8257 esac 8258 fi 8259 FIND=$ac_cv_path_FIND 8260 if test -n "$FIND"; then 8261 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $FIND" >&5 8262 $as_echo "$FIND" >&6; } 8263 else 8264 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 8265 $as_echo "no" >&6; } 8266 fi 8267 8268 8269 if test "x$FIND" = x; then 8270 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 8271 fi 8272 else 8273 # Otherwise we believe it is a complete path. Use it as it is. 8274 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool FIND=$tool_specified" >&5 8275 $as_echo "$as_me: Will use user supplied tool FIND=$tool_specified" >&6;} 8276 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for FIND" >&5 8277 $as_echo_n "checking for FIND... " >&6; } 8278 if test ! -x "$tool_specified"; then 8279 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 8280 $as_echo "not found" >&6; } 8281 as_fn_error $? "User supplied tool FIND=$tool_specified does not exist or is not executable" "$LINENO" 5 8282 fi 8283 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 8284 $as_echo "$tool_specified" >&6; } 8285 fi 8286 fi 8287 fi 8288 8289 fi 8290 8291 8292 8293 if test "x$FIND" = x; then 8294 as_fn_error $? "Could not find required tool for FIND" "$LINENO" 5 8295 fi 8296 8297 8298 8299 8300 8301 # Publish this variable in the help. 8302 8303 8304 if [ -z "${HEAD+x}" ]; then 8305 # The variable is not set by user, try to locate tool using the code snippet 8306 for ac_prog in head 8307 do 8308 # Extract the first word of "$ac_prog", so it can be a program name with args. 8309 set dummy $ac_prog; ac_word=$2 8310 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 8311 $as_echo_n "checking for $ac_word... " >&6; } 8312 if ${ac_cv_path_HEAD+:} false; then : 8313 $as_echo_n "(cached) " >&6 8314 else 8315 case $HEAD in 8316 [\\/]* | ?:[\\/]*) 8317 ac_cv_path_HEAD="$HEAD" # Let the user override the test with a path. 8318 ;; 8319 *) 8320 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 8321 for as_dir in $PATH 8322 do 8323 IFS=$as_save_IFS 8324 test -z "$as_dir" && as_dir=. 8325 for ac_exec_ext in '' $ac_executable_extensions; do 8326 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 8327 ac_cv_path_HEAD="$as_dir/$ac_word$ac_exec_ext" 8328 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 8329 break 2 8330 fi 8331 done 8332 done 8333 IFS=$as_save_IFS 8334 8335 ;; 8336 esac 8337 fi 8338 HEAD=$ac_cv_path_HEAD 8339 if test -n "$HEAD"; then 8340 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $HEAD" >&5 8341 $as_echo "$HEAD" >&6; } 8342 else 8343 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 8344 $as_echo "no" >&6; } 8345 fi 8346 8347 8348 test -n "$HEAD" && break 8349 done 8350 8351 else 8352 # The variable is set, but is it from the command line or the environment? 8353 8354 # Try to remove the string !HEAD! from our list. 8355 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!HEAD!/} 8356 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 8357 # If it failed, the variable was not from the command line. Ignore it, 8358 # but warn the user (except for BASH, which is always set by the calling BASH). 8359 if test "xHEAD" != xBASH; then 8360 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of HEAD from the environment. Use command line variables instead." >&5 8361 $as_echo "$as_me: WARNING: Ignoring value of HEAD from the environment. Use command line variables instead." >&2;} 8362 fi 8363 # Try to locate tool using the code snippet 8364 for ac_prog in head 8365 do 8366 # Extract the first word of "$ac_prog", so it can be a program name with args. 8367 set dummy $ac_prog; ac_word=$2 8368 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 8369 $as_echo_n "checking for $ac_word... " >&6; } 8370 if ${ac_cv_path_HEAD+:} false; then : 8371 $as_echo_n "(cached) " >&6 8372 else 8373 case $HEAD in 8374 [\\/]* | ?:[\\/]*) 8375 ac_cv_path_HEAD="$HEAD" # Let the user override the test with a path. 8376 ;; 8377 *) 8378 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 8379 for as_dir in $PATH 8380 do 8381 IFS=$as_save_IFS 8382 test -z "$as_dir" && as_dir=. 8383 for ac_exec_ext in '' $ac_executable_extensions; do 8384 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 8385 ac_cv_path_HEAD="$as_dir/$ac_word$ac_exec_ext" 8386 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 8387 break 2 8388 fi 8389 done 8390 done 8391 IFS=$as_save_IFS 8392 8393 ;; 8394 esac 8395 fi 8396 HEAD=$ac_cv_path_HEAD 8397 if test -n "$HEAD"; then 8398 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $HEAD" >&5 8399 $as_echo "$HEAD" >&6; } 8400 else 8401 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 8402 $as_echo "no" >&6; } 8403 fi 8404 8405 8406 test -n "$HEAD" && break 8407 done 8408 8409 else 8410 # If it succeeded, then it was overridden by the user. We will use it 8411 # for the tool. 8412 8413 # First remove it from the list of overridden variables, so we can test 8414 # for unknown variables in the end. 8415 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 8416 8417 # Check if we try to supply an empty value 8418 if test "x$HEAD" = x; then 8419 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool HEAD= (no value)" >&5 8420 $as_echo "$as_me: Setting user supplied tool HEAD= (no value)" >&6;} 8421 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for HEAD" >&5 8422 $as_echo_n "checking for HEAD... " >&6; } 8423 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 8424 $as_echo "disabled" >&6; } 8425 else 8426 # Check if the provided tool contains a complete path. 8427 tool_specified="$HEAD" 8428 tool_basename="${tool_specified##*/}" 8429 if test "x$tool_basename" = "x$tool_specified"; then 8430 # A command without a complete path is provided, search $PATH. 8431 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool HEAD=$tool_basename" >&5 8432 $as_echo "$as_me: Will search for user supplied tool HEAD=$tool_basename" >&6;} 8433 # Extract the first word of "$tool_basename", so it can be a program name with args. 8434 set dummy $tool_basename; ac_word=$2 8435 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 8436 $as_echo_n "checking for $ac_word... " >&6; } 8437 if ${ac_cv_path_HEAD+:} false; then : 8438 $as_echo_n "(cached) " >&6 8439 else 8440 case $HEAD in 8441 [\\/]* | ?:[\\/]*) 8442 ac_cv_path_HEAD="$HEAD" # Let the user override the test with a path. 8443 ;; 8444 *) 8445 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 8446 for as_dir in $PATH 8447 do 8448 IFS=$as_save_IFS 8449 test -z "$as_dir" && as_dir=. 8450 for ac_exec_ext in '' $ac_executable_extensions; do 8451 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 8452 ac_cv_path_HEAD="$as_dir/$ac_word$ac_exec_ext" 8453 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 8454 break 2 8455 fi 8456 done 8457 done 8458 IFS=$as_save_IFS 8459 8460 ;; 8461 esac 8462 fi 8463 HEAD=$ac_cv_path_HEAD 8464 if test -n "$HEAD"; then 8465 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $HEAD" >&5 8466 $as_echo "$HEAD" >&6; } 8467 else 8468 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 8469 $as_echo "no" >&6; } 8470 fi 8471 8472 8473 if test "x$HEAD" = x; then 8474 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 8475 fi 8476 else 8477 # Otherwise we believe it is a complete path. Use it as it is. 8478 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool HEAD=$tool_specified" >&5 8479 $as_echo "$as_me: Will use user supplied tool HEAD=$tool_specified" >&6;} 8480 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for HEAD" >&5 8481 $as_echo_n "checking for HEAD... " >&6; } 8482 if test ! -x "$tool_specified"; then 8483 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 8484 $as_echo "not found" >&6; } 8485 as_fn_error $? "User supplied tool HEAD=$tool_specified does not exist or is not executable" "$LINENO" 5 8486 fi 8487 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 8488 $as_echo "$tool_specified" >&6; } 8489 fi 8490 fi 8491 fi 8492 8493 fi 8494 8495 8496 8497 if test "x$HEAD" = x; then 8498 as_fn_error $? "Could not find required tool for HEAD" "$LINENO" 5 8499 fi 8500 8501 8502 8503 8504 8505 # Publish this variable in the help. 8506 8507 8508 if [ -z "${GUNZIP+x}" ]; then 8509 # The variable is not set by user, try to locate tool using the code snippet 8510 for ac_prog in gunzip 8511 do 8512 # Extract the first word of "$ac_prog", so it can be a program name with args. 8513 set dummy $ac_prog; ac_word=$2 8514 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 8515 $as_echo_n "checking for $ac_word... " >&6; } 8516 if ${ac_cv_path_GUNZIP+:} false; then : 8517 $as_echo_n "(cached) " >&6 8518 else 8519 case $GUNZIP in 8520 [\\/]* | ?:[\\/]*) 8521 ac_cv_path_GUNZIP="$GUNZIP" # Let the user override the test with a path. 8522 ;; 8523 *) 8524 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 8525 for as_dir in $PATH 8526 do 8527 IFS=$as_save_IFS 8528 test -z "$as_dir" && as_dir=. 8529 for ac_exec_ext in '' $ac_executable_extensions; do 8530 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 8531 ac_cv_path_GUNZIP="$as_dir/$ac_word$ac_exec_ext" 8532 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 8533 break 2 8534 fi 8535 done 8536 done 8537 IFS=$as_save_IFS 8538 8539 ;; 8540 esac 8541 fi 8542 GUNZIP=$ac_cv_path_GUNZIP 8543 if test -n "$GUNZIP"; then 8544 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $GUNZIP" >&5 8545 $as_echo "$GUNZIP" >&6; } 8546 else 8547 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 8548 $as_echo "no" >&6; } 8549 fi 8550 8551 8552 test -n "$GUNZIP" && break 8553 done 8554 8555 else 8556 # The variable is set, but is it from the command line or the environment? 8557 8558 # Try to remove the string !GUNZIP! from our list. 8559 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!GUNZIP!/} 8560 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 8561 # If it failed, the variable was not from the command line. Ignore it, 8562 # but warn the user (except for BASH, which is always set by the calling BASH). 8563 if test "xGUNZIP" != xBASH; then 8564 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of GUNZIP from the environment. Use command line variables instead." >&5 8565 $as_echo "$as_me: WARNING: Ignoring value of GUNZIP from the environment. Use command line variables instead." >&2;} 8566 fi 8567 # Try to locate tool using the code snippet 8568 for ac_prog in gunzip 8569 do 8570 # Extract the first word of "$ac_prog", so it can be a program name with args. 8571 set dummy $ac_prog; ac_word=$2 8572 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 8573 $as_echo_n "checking for $ac_word... " >&6; } 8574 if ${ac_cv_path_GUNZIP+:} false; then : 8575 $as_echo_n "(cached) " >&6 8576 else 8577 case $GUNZIP in 8578 [\\/]* | ?:[\\/]*) 8579 ac_cv_path_GUNZIP="$GUNZIP" # Let the user override the test with a path. 8580 ;; 8581 *) 8582 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 8583 for as_dir in $PATH 8584 do 8585 IFS=$as_save_IFS 8586 test -z "$as_dir" && as_dir=. 8587 for ac_exec_ext in '' $ac_executable_extensions; do 8588 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 8589 ac_cv_path_GUNZIP="$as_dir/$ac_word$ac_exec_ext" 8590 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 8591 break 2 8592 fi 8593 done 8594 done 8595 IFS=$as_save_IFS 8596 8597 ;; 8598 esac 8599 fi 8600 GUNZIP=$ac_cv_path_GUNZIP 8601 if test -n "$GUNZIP"; then 8602 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $GUNZIP" >&5 8603 $as_echo "$GUNZIP" >&6; } 8604 else 8605 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 8606 $as_echo "no" >&6; } 8607 fi 8608 8609 8610 test -n "$GUNZIP" && break 8611 done 8612 8613 else 8614 # If it succeeded, then it was overridden by the user. We will use it 8615 # for the tool. 8616 8617 # First remove it from the list of overridden variables, so we can test 8618 # for unknown variables in the end. 8619 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 8620 8621 # Check if we try to supply an empty value 8622 if test "x$GUNZIP" = x; then 8623 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool GUNZIP= (no value)" >&5 8624 $as_echo "$as_me: Setting user supplied tool GUNZIP= (no value)" >&6;} 8625 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for GUNZIP" >&5 8626 $as_echo_n "checking for GUNZIP... " >&6; } 8627 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 8628 $as_echo "disabled" >&6; } 8629 else 8630 # Check if the provided tool contains a complete path. 8631 tool_specified="$GUNZIP" 8632 tool_basename="${tool_specified##*/}" 8633 if test "x$tool_basename" = "x$tool_specified"; then 8634 # A command without a complete path is provided, search $PATH. 8635 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool GUNZIP=$tool_basename" >&5 8636 $as_echo "$as_me: Will search for user supplied tool GUNZIP=$tool_basename" >&6;} 8637 # Extract the first word of "$tool_basename", so it can be a program name with args. 8638 set dummy $tool_basename; ac_word=$2 8639 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 8640 $as_echo_n "checking for $ac_word... " >&6; } 8641 if ${ac_cv_path_GUNZIP+:} false; then : 8642 $as_echo_n "(cached) " >&6 8643 else 8644 case $GUNZIP in 8645 [\\/]* | ?:[\\/]*) 8646 ac_cv_path_GUNZIP="$GUNZIP" # Let the user override the test with a path. 8647 ;; 8648 *) 8649 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 8650 for as_dir in $PATH 8651 do 8652 IFS=$as_save_IFS 8653 test -z "$as_dir" && as_dir=. 8654 for ac_exec_ext in '' $ac_executable_extensions; do 8655 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 8656 ac_cv_path_GUNZIP="$as_dir/$ac_word$ac_exec_ext" 8657 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 8658 break 2 8659 fi 8660 done 8661 done 8662 IFS=$as_save_IFS 8663 8664 ;; 8665 esac 8666 fi 8667 GUNZIP=$ac_cv_path_GUNZIP 8668 if test -n "$GUNZIP"; then 8669 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $GUNZIP" >&5 8670 $as_echo "$GUNZIP" >&6; } 8671 else 8672 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 8673 $as_echo "no" >&6; } 8674 fi 8675 8676 8677 if test "x$GUNZIP" = x; then 8678 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 8679 fi 8680 else 8681 # Otherwise we believe it is a complete path. Use it as it is. 8682 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool GUNZIP=$tool_specified" >&5 8683 $as_echo "$as_me: Will use user supplied tool GUNZIP=$tool_specified" >&6;} 8684 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for GUNZIP" >&5 8685 $as_echo_n "checking for GUNZIP... " >&6; } 8686 if test ! -x "$tool_specified"; then 8687 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 8688 $as_echo "not found" >&6; } 8689 as_fn_error $? "User supplied tool GUNZIP=$tool_specified does not exist or is not executable" "$LINENO" 5 8690 fi 8691 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 8692 $as_echo "$tool_specified" >&6; } 8693 fi 8694 fi 8695 fi 8696 8697 fi 8698 8699 8700 8701 if test "x$GUNZIP" = x; then 8702 as_fn_error $? "Could not find required tool for GUNZIP" "$LINENO" 5 8703 fi 8704 8705 8706 8707 8708 8709 # Publish this variable in the help. 8710 8711 8712 if [ -z "${GZIP+x}" ]; then 8713 # The variable is not set by user, try to locate tool using the code snippet 8714 for ac_prog in pigz gzip 8715 do 8716 # Extract the first word of "$ac_prog", so it can be a program name with args. 8717 set dummy $ac_prog; ac_word=$2 8718 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 8719 $as_echo_n "checking for $ac_word... " >&6; } 8720 if ${ac_cv_path_GZIP+:} false; then : 8721 $as_echo_n "(cached) " >&6 8722 else 8723 case $GZIP in 8724 [\\/]* | ?:[\\/]*) 8725 ac_cv_path_GZIP="$GZIP" # Let the user override the test with a path. 8726 ;; 8727 *) 8728 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 8729 for as_dir in $PATH 8730 do 8731 IFS=$as_save_IFS 8732 test -z "$as_dir" && as_dir=. 8733 for ac_exec_ext in '' $ac_executable_extensions; do 8734 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 8735 ac_cv_path_GZIP="$as_dir/$ac_word$ac_exec_ext" 8736 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 8737 break 2 8738 fi 8739 done 8740 done 8741 IFS=$as_save_IFS 8742 8743 ;; 8744 esac 8745 fi 8746 GZIP=$ac_cv_path_GZIP 8747 if test -n "$GZIP"; then 8748 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $GZIP" >&5 8749 $as_echo "$GZIP" >&6; } 8750 else 8751 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 8752 $as_echo "no" >&6; } 8753 fi 8754 8755 8756 test -n "$GZIP" && break 8757 done 8758 8759 else 8760 # The variable is set, but is it from the command line or the environment? 8761 8762 # Try to remove the string !GZIP! from our list. 8763 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!GZIP!/} 8764 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 8765 # If it failed, the variable was not from the command line. Ignore it, 8766 # but warn the user (except for BASH, which is always set by the calling BASH). 8767 if test "xGZIP" != xBASH; then 8768 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of GZIP from the environment. Use command line variables instead." >&5 8769 $as_echo "$as_me: WARNING: Ignoring value of GZIP from the environment. Use command line variables instead." >&2;} 8770 fi 8771 # Try to locate tool using the code snippet 8772 for ac_prog in pigz gzip 8773 do 8774 # Extract the first word of "$ac_prog", so it can be a program name with args. 8775 set dummy $ac_prog; ac_word=$2 8776 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 8777 $as_echo_n "checking for $ac_word... " >&6; } 8778 if ${ac_cv_path_GZIP+:} false; then : 8779 $as_echo_n "(cached) " >&6 8780 else 8781 case $GZIP in 8782 [\\/]* | ?:[\\/]*) 8783 ac_cv_path_GZIP="$GZIP" # Let the user override the test with a path. 8784 ;; 8785 *) 8786 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 8787 for as_dir in $PATH 8788 do 8789 IFS=$as_save_IFS 8790 test -z "$as_dir" && as_dir=. 8791 for ac_exec_ext in '' $ac_executable_extensions; do 8792 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 8793 ac_cv_path_GZIP="$as_dir/$ac_word$ac_exec_ext" 8794 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 8795 break 2 8796 fi 8797 done 8798 done 8799 IFS=$as_save_IFS 8800 8801 ;; 8802 esac 8803 fi 8804 GZIP=$ac_cv_path_GZIP 8805 if test -n "$GZIP"; then 8806 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $GZIP" >&5 8807 $as_echo "$GZIP" >&6; } 8808 else 8809 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 8810 $as_echo "no" >&6; } 8811 fi 8812 8813 8814 test -n "$GZIP" && break 8815 done 8816 8817 else 8818 # If it succeeded, then it was overridden by the user. We will use it 8819 # for the tool. 8820 8821 # First remove it from the list of overridden variables, so we can test 8822 # for unknown variables in the end. 8823 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 8824 8825 # Check if we try to supply an empty value 8826 if test "x$GZIP" = x; then 8827 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool GZIP= (no value)" >&5 8828 $as_echo "$as_me: Setting user supplied tool GZIP= (no value)" >&6;} 8829 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for GZIP" >&5 8830 $as_echo_n "checking for GZIP... " >&6; } 8831 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 8832 $as_echo "disabled" >&6; } 8833 else 8834 # Check if the provided tool contains a complete path. 8835 tool_specified="$GZIP" 8836 tool_basename="${tool_specified##*/}" 8837 if test "x$tool_basename" = "x$tool_specified"; then 8838 # A command without a complete path is provided, search $PATH. 8839 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool GZIP=$tool_basename" >&5 8840 $as_echo "$as_me: Will search for user supplied tool GZIP=$tool_basename" >&6;} 8841 # Extract the first word of "$tool_basename", so it can be a program name with args. 8842 set dummy $tool_basename; ac_word=$2 8843 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 8844 $as_echo_n "checking for $ac_word... " >&6; } 8845 if ${ac_cv_path_GZIP+:} false; then : 8846 $as_echo_n "(cached) " >&6 8847 else 8848 case $GZIP in 8849 [\\/]* | ?:[\\/]*) 8850 ac_cv_path_GZIP="$GZIP" # Let the user override the test with a path. 8851 ;; 8852 *) 8853 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 8854 for as_dir in $PATH 8855 do 8856 IFS=$as_save_IFS 8857 test -z "$as_dir" && as_dir=. 8858 for ac_exec_ext in '' $ac_executable_extensions; do 8859 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 8860 ac_cv_path_GZIP="$as_dir/$ac_word$ac_exec_ext" 8861 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 8862 break 2 8863 fi 8864 done 8865 done 8866 IFS=$as_save_IFS 8867 8868 ;; 8869 esac 8870 fi 8871 GZIP=$ac_cv_path_GZIP 8872 if test -n "$GZIP"; then 8873 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $GZIP" >&5 8874 $as_echo "$GZIP" >&6; } 8875 else 8876 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 8877 $as_echo "no" >&6; } 8878 fi 8879 8880 8881 if test "x$GZIP" = x; then 8882 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 8883 fi 8884 else 8885 # Otherwise we believe it is a complete path. Use it as it is. 8886 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool GZIP=$tool_specified" >&5 8887 $as_echo "$as_me: Will use user supplied tool GZIP=$tool_specified" >&6;} 8888 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for GZIP" >&5 8889 $as_echo_n "checking for GZIP... " >&6; } 8890 if test ! -x "$tool_specified"; then 8891 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 8892 $as_echo "not found" >&6; } 8893 as_fn_error $? "User supplied tool GZIP=$tool_specified does not exist or is not executable" "$LINENO" 5 8894 fi 8895 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 8896 $as_echo "$tool_specified" >&6; } 8897 fi 8898 fi 8899 fi 8900 8901 fi 8902 8903 8904 8905 if test "x$GZIP" = x; then 8906 as_fn_error $? "Could not find required tool for GZIP" "$LINENO" 5 8907 fi 8908 8909 8910 8911 8912 8913 # Publish this variable in the help. 8914 8915 8916 if [ -z "${LN+x}" ]; then 8917 # The variable is not set by user, try to locate tool using the code snippet 8918 for ac_prog in ln 8919 do 8920 # Extract the first word of "$ac_prog", so it can be a program name with args. 8921 set dummy $ac_prog; ac_word=$2 8922 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 8923 $as_echo_n "checking for $ac_word... " >&6; } 8924 if ${ac_cv_path_LN+:} false; then : 8925 $as_echo_n "(cached) " >&6 8926 else 8927 case $LN in 8928 [\\/]* | ?:[\\/]*) 8929 ac_cv_path_LN="$LN" # Let the user override the test with a path. 8930 ;; 8931 *) 8932 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 8933 for as_dir in $PATH 8934 do 8935 IFS=$as_save_IFS 8936 test -z "$as_dir" && as_dir=. 8937 for ac_exec_ext in '' $ac_executable_extensions; do 8938 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 8939 ac_cv_path_LN="$as_dir/$ac_word$ac_exec_ext" 8940 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 8941 break 2 8942 fi 8943 done 8944 done 8945 IFS=$as_save_IFS 8946 8947 ;; 8948 esac 8949 fi 8950 LN=$ac_cv_path_LN 8951 if test -n "$LN"; then 8952 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $LN" >&5 8953 $as_echo "$LN" >&6; } 8954 else 8955 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 8956 $as_echo "no" >&6; } 8957 fi 8958 8959 8960 test -n "$LN" && break 8961 done 8962 8963 else 8964 # The variable is set, but is it from the command line or the environment? 8965 8966 # Try to remove the string !LN! from our list. 8967 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!LN!/} 8968 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 8969 # If it failed, the variable was not from the command line. Ignore it, 8970 # but warn the user (except for BASH, which is always set by the calling BASH). 8971 if test "xLN" != xBASH; then 8972 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of LN from the environment. Use command line variables instead." >&5 8973 $as_echo "$as_me: WARNING: Ignoring value of LN from the environment. Use command line variables instead." >&2;} 8974 fi 8975 # Try to locate tool using the code snippet 8976 for ac_prog in ln 8977 do 8978 # Extract the first word of "$ac_prog", so it can be a program name with args. 8979 set dummy $ac_prog; ac_word=$2 8980 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 8981 $as_echo_n "checking for $ac_word... " >&6; } 8982 if ${ac_cv_path_LN+:} false; then : 8983 $as_echo_n "(cached) " >&6 8984 else 8985 case $LN in 8986 [\\/]* | ?:[\\/]*) 8987 ac_cv_path_LN="$LN" # Let the user override the test with a path. 8988 ;; 8989 *) 8990 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 8991 for as_dir in $PATH 8992 do 8993 IFS=$as_save_IFS 8994 test -z "$as_dir" && as_dir=. 8995 for ac_exec_ext in '' $ac_executable_extensions; do 8996 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 8997 ac_cv_path_LN="$as_dir/$ac_word$ac_exec_ext" 8998 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 8999 break 2 9000 fi 9001 done 9002 done 9003 IFS=$as_save_IFS 9004 9005 ;; 9006 esac 9007 fi 9008 LN=$ac_cv_path_LN 9009 if test -n "$LN"; then 9010 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $LN" >&5 9011 $as_echo "$LN" >&6; } 9012 else 9013 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 9014 $as_echo "no" >&6; } 9015 fi 9016 9017 9018 test -n "$LN" && break 9019 done 9020 9021 else 9022 # If it succeeded, then it was overridden by the user. We will use it 9023 # for the tool. 9024 9025 # First remove it from the list of overridden variables, so we can test 9026 # for unknown variables in the end. 9027 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 9028 9029 # Check if we try to supply an empty value 9030 if test "x$LN" = x; then 9031 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool LN= (no value)" >&5 9032 $as_echo "$as_me: Setting user supplied tool LN= (no value)" >&6;} 9033 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for LN" >&5 9034 $as_echo_n "checking for LN... " >&6; } 9035 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 9036 $as_echo "disabled" >&6; } 9037 else 9038 # Check if the provided tool contains a complete path. 9039 tool_specified="$LN" 9040 tool_basename="${tool_specified##*/}" 9041 if test "x$tool_basename" = "x$tool_specified"; then 9042 # A command without a complete path is provided, search $PATH. 9043 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool LN=$tool_basename" >&5 9044 $as_echo "$as_me: Will search for user supplied tool LN=$tool_basename" >&6;} 9045 # Extract the first word of "$tool_basename", so it can be a program name with args. 9046 set dummy $tool_basename; ac_word=$2 9047 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 9048 $as_echo_n "checking for $ac_word... " >&6; } 9049 if ${ac_cv_path_LN+:} false; then : 9050 $as_echo_n "(cached) " >&6 9051 else 9052 case $LN in 9053 [\\/]* | ?:[\\/]*) 9054 ac_cv_path_LN="$LN" # Let the user override the test with a path. 9055 ;; 9056 *) 9057 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 9058 for as_dir in $PATH 9059 do 9060 IFS=$as_save_IFS 9061 test -z "$as_dir" && as_dir=. 9062 for ac_exec_ext in '' $ac_executable_extensions; do 9063 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 9064 ac_cv_path_LN="$as_dir/$ac_word$ac_exec_ext" 9065 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 9066 break 2 9067 fi 9068 done 9069 done 9070 IFS=$as_save_IFS 9071 9072 ;; 9073 esac 9074 fi 9075 LN=$ac_cv_path_LN 9076 if test -n "$LN"; then 9077 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $LN" >&5 9078 $as_echo "$LN" >&6; } 9079 else 9080 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 9081 $as_echo "no" >&6; } 9082 fi 9083 9084 9085 if test "x$LN" = x; then 9086 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 9087 fi 9088 else 9089 # Otherwise we believe it is a complete path. Use it as it is. 9090 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool LN=$tool_specified" >&5 9091 $as_echo "$as_me: Will use user supplied tool LN=$tool_specified" >&6;} 9092 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for LN" >&5 9093 $as_echo_n "checking for LN... " >&6; } 9094 if test ! -x "$tool_specified"; then 9095 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 9096 $as_echo "not found" >&6; } 9097 as_fn_error $? "User supplied tool LN=$tool_specified does not exist or is not executable" "$LINENO" 5 9098 fi 9099 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 9100 $as_echo "$tool_specified" >&6; } 9101 fi 9102 fi 9103 fi 9104 9105 fi 9106 9107 9108 9109 if test "x$LN" = x; then 9110 as_fn_error $? "Could not find required tool for LN" "$LINENO" 5 9111 fi 9112 9113 9114 9115 9116 9117 # Publish this variable in the help. 9118 9119 9120 if [ -z "${LS+x}" ]; then 9121 # The variable is not set by user, try to locate tool using the code snippet 9122 for ac_prog in ls 9123 do 9124 # Extract the first word of "$ac_prog", so it can be a program name with args. 9125 set dummy $ac_prog; ac_word=$2 9126 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 9127 $as_echo_n "checking for $ac_word... " >&6; } 9128 if ${ac_cv_path_LS+:} false; then : 9129 $as_echo_n "(cached) " >&6 9130 else 9131 case $LS in 9132 [\\/]* | ?:[\\/]*) 9133 ac_cv_path_LS="$LS" # Let the user override the test with a path. 9134 ;; 9135 *) 9136 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 9137 for as_dir in $PATH 9138 do 9139 IFS=$as_save_IFS 9140 test -z "$as_dir" && as_dir=. 9141 for ac_exec_ext in '' $ac_executable_extensions; do 9142 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 9143 ac_cv_path_LS="$as_dir/$ac_word$ac_exec_ext" 9144 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 9145 break 2 9146 fi 9147 done 9148 done 9149 IFS=$as_save_IFS 9150 9151 ;; 9152 esac 9153 fi 9154 LS=$ac_cv_path_LS 9155 if test -n "$LS"; then 9156 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $LS" >&5 9157 $as_echo "$LS" >&6; } 9158 else 9159 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 9160 $as_echo "no" >&6; } 9161 fi 9162 9163 9164 test -n "$LS" && break 9165 done 9166 9167 else 9168 # The variable is set, but is it from the command line or the environment? 9169 9170 # Try to remove the string !LS! from our list. 9171 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!LS!/} 9172 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 9173 # If it failed, the variable was not from the command line. Ignore it, 9174 # but warn the user (except for BASH, which is always set by the calling BASH). 9175 if test "xLS" != xBASH; then 9176 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of LS from the environment. Use command line variables instead." >&5 9177 $as_echo "$as_me: WARNING: Ignoring value of LS from the environment. Use command line variables instead." >&2;} 9178 fi 9179 # Try to locate tool using the code snippet 9180 for ac_prog in ls 9181 do 9182 # Extract the first word of "$ac_prog", so it can be a program name with args. 9183 set dummy $ac_prog; ac_word=$2 9184 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 9185 $as_echo_n "checking for $ac_word... " >&6; } 9186 if ${ac_cv_path_LS+:} false; then : 9187 $as_echo_n "(cached) " >&6 9188 else 9189 case $LS in 9190 [\\/]* | ?:[\\/]*) 9191 ac_cv_path_LS="$LS" # Let the user override the test with a path. 9192 ;; 9193 *) 9194 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 9195 for as_dir in $PATH 9196 do 9197 IFS=$as_save_IFS 9198 test -z "$as_dir" && as_dir=. 9199 for ac_exec_ext in '' $ac_executable_extensions; do 9200 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 9201 ac_cv_path_LS="$as_dir/$ac_word$ac_exec_ext" 9202 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 9203 break 2 9204 fi 9205 done 9206 done 9207 IFS=$as_save_IFS 9208 9209 ;; 9210 esac 9211 fi 9212 LS=$ac_cv_path_LS 9213 if test -n "$LS"; then 9214 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $LS" >&5 9215 $as_echo "$LS" >&6; } 9216 else 9217 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 9218 $as_echo "no" >&6; } 9219 fi 9220 9221 9222 test -n "$LS" && break 9223 done 9224 9225 else 9226 # If it succeeded, then it was overridden by the user. We will use it 9227 # for the tool. 9228 9229 # First remove it from the list of overridden variables, so we can test 9230 # for unknown variables in the end. 9231 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 9232 9233 # Check if we try to supply an empty value 9234 if test "x$LS" = x; then 9235 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool LS= (no value)" >&5 9236 $as_echo "$as_me: Setting user supplied tool LS= (no value)" >&6;} 9237 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for LS" >&5 9238 $as_echo_n "checking for LS... " >&6; } 9239 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 9240 $as_echo "disabled" >&6; } 9241 else 9242 # Check if the provided tool contains a complete path. 9243 tool_specified="$LS" 9244 tool_basename="${tool_specified##*/}" 9245 if test "x$tool_basename" = "x$tool_specified"; then 9246 # A command without a complete path is provided, search $PATH. 9247 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool LS=$tool_basename" >&5 9248 $as_echo "$as_me: Will search for user supplied tool LS=$tool_basename" >&6;} 9249 # Extract the first word of "$tool_basename", so it can be a program name with args. 9250 set dummy $tool_basename; ac_word=$2 9251 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 9252 $as_echo_n "checking for $ac_word... " >&6; } 9253 if ${ac_cv_path_LS+:} false; then : 9254 $as_echo_n "(cached) " >&6 9255 else 9256 case $LS in 9257 [\\/]* | ?:[\\/]*) 9258 ac_cv_path_LS="$LS" # Let the user override the test with a path. 9259 ;; 9260 *) 9261 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 9262 for as_dir in $PATH 9263 do 9264 IFS=$as_save_IFS 9265 test -z "$as_dir" && as_dir=. 9266 for ac_exec_ext in '' $ac_executable_extensions; do 9267 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 9268 ac_cv_path_LS="$as_dir/$ac_word$ac_exec_ext" 9269 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 9270 break 2 9271 fi 9272 done 9273 done 9274 IFS=$as_save_IFS 9275 9276 ;; 9277 esac 9278 fi 9279 LS=$ac_cv_path_LS 9280 if test -n "$LS"; then 9281 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $LS" >&5 9282 $as_echo "$LS" >&6; } 9283 else 9284 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 9285 $as_echo "no" >&6; } 9286 fi 9287 9288 9289 if test "x$LS" = x; then 9290 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 9291 fi 9292 else 9293 # Otherwise we believe it is a complete path. Use it as it is. 9294 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool LS=$tool_specified" >&5 9295 $as_echo "$as_me: Will use user supplied tool LS=$tool_specified" >&6;} 9296 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for LS" >&5 9297 $as_echo_n "checking for LS... " >&6; } 9298 if test ! -x "$tool_specified"; then 9299 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 9300 $as_echo "not found" >&6; } 9301 as_fn_error $? "User supplied tool LS=$tool_specified does not exist or is not executable" "$LINENO" 5 9302 fi 9303 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 9304 $as_echo "$tool_specified" >&6; } 9305 fi 9306 fi 9307 fi 9308 9309 fi 9310 9311 9312 9313 if test "x$LS" = x; then 9314 as_fn_error $? "Could not find required tool for LS" "$LINENO" 5 9315 fi 9316 9317 9318 9319 9320 9321 # Publish this variable in the help. 9322 9323 9324 if [ -z "${MKDIR+x}" ]; then 9325 # The variable is not set by user, try to locate tool using the code snippet 9326 for ac_prog in mkdir 9327 do 9328 # Extract the first word of "$ac_prog", so it can be a program name with args. 9329 set dummy $ac_prog; ac_word=$2 9330 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 9331 $as_echo_n "checking for $ac_word... " >&6; } 9332 if ${ac_cv_path_MKDIR+:} false; then : 9333 $as_echo_n "(cached) " >&6 9334 else 9335 case $MKDIR in 9336 [\\/]* | ?:[\\/]*) 9337 ac_cv_path_MKDIR="$MKDIR" # Let the user override the test with a path. 9338 ;; 9339 *) 9340 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 9341 for as_dir in $PATH 9342 do 9343 IFS=$as_save_IFS 9344 test -z "$as_dir" && as_dir=. 9345 for ac_exec_ext in '' $ac_executable_extensions; do 9346 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 9347 ac_cv_path_MKDIR="$as_dir/$ac_word$ac_exec_ext" 9348 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 9349 break 2 9350 fi 9351 done 9352 done 9353 IFS=$as_save_IFS 9354 9355 ;; 9356 esac 9357 fi 9358 MKDIR=$ac_cv_path_MKDIR 9359 if test -n "$MKDIR"; then 9360 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MKDIR" >&5 9361 $as_echo "$MKDIR" >&6; } 9362 else 9363 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 9364 $as_echo "no" >&6; } 9365 fi 9366 9367 9368 test -n "$MKDIR" && break 9369 done 9370 9371 else 9372 # The variable is set, but is it from the command line or the environment? 9373 9374 # Try to remove the string !MKDIR! from our list. 9375 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!MKDIR!/} 9376 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 9377 # If it failed, the variable was not from the command line. Ignore it, 9378 # but warn the user (except for BASH, which is always set by the calling BASH). 9379 if test "xMKDIR" != xBASH; then 9380 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of MKDIR from the environment. Use command line variables instead." >&5 9381 $as_echo "$as_me: WARNING: Ignoring value of MKDIR from the environment. Use command line variables instead." >&2;} 9382 fi 9383 # Try to locate tool using the code snippet 9384 for ac_prog in mkdir 9385 do 9386 # Extract the first word of "$ac_prog", so it can be a program name with args. 9387 set dummy $ac_prog; ac_word=$2 9388 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 9389 $as_echo_n "checking for $ac_word... " >&6; } 9390 if ${ac_cv_path_MKDIR+:} false; then : 9391 $as_echo_n "(cached) " >&6 9392 else 9393 case $MKDIR in 9394 [\\/]* | ?:[\\/]*) 9395 ac_cv_path_MKDIR="$MKDIR" # Let the user override the test with a path. 9396 ;; 9397 *) 9398 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 9399 for as_dir in $PATH 9400 do 9401 IFS=$as_save_IFS 9402 test -z "$as_dir" && as_dir=. 9403 for ac_exec_ext in '' $ac_executable_extensions; do 9404 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 9405 ac_cv_path_MKDIR="$as_dir/$ac_word$ac_exec_ext" 9406 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 9407 break 2 9408 fi 9409 done 9410 done 9411 IFS=$as_save_IFS 9412 9413 ;; 9414 esac 9415 fi 9416 MKDIR=$ac_cv_path_MKDIR 9417 if test -n "$MKDIR"; then 9418 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MKDIR" >&5 9419 $as_echo "$MKDIR" >&6; } 9420 else 9421 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 9422 $as_echo "no" >&6; } 9423 fi 9424 9425 9426 test -n "$MKDIR" && break 9427 done 9428 9429 else 9430 # If it succeeded, then it was overridden by the user. We will use it 9431 # for the tool. 9432 9433 # First remove it from the list of overridden variables, so we can test 9434 # for unknown variables in the end. 9435 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 9436 9437 # Check if we try to supply an empty value 9438 if test "x$MKDIR" = x; then 9439 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool MKDIR= (no value)" >&5 9440 $as_echo "$as_me: Setting user supplied tool MKDIR= (no value)" >&6;} 9441 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for MKDIR" >&5 9442 $as_echo_n "checking for MKDIR... " >&6; } 9443 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 9444 $as_echo "disabled" >&6; } 9445 else 9446 # Check if the provided tool contains a complete path. 9447 tool_specified="$MKDIR" 9448 tool_basename="${tool_specified##*/}" 9449 if test "x$tool_basename" = "x$tool_specified"; then 9450 # A command without a complete path is provided, search $PATH. 9451 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool MKDIR=$tool_basename" >&5 9452 $as_echo "$as_me: Will search for user supplied tool MKDIR=$tool_basename" >&6;} 9453 # Extract the first word of "$tool_basename", so it can be a program name with args. 9454 set dummy $tool_basename; ac_word=$2 9455 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 9456 $as_echo_n "checking for $ac_word... " >&6; } 9457 if ${ac_cv_path_MKDIR+:} false; then : 9458 $as_echo_n "(cached) " >&6 9459 else 9460 case $MKDIR in 9461 [\\/]* | ?:[\\/]*) 9462 ac_cv_path_MKDIR="$MKDIR" # Let the user override the test with a path. 9463 ;; 9464 *) 9465 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 9466 for as_dir in $PATH 9467 do 9468 IFS=$as_save_IFS 9469 test -z "$as_dir" && as_dir=. 9470 for ac_exec_ext in '' $ac_executable_extensions; do 9471 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 9472 ac_cv_path_MKDIR="$as_dir/$ac_word$ac_exec_ext" 9473 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 9474 break 2 9475 fi 9476 done 9477 done 9478 IFS=$as_save_IFS 9479 9480 ;; 9481 esac 9482 fi 9483 MKDIR=$ac_cv_path_MKDIR 9484 if test -n "$MKDIR"; then 9485 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MKDIR" >&5 9486 $as_echo "$MKDIR" >&6; } 9487 else 9488 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 9489 $as_echo "no" >&6; } 9490 fi 9491 9492 9493 if test "x$MKDIR" = x; then 9494 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 9495 fi 9496 else 9497 # Otherwise we believe it is a complete path. Use it as it is. 9498 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool MKDIR=$tool_specified" >&5 9499 $as_echo "$as_me: Will use user supplied tool MKDIR=$tool_specified" >&6;} 9500 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for MKDIR" >&5 9501 $as_echo_n "checking for MKDIR... " >&6; } 9502 if test ! -x "$tool_specified"; then 9503 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 9504 $as_echo "not found" >&6; } 9505 as_fn_error $? "User supplied tool MKDIR=$tool_specified does not exist or is not executable" "$LINENO" 5 9506 fi 9507 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 9508 $as_echo "$tool_specified" >&6; } 9509 fi 9510 fi 9511 fi 9512 9513 fi 9514 9515 9516 9517 if test "x$MKDIR" = x; then 9518 as_fn_error $? "Could not find required tool for MKDIR" "$LINENO" 5 9519 fi 9520 9521 9522 9523 9524 9525 # Publish this variable in the help. 9526 9527 9528 if [ -z "${MKTEMP+x}" ]; then 9529 # The variable is not set by user, try to locate tool using the code snippet 9530 for ac_prog in mktemp 9531 do 9532 # Extract the first word of "$ac_prog", so it can be a program name with args. 9533 set dummy $ac_prog; ac_word=$2 9534 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 9535 $as_echo_n "checking for $ac_word... " >&6; } 9536 if ${ac_cv_path_MKTEMP+:} false; then : 9537 $as_echo_n "(cached) " >&6 9538 else 9539 case $MKTEMP in 9540 [\\/]* | ?:[\\/]*) 9541 ac_cv_path_MKTEMP="$MKTEMP" # Let the user override the test with a path. 9542 ;; 9543 *) 9544 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 9545 for as_dir in $PATH 9546 do 9547 IFS=$as_save_IFS 9548 test -z "$as_dir" && as_dir=. 9549 for ac_exec_ext in '' $ac_executable_extensions; do 9550 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 9551 ac_cv_path_MKTEMP="$as_dir/$ac_word$ac_exec_ext" 9552 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 9553 break 2 9554 fi 9555 done 9556 done 9557 IFS=$as_save_IFS 9558 9559 ;; 9560 esac 9561 fi 9562 MKTEMP=$ac_cv_path_MKTEMP 9563 if test -n "$MKTEMP"; then 9564 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MKTEMP" >&5 9565 $as_echo "$MKTEMP" >&6; } 9566 else 9567 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 9568 $as_echo "no" >&6; } 9569 fi 9570 9571 9572 test -n "$MKTEMP" && break 9573 done 9574 9575 else 9576 # The variable is set, but is it from the command line or the environment? 9577 9578 # Try to remove the string !MKTEMP! from our list. 9579 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!MKTEMP!/} 9580 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 9581 # If it failed, the variable was not from the command line. Ignore it, 9582 # but warn the user (except for BASH, which is always set by the calling BASH). 9583 if test "xMKTEMP" != xBASH; then 9584 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of MKTEMP from the environment. Use command line variables instead." >&5 9585 $as_echo "$as_me: WARNING: Ignoring value of MKTEMP from the environment. Use command line variables instead." >&2;} 9586 fi 9587 # Try to locate tool using the code snippet 9588 for ac_prog in mktemp 9589 do 9590 # Extract the first word of "$ac_prog", so it can be a program name with args. 9591 set dummy $ac_prog; ac_word=$2 9592 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 9593 $as_echo_n "checking for $ac_word... " >&6; } 9594 if ${ac_cv_path_MKTEMP+:} false; then : 9595 $as_echo_n "(cached) " >&6 9596 else 9597 case $MKTEMP in 9598 [\\/]* | ?:[\\/]*) 9599 ac_cv_path_MKTEMP="$MKTEMP" # Let the user override the test with a path. 9600 ;; 9601 *) 9602 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 9603 for as_dir in $PATH 9604 do 9605 IFS=$as_save_IFS 9606 test -z "$as_dir" && as_dir=. 9607 for ac_exec_ext in '' $ac_executable_extensions; do 9608 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 9609 ac_cv_path_MKTEMP="$as_dir/$ac_word$ac_exec_ext" 9610 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 9611 break 2 9612 fi 9613 done 9614 done 9615 IFS=$as_save_IFS 9616 9617 ;; 9618 esac 9619 fi 9620 MKTEMP=$ac_cv_path_MKTEMP 9621 if test -n "$MKTEMP"; then 9622 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MKTEMP" >&5 9623 $as_echo "$MKTEMP" >&6; } 9624 else 9625 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 9626 $as_echo "no" >&6; } 9627 fi 9628 9629 9630 test -n "$MKTEMP" && break 9631 done 9632 9633 else 9634 # If it succeeded, then it was overridden by the user. We will use it 9635 # for the tool. 9636 9637 # First remove it from the list of overridden variables, so we can test 9638 # for unknown variables in the end. 9639 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 9640 9641 # Check if we try to supply an empty value 9642 if test "x$MKTEMP" = x; then 9643 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool MKTEMP= (no value)" >&5 9644 $as_echo "$as_me: Setting user supplied tool MKTEMP= (no value)" >&6;} 9645 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for MKTEMP" >&5 9646 $as_echo_n "checking for MKTEMP... " >&6; } 9647 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 9648 $as_echo "disabled" >&6; } 9649 else 9650 # Check if the provided tool contains a complete path. 9651 tool_specified="$MKTEMP" 9652 tool_basename="${tool_specified##*/}" 9653 if test "x$tool_basename" = "x$tool_specified"; then 9654 # A command without a complete path is provided, search $PATH. 9655 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool MKTEMP=$tool_basename" >&5 9656 $as_echo "$as_me: Will search for user supplied tool MKTEMP=$tool_basename" >&6;} 9657 # Extract the first word of "$tool_basename", so it can be a program name with args. 9658 set dummy $tool_basename; ac_word=$2 9659 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 9660 $as_echo_n "checking for $ac_word... " >&6; } 9661 if ${ac_cv_path_MKTEMP+:} false; then : 9662 $as_echo_n "(cached) " >&6 9663 else 9664 case $MKTEMP in 9665 [\\/]* | ?:[\\/]*) 9666 ac_cv_path_MKTEMP="$MKTEMP" # Let the user override the test with a path. 9667 ;; 9668 *) 9669 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 9670 for as_dir in $PATH 9671 do 9672 IFS=$as_save_IFS 9673 test -z "$as_dir" && as_dir=. 9674 for ac_exec_ext in '' $ac_executable_extensions; do 9675 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 9676 ac_cv_path_MKTEMP="$as_dir/$ac_word$ac_exec_ext" 9677 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 9678 break 2 9679 fi 9680 done 9681 done 9682 IFS=$as_save_IFS 9683 9684 ;; 9685 esac 9686 fi 9687 MKTEMP=$ac_cv_path_MKTEMP 9688 if test -n "$MKTEMP"; then 9689 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MKTEMP" >&5 9690 $as_echo "$MKTEMP" >&6; } 9691 else 9692 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 9693 $as_echo "no" >&6; } 9694 fi 9695 9696 9697 if test "x$MKTEMP" = x; then 9698 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 9699 fi 9700 else 9701 # Otherwise we believe it is a complete path. Use it as it is. 9702 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool MKTEMP=$tool_specified" >&5 9703 $as_echo "$as_me: Will use user supplied tool MKTEMP=$tool_specified" >&6;} 9704 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for MKTEMP" >&5 9705 $as_echo_n "checking for MKTEMP... " >&6; } 9706 if test ! -x "$tool_specified"; then 9707 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 9708 $as_echo "not found" >&6; } 9709 as_fn_error $? "User supplied tool MKTEMP=$tool_specified does not exist or is not executable" "$LINENO" 5 9710 fi 9711 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 9712 $as_echo "$tool_specified" >&6; } 9713 fi 9714 fi 9715 fi 9716 9717 fi 9718 9719 9720 9721 if test "x$MKTEMP" = x; then 9722 as_fn_error $? "Could not find required tool for MKTEMP" "$LINENO" 5 9723 fi 9724 9725 9726 9727 9728 9729 # Publish this variable in the help. 9730 9731 9732 if [ -z "${MV+x}" ]; then 9733 # The variable is not set by user, try to locate tool using the code snippet 9734 for ac_prog in mv 9735 do 9736 # Extract the first word of "$ac_prog", so it can be a program name with args. 9737 set dummy $ac_prog; ac_word=$2 9738 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 9739 $as_echo_n "checking for $ac_word... " >&6; } 9740 if ${ac_cv_path_MV+:} false; then : 9741 $as_echo_n "(cached) " >&6 9742 else 9743 case $MV in 9744 [\\/]* | ?:[\\/]*) 9745 ac_cv_path_MV="$MV" # Let the user override the test with a path. 9746 ;; 9747 *) 9748 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 9749 for as_dir in $PATH 9750 do 9751 IFS=$as_save_IFS 9752 test -z "$as_dir" && as_dir=. 9753 for ac_exec_ext in '' $ac_executable_extensions; do 9754 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 9755 ac_cv_path_MV="$as_dir/$ac_word$ac_exec_ext" 9756 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 9757 break 2 9758 fi 9759 done 9760 done 9761 IFS=$as_save_IFS 9762 9763 ;; 9764 esac 9765 fi 9766 MV=$ac_cv_path_MV 9767 if test -n "$MV"; then 9768 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MV" >&5 9769 $as_echo "$MV" >&6; } 9770 else 9771 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 9772 $as_echo "no" >&6; } 9773 fi 9774 9775 9776 test -n "$MV" && break 9777 done 9778 9779 else 9780 # The variable is set, but is it from the command line or the environment? 9781 9782 # Try to remove the string !MV! from our list. 9783 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!MV!/} 9784 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 9785 # If it failed, the variable was not from the command line. Ignore it, 9786 # but warn the user (except for BASH, which is always set by the calling BASH). 9787 if test "xMV" != xBASH; then 9788 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of MV from the environment. Use command line variables instead." >&5 9789 $as_echo "$as_me: WARNING: Ignoring value of MV from the environment. Use command line variables instead." >&2;} 9790 fi 9791 # Try to locate tool using the code snippet 9792 for ac_prog in mv 9793 do 9794 # Extract the first word of "$ac_prog", so it can be a program name with args. 9795 set dummy $ac_prog; ac_word=$2 9796 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 9797 $as_echo_n "checking for $ac_word... " >&6; } 9798 if ${ac_cv_path_MV+:} false; then : 9799 $as_echo_n "(cached) " >&6 9800 else 9801 case $MV in 9802 [\\/]* | ?:[\\/]*) 9803 ac_cv_path_MV="$MV" # Let the user override the test with a path. 9804 ;; 9805 *) 9806 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 9807 for as_dir in $PATH 9808 do 9809 IFS=$as_save_IFS 9810 test -z "$as_dir" && as_dir=. 9811 for ac_exec_ext in '' $ac_executable_extensions; do 9812 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 9813 ac_cv_path_MV="$as_dir/$ac_word$ac_exec_ext" 9814 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 9815 break 2 9816 fi 9817 done 9818 done 9819 IFS=$as_save_IFS 9820 9821 ;; 9822 esac 9823 fi 9824 MV=$ac_cv_path_MV 9825 if test -n "$MV"; then 9826 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MV" >&5 9827 $as_echo "$MV" >&6; } 9828 else 9829 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 9830 $as_echo "no" >&6; } 9831 fi 9832 9833 9834 test -n "$MV" && break 9835 done 9836 9837 else 9838 # If it succeeded, then it was overridden by the user. We will use it 9839 # for the tool. 9840 9841 # First remove it from the list of overridden variables, so we can test 9842 # for unknown variables in the end. 9843 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 9844 9845 # Check if we try to supply an empty value 9846 if test "x$MV" = x; then 9847 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool MV= (no value)" >&5 9848 $as_echo "$as_me: Setting user supplied tool MV= (no value)" >&6;} 9849 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for MV" >&5 9850 $as_echo_n "checking for MV... " >&6; } 9851 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 9852 $as_echo "disabled" >&6; } 9853 else 9854 # Check if the provided tool contains a complete path. 9855 tool_specified="$MV" 9856 tool_basename="${tool_specified##*/}" 9857 if test "x$tool_basename" = "x$tool_specified"; then 9858 # A command without a complete path is provided, search $PATH. 9859 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool MV=$tool_basename" >&5 9860 $as_echo "$as_me: Will search for user supplied tool MV=$tool_basename" >&6;} 9861 # Extract the first word of "$tool_basename", so it can be a program name with args. 9862 set dummy $tool_basename; ac_word=$2 9863 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 9864 $as_echo_n "checking for $ac_word... " >&6; } 9865 if ${ac_cv_path_MV+:} false; then : 9866 $as_echo_n "(cached) " >&6 9867 else 9868 case $MV in 9869 [\\/]* | ?:[\\/]*) 9870 ac_cv_path_MV="$MV" # Let the user override the test with a path. 9871 ;; 9872 *) 9873 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 9874 for as_dir in $PATH 9875 do 9876 IFS=$as_save_IFS 9877 test -z "$as_dir" && as_dir=. 9878 for ac_exec_ext in '' $ac_executable_extensions; do 9879 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 9880 ac_cv_path_MV="$as_dir/$ac_word$ac_exec_ext" 9881 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 9882 break 2 9883 fi 9884 done 9885 done 9886 IFS=$as_save_IFS 9887 9888 ;; 9889 esac 9890 fi 9891 MV=$ac_cv_path_MV 9892 if test -n "$MV"; then 9893 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MV" >&5 9894 $as_echo "$MV" >&6; } 9895 else 9896 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 9897 $as_echo "no" >&6; } 9898 fi 9899 9900 9901 if test "x$MV" = x; then 9902 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 9903 fi 9904 else 9905 # Otherwise we believe it is a complete path. Use it as it is. 9906 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool MV=$tool_specified" >&5 9907 $as_echo "$as_me: Will use user supplied tool MV=$tool_specified" >&6;} 9908 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for MV" >&5 9909 $as_echo_n "checking for MV... " >&6; } 9910 if test ! -x "$tool_specified"; then 9911 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 9912 $as_echo "not found" >&6; } 9913 as_fn_error $? "User supplied tool MV=$tool_specified does not exist or is not executable" "$LINENO" 5 9914 fi 9915 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 9916 $as_echo "$tool_specified" >&6; } 9917 fi 9918 fi 9919 fi 9920 9921 fi 9922 9923 9924 9925 if test "x$MV" = x; then 9926 as_fn_error $? "Could not find required tool for MV" "$LINENO" 5 9927 fi 9928 9929 9930 9931 9932 9933 # Publish this variable in the help. 9934 9935 9936 if [ -z "${NAWK+x}" ]; then 9937 # The variable is not set by user, try to locate tool using the code snippet 9938 for ac_prog in nawk gawk awk 9939 do 9940 # Extract the first word of "$ac_prog", so it can be a program name with args. 9941 set dummy $ac_prog; ac_word=$2 9942 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 9943 $as_echo_n "checking for $ac_word... " >&6; } 9944 if ${ac_cv_path_NAWK+:} false; then : 9945 $as_echo_n "(cached) " >&6 9946 else 9947 case $NAWK in 9948 [\\/]* | ?:[\\/]*) 9949 ac_cv_path_NAWK="$NAWK" # Let the user override the test with a path. 9950 ;; 9951 *) 9952 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 9953 for as_dir in $PATH 9954 do 9955 IFS=$as_save_IFS 9956 test -z "$as_dir" && as_dir=. 9957 for ac_exec_ext in '' $ac_executable_extensions; do 9958 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 9959 ac_cv_path_NAWK="$as_dir/$ac_word$ac_exec_ext" 9960 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 9961 break 2 9962 fi 9963 done 9964 done 9965 IFS=$as_save_IFS 9966 9967 ;; 9968 esac 9969 fi 9970 NAWK=$ac_cv_path_NAWK 9971 if test -n "$NAWK"; then 9972 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $NAWK" >&5 9973 $as_echo "$NAWK" >&6; } 9974 else 9975 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 9976 $as_echo "no" >&6; } 9977 fi 9978 9979 9980 test -n "$NAWK" && break 9981 done 9982 9983 else 9984 # The variable is set, but is it from the command line or the environment? 9985 9986 # Try to remove the string !NAWK! from our list. 9987 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!NAWK!/} 9988 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 9989 # If it failed, the variable was not from the command line. Ignore it, 9990 # but warn the user (except for BASH, which is always set by the calling BASH). 9991 if test "xNAWK" != xBASH; then 9992 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of NAWK from the environment. Use command line variables instead." >&5 9993 $as_echo "$as_me: WARNING: Ignoring value of NAWK from the environment. Use command line variables instead." >&2;} 9994 fi 9995 # Try to locate tool using the code snippet 9996 for ac_prog in nawk gawk awk 9997 do 9998 # Extract the first word of "$ac_prog", so it can be a program name with args. 9999 set dummy $ac_prog; ac_word=$2 10000 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 10001 $as_echo_n "checking for $ac_word... " >&6; } 10002 if ${ac_cv_path_NAWK+:} false; then : 10003 $as_echo_n "(cached) " >&6 10004 else 10005 case $NAWK in 10006 [\\/]* | ?:[\\/]*) 10007 ac_cv_path_NAWK="$NAWK" # Let the user override the test with a path. 10008 ;; 10009 *) 10010 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 10011 for as_dir in $PATH 10012 do 10013 IFS=$as_save_IFS 10014 test -z "$as_dir" && as_dir=. 10015 for ac_exec_ext in '' $ac_executable_extensions; do 10016 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 10017 ac_cv_path_NAWK="$as_dir/$ac_word$ac_exec_ext" 10018 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 10019 break 2 10020 fi 10021 done 10022 done 10023 IFS=$as_save_IFS 10024 10025 ;; 10026 esac 10027 fi 10028 NAWK=$ac_cv_path_NAWK 10029 if test -n "$NAWK"; then 10030 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $NAWK" >&5 10031 $as_echo "$NAWK" >&6; } 10032 else 10033 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 10034 $as_echo "no" >&6; } 10035 fi 10036 10037 10038 test -n "$NAWK" && break 10039 done 10040 10041 else 10042 # If it succeeded, then it was overridden by the user. We will use it 10043 # for the tool. 10044 10045 # First remove it from the list of overridden variables, so we can test 10046 # for unknown variables in the end. 10047 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 10048 10049 # Check if we try to supply an empty value 10050 if test "x$NAWK" = x; then 10051 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool NAWK= (no value)" >&5 10052 $as_echo "$as_me: Setting user supplied tool NAWK= (no value)" >&6;} 10053 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for NAWK" >&5 10054 $as_echo_n "checking for NAWK... " >&6; } 10055 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 10056 $as_echo "disabled" >&6; } 10057 else 10058 # Check if the provided tool contains a complete path. 10059 tool_specified="$NAWK" 10060 tool_basename="${tool_specified##*/}" 10061 if test "x$tool_basename" = "x$tool_specified"; then 10062 # A command without a complete path is provided, search $PATH. 10063 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool NAWK=$tool_basename" >&5 10064 $as_echo "$as_me: Will search for user supplied tool NAWK=$tool_basename" >&6;} 10065 # Extract the first word of "$tool_basename", so it can be a program name with args. 10066 set dummy $tool_basename; ac_word=$2 10067 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 10068 $as_echo_n "checking for $ac_word... " >&6; } 10069 if ${ac_cv_path_NAWK+:} false; then : 10070 $as_echo_n "(cached) " >&6 10071 else 10072 case $NAWK in 10073 [\\/]* | ?:[\\/]*) 10074 ac_cv_path_NAWK="$NAWK" # Let the user override the test with a path. 10075 ;; 10076 *) 10077 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 10078 for as_dir in $PATH 10079 do 10080 IFS=$as_save_IFS 10081 test -z "$as_dir" && as_dir=. 10082 for ac_exec_ext in '' $ac_executable_extensions; do 10083 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 10084 ac_cv_path_NAWK="$as_dir/$ac_word$ac_exec_ext" 10085 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 10086 break 2 10087 fi 10088 done 10089 done 10090 IFS=$as_save_IFS 10091 10092 ;; 10093 esac 10094 fi 10095 NAWK=$ac_cv_path_NAWK 10096 if test -n "$NAWK"; then 10097 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $NAWK" >&5 10098 $as_echo "$NAWK" >&6; } 10099 else 10100 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 10101 $as_echo "no" >&6; } 10102 fi 10103 10104 10105 if test "x$NAWK" = x; then 10106 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 10107 fi 10108 else 10109 # Otherwise we believe it is a complete path. Use it as it is. 10110 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool NAWK=$tool_specified" >&5 10111 $as_echo "$as_me: Will use user supplied tool NAWK=$tool_specified" >&6;} 10112 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for NAWK" >&5 10113 $as_echo_n "checking for NAWK... " >&6; } 10114 if test ! -x "$tool_specified"; then 10115 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 10116 $as_echo "not found" >&6; } 10117 as_fn_error $? "User supplied tool NAWK=$tool_specified does not exist or is not executable" "$LINENO" 5 10118 fi 10119 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 10120 $as_echo "$tool_specified" >&6; } 10121 fi 10122 fi 10123 fi 10124 10125 fi 10126 10127 10128 10129 if test "x$NAWK" = x; then 10130 as_fn_error $? "Could not find required tool for NAWK" "$LINENO" 5 10131 fi 10132 10133 10134 10135 10136 10137 # Publish this variable in the help. 10138 10139 10140 if [ -z "${PRINTF+x}" ]; then 10141 # The variable is not set by user, try to locate tool using the code snippet 10142 for ac_prog in printf 10143 do 10144 # Extract the first word of "$ac_prog", so it can be a program name with args. 10145 set dummy $ac_prog; ac_word=$2 10146 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 10147 $as_echo_n "checking for $ac_word... " >&6; } 10148 if ${ac_cv_path_PRINTF+:} false; then : 10149 $as_echo_n "(cached) " >&6 10150 else 10151 case $PRINTF in 10152 [\\/]* | ?:[\\/]*) 10153 ac_cv_path_PRINTF="$PRINTF" # Let the user override the test with a path. 10154 ;; 10155 *) 10156 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 10157 for as_dir in $PATH 10158 do 10159 IFS=$as_save_IFS 10160 test -z "$as_dir" && as_dir=. 10161 for ac_exec_ext in '' $ac_executable_extensions; do 10162 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 10163 ac_cv_path_PRINTF="$as_dir/$ac_word$ac_exec_ext" 10164 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 10165 break 2 10166 fi 10167 done 10168 done 10169 IFS=$as_save_IFS 10170 10171 ;; 10172 esac 10173 fi 10174 PRINTF=$ac_cv_path_PRINTF 10175 if test -n "$PRINTF"; then 10176 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $PRINTF" >&5 10177 $as_echo "$PRINTF" >&6; } 10178 else 10179 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 10180 $as_echo "no" >&6; } 10181 fi 10182 10183 10184 test -n "$PRINTF" && break 10185 done 10186 10187 else 10188 # The variable is set, but is it from the command line or the environment? 10189 10190 # Try to remove the string !PRINTF! from our list. 10191 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!PRINTF!/} 10192 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 10193 # If it failed, the variable was not from the command line. Ignore it, 10194 # but warn the user (except for BASH, which is always set by the calling BASH). 10195 if test "xPRINTF" != xBASH; then 10196 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of PRINTF from the environment. Use command line variables instead." >&5 10197 $as_echo "$as_me: WARNING: Ignoring value of PRINTF from the environment. Use command line variables instead." >&2;} 10198 fi 10199 # Try to locate tool using the code snippet 10200 for ac_prog in printf 10201 do 10202 # Extract the first word of "$ac_prog", so it can be a program name with args. 10203 set dummy $ac_prog; ac_word=$2 10204 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 10205 $as_echo_n "checking for $ac_word... " >&6; } 10206 if ${ac_cv_path_PRINTF+:} false; then : 10207 $as_echo_n "(cached) " >&6 10208 else 10209 case $PRINTF in 10210 [\\/]* | ?:[\\/]*) 10211 ac_cv_path_PRINTF="$PRINTF" # Let the user override the test with a path. 10212 ;; 10213 *) 10214 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 10215 for as_dir in $PATH 10216 do 10217 IFS=$as_save_IFS 10218 test -z "$as_dir" && as_dir=. 10219 for ac_exec_ext in '' $ac_executable_extensions; do 10220 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 10221 ac_cv_path_PRINTF="$as_dir/$ac_word$ac_exec_ext" 10222 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 10223 break 2 10224 fi 10225 done 10226 done 10227 IFS=$as_save_IFS 10228 10229 ;; 10230 esac 10231 fi 10232 PRINTF=$ac_cv_path_PRINTF 10233 if test -n "$PRINTF"; then 10234 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $PRINTF" >&5 10235 $as_echo "$PRINTF" >&6; } 10236 else 10237 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 10238 $as_echo "no" >&6; } 10239 fi 10240 10241 10242 test -n "$PRINTF" && break 10243 done 10244 10245 else 10246 # If it succeeded, then it was overridden by the user. We will use it 10247 # for the tool. 10248 10249 # First remove it from the list of overridden variables, so we can test 10250 # for unknown variables in the end. 10251 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 10252 10253 # Check if we try to supply an empty value 10254 if test "x$PRINTF" = x; then 10255 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool PRINTF= (no value)" >&5 10256 $as_echo "$as_me: Setting user supplied tool PRINTF= (no value)" >&6;} 10257 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for PRINTF" >&5 10258 $as_echo_n "checking for PRINTF... " >&6; } 10259 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 10260 $as_echo "disabled" >&6; } 10261 else 10262 # Check if the provided tool contains a complete path. 10263 tool_specified="$PRINTF" 10264 tool_basename="${tool_specified##*/}" 10265 if test "x$tool_basename" = "x$tool_specified"; then 10266 # A command without a complete path is provided, search $PATH. 10267 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool PRINTF=$tool_basename" >&5 10268 $as_echo "$as_me: Will search for user supplied tool PRINTF=$tool_basename" >&6;} 10269 # Extract the first word of "$tool_basename", so it can be a program name with args. 10270 set dummy $tool_basename; ac_word=$2 10271 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 10272 $as_echo_n "checking for $ac_word... " >&6; } 10273 if ${ac_cv_path_PRINTF+:} false; then : 10274 $as_echo_n "(cached) " >&6 10275 else 10276 case $PRINTF in 10277 [\\/]* | ?:[\\/]*) 10278 ac_cv_path_PRINTF="$PRINTF" # Let the user override the test with a path. 10279 ;; 10280 *) 10281 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 10282 for as_dir in $PATH 10283 do 10284 IFS=$as_save_IFS 10285 test -z "$as_dir" && as_dir=. 10286 for ac_exec_ext in '' $ac_executable_extensions; do 10287 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 10288 ac_cv_path_PRINTF="$as_dir/$ac_word$ac_exec_ext" 10289 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 10290 break 2 10291 fi 10292 done 10293 done 10294 IFS=$as_save_IFS 10295 10296 ;; 10297 esac 10298 fi 10299 PRINTF=$ac_cv_path_PRINTF 10300 if test -n "$PRINTF"; then 10301 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $PRINTF" >&5 10302 $as_echo "$PRINTF" >&6; } 10303 else 10304 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 10305 $as_echo "no" >&6; } 10306 fi 10307 10308 10309 if test "x$PRINTF" = x; then 10310 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 10311 fi 10312 else 10313 # Otherwise we believe it is a complete path. Use it as it is. 10314 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool PRINTF=$tool_specified" >&5 10315 $as_echo "$as_me: Will use user supplied tool PRINTF=$tool_specified" >&6;} 10316 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for PRINTF" >&5 10317 $as_echo_n "checking for PRINTF... " >&6; } 10318 if test ! -x "$tool_specified"; then 10319 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 10320 $as_echo "not found" >&6; } 10321 as_fn_error $? "User supplied tool PRINTF=$tool_specified does not exist or is not executable" "$LINENO" 5 10322 fi 10323 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 10324 $as_echo "$tool_specified" >&6; } 10325 fi 10326 fi 10327 fi 10328 10329 fi 10330 10331 10332 10333 if test "x$PRINTF" = x; then 10334 as_fn_error $? "Could not find required tool for PRINTF" "$LINENO" 5 10335 fi 10336 10337 10338 10339 10340 10341 # Publish this variable in the help. 10342 10343 10344 if [ -z "${RM+x}" ]; then 10345 # The variable is not set by user, try to locate tool using the code snippet 10346 for ac_prog in rm 10347 do 10348 # Extract the first word of "$ac_prog", so it can be a program name with args. 10349 set dummy $ac_prog; ac_word=$2 10350 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 10351 $as_echo_n "checking for $ac_word... " >&6; } 10352 if ${ac_cv_path_RM+:} false; then : 10353 $as_echo_n "(cached) " >&6 10354 else 10355 case $RM in 10356 [\\/]* | ?:[\\/]*) 10357 ac_cv_path_RM="$RM" # Let the user override the test with a path. 10358 ;; 10359 *) 10360 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 10361 for as_dir in $PATH 10362 do 10363 IFS=$as_save_IFS 10364 test -z "$as_dir" && as_dir=. 10365 for ac_exec_ext in '' $ac_executable_extensions; do 10366 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 10367 ac_cv_path_RM="$as_dir/$ac_word$ac_exec_ext" 10368 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 10369 break 2 10370 fi 10371 done 10372 done 10373 IFS=$as_save_IFS 10374 10375 ;; 10376 esac 10377 fi 10378 RM=$ac_cv_path_RM 10379 if test -n "$RM"; then 10380 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $RM" >&5 10381 $as_echo "$RM" >&6; } 10382 else 10383 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 10384 $as_echo "no" >&6; } 10385 fi 10386 10387 10388 test -n "$RM" && break 10389 done 10390 10391 else 10392 # The variable is set, but is it from the command line or the environment? 10393 10394 # Try to remove the string !RM! from our list. 10395 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!RM!/} 10396 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 10397 # If it failed, the variable was not from the command line. Ignore it, 10398 # but warn the user (except for BASH, which is always set by the calling BASH). 10399 if test "xRM" != xBASH; then 10400 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of RM from the environment. Use command line variables instead." >&5 10401 $as_echo "$as_me: WARNING: Ignoring value of RM from the environment. Use command line variables instead." >&2;} 10402 fi 10403 # Try to locate tool using the code snippet 10404 for ac_prog in rm 10405 do 10406 # Extract the first word of "$ac_prog", so it can be a program name with args. 10407 set dummy $ac_prog; ac_word=$2 10408 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 10409 $as_echo_n "checking for $ac_word... " >&6; } 10410 if ${ac_cv_path_RM+:} false; then : 10411 $as_echo_n "(cached) " >&6 10412 else 10413 case $RM in 10414 [\\/]* | ?:[\\/]*) 10415 ac_cv_path_RM="$RM" # Let the user override the test with a path. 10416 ;; 10417 *) 10418 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 10419 for as_dir in $PATH 10420 do 10421 IFS=$as_save_IFS 10422 test -z "$as_dir" && as_dir=. 10423 for ac_exec_ext in '' $ac_executable_extensions; do 10424 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 10425 ac_cv_path_RM="$as_dir/$ac_word$ac_exec_ext" 10426 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 10427 break 2 10428 fi 10429 done 10430 done 10431 IFS=$as_save_IFS 10432 10433 ;; 10434 esac 10435 fi 10436 RM=$ac_cv_path_RM 10437 if test -n "$RM"; then 10438 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $RM" >&5 10439 $as_echo "$RM" >&6; } 10440 else 10441 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 10442 $as_echo "no" >&6; } 10443 fi 10444 10445 10446 test -n "$RM" && break 10447 done 10448 10449 else 10450 # If it succeeded, then it was overridden by the user. We will use it 10451 # for the tool. 10452 10453 # First remove it from the list of overridden variables, so we can test 10454 # for unknown variables in the end. 10455 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 10456 10457 # Check if we try to supply an empty value 10458 if test "x$RM" = x; then 10459 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool RM= (no value)" >&5 10460 $as_echo "$as_me: Setting user supplied tool RM= (no value)" >&6;} 10461 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for RM" >&5 10462 $as_echo_n "checking for RM... " >&6; } 10463 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 10464 $as_echo "disabled" >&6; } 10465 else 10466 # Check if the provided tool contains a complete path. 10467 tool_specified="$RM" 10468 tool_basename="${tool_specified##*/}" 10469 if test "x$tool_basename" = "x$tool_specified"; then 10470 # A command without a complete path is provided, search $PATH. 10471 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool RM=$tool_basename" >&5 10472 $as_echo "$as_me: Will search for user supplied tool RM=$tool_basename" >&6;} 10473 # Extract the first word of "$tool_basename", so it can be a program name with args. 10474 set dummy $tool_basename; ac_word=$2 10475 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 10476 $as_echo_n "checking for $ac_word... " >&6; } 10477 if ${ac_cv_path_RM+:} false; then : 10478 $as_echo_n "(cached) " >&6 10479 else 10480 case $RM in 10481 [\\/]* | ?:[\\/]*) 10482 ac_cv_path_RM="$RM" # Let the user override the test with a path. 10483 ;; 10484 *) 10485 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 10486 for as_dir in $PATH 10487 do 10488 IFS=$as_save_IFS 10489 test -z "$as_dir" && as_dir=. 10490 for ac_exec_ext in '' $ac_executable_extensions; do 10491 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 10492 ac_cv_path_RM="$as_dir/$ac_word$ac_exec_ext" 10493 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 10494 break 2 10495 fi 10496 done 10497 done 10498 IFS=$as_save_IFS 10499 10500 ;; 10501 esac 10502 fi 10503 RM=$ac_cv_path_RM 10504 if test -n "$RM"; then 10505 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $RM" >&5 10506 $as_echo "$RM" >&6; } 10507 else 10508 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 10509 $as_echo "no" >&6; } 10510 fi 10511 10512 10513 if test "x$RM" = x; then 10514 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 10515 fi 10516 else 10517 # Otherwise we believe it is a complete path. Use it as it is. 10518 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool RM=$tool_specified" >&5 10519 $as_echo "$as_me: Will use user supplied tool RM=$tool_specified" >&6;} 10520 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for RM" >&5 10521 $as_echo_n "checking for RM... " >&6; } 10522 if test ! -x "$tool_specified"; then 10523 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 10524 $as_echo "not found" >&6; } 10525 as_fn_error $? "User supplied tool RM=$tool_specified does not exist or is not executable" "$LINENO" 5 10526 fi 10527 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 10528 $as_echo "$tool_specified" >&6; } 10529 fi 10530 fi 10531 fi 10532 10533 fi 10534 10535 10536 10537 if test "x$RM" = x; then 10538 as_fn_error $? "Could not find required tool for RM" "$LINENO" 5 10539 fi 10540 10541 10542 10543 10544 10545 # Publish this variable in the help. 10546 10547 10548 if [ -z "${RMDIR+x}" ]; then 10549 # The variable is not set by user, try to locate tool using the code snippet 10550 for ac_prog in rmdir 10551 do 10552 # Extract the first word of "$ac_prog", so it can be a program name with args. 10553 set dummy $ac_prog; ac_word=$2 10554 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 10555 $as_echo_n "checking for $ac_word... " >&6; } 10556 if ${ac_cv_path_RMDIR+:} false; then : 10557 $as_echo_n "(cached) " >&6 10558 else 10559 case $RMDIR in 10560 [\\/]* | ?:[\\/]*) 10561 ac_cv_path_RMDIR="$RMDIR" # Let the user override the test with a path. 10562 ;; 10563 *) 10564 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 10565 for as_dir in $PATH 10566 do 10567 IFS=$as_save_IFS 10568 test -z "$as_dir" && as_dir=. 10569 for ac_exec_ext in '' $ac_executable_extensions; do 10570 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 10571 ac_cv_path_RMDIR="$as_dir/$ac_word$ac_exec_ext" 10572 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 10573 break 2 10574 fi 10575 done 10576 done 10577 IFS=$as_save_IFS 10578 10579 ;; 10580 esac 10581 fi 10582 RMDIR=$ac_cv_path_RMDIR 10583 if test -n "$RMDIR"; then 10584 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $RMDIR" >&5 10585 $as_echo "$RMDIR" >&6; } 10586 else 10587 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 10588 $as_echo "no" >&6; } 10589 fi 10590 10591 10592 test -n "$RMDIR" && break 10593 done 10594 10595 else 10596 # The variable is set, but is it from the command line or the environment? 10597 10598 # Try to remove the string !RMDIR! from our list. 10599 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!RMDIR!/} 10600 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 10601 # If it failed, the variable was not from the command line. Ignore it, 10602 # but warn the user (except for BASH, which is always set by the calling BASH). 10603 if test "xRMDIR" != xBASH; then 10604 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of RMDIR from the environment. Use command line variables instead." >&5 10605 $as_echo "$as_me: WARNING: Ignoring value of RMDIR from the environment. Use command line variables instead." >&2;} 10606 fi 10607 # Try to locate tool using the code snippet 10608 for ac_prog in rmdir 10609 do 10610 # Extract the first word of "$ac_prog", so it can be a program name with args. 10611 set dummy $ac_prog; ac_word=$2 10612 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 10613 $as_echo_n "checking for $ac_word... " >&6; } 10614 if ${ac_cv_path_RMDIR+:} false; then : 10615 $as_echo_n "(cached) " >&6 10616 else 10617 case $RMDIR in 10618 [\\/]* | ?:[\\/]*) 10619 ac_cv_path_RMDIR="$RMDIR" # Let the user override the test with a path. 10620 ;; 10621 *) 10622 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 10623 for as_dir in $PATH 10624 do 10625 IFS=$as_save_IFS 10626 test -z "$as_dir" && as_dir=. 10627 for ac_exec_ext in '' $ac_executable_extensions; do 10628 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 10629 ac_cv_path_RMDIR="$as_dir/$ac_word$ac_exec_ext" 10630 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 10631 break 2 10632 fi 10633 done 10634 done 10635 IFS=$as_save_IFS 10636 10637 ;; 10638 esac 10639 fi 10640 RMDIR=$ac_cv_path_RMDIR 10641 if test -n "$RMDIR"; then 10642 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $RMDIR" >&5 10643 $as_echo "$RMDIR" >&6; } 10644 else 10645 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 10646 $as_echo "no" >&6; } 10647 fi 10648 10649 10650 test -n "$RMDIR" && break 10651 done 10652 10653 else 10654 # If it succeeded, then it was overridden by the user. We will use it 10655 # for the tool. 10656 10657 # First remove it from the list of overridden variables, so we can test 10658 # for unknown variables in the end. 10659 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 10660 10661 # Check if we try to supply an empty value 10662 if test "x$RMDIR" = x; then 10663 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool RMDIR= (no value)" >&5 10664 $as_echo "$as_me: Setting user supplied tool RMDIR= (no value)" >&6;} 10665 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for RMDIR" >&5 10666 $as_echo_n "checking for RMDIR... " >&6; } 10667 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 10668 $as_echo "disabled" >&6; } 10669 else 10670 # Check if the provided tool contains a complete path. 10671 tool_specified="$RMDIR" 10672 tool_basename="${tool_specified##*/}" 10673 if test "x$tool_basename" = "x$tool_specified"; then 10674 # A command without a complete path is provided, search $PATH. 10675 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool RMDIR=$tool_basename" >&5 10676 $as_echo "$as_me: Will search for user supplied tool RMDIR=$tool_basename" >&6;} 10677 # Extract the first word of "$tool_basename", so it can be a program name with args. 10678 set dummy $tool_basename; ac_word=$2 10679 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 10680 $as_echo_n "checking for $ac_word... " >&6; } 10681 if ${ac_cv_path_RMDIR+:} false; then : 10682 $as_echo_n "(cached) " >&6 10683 else 10684 case $RMDIR in 10685 [\\/]* | ?:[\\/]*) 10686 ac_cv_path_RMDIR="$RMDIR" # Let the user override the test with a path. 10687 ;; 10688 *) 10689 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 10690 for as_dir in $PATH 10691 do 10692 IFS=$as_save_IFS 10693 test -z "$as_dir" && as_dir=. 10694 for ac_exec_ext in '' $ac_executable_extensions; do 10695 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 10696 ac_cv_path_RMDIR="$as_dir/$ac_word$ac_exec_ext" 10697 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 10698 break 2 10699 fi 10700 done 10701 done 10702 IFS=$as_save_IFS 10703 10704 ;; 10705 esac 10706 fi 10707 RMDIR=$ac_cv_path_RMDIR 10708 if test -n "$RMDIR"; then 10709 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $RMDIR" >&5 10710 $as_echo "$RMDIR" >&6; } 10711 else 10712 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 10713 $as_echo "no" >&6; } 10714 fi 10715 10716 10717 if test "x$RMDIR" = x; then 10718 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 10719 fi 10720 else 10721 # Otherwise we believe it is a complete path. Use it as it is. 10722 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool RMDIR=$tool_specified" >&5 10723 $as_echo "$as_me: Will use user supplied tool RMDIR=$tool_specified" >&6;} 10724 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for RMDIR" >&5 10725 $as_echo_n "checking for RMDIR... " >&6; } 10726 if test ! -x "$tool_specified"; then 10727 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 10728 $as_echo "not found" >&6; } 10729 as_fn_error $? "User supplied tool RMDIR=$tool_specified does not exist or is not executable" "$LINENO" 5 10730 fi 10731 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 10732 $as_echo "$tool_specified" >&6; } 10733 fi 10734 fi 10735 fi 10736 10737 fi 10738 10739 10740 10741 if test "x$RMDIR" = x; then 10742 as_fn_error $? "Could not find required tool for RMDIR" "$LINENO" 5 10743 fi 10744 10745 10746 10747 10748 10749 # Publish this variable in the help. 10750 10751 10752 if [ -z "${SH+x}" ]; then 10753 # The variable is not set by user, try to locate tool using the code snippet 10754 for ac_prog in sh 10755 do 10756 # Extract the first word of "$ac_prog", so it can be a program name with args. 10757 set dummy $ac_prog; ac_word=$2 10758 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 10759 $as_echo_n "checking for $ac_word... " >&6; } 10760 if ${ac_cv_path_SH+:} false; then : 10761 $as_echo_n "(cached) " >&6 10762 else 10763 case $SH in 10764 [\\/]* | ?:[\\/]*) 10765 ac_cv_path_SH="$SH" # Let the user override the test with a path. 10766 ;; 10767 *) 10768 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 10769 for as_dir in $PATH 10770 do 10771 IFS=$as_save_IFS 10772 test -z "$as_dir" && as_dir=. 10773 for ac_exec_ext in '' $ac_executable_extensions; do 10774 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 10775 ac_cv_path_SH="$as_dir/$ac_word$ac_exec_ext" 10776 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 10777 break 2 10778 fi 10779 done 10780 done 10781 IFS=$as_save_IFS 10782 10783 ;; 10784 esac 10785 fi 10786 SH=$ac_cv_path_SH 10787 if test -n "$SH"; then 10788 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $SH" >&5 10789 $as_echo "$SH" >&6; } 10790 else 10791 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 10792 $as_echo "no" >&6; } 10793 fi 10794 10795 10796 test -n "$SH" && break 10797 done 10798 10799 else 10800 # The variable is set, but is it from the command line or the environment? 10801 10802 # Try to remove the string !SH! from our list. 10803 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!SH!/} 10804 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 10805 # If it failed, the variable was not from the command line. Ignore it, 10806 # but warn the user (except for BASH, which is always set by the calling BASH). 10807 if test "xSH" != xBASH; then 10808 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of SH from the environment. Use command line variables instead." >&5 10809 $as_echo "$as_me: WARNING: Ignoring value of SH from the environment. Use command line variables instead." >&2;} 10810 fi 10811 # Try to locate tool using the code snippet 10812 for ac_prog in sh 10813 do 10814 # Extract the first word of "$ac_prog", so it can be a program name with args. 10815 set dummy $ac_prog; ac_word=$2 10816 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 10817 $as_echo_n "checking for $ac_word... " >&6; } 10818 if ${ac_cv_path_SH+:} false; then : 10819 $as_echo_n "(cached) " >&6 10820 else 10821 case $SH in 10822 [\\/]* | ?:[\\/]*) 10823 ac_cv_path_SH="$SH" # Let the user override the test with a path. 10824 ;; 10825 *) 10826 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 10827 for as_dir in $PATH 10828 do 10829 IFS=$as_save_IFS 10830 test -z "$as_dir" && as_dir=. 10831 for ac_exec_ext in '' $ac_executable_extensions; do 10832 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 10833 ac_cv_path_SH="$as_dir/$ac_word$ac_exec_ext" 10834 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 10835 break 2 10836 fi 10837 done 10838 done 10839 IFS=$as_save_IFS 10840 10841 ;; 10842 esac 10843 fi 10844 SH=$ac_cv_path_SH 10845 if test -n "$SH"; then 10846 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $SH" >&5 10847 $as_echo "$SH" >&6; } 10848 else 10849 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 10850 $as_echo "no" >&6; } 10851 fi 10852 10853 10854 test -n "$SH" && break 10855 done 10856 10857 else 10858 # If it succeeded, then it was overridden by the user. We will use it 10859 # for the tool. 10860 10861 # First remove it from the list of overridden variables, so we can test 10862 # for unknown variables in the end. 10863 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 10864 10865 # Check if we try to supply an empty value 10866 if test "x$SH" = x; then 10867 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool SH= (no value)" >&5 10868 $as_echo "$as_me: Setting user supplied tool SH= (no value)" >&6;} 10869 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for SH" >&5 10870 $as_echo_n "checking for SH... " >&6; } 10871 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 10872 $as_echo "disabled" >&6; } 10873 else 10874 # Check if the provided tool contains a complete path. 10875 tool_specified="$SH" 10876 tool_basename="${tool_specified##*/}" 10877 if test "x$tool_basename" = "x$tool_specified"; then 10878 # A command without a complete path is provided, search $PATH. 10879 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool SH=$tool_basename" >&5 10880 $as_echo "$as_me: Will search for user supplied tool SH=$tool_basename" >&6;} 10881 # Extract the first word of "$tool_basename", so it can be a program name with args. 10882 set dummy $tool_basename; ac_word=$2 10883 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 10884 $as_echo_n "checking for $ac_word... " >&6; } 10885 if ${ac_cv_path_SH+:} false; then : 10886 $as_echo_n "(cached) " >&6 10887 else 10888 case $SH in 10889 [\\/]* | ?:[\\/]*) 10890 ac_cv_path_SH="$SH" # Let the user override the test with a path. 10891 ;; 10892 *) 10893 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 10894 for as_dir in $PATH 10895 do 10896 IFS=$as_save_IFS 10897 test -z "$as_dir" && as_dir=. 10898 for ac_exec_ext in '' $ac_executable_extensions; do 10899 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 10900 ac_cv_path_SH="$as_dir/$ac_word$ac_exec_ext" 10901 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 10902 break 2 10903 fi 10904 done 10905 done 10906 IFS=$as_save_IFS 10907 10908 ;; 10909 esac 10910 fi 10911 SH=$ac_cv_path_SH 10912 if test -n "$SH"; then 10913 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $SH" >&5 10914 $as_echo "$SH" >&6; } 10915 else 10916 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 10917 $as_echo "no" >&6; } 10918 fi 10919 10920 10921 if test "x$SH" = x; then 10922 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 10923 fi 10924 else 10925 # Otherwise we believe it is a complete path. Use it as it is. 10926 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool SH=$tool_specified" >&5 10927 $as_echo "$as_me: Will use user supplied tool SH=$tool_specified" >&6;} 10928 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for SH" >&5 10929 $as_echo_n "checking for SH... " >&6; } 10930 if test ! -x "$tool_specified"; then 10931 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 10932 $as_echo "not found" >&6; } 10933 as_fn_error $? "User supplied tool SH=$tool_specified does not exist or is not executable" "$LINENO" 5 10934 fi 10935 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 10936 $as_echo "$tool_specified" >&6; } 10937 fi 10938 fi 10939 fi 10940 10941 fi 10942 10943 10944 10945 if test "x$SH" = x; then 10946 as_fn_error $? "Could not find required tool for SH" "$LINENO" 5 10947 fi 10948 10949 10950 10951 10952 10953 # Publish this variable in the help. 10954 10955 10956 if [ -z "${SORT+x}" ]; then 10957 # The variable is not set by user, try to locate tool using the code snippet 10958 for ac_prog in sort 10959 do 10960 # Extract the first word of "$ac_prog", so it can be a program name with args. 10961 set dummy $ac_prog; ac_word=$2 10962 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 10963 $as_echo_n "checking for $ac_word... " >&6; } 10964 if ${ac_cv_path_SORT+:} false; then : 10965 $as_echo_n "(cached) " >&6 10966 else 10967 case $SORT in 10968 [\\/]* | ?:[\\/]*) 10969 ac_cv_path_SORT="$SORT" # Let the user override the test with a path. 10970 ;; 10971 *) 10972 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 10973 for as_dir in $PATH 10974 do 10975 IFS=$as_save_IFS 10976 test -z "$as_dir" && as_dir=. 10977 for ac_exec_ext in '' $ac_executable_extensions; do 10978 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 10979 ac_cv_path_SORT="$as_dir/$ac_word$ac_exec_ext" 10980 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 10981 break 2 10982 fi 10983 done 10984 done 10985 IFS=$as_save_IFS 10986 10987 ;; 10988 esac 10989 fi 10990 SORT=$ac_cv_path_SORT 10991 if test -n "$SORT"; then 10992 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $SORT" >&5 10993 $as_echo "$SORT" >&6; } 10994 else 10995 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 10996 $as_echo "no" >&6; } 10997 fi 10998 10999 11000 test -n "$SORT" && break 11001 done 11002 11003 else 11004 # The variable is set, but is it from the command line or the environment? 11005 11006 # Try to remove the string !SORT! from our list. 11007 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!SORT!/} 11008 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 11009 # If it failed, the variable was not from the command line. Ignore it, 11010 # but warn the user (except for BASH, which is always set by the calling BASH). 11011 if test "xSORT" != xBASH; then 11012 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of SORT from the environment. Use command line variables instead." >&5 11013 $as_echo "$as_me: WARNING: Ignoring value of SORT from the environment. Use command line variables instead." >&2;} 11014 fi 11015 # Try to locate tool using the code snippet 11016 for ac_prog in sort 11017 do 11018 # Extract the first word of "$ac_prog", so it can be a program name with args. 11019 set dummy $ac_prog; ac_word=$2 11020 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 11021 $as_echo_n "checking for $ac_word... " >&6; } 11022 if ${ac_cv_path_SORT+:} false; then : 11023 $as_echo_n "(cached) " >&6 11024 else 11025 case $SORT in 11026 [\\/]* | ?:[\\/]*) 11027 ac_cv_path_SORT="$SORT" # Let the user override the test with a path. 11028 ;; 11029 *) 11030 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 11031 for as_dir in $PATH 11032 do 11033 IFS=$as_save_IFS 11034 test -z "$as_dir" && as_dir=. 11035 for ac_exec_ext in '' $ac_executable_extensions; do 11036 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 11037 ac_cv_path_SORT="$as_dir/$ac_word$ac_exec_ext" 11038 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 11039 break 2 11040 fi 11041 done 11042 done 11043 IFS=$as_save_IFS 11044 11045 ;; 11046 esac 11047 fi 11048 SORT=$ac_cv_path_SORT 11049 if test -n "$SORT"; then 11050 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $SORT" >&5 11051 $as_echo "$SORT" >&6; } 11052 else 11053 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 11054 $as_echo "no" >&6; } 11055 fi 11056 11057 11058 test -n "$SORT" && break 11059 done 11060 11061 else 11062 # If it succeeded, then it was overridden by the user. We will use it 11063 # for the tool. 11064 11065 # First remove it from the list of overridden variables, so we can test 11066 # for unknown variables in the end. 11067 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 11068 11069 # Check if we try to supply an empty value 11070 if test "x$SORT" = x; then 11071 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool SORT= (no value)" >&5 11072 $as_echo "$as_me: Setting user supplied tool SORT= (no value)" >&6;} 11073 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for SORT" >&5 11074 $as_echo_n "checking for SORT... " >&6; } 11075 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 11076 $as_echo "disabled" >&6; } 11077 else 11078 # Check if the provided tool contains a complete path. 11079 tool_specified="$SORT" 11080 tool_basename="${tool_specified##*/}" 11081 if test "x$tool_basename" = "x$tool_specified"; then 11082 # A command without a complete path is provided, search $PATH. 11083 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool SORT=$tool_basename" >&5 11084 $as_echo "$as_me: Will search for user supplied tool SORT=$tool_basename" >&6;} 11085 # Extract the first word of "$tool_basename", so it can be a program name with args. 11086 set dummy $tool_basename; ac_word=$2 11087 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 11088 $as_echo_n "checking for $ac_word... " >&6; } 11089 if ${ac_cv_path_SORT+:} false; then : 11090 $as_echo_n "(cached) " >&6 11091 else 11092 case $SORT in 11093 [\\/]* | ?:[\\/]*) 11094 ac_cv_path_SORT="$SORT" # Let the user override the test with a path. 11095 ;; 11096 *) 11097 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 11098 for as_dir in $PATH 11099 do 11100 IFS=$as_save_IFS 11101 test -z "$as_dir" && as_dir=. 11102 for ac_exec_ext in '' $ac_executable_extensions; do 11103 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 11104 ac_cv_path_SORT="$as_dir/$ac_word$ac_exec_ext" 11105 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 11106 break 2 11107 fi 11108 done 11109 done 11110 IFS=$as_save_IFS 11111 11112 ;; 11113 esac 11114 fi 11115 SORT=$ac_cv_path_SORT 11116 if test -n "$SORT"; then 11117 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $SORT" >&5 11118 $as_echo "$SORT" >&6; } 11119 else 11120 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 11121 $as_echo "no" >&6; } 11122 fi 11123 11124 11125 if test "x$SORT" = x; then 11126 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 11127 fi 11128 else 11129 # Otherwise we believe it is a complete path. Use it as it is. 11130 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool SORT=$tool_specified" >&5 11131 $as_echo "$as_me: Will use user supplied tool SORT=$tool_specified" >&6;} 11132 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for SORT" >&5 11133 $as_echo_n "checking for SORT... " >&6; } 11134 if test ! -x "$tool_specified"; then 11135 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 11136 $as_echo "not found" >&6; } 11137 as_fn_error $? "User supplied tool SORT=$tool_specified does not exist or is not executable" "$LINENO" 5 11138 fi 11139 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 11140 $as_echo "$tool_specified" >&6; } 11141 fi 11142 fi 11143 fi 11144 11145 fi 11146 11147 11148 11149 if test "x$SORT" = x; then 11150 as_fn_error $? "Could not find required tool for SORT" "$LINENO" 5 11151 fi 11152 11153 11154 11155 11156 11157 # Publish this variable in the help. 11158 11159 11160 if [ -z "${TAIL+x}" ]; then 11161 # The variable is not set by user, try to locate tool using the code snippet 11162 for ac_prog in tail 11163 do 11164 # Extract the first word of "$ac_prog", so it can be a program name with args. 11165 set dummy $ac_prog; ac_word=$2 11166 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 11167 $as_echo_n "checking for $ac_word... " >&6; } 11168 if ${ac_cv_path_TAIL+:} false; then : 11169 $as_echo_n "(cached) " >&6 11170 else 11171 case $TAIL in 11172 [\\/]* | ?:[\\/]*) 11173 ac_cv_path_TAIL="$TAIL" # Let the user override the test with a path. 11174 ;; 11175 *) 11176 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 11177 for as_dir in $PATH 11178 do 11179 IFS=$as_save_IFS 11180 test -z "$as_dir" && as_dir=. 11181 for ac_exec_ext in '' $ac_executable_extensions; do 11182 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 11183 ac_cv_path_TAIL="$as_dir/$ac_word$ac_exec_ext" 11184 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 11185 break 2 11186 fi 11187 done 11188 done 11189 IFS=$as_save_IFS 11190 11191 ;; 11192 esac 11193 fi 11194 TAIL=$ac_cv_path_TAIL 11195 if test -n "$TAIL"; then 11196 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $TAIL" >&5 11197 $as_echo "$TAIL" >&6; } 11198 else 11199 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 11200 $as_echo "no" >&6; } 11201 fi 11202 11203 11204 test -n "$TAIL" && break 11205 done 11206 11207 else 11208 # The variable is set, but is it from the command line or the environment? 11209 11210 # Try to remove the string !TAIL! from our list. 11211 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!TAIL!/} 11212 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 11213 # If it failed, the variable was not from the command line. Ignore it, 11214 # but warn the user (except for BASH, which is always set by the calling BASH). 11215 if test "xTAIL" != xBASH; then 11216 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of TAIL from the environment. Use command line variables instead." >&5 11217 $as_echo "$as_me: WARNING: Ignoring value of TAIL from the environment. Use command line variables instead." >&2;} 11218 fi 11219 # Try to locate tool using the code snippet 11220 for ac_prog in tail 11221 do 11222 # Extract the first word of "$ac_prog", so it can be a program name with args. 11223 set dummy $ac_prog; ac_word=$2 11224 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 11225 $as_echo_n "checking for $ac_word... " >&6; } 11226 if ${ac_cv_path_TAIL+:} false; then : 11227 $as_echo_n "(cached) " >&6 11228 else 11229 case $TAIL in 11230 [\\/]* | ?:[\\/]*) 11231 ac_cv_path_TAIL="$TAIL" # Let the user override the test with a path. 11232 ;; 11233 *) 11234 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 11235 for as_dir in $PATH 11236 do 11237 IFS=$as_save_IFS 11238 test -z "$as_dir" && as_dir=. 11239 for ac_exec_ext in '' $ac_executable_extensions; do 11240 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 11241 ac_cv_path_TAIL="$as_dir/$ac_word$ac_exec_ext" 11242 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 11243 break 2 11244 fi 11245 done 11246 done 11247 IFS=$as_save_IFS 11248 11249 ;; 11250 esac 11251 fi 11252 TAIL=$ac_cv_path_TAIL 11253 if test -n "$TAIL"; then 11254 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $TAIL" >&5 11255 $as_echo "$TAIL" >&6; } 11256 else 11257 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 11258 $as_echo "no" >&6; } 11259 fi 11260 11261 11262 test -n "$TAIL" && break 11263 done 11264 11265 else 11266 # If it succeeded, then it was overridden by the user. We will use it 11267 # for the tool. 11268 11269 # First remove it from the list of overridden variables, so we can test 11270 # for unknown variables in the end. 11271 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 11272 11273 # Check if we try to supply an empty value 11274 if test "x$TAIL" = x; then 11275 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool TAIL= (no value)" >&5 11276 $as_echo "$as_me: Setting user supplied tool TAIL= (no value)" >&6;} 11277 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for TAIL" >&5 11278 $as_echo_n "checking for TAIL... " >&6; } 11279 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 11280 $as_echo "disabled" >&6; } 11281 else 11282 # Check if the provided tool contains a complete path. 11283 tool_specified="$TAIL" 11284 tool_basename="${tool_specified##*/}" 11285 if test "x$tool_basename" = "x$tool_specified"; then 11286 # A command without a complete path is provided, search $PATH. 11287 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool TAIL=$tool_basename" >&5 11288 $as_echo "$as_me: Will search for user supplied tool TAIL=$tool_basename" >&6;} 11289 # Extract the first word of "$tool_basename", so it can be a program name with args. 11290 set dummy $tool_basename; ac_word=$2 11291 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 11292 $as_echo_n "checking for $ac_word... " >&6; } 11293 if ${ac_cv_path_TAIL+:} false; then : 11294 $as_echo_n "(cached) " >&6 11295 else 11296 case $TAIL in 11297 [\\/]* | ?:[\\/]*) 11298 ac_cv_path_TAIL="$TAIL" # Let the user override the test with a path. 11299 ;; 11300 *) 11301 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 11302 for as_dir in $PATH 11303 do 11304 IFS=$as_save_IFS 11305 test -z "$as_dir" && as_dir=. 11306 for ac_exec_ext in '' $ac_executable_extensions; do 11307 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 11308 ac_cv_path_TAIL="$as_dir/$ac_word$ac_exec_ext" 11309 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 11310 break 2 11311 fi 11312 done 11313 done 11314 IFS=$as_save_IFS 11315 11316 ;; 11317 esac 11318 fi 11319 TAIL=$ac_cv_path_TAIL 11320 if test -n "$TAIL"; then 11321 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $TAIL" >&5 11322 $as_echo "$TAIL" >&6; } 11323 else 11324 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 11325 $as_echo "no" >&6; } 11326 fi 11327 11328 11329 if test "x$TAIL" = x; then 11330 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 11331 fi 11332 else 11333 # Otherwise we believe it is a complete path. Use it as it is. 11334 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool TAIL=$tool_specified" >&5 11335 $as_echo "$as_me: Will use user supplied tool TAIL=$tool_specified" >&6;} 11336 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for TAIL" >&5 11337 $as_echo_n "checking for TAIL... " >&6; } 11338 if test ! -x "$tool_specified"; then 11339 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 11340 $as_echo "not found" >&6; } 11341 as_fn_error $? "User supplied tool TAIL=$tool_specified does not exist or is not executable" "$LINENO" 5 11342 fi 11343 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 11344 $as_echo "$tool_specified" >&6; } 11345 fi 11346 fi 11347 fi 11348 11349 fi 11350 11351 11352 11353 if test "x$TAIL" = x; then 11354 as_fn_error $? "Could not find required tool for TAIL" "$LINENO" 5 11355 fi 11356 11357 11358 11359 11360 11361 # Publish this variable in the help. 11362 11363 11364 if [ -z "${TAR+x}" ]; then 11365 # The variable is not set by user, try to locate tool using the code snippet 11366 for ac_prog in gtar tar 11367 do 11368 # Extract the first word of "$ac_prog", so it can be a program name with args. 11369 set dummy $ac_prog; ac_word=$2 11370 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 11371 $as_echo_n "checking for $ac_word... " >&6; } 11372 if ${ac_cv_path_TAR+:} false; then : 11373 $as_echo_n "(cached) " >&6 11374 else 11375 case $TAR in 11376 [\\/]* | ?:[\\/]*) 11377 ac_cv_path_TAR="$TAR" # Let the user override the test with a path. 11378 ;; 11379 *) 11380 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 11381 for as_dir in $PATH 11382 do 11383 IFS=$as_save_IFS 11384 test -z "$as_dir" && as_dir=. 11385 for ac_exec_ext in '' $ac_executable_extensions; do 11386 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 11387 ac_cv_path_TAR="$as_dir/$ac_word$ac_exec_ext" 11388 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 11389 break 2 11390 fi 11391 done 11392 done 11393 IFS=$as_save_IFS 11394 11395 ;; 11396 esac 11397 fi 11398 TAR=$ac_cv_path_TAR 11399 if test -n "$TAR"; then 11400 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $TAR" >&5 11401 $as_echo "$TAR" >&6; } 11402 else 11403 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 11404 $as_echo "no" >&6; } 11405 fi 11406 11407 11408 test -n "$TAR" && break 11409 done 11410 11411 else 11412 # The variable is set, but is it from the command line or the environment? 11413 11414 # Try to remove the string !TAR! from our list. 11415 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!TAR!/} 11416 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 11417 # If it failed, the variable was not from the command line. Ignore it, 11418 # but warn the user (except for BASH, which is always set by the calling BASH). 11419 if test "xTAR" != xBASH; then 11420 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of TAR from the environment. Use command line variables instead." >&5 11421 $as_echo "$as_me: WARNING: Ignoring value of TAR from the environment. Use command line variables instead." >&2;} 11422 fi 11423 # Try to locate tool using the code snippet 11424 for ac_prog in gtar tar 11425 do 11426 # Extract the first word of "$ac_prog", so it can be a program name with args. 11427 set dummy $ac_prog; ac_word=$2 11428 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 11429 $as_echo_n "checking for $ac_word... " >&6; } 11430 if ${ac_cv_path_TAR+:} false; then : 11431 $as_echo_n "(cached) " >&6 11432 else 11433 case $TAR in 11434 [\\/]* | ?:[\\/]*) 11435 ac_cv_path_TAR="$TAR" # Let the user override the test with a path. 11436 ;; 11437 *) 11438 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 11439 for as_dir in $PATH 11440 do 11441 IFS=$as_save_IFS 11442 test -z "$as_dir" && as_dir=. 11443 for ac_exec_ext in '' $ac_executable_extensions; do 11444 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 11445 ac_cv_path_TAR="$as_dir/$ac_word$ac_exec_ext" 11446 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 11447 break 2 11448 fi 11449 done 11450 done 11451 IFS=$as_save_IFS 11452 11453 ;; 11454 esac 11455 fi 11456 TAR=$ac_cv_path_TAR 11457 if test -n "$TAR"; then 11458 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $TAR" >&5 11459 $as_echo "$TAR" >&6; } 11460 else 11461 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 11462 $as_echo "no" >&6; } 11463 fi 11464 11465 11466 test -n "$TAR" && break 11467 done 11468 11469 else 11470 # If it succeeded, then it was overridden by the user. We will use it 11471 # for the tool. 11472 11473 # First remove it from the list of overridden variables, so we can test 11474 # for unknown variables in the end. 11475 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 11476 11477 # Check if we try to supply an empty value 11478 if test "x$TAR" = x; then 11479 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool TAR= (no value)" >&5 11480 $as_echo "$as_me: Setting user supplied tool TAR= (no value)" >&6;} 11481 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for TAR" >&5 11482 $as_echo_n "checking for TAR... " >&6; } 11483 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 11484 $as_echo "disabled" >&6; } 11485 else 11486 # Check if the provided tool contains a complete path. 11487 tool_specified="$TAR" 11488 tool_basename="${tool_specified##*/}" 11489 if test "x$tool_basename" = "x$tool_specified"; then 11490 # A command without a complete path is provided, search $PATH. 11491 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool TAR=$tool_basename" >&5 11492 $as_echo "$as_me: Will search for user supplied tool TAR=$tool_basename" >&6;} 11493 # Extract the first word of "$tool_basename", so it can be a program name with args. 11494 set dummy $tool_basename; ac_word=$2 11495 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 11496 $as_echo_n "checking for $ac_word... " >&6; } 11497 if ${ac_cv_path_TAR+:} false; then : 11498 $as_echo_n "(cached) " >&6 11499 else 11500 case $TAR in 11501 [\\/]* | ?:[\\/]*) 11502 ac_cv_path_TAR="$TAR" # Let the user override the test with a path. 11503 ;; 11504 *) 11505 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 11506 for as_dir in $PATH 11507 do 11508 IFS=$as_save_IFS 11509 test -z "$as_dir" && as_dir=. 11510 for ac_exec_ext in '' $ac_executable_extensions; do 11511 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 11512 ac_cv_path_TAR="$as_dir/$ac_word$ac_exec_ext" 11513 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 11514 break 2 11515 fi 11516 done 11517 done 11518 IFS=$as_save_IFS 11519 11520 ;; 11521 esac 11522 fi 11523 TAR=$ac_cv_path_TAR 11524 if test -n "$TAR"; then 11525 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $TAR" >&5 11526 $as_echo "$TAR" >&6; } 11527 else 11528 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 11529 $as_echo "no" >&6; } 11530 fi 11531 11532 11533 if test "x$TAR" = x; then 11534 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 11535 fi 11536 else 11537 # Otherwise we believe it is a complete path. Use it as it is. 11538 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool TAR=$tool_specified" >&5 11539 $as_echo "$as_me: Will use user supplied tool TAR=$tool_specified" >&6;} 11540 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for TAR" >&5 11541 $as_echo_n "checking for TAR... " >&6; } 11542 if test ! -x "$tool_specified"; then 11543 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 11544 $as_echo "not found" >&6; } 11545 as_fn_error $? "User supplied tool TAR=$tool_specified does not exist or is not executable" "$LINENO" 5 11546 fi 11547 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 11548 $as_echo "$tool_specified" >&6; } 11549 fi 11550 fi 11551 fi 11552 11553 fi 11554 11555 11556 11557 if test "x$TAR" = x; then 11558 as_fn_error $? "Could not find required tool for TAR" "$LINENO" 5 11559 fi 11560 11561 11562 11563 11564 11565 # Publish this variable in the help. 11566 11567 11568 if [ -z "${TEE+x}" ]; then 11569 # The variable is not set by user, try to locate tool using the code snippet 11570 for ac_prog in tee 11571 do 11572 # Extract the first word of "$ac_prog", so it can be a program name with args. 11573 set dummy $ac_prog; ac_word=$2 11574 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 11575 $as_echo_n "checking for $ac_word... " >&6; } 11576 if ${ac_cv_path_TEE+:} false; then : 11577 $as_echo_n "(cached) " >&6 11578 else 11579 case $TEE in 11580 [\\/]* | ?:[\\/]*) 11581 ac_cv_path_TEE="$TEE" # Let the user override the test with a path. 11582 ;; 11583 *) 11584 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 11585 for as_dir in $PATH 11586 do 11587 IFS=$as_save_IFS 11588 test -z "$as_dir" && as_dir=. 11589 for ac_exec_ext in '' $ac_executable_extensions; do 11590 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 11591 ac_cv_path_TEE="$as_dir/$ac_word$ac_exec_ext" 11592 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 11593 break 2 11594 fi 11595 done 11596 done 11597 IFS=$as_save_IFS 11598 11599 ;; 11600 esac 11601 fi 11602 TEE=$ac_cv_path_TEE 11603 if test -n "$TEE"; then 11604 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $TEE" >&5 11605 $as_echo "$TEE" >&6; } 11606 else 11607 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 11608 $as_echo "no" >&6; } 11609 fi 11610 11611 11612 test -n "$TEE" && break 11613 done 11614 11615 else 11616 # The variable is set, but is it from the command line or the environment? 11617 11618 # Try to remove the string !TEE! from our list. 11619 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!TEE!/} 11620 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 11621 # If it failed, the variable was not from the command line. Ignore it, 11622 # but warn the user (except for BASH, which is always set by the calling BASH). 11623 if test "xTEE" != xBASH; then 11624 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of TEE from the environment. Use command line variables instead." >&5 11625 $as_echo "$as_me: WARNING: Ignoring value of TEE from the environment. Use command line variables instead." >&2;} 11626 fi 11627 # Try to locate tool using the code snippet 11628 for ac_prog in tee 11629 do 11630 # Extract the first word of "$ac_prog", so it can be a program name with args. 11631 set dummy $ac_prog; ac_word=$2 11632 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 11633 $as_echo_n "checking for $ac_word... " >&6; } 11634 if ${ac_cv_path_TEE+:} false; then : 11635 $as_echo_n "(cached) " >&6 11636 else 11637 case $TEE in 11638 [\\/]* | ?:[\\/]*) 11639 ac_cv_path_TEE="$TEE" # Let the user override the test with a path. 11640 ;; 11641 *) 11642 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 11643 for as_dir in $PATH 11644 do 11645 IFS=$as_save_IFS 11646 test -z "$as_dir" && as_dir=. 11647 for ac_exec_ext in '' $ac_executable_extensions; do 11648 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 11649 ac_cv_path_TEE="$as_dir/$ac_word$ac_exec_ext" 11650 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 11651 break 2 11652 fi 11653 done 11654 done 11655 IFS=$as_save_IFS 11656 11657 ;; 11658 esac 11659 fi 11660 TEE=$ac_cv_path_TEE 11661 if test -n "$TEE"; then 11662 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $TEE" >&5 11663 $as_echo "$TEE" >&6; } 11664 else 11665 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 11666 $as_echo "no" >&6; } 11667 fi 11668 11669 11670 test -n "$TEE" && break 11671 done 11672 11673 else 11674 # If it succeeded, then it was overridden by the user. We will use it 11675 # for the tool. 11676 11677 # First remove it from the list of overridden variables, so we can test 11678 # for unknown variables in the end. 11679 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 11680 11681 # Check if we try to supply an empty value 11682 if test "x$TEE" = x; then 11683 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool TEE= (no value)" >&5 11684 $as_echo "$as_me: Setting user supplied tool TEE= (no value)" >&6;} 11685 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for TEE" >&5 11686 $as_echo_n "checking for TEE... " >&6; } 11687 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 11688 $as_echo "disabled" >&6; } 11689 else 11690 # Check if the provided tool contains a complete path. 11691 tool_specified="$TEE" 11692 tool_basename="${tool_specified##*/}" 11693 if test "x$tool_basename" = "x$tool_specified"; then 11694 # A command without a complete path is provided, search $PATH. 11695 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool TEE=$tool_basename" >&5 11696 $as_echo "$as_me: Will search for user supplied tool TEE=$tool_basename" >&6;} 11697 # Extract the first word of "$tool_basename", so it can be a program name with args. 11698 set dummy $tool_basename; ac_word=$2 11699 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 11700 $as_echo_n "checking for $ac_word... " >&6; } 11701 if ${ac_cv_path_TEE+:} false; then : 11702 $as_echo_n "(cached) " >&6 11703 else 11704 case $TEE in 11705 [\\/]* | ?:[\\/]*) 11706 ac_cv_path_TEE="$TEE" # Let the user override the test with a path. 11707 ;; 11708 *) 11709 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 11710 for as_dir in $PATH 11711 do 11712 IFS=$as_save_IFS 11713 test -z "$as_dir" && as_dir=. 11714 for ac_exec_ext in '' $ac_executable_extensions; do 11715 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 11716 ac_cv_path_TEE="$as_dir/$ac_word$ac_exec_ext" 11717 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 11718 break 2 11719 fi 11720 done 11721 done 11722 IFS=$as_save_IFS 11723 11724 ;; 11725 esac 11726 fi 11727 TEE=$ac_cv_path_TEE 11728 if test -n "$TEE"; then 11729 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $TEE" >&5 11730 $as_echo "$TEE" >&6; } 11731 else 11732 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 11733 $as_echo "no" >&6; } 11734 fi 11735 11736 11737 if test "x$TEE" = x; then 11738 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 11739 fi 11740 else 11741 # Otherwise we believe it is a complete path. Use it as it is. 11742 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool TEE=$tool_specified" >&5 11743 $as_echo "$as_me: Will use user supplied tool TEE=$tool_specified" >&6;} 11744 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for TEE" >&5 11745 $as_echo_n "checking for TEE... " >&6; } 11746 if test ! -x "$tool_specified"; then 11747 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 11748 $as_echo "not found" >&6; } 11749 as_fn_error $? "User supplied tool TEE=$tool_specified does not exist or is not executable" "$LINENO" 5 11750 fi 11751 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 11752 $as_echo "$tool_specified" >&6; } 11753 fi 11754 fi 11755 fi 11756 11757 fi 11758 11759 11760 11761 if test "x$TEE" = x; then 11762 as_fn_error $? "Could not find required tool for TEE" "$LINENO" 5 11763 fi 11764 11765 11766 11767 11768 11769 # Publish this variable in the help. 11770 11771 11772 if [ -z "${TOUCH+x}" ]; then 11773 # The variable is not set by user, try to locate tool using the code snippet 11774 for ac_prog in touch 11775 do 11776 # Extract the first word of "$ac_prog", so it can be a program name with args. 11777 set dummy $ac_prog; ac_word=$2 11778 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 11779 $as_echo_n "checking for $ac_word... " >&6; } 11780 if ${ac_cv_path_TOUCH+:} false; then : 11781 $as_echo_n "(cached) " >&6 11782 else 11783 case $TOUCH in 11784 [\\/]* | ?:[\\/]*) 11785 ac_cv_path_TOUCH="$TOUCH" # Let the user override the test with a path. 11786 ;; 11787 *) 11788 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 11789 for as_dir in $PATH 11790 do 11791 IFS=$as_save_IFS 11792 test -z "$as_dir" && as_dir=. 11793 for ac_exec_ext in '' $ac_executable_extensions; do 11794 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 11795 ac_cv_path_TOUCH="$as_dir/$ac_word$ac_exec_ext" 11796 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 11797 break 2 11798 fi 11799 done 11800 done 11801 IFS=$as_save_IFS 11802 11803 ;; 11804 esac 11805 fi 11806 TOUCH=$ac_cv_path_TOUCH 11807 if test -n "$TOUCH"; then 11808 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $TOUCH" >&5 11809 $as_echo "$TOUCH" >&6; } 11810 else 11811 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 11812 $as_echo "no" >&6; } 11813 fi 11814 11815 11816 test -n "$TOUCH" && break 11817 done 11818 11819 else 11820 # The variable is set, but is it from the command line or the environment? 11821 11822 # Try to remove the string !TOUCH! from our list. 11823 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!TOUCH!/} 11824 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 11825 # If it failed, the variable was not from the command line. Ignore it, 11826 # but warn the user (except for BASH, which is always set by the calling BASH). 11827 if test "xTOUCH" != xBASH; then 11828 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of TOUCH from the environment. Use command line variables instead." >&5 11829 $as_echo "$as_me: WARNING: Ignoring value of TOUCH from the environment. Use command line variables instead." >&2;} 11830 fi 11831 # Try to locate tool using the code snippet 11832 for ac_prog in touch 11833 do 11834 # Extract the first word of "$ac_prog", so it can be a program name with args. 11835 set dummy $ac_prog; ac_word=$2 11836 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 11837 $as_echo_n "checking for $ac_word... " >&6; } 11838 if ${ac_cv_path_TOUCH+:} false; then : 11839 $as_echo_n "(cached) " >&6 11840 else 11841 case $TOUCH in 11842 [\\/]* | ?:[\\/]*) 11843 ac_cv_path_TOUCH="$TOUCH" # Let the user override the test with a path. 11844 ;; 11845 *) 11846 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 11847 for as_dir in $PATH 11848 do 11849 IFS=$as_save_IFS 11850 test -z "$as_dir" && as_dir=. 11851 for ac_exec_ext in '' $ac_executable_extensions; do 11852 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 11853 ac_cv_path_TOUCH="$as_dir/$ac_word$ac_exec_ext" 11854 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 11855 break 2 11856 fi 11857 done 11858 done 11859 IFS=$as_save_IFS 11860 11861 ;; 11862 esac 11863 fi 11864 TOUCH=$ac_cv_path_TOUCH 11865 if test -n "$TOUCH"; then 11866 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $TOUCH" >&5 11867 $as_echo "$TOUCH" >&6; } 11868 else 11869 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 11870 $as_echo "no" >&6; } 11871 fi 11872 11873 11874 test -n "$TOUCH" && break 11875 done 11876 11877 else 11878 # If it succeeded, then it was overridden by the user. We will use it 11879 # for the tool. 11880 11881 # First remove it from the list of overridden variables, so we can test 11882 # for unknown variables in the end. 11883 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 11884 11885 # Check if we try to supply an empty value 11886 if test "x$TOUCH" = x; then 11887 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool TOUCH= (no value)" >&5 11888 $as_echo "$as_me: Setting user supplied tool TOUCH= (no value)" >&6;} 11889 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for TOUCH" >&5 11890 $as_echo_n "checking for TOUCH... " >&6; } 11891 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 11892 $as_echo "disabled" >&6; } 11893 else 11894 # Check if the provided tool contains a complete path. 11895 tool_specified="$TOUCH" 11896 tool_basename="${tool_specified##*/}" 11897 if test "x$tool_basename" = "x$tool_specified"; then 11898 # A command without a complete path is provided, search $PATH. 11899 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool TOUCH=$tool_basename" >&5 11900 $as_echo "$as_me: Will search for user supplied tool TOUCH=$tool_basename" >&6;} 11901 # Extract the first word of "$tool_basename", so it can be a program name with args. 11902 set dummy $tool_basename; ac_word=$2 11903 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 11904 $as_echo_n "checking for $ac_word... " >&6; } 11905 if ${ac_cv_path_TOUCH+:} false; then : 11906 $as_echo_n "(cached) " >&6 11907 else 11908 case $TOUCH in 11909 [\\/]* | ?:[\\/]*) 11910 ac_cv_path_TOUCH="$TOUCH" # Let the user override the test with a path. 11911 ;; 11912 *) 11913 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 11914 for as_dir in $PATH 11915 do 11916 IFS=$as_save_IFS 11917 test -z "$as_dir" && as_dir=. 11918 for ac_exec_ext in '' $ac_executable_extensions; do 11919 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 11920 ac_cv_path_TOUCH="$as_dir/$ac_word$ac_exec_ext" 11921 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 11922 break 2 11923 fi 11924 done 11925 done 11926 IFS=$as_save_IFS 11927 11928 ;; 11929 esac 11930 fi 11931 TOUCH=$ac_cv_path_TOUCH 11932 if test -n "$TOUCH"; then 11933 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $TOUCH" >&5 11934 $as_echo "$TOUCH" >&6; } 11935 else 11936 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 11937 $as_echo "no" >&6; } 11938 fi 11939 11940 11941 if test "x$TOUCH" = x; then 11942 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 11943 fi 11944 else 11945 # Otherwise we believe it is a complete path. Use it as it is. 11946 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool TOUCH=$tool_specified" >&5 11947 $as_echo "$as_me: Will use user supplied tool TOUCH=$tool_specified" >&6;} 11948 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for TOUCH" >&5 11949 $as_echo_n "checking for TOUCH... " >&6; } 11950 if test ! -x "$tool_specified"; then 11951 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 11952 $as_echo "not found" >&6; } 11953 as_fn_error $? "User supplied tool TOUCH=$tool_specified does not exist or is not executable" "$LINENO" 5 11954 fi 11955 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 11956 $as_echo "$tool_specified" >&6; } 11957 fi 11958 fi 11959 fi 11960 11961 fi 11962 11963 11964 11965 if test "x$TOUCH" = x; then 11966 as_fn_error $? "Could not find required tool for TOUCH" "$LINENO" 5 11967 fi 11968 11969 11970 11971 11972 11973 # Publish this variable in the help. 11974 11975 11976 if [ -z "${TR+x}" ]; then 11977 # The variable is not set by user, try to locate tool using the code snippet 11978 for ac_prog in tr 11979 do 11980 # Extract the first word of "$ac_prog", so it can be a program name with args. 11981 set dummy $ac_prog; ac_word=$2 11982 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 11983 $as_echo_n "checking for $ac_word... " >&6; } 11984 if ${ac_cv_path_TR+:} false; then : 11985 $as_echo_n "(cached) " >&6 11986 else 11987 case $TR in 11988 [\\/]* | ?:[\\/]*) 11989 ac_cv_path_TR="$TR" # Let the user override the test with a path. 11990 ;; 11991 *) 11992 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 11993 for as_dir in $PATH 11994 do 11995 IFS=$as_save_IFS 11996 test -z "$as_dir" && as_dir=. 11997 for ac_exec_ext in '' $ac_executable_extensions; do 11998 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 11999 ac_cv_path_TR="$as_dir/$ac_word$ac_exec_ext" 12000 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 12001 break 2 12002 fi 12003 done 12004 done 12005 IFS=$as_save_IFS 12006 12007 ;; 12008 esac 12009 fi 12010 TR=$ac_cv_path_TR 12011 if test -n "$TR"; then 12012 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $TR" >&5 12013 $as_echo "$TR" >&6; } 12014 else 12015 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 12016 $as_echo "no" >&6; } 12017 fi 12018 12019 12020 test -n "$TR" && break 12021 done 12022 12023 else 12024 # The variable is set, but is it from the command line or the environment? 12025 12026 # Try to remove the string !TR! from our list. 12027 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!TR!/} 12028 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 12029 # If it failed, the variable was not from the command line. Ignore it, 12030 # but warn the user (except for BASH, which is always set by the calling BASH). 12031 if test "xTR" != xBASH; then 12032 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of TR from the environment. Use command line variables instead." >&5 12033 $as_echo "$as_me: WARNING: Ignoring value of TR from the environment. Use command line variables instead." >&2;} 12034 fi 12035 # Try to locate tool using the code snippet 12036 for ac_prog in tr 12037 do 12038 # Extract the first word of "$ac_prog", so it can be a program name with args. 12039 set dummy $ac_prog; ac_word=$2 12040 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 12041 $as_echo_n "checking for $ac_word... " >&6; } 12042 if ${ac_cv_path_TR+:} false; then : 12043 $as_echo_n "(cached) " >&6 12044 else 12045 case $TR in 12046 [\\/]* | ?:[\\/]*) 12047 ac_cv_path_TR="$TR" # Let the user override the test with a path. 12048 ;; 12049 *) 12050 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 12051 for as_dir in $PATH 12052 do 12053 IFS=$as_save_IFS 12054 test -z "$as_dir" && as_dir=. 12055 for ac_exec_ext in '' $ac_executable_extensions; do 12056 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 12057 ac_cv_path_TR="$as_dir/$ac_word$ac_exec_ext" 12058 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 12059 break 2 12060 fi 12061 done 12062 done 12063 IFS=$as_save_IFS 12064 12065 ;; 12066 esac 12067 fi 12068 TR=$ac_cv_path_TR 12069 if test -n "$TR"; then 12070 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $TR" >&5 12071 $as_echo "$TR" >&6; } 12072 else 12073 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 12074 $as_echo "no" >&6; } 12075 fi 12076 12077 12078 test -n "$TR" && break 12079 done 12080 12081 else 12082 # If it succeeded, then it was overridden by the user. We will use it 12083 # for the tool. 12084 12085 # First remove it from the list of overridden variables, so we can test 12086 # for unknown variables in the end. 12087 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 12088 12089 # Check if we try to supply an empty value 12090 if test "x$TR" = x; then 12091 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool TR= (no value)" >&5 12092 $as_echo "$as_me: Setting user supplied tool TR= (no value)" >&6;} 12093 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for TR" >&5 12094 $as_echo_n "checking for TR... " >&6; } 12095 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 12096 $as_echo "disabled" >&6; } 12097 else 12098 # Check if the provided tool contains a complete path. 12099 tool_specified="$TR" 12100 tool_basename="${tool_specified##*/}" 12101 if test "x$tool_basename" = "x$tool_specified"; then 12102 # A command without a complete path is provided, search $PATH. 12103 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool TR=$tool_basename" >&5 12104 $as_echo "$as_me: Will search for user supplied tool TR=$tool_basename" >&6;} 12105 # Extract the first word of "$tool_basename", so it can be a program name with args. 12106 set dummy $tool_basename; ac_word=$2 12107 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 12108 $as_echo_n "checking for $ac_word... " >&6; } 12109 if ${ac_cv_path_TR+:} false; then : 12110 $as_echo_n "(cached) " >&6 12111 else 12112 case $TR in 12113 [\\/]* | ?:[\\/]*) 12114 ac_cv_path_TR="$TR" # Let the user override the test with a path. 12115 ;; 12116 *) 12117 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 12118 for as_dir in $PATH 12119 do 12120 IFS=$as_save_IFS 12121 test -z "$as_dir" && as_dir=. 12122 for ac_exec_ext in '' $ac_executable_extensions; do 12123 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 12124 ac_cv_path_TR="$as_dir/$ac_word$ac_exec_ext" 12125 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 12126 break 2 12127 fi 12128 done 12129 done 12130 IFS=$as_save_IFS 12131 12132 ;; 12133 esac 12134 fi 12135 TR=$ac_cv_path_TR 12136 if test -n "$TR"; then 12137 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $TR" >&5 12138 $as_echo "$TR" >&6; } 12139 else 12140 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 12141 $as_echo "no" >&6; } 12142 fi 12143 12144 12145 if test "x$TR" = x; then 12146 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 12147 fi 12148 else 12149 # Otherwise we believe it is a complete path. Use it as it is. 12150 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool TR=$tool_specified" >&5 12151 $as_echo "$as_me: Will use user supplied tool TR=$tool_specified" >&6;} 12152 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for TR" >&5 12153 $as_echo_n "checking for TR... " >&6; } 12154 if test ! -x "$tool_specified"; then 12155 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 12156 $as_echo "not found" >&6; } 12157 as_fn_error $? "User supplied tool TR=$tool_specified does not exist or is not executable" "$LINENO" 5 12158 fi 12159 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 12160 $as_echo "$tool_specified" >&6; } 12161 fi 12162 fi 12163 fi 12164 12165 fi 12166 12167 12168 12169 if test "x$TR" = x; then 12170 as_fn_error $? "Could not find required tool for TR" "$LINENO" 5 12171 fi 12172 12173 12174 12175 12176 12177 # Publish this variable in the help. 12178 12179 12180 if [ -z "${UNAME+x}" ]; then 12181 # The variable is not set by user, try to locate tool using the code snippet 12182 for ac_prog in uname 12183 do 12184 # Extract the first word of "$ac_prog", so it can be a program name with args. 12185 set dummy $ac_prog; ac_word=$2 12186 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 12187 $as_echo_n "checking for $ac_word... " >&6; } 12188 if ${ac_cv_path_UNAME+:} false; then : 12189 $as_echo_n "(cached) " >&6 12190 else 12191 case $UNAME in 12192 [\\/]* | ?:[\\/]*) 12193 ac_cv_path_UNAME="$UNAME" # Let the user override the test with a path. 12194 ;; 12195 *) 12196 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 12197 for as_dir in $PATH 12198 do 12199 IFS=$as_save_IFS 12200 test -z "$as_dir" && as_dir=. 12201 for ac_exec_ext in '' $ac_executable_extensions; do 12202 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 12203 ac_cv_path_UNAME="$as_dir/$ac_word$ac_exec_ext" 12204 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 12205 break 2 12206 fi 12207 done 12208 done 12209 IFS=$as_save_IFS 12210 12211 ;; 12212 esac 12213 fi 12214 UNAME=$ac_cv_path_UNAME 12215 if test -n "$UNAME"; then 12216 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $UNAME" >&5 12217 $as_echo "$UNAME" >&6; } 12218 else 12219 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 12220 $as_echo "no" >&6; } 12221 fi 12222 12223 12224 test -n "$UNAME" && break 12225 done 12226 12227 else 12228 # The variable is set, but is it from the command line or the environment? 12229 12230 # Try to remove the string !UNAME! from our list. 12231 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!UNAME!/} 12232 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 12233 # If it failed, the variable was not from the command line. Ignore it, 12234 # but warn the user (except for BASH, which is always set by the calling BASH). 12235 if test "xUNAME" != xBASH; then 12236 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of UNAME from the environment. Use command line variables instead." >&5 12237 $as_echo "$as_me: WARNING: Ignoring value of UNAME from the environment. Use command line variables instead." >&2;} 12238 fi 12239 # Try to locate tool using the code snippet 12240 for ac_prog in uname 12241 do 12242 # Extract the first word of "$ac_prog", so it can be a program name with args. 12243 set dummy $ac_prog; ac_word=$2 12244 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 12245 $as_echo_n "checking for $ac_word... " >&6; } 12246 if ${ac_cv_path_UNAME+:} false; then : 12247 $as_echo_n "(cached) " >&6 12248 else 12249 case $UNAME in 12250 [\\/]* | ?:[\\/]*) 12251 ac_cv_path_UNAME="$UNAME" # Let the user override the test with a path. 12252 ;; 12253 *) 12254 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 12255 for as_dir in $PATH 12256 do 12257 IFS=$as_save_IFS 12258 test -z "$as_dir" && as_dir=. 12259 for ac_exec_ext in '' $ac_executable_extensions; do 12260 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 12261 ac_cv_path_UNAME="$as_dir/$ac_word$ac_exec_ext" 12262 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 12263 break 2 12264 fi 12265 done 12266 done 12267 IFS=$as_save_IFS 12268 12269 ;; 12270 esac 12271 fi 12272 UNAME=$ac_cv_path_UNAME 12273 if test -n "$UNAME"; then 12274 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $UNAME" >&5 12275 $as_echo "$UNAME" >&6; } 12276 else 12277 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 12278 $as_echo "no" >&6; } 12279 fi 12280 12281 12282 test -n "$UNAME" && break 12283 done 12284 12285 else 12286 # If it succeeded, then it was overridden by the user. We will use it 12287 # for the tool. 12288 12289 # First remove it from the list of overridden variables, so we can test 12290 # for unknown variables in the end. 12291 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 12292 12293 # Check if we try to supply an empty value 12294 if test "x$UNAME" = x; then 12295 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool UNAME= (no value)" >&5 12296 $as_echo "$as_me: Setting user supplied tool UNAME= (no value)" >&6;} 12297 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for UNAME" >&5 12298 $as_echo_n "checking for UNAME... " >&6; } 12299 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 12300 $as_echo "disabled" >&6; } 12301 else 12302 # Check if the provided tool contains a complete path. 12303 tool_specified="$UNAME" 12304 tool_basename="${tool_specified##*/}" 12305 if test "x$tool_basename" = "x$tool_specified"; then 12306 # A command without a complete path is provided, search $PATH. 12307 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool UNAME=$tool_basename" >&5 12308 $as_echo "$as_me: Will search for user supplied tool UNAME=$tool_basename" >&6;} 12309 # Extract the first word of "$tool_basename", so it can be a program name with args. 12310 set dummy $tool_basename; ac_word=$2 12311 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 12312 $as_echo_n "checking for $ac_word... " >&6; } 12313 if ${ac_cv_path_UNAME+:} false; then : 12314 $as_echo_n "(cached) " >&6 12315 else 12316 case $UNAME in 12317 [\\/]* | ?:[\\/]*) 12318 ac_cv_path_UNAME="$UNAME" # Let the user override the test with a path. 12319 ;; 12320 *) 12321 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 12322 for as_dir in $PATH 12323 do 12324 IFS=$as_save_IFS 12325 test -z "$as_dir" && as_dir=. 12326 for ac_exec_ext in '' $ac_executable_extensions; do 12327 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 12328 ac_cv_path_UNAME="$as_dir/$ac_word$ac_exec_ext" 12329 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 12330 break 2 12331 fi 12332 done 12333 done 12334 IFS=$as_save_IFS 12335 12336 ;; 12337 esac 12338 fi 12339 UNAME=$ac_cv_path_UNAME 12340 if test -n "$UNAME"; then 12341 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $UNAME" >&5 12342 $as_echo "$UNAME" >&6; } 12343 else 12344 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 12345 $as_echo "no" >&6; } 12346 fi 12347 12348 12349 if test "x$UNAME" = x; then 12350 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 12351 fi 12352 else 12353 # Otherwise we believe it is a complete path. Use it as it is. 12354 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool UNAME=$tool_specified" >&5 12355 $as_echo "$as_me: Will use user supplied tool UNAME=$tool_specified" >&6;} 12356 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for UNAME" >&5 12357 $as_echo_n "checking for UNAME... " >&6; } 12358 if test ! -x "$tool_specified"; then 12359 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 12360 $as_echo "not found" >&6; } 12361 as_fn_error $? "User supplied tool UNAME=$tool_specified does not exist or is not executable" "$LINENO" 5 12362 fi 12363 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 12364 $as_echo "$tool_specified" >&6; } 12365 fi 12366 fi 12367 fi 12368 12369 fi 12370 12371 12372 12373 if test "x$UNAME" = x; then 12374 as_fn_error $? "Could not find required tool for UNAME" "$LINENO" 5 12375 fi 12376 12377 12378 12379 12380 12381 # Publish this variable in the help. 12382 12383 12384 if [ -z "${UNIQ+x}" ]; then 12385 # The variable is not set by user, try to locate tool using the code snippet 12386 for ac_prog in uniq 12387 do 12388 # Extract the first word of "$ac_prog", so it can be a program name with args. 12389 set dummy $ac_prog; ac_word=$2 12390 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 12391 $as_echo_n "checking for $ac_word... " >&6; } 12392 if ${ac_cv_path_UNIQ+:} false; then : 12393 $as_echo_n "(cached) " >&6 12394 else 12395 case $UNIQ in 12396 [\\/]* | ?:[\\/]*) 12397 ac_cv_path_UNIQ="$UNIQ" # Let the user override the test with a path. 12398 ;; 12399 *) 12400 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 12401 for as_dir in $PATH 12402 do 12403 IFS=$as_save_IFS 12404 test -z "$as_dir" && as_dir=. 12405 for ac_exec_ext in '' $ac_executable_extensions; do 12406 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 12407 ac_cv_path_UNIQ="$as_dir/$ac_word$ac_exec_ext" 12408 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 12409 break 2 12410 fi 12411 done 12412 done 12413 IFS=$as_save_IFS 12414 12415 ;; 12416 esac 12417 fi 12418 UNIQ=$ac_cv_path_UNIQ 12419 if test -n "$UNIQ"; then 12420 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $UNIQ" >&5 12421 $as_echo "$UNIQ" >&6; } 12422 else 12423 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 12424 $as_echo "no" >&6; } 12425 fi 12426 12427 12428 test -n "$UNIQ" && break 12429 done 12430 12431 else 12432 # The variable is set, but is it from the command line or the environment? 12433 12434 # Try to remove the string !UNIQ! from our list. 12435 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!UNIQ!/} 12436 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 12437 # If it failed, the variable was not from the command line. Ignore it, 12438 # but warn the user (except for BASH, which is always set by the calling BASH). 12439 if test "xUNIQ" != xBASH; then 12440 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of UNIQ from the environment. Use command line variables instead." >&5 12441 $as_echo "$as_me: WARNING: Ignoring value of UNIQ from the environment. Use command line variables instead." >&2;} 12442 fi 12443 # Try to locate tool using the code snippet 12444 for ac_prog in uniq 12445 do 12446 # Extract the first word of "$ac_prog", so it can be a program name with args. 12447 set dummy $ac_prog; ac_word=$2 12448 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 12449 $as_echo_n "checking for $ac_word... " >&6; } 12450 if ${ac_cv_path_UNIQ+:} false; then : 12451 $as_echo_n "(cached) " >&6 12452 else 12453 case $UNIQ in 12454 [\\/]* | ?:[\\/]*) 12455 ac_cv_path_UNIQ="$UNIQ" # Let the user override the test with a path. 12456 ;; 12457 *) 12458 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 12459 for as_dir in $PATH 12460 do 12461 IFS=$as_save_IFS 12462 test -z "$as_dir" && as_dir=. 12463 for ac_exec_ext in '' $ac_executable_extensions; do 12464 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 12465 ac_cv_path_UNIQ="$as_dir/$ac_word$ac_exec_ext" 12466 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 12467 break 2 12468 fi 12469 done 12470 done 12471 IFS=$as_save_IFS 12472 12473 ;; 12474 esac 12475 fi 12476 UNIQ=$ac_cv_path_UNIQ 12477 if test -n "$UNIQ"; then 12478 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $UNIQ" >&5 12479 $as_echo "$UNIQ" >&6; } 12480 else 12481 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 12482 $as_echo "no" >&6; } 12483 fi 12484 12485 12486 test -n "$UNIQ" && break 12487 done 12488 12489 else 12490 # If it succeeded, then it was overridden by the user. We will use it 12491 # for the tool. 12492 12493 # First remove it from the list of overridden variables, so we can test 12494 # for unknown variables in the end. 12495 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 12496 12497 # Check if we try to supply an empty value 12498 if test "x$UNIQ" = x; then 12499 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool UNIQ= (no value)" >&5 12500 $as_echo "$as_me: Setting user supplied tool UNIQ= (no value)" >&6;} 12501 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for UNIQ" >&5 12502 $as_echo_n "checking for UNIQ... " >&6; } 12503 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 12504 $as_echo "disabled" >&6; } 12505 else 12506 # Check if the provided tool contains a complete path. 12507 tool_specified="$UNIQ" 12508 tool_basename="${tool_specified##*/}" 12509 if test "x$tool_basename" = "x$tool_specified"; then 12510 # A command without a complete path is provided, search $PATH. 12511 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool UNIQ=$tool_basename" >&5 12512 $as_echo "$as_me: Will search for user supplied tool UNIQ=$tool_basename" >&6;} 12513 # Extract the first word of "$tool_basename", so it can be a program name with args. 12514 set dummy $tool_basename; ac_word=$2 12515 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 12516 $as_echo_n "checking for $ac_word... " >&6; } 12517 if ${ac_cv_path_UNIQ+:} false; then : 12518 $as_echo_n "(cached) " >&6 12519 else 12520 case $UNIQ in 12521 [\\/]* | ?:[\\/]*) 12522 ac_cv_path_UNIQ="$UNIQ" # Let the user override the test with a path. 12523 ;; 12524 *) 12525 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 12526 for as_dir in $PATH 12527 do 12528 IFS=$as_save_IFS 12529 test -z "$as_dir" && as_dir=. 12530 for ac_exec_ext in '' $ac_executable_extensions; do 12531 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 12532 ac_cv_path_UNIQ="$as_dir/$ac_word$ac_exec_ext" 12533 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 12534 break 2 12535 fi 12536 done 12537 done 12538 IFS=$as_save_IFS 12539 12540 ;; 12541 esac 12542 fi 12543 UNIQ=$ac_cv_path_UNIQ 12544 if test -n "$UNIQ"; then 12545 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $UNIQ" >&5 12546 $as_echo "$UNIQ" >&6; } 12547 else 12548 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 12549 $as_echo "no" >&6; } 12550 fi 12551 12552 12553 if test "x$UNIQ" = x; then 12554 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 12555 fi 12556 else 12557 # Otherwise we believe it is a complete path. Use it as it is. 12558 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool UNIQ=$tool_specified" >&5 12559 $as_echo "$as_me: Will use user supplied tool UNIQ=$tool_specified" >&6;} 12560 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for UNIQ" >&5 12561 $as_echo_n "checking for UNIQ... " >&6; } 12562 if test ! -x "$tool_specified"; then 12563 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 12564 $as_echo "not found" >&6; } 12565 as_fn_error $? "User supplied tool UNIQ=$tool_specified does not exist or is not executable" "$LINENO" 5 12566 fi 12567 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 12568 $as_echo "$tool_specified" >&6; } 12569 fi 12570 fi 12571 fi 12572 12573 fi 12574 12575 12576 12577 if test "x$UNIQ" = x; then 12578 as_fn_error $? "Could not find required tool for UNIQ" "$LINENO" 5 12579 fi 12580 12581 12582 12583 12584 12585 # Publish this variable in the help. 12586 12587 12588 if [ -z "${WC+x}" ]; then 12589 # The variable is not set by user, try to locate tool using the code snippet 12590 for ac_prog in wc 12591 do 12592 # Extract the first word of "$ac_prog", so it can be a program name with args. 12593 set dummy $ac_prog; ac_word=$2 12594 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 12595 $as_echo_n "checking for $ac_word... " >&6; } 12596 if ${ac_cv_path_WC+:} false; then : 12597 $as_echo_n "(cached) " >&6 12598 else 12599 case $WC in 12600 [\\/]* | ?:[\\/]*) 12601 ac_cv_path_WC="$WC" # Let the user override the test with a path. 12602 ;; 12603 *) 12604 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 12605 for as_dir in $PATH 12606 do 12607 IFS=$as_save_IFS 12608 test -z "$as_dir" && as_dir=. 12609 for ac_exec_ext in '' $ac_executable_extensions; do 12610 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 12611 ac_cv_path_WC="$as_dir/$ac_word$ac_exec_ext" 12612 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 12613 break 2 12614 fi 12615 done 12616 done 12617 IFS=$as_save_IFS 12618 12619 ;; 12620 esac 12621 fi 12622 WC=$ac_cv_path_WC 12623 if test -n "$WC"; then 12624 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $WC" >&5 12625 $as_echo "$WC" >&6; } 12626 else 12627 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 12628 $as_echo "no" >&6; } 12629 fi 12630 12631 12632 test -n "$WC" && break 12633 done 12634 12635 else 12636 # The variable is set, but is it from the command line or the environment? 12637 12638 # Try to remove the string !WC! from our list. 12639 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!WC!/} 12640 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 12641 # If it failed, the variable was not from the command line. Ignore it, 12642 # but warn the user (except for BASH, which is always set by the calling BASH). 12643 if test "xWC" != xBASH; then 12644 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of WC from the environment. Use command line variables instead." >&5 12645 $as_echo "$as_me: WARNING: Ignoring value of WC from the environment. Use command line variables instead." >&2;} 12646 fi 12647 # Try to locate tool using the code snippet 12648 for ac_prog in wc 12649 do 12650 # Extract the first word of "$ac_prog", so it can be a program name with args. 12651 set dummy $ac_prog; ac_word=$2 12652 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 12653 $as_echo_n "checking for $ac_word... " >&6; } 12654 if ${ac_cv_path_WC+:} false; then : 12655 $as_echo_n "(cached) " >&6 12656 else 12657 case $WC in 12658 [\\/]* | ?:[\\/]*) 12659 ac_cv_path_WC="$WC" # Let the user override the test with a path. 12660 ;; 12661 *) 12662 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 12663 for as_dir in $PATH 12664 do 12665 IFS=$as_save_IFS 12666 test -z "$as_dir" && as_dir=. 12667 for ac_exec_ext in '' $ac_executable_extensions; do 12668 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 12669 ac_cv_path_WC="$as_dir/$ac_word$ac_exec_ext" 12670 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 12671 break 2 12672 fi 12673 done 12674 done 12675 IFS=$as_save_IFS 12676 12677 ;; 12678 esac 12679 fi 12680 WC=$ac_cv_path_WC 12681 if test -n "$WC"; then 12682 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $WC" >&5 12683 $as_echo "$WC" >&6; } 12684 else 12685 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 12686 $as_echo "no" >&6; } 12687 fi 12688 12689 12690 test -n "$WC" && break 12691 done 12692 12693 else 12694 # If it succeeded, then it was overridden by the user. We will use it 12695 # for the tool. 12696 12697 # First remove it from the list of overridden variables, so we can test 12698 # for unknown variables in the end. 12699 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 12700 12701 # Check if we try to supply an empty value 12702 if test "x$WC" = x; then 12703 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool WC= (no value)" >&5 12704 $as_echo "$as_me: Setting user supplied tool WC= (no value)" >&6;} 12705 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for WC" >&5 12706 $as_echo_n "checking for WC... " >&6; } 12707 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 12708 $as_echo "disabled" >&6; } 12709 else 12710 # Check if the provided tool contains a complete path. 12711 tool_specified="$WC" 12712 tool_basename="${tool_specified##*/}" 12713 if test "x$tool_basename" = "x$tool_specified"; then 12714 # A command without a complete path is provided, search $PATH. 12715 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool WC=$tool_basename" >&5 12716 $as_echo "$as_me: Will search for user supplied tool WC=$tool_basename" >&6;} 12717 # Extract the first word of "$tool_basename", so it can be a program name with args. 12718 set dummy $tool_basename; ac_word=$2 12719 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 12720 $as_echo_n "checking for $ac_word... " >&6; } 12721 if ${ac_cv_path_WC+:} false; then : 12722 $as_echo_n "(cached) " >&6 12723 else 12724 case $WC in 12725 [\\/]* | ?:[\\/]*) 12726 ac_cv_path_WC="$WC" # Let the user override the test with a path. 12727 ;; 12728 *) 12729 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 12730 for as_dir in $PATH 12731 do 12732 IFS=$as_save_IFS 12733 test -z "$as_dir" && as_dir=. 12734 for ac_exec_ext in '' $ac_executable_extensions; do 12735 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 12736 ac_cv_path_WC="$as_dir/$ac_word$ac_exec_ext" 12737 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 12738 break 2 12739 fi 12740 done 12741 done 12742 IFS=$as_save_IFS 12743 12744 ;; 12745 esac 12746 fi 12747 WC=$ac_cv_path_WC 12748 if test -n "$WC"; then 12749 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $WC" >&5 12750 $as_echo "$WC" >&6; } 12751 else 12752 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 12753 $as_echo "no" >&6; } 12754 fi 12755 12756 12757 if test "x$WC" = x; then 12758 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 12759 fi 12760 else 12761 # Otherwise we believe it is a complete path. Use it as it is. 12762 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool WC=$tool_specified" >&5 12763 $as_echo "$as_me: Will use user supplied tool WC=$tool_specified" >&6;} 12764 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for WC" >&5 12765 $as_echo_n "checking for WC... " >&6; } 12766 if test ! -x "$tool_specified"; then 12767 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 12768 $as_echo "not found" >&6; } 12769 as_fn_error $? "User supplied tool WC=$tool_specified does not exist or is not executable" "$LINENO" 5 12770 fi 12771 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 12772 $as_echo "$tool_specified" >&6; } 12773 fi 12774 fi 12775 fi 12776 12777 fi 12778 12779 12780 12781 if test "x$WC" = x; then 12782 as_fn_error $? "Could not find required tool for WC" "$LINENO" 5 12783 fi 12784 12785 12786 12787 12788 12789 # Publish this variable in the help. 12790 12791 12792 if [ -z "${WHICH+x}" ]; then 12793 # The variable is not set by user, try to locate tool using the code snippet 12794 for ac_prog in which 12795 do 12796 # Extract the first word of "$ac_prog", so it can be a program name with args. 12797 set dummy $ac_prog; ac_word=$2 12798 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 12799 $as_echo_n "checking for $ac_word... " >&6; } 12800 if ${ac_cv_path_WHICH+:} false; then : 12801 $as_echo_n "(cached) " >&6 12802 else 12803 case $WHICH in 12804 [\\/]* | ?:[\\/]*) 12805 ac_cv_path_WHICH="$WHICH" # Let the user override the test with a path. 12806 ;; 12807 *) 12808 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 12809 for as_dir in $PATH 12810 do 12811 IFS=$as_save_IFS 12812 test -z "$as_dir" && as_dir=. 12813 for ac_exec_ext in '' $ac_executable_extensions; do 12814 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 12815 ac_cv_path_WHICH="$as_dir/$ac_word$ac_exec_ext" 12816 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 12817 break 2 12818 fi 12819 done 12820 done 12821 IFS=$as_save_IFS 12822 12823 ;; 12824 esac 12825 fi 12826 WHICH=$ac_cv_path_WHICH 12827 if test -n "$WHICH"; then 12828 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $WHICH" >&5 12829 $as_echo "$WHICH" >&6; } 12830 else 12831 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 12832 $as_echo "no" >&6; } 12833 fi 12834 12835 12836 test -n "$WHICH" && break 12837 done 12838 12839 else 12840 # The variable is set, but is it from the command line or the environment? 12841 12842 # Try to remove the string !WHICH! from our list. 12843 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!WHICH!/} 12844 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 12845 # If it failed, the variable was not from the command line. Ignore it, 12846 # but warn the user (except for BASH, which is always set by the calling BASH). 12847 if test "xWHICH" != xBASH; then 12848 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of WHICH from the environment. Use command line variables instead." >&5 12849 $as_echo "$as_me: WARNING: Ignoring value of WHICH from the environment. Use command line variables instead." >&2;} 12850 fi 12851 # Try to locate tool using the code snippet 12852 for ac_prog in which 12853 do 12854 # Extract the first word of "$ac_prog", so it can be a program name with args. 12855 set dummy $ac_prog; ac_word=$2 12856 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 12857 $as_echo_n "checking for $ac_word... " >&6; } 12858 if ${ac_cv_path_WHICH+:} false; then : 12859 $as_echo_n "(cached) " >&6 12860 else 12861 case $WHICH in 12862 [\\/]* | ?:[\\/]*) 12863 ac_cv_path_WHICH="$WHICH" # Let the user override the test with a path. 12864 ;; 12865 *) 12866 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 12867 for as_dir in $PATH 12868 do 12869 IFS=$as_save_IFS 12870 test -z "$as_dir" && as_dir=. 12871 for ac_exec_ext in '' $ac_executable_extensions; do 12872 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 12873 ac_cv_path_WHICH="$as_dir/$ac_word$ac_exec_ext" 12874 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 12875 break 2 12876 fi 12877 done 12878 done 12879 IFS=$as_save_IFS 12880 12881 ;; 12882 esac 12883 fi 12884 WHICH=$ac_cv_path_WHICH 12885 if test -n "$WHICH"; then 12886 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $WHICH" >&5 12887 $as_echo "$WHICH" >&6; } 12888 else 12889 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 12890 $as_echo "no" >&6; } 12891 fi 12892 12893 12894 test -n "$WHICH" && break 12895 done 12896 12897 else 12898 # If it succeeded, then it was overridden by the user. We will use it 12899 # for the tool. 12900 12901 # First remove it from the list of overridden variables, so we can test 12902 # for unknown variables in the end. 12903 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 12904 12905 # Check if we try to supply an empty value 12906 if test "x$WHICH" = x; then 12907 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool WHICH= (no value)" >&5 12908 $as_echo "$as_me: Setting user supplied tool WHICH= (no value)" >&6;} 12909 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for WHICH" >&5 12910 $as_echo_n "checking for WHICH... " >&6; } 12911 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 12912 $as_echo "disabled" >&6; } 12913 else 12914 # Check if the provided tool contains a complete path. 12915 tool_specified="$WHICH" 12916 tool_basename="${tool_specified##*/}" 12917 if test "x$tool_basename" = "x$tool_specified"; then 12918 # A command without a complete path is provided, search $PATH. 12919 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool WHICH=$tool_basename" >&5 12920 $as_echo "$as_me: Will search for user supplied tool WHICH=$tool_basename" >&6;} 12921 # Extract the first word of "$tool_basename", so it can be a program name with args. 12922 set dummy $tool_basename; ac_word=$2 12923 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 12924 $as_echo_n "checking for $ac_word... " >&6; } 12925 if ${ac_cv_path_WHICH+:} false; then : 12926 $as_echo_n "(cached) " >&6 12927 else 12928 case $WHICH in 12929 [\\/]* | ?:[\\/]*) 12930 ac_cv_path_WHICH="$WHICH" # Let the user override the test with a path. 12931 ;; 12932 *) 12933 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 12934 for as_dir in $PATH 12935 do 12936 IFS=$as_save_IFS 12937 test -z "$as_dir" && as_dir=. 12938 for ac_exec_ext in '' $ac_executable_extensions; do 12939 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 12940 ac_cv_path_WHICH="$as_dir/$ac_word$ac_exec_ext" 12941 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 12942 break 2 12943 fi 12944 done 12945 done 12946 IFS=$as_save_IFS 12947 12948 ;; 12949 esac 12950 fi 12951 WHICH=$ac_cv_path_WHICH 12952 if test -n "$WHICH"; then 12953 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $WHICH" >&5 12954 $as_echo "$WHICH" >&6; } 12955 else 12956 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 12957 $as_echo "no" >&6; } 12958 fi 12959 12960 12961 if test "x$WHICH" = x; then 12962 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 12963 fi 12964 else 12965 # Otherwise we believe it is a complete path. Use it as it is. 12966 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool WHICH=$tool_specified" >&5 12967 $as_echo "$as_me: Will use user supplied tool WHICH=$tool_specified" >&6;} 12968 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for WHICH" >&5 12969 $as_echo_n "checking for WHICH... " >&6; } 12970 if test ! -x "$tool_specified"; then 12971 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 12972 $as_echo "not found" >&6; } 12973 as_fn_error $? "User supplied tool WHICH=$tool_specified does not exist or is not executable" "$LINENO" 5 12974 fi 12975 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 12976 $as_echo "$tool_specified" >&6; } 12977 fi 12978 fi 12979 fi 12980 12981 fi 12982 12983 12984 12985 if test "x$WHICH" = x; then 12986 as_fn_error $? "Could not find required tool for WHICH" "$LINENO" 5 12987 fi 12988 12989 12990 12991 12992 12993 # Publish this variable in the help. 12994 12995 12996 if [ -z "${XARGS+x}" ]; then 12997 # The variable is not set by user, try to locate tool using the code snippet 12998 for ac_prog in xargs 12999 do 13000 # Extract the first word of "$ac_prog", so it can be a program name with args. 13001 set dummy $ac_prog; ac_word=$2 13002 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 13003 $as_echo_n "checking for $ac_word... " >&6; } 13004 if ${ac_cv_path_XARGS+:} false; then : 13005 $as_echo_n "(cached) " >&6 13006 else 13007 case $XARGS in 13008 [\\/]* | ?:[\\/]*) 13009 ac_cv_path_XARGS="$XARGS" # Let the user override the test with a path. 13010 ;; 13011 *) 13012 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 13013 for as_dir in $PATH 13014 do 13015 IFS=$as_save_IFS 13016 test -z "$as_dir" && as_dir=. 13017 for ac_exec_ext in '' $ac_executable_extensions; do 13018 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 13019 ac_cv_path_XARGS="$as_dir/$ac_word$ac_exec_ext" 13020 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 13021 break 2 13022 fi 13023 done 13024 done 13025 IFS=$as_save_IFS 13026 13027 ;; 13028 esac 13029 fi 13030 XARGS=$ac_cv_path_XARGS 13031 if test -n "$XARGS"; then 13032 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $XARGS" >&5 13033 $as_echo "$XARGS" >&6; } 13034 else 13035 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 13036 $as_echo "no" >&6; } 13037 fi 13038 13039 13040 test -n "$XARGS" && break 13041 done 13042 13043 else 13044 # The variable is set, but is it from the command line or the environment? 13045 13046 # Try to remove the string !XARGS! from our list. 13047 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!XARGS!/} 13048 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 13049 # If it failed, the variable was not from the command line. Ignore it, 13050 # but warn the user (except for BASH, which is always set by the calling BASH). 13051 if test "xXARGS" != xBASH; then 13052 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of XARGS from the environment. Use command line variables instead." >&5 13053 $as_echo "$as_me: WARNING: Ignoring value of XARGS from the environment. Use command line variables instead." >&2;} 13054 fi 13055 # Try to locate tool using the code snippet 13056 for ac_prog in xargs 13057 do 13058 # Extract the first word of "$ac_prog", so it can be a program name with args. 13059 set dummy $ac_prog; ac_word=$2 13060 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 13061 $as_echo_n "checking for $ac_word... " >&6; } 13062 if ${ac_cv_path_XARGS+:} false; then : 13063 $as_echo_n "(cached) " >&6 13064 else 13065 case $XARGS in 13066 [\\/]* | ?:[\\/]*) 13067 ac_cv_path_XARGS="$XARGS" # Let the user override the test with a path. 13068 ;; 13069 *) 13070 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 13071 for as_dir in $PATH 13072 do 13073 IFS=$as_save_IFS 13074 test -z "$as_dir" && as_dir=. 13075 for ac_exec_ext in '' $ac_executable_extensions; do 13076 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 13077 ac_cv_path_XARGS="$as_dir/$ac_word$ac_exec_ext" 13078 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 13079 break 2 13080 fi 13081 done 13082 done 13083 IFS=$as_save_IFS 13084 13085 ;; 13086 esac 13087 fi 13088 XARGS=$ac_cv_path_XARGS 13089 if test -n "$XARGS"; then 13090 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $XARGS" >&5 13091 $as_echo "$XARGS" >&6; } 13092 else 13093 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 13094 $as_echo "no" >&6; } 13095 fi 13096 13097 13098 test -n "$XARGS" && break 13099 done 13100 13101 else 13102 # If it succeeded, then it was overridden by the user. We will use it 13103 # for the tool. 13104 13105 # First remove it from the list of overridden variables, so we can test 13106 # for unknown variables in the end. 13107 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 13108 13109 # Check if we try to supply an empty value 13110 if test "x$XARGS" = x; then 13111 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool XARGS= (no value)" >&5 13112 $as_echo "$as_me: Setting user supplied tool XARGS= (no value)" >&6;} 13113 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for XARGS" >&5 13114 $as_echo_n "checking for XARGS... " >&6; } 13115 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 13116 $as_echo "disabled" >&6; } 13117 else 13118 # Check if the provided tool contains a complete path. 13119 tool_specified="$XARGS" 13120 tool_basename="${tool_specified##*/}" 13121 if test "x$tool_basename" = "x$tool_specified"; then 13122 # A command without a complete path is provided, search $PATH. 13123 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool XARGS=$tool_basename" >&5 13124 $as_echo "$as_me: Will search for user supplied tool XARGS=$tool_basename" >&6;} 13125 # Extract the first word of "$tool_basename", so it can be a program name with args. 13126 set dummy $tool_basename; ac_word=$2 13127 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 13128 $as_echo_n "checking for $ac_word... " >&6; } 13129 if ${ac_cv_path_XARGS+:} false; then : 13130 $as_echo_n "(cached) " >&6 13131 else 13132 case $XARGS in 13133 [\\/]* | ?:[\\/]*) 13134 ac_cv_path_XARGS="$XARGS" # Let the user override the test with a path. 13135 ;; 13136 *) 13137 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 13138 for as_dir in $PATH 13139 do 13140 IFS=$as_save_IFS 13141 test -z "$as_dir" && as_dir=. 13142 for ac_exec_ext in '' $ac_executable_extensions; do 13143 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 13144 ac_cv_path_XARGS="$as_dir/$ac_word$ac_exec_ext" 13145 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 13146 break 2 13147 fi 13148 done 13149 done 13150 IFS=$as_save_IFS 13151 13152 ;; 13153 esac 13154 fi 13155 XARGS=$ac_cv_path_XARGS 13156 if test -n "$XARGS"; then 13157 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $XARGS" >&5 13158 $as_echo "$XARGS" >&6; } 13159 else 13160 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 13161 $as_echo "no" >&6; } 13162 fi 13163 13164 13165 if test "x$XARGS" = x; then 13166 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 13167 fi 13168 else 13169 # Otherwise we believe it is a complete path. Use it as it is. 13170 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool XARGS=$tool_specified" >&5 13171 $as_echo "$as_me: Will use user supplied tool XARGS=$tool_specified" >&6;} 13172 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for XARGS" >&5 13173 $as_echo_n "checking for XARGS... " >&6; } 13174 if test ! -x "$tool_specified"; then 13175 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 13176 $as_echo "not found" >&6; } 13177 as_fn_error $? "User supplied tool XARGS=$tool_specified does not exist or is not executable" "$LINENO" 5 13178 fi 13179 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 13180 $as_echo "$tool_specified" >&6; } 13181 fi 13182 fi 13183 fi 13184 13185 fi 13186 13187 13188 13189 if test "x$XARGS" = x; then 13190 as_fn_error $? "Could not find required tool for XARGS" "$LINENO" 5 13191 fi 13192 13193 13194 13195 # Then required tools that require some special treatment. 13196 13197 13198 # Publish this variable in the help. 13199 13200 13201 if [ -z "${AWK+x}" ]; then 13202 # The variable is not set by user, try to locate tool using the code snippet 13203 for ac_prog in gawk mawk nawk awk 13204 do 13205 # Extract the first word of "$ac_prog", so it can be a program name with args. 13206 set dummy $ac_prog; ac_word=$2 13207 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 13208 $as_echo_n "checking for $ac_word... " >&6; } 13209 if ${ac_cv_prog_AWK+:} false; then : 13210 $as_echo_n "(cached) " >&6 13211 else 13212 if test -n "$AWK"; then 13213 ac_cv_prog_AWK="$AWK" # Let the user override the test. 13214 else 13215 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 13216 for as_dir in $PATH 13217 do 13218 IFS=$as_save_IFS 13219 test -z "$as_dir" && as_dir=. 13220 for ac_exec_ext in '' $ac_executable_extensions; do 13221 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 13222 ac_cv_prog_AWK="$ac_prog" 13223 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 13224 break 2 13225 fi 13226 done 13227 done 13228 IFS=$as_save_IFS 13229 13230 fi 13231 fi 13232 AWK=$ac_cv_prog_AWK 13233 if test -n "$AWK"; then 13234 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $AWK" >&5 13235 $as_echo "$AWK" >&6; } 13236 else 13237 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 13238 $as_echo "no" >&6; } 13239 fi 13240 13241 13242 test -n "$AWK" && break 13243 done 13244 13245 else 13246 # The variable is set, but is it from the command line or the environment? 13247 13248 # Try to remove the string !AWK! from our list. 13249 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!AWK!/} 13250 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 13251 # If it failed, the variable was not from the command line. Ignore it, 13252 # but warn the user (except for BASH, which is always set by the calling BASH). 13253 if test "xAWK" != xBASH; then 13254 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of AWK from the environment. Use command line variables instead." >&5 13255 $as_echo "$as_me: WARNING: Ignoring value of AWK from the environment. Use command line variables instead." >&2;} 13256 fi 13257 # Try to locate tool using the code snippet 13258 for ac_prog in gawk mawk nawk awk 13259 do 13260 # Extract the first word of "$ac_prog", so it can be a program name with args. 13261 set dummy $ac_prog; ac_word=$2 13262 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 13263 $as_echo_n "checking for $ac_word... " >&6; } 13264 if ${ac_cv_prog_AWK+:} false; then : 13265 $as_echo_n "(cached) " >&6 13266 else 13267 if test -n "$AWK"; then 13268 ac_cv_prog_AWK="$AWK" # Let the user override the test. 13269 else 13270 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 13271 for as_dir in $PATH 13272 do 13273 IFS=$as_save_IFS 13274 test -z "$as_dir" && as_dir=. 13275 for ac_exec_ext in '' $ac_executable_extensions; do 13276 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 13277 ac_cv_prog_AWK="$ac_prog" 13278 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 13279 break 2 13280 fi 13281 done 13282 done 13283 IFS=$as_save_IFS 13284 13285 fi 13286 fi 13287 AWK=$ac_cv_prog_AWK 13288 if test -n "$AWK"; then 13289 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $AWK" >&5 13290 $as_echo "$AWK" >&6; } 13291 else 13292 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 13293 $as_echo "no" >&6; } 13294 fi 13295 13296 13297 test -n "$AWK" && break 13298 done 13299 13300 else 13301 # If it succeeded, then it was overridden by the user. We will use it 13302 # for the tool. 13303 13304 # First remove it from the list of overridden variables, so we can test 13305 # for unknown variables in the end. 13306 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 13307 13308 # Check if we try to supply an empty value 13309 if test "x$AWK" = x; then 13310 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool AWK= (no value)" >&5 13311 $as_echo "$as_me: Setting user supplied tool AWK= (no value)" >&6;} 13312 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for AWK" >&5 13313 $as_echo_n "checking for AWK... " >&6; } 13314 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 13315 $as_echo "disabled" >&6; } 13316 else 13317 # Check if the provided tool contains a complete path. 13318 tool_specified="$AWK" 13319 tool_basename="${tool_specified##*/}" 13320 if test "x$tool_basename" = "x$tool_specified"; then 13321 # A command without a complete path is provided, search $PATH. 13322 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool AWK=$tool_basename" >&5 13323 $as_echo "$as_me: Will search for user supplied tool AWK=$tool_basename" >&6;} 13324 # Extract the first word of "$tool_basename", so it can be a program name with args. 13325 set dummy $tool_basename; ac_word=$2 13326 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 13327 $as_echo_n "checking for $ac_word... " >&6; } 13328 if ${ac_cv_path_AWK+:} false; then : 13329 $as_echo_n "(cached) " >&6 13330 else 13331 case $AWK in 13332 [\\/]* | ?:[\\/]*) 13333 ac_cv_path_AWK="$AWK" # Let the user override the test with a path. 13334 ;; 13335 *) 13336 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 13337 for as_dir in $PATH 13338 do 13339 IFS=$as_save_IFS 13340 test -z "$as_dir" && as_dir=. 13341 for ac_exec_ext in '' $ac_executable_extensions; do 13342 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 13343 ac_cv_path_AWK="$as_dir/$ac_word$ac_exec_ext" 13344 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 13345 break 2 13346 fi 13347 done 13348 done 13349 IFS=$as_save_IFS 13350 13351 ;; 13352 esac 13353 fi 13354 AWK=$ac_cv_path_AWK 13355 if test -n "$AWK"; then 13356 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $AWK" >&5 13357 $as_echo "$AWK" >&6; } 13358 else 13359 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 13360 $as_echo "no" >&6; } 13361 fi 13362 13363 13364 if test "x$AWK" = x; then 13365 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 13366 fi 13367 else 13368 # Otherwise we believe it is a complete path. Use it as it is. 13369 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool AWK=$tool_specified" >&5 13370 $as_echo "$as_me: Will use user supplied tool AWK=$tool_specified" >&6;} 13371 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for AWK" >&5 13372 $as_echo_n "checking for AWK... " >&6; } 13373 if test ! -x "$tool_specified"; then 13374 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 13375 $as_echo "not found" >&6; } 13376 as_fn_error $? "User supplied tool AWK=$tool_specified does not exist or is not executable" "$LINENO" 5 13377 fi 13378 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 13379 $as_echo "$tool_specified" >&6; } 13380 fi 13381 fi 13382 fi 13383 13384 fi 13385 13386 13387 if test "x$AWK" = x; then 13388 as_fn_error $? "Could not find required tool for AWK" "$LINENO" 5 13389 fi 13390 13391 13392 13393 13394 # Publish this variable in the help. 13395 13396 13397 if [ -z "${GREP+x}" ]; then 13398 # The variable is not set by user, try to locate tool using the code snippet 13399 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for grep that handles long lines and -e" >&5 13400 $as_echo_n "checking for grep that handles long lines and -e... " >&6; } 13401 if ${ac_cv_path_GREP+:} false; then : 13402 $as_echo_n "(cached) " >&6 13403 else 13404 if test -z "$GREP"; then 13405 ac_path_GREP_found=false 13406 # Loop through the user's path and test for each of PROGNAME-LIST 13407 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 13408 for as_dir in $PATH$PATH_SEPARATOR/usr/xpg4/bin 13409 do 13410 IFS=$as_save_IFS 13411 test -z "$as_dir" && as_dir=. 13412 for ac_prog in grep ggrep; do 13413 for ac_exec_ext in '' $ac_executable_extensions; do 13414 ac_path_GREP="$as_dir/$ac_prog$ac_exec_ext" 13415 as_fn_executable_p "$ac_path_GREP" || continue 13416 # Check for GNU ac_path_GREP and select it if it is found. 13417 # Check for GNU $ac_path_GREP 13418 case `"$ac_path_GREP" --version 2>&1` in 13419 *GNU*) 13420 ac_cv_path_GREP="$ac_path_GREP" ac_path_GREP_found=:;; 13421 *) 13422 ac_count=0 13423 $as_echo_n 0123456789 >"conftest.in" 13424 while : 13425 do 13426 cat "conftest.in" "conftest.in" >"conftest.tmp" 13427 mv "conftest.tmp" "conftest.in" 13428 cp "conftest.in" "conftest.nl" 13429 $as_echo 'GREP' >> "conftest.nl" 13430 "$ac_path_GREP" -e 'GREP$' -e '-(cannot match)-' < "conftest.nl" >"conftest.out" 2>/dev/null || break 13431 diff "conftest.out" "conftest.nl" >/dev/null 2>&1 || break 13432 as_fn_arith $ac_count + 1 && ac_count=$as_val 13433 if test $ac_count -gt ${ac_path_GREP_max-0}; then 13434 # Best one so far, save it but keep looking for a better one 13435 ac_cv_path_GREP="$ac_path_GREP" 13436 ac_path_GREP_max=$ac_count 13437 fi 13438 # 10*(2^10) chars as input seems more than enough 13439 test $ac_count -gt 10 && break 13440 done 13441 rm -f conftest.in conftest.tmp conftest.nl conftest.out;; 13442 esac 13443 13444 $ac_path_GREP_found && break 3 13445 done 13446 done 13447 done 13448 IFS=$as_save_IFS 13449 if test -z "$ac_cv_path_GREP"; then 13450 as_fn_error $? "no acceptable grep could be found in $PATH$PATH_SEPARATOR/usr/xpg4/bin" "$LINENO" 5 13451 fi 13452 else 13453 ac_cv_path_GREP=$GREP 13454 fi 13455 13456 fi 13457 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_path_GREP" >&5 13458 $as_echo "$ac_cv_path_GREP" >&6; } 13459 GREP="$ac_cv_path_GREP" 13460 13461 13462 else 13463 # The variable is set, but is it from the command line or the environment? 13464 13465 # Try to remove the string !GREP! from our list. 13466 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!GREP!/} 13467 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 13468 # If it failed, the variable was not from the command line. Ignore it, 13469 # but warn the user (except for BASH, which is always set by the calling BASH). 13470 if test "xGREP" != xBASH; then 13471 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of GREP from the environment. Use command line variables instead." >&5 13472 $as_echo "$as_me: WARNING: Ignoring value of GREP from the environment. Use command line variables instead." >&2;} 13473 fi 13474 # Try to locate tool using the code snippet 13475 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for grep that handles long lines and -e" >&5 13476 $as_echo_n "checking for grep that handles long lines and -e... " >&6; } 13477 if ${ac_cv_path_GREP+:} false; then : 13478 $as_echo_n "(cached) " >&6 13479 else 13480 if test -z "$GREP"; then 13481 ac_path_GREP_found=false 13482 # Loop through the user's path and test for each of PROGNAME-LIST 13483 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 13484 for as_dir in $PATH$PATH_SEPARATOR/usr/xpg4/bin 13485 do 13486 IFS=$as_save_IFS 13487 test -z "$as_dir" && as_dir=. 13488 for ac_prog in grep ggrep; do 13489 for ac_exec_ext in '' $ac_executable_extensions; do 13490 ac_path_GREP="$as_dir/$ac_prog$ac_exec_ext" 13491 as_fn_executable_p "$ac_path_GREP" || continue 13492 # Check for GNU ac_path_GREP and select it if it is found. 13493 # Check for GNU $ac_path_GREP 13494 case `"$ac_path_GREP" --version 2>&1` in 13495 *GNU*) 13496 ac_cv_path_GREP="$ac_path_GREP" ac_path_GREP_found=:;; 13497 *) 13498 ac_count=0 13499 $as_echo_n 0123456789 >"conftest.in" 13500 while : 13501 do 13502 cat "conftest.in" "conftest.in" >"conftest.tmp" 13503 mv "conftest.tmp" "conftest.in" 13504 cp "conftest.in" "conftest.nl" 13505 $as_echo 'GREP' >> "conftest.nl" 13506 "$ac_path_GREP" -e 'GREP$' -e '-(cannot match)-' < "conftest.nl" >"conftest.out" 2>/dev/null || break 13507 diff "conftest.out" "conftest.nl" >/dev/null 2>&1 || break 13508 as_fn_arith $ac_count + 1 && ac_count=$as_val 13509 if test $ac_count -gt ${ac_path_GREP_max-0}; then 13510 # Best one so far, save it but keep looking for a better one 13511 ac_cv_path_GREP="$ac_path_GREP" 13512 ac_path_GREP_max=$ac_count 13513 fi 13514 # 10*(2^10) chars as input seems more than enough 13515 test $ac_count -gt 10 && break 13516 done 13517 rm -f conftest.in conftest.tmp conftest.nl conftest.out;; 13518 esac 13519 13520 $ac_path_GREP_found && break 3 13521 done 13522 done 13523 done 13524 IFS=$as_save_IFS 13525 if test -z "$ac_cv_path_GREP"; then 13526 as_fn_error $? "no acceptable grep could be found in $PATH$PATH_SEPARATOR/usr/xpg4/bin" "$LINENO" 5 13527 fi 13528 else 13529 ac_cv_path_GREP=$GREP 13530 fi 13531 13532 fi 13533 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_path_GREP" >&5 13534 $as_echo "$ac_cv_path_GREP" >&6; } 13535 GREP="$ac_cv_path_GREP" 13536 13537 13538 else 13539 # If it succeeded, then it was overridden by the user. We will use it 13540 # for the tool. 13541 13542 # First remove it from the list of overridden variables, so we can test 13543 # for unknown variables in the end. 13544 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 13545 13546 # Check if we try to supply an empty value 13547 if test "x$GREP" = x; then 13548 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool GREP= (no value)" >&5 13549 $as_echo "$as_me: Setting user supplied tool GREP= (no value)" >&6;} 13550 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for GREP" >&5 13551 $as_echo_n "checking for GREP... " >&6; } 13552 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 13553 $as_echo "disabled" >&6; } 13554 else 13555 # Check if the provided tool contains a complete path. 13556 tool_specified="$GREP" 13557 tool_basename="${tool_specified##*/}" 13558 if test "x$tool_basename" = "x$tool_specified"; then 13559 # A command without a complete path is provided, search $PATH. 13560 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool GREP=$tool_basename" >&5 13561 $as_echo "$as_me: Will search for user supplied tool GREP=$tool_basename" >&6;} 13562 # Extract the first word of "$tool_basename", so it can be a program name with args. 13563 set dummy $tool_basename; ac_word=$2 13564 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 13565 $as_echo_n "checking for $ac_word... " >&6; } 13566 if ${ac_cv_path_GREP+:} false; then : 13567 $as_echo_n "(cached) " >&6 13568 else 13569 case $GREP in 13570 [\\/]* | ?:[\\/]*) 13571 ac_cv_path_GREP="$GREP" # Let the user override the test with a path. 13572 ;; 13573 *) 13574 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 13575 for as_dir in $PATH 13576 do 13577 IFS=$as_save_IFS 13578 test -z "$as_dir" && as_dir=. 13579 for ac_exec_ext in '' $ac_executable_extensions; do 13580 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 13581 ac_cv_path_GREP="$as_dir/$ac_word$ac_exec_ext" 13582 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 13583 break 2 13584 fi 13585 done 13586 done 13587 IFS=$as_save_IFS 13588 13589 ;; 13590 esac 13591 fi 13592 GREP=$ac_cv_path_GREP 13593 if test -n "$GREP"; then 13594 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $GREP" >&5 13595 $as_echo "$GREP" >&6; } 13596 else 13597 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 13598 $as_echo "no" >&6; } 13599 fi 13600 13601 13602 if test "x$GREP" = x; then 13603 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 13604 fi 13605 else 13606 # Otherwise we believe it is a complete path. Use it as it is. 13607 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool GREP=$tool_specified" >&5 13608 $as_echo "$as_me: Will use user supplied tool GREP=$tool_specified" >&6;} 13609 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for GREP" >&5 13610 $as_echo_n "checking for GREP... " >&6; } 13611 if test ! -x "$tool_specified"; then 13612 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 13613 $as_echo "not found" >&6; } 13614 as_fn_error $? "User supplied tool GREP=$tool_specified does not exist or is not executable" "$LINENO" 5 13615 fi 13616 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 13617 $as_echo "$tool_specified" >&6; } 13618 fi 13619 fi 13620 fi 13621 13622 fi 13623 13624 13625 if test "x$GREP" = x; then 13626 as_fn_error $? "Could not find required tool for GREP" "$LINENO" 5 13627 fi 13628 13629 13630 13631 13632 # Publish this variable in the help. 13633 13634 13635 if [ -z "${EGREP+x}" ]; then 13636 # The variable is not set by user, try to locate tool using the code snippet 13637 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for egrep" >&5 13638 $as_echo_n "checking for egrep... " >&6; } 13639 if ${ac_cv_path_EGREP+:} false; then : 13640 $as_echo_n "(cached) " >&6 13641 else 13642 if echo a | $GREP -E '(a|b)' >/dev/null 2>&1 13643 then ac_cv_path_EGREP="$GREP -E" 13644 else 13645 if test -z "$EGREP"; then 13646 ac_path_EGREP_found=false 13647 # Loop through the user's path and test for each of PROGNAME-LIST 13648 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 13649 for as_dir in $PATH$PATH_SEPARATOR/usr/xpg4/bin 13650 do 13651 IFS=$as_save_IFS 13652 test -z "$as_dir" && as_dir=. 13653 for ac_prog in egrep; do 13654 for ac_exec_ext in '' $ac_executable_extensions; do 13655 ac_path_EGREP="$as_dir/$ac_prog$ac_exec_ext" 13656 as_fn_executable_p "$ac_path_EGREP" || continue 13657 # Check for GNU ac_path_EGREP and select it if it is found. 13658 # Check for GNU $ac_path_EGREP 13659 case `"$ac_path_EGREP" --version 2>&1` in 13660 *GNU*) 13661 ac_cv_path_EGREP="$ac_path_EGREP" ac_path_EGREP_found=:;; 13662 *) 13663 ac_count=0 13664 $as_echo_n 0123456789 >"conftest.in" 13665 while : 13666 do 13667 cat "conftest.in" "conftest.in" >"conftest.tmp" 13668 mv "conftest.tmp" "conftest.in" 13669 cp "conftest.in" "conftest.nl" 13670 $as_echo 'EGREP' >> "conftest.nl" 13671 "$ac_path_EGREP" 'EGREP$' < "conftest.nl" >"conftest.out" 2>/dev/null || break 13672 diff "conftest.out" "conftest.nl" >/dev/null 2>&1 || break 13673 as_fn_arith $ac_count + 1 && ac_count=$as_val 13674 if test $ac_count -gt ${ac_path_EGREP_max-0}; then 13675 # Best one so far, save it but keep looking for a better one 13676 ac_cv_path_EGREP="$ac_path_EGREP" 13677 ac_path_EGREP_max=$ac_count 13678 fi 13679 # 10*(2^10) chars as input seems more than enough 13680 test $ac_count -gt 10 && break 13681 done 13682 rm -f conftest.in conftest.tmp conftest.nl conftest.out;; 13683 esac 13684 13685 $ac_path_EGREP_found && break 3 13686 done 13687 done 13688 done 13689 IFS=$as_save_IFS 13690 if test -z "$ac_cv_path_EGREP"; then 13691 as_fn_error $? "no acceptable egrep could be found in $PATH$PATH_SEPARATOR/usr/xpg4/bin" "$LINENO" 5 13692 fi 13693 else 13694 ac_cv_path_EGREP=$EGREP 13695 fi 13696 13697 fi 13698 fi 13699 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_path_EGREP" >&5 13700 $as_echo "$ac_cv_path_EGREP" >&6; } 13701 EGREP="$ac_cv_path_EGREP" 13702 13703 13704 else 13705 # The variable is set, but is it from the command line or the environment? 13706 13707 # Try to remove the string !EGREP! from our list. 13708 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!EGREP!/} 13709 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 13710 # If it failed, the variable was not from the command line. Ignore it, 13711 # but warn the user (except for BASH, which is always set by the calling BASH). 13712 if test "xEGREP" != xBASH; then 13713 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of EGREP from the environment. Use command line variables instead." >&5 13714 $as_echo "$as_me: WARNING: Ignoring value of EGREP from the environment. Use command line variables instead." >&2;} 13715 fi 13716 # Try to locate tool using the code snippet 13717 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for egrep" >&5 13718 $as_echo_n "checking for egrep... " >&6; } 13719 if ${ac_cv_path_EGREP+:} false; then : 13720 $as_echo_n "(cached) " >&6 13721 else 13722 if echo a | $GREP -E '(a|b)' >/dev/null 2>&1 13723 then ac_cv_path_EGREP="$GREP -E" 13724 else 13725 if test -z "$EGREP"; then 13726 ac_path_EGREP_found=false 13727 # Loop through the user's path and test for each of PROGNAME-LIST 13728 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 13729 for as_dir in $PATH$PATH_SEPARATOR/usr/xpg4/bin 13730 do 13731 IFS=$as_save_IFS 13732 test -z "$as_dir" && as_dir=. 13733 for ac_prog in egrep; do 13734 for ac_exec_ext in '' $ac_executable_extensions; do 13735 ac_path_EGREP="$as_dir/$ac_prog$ac_exec_ext" 13736 as_fn_executable_p "$ac_path_EGREP" || continue 13737 # Check for GNU ac_path_EGREP and select it if it is found. 13738 # Check for GNU $ac_path_EGREP 13739 case `"$ac_path_EGREP" --version 2>&1` in 13740 *GNU*) 13741 ac_cv_path_EGREP="$ac_path_EGREP" ac_path_EGREP_found=:;; 13742 *) 13743 ac_count=0 13744 $as_echo_n 0123456789 >"conftest.in" 13745 while : 13746 do 13747 cat "conftest.in" "conftest.in" >"conftest.tmp" 13748 mv "conftest.tmp" "conftest.in" 13749 cp "conftest.in" "conftest.nl" 13750 $as_echo 'EGREP' >> "conftest.nl" 13751 "$ac_path_EGREP" 'EGREP$' < "conftest.nl" >"conftest.out" 2>/dev/null || break 13752 diff "conftest.out" "conftest.nl" >/dev/null 2>&1 || break 13753 as_fn_arith $ac_count + 1 && ac_count=$as_val 13754 if test $ac_count -gt ${ac_path_EGREP_max-0}; then 13755 # Best one so far, save it but keep looking for a better one 13756 ac_cv_path_EGREP="$ac_path_EGREP" 13757 ac_path_EGREP_max=$ac_count 13758 fi 13759 # 10*(2^10) chars as input seems more than enough 13760 test $ac_count -gt 10 && break 13761 done 13762 rm -f conftest.in conftest.tmp conftest.nl conftest.out;; 13763 esac 13764 13765 $ac_path_EGREP_found && break 3 13766 done 13767 done 13768 done 13769 IFS=$as_save_IFS 13770 if test -z "$ac_cv_path_EGREP"; then 13771 as_fn_error $? "no acceptable egrep could be found in $PATH$PATH_SEPARATOR/usr/xpg4/bin" "$LINENO" 5 13772 fi 13773 else 13774 ac_cv_path_EGREP=$EGREP 13775 fi 13776 13777 fi 13778 fi 13779 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_path_EGREP" >&5 13780 $as_echo "$ac_cv_path_EGREP" >&6; } 13781 EGREP="$ac_cv_path_EGREP" 13782 13783 13784 else 13785 # If it succeeded, then it was overridden by the user. We will use it 13786 # for the tool. 13787 13788 # First remove it from the list of overridden variables, so we can test 13789 # for unknown variables in the end. 13790 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 13791 13792 # Check if we try to supply an empty value 13793 if test "x$EGREP" = x; then 13794 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool EGREP= (no value)" >&5 13795 $as_echo "$as_me: Setting user supplied tool EGREP= (no value)" >&6;} 13796 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for EGREP" >&5 13797 $as_echo_n "checking for EGREP... " >&6; } 13798 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 13799 $as_echo "disabled" >&6; } 13800 else 13801 # Check if the provided tool contains a complete path. 13802 tool_specified="$EGREP" 13803 tool_basename="${tool_specified##*/}" 13804 if test "x$tool_basename" = "x$tool_specified"; then 13805 # A command without a complete path is provided, search $PATH. 13806 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool EGREP=$tool_basename" >&5 13807 $as_echo "$as_me: Will search for user supplied tool EGREP=$tool_basename" >&6;} 13808 # Extract the first word of "$tool_basename", so it can be a program name with args. 13809 set dummy $tool_basename; ac_word=$2 13810 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 13811 $as_echo_n "checking for $ac_word... " >&6; } 13812 if ${ac_cv_path_EGREP+:} false; then : 13813 $as_echo_n "(cached) " >&6 13814 else 13815 case $EGREP in 13816 [\\/]* | ?:[\\/]*) 13817 ac_cv_path_EGREP="$EGREP" # Let the user override the test with a path. 13818 ;; 13819 *) 13820 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 13821 for as_dir in $PATH 13822 do 13823 IFS=$as_save_IFS 13824 test -z "$as_dir" && as_dir=. 13825 for ac_exec_ext in '' $ac_executable_extensions; do 13826 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 13827 ac_cv_path_EGREP="$as_dir/$ac_word$ac_exec_ext" 13828 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 13829 break 2 13830 fi 13831 done 13832 done 13833 IFS=$as_save_IFS 13834 13835 ;; 13836 esac 13837 fi 13838 EGREP=$ac_cv_path_EGREP 13839 if test -n "$EGREP"; then 13840 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $EGREP" >&5 13841 $as_echo "$EGREP" >&6; } 13842 else 13843 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 13844 $as_echo "no" >&6; } 13845 fi 13846 13847 13848 if test "x$EGREP" = x; then 13849 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 13850 fi 13851 else 13852 # Otherwise we believe it is a complete path. Use it as it is. 13853 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool EGREP=$tool_specified" >&5 13854 $as_echo "$as_me: Will use user supplied tool EGREP=$tool_specified" >&6;} 13855 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for EGREP" >&5 13856 $as_echo_n "checking for EGREP... " >&6; } 13857 if test ! -x "$tool_specified"; then 13858 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 13859 $as_echo "not found" >&6; } 13860 as_fn_error $? "User supplied tool EGREP=$tool_specified does not exist or is not executable" "$LINENO" 5 13861 fi 13862 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 13863 $as_echo "$tool_specified" >&6; } 13864 fi 13865 fi 13866 fi 13867 13868 fi 13869 13870 13871 if test "x$EGREP" = x; then 13872 as_fn_error $? "Could not find required tool for EGREP" "$LINENO" 5 13873 fi 13874 13875 13876 13877 13878 # Publish this variable in the help. 13879 13880 13881 if [ -z "${FGREP+x}" ]; then 13882 # The variable is not set by user, try to locate tool using the code snippet 13883 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for fgrep" >&5 13884 $as_echo_n "checking for fgrep... " >&6; } 13885 if ${ac_cv_path_FGREP+:} false; then : 13886 $as_echo_n "(cached) " >&6 13887 else 13888 if echo 'ab*c' | $GREP -F 'ab*c' >/dev/null 2>&1 13889 then ac_cv_path_FGREP="$GREP -F" 13890 else 13891 if test -z "$FGREP"; then 13892 ac_path_FGREP_found=false 13893 # Loop through the user's path and test for each of PROGNAME-LIST 13894 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 13895 for as_dir in $PATH$PATH_SEPARATOR/usr/xpg4/bin 13896 do 13897 IFS=$as_save_IFS 13898 test -z "$as_dir" && as_dir=. 13899 for ac_prog in fgrep; do 13900 for ac_exec_ext in '' $ac_executable_extensions; do 13901 ac_path_FGREP="$as_dir/$ac_prog$ac_exec_ext" 13902 as_fn_executable_p "$ac_path_FGREP" || continue 13903 # Check for GNU ac_path_FGREP and select it if it is found. 13904 # Check for GNU $ac_path_FGREP 13905 case `"$ac_path_FGREP" --version 2>&1` in 13906 *GNU*) 13907 ac_cv_path_FGREP="$ac_path_FGREP" ac_path_FGREP_found=:;; 13908 *) 13909 ac_count=0 13910 $as_echo_n 0123456789 >"conftest.in" 13911 while : 13912 do 13913 cat "conftest.in" "conftest.in" >"conftest.tmp" 13914 mv "conftest.tmp" "conftest.in" 13915 cp "conftest.in" "conftest.nl" 13916 $as_echo 'FGREP' >> "conftest.nl" 13917 "$ac_path_FGREP" FGREP < "conftest.nl" >"conftest.out" 2>/dev/null || break 13918 diff "conftest.out" "conftest.nl" >/dev/null 2>&1 || break 13919 as_fn_arith $ac_count + 1 && ac_count=$as_val 13920 if test $ac_count -gt ${ac_path_FGREP_max-0}; then 13921 # Best one so far, save it but keep looking for a better one 13922 ac_cv_path_FGREP="$ac_path_FGREP" 13923 ac_path_FGREP_max=$ac_count 13924 fi 13925 # 10*(2^10) chars as input seems more than enough 13926 test $ac_count -gt 10 && break 13927 done 13928 rm -f conftest.in conftest.tmp conftest.nl conftest.out;; 13929 esac 13930 13931 $ac_path_FGREP_found && break 3 13932 done 13933 done 13934 done 13935 IFS=$as_save_IFS 13936 if test -z "$ac_cv_path_FGREP"; then 13937 as_fn_error $? "no acceptable fgrep could be found in $PATH$PATH_SEPARATOR/usr/xpg4/bin" "$LINENO" 5 13938 fi 13939 else 13940 ac_cv_path_FGREP=$FGREP 13941 fi 13942 13943 fi 13944 fi 13945 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_path_FGREP" >&5 13946 $as_echo "$ac_cv_path_FGREP" >&6; } 13947 FGREP="$ac_cv_path_FGREP" 13948 13949 13950 else 13951 # The variable is set, but is it from the command line or the environment? 13952 13953 # Try to remove the string !FGREP! from our list. 13954 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!FGREP!/} 13955 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 13956 # If it failed, the variable was not from the command line. Ignore it, 13957 # but warn the user (except for BASH, which is always set by the calling BASH). 13958 if test "xFGREP" != xBASH; then 13959 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of FGREP from the environment. Use command line variables instead." >&5 13960 $as_echo "$as_me: WARNING: Ignoring value of FGREP from the environment. Use command line variables instead." >&2;} 13961 fi 13962 # Try to locate tool using the code snippet 13963 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for fgrep" >&5 13964 $as_echo_n "checking for fgrep... " >&6; } 13965 if ${ac_cv_path_FGREP+:} false; then : 13966 $as_echo_n "(cached) " >&6 13967 else 13968 if echo 'ab*c' | $GREP -F 'ab*c' >/dev/null 2>&1 13969 then ac_cv_path_FGREP="$GREP -F" 13970 else 13971 if test -z "$FGREP"; then 13972 ac_path_FGREP_found=false 13973 # Loop through the user's path and test for each of PROGNAME-LIST 13974 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 13975 for as_dir in $PATH$PATH_SEPARATOR/usr/xpg4/bin 13976 do 13977 IFS=$as_save_IFS 13978 test -z "$as_dir" && as_dir=. 13979 for ac_prog in fgrep; do 13980 for ac_exec_ext in '' $ac_executable_extensions; do 13981 ac_path_FGREP="$as_dir/$ac_prog$ac_exec_ext" 13982 as_fn_executable_p "$ac_path_FGREP" || continue 13983 # Check for GNU ac_path_FGREP and select it if it is found. 13984 # Check for GNU $ac_path_FGREP 13985 case `"$ac_path_FGREP" --version 2>&1` in 13986 *GNU*) 13987 ac_cv_path_FGREP="$ac_path_FGREP" ac_path_FGREP_found=:;; 13988 *) 13989 ac_count=0 13990 $as_echo_n 0123456789 >"conftest.in" 13991 while : 13992 do 13993 cat "conftest.in" "conftest.in" >"conftest.tmp" 13994 mv "conftest.tmp" "conftest.in" 13995 cp "conftest.in" "conftest.nl" 13996 $as_echo 'FGREP' >> "conftest.nl" 13997 "$ac_path_FGREP" FGREP < "conftest.nl" >"conftest.out" 2>/dev/null || break 13998 diff "conftest.out" "conftest.nl" >/dev/null 2>&1 || break 13999 as_fn_arith $ac_count + 1 && ac_count=$as_val 14000 if test $ac_count -gt ${ac_path_FGREP_max-0}; then 14001 # Best one so far, save it but keep looking for a better one 14002 ac_cv_path_FGREP="$ac_path_FGREP" 14003 ac_path_FGREP_max=$ac_count 14004 fi 14005 # 10*(2^10) chars as input seems more than enough 14006 test $ac_count -gt 10 && break 14007 done 14008 rm -f conftest.in conftest.tmp conftest.nl conftest.out;; 14009 esac 14010 14011 $ac_path_FGREP_found && break 3 14012 done 14013 done 14014 done 14015 IFS=$as_save_IFS 14016 if test -z "$ac_cv_path_FGREP"; then 14017 as_fn_error $? "no acceptable fgrep could be found in $PATH$PATH_SEPARATOR/usr/xpg4/bin" "$LINENO" 5 14018 fi 14019 else 14020 ac_cv_path_FGREP=$FGREP 14021 fi 14022 14023 fi 14024 fi 14025 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_path_FGREP" >&5 14026 $as_echo "$ac_cv_path_FGREP" >&6; } 14027 FGREP="$ac_cv_path_FGREP" 14028 14029 14030 else 14031 # If it succeeded, then it was overridden by the user. We will use it 14032 # for the tool. 14033 14034 # First remove it from the list of overridden variables, so we can test 14035 # for unknown variables in the end. 14036 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 14037 14038 # Check if we try to supply an empty value 14039 if test "x$FGREP" = x; then 14040 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool FGREP= (no value)" >&5 14041 $as_echo "$as_me: Setting user supplied tool FGREP= (no value)" >&6;} 14042 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for FGREP" >&5 14043 $as_echo_n "checking for FGREP... " >&6; } 14044 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 14045 $as_echo "disabled" >&6; } 14046 else 14047 # Check if the provided tool contains a complete path. 14048 tool_specified="$FGREP" 14049 tool_basename="${tool_specified##*/}" 14050 if test "x$tool_basename" = "x$tool_specified"; then 14051 # A command without a complete path is provided, search $PATH. 14052 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool FGREP=$tool_basename" >&5 14053 $as_echo "$as_me: Will search for user supplied tool FGREP=$tool_basename" >&6;} 14054 # Extract the first word of "$tool_basename", so it can be a program name with args. 14055 set dummy $tool_basename; ac_word=$2 14056 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 14057 $as_echo_n "checking for $ac_word... " >&6; } 14058 if ${ac_cv_path_FGREP+:} false; then : 14059 $as_echo_n "(cached) " >&6 14060 else 14061 case $FGREP in 14062 [\\/]* | ?:[\\/]*) 14063 ac_cv_path_FGREP="$FGREP" # Let the user override the test with a path. 14064 ;; 14065 *) 14066 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 14067 for as_dir in $PATH 14068 do 14069 IFS=$as_save_IFS 14070 test -z "$as_dir" && as_dir=. 14071 for ac_exec_ext in '' $ac_executable_extensions; do 14072 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 14073 ac_cv_path_FGREP="$as_dir/$ac_word$ac_exec_ext" 14074 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 14075 break 2 14076 fi 14077 done 14078 done 14079 IFS=$as_save_IFS 14080 14081 ;; 14082 esac 14083 fi 14084 FGREP=$ac_cv_path_FGREP 14085 if test -n "$FGREP"; then 14086 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $FGREP" >&5 14087 $as_echo "$FGREP" >&6; } 14088 else 14089 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 14090 $as_echo "no" >&6; } 14091 fi 14092 14093 14094 if test "x$FGREP" = x; then 14095 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 14096 fi 14097 else 14098 # Otherwise we believe it is a complete path. Use it as it is. 14099 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool FGREP=$tool_specified" >&5 14100 $as_echo "$as_me: Will use user supplied tool FGREP=$tool_specified" >&6;} 14101 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for FGREP" >&5 14102 $as_echo_n "checking for FGREP... " >&6; } 14103 if test ! -x "$tool_specified"; then 14104 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 14105 $as_echo "not found" >&6; } 14106 as_fn_error $? "User supplied tool FGREP=$tool_specified does not exist or is not executable" "$LINENO" 5 14107 fi 14108 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 14109 $as_echo "$tool_specified" >&6; } 14110 fi 14111 fi 14112 fi 14113 14114 fi 14115 14116 14117 if test "x$FGREP" = x; then 14118 as_fn_error $? "Could not find required tool for FGREP" "$LINENO" 5 14119 fi 14120 14121 14122 14123 14124 # Publish this variable in the help. 14125 14126 14127 if [ -z "${SED+x}" ]; then 14128 # The variable is not set by user, try to locate tool using the code snippet 14129 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for a sed that does not truncate output" >&5 14130 $as_echo_n "checking for a sed that does not truncate output... " >&6; } 14131 if ${ac_cv_path_SED+:} false; then : 14132 $as_echo_n "(cached) " >&6 14133 else 14134 ac_script=s/aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa/bbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbb/ 14135 for ac_i in 1 2 3 4 5 6 7; do 14136 ac_script="$ac_script$as_nl$ac_script" 14137 done 14138 echo "$ac_script" 2>/dev/null | sed 99q >conftest.sed 14139 { ac_script=; unset ac_script;} 14140 if test -z "$SED"; then 14141 ac_path_SED_found=false 14142 # Loop through the user's path and test for each of PROGNAME-LIST 14143 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 14144 for as_dir in $PATH 14145 do 14146 IFS=$as_save_IFS 14147 test -z "$as_dir" && as_dir=. 14148 for ac_prog in sed gsed; do 14149 for ac_exec_ext in '' $ac_executable_extensions; do 14150 ac_path_SED="$as_dir/$ac_prog$ac_exec_ext" 14151 as_fn_executable_p "$ac_path_SED" || continue 14152 # Check for GNU ac_path_SED and select it if it is found. 14153 # Check for GNU $ac_path_SED 14154 case `"$ac_path_SED" --version 2>&1` in 14155 *GNU*) 14156 ac_cv_path_SED="$ac_path_SED" ac_path_SED_found=:;; 14157 *) 14158 ac_count=0 14159 $as_echo_n 0123456789 >"conftest.in" 14160 while : 14161 do 14162 cat "conftest.in" "conftest.in" >"conftest.tmp" 14163 mv "conftest.tmp" "conftest.in" 14164 cp "conftest.in" "conftest.nl" 14165 $as_echo '' >> "conftest.nl" 14166 "$ac_path_SED" -f conftest.sed < "conftest.nl" >"conftest.out" 2>/dev/null || break 14167 diff "conftest.out" "conftest.nl" >/dev/null 2>&1 || break 14168 as_fn_arith $ac_count + 1 && ac_count=$as_val 14169 if test $ac_count -gt ${ac_path_SED_max-0}; then 14170 # Best one so far, save it but keep looking for a better one 14171 ac_cv_path_SED="$ac_path_SED" 14172 ac_path_SED_max=$ac_count 14173 fi 14174 # 10*(2^10) chars as input seems more than enough 14175 test $ac_count -gt 10 && break 14176 done 14177 rm -f conftest.in conftest.tmp conftest.nl conftest.out;; 14178 esac 14179 14180 $ac_path_SED_found && break 3 14181 done 14182 done 14183 done 14184 IFS=$as_save_IFS 14185 if test -z "$ac_cv_path_SED"; then 14186 as_fn_error $? "no acceptable sed could be found in \$PATH" "$LINENO" 5 14187 fi 14188 else 14189 ac_cv_path_SED=$SED 14190 fi 14191 14192 fi 14193 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_path_SED" >&5 14194 $as_echo "$ac_cv_path_SED" >&6; } 14195 SED="$ac_cv_path_SED" 14196 rm -f conftest.sed 14197 14198 else 14199 # The variable is set, but is it from the command line or the environment? 14200 14201 # Try to remove the string !SED! from our list. 14202 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!SED!/} 14203 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 14204 # If it failed, the variable was not from the command line. Ignore it, 14205 # but warn the user (except for BASH, which is always set by the calling BASH). 14206 if test "xSED" != xBASH; then 14207 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of SED from the environment. Use command line variables instead." >&5 14208 $as_echo "$as_me: WARNING: Ignoring value of SED from the environment. Use command line variables instead." >&2;} 14209 fi 14210 # Try to locate tool using the code snippet 14211 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for a sed that does not truncate output" >&5 14212 $as_echo_n "checking for a sed that does not truncate output... " >&6; } 14213 if ${ac_cv_path_SED+:} false; then : 14214 $as_echo_n "(cached) " >&6 14215 else 14216 ac_script=s/aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa/bbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbb/ 14217 for ac_i in 1 2 3 4 5 6 7; do 14218 ac_script="$ac_script$as_nl$ac_script" 14219 done 14220 echo "$ac_script" 2>/dev/null | sed 99q >conftest.sed 14221 { ac_script=; unset ac_script;} 14222 if test -z "$SED"; then 14223 ac_path_SED_found=false 14224 # Loop through the user's path and test for each of PROGNAME-LIST 14225 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 14226 for as_dir in $PATH 14227 do 14228 IFS=$as_save_IFS 14229 test -z "$as_dir" && as_dir=. 14230 for ac_prog in sed gsed; do 14231 for ac_exec_ext in '' $ac_executable_extensions; do 14232 ac_path_SED="$as_dir/$ac_prog$ac_exec_ext" 14233 as_fn_executable_p "$ac_path_SED" || continue 14234 # Check for GNU ac_path_SED and select it if it is found. 14235 # Check for GNU $ac_path_SED 14236 case `"$ac_path_SED" --version 2>&1` in 14237 *GNU*) 14238 ac_cv_path_SED="$ac_path_SED" ac_path_SED_found=:;; 14239 *) 14240 ac_count=0 14241 $as_echo_n 0123456789 >"conftest.in" 14242 while : 14243 do 14244 cat "conftest.in" "conftest.in" >"conftest.tmp" 14245 mv "conftest.tmp" "conftest.in" 14246 cp "conftest.in" "conftest.nl" 14247 $as_echo '' >> "conftest.nl" 14248 "$ac_path_SED" -f conftest.sed < "conftest.nl" >"conftest.out" 2>/dev/null || break 14249 diff "conftest.out" "conftest.nl" >/dev/null 2>&1 || break 14250 as_fn_arith $ac_count + 1 && ac_count=$as_val 14251 if test $ac_count -gt ${ac_path_SED_max-0}; then 14252 # Best one so far, save it but keep looking for a better one 14253 ac_cv_path_SED="$ac_path_SED" 14254 ac_path_SED_max=$ac_count 14255 fi 14256 # 10*(2^10) chars as input seems more than enough 14257 test $ac_count -gt 10 && break 14258 done 14259 rm -f conftest.in conftest.tmp conftest.nl conftest.out;; 14260 esac 14261 14262 $ac_path_SED_found && break 3 14263 done 14264 done 14265 done 14266 IFS=$as_save_IFS 14267 if test -z "$ac_cv_path_SED"; then 14268 as_fn_error $? "no acceptable sed could be found in \$PATH" "$LINENO" 5 14269 fi 14270 else 14271 ac_cv_path_SED=$SED 14272 fi 14273 14274 fi 14275 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_path_SED" >&5 14276 $as_echo "$ac_cv_path_SED" >&6; } 14277 SED="$ac_cv_path_SED" 14278 rm -f conftest.sed 14279 14280 else 14281 # If it succeeded, then it was overridden by the user. We will use it 14282 # for the tool. 14283 14284 # First remove it from the list of overridden variables, so we can test 14285 # for unknown variables in the end. 14286 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 14287 14288 # Check if we try to supply an empty value 14289 if test "x$SED" = x; then 14290 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool SED= (no value)" >&5 14291 $as_echo "$as_me: Setting user supplied tool SED= (no value)" >&6;} 14292 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for SED" >&5 14293 $as_echo_n "checking for SED... " >&6; } 14294 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 14295 $as_echo "disabled" >&6; } 14296 else 14297 # Check if the provided tool contains a complete path. 14298 tool_specified="$SED" 14299 tool_basename="${tool_specified##*/}" 14300 if test "x$tool_basename" = "x$tool_specified"; then 14301 # A command without a complete path is provided, search $PATH. 14302 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool SED=$tool_basename" >&5 14303 $as_echo "$as_me: Will search for user supplied tool SED=$tool_basename" >&6;} 14304 # Extract the first word of "$tool_basename", so it can be a program name with args. 14305 set dummy $tool_basename; ac_word=$2 14306 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 14307 $as_echo_n "checking for $ac_word... " >&6; } 14308 if ${ac_cv_path_SED+:} false; then : 14309 $as_echo_n "(cached) " >&6 14310 else 14311 case $SED in 14312 [\\/]* | ?:[\\/]*) 14313 ac_cv_path_SED="$SED" # Let the user override the test with a path. 14314 ;; 14315 *) 14316 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 14317 for as_dir in $PATH 14318 do 14319 IFS=$as_save_IFS 14320 test -z "$as_dir" && as_dir=. 14321 for ac_exec_ext in '' $ac_executable_extensions; do 14322 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 14323 ac_cv_path_SED="$as_dir/$ac_word$ac_exec_ext" 14324 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 14325 break 2 14326 fi 14327 done 14328 done 14329 IFS=$as_save_IFS 14330 14331 ;; 14332 esac 14333 fi 14334 SED=$ac_cv_path_SED 14335 if test -n "$SED"; then 14336 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $SED" >&5 14337 $as_echo "$SED" >&6; } 14338 else 14339 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 14340 $as_echo "no" >&6; } 14341 fi 14342 14343 14344 if test "x$SED" = x; then 14345 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 14346 fi 14347 else 14348 # Otherwise we believe it is a complete path. Use it as it is. 14349 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool SED=$tool_specified" >&5 14350 $as_echo "$as_me: Will use user supplied tool SED=$tool_specified" >&6;} 14351 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for SED" >&5 14352 $as_echo_n "checking for SED... " >&6; } 14353 if test ! -x "$tool_specified"; then 14354 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 14355 $as_echo "not found" >&6; } 14356 as_fn_error $? "User supplied tool SED=$tool_specified does not exist or is not executable" "$LINENO" 5 14357 fi 14358 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 14359 $as_echo "$tool_specified" >&6; } 14360 fi 14361 fi 14362 fi 14363 14364 fi 14365 14366 14367 if test "x$SED" = x; then 14368 as_fn_error $? "Could not find required tool for SED" "$LINENO" 5 14369 fi 14370 14371 14372 14373 # Always force rm. 14374 RM="$RM -f" 14375 14376 # pwd behaves differently on various platforms and some don't support the -L flag. 14377 # Always use the bash builtin pwd to get uniform behavior. 14378 THEPWDCMD=pwd 14379 14380 # These are not required on all platforms 14381 14382 14383 # Publish this variable in the help. 14384 14385 14386 if [ -z "${CYGPATH+x}" ]; then 14387 # The variable is not set by user, try to locate tool using the code snippet 14388 for ac_prog in cygpath 14389 do 14390 # Extract the first word of "$ac_prog", so it can be a program name with args. 14391 set dummy $ac_prog; ac_word=$2 14392 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 14393 $as_echo_n "checking for $ac_word... " >&6; } 14394 if ${ac_cv_path_CYGPATH+:} false; then : 14395 $as_echo_n "(cached) " >&6 14396 else 14397 case $CYGPATH in 14398 [\\/]* | ?:[\\/]*) 14399 ac_cv_path_CYGPATH="$CYGPATH" # Let the user override the test with a path. 14400 ;; 14401 *) 14402 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 14403 for as_dir in $PATH 14404 do 14405 IFS=$as_save_IFS 14406 test -z "$as_dir" && as_dir=. 14407 for ac_exec_ext in '' $ac_executable_extensions; do 14408 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 14409 ac_cv_path_CYGPATH="$as_dir/$ac_word$ac_exec_ext" 14410 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 14411 break 2 14412 fi 14413 done 14414 done 14415 IFS=$as_save_IFS 14416 14417 ;; 14418 esac 14419 fi 14420 CYGPATH=$ac_cv_path_CYGPATH 14421 if test -n "$CYGPATH"; then 14422 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CYGPATH" >&5 14423 $as_echo "$CYGPATH" >&6; } 14424 else 14425 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 14426 $as_echo "no" >&6; } 14427 fi 14428 14429 14430 test -n "$CYGPATH" && break 14431 done 14432 14433 else 14434 # The variable is set, but is it from the command line or the environment? 14435 14436 # Try to remove the string !CYGPATH! from our list. 14437 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!CYGPATH!/} 14438 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 14439 # If it failed, the variable was not from the command line. Ignore it, 14440 # but warn the user (except for BASH, which is always set by the calling BASH). 14441 if test "xCYGPATH" != xBASH; then 14442 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of CYGPATH from the environment. Use command line variables instead." >&5 14443 $as_echo "$as_me: WARNING: Ignoring value of CYGPATH from the environment. Use command line variables instead." >&2;} 14444 fi 14445 # Try to locate tool using the code snippet 14446 for ac_prog in cygpath 14447 do 14448 # Extract the first word of "$ac_prog", so it can be a program name with args. 14449 set dummy $ac_prog; ac_word=$2 14450 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 14451 $as_echo_n "checking for $ac_word... " >&6; } 14452 if ${ac_cv_path_CYGPATH+:} false; then : 14453 $as_echo_n "(cached) " >&6 14454 else 14455 case $CYGPATH in 14456 [\\/]* | ?:[\\/]*) 14457 ac_cv_path_CYGPATH="$CYGPATH" # Let the user override the test with a path. 14458 ;; 14459 *) 14460 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 14461 for as_dir in $PATH 14462 do 14463 IFS=$as_save_IFS 14464 test -z "$as_dir" && as_dir=. 14465 for ac_exec_ext in '' $ac_executable_extensions; do 14466 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 14467 ac_cv_path_CYGPATH="$as_dir/$ac_word$ac_exec_ext" 14468 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 14469 break 2 14470 fi 14471 done 14472 done 14473 IFS=$as_save_IFS 14474 14475 ;; 14476 esac 14477 fi 14478 CYGPATH=$ac_cv_path_CYGPATH 14479 if test -n "$CYGPATH"; then 14480 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CYGPATH" >&5 14481 $as_echo "$CYGPATH" >&6; } 14482 else 14483 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 14484 $as_echo "no" >&6; } 14485 fi 14486 14487 14488 test -n "$CYGPATH" && break 14489 done 14490 14491 else 14492 # If it succeeded, then it was overridden by the user. We will use it 14493 # for the tool. 14494 14495 # First remove it from the list of overridden variables, so we can test 14496 # for unknown variables in the end. 14497 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 14498 14499 # Check if we try to supply an empty value 14500 if test "x$CYGPATH" = x; then 14501 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool CYGPATH= (no value)" >&5 14502 $as_echo "$as_me: Setting user supplied tool CYGPATH= (no value)" >&6;} 14503 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for CYGPATH" >&5 14504 $as_echo_n "checking for CYGPATH... " >&6; } 14505 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 14506 $as_echo "disabled" >&6; } 14507 else 14508 # Check if the provided tool contains a complete path. 14509 tool_specified="$CYGPATH" 14510 tool_basename="${tool_specified##*/}" 14511 if test "x$tool_basename" = "x$tool_specified"; then 14512 # A command without a complete path is provided, search $PATH. 14513 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool CYGPATH=$tool_basename" >&5 14514 $as_echo "$as_me: Will search for user supplied tool CYGPATH=$tool_basename" >&6;} 14515 # Extract the first word of "$tool_basename", so it can be a program name with args. 14516 set dummy $tool_basename; ac_word=$2 14517 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 14518 $as_echo_n "checking for $ac_word... " >&6; } 14519 if ${ac_cv_path_CYGPATH+:} false; then : 14520 $as_echo_n "(cached) " >&6 14521 else 14522 case $CYGPATH in 14523 [\\/]* | ?:[\\/]*) 14524 ac_cv_path_CYGPATH="$CYGPATH" # Let the user override the test with a path. 14525 ;; 14526 *) 14527 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 14528 for as_dir in $PATH 14529 do 14530 IFS=$as_save_IFS 14531 test -z "$as_dir" && as_dir=. 14532 for ac_exec_ext in '' $ac_executable_extensions; do 14533 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 14534 ac_cv_path_CYGPATH="$as_dir/$ac_word$ac_exec_ext" 14535 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 14536 break 2 14537 fi 14538 done 14539 done 14540 IFS=$as_save_IFS 14541 14542 ;; 14543 esac 14544 fi 14545 CYGPATH=$ac_cv_path_CYGPATH 14546 if test -n "$CYGPATH"; then 14547 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CYGPATH" >&5 14548 $as_echo "$CYGPATH" >&6; } 14549 else 14550 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 14551 $as_echo "no" >&6; } 14552 fi 14553 14554 14555 if test "x$CYGPATH" = x; then 14556 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 14557 fi 14558 else 14559 # Otherwise we believe it is a complete path. Use it as it is. 14560 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool CYGPATH=$tool_specified" >&5 14561 $as_echo "$as_me: Will use user supplied tool CYGPATH=$tool_specified" >&6;} 14562 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for CYGPATH" >&5 14563 $as_echo_n "checking for CYGPATH... " >&6; } 14564 if test ! -x "$tool_specified"; then 14565 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 14566 $as_echo "not found" >&6; } 14567 as_fn_error $? "User supplied tool CYGPATH=$tool_specified does not exist or is not executable" "$LINENO" 5 14568 fi 14569 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 14570 $as_echo "$tool_specified" >&6; } 14571 fi 14572 fi 14573 fi 14574 14575 fi 14576 14577 14578 14579 14580 # Publish this variable in the help. 14581 14582 14583 if [ -z "${READLINK+x}" ]; then 14584 # The variable is not set by user, try to locate tool using the code snippet 14585 for ac_prog in greadlink readlink 14586 do 14587 # Extract the first word of "$ac_prog", so it can be a program name with args. 14588 set dummy $ac_prog; ac_word=$2 14589 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 14590 $as_echo_n "checking for $ac_word... " >&6; } 14591 if ${ac_cv_path_READLINK+:} false; then : 14592 $as_echo_n "(cached) " >&6 14593 else 14594 case $READLINK in 14595 [\\/]* | ?:[\\/]*) 14596 ac_cv_path_READLINK="$READLINK" # Let the user override the test with a path. 14597 ;; 14598 *) 14599 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 14600 for as_dir in $PATH 14601 do 14602 IFS=$as_save_IFS 14603 test -z "$as_dir" && as_dir=. 14604 for ac_exec_ext in '' $ac_executable_extensions; do 14605 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 14606 ac_cv_path_READLINK="$as_dir/$ac_word$ac_exec_ext" 14607 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 14608 break 2 14609 fi 14610 done 14611 done 14612 IFS=$as_save_IFS 14613 14614 ;; 14615 esac 14616 fi 14617 READLINK=$ac_cv_path_READLINK 14618 if test -n "$READLINK"; then 14619 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $READLINK" >&5 14620 $as_echo "$READLINK" >&6; } 14621 else 14622 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 14623 $as_echo "no" >&6; } 14624 fi 14625 14626 14627 test -n "$READLINK" && break 14628 done 14629 14630 else 14631 # The variable is set, but is it from the command line or the environment? 14632 14633 # Try to remove the string !READLINK! from our list. 14634 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!READLINK!/} 14635 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 14636 # If it failed, the variable was not from the command line. Ignore it, 14637 # but warn the user (except for BASH, which is always set by the calling BASH). 14638 if test "xREADLINK" != xBASH; then 14639 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of READLINK from the environment. Use command line variables instead." >&5 14640 $as_echo "$as_me: WARNING: Ignoring value of READLINK from the environment. Use command line variables instead." >&2;} 14641 fi 14642 # Try to locate tool using the code snippet 14643 for ac_prog in greadlink readlink 14644 do 14645 # Extract the first word of "$ac_prog", so it can be a program name with args. 14646 set dummy $ac_prog; ac_word=$2 14647 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 14648 $as_echo_n "checking for $ac_word... " >&6; } 14649 if ${ac_cv_path_READLINK+:} false; then : 14650 $as_echo_n "(cached) " >&6 14651 else 14652 case $READLINK in 14653 [\\/]* | ?:[\\/]*) 14654 ac_cv_path_READLINK="$READLINK" # Let the user override the test with a path. 14655 ;; 14656 *) 14657 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 14658 for as_dir in $PATH 14659 do 14660 IFS=$as_save_IFS 14661 test -z "$as_dir" && as_dir=. 14662 for ac_exec_ext in '' $ac_executable_extensions; do 14663 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 14664 ac_cv_path_READLINK="$as_dir/$ac_word$ac_exec_ext" 14665 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 14666 break 2 14667 fi 14668 done 14669 done 14670 IFS=$as_save_IFS 14671 14672 ;; 14673 esac 14674 fi 14675 READLINK=$ac_cv_path_READLINK 14676 if test -n "$READLINK"; then 14677 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $READLINK" >&5 14678 $as_echo "$READLINK" >&6; } 14679 else 14680 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 14681 $as_echo "no" >&6; } 14682 fi 14683 14684 14685 test -n "$READLINK" && break 14686 done 14687 14688 else 14689 # If it succeeded, then it was overridden by the user. We will use it 14690 # for the tool. 14691 14692 # First remove it from the list of overridden variables, so we can test 14693 # for unknown variables in the end. 14694 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 14695 14696 # Check if we try to supply an empty value 14697 if test "x$READLINK" = x; then 14698 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool READLINK= (no value)" >&5 14699 $as_echo "$as_me: Setting user supplied tool READLINK= (no value)" >&6;} 14700 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for READLINK" >&5 14701 $as_echo_n "checking for READLINK... " >&6; } 14702 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 14703 $as_echo "disabled" >&6; } 14704 else 14705 # Check if the provided tool contains a complete path. 14706 tool_specified="$READLINK" 14707 tool_basename="${tool_specified##*/}" 14708 if test "x$tool_basename" = "x$tool_specified"; then 14709 # A command without a complete path is provided, search $PATH. 14710 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool READLINK=$tool_basename" >&5 14711 $as_echo "$as_me: Will search for user supplied tool READLINK=$tool_basename" >&6;} 14712 # Extract the first word of "$tool_basename", so it can be a program name with args. 14713 set dummy $tool_basename; ac_word=$2 14714 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 14715 $as_echo_n "checking for $ac_word... " >&6; } 14716 if ${ac_cv_path_READLINK+:} false; then : 14717 $as_echo_n "(cached) " >&6 14718 else 14719 case $READLINK in 14720 [\\/]* | ?:[\\/]*) 14721 ac_cv_path_READLINK="$READLINK" # Let the user override the test with a path. 14722 ;; 14723 *) 14724 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 14725 for as_dir in $PATH 14726 do 14727 IFS=$as_save_IFS 14728 test -z "$as_dir" && as_dir=. 14729 for ac_exec_ext in '' $ac_executable_extensions; do 14730 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 14731 ac_cv_path_READLINK="$as_dir/$ac_word$ac_exec_ext" 14732 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 14733 break 2 14734 fi 14735 done 14736 done 14737 IFS=$as_save_IFS 14738 14739 ;; 14740 esac 14741 fi 14742 READLINK=$ac_cv_path_READLINK 14743 if test -n "$READLINK"; then 14744 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $READLINK" >&5 14745 $as_echo "$READLINK" >&6; } 14746 else 14747 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 14748 $as_echo "no" >&6; } 14749 fi 14750 14751 14752 if test "x$READLINK" = x; then 14753 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 14754 fi 14755 else 14756 # Otherwise we believe it is a complete path. Use it as it is. 14757 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool READLINK=$tool_specified" >&5 14758 $as_echo "$as_me: Will use user supplied tool READLINK=$tool_specified" >&6;} 14759 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for READLINK" >&5 14760 $as_echo_n "checking for READLINK... " >&6; } 14761 if test ! -x "$tool_specified"; then 14762 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 14763 $as_echo "not found" >&6; } 14764 as_fn_error $? "User supplied tool READLINK=$tool_specified does not exist or is not executable" "$LINENO" 5 14765 fi 14766 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 14767 $as_echo "$tool_specified" >&6; } 14768 fi 14769 fi 14770 fi 14771 14772 fi 14773 14774 14775 14776 14777 # Publish this variable in the help. 14778 14779 14780 if [ -z "${DF+x}" ]; then 14781 # The variable is not set by user, try to locate tool using the code snippet 14782 for ac_prog in df 14783 do 14784 # Extract the first word of "$ac_prog", so it can be a program name with args. 14785 set dummy $ac_prog; ac_word=$2 14786 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 14787 $as_echo_n "checking for $ac_word... " >&6; } 14788 if ${ac_cv_path_DF+:} false; then : 14789 $as_echo_n "(cached) " >&6 14790 else 14791 case $DF in 14792 [\\/]* | ?:[\\/]*) 14793 ac_cv_path_DF="$DF" # Let the user override the test with a path. 14794 ;; 14795 *) 14796 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 14797 for as_dir in $PATH 14798 do 14799 IFS=$as_save_IFS 14800 test -z "$as_dir" && as_dir=. 14801 for ac_exec_ext in '' $ac_executable_extensions; do 14802 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 14803 ac_cv_path_DF="$as_dir/$ac_word$ac_exec_ext" 14804 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 14805 break 2 14806 fi 14807 done 14808 done 14809 IFS=$as_save_IFS 14810 14811 ;; 14812 esac 14813 fi 14814 DF=$ac_cv_path_DF 14815 if test -n "$DF"; then 14816 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $DF" >&5 14817 $as_echo "$DF" >&6; } 14818 else 14819 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 14820 $as_echo "no" >&6; } 14821 fi 14822 14823 14824 test -n "$DF" && break 14825 done 14826 14827 else 14828 # The variable is set, but is it from the command line or the environment? 14829 14830 # Try to remove the string !DF! from our list. 14831 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!DF!/} 14832 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 14833 # If it failed, the variable was not from the command line. Ignore it, 14834 # but warn the user (except for BASH, which is always set by the calling BASH). 14835 if test "xDF" != xBASH; then 14836 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of DF from the environment. Use command line variables instead." >&5 14837 $as_echo "$as_me: WARNING: Ignoring value of DF from the environment. Use command line variables instead." >&2;} 14838 fi 14839 # Try to locate tool using the code snippet 14840 for ac_prog in df 14841 do 14842 # Extract the first word of "$ac_prog", so it can be a program name with args. 14843 set dummy $ac_prog; ac_word=$2 14844 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 14845 $as_echo_n "checking for $ac_word... " >&6; } 14846 if ${ac_cv_path_DF+:} false; then : 14847 $as_echo_n "(cached) " >&6 14848 else 14849 case $DF in 14850 [\\/]* | ?:[\\/]*) 14851 ac_cv_path_DF="$DF" # Let the user override the test with a path. 14852 ;; 14853 *) 14854 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 14855 for as_dir in $PATH 14856 do 14857 IFS=$as_save_IFS 14858 test -z "$as_dir" && as_dir=. 14859 for ac_exec_ext in '' $ac_executable_extensions; do 14860 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 14861 ac_cv_path_DF="$as_dir/$ac_word$ac_exec_ext" 14862 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 14863 break 2 14864 fi 14865 done 14866 done 14867 IFS=$as_save_IFS 14868 14869 ;; 14870 esac 14871 fi 14872 DF=$ac_cv_path_DF 14873 if test -n "$DF"; then 14874 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $DF" >&5 14875 $as_echo "$DF" >&6; } 14876 else 14877 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 14878 $as_echo "no" >&6; } 14879 fi 14880 14881 14882 test -n "$DF" && break 14883 done 14884 14885 else 14886 # If it succeeded, then it was overridden by the user. We will use it 14887 # for the tool. 14888 14889 # First remove it from the list of overridden variables, so we can test 14890 # for unknown variables in the end. 14891 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 14892 14893 # Check if we try to supply an empty value 14894 if test "x$DF" = x; then 14895 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool DF= (no value)" >&5 14896 $as_echo "$as_me: Setting user supplied tool DF= (no value)" >&6;} 14897 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for DF" >&5 14898 $as_echo_n "checking for DF... " >&6; } 14899 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 14900 $as_echo "disabled" >&6; } 14901 else 14902 # Check if the provided tool contains a complete path. 14903 tool_specified="$DF" 14904 tool_basename="${tool_specified##*/}" 14905 if test "x$tool_basename" = "x$tool_specified"; then 14906 # A command without a complete path is provided, search $PATH. 14907 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool DF=$tool_basename" >&5 14908 $as_echo "$as_me: Will search for user supplied tool DF=$tool_basename" >&6;} 14909 # Extract the first word of "$tool_basename", so it can be a program name with args. 14910 set dummy $tool_basename; ac_word=$2 14911 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 14912 $as_echo_n "checking for $ac_word... " >&6; } 14913 if ${ac_cv_path_DF+:} false; then : 14914 $as_echo_n "(cached) " >&6 14915 else 14916 case $DF in 14917 [\\/]* | ?:[\\/]*) 14918 ac_cv_path_DF="$DF" # Let the user override the test with a path. 14919 ;; 14920 *) 14921 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 14922 for as_dir in $PATH 14923 do 14924 IFS=$as_save_IFS 14925 test -z "$as_dir" && as_dir=. 14926 for ac_exec_ext in '' $ac_executable_extensions; do 14927 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 14928 ac_cv_path_DF="$as_dir/$ac_word$ac_exec_ext" 14929 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 14930 break 2 14931 fi 14932 done 14933 done 14934 IFS=$as_save_IFS 14935 14936 ;; 14937 esac 14938 fi 14939 DF=$ac_cv_path_DF 14940 if test -n "$DF"; then 14941 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $DF" >&5 14942 $as_echo "$DF" >&6; } 14943 else 14944 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 14945 $as_echo "no" >&6; } 14946 fi 14947 14948 14949 if test "x$DF" = x; then 14950 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 14951 fi 14952 else 14953 # Otherwise we believe it is a complete path. Use it as it is. 14954 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool DF=$tool_specified" >&5 14955 $as_echo "$as_me: Will use user supplied tool DF=$tool_specified" >&6;} 14956 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for DF" >&5 14957 $as_echo_n "checking for DF... " >&6; } 14958 if test ! -x "$tool_specified"; then 14959 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 14960 $as_echo "not found" >&6; } 14961 as_fn_error $? "User supplied tool DF=$tool_specified does not exist or is not executable" "$LINENO" 5 14962 fi 14963 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 14964 $as_echo "$tool_specified" >&6; } 14965 fi 14966 fi 14967 fi 14968 14969 fi 14970 14971 14972 14973 14974 # Publish this variable in the help. 14975 14976 14977 if [ -z "${CPIO+x}" ]; then 14978 # The variable is not set by user, try to locate tool using the code snippet 14979 for ac_prog in cpio bsdcpio 14980 do 14981 # Extract the first word of "$ac_prog", so it can be a program name with args. 14982 set dummy $ac_prog; ac_word=$2 14983 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 14984 $as_echo_n "checking for $ac_word... " >&6; } 14985 if ${ac_cv_path_CPIO+:} false; then : 14986 $as_echo_n "(cached) " >&6 14987 else 14988 case $CPIO in 14989 [\\/]* | ?:[\\/]*) 14990 ac_cv_path_CPIO="$CPIO" # Let the user override the test with a path. 14991 ;; 14992 *) 14993 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 14994 for as_dir in $PATH 14995 do 14996 IFS=$as_save_IFS 14997 test -z "$as_dir" && as_dir=. 14998 for ac_exec_ext in '' $ac_executable_extensions; do 14999 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 15000 ac_cv_path_CPIO="$as_dir/$ac_word$ac_exec_ext" 15001 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 15002 break 2 15003 fi 15004 done 15005 done 15006 IFS=$as_save_IFS 15007 15008 ;; 15009 esac 15010 fi 15011 CPIO=$ac_cv_path_CPIO 15012 if test -n "$CPIO"; then 15013 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CPIO" >&5 15014 $as_echo "$CPIO" >&6; } 15015 else 15016 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 15017 $as_echo "no" >&6; } 15018 fi 15019 15020 15021 test -n "$CPIO" && break 15022 done 15023 15024 else 15025 # The variable is set, but is it from the command line or the environment? 15026 15027 # Try to remove the string !CPIO! from our list. 15028 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!CPIO!/} 15029 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 15030 # If it failed, the variable was not from the command line. Ignore it, 15031 # but warn the user (except for BASH, which is always set by the calling BASH). 15032 if test "xCPIO" != xBASH; then 15033 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of CPIO from the environment. Use command line variables instead." >&5 15034 $as_echo "$as_me: WARNING: Ignoring value of CPIO from the environment. Use command line variables instead." >&2;} 15035 fi 15036 # Try to locate tool using the code snippet 15037 for ac_prog in cpio bsdcpio 15038 do 15039 # Extract the first word of "$ac_prog", so it can be a program name with args. 15040 set dummy $ac_prog; ac_word=$2 15041 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 15042 $as_echo_n "checking for $ac_word... " >&6; } 15043 if ${ac_cv_path_CPIO+:} false; then : 15044 $as_echo_n "(cached) " >&6 15045 else 15046 case $CPIO in 15047 [\\/]* | ?:[\\/]*) 15048 ac_cv_path_CPIO="$CPIO" # Let the user override the test with a path. 15049 ;; 15050 *) 15051 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 15052 for as_dir in $PATH 15053 do 15054 IFS=$as_save_IFS 15055 test -z "$as_dir" && as_dir=. 15056 for ac_exec_ext in '' $ac_executable_extensions; do 15057 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 15058 ac_cv_path_CPIO="$as_dir/$ac_word$ac_exec_ext" 15059 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 15060 break 2 15061 fi 15062 done 15063 done 15064 IFS=$as_save_IFS 15065 15066 ;; 15067 esac 15068 fi 15069 CPIO=$ac_cv_path_CPIO 15070 if test -n "$CPIO"; then 15071 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CPIO" >&5 15072 $as_echo "$CPIO" >&6; } 15073 else 15074 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 15075 $as_echo "no" >&6; } 15076 fi 15077 15078 15079 test -n "$CPIO" && break 15080 done 15081 15082 else 15083 # If it succeeded, then it was overridden by the user. We will use it 15084 # for the tool. 15085 15086 # First remove it from the list of overridden variables, so we can test 15087 # for unknown variables in the end. 15088 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 15089 15090 # Check if we try to supply an empty value 15091 if test "x$CPIO" = x; then 15092 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool CPIO= (no value)" >&5 15093 $as_echo "$as_me: Setting user supplied tool CPIO= (no value)" >&6;} 15094 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for CPIO" >&5 15095 $as_echo_n "checking for CPIO... " >&6; } 15096 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 15097 $as_echo "disabled" >&6; } 15098 else 15099 # Check if the provided tool contains a complete path. 15100 tool_specified="$CPIO" 15101 tool_basename="${tool_specified##*/}" 15102 if test "x$tool_basename" = "x$tool_specified"; then 15103 # A command without a complete path is provided, search $PATH. 15104 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool CPIO=$tool_basename" >&5 15105 $as_echo "$as_me: Will search for user supplied tool CPIO=$tool_basename" >&6;} 15106 # Extract the first word of "$tool_basename", so it can be a program name with args. 15107 set dummy $tool_basename; ac_word=$2 15108 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 15109 $as_echo_n "checking for $ac_word... " >&6; } 15110 if ${ac_cv_path_CPIO+:} false; then : 15111 $as_echo_n "(cached) " >&6 15112 else 15113 case $CPIO in 15114 [\\/]* | ?:[\\/]*) 15115 ac_cv_path_CPIO="$CPIO" # Let the user override the test with a path. 15116 ;; 15117 *) 15118 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 15119 for as_dir in $PATH 15120 do 15121 IFS=$as_save_IFS 15122 test -z "$as_dir" && as_dir=. 15123 for ac_exec_ext in '' $ac_executable_extensions; do 15124 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 15125 ac_cv_path_CPIO="$as_dir/$ac_word$ac_exec_ext" 15126 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 15127 break 2 15128 fi 15129 done 15130 done 15131 IFS=$as_save_IFS 15132 15133 ;; 15134 esac 15135 fi 15136 CPIO=$ac_cv_path_CPIO 15137 if test -n "$CPIO"; then 15138 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CPIO" >&5 15139 $as_echo "$CPIO" >&6; } 15140 else 15141 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 15142 $as_echo "no" >&6; } 15143 fi 15144 15145 15146 if test "x$CPIO" = x; then 15147 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 15148 fi 15149 else 15150 # Otherwise we believe it is a complete path. Use it as it is. 15151 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool CPIO=$tool_specified" >&5 15152 $as_echo "$as_me: Will use user supplied tool CPIO=$tool_specified" >&6;} 15153 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for CPIO" >&5 15154 $as_echo_n "checking for CPIO... " >&6; } 15155 if test ! -x "$tool_specified"; then 15156 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 15157 $as_echo "not found" >&6; } 15158 as_fn_error $? "User supplied tool CPIO=$tool_specified does not exist or is not executable" "$LINENO" 5 15159 fi 15160 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 15161 $as_echo "$tool_specified" >&6; } 15162 fi 15163 fi 15164 fi 15165 15166 fi 15167 15168 15169 15170 15171 # Publish this variable in the help. 15172 15173 15174 if [ -z "${NICE+x}" ]; then 15175 # The variable is not set by user, try to locate tool using the code snippet 15176 for ac_prog in nice 15177 do 15178 # Extract the first word of "$ac_prog", so it can be a program name with args. 15179 set dummy $ac_prog; ac_word=$2 15180 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 15181 $as_echo_n "checking for $ac_word... " >&6; } 15182 if ${ac_cv_path_NICE+:} false; then : 15183 $as_echo_n "(cached) " >&6 15184 else 15185 case $NICE in 15186 [\\/]* | ?:[\\/]*) 15187 ac_cv_path_NICE="$NICE" # Let the user override the test with a path. 15188 ;; 15189 *) 15190 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 15191 for as_dir in $PATH 15192 do 15193 IFS=$as_save_IFS 15194 test -z "$as_dir" && as_dir=. 15195 for ac_exec_ext in '' $ac_executable_extensions; do 15196 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 15197 ac_cv_path_NICE="$as_dir/$ac_word$ac_exec_ext" 15198 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 15199 break 2 15200 fi 15201 done 15202 done 15203 IFS=$as_save_IFS 15204 15205 ;; 15206 esac 15207 fi 15208 NICE=$ac_cv_path_NICE 15209 if test -n "$NICE"; then 15210 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $NICE" >&5 15211 $as_echo "$NICE" >&6; } 15212 else 15213 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 15214 $as_echo "no" >&6; } 15215 fi 15216 15217 15218 test -n "$NICE" && break 15219 done 15220 15221 else 15222 # The variable is set, but is it from the command line or the environment? 15223 15224 # Try to remove the string !NICE! from our list. 15225 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!NICE!/} 15226 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 15227 # If it failed, the variable was not from the command line. Ignore it, 15228 # but warn the user (except for BASH, which is always set by the calling BASH). 15229 if test "xNICE" != xBASH; then 15230 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of NICE from the environment. Use command line variables instead." >&5 15231 $as_echo "$as_me: WARNING: Ignoring value of NICE from the environment. Use command line variables instead." >&2;} 15232 fi 15233 # Try to locate tool using the code snippet 15234 for ac_prog in nice 15235 do 15236 # Extract the first word of "$ac_prog", so it can be a program name with args. 15237 set dummy $ac_prog; ac_word=$2 15238 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 15239 $as_echo_n "checking for $ac_word... " >&6; } 15240 if ${ac_cv_path_NICE+:} false; then : 15241 $as_echo_n "(cached) " >&6 15242 else 15243 case $NICE in 15244 [\\/]* | ?:[\\/]*) 15245 ac_cv_path_NICE="$NICE" # Let the user override the test with a path. 15246 ;; 15247 *) 15248 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 15249 for as_dir in $PATH 15250 do 15251 IFS=$as_save_IFS 15252 test -z "$as_dir" && as_dir=. 15253 for ac_exec_ext in '' $ac_executable_extensions; do 15254 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 15255 ac_cv_path_NICE="$as_dir/$ac_word$ac_exec_ext" 15256 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 15257 break 2 15258 fi 15259 done 15260 done 15261 IFS=$as_save_IFS 15262 15263 ;; 15264 esac 15265 fi 15266 NICE=$ac_cv_path_NICE 15267 if test -n "$NICE"; then 15268 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $NICE" >&5 15269 $as_echo "$NICE" >&6; } 15270 else 15271 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 15272 $as_echo "no" >&6; } 15273 fi 15274 15275 15276 test -n "$NICE" && break 15277 done 15278 15279 else 15280 # If it succeeded, then it was overridden by the user. We will use it 15281 # for the tool. 15282 15283 # First remove it from the list of overridden variables, so we can test 15284 # for unknown variables in the end. 15285 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 15286 15287 # Check if we try to supply an empty value 15288 if test "x$NICE" = x; then 15289 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool NICE= (no value)" >&5 15290 $as_echo "$as_me: Setting user supplied tool NICE= (no value)" >&6;} 15291 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for NICE" >&5 15292 $as_echo_n "checking for NICE... " >&6; } 15293 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 15294 $as_echo "disabled" >&6; } 15295 else 15296 # Check if the provided tool contains a complete path. 15297 tool_specified="$NICE" 15298 tool_basename="${tool_specified##*/}" 15299 if test "x$tool_basename" = "x$tool_specified"; then 15300 # A command without a complete path is provided, search $PATH. 15301 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool NICE=$tool_basename" >&5 15302 $as_echo "$as_me: Will search for user supplied tool NICE=$tool_basename" >&6;} 15303 # Extract the first word of "$tool_basename", so it can be a program name with args. 15304 set dummy $tool_basename; ac_word=$2 15305 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 15306 $as_echo_n "checking for $ac_word... " >&6; } 15307 if ${ac_cv_path_NICE+:} false; then : 15308 $as_echo_n "(cached) " >&6 15309 else 15310 case $NICE in 15311 [\\/]* | ?:[\\/]*) 15312 ac_cv_path_NICE="$NICE" # Let the user override the test with a path. 15313 ;; 15314 *) 15315 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 15316 for as_dir in $PATH 15317 do 15318 IFS=$as_save_IFS 15319 test -z "$as_dir" && as_dir=. 15320 for ac_exec_ext in '' $ac_executable_extensions; do 15321 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 15322 ac_cv_path_NICE="$as_dir/$ac_word$ac_exec_ext" 15323 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 15324 break 2 15325 fi 15326 done 15327 done 15328 IFS=$as_save_IFS 15329 15330 ;; 15331 esac 15332 fi 15333 NICE=$ac_cv_path_NICE 15334 if test -n "$NICE"; then 15335 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $NICE" >&5 15336 $as_echo "$NICE" >&6; } 15337 else 15338 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 15339 $as_echo "no" >&6; } 15340 fi 15341 15342 15343 if test "x$NICE" = x; then 15344 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 15345 fi 15346 else 15347 # Otherwise we believe it is a complete path. Use it as it is. 15348 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool NICE=$tool_specified" >&5 15349 $as_echo "$as_me: Will use user supplied tool NICE=$tool_specified" >&6;} 15350 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for NICE" >&5 15351 $as_echo_n "checking for NICE... " >&6; } 15352 if test ! -x "$tool_specified"; then 15353 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 15354 $as_echo "not found" >&6; } 15355 as_fn_error $? "User supplied tool NICE=$tool_specified does not exist or is not executable" "$LINENO" 5 15356 fi 15357 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 15358 $as_echo "$tool_specified" >&6; } 15359 fi 15360 fi 15361 fi 15362 15363 fi 15364 15365 15366 15367 15368 # Publish this variable in the help. 15369 15370 15371 if [ -z "${PANDOC+x}" ]; then 15372 # The variable is not set by user, try to locate tool using the code snippet 15373 for ac_prog in pandoc 15374 do 15375 # Extract the first word of "$ac_prog", so it can be a program name with args. 15376 set dummy $ac_prog; ac_word=$2 15377 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 15378 $as_echo_n "checking for $ac_word... " >&6; } 15379 if ${ac_cv_path_PANDOC+:} false; then : 15380 $as_echo_n "(cached) " >&6 15381 else 15382 case $PANDOC in 15383 [\\/]* | ?:[\\/]*) 15384 ac_cv_path_PANDOC="$PANDOC" # Let the user override the test with a path. 15385 ;; 15386 *) 15387 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 15388 for as_dir in $PATH 15389 do 15390 IFS=$as_save_IFS 15391 test -z "$as_dir" && as_dir=. 15392 for ac_exec_ext in '' $ac_executable_extensions; do 15393 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 15394 ac_cv_path_PANDOC="$as_dir/$ac_word$ac_exec_ext" 15395 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 15396 break 2 15397 fi 15398 done 15399 done 15400 IFS=$as_save_IFS 15401 15402 ;; 15403 esac 15404 fi 15405 PANDOC=$ac_cv_path_PANDOC 15406 if test -n "$PANDOC"; then 15407 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $PANDOC" >&5 15408 $as_echo "$PANDOC" >&6; } 15409 else 15410 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 15411 $as_echo "no" >&6; } 15412 fi 15413 15414 15415 test -n "$PANDOC" && break 15416 done 15417 15418 else 15419 # The variable is set, but is it from the command line or the environment? 15420 15421 # Try to remove the string !PANDOC! from our list. 15422 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!PANDOC!/} 15423 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 15424 # If it failed, the variable was not from the command line. Ignore it, 15425 # but warn the user (except for BASH, which is always set by the calling BASH). 15426 if test "xPANDOC" != xBASH; then 15427 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of PANDOC from the environment. Use command line variables instead." >&5 15428 $as_echo "$as_me: WARNING: Ignoring value of PANDOC from the environment. Use command line variables instead." >&2;} 15429 fi 15430 # Try to locate tool using the code snippet 15431 for ac_prog in pandoc 15432 do 15433 # Extract the first word of "$ac_prog", so it can be a program name with args. 15434 set dummy $ac_prog; ac_word=$2 15435 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 15436 $as_echo_n "checking for $ac_word... " >&6; } 15437 if ${ac_cv_path_PANDOC+:} false; then : 15438 $as_echo_n "(cached) " >&6 15439 else 15440 case $PANDOC in 15441 [\\/]* | ?:[\\/]*) 15442 ac_cv_path_PANDOC="$PANDOC" # Let the user override the test with a path. 15443 ;; 15444 *) 15445 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 15446 for as_dir in $PATH 15447 do 15448 IFS=$as_save_IFS 15449 test -z "$as_dir" && as_dir=. 15450 for ac_exec_ext in '' $ac_executable_extensions; do 15451 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 15452 ac_cv_path_PANDOC="$as_dir/$ac_word$ac_exec_ext" 15453 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 15454 break 2 15455 fi 15456 done 15457 done 15458 IFS=$as_save_IFS 15459 15460 ;; 15461 esac 15462 fi 15463 PANDOC=$ac_cv_path_PANDOC 15464 if test -n "$PANDOC"; then 15465 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $PANDOC" >&5 15466 $as_echo "$PANDOC" >&6; } 15467 else 15468 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 15469 $as_echo "no" >&6; } 15470 fi 15471 15472 15473 test -n "$PANDOC" && break 15474 done 15475 15476 else 15477 # If it succeeded, then it was overridden by the user. We will use it 15478 # for the tool. 15479 15480 # First remove it from the list of overridden variables, so we can test 15481 # for unknown variables in the end. 15482 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 15483 15484 # Check if we try to supply an empty value 15485 if test "x$PANDOC" = x; then 15486 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool PANDOC= (no value)" >&5 15487 $as_echo "$as_me: Setting user supplied tool PANDOC= (no value)" >&6;} 15488 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for PANDOC" >&5 15489 $as_echo_n "checking for PANDOC... " >&6; } 15490 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 15491 $as_echo "disabled" >&6; } 15492 else 15493 # Check if the provided tool contains a complete path. 15494 tool_specified="$PANDOC" 15495 tool_basename="${tool_specified##*/}" 15496 if test "x$tool_basename" = "x$tool_specified"; then 15497 # A command without a complete path is provided, search $PATH. 15498 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool PANDOC=$tool_basename" >&5 15499 $as_echo "$as_me: Will search for user supplied tool PANDOC=$tool_basename" >&6;} 15500 # Extract the first word of "$tool_basename", so it can be a program name with args. 15501 set dummy $tool_basename; ac_word=$2 15502 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 15503 $as_echo_n "checking for $ac_word... " >&6; } 15504 if ${ac_cv_path_PANDOC+:} false; then : 15505 $as_echo_n "(cached) " >&6 15506 else 15507 case $PANDOC in 15508 [\\/]* | ?:[\\/]*) 15509 ac_cv_path_PANDOC="$PANDOC" # Let the user override the test with a path. 15510 ;; 15511 *) 15512 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 15513 for as_dir in $PATH 15514 do 15515 IFS=$as_save_IFS 15516 test -z "$as_dir" && as_dir=. 15517 for ac_exec_ext in '' $ac_executable_extensions; do 15518 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 15519 ac_cv_path_PANDOC="$as_dir/$ac_word$ac_exec_ext" 15520 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 15521 break 2 15522 fi 15523 done 15524 done 15525 IFS=$as_save_IFS 15526 15527 ;; 15528 esac 15529 fi 15530 PANDOC=$ac_cv_path_PANDOC 15531 if test -n "$PANDOC"; then 15532 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $PANDOC" >&5 15533 $as_echo "$PANDOC" >&6; } 15534 else 15535 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 15536 $as_echo "no" >&6; } 15537 fi 15538 15539 15540 if test "x$PANDOC" = x; then 15541 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 15542 fi 15543 else 15544 # Otherwise we believe it is a complete path. Use it as it is. 15545 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool PANDOC=$tool_specified" >&5 15546 $as_echo "$as_me: Will use user supplied tool PANDOC=$tool_specified" >&6;} 15547 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for PANDOC" >&5 15548 $as_echo_n "checking for PANDOC... " >&6; } 15549 if test ! -x "$tool_specified"; then 15550 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 15551 $as_echo "not found" >&6; } 15552 as_fn_error $? "User supplied tool PANDOC=$tool_specified does not exist or is not executable" "$LINENO" 5 15553 fi 15554 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 15555 $as_echo "$tool_specified" >&6; } 15556 fi 15557 fi 15558 fi 15559 15560 fi 15561 15562 15563 15564 15565 # Now we can determine OpenJDK build and target platforms. This is required to 15566 # have early on. 15567 # Make sure we can run config.sub. 15568 $SHELL "$ac_aux_dir/config.sub" sun4 >/dev/null 2>&1 || 15569 as_fn_error $? "cannot run $SHELL $ac_aux_dir/config.sub" "$LINENO" 5 15570 15571 { $as_echo "$as_me:${as_lineno-$LINENO}: checking build system type" >&5 15572 $as_echo_n "checking build system type... " >&6; } 15573 if ${ac_cv_build+:} false; then : 15574 $as_echo_n "(cached) " >&6 15575 else 15576 ac_build_alias=$build_alias 15577 test "x$ac_build_alias" = x && 15578 ac_build_alias=`$SHELL "$ac_aux_dir/config.guess"` 15579 test "x$ac_build_alias" = x && 15580 as_fn_error $? "cannot guess build type; you must specify one" "$LINENO" 5 15581 ac_cv_build=`$SHELL "$ac_aux_dir/config.sub" $ac_build_alias` || 15582 as_fn_error $? "$SHELL $ac_aux_dir/config.sub $ac_build_alias failed" "$LINENO" 5 15583 15584 fi 15585 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_build" >&5 15586 $as_echo "$ac_cv_build" >&6; } 15587 case $ac_cv_build in 15588 *-*-*) ;; 15589 *) as_fn_error $? "invalid value of canonical build" "$LINENO" 5;; 15590 esac 15591 build=$ac_cv_build 15592 ac_save_IFS=$IFS; IFS='-' 15593 set x $ac_cv_build 15594 shift 15595 build_cpu=$1 15596 build_vendor=$2 15597 shift; shift 15598 # Remember, the first character of IFS is used to create $*, 15599 # except with old shells: 15600 build_os=$* 15601 IFS=$ac_save_IFS 15602 case $build_os in *\ *) build_os=`echo "$build_os" | sed 's/ /-/g'`;; esac 15603 15604 15605 { $as_echo "$as_me:${as_lineno-$LINENO}: checking host system type" >&5 15606 $as_echo_n "checking host system type... " >&6; } 15607 if ${ac_cv_host+:} false; then : 15608 $as_echo_n "(cached) " >&6 15609 else 15610 if test "x$host_alias" = x; then 15611 ac_cv_host=$ac_cv_build 15612 else 15613 ac_cv_host=`$SHELL "$ac_aux_dir/config.sub" $host_alias` || 15614 as_fn_error $? "$SHELL $ac_aux_dir/config.sub $host_alias failed" "$LINENO" 5 15615 fi 15616 15617 fi 15618 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_host" >&5 15619 $as_echo "$ac_cv_host" >&6; } 15620 case $ac_cv_host in 15621 *-*-*) ;; 15622 *) as_fn_error $? "invalid value of canonical host" "$LINENO" 5;; 15623 esac 15624 host=$ac_cv_host 15625 ac_save_IFS=$IFS; IFS='-' 15626 set x $ac_cv_host 15627 shift 15628 host_cpu=$1 15629 host_vendor=$2 15630 shift; shift 15631 # Remember, the first character of IFS is used to create $*, 15632 # except with old shells: 15633 host_os=$* 15634 IFS=$ac_save_IFS 15635 case $host_os in *\ *) host_os=`echo "$host_os" | sed 's/ /-/g'`;; esac 15636 15637 15638 { $as_echo "$as_me:${as_lineno-$LINENO}: checking target system type" >&5 15639 $as_echo_n "checking target system type... " >&6; } 15640 if ${ac_cv_target+:} false; then : 15641 $as_echo_n "(cached) " >&6 15642 else 15643 if test "x$target_alias" = x; then 15644 ac_cv_target=$ac_cv_host 15645 else 15646 ac_cv_target=`$SHELL "$ac_aux_dir/config.sub" $target_alias` || 15647 as_fn_error $? "$SHELL $ac_aux_dir/config.sub $target_alias failed" "$LINENO" 5 15648 fi 15649 15650 fi 15651 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_target" >&5 15652 $as_echo "$ac_cv_target" >&6; } 15653 case $ac_cv_target in 15654 *-*-*) ;; 15655 *) as_fn_error $? "invalid value of canonical target" "$LINENO" 5;; 15656 esac 15657 target=$ac_cv_target 15658 ac_save_IFS=$IFS; IFS='-' 15659 set x $ac_cv_target 15660 shift 15661 target_cpu=$1 15662 target_vendor=$2 15663 shift; shift 15664 # Remember, the first character of IFS is used to create $*, 15665 # except with old shells: 15666 target_os=$* 15667 IFS=$ac_save_IFS 15668 case $target_os in *\ *) target_os=`echo "$target_os" | sed 's/ /-/g'`;; esac 15669 15670 15671 # The aliases save the names the user supplied, while $host etc. 15672 # will get canonicalized. 15673 test -n "$target_alias" && 15674 test "$program_prefix$program_suffix$program_transform_name" = \ 15675 NONENONEs,x,x, && 15676 program_prefix=${target_alias}- 15677 15678 # Figure out the build and target systems. # Note that in autoconf terminology, "build" is obvious, but "target" 15679 # is confusing; it assumes you are cross-compiling a cross-compiler (!) and "target" is thus the target of the 15680 # product you're building. The target of this build is called "host". Since this is confusing to most people, we 15681 # have not adopted that system, but use "target" as the platform we are building for. In some places though we need 15682 # to use the configure naming style. 15683 15684 15685 15686 15687 15688 # Copy the autoconf trip/quadruplet verbatim to OPENJDK_TARGET_AUTOCONF_NAME 15689 # (from the autoconf "host") and OPENJDK_BUILD_AUTOCONF_NAME 15690 # Note that we might later on rewrite e.g. OPENJDK_TARGET_CPU due to reduced build, 15691 # but this will not change the value of OPENJDK_TARGET_AUTOCONF_NAME. 15692 OPENJDK_TARGET_AUTOCONF_NAME="$host" 15693 OPENJDK_BUILD_AUTOCONF_NAME="$build" 15694 15695 15696 15697 # Convert the autoconf OS/CPU value to our own data, into the VAR_OS/CPU variables. 15698 15699 case "$build_os" in 15700 *linux*) 15701 VAR_OS=linux 15702 VAR_OS_TYPE=unix 15703 ;; 15704 *solaris*) 15705 VAR_OS=solaris 15706 VAR_OS_TYPE=unix 15707 ;; 15708 *darwin*) 15709 VAR_OS=macosx 15710 VAR_OS_TYPE=unix 15711 ;; 15712 *bsd*) 15713 VAR_OS=bsd 15714 VAR_OS_TYPE=unix 15715 ;; 15716 *cygwin*) 15717 VAR_OS=windows 15718 VAR_OS_ENV=windows.cygwin 15719 ;; 15720 *mingw*) 15721 VAR_OS=windows 15722 VAR_OS_ENV=windows.msys 15723 ;; 15724 *aix*) 15725 VAR_OS=aix 15726 VAR_OS_TYPE=unix 15727 ;; 15728 *) 15729 as_fn_error $? "unsupported operating system $build_os" "$LINENO" 5 15730 ;; 15731 esac 15732 15733 15734 # First argument is the cpu name from the trip/quad 15735 case "$build_cpu" in 15736 x86_64) 15737 VAR_CPU=x86_64 15738 VAR_CPU_ARCH=x86 15739 VAR_CPU_BITS=64 15740 VAR_CPU_ENDIAN=little 15741 ;; 15742 i?86) 15743 VAR_CPU=x86 15744 VAR_CPU_ARCH=x86 15745 VAR_CPU_BITS=32 15746 VAR_CPU_ENDIAN=little 15747 ;; 15748 alpha*) 15749 VAR_CPU=alpha 15750 VAR_CPU_ARCH=alpha 15751 VAR_CPU_BITS=64 15752 VAR_CPU_ENDIAN=little 15753 ;; 15754 arm*) 15755 VAR_CPU=arm 15756 VAR_CPU_ARCH=arm 15757 VAR_CPU_BITS=32 15758 VAR_CPU_ENDIAN=little 15759 ;; 15760 aarch64) 15761 VAR_CPU=aarch64 15762 VAR_CPU_ARCH=aarch64 15763 VAR_CPU_BITS=64 15764 VAR_CPU_ENDIAN=little 15765 ;; 15766 m68k) 15767 VAR_CPU=m68k 15768 VAR_CPU_ARCH=m68k 15769 VAR_CPU_BITS=32 15770 VAR_CPU_ENDIAN=big 15771 ;; 15772 mips) 15773 VAR_CPU=mips 15774 VAR_CPU_ARCH=mips 15775 VAR_CPU_BITS=32 15776 VAR_CPU_ENDIAN=big 15777 ;; 15778 mipsel) 15779 VAR_CPU=mipsel 15780 VAR_CPU_ARCH=mipsel 15781 VAR_CPU_BITS=32 15782 VAR_CPU_ENDIAN=little 15783 ;; 15784 mips64) 15785 VAR_CPU=mips64 15786 VAR_CPU_ARCH=mips64 15787 VAR_CPU_BITS=64 15788 VAR_CPU_ENDIAN=big 15789 ;; 15790 mips64el) 15791 VAR_CPU=mips64el 15792 VAR_CPU_ARCH=mips64el 15793 VAR_CPU_BITS=64 15794 VAR_CPU_ENDIAN=little 15795 ;; 15796 powerpc) 15797 VAR_CPU=ppc 15798 VAR_CPU_ARCH=ppc 15799 VAR_CPU_BITS=32 15800 VAR_CPU_ENDIAN=big 15801 ;; 15802 powerpc64) 15803 VAR_CPU=ppc64 15804 VAR_CPU_ARCH=ppc 15805 VAR_CPU_BITS=64 15806 VAR_CPU_ENDIAN=big 15807 ;; 15808 powerpc64le) 15809 VAR_CPU=ppc64le 15810 VAR_CPU_ARCH=ppc 15811 VAR_CPU_BITS=64 15812 VAR_CPU_ENDIAN=little 15813 ;; 15814 s390) 15815 VAR_CPU=s390 15816 VAR_CPU_ARCH=s390 15817 VAR_CPU_BITS=32 15818 VAR_CPU_ENDIAN=big 15819 ;; 15820 s390x) 15821 VAR_CPU=s390x 15822 VAR_CPU_ARCH=s390 15823 VAR_CPU_BITS=64 15824 VAR_CPU_ENDIAN=big 15825 ;; 15826 sh*eb) 15827 VAR_CPU=sh 15828 VAR_CPU_ARCH=sh 15829 VAR_CPU_BITS=32 15830 VAR_CPU_ENDIAN=big 15831 ;; 15832 sh*) 15833 VAR_CPU=sh 15834 VAR_CPU_ARCH=sh 15835 VAR_CPU_BITS=32 15836 VAR_CPU_ENDIAN=little 15837 ;; 15838 sparc) 15839 VAR_CPU=sparc 15840 VAR_CPU_ARCH=sparc 15841 VAR_CPU_BITS=32 15842 VAR_CPU_ENDIAN=big 15843 ;; 15844 sparcv9|sparc64) 15845 VAR_CPU=sparcv9 15846 VAR_CPU_ARCH=sparc 15847 VAR_CPU_BITS=64 15848 VAR_CPU_ENDIAN=big 15849 ;; 15850 *) 15851 as_fn_error $? "unsupported cpu $build_cpu" "$LINENO" 5 15852 ;; 15853 esac 15854 15855 # ..and setup our own variables. (Do this explicitly to facilitate searching) 15856 OPENJDK_BUILD_OS="$VAR_OS" 15857 if test "x$VAR_OS_TYPE" != x; then 15858 OPENJDK_BUILD_OS_TYPE="$VAR_OS_TYPE" 15859 else 15860 OPENJDK_BUILD_OS_TYPE="$VAR_OS" 15861 fi 15862 if test "x$VAR_OS_ENV" != x; then 15863 OPENJDK_BUILD_OS_ENV="$VAR_OS_ENV" 15864 else 15865 OPENJDK_BUILD_OS_ENV="$VAR_OS" 15866 fi 15867 OPENJDK_BUILD_CPU="$VAR_CPU" 15868 OPENJDK_BUILD_CPU_ARCH="$VAR_CPU_ARCH" 15869 OPENJDK_BUILD_CPU_BITS="$VAR_CPU_BITS" 15870 OPENJDK_BUILD_CPU_ENDIAN="$VAR_CPU_ENDIAN" 15871 15872 15873 15874 15875 15876 15877 15878 15879 { $as_echo "$as_me:${as_lineno-$LINENO}: checking openjdk-build os-cpu" >&5 15880 $as_echo_n "checking openjdk-build os-cpu... " >&6; } 15881 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $OPENJDK_BUILD_OS-$OPENJDK_BUILD_CPU" >&5 15882 $as_echo "$OPENJDK_BUILD_OS-$OPENJDK_BUILD_CPU" >&6; } 15883 15884 # Convert the autoconf OS/CPU value to our own data, into the VAR_OS/CPU variables. 15885 15886 case "$host_os" in 15887 *linux*) 15888 VAR_OS=linux 15889 VAR_OS_TYPE=unix 15890 ;; 15891 *solaris*) 15892 VAR_OS=solaris 15893 VAR_OS_TYPE=unix 15894 ;; 15895 *darwin*) 15896 VAR_OS=macosx 15897 VAR_OS_TYPE=unix 15898 ;; 15899 *bsd*) 15900 VAR_OS=bsd 15901 VAR_OS_TYPE=unix 15902 ;; 15903 *cygwin*) 15904 VAR_OS=windows 15905 VAR_OS_ENV=windows.cygwin 15906 ;; 15907 *mingw*) 15908 VAR_OS=windows 15909 VAR_OS_ENV=windows.msys 15910 ;; 15911 *aix*) 15912 VAR_OS=aix 15913 VAR_OS_TYPE=unix 15914 ;; 15915 *) 15916 as_fn_error $? "unsupported operating system $host_os" "$LINENO" 5 15917 ;; 15918 esac 15919 15920 15921 # First argument is the cpu name from the trip/quad 15922 case "$host_cpu" in 15923 x86_64) 15924 VAR_CPU=x86_64 15925 VAR_CPU_ARCH=x86 15926 VAR_CPU_BITS=64 15927 VAR_CPU_ENDIAN=little 15928 ;; 15929 i?86) 15930 VAR_CPU=x86 15931 VAR_CPU_ARCH=x86 15932 VAR_CPU_BITS=32 15933 VAR_CPU_ENDIAN=little 15934 ;; 15935 alpha*) 15936 VAR_CPU=alpha 15937 VAR_CPU_ARCH=alpha 15938 VAR_CPU_BITS=64 15939 VAR_CPU_ENDIAN=little 15940 ;; 15941 arm*) 15942 VAR_CPU=arm 15943 VAR_CPU_ARCH=arm 15944 VAR_CPU_BITS=32 15945 VAR_CPU_ENDIAN=little 15946 ;; 15947 aarch64) 15948 VAR_CPU=aarch64 15949 VAR_CPU_ARCH=aarch64 15950 VAR_CPU_BITS=64 15951 VAR_CPU_ENDIAN=little 15952 ;; 15953 m68k) 15954 VAR_CPU=m68k 15955 VAR_CPU_ARCH=m68k 15956 VAR_CPU_BITS=32 15957 VAR_CPU_ENDIAN=big 15958 ;; 15959 mips) 15960 VAR_CPU=mips 15961 VAR_CPU_ARCH=mips 15962 VAR_CPU_BITS=32 15963 VAR_CPU_ENDIAN=big 15964 ;; 15965 mipsel) 15966 VAR_CPU=mipsel 15967 VAR_CPU_ARCH=mipsel 15968 VAR_CPU_BITS=32 15969 VAR_CPU_ENDIAN=little 15970 ;; 15971 mips64) 15972 VAR_CPU=mips64 15973 VAR_CPU_ARCH=mips64 15974 VAR_CPU_BITS=64 15975 VAR_CPU_ENDIAN=big 15976 ;; 15977 mips64el) 15978 VAR_CPU=mips64el 15979 VAR_CPU_ARCH=mips64el 15980 VAR_CPU_BITS=64 15981 VAR_CPU_ENDIAN=little 15982 ;; 15983 powerpc) 15984 VAR_CPU=ppc 15985 VAR_CPU_ARCH=ppc 15986 VAR_CPU_BITS=32 15987 VAR_CPU_ENDIAN=big 15988 ;; 15989 powerpc64) 15990 VAR_CPU=ppc64 15991 VAR_CPU_ARCH=ppc 15992 VAR_CPU_BITS=64 15993 VAR_CPU_ENDIAN=big 15994 ;; 15995 powerpc64le) 15996 VAR_CPU=ppc64le 15997 VAR_CPU_ARCH=ppc 15998 VAR_CPU_BITS=64 15999 VAR_CPU_ENDIAN=little 16000 ;; 16001 s390) 16002 VAR_CPU=s390 16003 VAR_CPU_ARCH=s390 16004 VAR_CPU_BITS=32 16005 VAR_CPU_ENDIAN=big 16006 ;; 16007 s390x) 16008 VAR_CPU=s390x 16009 VAR_CPU_ARCH=s390 16010 VAR_CPU_BITS=64 16011 VAR_CPU_ENDIAN=big 16012 ;; 16013 sh*eb) 16014 VAR_CPU=sh 16015 VAR_CPU_ARCH=sh 16016 VAR_CPU_BITS=32 16017 VAR_CPU_ENDIAN=big 16018 ;; 16019 sh*) 16020 VAR_CPU=sh 16021 VAR_CPU_ARCH=sh 16022 VAR_CPU_BITS=32 16023 VAR_CPU_ENDIAN=little 16024 ;; 16025 sparc) 16026 VAR_CPU=sparc 16027 VAR_CPU_ARCH=sparc 16028 VAR_CPU_BITS=32 16029 VAR_CPU_ENDIAN=big 16030 ;; 16031 sparcv9|sparc64) 16032 VAR_CPU=sparcv9 16033 VAR_CPU_ARCH=sparc 16034 VAR_CPU_BITS=64 16035 VAR_CPU_ENDIAN=big 16036 ;; 16037 *) 16038 as_fn_error $? "unsupported cpu $host_cpu" "$LINENO" 5 16039 ;; 16040 esac 16041 16042 # ... and setup our own variables. (Do this explicitly to facilitate searching) 16043 OPENJDK_TARGET_OS="$VAR_OS" 16044 if test "x$VAR_OS_TYPE" != x; then 16045 OPENJDK_TARGET_OS_TYPE="$VAR_OS_TYPE" 16046 else 16047 OPENJDK_TARGET_OS_TYPE="$VAR_OS" 16048 fi 16049 if test "x$VAR_OS_ENV" != x; then 16050 OPENJDK_TARGET_OS_ENV="$VAR_OS_ENV" 16051 else 16052 OPENJDK_TARGET_OS_ENV="$VAR_OS" 16053 fi 16054 OPENJDK_TARGET_CPU="$VAR_CPU" 16055 OPENJDK_TARGET_CPU_ARCH="$VAR_CPU_ARCH" 16056 OPENJDK_TARGET_CPU_BITS="$VAR_CPU_BITS" 16057 OPENJDK_TARGET_CPU_ENDIAN="$VAR_CPU_ENDIAN" 16058 16059 16060 16061 16062 16063 16064 16065 16066 { $as_echo "$as_me:${as_lineno-$LINENO}: checking openjdk-target os-cpu" >&5 16067 $as_echo_n "checking openjdk-target os-cpu... " >&6; } 16068 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $OPENJDK_TARGET_OS-$OPENJDK_TARGET_CPU" >&5 16069 $as_echo "$OPENJDK_TARGET_OS-$OPENJDK_TARGET_CPU" >&6; } 16070 16071 16072 16073 # Check whether --with-target-bits was given. 16074 if test "${with_target_bits+set}" = set; then : 16075 withval=$with_target_bits; 16076 fi 16077 16078 16079 # We have three types of compiles: 16080 # native == normal compilation, target system == build system 16081 # cross == traditional cross compilation, target system != build system; special toolchain needed 16082 # reduced == using native compilers, but with special flags (e.g. -m32) to produce 32-bit builds on 64-bit machines 16083 # 16084 if test "x$OPENJDK_BUILD_AUTOCONF_NAME" != "x$OPENJDK_TARGET_AUTOCONF_NAME"; then 16085 # We're doing a proper cross-compilation 16086 COMPILE_TYPE="cross" 16087 else 16088 COMPILE_TYPE="native" 16089 fi 16090 16091 if test "x$with_target_bits" != x; then 16092 if test "x$COMPILE_TYPE" = "xcross"; then 16093 as_fn_error $? "It is not possible to combine --with-target-bits=X and proper cross-compilation. Choose either." "$LINENO" 5 16094 fi 16095 16096 if test "x$with_target_bits" = x32 && test "x$OPENJDK_TARGET_CPU_BITS" = x64; then 16097 # A reduced build is requested 16098 COMPILE_TYPE="reduced" 16099 OPENJDK_TARGET_CPU_BITS=32 16100 if test "x$OPENJDK_TARGET_CPU_ARCH" = "xx86"; then 16101 OPENJDK_TARGET_CPU=x86 16102 elif test "x$OPENJDK_TARGET_CPU_ARCH" = "xsparc"; then 16103 OPENJDK_TARGET_CPU=sparc 16104 else 16105 as_fn_error $? "Reduced build (--with-target-bits=32) is only supported on x86_64 and sparcv9" "$LINENO" 5 16106 fi 16107 elif test "x$with_target_bits" = x64 && test "x$OPENJDK_TARGET_CPU_BITS" = x32; then 16108 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 16109 elif test "x$with_target_bits" = "x$OPENJDK_TARGET_CPU_BITS"; then 16110 { $as_echo "$as_me:${as_lineno-$LINENO}: --with-target-bits are set to build platform address size; argument has no meaning" >&5 16111 $as_echo "$as_me: --with-target-bits are set to build platform address size; argument has no meaning" >&6;} 16112 else 16113 as_fn_error $? "--with-target-bits can only be 32 or 64, you specified $with_target_bits!" "$LINENO" 5 16114 fi 16115 fi 16116 16117 16118 { $as_echo "$as_me:${as_lineno-$LINENO}: checking compilation type" >&5 16119 $as_echo_n "checking compilation type... " >&6; } 16120 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $COMPILE_TYPE" >&5 16121 $as_echo "$COMPILE_TYPE" >&6; } 16122 16123 16124 if test "x$OPENJDK_TARGET_OS" = xmacosx; then 16125 OPENJDK_MODULE_TARGET_OS_NAME="macos" 16126 else 16127 OPENJDK_MODULE_TARGET_OS_NAME="$OPENJDK_TARGET_OS" 16128 fi 16129 16130 if test "x$OPENJDK_TARGET_CPU" = xx86_64; then 16131 OPENJDK_MODULE_TARGET_OS_ARCH="amd64" 16132 else 16133 OPENJDK_MODULE_TARGET_OS_ARCH="$OPENJDK_TARGET_CPU" 16134 fi 16135 16136 OPENJDK_MODULE_TARGET_PLATFORM="${OPENJDK_MODULE_TARGET_OS_NAME}-${OPENJDK_MODULE_TARGET_OS_ARCH}" 16137 16138 16139 16140 if test "x$OPENJDK_TARGET_OS" = "xsolaris"; then 16141 RELEASE_FILE_OS_NAME=SunOS 16142 fi 16143 if test "x$OPENJDK_TARGET_OS" = "xlinux"; then 16144 RELEASE_FILE_OS_NAME=Linux 16145 fi 16146 if test "x$OPENJDK_TARGET_OS" = "xwindows"; then 16147 RELEASE_FILE_OS_NAME=Windows 16148 fi 16149 if test "x$OPENJDK_TARGET_OS" = xmacosx; then 16150 RELEASE_FILE_OS_NAME="Darwin" 16151 fi 16152 if test "x$OPENJDK_TARGET_OS" = "xaix"; then 16153 RELEASE_FILE_OS_NAME="AIX" 16154 fi 16155 RELEASE_FILE_OS_ARCH=${OPENJDK_TARGET_CPU} 16156 16157 16158 16159 16160 16161 16162 # Also store the legacy naming of the cpu. 16163 # Ie i586 and amd64 instead of x86 and x86_64 16164 OPENJDK_TARGET_CPU_LEGACY="$OPENJDK_TARGET_CPU" 16165 if test "x$OPENJDK_TARGET_CPU" = xx86; then 16166 OPENJDK_TARGET_CPU_LEGACY="i586" 16167 elif test "x$OPENJDK_TARGET_OS" != xmacosx && test "x$OPENJDK_TARGET_CPU" = xx86_64; then 16168 # On all platforms except MacOSX replace x86_64 with amd64. 16169 OPENJDK_TARGET_CPU_LEGACY="amd64" 16170 elif test "x$OPENJDK_TARGET_CPU" = xalpha; then 16171 # Avoid name collisions with variables named alpha 16172 OPENJDK_TARGET_CPU_LEGACY="_alpha_" 16173 elif test "x$OPENJDK_TARGET_CPU" = xsh; then 16174 # Avoid name collisions with variables named sh 16175 OPENJDK_TARGET_CPU_LEGACY="_sh_" 16176 fi 16177 16178 16179 # And the second legacy naming of the cpu. 16180 # Ie i386 and amd64 instead of x86 and x86_64. 16181 OPENJDK_TARGET_CPU_LEGACY_LIB="$OPENJDK_TARGET_CPU" 16182 if test "x$OPENJDK_TARGET_CPU" = xx86; then 16183 OPENJDK_TARGET_CPU_LEGACY_LIB="i386" 16184 elif test "x$OPENJDK_TARGET_CPU" = xx86_64; then 16185 OPENJDK_TARGET_CPU_LEGACY_LIB="amd64" 16186 fi 16187 16188 16189 # OPENJDK_TARGET_CPU_ISADIR is normally empty. On 64-bit Solaris systems, it is set to 16190 # /amd64 or /sparcv9. This string is appended to some library paths, like this: 16191 # /usr/lib${OPENJDK_TARGET_CPU_ISADIR}/libexample.so 16192 OPENJDK_TARGET_CPU_ISADIR="" 16193 if test "x$OPENJDK_TARGET_OS" = xsolaris; then 16194 if test "x$OPENJDK_TARGET_CPU" = xx86_64; then 16195 OPENJDK_TARGET_CPU_ISADIR="/amd64" 16196 elif test "x$OPENJDK_TARGET_CPU" = xsparcv9; then 16197 OPENJDK_TARGET_CPU_ISADIR="/sparcv9" 16198 fi 16199 fi 16200 16201 16202 # Setup OPENJDK_TARGET_CPU_OSARCH, which is used to set the os.arch Java system property 16203 OPENJDK_TARGET_CPU_OSARCH="$OPENJDK_TARGET_CPU" 16204 if test "x$OPENJDK_TARGET_OS" = xlinux && test "x$OPENJDK_TARGET_CPU" = xx86; then 16205 # On linux only, we replace x86 with i386. 16206 OPENJDK_TARGET_CPU_OSARCH="i386" 16207 elif test "x$OPENJDK_TARGET_OS" != xmacosx && test "x$OPENJDK_TARGET_CPU" = xx86_64; then 16208 # On all platforms except macosx, we replace x86_64 with amd64. 16209 OPENJDK_TARGET_CPU_OSARCH="amd64" 16210 fi 16211 16212 16213 OPENJDK_TARGET_CPU_JLI="$OPENJDK_TARGET_CPU" 16214 if test "x$OPENJDK_TARGET_CPU" = xx86; then 16215 OPENJDK_TARGET_CPU_JLI="i386" 16216 elif test "x$OPENJDK_TARGET_OS" != xmacosx && test "x$OPENJDK_TARGET_CPU" = xx86_64; then 16217 # On all platforms except macosx, we replace x86_64 with amd64. 16218 OPENJDK_TARGET_CPU_JLI="amd64" 16219 fi 16220 16221 # The new version string in JDK 9 also defined new naming of OS and ARCH for bundles 16222 # Macosx is osx and x86_64 is x64 16223 if test "x$OPENJDK_TARGET_OS" = xmacosx; then 16224 OPENJDK_TARGET_OS_BUNDLE="osx" 16225 else 16226 OPENJDK_TARGET_OS_BUNDLE="$OPENJDK_TARGET_OS" 16227 fi 16228 if test "x$OPENJDK_TARGET_CPU" = xx86_64; then 16229 OPENJDK_TARGET_CPU_BUNDLE="x64" 16230 else 16231 OPENJDK_TARGET_CPU_BUNDLE="$OPENJDK_TARGET_CPU" 16232 fi 16233 OPENJDK_TARGET_BUNDLE_PLATFORM="${OPENJDK_TARGET_OS_BUNDLE}-${OPENJDK_TARGET_CPU_BUNDLE}" 16234 16235 16236 if test "x$OPENJDK_TARGET_CPU_BITS" = x64; then 16237 # -D_LP64=1 is only set on linux and mac. Setting on windows causes diff in 16238 # unpack200.exe. This variable is used in 16239 # FLAGS_SETUP_COMPILER_FLAGS_FOR_JDK_HELPER. 16240 if test "x$OPENJDK_TARGET_OS" = xlinux || test "x$OPENJDK_TARGET_OS" = xmacosx; then 16241 OPENJDK_TARGET_ADD_LP64="-D_LP64=1" 16242 fi 16243 fi 16244 16245 if test "x$COMPILE_TYPE" = "xcross"; then 16246 # FIXME: ... or should this include reduced builds..? 16247 DEFINE_CROSS_COMPILE_ARCH="CROSS_COMPILE_ARCH:=$OPENJDK_TARGET_CPU_LEGACY" 16248 else 16249 DEFINE_CROSS_COMPILE_ARCH="" 16250 fi 16251 16252 16253 # Convert openjdk platform names to hotspot names 16254 16255 HOTSPOT_TARGET_OS=${OPENJDK_TARGET_OS} 16256 if test "x$OPENJDK_TARGET_OS" = xmacosx; then 16257 HOTSPOT_TARGET_OS=bsd 16258 fi 16259 16260 16261 HOTSPOT_TARGET_OS_TYPE=${OPENJDK_TARGET_OS_TYPE} 16262 if test "x$OPENJDK_TARGET_OS_TYPE" = xunix; then 16263 HOTSPOT_TARGET_OS_TYPE=posix 16264 fi 16265 16266 16267 HOTSPOT_TARGET_CPU=${OPENJDK_TARGET_CPU} 16268 if test "x$OPENJDK_TARGET_CPU" = xx86; then 16269 HOTSPOT_TARGET_CPU=x86_32 16270 elif test "x$OPENJDK_TARGET_CPU" = xsparcv9; then 16271 HOTSPOT_TARGET_CPU=sparc 16272 elif test "x$OPENJDK_TARGET_CPU" = xppc64; then 16273 HOTSPOT_TARGET_CPU=ppc_64 16274 elif test "x$OPENJDK_TARGET_CPU" = xppc64le; then 16275 HOTSPOT_TARGET_CPU=ppc_64 16276 fi 16277 16278 16279 # This is identical with OPENJDK_*, but define anyway for consistency. 16280 HOTSPOT_TARGET_CPU_ARCH=${OPENJDK_TARGET_CPU_ARCH} 16281 16282 16283 # Setup HOTSPOT_TARGET_CPU_DEFINE 16284 if test "x$OPENJDK_TARGET_CPU" = xx86; then 16285 HOTSPOT_TARGET_CPU_DEFINE=IA32 16286 elif test "x$OPENJDK_TARGET_CPU" = xx86_64; then 16287 HOTSPOT_TARGET_CPU_DEFINE=AMD64 16288 elif test "x$OPENJDK_TARGET_CPU" = xsparcv9; then 16289 HOTSPOT_TARGET_CPU_DEFINE=SPARC 16290 elif test "x$OPENJDK_TARGET_CPU" = xaarch64; then 16291 HOTSPOT_TARGET_CPU_DEFINE=AARCH64 16292 elif test "x$OPENJDK_TARGET_CPU" = xppc64; then 16293 HOTSPOT_TARGET_CPU_DEFINE=PPC64 16294 elif test "x$OPENJDK_TARGET_CPU" = xppc64le; then 16295 HOTSPOT_TARGET_CPU_DEFINE=PPC64 16296 16297 # The cpu defines below are for zero, we don't support them directly. 16298 elif test "x$OPENJDK_TARGET_CPU" = xsparc; then 16299 HOTSPOT_TARGET_CPU_DEFINE=SPARC 16300 elif test "x$OPENJDK_TARGET_CPU" = xppc; then 16301 HOTSPOT_TARGET_CPU_DEFINE=PPC32 16302 elif test "x$OPENJDK_TARGET_CPU" = xs390; then 16303 HOTSPOT_TARGET_CPU_DEFINE=S390 16304 elif test "x$OPENJDK_TARGET_CPU" = xs390x; then 16305 HOTSPOT_TARGET_CPU_DEFINE=S390 16306 elif test "x$OPENJDK_TARGET_CPU" != x; then 16307 HOTSPOT_TARGET_CPU_DEFINE=$(echo $OPENJDK_TARGET_CPU | tr a-z A-Z) 16308 fi 16309 16310 16311 # For historical reasons, the OS include directories have odd names. 16312 OPENJDK_TARGET_OS_INCLUDE_SUBDIR="$OPENJDK_TARGET_OS" 16313 if test "x$OPENJDK_TARGET_OS" = "xwindows"; then 16314 OPENJDK_TARGET_OS_INCLUDE_SUBDIR="win32" 16315 elif test "x$OPENJDK_TARGET_OS" = "xmacosx"; then 16316 OPENJDK_TARGET_OS_INCLUDE_SUBDIR="darwin" 16317 fi 16318 16319 16320 16321 # Also store the legacy naming of the cpu. 16322 # Ie i586 and amd64 instead of x86 and x86_64 16323 OPENJDK_BUILD_CPU_LEGACY="$OPENJDK_BUILD_CPU" 16324 if test "x$OPENJDK_BUILD_CPU" = xx86; then 16325 OPENJDK_BUILD_CPU_LEGACY="i586" 16326 elif test "x$OPENJDK_BUILD_OS" != xmacosx && test "x$OPENJDK_BUILD_CPU" = xx86_64; then 16327 # On all platforms except MacOSX replace x86_64 with amd64. 16328 OPENJDK_BUILD_CPU_LEGACY="amd64" 16329 elif test "x$OPENJDK_BUILD_CPU" = xalpha; then 16330 # Avoid name collisions with variables named alpha 16331 OPENJDK_BUILD_CPU_LEGACY="_alpha_" 16332 elif test "x$OPENJDK_BUILD_CPU" = xsh; then 16333 # Avoid name collisions with variables named sh 16334 OPENJDK_BUILD_CPU_LEGACY="_sh_" 16335 fi 16336 16337 16338 # And the second legacy naming of the cpu. 16339 # Ie i386 and amd64 instead of x86 and x86_64. 16340 OPENJDK_BUILD_CPU_LEGACY_LIB="$OPENJDK_BUILD_CPU" 16341 if test "x$OPENJDK_BUILD_CPU" = xx86; then 16342 OPENJDK_BUILD_CPU_LEGACY_LIB="i386" 16343 elif test "x$OPENJDK_BUILD_CPU" = xx86_64; then 16344 OPENJDK_BUILD_CPU_LEGACY_LIB="amd64" 16345 fi 16346 16347 16348 # OPENJDK_BUILD_CPU_ISADIR is normally empty. On 64-bit Solaris systems, it is set to 16349 # /amd64 or /sparcv9. This string is appended to some library paths, like this: 16350 # /usr/lib${OPENJDK_BUILD_CPU_ISADIR}/libexample.so 16351 OPENJDK_BUILD_CPU_ISADIR="" 16352 if test "x$OPENJDK_BUILD_OS" = xsolaris; then 16353 if test "x$OPENJDK_BUILD_CPU" = xx86_64; then 16354 OPENJDK_BUILD_CPU_ISADIR="/amd64" 16355 elif test "x$OPENJDK_BUILD_CPU" = xsparcv9; then 16356 OPENJDK_BUILD_CPU_ISADIR="/sparcv9" 16357 fi 16358 fi 16359 16360 16361 # Setup OPENJDK_BUILD_CPU_OSARCH, which is used to set the os.arch Java system property 16362 OPENJDK_BUILD_CPU_OSARCH="$OPENJDK_BUILD_CPU" 16363 if test "x$OPENJDK_BUILD_OS" = xlinux && test "x$OPENJDK_BUILD_CPU" = xx86; then 16364 # On linux only, we replace x86 with i386. 16365 OPENJDK_BUILD_CPU_OSARCH="i386" 16366 elif test "x$OPENJDK_BUILD_OS" != xmacosx && test "x$OPENJDK_BUILD_CPU" = xx86_64; then 16367 # On all platforms except macosx, we replace x86_64 with amd64. 16368 OPENJDK_BUILD_CPU_OSARCH="amd64" 16369 fi 16370 16371 16372 OPENJDK_BUILD_CPU_JLI="$OPENJDK_BUILD_CPU" 16373 if test "x$OPENJDK_BUILD_CPU" = xx86; then 16374 OPENJDK_BUILD_CPU_JLI="i386" 16375 elif test "x$OPENJDK_BUILD_OS" != xmacosx && test "x$OPENJDK_BUILD_CPU" = xx86_64; then 16376 # On all platforms except macosx, we replace x86_64 with amd64. 16377 OPENJDK_BUILD_CPU_JLI="amd64" 16378 fi 16379 16380 # The new version string in JDK 9 also defined new naming of OS and ARCH for bundles 16381 # Macosx is osx and x86_64 is x64 16382 if test "x$OPENJDK_BUILD_OS" = xmacosx; then 16383 OPENJDK_BUILD_OS_BUNDLE="osx" 16384 else 16385 OPENJDK_BUILD_OS_BUNDLE="$OPENJDK_TARGET_OS" 16386 fi 16387 if test "x$OPENJDK_BUILD_CPU" = xx86_64; then 16388 OPENJDK_BUILD_CPU_BUNDLE="x64" 16389 else 16390 OPENJDK_BUILD_CPU_BUNDLE="$OPENJDK_BUILD_CPU" 16391 fi 16392 OPENJDK_BUILD_BUNDLE_PLATFORM="${OPENJDK_BUILD_OS_BUNDLE}-${OPENJDK_BUILD_CPU_BUNDLE}" 16393 16394 16395 if test "x$OPENJDK_BUILD_CPU_BITS" = x64; then 16396 # -D_LP64=1 is only set on linux and mac. Setting on windows causes diff in 16397 # unpack200.exe. This variable is used in 16398 # FLAGS_SETUP_COMPILER_FLAGS_FOR_JDK_HELPER. 16399 if test "x$OPENJDK_BUILD_OS" = xlinux || test "x$OPENJDK_BUILD_OS" = xmacosx; then 16400 OPENJDK_BUILD_ADD_LP64="-D_LP64=1" 16401 fi 16402 fi 16403 16404 if test "x$COMPILE_TYPE" = "xcross"; then 16405 # FIXME: ... or should this include reduced builds..? 16406 DEFINE_CROSS_COMPILE_ARCH="CROSS_COMPILE_ARCH:=$OPENJDK_BUILD_CPU_LEGACY" 16407 else 16408 DEFINE_CROSS_COMPILE_ARCH="" 16409 fi 16410 16411 16412 # Convert openjdk platform names to hotspot names 16413 16414 HOTSPOT_BUILD_OS=${OPENJDK_BUILD_OS} 16415 if test "x$OPENJDK_BUILD_OS" = xmacosx; then 16416 HOTSPOT_BUILD_OS=bsd 16417 fi 16418 16419 16420 HOTSPOT_BUILD_OS_TYPE=${OPENJDK_BUILD_OS_TYPE} 16421 if test "x$OPENJDK_BUILD_OS_TYPE" = xunix; then 16422 HOTSPOT_BUILD_OS_TYPE=posix 16423 fi 16424 16425 16426 HOTSPOT_BUILD_CPU=${OPENJDK_BUILD_CPU} 16427 if test "x$OPENJDK_BUILD_CPU" = xx86; then 16428 HOTSPOT_BUILD_CPU=x86_32 16429 elif test "x$OPENJDK_BUILD_CPU" = xsparcv9; then 16430 HOTSPOT_BUILD_CPU=sparc 16431 elif test "x$OPENJDK_BUILD_CPU" = xppc64; then 16432 HOTSPOT_BUILD_CPU=ppc_64 16433 elif test "x$OPENJDK_BUILD_CPU" = xppc64le; then 16434 HOTSPOT_BUILD_CPU=ppc_64 16435 fi 16436 16437 16438 # This is identical with OPENJDK_*, but define anyway for consistency. 16439 HOTSPOT_BUILD_CPU_ARCH=${OPENJDK_BUILD_CPU_ARCH} 16440 16441 16442 # Setup HOTSPOT_BUILD_CPU_DEFINE 16443 if test "x$OPENJDK_BUILD_CPU" = xx86; then 16444 HOTSPOT_BUILD_CPU_DEFINE=IA32 16445 elif test "x$OPENJDK_BUILD_CPU" = xx86_64; then 16446 HOTSPOT_BUILD_CPU_DEFINE=AMD64 16447 elif test "x$OPENJDK_BUILD_CPU" = xsparcv9; then 16448 HOTSPOT_BUILD_CPU_DEFINE=SPARC 16449 elif test "x$OPENJDK_BUILD_CPU" = xaarch64; then 16450 HOTSPOT_BUILD_CPU_DEFINE=AARCH64 16451 elif test "x$OPENJDK_BUILD_CPU" = xppc64; then 16452 HOTSPOT_BUILD_CPU_DEFINE=PPC64 16453 elif test "x$OPENJDK_BUILD_CPU" = xppc64le; then 16454 HOTSPOT_BUILD_CPU_DEFINE=PPC64 16455 16456 # The cpu defines below are for zero, we don't support them directly. 16457 elif test "x$OPENJDK_BUILD_CPU" = xsparc; then 16458 HOTSPOT_BUILD_CPU_DEFINE=SPARC 16459 elif test "x$OPENJDK_BUILD_CPU" = xppc; then 16460 HOTSPOT_BUILD_CPU_DEFINE=PPC32 16461 elif test "x$OPENJDK_BUILD_CPU" = xs390; then 16462 HOTSPOT_BUILD_CPU_DEFINE=S390 16463 elif test "x$OPENJDK_BUILD_CPU" = xs390x; then 16464 HOTSPOT_BUILD_CPU_DEFINE=S390 16465 elif test "x$OPENJDK_BUILD_CPU" != x; then 16466 HOTSPOT_BUILD_CPU_DEFINE=$(echo $OPENJDK_BUILD_CPU | tr a-z A-Z) 16467 fi 16468 16469 16470 # For historical reasons, the OS include directories have odd names. 16471 OPENJDK_BUILD_OS_INCLUDE_SUBDIR="$OPENJDK_TARGET_OS" 16472 if test "x$OPENJDK_TARGET_OS" = "xwindows"; then 16473 OPENJDK_BUILD_OS_INCLUDE_SUBDIR="win32" 16474 elif test "x$OPENJDK_TARGET_OS" = "xmacosx"; then 16475 OPENJDK_BUILD_OS_INCLUDE_SUBDIR="darwin" 16476 fi 16477 16478 16479 16480 16481 16482 # Continue setting up basic stuff. Most remaining code require fundamental tools. 16483 16484 # Save the current directory this script was started from 16485 CURDIR="$PWD" 16486 16487 # We might need to rewrite ORIGINAL_PATH, if it includes "#", to quote them 16488 # for make. We couldn't do this when we retrieved ORIGINAL_PATH, since SED 16489 # was not available at that time. 16490 REWRITTEN_PATH=`$ECHO "$ORIGINAL_PATH" | $SED -e 's/#/\\\\#/g'` 16491 if test "x$REWRITTEN_PATH" != "x$ORIGINAL_PATH"; then 16492 ORIGINAL_PATH="$REWRITTEN_PATH" 16493 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting ORIGINAL_PATH to $REWRITTEN_PATH" >&5 16494 $as_echo "$as_me: Rewriting ORIGINAL_PATH to $REWRITTEN_PATH" >&6;} 16495 fi 16496 16497 if test "x$OPENJDK_TARGET_OS" = "xwindows"; then 16498 PATH_SEP=";" 16499 16500 SRC_ROOT_LENGTH=`$THEPWDCMD -L|$WC -m` 16501 if test $SRC_ROOT_LENGTH -gt 100; then 16502 as_fn_error $? "Your base path is too long. It is $SRC_ROOT_LENGTH characters long, but only 100 is supported" "$LINENO" 5 16503 fi 16504 16505 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 16506 { $as_echo "$as_me:${as_lineno-$LINENO}: checking cygwin release" >&5 16507 $as_echo_n "checking cygwin release... " >&6; } 16508 CYGWIN_VERSION=`$UNAME -r` 16509 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CYGWIN_VERSION" >&5 16510 $as_echo "$CYGWIN_VERSION" >&6; } 16511 WINDOWS_ENV_VENDOR='cygwin' 16512 WINDOWS_ENV_VERSION="$CYGWIN_VERSION" 16513 16514 CYGWIN_VERSION_OLD=`$ECHO $CYGWIN_VERSION | $GREP -e '^1\.0-6'` 16515 if test "x$CYGWIN_VERSION_OLD" != x; then 16516 { $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 16517 $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;} 16518 as_fn_error $? "Cannot continue" "$LINENO" 5 16519 fi 16520 if test "x$CYGPATH" = x; then 16521 as_fn_error $? "Something is wrong with your cygwin installation since I cannot find cygpath.exe in your path" "$LINENO" 5 16522 fi 16523 { $as_echo "$as_me:${as_lineno-$LINENO}: checking cygwin root directory as unix-style path" >&5 16524 $as_echo_n "checking cygwin root directory as unix-style path... " >&6; } 16525 # The cmd output ends with Windows line endings (CR/LF) 16526 cygwin_winpath_root=`cd / ; cmd /c cd | $TR -d '\r\n'` 16527 # Force cygpath to report the proper root by including a trailing space, and then stripping it off again. 16528 CYGWIN_ROOT_PATH=`$CYGPATH -u "$cygwin_winpath_root " | $CUT -f 1 -d " "` 16529 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CYGWIN_ROOT_PATH" >&5 16530 $as_echo "$CYGWIN_ROOT_PATH" >&6; } 16531 WINDOWS_ENV_ROOT_PATH="$CYGWIN_ROOT_PATH" 16532 test_cygdrive_prefix=`$ECHO $CYGWIN_ROOT_PATH | $GREP ^/cygdrive/` 16533 if test "x$test_cygdrive_prefix" = x; then 16534 as_fn_error $? "Your cygdrive prefix is not /cygdrive. This is currently not supported. Change with mount -c." "$LINENO" 5 16535 fi 16536 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 16537 { $as_echo "$as_me:${as_lineno-$LINENO}: checking msys release" >&5 16538 $as_echo_n "checking msys release... " >&6; } 16539 MSYS_VERSION=`$UNAME -r` 16540 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MSYS_VERSION" >&5 16541 $as_echo "$MSYS_VERSION" >&6; } 16542 16543 WINDOWS_ENV_VENDOR='msys' 16544 WINDOWS_ENV_VERSION="$MSYS_VERSION" 16545 16546 { $as_echo "$as_me:${as_lineno-$LINENO}: checking msys root directory as unix-style path" >&5 16547 $as_echo_n "checking msys root directory as unix-style path... " >&6; } 16548 # The cmd output ends with Windows line endings (CR/LF), the grep command will strip that away 16549 MSYS_ROOT_PATH=`cd / ; cmd /c cd | $GREP ".*"` 16550 16551 windows_path="$MSYS_ROOT_PATH" 16552 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 16553 unix_path=`$CYGPATH -u "$windows_path"` 16554 MSYS_ROOT_PATH="$unix_path" 16555 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 16556 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 16557 MSYS_ROOT_PATH="$unix_path" 16558 fi 16559 16560 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MSYS_ROOT_PATH" >&5 16561 $as_echo "$MSYS_ROOT_PATH" >&6; } 16562 WINDOWS_ENV_ROOT_PATH="$MSYS_ROOT_PATH" 16563 else 16564 as_fn_error $? "Unknown Windows environment. Neither cygwin nor msys was detected." "$LINENO" 5 16565 fi 16566 16567 # Test if windows or unix (cygwin/msys) find is first in path. 16568 { $as_echo "$as_me:${as_lineno-$LINENO}: checking what kind of 'find' is first on the PATH" >&5 16569 $as_echo_n "checking what kind of 'find' is first on the PATH... " >&6; } 16570 FIND_BINARY_OUTPUT=`find --version 2>&1` 16571 if test "x`echo $FIND_BINARY_OUTPUT | $GREP GNU`" != x; then 16572 { $as_echo "$as_me:${as_lineno-$LINENO}: result: unix style" >&5 16573 $as_echo "unix style" >&6; } 16574 elif test "x`echo $FIND_BINARY_OUTPUT | $GREP FIND`" != x; then 16575 { $as_echo "$as_me:${as_lineno-$LINENO}: result: Windows" >&5 16576 $as_echo "Windows" >&6; } 16577 { $as_echo "$as_me:${as_lineno-$LINENO}: Your path contains Windows tools (C:\Windows\system32) before your unix (cygwin or msys) tools." >&5 16578 $as_echo "$as_me: Your path contains Windows tools (C:\Windows\system32) before your unix (cygwin or msys) tools." >&6;} 16579 { $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 16580 $as_echo "$as_me: This will not work. Please correct and make sure /usr/bin (or similar) is first in path." >&6;} 16581 as_fn_error $? "Cannot continue" "$LINENO" 5 16582 else 16583 { $as_echo "$as_me:${as_lineno-$LINENO}: result: unknown" >&5 16584 $as_echo "unknown" >&6; } 16585 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: It seems that your find utility is non-standard." >&5 16586 $as_echo "$as_me: WARNING: It seems that your find utility is non-standard." >&2;} 16587 fi 16588 16589 else 16590 PATH_SEP=":" 16591 fi 16592 16593 16594 # We get the top-level directory from the supporting wrappers. 16595 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for top-level directory" >&5 16596 $as_echo_n "checking for top-level directory... " >&6; } 16597 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $TOPDIR" >&5 16598 $as_echo "$TOPDIR" >&6; } 16599 16600 16601 # We can only call BASIC_FIXUP_PATH after BASIC_CHECK_PATHS_WINDOWS. 16602 16603 # Only process if variable expands to non-empty 16604 16605 if test "x$CURDIR" != x; then 16606 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 16607 16608 # Input might be given as Windows format, start by converting to 16609 # unix format. 16610 path="$CURDIR" 16611 new_path=`$CYGPATH -u "$path"` 16612 16613 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 16614 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 16615 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 16616 # "foo.exe" is OK but "foo" is an error. 16617 # 16618 # This test is therefore slightly more accurate than "test -f" to check for file precense. 16619 # It is also a way to make sure we got the proper file name for the real test later on. 16620 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 16621 if test "x$test_shortpath" = x; then 16622 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of CURDIR, which resolves as \"$path\", is invalid." >&5 16623 $as_echo "$as_me: The path of CURDIR, which resolves as \"$path\", is invalid." >&6;} 16624 as_fn_error $? "Cannot locate the the path of CURDIR" "$LINENO" 5 16625 fi 16626 16627 # Call helper function which possibly converts this using DOS-style short mode. 16628 # If so, the updated path is stored in $new_path. 16629 16630 input_path="$new_path" 16631 # Check if we need to convert this using DOS-style short mode. If the path 16632 # contains just simple characters, use it. Otherwise (spaces, weird characters), 16633 # take no chances and rewrite it. 16634 # Note: m4 eats our [], so we need to use [ and ] instead. 16635 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 16636 if test "x$has_forbidden_chars" != x; then 16637 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 16638 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 16639 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 16640 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 16641 # Going to short mode and back again did indeed matter. Since short mode is 16642 # case insensitive, let's make it lowercase to improve readability. 16643 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 16644 # Now convert it back to Unix-style (cygpath) 16645 input_path=`$CYGPATH -u "$shortmode_path"` 16646 new_path="$input_path" 16647 fi 16648 fi 16649 16650 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 16651 if test "x$test_cygdrive_prefix" = x; then 16652 # As a simple fix, exclude /usr/bin since it's not a real path. 16653 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 16654 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 16655 # a path prefixed by /cygdrive for fixpath to work. 16656 new_path="$CYGWIN_ROOT_PATH$input_path" 16657 fi 16658 fi 16659 16660 16661 if test "x$path" != "x$new_path"; then 16662 CURDIR="$new_path" 16663 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting CURDIR to \"$new_path\"" >&5 16664 $as_echo "$as_me: Rewriting CURDIR to \"$new_path\"" >&6;} 16665 fi 16666 16667 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 16668 16669 path="$CURDIR" 16670 has_colon=`$ECHO $path | $GREP ^.:` 16671 new_path="$path" 16672 if test "x$has_colon" = x; then 16673 # Not in mixed or Windows style, start by that. 16674 new_path=`cmd //c echo $path` 16675 fi 16676 16677 16678 input_path="$new_path" 16679 # Check if we need to convert this using DOS-style short mode. If the path 16680 # contains just simple characters, use it. Otherwise (spaces, weird characters), 16681 # take no chances and rewrite it. 16682 # Note: m4 eats our [], so we need to use [ and ] instead. 16683 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 16684 if test "x$has_forbidden_chars" != x; then 16685 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 16686 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 16687 fi 16688 16689 16690 windows_path="$new_path" 16691 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 16692 unix_path=`$CYGPATH -u "$windows_path"` 16693 new_path="$unix_path" 16694 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 16695 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 16696 new_path="$unix_path" 16697 fi 16698 16699 if test "x$path" != "x$new_path"; then 16700 CURDIR="$new_path" 16701 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting CURDIR to \"$new_path\"" >&5 16702 $as_echo "$as_me: Rewriting CURDIR to \"$new_path\"" >&6;} 16703 fi 16704 16705 # Save the first 10 bytes of this path to the storage, so fixpath can work. 16706 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 16707 16708 else 16709 # We're on a unix platform. Hooray! :) 16710 path="$CURDIR" 16711 has_space=`$ECHO "$path" | $GREP " "` 16712 if test "x$has_space" != x; then 16713 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of CURDIR, which resolves as \"$path\", is invalid." >&5 16714 $as_echo "$as_me: The path of CURDIR, which resolves as \"$path\", is invalid." >&6;} 16715 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 16716 fi 16717 16718 # Use eval to expand a potential ~ 16719 eval path="$path" 16720 if test ! -f "$path" && test ! -d "$path"; then 16721 as_fn_error $? "The path of CURDIR, which resolves as \"$path\", is not found." "$LINENO" 5 16722 fi 16723 16724 if test -d "$path"; then 16725 CURDIR="`cd "$path"; $THEPWDCMD -L`" 16726 else 16727 dir="`$DIRNAME "$path"`" 16728 base="`$BASENAME "$path"`" 16729 CURDIR="`cd "$dir"; $THEPWDCMD -L`/$base" 16730 fi 16731 fi 16732 fi 16733 16734 16735 # Only process if variable expands to non-empty 16736 16737 if test "x$TOPDIR" != x; then 16738 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 16739 16740 # Input might be given as Windows format, start by converting to 16741 # unix format. 16742 path="$TOPDIR" 16743 new_path=`$CYGPATH -u "$path"` 16744 16745 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 16746 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 16747 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 16748 # "foo.exe" is OK but "foo" is an error. 16749 # 16750 # This test is therefore slightly more accurate than "test -f" to check for file precense. 16751 # It is also a way to make sure we got the proper file name for the real test later on. 16752 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 16753 if test "x$test_shortpath" = x; then 16754 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of TOPDIR, which resolves as \"$path\", is invalid." >&5 16755 $as_echo "$as_me: The path of TOPDIR, which resolves as \"$path\", is invalid." >&6;} 16756 as_fn_error $? "Cannot locate the the path of TOPDIR" "$LINENO" 5 16757 fi 16758 16759 # Call helper function which possibly converts this using DOS-style short mode. 16760 # If so, the updated path is stored in $new_path. 16761 16762 input_path="$new_path" 16763 # Check if we need to convert this using DOS-style short mode. If the path 16764 # contains just simple characters, use it. Otherwise (spaces, weird characters), 16765 # take no chances and rewrite it. 16766 # Note: m4 eats our [], so we need to use [ and ] instead. 16767 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 16768 if test "x$has_forbidden_chars" != x; then 16769 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 16770 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 16771 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 16772 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 16773 # Going to short mode and back again did indeed matter. Since short mode is 16774 # case insensitive, let's make it lowercase to improve readability. 16775 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 16776 # Now convert it back to Unix-style (cygpath) 16777 input_path=`$CYGPATH -u "$shortmode_path"` 16778 new_path="$input_path" 16779 fi 16780 fi 16781 16782 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 16783 if test "x$test_cygdrive_prefix" = x; then 16784 # As a simple fix, exclude /usr/bin since it's not a real path. 16785 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 16786 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 16787 # a path prefixed by /cygdrive for fixpath to work. 16788 new_path="$CYGWIN_ROOT_PATH$input_path" 16789 fi 16790 fi 16791 16792 16793 if test "x$path" != "x$new_path"; then 16794 TOPDIR="$new_path" 16795 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting TOPDIR to \"$new_path\"" >&5 16796 $as_echo "$as_me: Rewriting TOPDIR to \"$new_path\"" >&6;} 16797 fi 16798 16799 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 16800 16801 path="$TOPDIR" 16802 has_colon=`$ECHO $path | $GREP ^.:` 16803 new_path="$path" 16804 if test "x$has_colon" = x; then 16805 # Not in mixed or Windows style, start by that. 16806 new_path=`cmd //c echo $path` 16807 fi 16808 16809 16810 input_path="$new_path" 16811 # Check if we need to convert this using DOS-style short mode. If the path 16812 # contains just simple characters, use it. Otherwise (spaces, weird characters), 16813 # take no chances and rewrite it. 16814 # Note: m4 eats our [], so we need to use [ and ] instead. 16815 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 16816 if test "x$has_forbidden_chars" != x; then 16817 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 16818 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 16819 fi 16820 16821 16822 windows_path="$new_path" 16823 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 16824 unix_path=`$CYGPATH -u "$windows_path"` 16825 new_path="$unix_path" 16826 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 16827 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 16828 new_path="$unix_path" 16829 fi 16830 16831 if test "x$path" != "x$new_path"; then 16832 TOPDIR="$new_path" 16833 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting TOPDIR to \"$new_path\"" >&5 16834 $as_echo "$as_me: Rewriting TOPDIR to \"$new_path\"" >&6;} 16835 fi 16836 16837 # Save the first 10 bytes of this path to the storage, so fixpath can work. 16838 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 16839 16840 else 16841 # We're on a unix platform. Hooray! :) 16842 path="$TOPDIR" 16843 has_space=`$ECHO "$path" | $GREP " "` 16844 if test "x$has_space" != x; then 16845 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of TOPDIR, which resolves as \"$path\", is invalid." >&5 16846 $as_echo "$as_me: The path of TOPDIR, which resolves as \"$path\", is invalid." >&6;} 16847 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 16848 fi 16849 16850 # Use eval to expand a potential ~ 16851 eval path="$path" 16852 if test ! -f "$path" && test ! -d "$path"; then 16853 as_fn_error $? "The path of TOPDIR, which resolves as \"$path\", is not found." "$LINENO" 5 16854 fi 16855 16856 if test -d "$path"; then 16857 TOPDIR="`cd "$path"; $THEPWDCMD -L`" 16858 else 16859 dir="`$DIRNAME "$path"`" 16860 base="`$BASENAME "$path"`" 16861 TOPDIR="`cd "$dir"; $THEPWDCMD -L`/$base" 16862 fi 16863 fi 16864 fi 16865 16866 16867 # Locate the directory of this script. 16868 AUTOCONF_DIR=$TOPDIR/make/autoconf 16869 16870 # Setup username (for use in adhoc version strings etc) 16871 # Outer [ ] to quote m4. 16872 USERNAME=`$ECHO "$USER" | $TR -d -c '[a-z][A-Z][0-9]'` 16873 16874 16875 16876 # Check if it's a pure open build or if custom sources are to be used. 16877 16878 # Check whether --enable-openjdk-only was given. 16879 if test "${enable_openjdk_only+set}" = set; then : 16880 enableval=$enable_openjdk_only; 16881 else 16882 enable_openjdk_only="no" 16883 fi 16884 16885 16886 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if custom source is suppressed (openjdk-only)" >&5 16887 $as_echo_n "checking if custom source is suppressed (openjdk-only)... " >&6; } 16888 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $enable_openjdk_only" >&5 16889 $as_echo "$enable_openjdk_only" >&6; } 16890 if test "x$enable_openjdk_only" = "xyes"; then 16891 SUPPRESS_CUSTOM_EXTENSIONS="true" 16892 elif test "x$enable_openjdk_only" = "xno"; then 16893 SUPPRESS_CUSTOM_EXTENSIONS="false" 16894 else 16895 as_fn_error $? "Invalid value for --enable-openjdk-only: $enable_openjdk_only" "$LINENO" 5 16896 fi 16897 16898 # custom-make-dir is deprecated. Please use your custom-hook.m4 to override 16899 # the IncludeCustomExtension macro. 16900 16901 16902 # Check whether --with-custom-make-dir was given. 16903 if test "${with_custom_make_dir+set}" = set; then : 16904 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 16905 $as_echo "$as_me: WARNING: Option --with-custom-make-dir is deprecated and will be ignored." >&2;} 16906 fi 16907 16908 16909 16910 16911 # These are needed to be able to create a configuration name (and thus the output directory) 16912 16913 { $as_echo "$as_me:${as_lineno-$LINENO}: checking which variant of the JDK to build" >&5 16914 $as_echo_n "checking which variant of the JDK to build... " >&6; } 16915 16916 # Check whether --with-jdk-variant was given. 16917 if test "${with_jdk_variant+set}" = set; then : 16918 withval=$with_jdk_variant; 16919 fi 16920 16921 16922 if test "x$with_jdk_variant" = xnormal || test "x$with_jdk_variant" = x; then 16923 JDK_VARIANT="normal" 16924 else 16925 as_fn_error $? "The available JDK variants are: normal" "$LINENO" 5 16926 fi 16927 16928 16929 16930 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $JDK_VARIANT" >&5 16931 $as_echo "$JDK_VARIANT" >&6; } 16932 16933 16934 DEBUG_LEVEL="release" 16935 { $as_echo "$as_me:${as_lineno-$LINENO}: checking which debug level to use" >&5 16936 $as_echo_n "checking which debug level to use... " >&6; } 16937 # Check whether --enable-debug was given. 16938 if test "${enable_debug+set}" = set; then : 16939 enableval=$enable_debug; 16940 ENABLE_DEBUG="${enableval}" 16941 DEBUG_LEVEL="fastdebug" 16942 16943 else 16944 ENABLE_DEBUG="no" 16945 fi 16946 16947 16948 16949 # Check whether --with-debug-level was given. 16950 if test "${with_debug_level+set}" = set; then : 16951 withval=$with_debug_level; 16952 DEBUG_LEVEL="${withval}" 16953 if test "x$ENABLE_DEBUG" = xyes; then 16954 as_fn_error $? "You cannot use both --enable-debug and --with-debug-level at the same time." "$LINENO" 5 16955 fi 16956 16957 fi 16958 16959 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $DEBUG_LEVEL" >&5 16960 $as_echo "$DEBUG_LEVEL" >&6; } 16961 16962 if test "x$DEBUG_LEVEL" != xrelease && \ 16963 test "x$DEBUG_LEVEL" != xoptimized && \ 16964 test "x$DEBUG_LEVEL" != xfastdebug && \ 16965 test "x$DEBUG_LEVEL" != xslowdebug; then 16966 as_fn_error $? "Allowed debug levels are: release, fastdebug, slowdebug and optimized" "$LINENO" 5 16967 fi 16968 16969 # Translate DEBUG_LEVEL to debug level used by Hotspot 16970 HOTSPOT_DEBUG_LEVEL="$DEBUG_LEVEL" 16971 if test "x$DEBUG_LEVEL" = xrelease; then 16972 HOTSPOT_DEBUG_LEVEL="product" 16973 elif test "x$DEBUG_LEVEL" = xslowdebug; then 16974 HOTSPOT_DEBUG_LEVEL="debug" 16975 fi 16976 16977 if test "x$DEBUG_LEVEL" = xoptimized; then 16978 # The debug level 'optimized' is a little special because it is currently only 16979 # applicable to the HotSpot build where it means to build a completely 16980 # optimized version of the VM without any debugging code (like for the 16981 # 'release' debug level which is called 'product' in the HotSpot build) but 16982 # with the exception that it can contain additional code which is otherwise 16983 # protected by '#ifndef PRODUCT' macros. These 'optimized' builds are used to 16984 # test new and/or experimental features which are not intended for customer 16985 # shipment. Because these new features need to be tested and benchmarked in 16986 # real world scenarios, we want to build the containing JDK at the 'release' 16987 # debug level. 16988 DEBUG_LEVEL="release" 16989 fi 16990 16991 16992 16993 16994 16995 16996 # Check whether --with-jvm-variants was given. 16997 if test "${with_jvm_variants+set}" = set; then : 16998 withval=$with_jvm_variants; 16999 fi 17000 17001 17002 17003 17004 # Check whether --with-cpu-port was given. 17005 if test "${with_cpu_port+set}" = set; then : 17006 withval=$with_cpu_port; 17007 fi 17008 17009 17010 if test "x$with_cpu_port" != x; then 17011 if test "x$OPENJDK_TARGET_CPU" != xaarch64; then 17012 as_fn_error $? "--with-cpu-port only available on aarch64" "$LINENO" 5 17013 fi 17014 if test "x$with_cpu_port" != xarm64 && \ 17015 test "x$with_cpu_port" != xaarch64; then 17016 as_fn_error $? "--with-cpu-port must specify arm64 or aarch64" "$LINENO" 5 17017 fi 17018 HOTSPOT_TARGET_CPU_PORT="$with_cpu_port" 17019 fi 17020 17021 17022 if test "x$with_jvm_variants" = x; then 17023 with_jvm_variants="server" 17024 fi 17025 JVM_VARIANTS_OPT="$with_jvm_variants" 17026 17027 # Has the user listed more than one variant? 17028 # Additional [] needed to keep m4 from mangling shell constructs. 17029 if [[ "$JVM_VARIANTS_OPT" =~ "," ]] ; then 17030 BUILDING_MULTIPLE_JVM_VARIANTS=true 17031 else 17032 BUILDING_MULTIPLE_JVM_VARIANTS=false 17033 fi 17034 # Replace the commas with AND for use in the build directory name. 17035 JVM_VARIANTS_WITH_AND=`$ECHO "$JVM_VARIANTS_OPT" | $SED -e 's/,/AND/g'` 17036 17037 { $as_echo "$as_me:${as_lineno-$LINENO}: checking which variants of the JVM to build" >&5 17038 $as_echo_n "checking which variants of the JVM to build... " >&6; } 17039 # JVM_VARIANTS is a space-separated list. 17040 # Also use minimal, not minimal1 (which is kept for backwards compatibility). 17041 JVM_VARIANTS=`$ECHO $JVM_VARIANTS_OPT | $SED -e 's/,/ /g' -e 's/minimal1/minimal/'` 17042 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $JVM_VARIANTS" >&5 17043 $as_echo "$JVM_VARIANTS" >&6; } 17044 17045 # Check that the selected variants are valid 17046 17047 # grep filter function inspired by a comment to http://stackoverflow.com/a/1617326 17048 # Notice that the original variant failes on SLES 10 and 11 17049 NEEDLE=${VALID_JVM_VARIANTS// /$'\n'} 17050 STACK=${JVM_VARIANTS// /$'\n'} 17051 INVALID_VARIANTS=`$GREP -Fvx "${NEEDLE}" <<< "${STACK}"` 17052 if test "x$INVALID_VARIANTS" != x; then 17053 { $as_echo "$as_me:${as_lineno-$LINENO}: Unknown variant(s) specified: $INVALID_VARIANTS" >&5 17054 $as_echo "$as_me: Unknown variant(s) specified: $INVALID_VARIANTS" >&6;} 17055 as_fn_error $? "The available JVM variants are: $VALID_JVM_VARIANTS" "$LINENO" 5 17056 fi 17057 17058 # All "special" variants share the same output directory ("server") 17059 VALID_MULTIPLE_JVM_VARIANTS="server client minimal" 17060 NEEDLE=${VALID_MULTIPLE_JVM_VARIANTS// /$'\n'} 17061 STACK=${JVM_VARIANTS// /$'\n'} 17062 INVALID_MULTIPLE_VARIANTS=`$GREP -Fvx "${NEEDLE}" <<< "${STACK}"` 17063 if test "x$INVALID_MULTIPLE_VARIANTS" != x && test "x$BUILDING_MULTIPLE_JVM_VARIANTS" = xtrue; then 17064 as_fn_error $? "You cannot build multiple variants with anything else than $VALID_MULTIPLE_JVM_VARIANTS." "$LINENO" 5 17065 fi 17066 17067 # The "main" variant is the one used by other libs to link against during the 17068 # build. 17069 if test "x$BUILDING_MULTIPLE_JVM_VARIANTS" = "xtrue"; then 17070 MAIN_VARIANT_PRIO_ORDER="server client minimal" 17071 for variant in $MAIN_VARIANT_PRIO_ORDER; do 17072 if [[ " $JVM_VARIANTS " =~ " $variant " ]] ; then 17073 JVM_VARIANT_MAIN="$variant" 17074 break 17075 fi 17076 done 17077 else 17078 JVM_VARIANT_MAIN="$JVM_VARIANTS" 17079 fi 17080 17081 17082 17083 17084 17085 if [[ " $JVM_VARIANTS " =~ " zero " ]] ; then 17086 # zero behaves as a platform and rewrites these values. This is really weird. :( 17087 # We are guaranteed that we do not build any other variants when building zero. 17088 HOTSPOT_TARGET_CPU=zero 17089 HOTSPOT_TARGET_CPU_ARCH=zero 17090 fi 17091 17092 17093 # With basic setup done, call the custom early hook. 17094 17095 17096 # Check if we have devkits, extra paths or sysroot set. 17097 17098 17099 # Check whether --with-devkit was given. 17100 if test "${with_devkit+set}" = set; then : 17101 withval=$with_devkit; 17102 17103 # Only process if variable expands to non-empty 17104 17105 if test "x$with_devkit" != x; then 17106 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 17107 17108 # Input might be given as Windows format, start by converting to 17109 # unix format. 17110 path="$with_devkit" 17111 new_path=`$CYGPATH -u "$path"` 17112 17113 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 17114 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 17115 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 17116 # "foo.exe" is OK but "foo" is an error. 17117 # 17118 # This test is therefore slightly more accurate than "test -f" to check for file precense. 17119 # It is also a way to make sure we got the proper file name for the real test later on. 17120 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 17121 if test "x$test_shortpath" = x; then 17122 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of with_devkit, which resolves as \"$path\", is invalid." >&5 17123 $as_echo "$as_me: The path of with_devkit, which resolves as \"$path\", is invalid." >&6;} 17124 as_fn_error $? "Cannot locate the the path of with_devkit" "$LINENO" 5 17125 fi 17126 17127 # Call helper function which possibly converts this using DOS-style short mode. 17128 # If so, the updated path is stored in $new_path. 17129 17130 input_path="$new_path" 17131 # Check if we need to convert this using DOS-style short mode. If the path 17132 # contains just simple characters, use it. Otherwise (spaces, weird characters), 17133 # take no chances and rewrite it. 17134 # Note: m4 eats our [], so we need to use [ and ] instead. 17135 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 17136 if test "x$has_forbidden_chars" != x; then 17137 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 17138 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 17139 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 17140 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 17141 # Going to short mode and back again did indeed matter. Since short mode is 17142 # case insensitive, let's make it lowercase to improve readability. 17143 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 17144 # Now convert it back to Unix-style (cygpath) 17145 input_path=`$CYGPATH -u "$shortmode_path"` 17146 new_path="$input_path" 17147 fi 17148 fi 17149 17150 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 17151 if test "x$test_cygdrive_prefix" = x; then 17152 # As a simple fix, exclude /usr/bin since it's not a real path. 17153 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 17154 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 17155 # a path prefixed by /cygdrive for fixpath to work. 17156 new_path="$CYGWIN_ROOT_PATH$input_path" 17157 fi 17158 fi 17159 17160 17161 if test "x$path" != "x$new_path"; then 17162 with_devkit="$new_path" 17163 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting with_devkit to \"$new_path\"" >&5 17164 $as_echo "$as_me: Rewriting with_devkit to \"$new_path\"" >&6;} 17165 fi 17166 17167 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 17168 17169 path="$with_devkit" 17170 has_colon=`$ECHO $path | $GREP ^.:` 17171 new_path="$path" 17172 if test "x$has_colon" = x; then 17173 # Not in mixed or Windows style, start by that. 17174 new_path=`cmd //c echo $path` 17175 fi 17176 17177 17178 input_path="$new_path" 17179 # Check if we need to convert this using DOS-style short mode. If the path 17180 # contains just simple characters, use it. Otherwise (spaces, weird characters), 17181 # take no chances and rewrite it. 17182 # Note: m4 eats our [], so we need to use [ and ] instead. 17183 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 17184 if test "x$has_forbidden_chars" != x; then 17185 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 17186 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 17187 fi 17188 17189 17190 windows_path="$new_path" 17191 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 17192 unix_path=`$CYGPATH -u "$windows_path"` 17193 new_path="$unix_path" 17194 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 17195 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 17196 new_path="$unix_path" 17197 fi 17198 17199 if test "x$path" != "x$new_path"; then 17200 with_devkit="$new_path" 17201 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting with_devkit to \"$new_path\"" >&5 17202 $as_echo "$as_me: Rewriting with_devkit to \"$new_path\"" >&6;} 17203 fi 17204 17205 # Save the first 10 bytes of this path to the storage, so fixpath can work. 17206 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 17207 17208 else 17209 # We're on a unix platform. Hooray! :) 17210 path="$with_devkit" 17211 has_space=`$ECHO "$path" | $GREP " "` 17212 if test "x$has_space" != x; then 17213 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of with_devkit, which resolves as \"$path\", is invalid." >&5 17214 $as_echo "$as_me: The path of with_devkit, which resolves as \"$path\", is invalid." >&6;} 17215 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 17216 fi 17217 17218 # Use eval to expand a potential ~ 17219 eval path="$path" 17220 if test ! -f "$path" && test ! -d "$path"; then 17221 as_fn_error $? "The path of with_devkit, which resolves as \"$path\", is not found." "$LINENO" 5 17222 fi 17223 17224 if test -d "$path"; then 17225 with_devkit="`cd "$path"; $THEPWDCMD -L`" 17226 else 17227 dir="`$DIRNAME "$path"`" 17228 base="`$BASENAME "$path"`" 17229 with_devkit="`cd "$dir"; $THEPWDCMD -L`/$base" 17230 fi 17231 fi 17232 fi 17233 17234 DEVKIT_ROOT="$with_devkit" 17235 # Check for a meta data info file in the root of the devkit 17236 if test -f "$DEVKIT_ROOT/devkit.info"; then 17237 . $DEVKIT_ROOT/devkit.info 17238 # This potentially sets the following: 17239 # A descriptive name of the devkit 17240 17241 if test "x$DEVKIT_NAME" = x; then 17242 eval DEVKIT_NAME="\${DEVKIT_NAME_${OPENJDK_TARGET_CPU}}" 17243 fi 17244 17245 # Corresponds to --with-extra-path 17246 17247 if test "x$DEVKIT_EXTRA_PATH" = x; then 17248 eval DEVKIT_EXTRA_PATH="\${DEVKIT_EXTRA_PATH_${OPENJDK_TARGET_CPU}}" 17249 fi 17250 17251 # Corresponds to --with-toolchain-path 17252 17253 if test "x$DEVKIT_TOOLCHAIN_PATH" = x; then 17254 eval DEVKIT_TOOLCHAIN_PATH="\${DEVKIT_TOOLCHAIN_PATH_${OPENJDK_TARGET_CPU}}" 17255 fi 17256 17257 # Corresponds to --with-sysroot 17258 17259 if test "x$DEVKIT_SYSROOT" = x; then 17260 eval DEVKIT_SYSROOT="\${DEVKIT_SYSROOT_${OPENJDK_TARGET_CPU}}" 17261 fi 17262 17263 17264 # Identifies the Visual Studio version in the devkit 17265 17266 if test "x$DEVKIT_VS_VERSION" = x; then 17267 eval DEVKIT_VS_VERSION="\${DEVKIT_VS_VERSION_${OPENJDK_TARGET_CPU}}" 17268 fi 17269 17270 # The Visual Studio include environment variable 17271 17272 if test "x$DEVKIT_VS_INCLUDE" = x; then 17273 eval DEVKIT_VS_INCLUDE="\${DEVKIT_VS_INCLUDE_${OPENJDK_TARGET_CPU}}" 17274 fi 17275 17276 # The Visual Studio lib environment variable 17277 17278 if test "x$DEVKIT_VS_LIB" = x; then 17279 eval DEVKIT_VS_LIB="\${DEVKIT_VS_LIB_${OPENJDK_TARGET_CPU}}" 17280 fi 17281 17282 # Corresponds to --with-msvcr-dll 17283 17284 if test "x$DEVKIT_MSVCR_DLL" = x; then 17285 eval DEVKIT_MSVCR_DLL="\${DEVKIT_MSVCR_DLL_${OPENJDK_TARGET_CPU}}" 17286 fi 17287 17288 # Corresponds to --with-msvcp-dll 17289 17290 if test "x$DEVKIT_MSVCP_DLL" = x; then 17291 eval DEVKIT_MSVCP_DLL="\${DEVKIT_MSVCP_DLL_${OPENJDK_TARGET_CPU}}" 17292 fi 17293 17294 fi 17295 17296 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for devkit" >&5 17297 $as_echo_n "checking for devkit... " >&6; } 17298 if test "x$DEVKIT_NAME" != x; then 17299 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $DEVKIT_NAME in $DEVKIT_ROOT" >&5 17300 $as_echo "$DEVKIT_NAME in $DEVKIT_ROOT" >&6; } 17301 else 17302 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $DEVKIT_ROOT" >&5 17303 $as_echo "$DEVKIT_ROOT" >&6; } 17304 fi 17305 17306 17307 if test "x$DEVKIT_EXTRA_PATH" != x; then 17308 if test "x$EXTRA_PATH" = x; then 17309 EXTRA_PATH="$DEVKIT_EXTRA_PATH" 17310 else 17311 EXTRA_PATH="$DEVKIT_EXTRA_PATH:$EXTRA_PATH" 17312 fi 17313 fi 17314 17315 17316 # Fallback default of just /bin if DEVKIT_PATH is not defined 17317 if test "x$DEVKIT_TOOLCHAIN_PATH" = x; then 17318 DEVKIT_TOOLCHAIN_PATH="$DEVKIT_ROOT/bin" 17319 fi 17320 17321 if test "x$DEVKIT_TOOLCHAIN_PATH" != x; then 17322 if test "x$TOOLCHAIN_PATH" = x; then 17323 TOOLCHAIN_PATH="$DEVKIT_TOOLCHAIN_PATH" 17324 else 17325 TOOLCHAIN_PATH="$DEVKIT_TOOLCHAIN_PATH:$TOOLCHAIN_PATH" 17326 fi 17327 fi 17328 17329 17330 # If DEVKIT_SYSROOT is set, use that, otherwise try a couple of known 17331 # places for backwards compatiblity. 17332 if test "x$DEVKIT_SYSROOT" != x; then 17333 SYSROOT="$DEVKIT_SYSROOT" 17334 elif test -d "$DEVKIT_ROOT/$host_alias/libc"; then 17335 SYSROOT="$DEVKIT_ROOT/$host_alias/libc" 17336 elif test -d "$DEVKIT_ROOT/$host/sys-root"; then 17337 SYSROOT="$DEVKIT_ROOT/$host/sys-root" 17338 fi 17339 17340 if test "x$DEVKIT_ROOT" != x; then 17341 DEVKIT_LIB_DIR="$DEVKIT_ROOT/lib" 17342 if test "x$OPENJDK_TARGET_CPU_BITS" = x64; then 17343 DEVKIT_LIB_DIR="$DEVKIT_ROOT/lib64" 17344 fi 17345 17346 fi 17347 17348 17349 fi 17350 17351 17352 # You can force the sysroot if the sysroot encoded into the compiler tools 17353 # is not correct. 17354 17355 # Check whether --with-sys-root was given. 17356 if test "${with_sys_root+set}" = set; then : 17357 withval=$with_sys_root; SYSROOT=$with_sys_root 17358 17359 fi 17360 17361 17362 17363 # Check whether --with-sysroot was given. 17364 if test "${with_sysroot+set}" = set; then : 17365 withval=$with_sysroot; SYSROOT=$with_sysroot 17366 17367 fi 17368 17369 17370 17371 # Check whether --with-tools-dir was given. 17372 if test "${with_tools_dir+set}" = set; then : 17373 withval=$with_tools_dir; 17374 if test "x$with_tools_dir" != x; then 17375 if test "x$TOOLCHAIN_PATH" = x; then 17376 TOOLCHAIN_PATH="$with_tools_dir" 17377 else 17378 TOOLCHAIN_PATH="$with_tools_dir:$TOOLCHAIN_PATH" 17379 fi 17380 fi 17381 17382 17383 fi 17384 17385 17386 17387 # Check whether --with-toolchain-path was given. 17388 if test "${with_toolchain_path+set}" = set; then : 17389 withval=$with_toolchain_path; 17390 if test "x$with_toolchain_path" != x; then 17391 if test "x$TOOLCHAIN_PATH" = x; then 17392 TOOLCHAIN_PATH="$with_toolchain_path" 17393 else 17394 TOOLCHAIN_PATH="$with_toolchain_path:$TOOLCHAIN_PATH" 17395 fi 17396 fi 17397 17398 17399 fi 17400 17401 17402 17403 # Check whether --with-extra-path was given. 17404 if test "${with_extra_path+set}" = set; then : 17405 withval=$with_extra_path; 17406 if test "x$with_extra_path" != x; then 17407 if test "x$EXTRA_PATH" = x; then 17408 EXTRA_PATH="$with_extra_path" 17409 else 17410 EXTRA_PATH="$with_extra_path:$EXTRA_PATH" 17411 fi 17412 fi 17413 17414 17415 fi 17416 17417 17418 if test "x$OPENJDK_BUILD_OS" = "xmacosx"; then 17419 # If a devkit has been supplied, find xcodebuild in the toolchain_path. 17420 # If not, detect if Xcode is installed by running xcodebuild -version 17421 # if no Xcode installed, xcodebuild exits with 1 17422 # if Xcode is installed, even if xcode-select is misconfigured, then it exits with 0 17423 if test "x$DEVKIT_ROOT" != x || /usr/bin/xcodebuild -version >/dev/null 2>&1; then 17424 # We need to use xcodebuild in the toolchain dir provided by the user, this will 17425 # fall back on the stub binary in /usr/bin/xcodebuild 17426 # Extract the first word of "xcodebuild", so it can be a program name with args. 17427 set dummy xcodebuild; ac_word=$2 17428 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 17429 $as_echo_n "checking for $ac_word... " >&6; } 17430 if ${ac_cv_path_XCODEBUILD+:} false; then : 17431 $as_echo_n "(cached) " >&6 17432 else 17433 case $XCODEBUILD in 17434 [\\/]* | ?:[\\/]*) 17435 ac_cv_path_XCODEBUILD="$XCODEBUILD" # Let the user override the test with a path. 17436 ;; 17437 *) 17438 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 17439 for as_dir in $TOOLCHAIN_PATH 17440 do 17441 IFS=$as_save_IFS 17442 test -z "$as_dir" && as_dir=. 17443 for ac_exec_ext in '' $ac_executable_extensions; do 17444 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 17445 ac_cv_path_XCODEBUILD="$as_dir/$ac_word$ac_exec_ext" 17446 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 17447 break 2 17448 fi 17449 done 17450 done 17451 IFS=$as_save_IFS 17452 17453 test -z "$ac_cv_path_XCODEBUILD" && ac_cv_path_XCODEBUILD="/usr/bin/xcodebuild" 17454 ;; 17455 esac 17456 fi 17457 XCODEBUILD=$ac_cv_path_XCODEBUILD 17458 if test -n "$XCODEBUILD"; then 17459 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $XCODEBUILD" >&5 17460 $as_echo "$XCODEBUILD" >&6; } 17461 else 17462 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 17463 $as_echo "no" >&6; } 17464 fi 17465 17466 17467 else 17468 # this should result in SYSROOT being empty, unless --with-sysroot is provided 17469 # when only the command line tools are installed there are no SDKs, so headers 17470 # are copied into the system frameworks 17471 XCODEBUILD= 17472 17473 fi 17474 17475 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for sdk name" >&5 17476 $as_echo_n "checking for sdk name... " >&6; } 17477 17478 # Check whether --with-sdk-name was given. 17479 if test "${with_sdk_name+set}" = set; then : 17480 withval=$with_sdk_name; SDKNAME=$with_sdk_name 17481 17482 fi 17483 17484 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $SDKNAME" >&5 17485 $as_echo "$SDKNAME" >&6; } 17486 17487 # if toolchain path is specified then don't rely on system headers, they may not compile 17488 HAVE_SYSTEM_FRAMEWORK_HEADERS=0 17489 test -z "$TOOLCHAIN_PATH" && \ 17490 HAVE_SYSTEM_FRAMEWORK_HEADERS=`test ! -f /System/Library/Frameworks/Foundation.framework/Headers/Foundation.h; echo $?` 17491 17492 if test -z "$SYSROOT"; then 17493 if test -n "$XCODEBUILD"; then 17494 # if we don't have system headers, use default SDK name (last resort) 17495 if test -z "$SDKNAME" -a $HAVE_SYSTEM_FRAMEWORK_HEADERS -eq 0; then 17496 SDKNAME=${SDKNAME:-macosx} 17497 fi 17498 17499 if test -n "$SDKNAME"; then 17500 # Call xcodebuild to determine SYSROOT 17501 SYSROOT=`"$XCODEBUILD" -sdk $SDKNAME -version | $GREP '^Path: ' | $SED 's/Path: //'` 17502 fi 17503 else 17504 if test $HAVE_SYSTEM_FRAMEWORK_HEADERS -eq 0; then 17505 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 17506 fi 17507 fi 17508 else 17509 # warn user if --with-sdk-name was also set 17510 if test -n "$with_sdk_name"; then 17511 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Both SYSROOT and --with-sdk-name are set, only SYSROOT will be used" >&5 17512 $as_echo "$as_me: WARNING: Both SYSROOT and --with-sdk-name are set, only SYSROOT will be used" >&2;} 17513 fi 17514 fi 17515 17516 if test $HAVE_SYSTEM_FRAMEWORK_HEADERS -eq 0 -a -z "$SYSROOT"; then 17517 # If no system framework headers, then SYSROOT must be set, or we won't build 17518 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 17519 fi 17520 17521 # Perform a basic sanity test 17522 if test ! -f "$SYSROOT/System/Library/Frameworks/Foundation.framework/Headers/Foundation.h"; then 17523 if test -z "$SYSROOT"; then 17524 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 17525 else 17526 as_fn_error $? "Invalid SDK or SYSROOT path, dependent framework headers not found" "$LINENO" 5 17527 fi 17528 fi 17529 17530 # set SDKROOT too, Xcode tools will pick it up 17531 SDKROOT="$SYSROOT" 17532 17533 fi 17534 17535 # Prepend the extra path to the global path 17536 17537 if test "x$EXTRA_PATH" != x; then 17538 if test "x$PATH" = x; then 17539 PATH="$EXTRA_PATH" 17540 else 17541 PATH="$EXTRA_PATH:$PATH" 17542 fi 17543 fi 17544 17545 17546 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for sysroot" >&5 17547 $as_echo_n "checking for sysroot... " >&6; } 17548 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $SYSROOT" >&5 17549 $as_echo "$SYSROOT" >&6; } 17550 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for toolchain path" >&5 17551 $as_echo_n "checking for toolchain path... " >&6; } 17552 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $TOOLCHAIN_PATH" >&5 17553 $as_echo "$TOOLCHAIN_PATH" >&6; } 17554 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for extra path" >&5 17555 $as_echo_n "checking for extra path... " >&6; } 17556 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $EXTRA_PATH" >&5 17557 $as_echo "$EXTRA_PATH" >&6; } 17558 17559 17560 # To properly create a configuration name, we need to have the OpenJDK target 17561 # and options (variants and debug level) parsed. 17562 17563 17564 17565 # Check whether --with-conf-name was given. 17566 if test "${with_conf_name+set}" = set; then : 17567 withval=$with_conf_name; CONF_NAME=${with_conf_name} 17568 fi 17569 17570 17571 # Test from where we are running configure, in or outside of src root. 17572 { $as_echo "$as_me:${as_lineno-$LINENO}: checking where to store configuration" >&5 17573 $as_echo_n "checking where to store configuration... " >&6; } 17574 if test "x$CURDIR" = "x$TOPDIR" || test "x$CURDIR" = "x$CUSTOM_ROOT" \ 17575 || test "x$CURDIR" = "x$TOPDIR/make/autoconf" \ 17576 || test "x$CURDIR" = "x$TOPDIR/make" ; then 17577 # We are running configure from the src root. 17578 # Create a default ./build/target-variant-debuglevel output root. 17579 if test "x${CONF_NAME}" = x; then 17580 { $as_echo "$as_me:${as_lineno-$LINENO}: result: in default location" >&5 17581 $as_echo "in default location" >&6; } 17582 CONF_NAME="${OPENJDK_TARGET_OS}-${OPENJDK_TARGET_CPU}-${JDK_VARIANT}-${JVM_VARIANTS_WITH_AND}-${DEBUG_LEVEL}" 17583 else 17584 { $as_echo "$as_me:${as_lineno-$LINENO}: result: in build directory with custom name" >&5 17585 $as_echo "in build directory with custom name" >&6; } 17586 fi 17587 17588 if test "x$CUSTOM_ROOT" != x; then 17589 OUTPUTDIR="${CUSTOM_ROOT}/build/${CONF_NAME}" 17590 else 17591 OUTPUTDIR="${TOPDIR}/build/${CONF_NAME}" 17592 fi 17593 $MKDIR -p "$OUTPUTDIR" 17594 if test ! -d "$OUTPUTDIR"; then 17595 as_fn_error $? "Could not create build directory $OUTPUTDIR" "$LINENO" 5 17596 fi 17597 else 17598 # We are running configure from outside of the src dir. 17599 # Then use the current directory as output dir! 17600 # If configuration is situated in normal build directory, just use the build 17601 # directory name as configuration name, otherwise use the complete path. 17602 if test "x${CONF_NAME}" = x; then 17603 CONF_NAME=`$ECHO $CURDIR | $SED -e "s!^${TOPDIR}/build/!!"` 17604 fi 17605 OUTPUTDIR="$CURDIR" 17606 { $as_echo "$as_me:${as_lineno-$LINENO}: result: in current directory" >&5 17607 $as_echo "in current directory" >&6; } 17608 17609 # WARNING: This might be a bad thing to do. You need to be sure you want to 17610 # have a configuration in this directory. Do some sanity checks! 17611 17612 if test ! -e "$OUTPUTDIR/spec.gmk"; then 17613 # If we have a spec.gmk, we have run here before and we are OK. Otherwise, check for 17614 # other files 17615 files_present=`$LS $OUTPUTDIR` 17616 # Configure has already touched config.log and confdefs.h in the current dir when this check 17617 # is performed. 17618 filtered_files=`$ECHO "$files_present" \ 17619 | $SED -e 's/config.log//g' \ 17620 -e 's/configure.log//g' \ 17621 -e 's/confdefs.h//g' \ 17622 -e 's/ //g' \ 17623 | $TR -d '\n'` 17624 if test "x$filtered_files" != x; then 17625 { $as_echo "$as_me:${as_lineno-$LINENO}: Current directory is $CURDIR." >&5 17626 $as_echo "$as_me: Current directory is $CURDIR." >&6;} 17627 { $as_echo "$as_me:${as_lineno-$LINENO}: Since this is not the source root, configure will output the configuration here" >&5 17628 $as_echo "$as_me: Since this is not the source root, configure will output the configuration here" >&6;} 17629 { $as_echo "$as_me:${as_lineno-$LINENO}: (as opposed to creating a configuration in <src_root>/build/<conf-name>)." >&5 17630 $as_echo "$as_me: (as opposed to creating a configuration in <src_root>/build/<conf-name>)." >&6;} 17631 { $as_echo "$as_me:${as_lineno-$LINENO}: However, this directory is not empty. This is not allowed, since it could" >&5 17632 $as_echo "$as_me: However, this directory is not empty. This is not allowed, since it could" >&6;} 17633 { $as_echo "$as_me:${as_lineno-$LINENO}: seriously mess up just about everything." >&5 17634 $as_echo "$as_me: seriously mess up just about everything." >&6;} 17635 { $as_echo "$as_me:${as_lineno-$LINENO}: Try 'cd $TOPDIR' and restart configure" >&5 17636 $as_echo "$as_me: Try 'cd $TOPDIR' and restart configure" >&6;} 17637 { $as_echo "$as_me:${as_lineno-$LINENO}: (or create a new empty directory and cd to it)." >&5 17638 $as_echo "$as_me: (or create a new empty directory and cd to it)." >&6;} 17639 as_fn_error $? "Will not continue creating configuration in $CURDIR" "$LINENO" 5 17640 fi 17641 fi 17642 fi 17643 { $as_echo "$as_me:${as_lineno-$LINENO}: checking what configuration name to use" >&5 17644 $as_echo_n "checking what configuration name to use... " >&6; } 17645 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CONF_NAME" >&5 17646 $as_echo "$CONF_NAME" >&6; } 17647 17648 17649 # Only process if variable expands to non-empty 17650 17651 if test "x$OUTPUTDIR" != x; then 17652 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 17653 17654 # Input might be given as Windows format, start by converting to 17655 # unix format. 17656 path="$OUTPUTDIR" 17657 new_path=`$CYGPATH -u "$path"` 17658 17659 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 17660 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 17661 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 17662 # "foo.exe" is OK but "foo" is an error. 17663 # 17664 # This test is therefore slightly more accurate than "test -f" to check for file precense. 17665 # It is also a way to make sure we got the proper file name for the real test later on. 17666 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 17667 if test "x$test_shortpath" = x; then 17668 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of OUTPUTDIR, which resolves as \"$path\", is invalid." >&5 17669 $as_echo "$as_me: The path of OUTPUTDIR, which resolves as \"$path\", is invalid." >&6;} 17670 as_fn_error $? "Cannot locate the the path of OUTPUTDIR" "$LINENO" 5 17671 fi 17672 17673 # Call helper function which possibly converts this using DOS-style short mode. 17674 # If so, the updated path is stored in $new_path. 17675 17676 input_path="$new_path" 17677 # Check if we need to convert this using DOS-style short mode. If the path 17678 # contains just simple characters, use it. Otherwise (spaces, weird characters), 17679 # take no chances and rewrite it. 17680 # Note: m4 eats our [], so we need to use [ and ] instead. 17681 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 17682 if test "x$has_forbidden_chars" != x; then 17683 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 17684 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 17685 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 17686 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 17687 # Going to short mode and back again did indeed matter. Since short mode is 17688 # case insensitive, let's make it lowercase to improve readability. 17689 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 17690 # Now convert it back to Unix-style (cygpath) 17691 input_path=`$CYGPATH -u "$shortmode_path"` 17692 new_path="$input_path" 17693 fi 17694 fi 17695 17696 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 17697 if test "x$test_cygdrive_prefix" = x; then 17698 # As a simple fix, exclude /usr/bin since it's not a real path. 17699 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 17700 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 17701 # a path prefixed by /cygdrive for fixpath to work. 17702 new_path="$CYGWIN_ROOT_PATH$input_path" 17703 fi 17704 fi 17705 17706 17707 if test "x$path" != "x$new_path"; then 17708 OUTPUTDIR="$new_path" 17709 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting OUTPUTDIR to \"$new_path\"" >&5 17710 $as_echo "$as_me: Rewriting OUTPUTDIR to \"$new_path\"" >&6;} 17711 fi 17712 17713 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 17714 17715 path="$OUTPUTDIR" 17716 has_colon=`$ECHO $path | $GREP ^.:` 17717 new_path="$path" 17718 if test "x$has_colon" = x; then 17719 # Not in mixed or Windows style, start by that. 17720 new_path=`cmd //c echo $path` 17721 fi 17722 17723 17724 input_path="$new_path" 17725 # Check if we need to convert this using DOS-style short mode. If the path 17726 # contains just simple characters, use it. Otherwise (spaces, weird characters), 17727 # take no chances and rewrite it. 17728 # Note: m4 eats our [], so we need to use [ and ] instead. 17729 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 17730 if test "x$has_forbidden_chars" != x; then 17731 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 17732 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 17733 fi 17734 17735 17736 windows_path="$new_path" 17737 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 17738 unix_path=`$CYGPATH -u "$windows_path"` 17739 new_path="$unix_path" 17740 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 17741 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 17742 new_path="$unix_path" 17743 fi 17744 17745 if test "x$path" != "x$new_path"; then 17746 OUTPUTDIR="$new_path" 17747 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting OUTPUTDIR to \"$new_path\"" >&5 17748 $as_echo "$as_me: Rewriting OUTPUTDIR to \"$new_path\"" >&6;} 17749 fi 17750 17751 # Save the first 10 bytes of this path to the storage, so fixpath can work. 17752 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 17753 17754 else 17755 # We're on a unix platform. Hooray! :) 17756 path="$OUTPUTDIR" 17757 has_space=`$ECHO "$path" | $GREP " "` 17758 if test "x$has_space" != x; then 17759 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of OUTPUTDIR, which resolves as \"$path\", is invalid." >&5 17760 $as_echo "$as_me: The path of OUTPUTDIR, which resolves as \"$path\", is invalid." >&6;} 17761 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 17762 fi 17763 17764 # Use eval to expand a potential ~ 17765 eval path="$path" 17766 if test ! -f "$path" && test ! -d "$path"; then 17767 as_fn_error $? "The path of OUTPUTDIR, which resolves as \"$path\", is not found." "$LINENO" 5 17768 fi 17769 17770 if test -d "$path"; then 17771 OUTPUTDIR="`cd "$path"; $THEPWDCMD -L`" 17772 else 17773 dir="`$DIRNAME "$path"`" 17774 base="`$BASENAME "$path"`" 17775 OUTPUTDIR="`cd "$dir"; $THEPWDCMD -L`/$base" 17776 fi 17777 fi 17778 fi 17779 17780 17781 CONFIGURESUPPORT_OUTPUTDIR="$OUTPUTDIR/configure-support" 17782 $MKDIR -p "$CONFIGURESUPPORT_OUTPUTDIR" 17783 17784 SPEC="$OUTPUTDIR/spec.gmk" 17785 17786 17787 17788 17789 17790 # The spec.gmk file contains all variables for the make system. 17791 ac_config_files="$ac_config_files $OUTPUTDIR/spec.gmk:$AUTOCONF_DIR/spec.gmk.in" 17792 17793 # The bootcycle-spec.gmk file contains support for boot cycle builds. 17794 ac_config_files="$ac_config_files $OUTPUTDIR/bootcycle-spec.gmk:$AUTOCONF_DIR/bootcycle-spec.gmk.in" 17795 17796 # The buildjdk-spec.gmk file contains support for building a buildjdk when cross compiling. 17797 ac_config_files="$ac_config_files $OUTPUTDIR/buildjdk-spec.gmk:$AUTOCONF_DIR/buildjdk-spec.gmk.in" 17798 17799 # The compare.sh is used to compare the build output to other builds. 17800 ac_config_files="$ac_config_files $OUTPUTDIR/compare.sh:$AUTOCONF_DIR/compare.sh.in" 17801 17802 # The generated Makefile knows where the spec.gmk is and where the source is. 17803 # You can run make from the OUTPUTDIR, or from the top-level Makefile 17804 # which will look for generated configurations 17805 ac_config_files="$ac_config_files $OUTPUTDIR/Makefile:$AUTOCONF_DIR/Makefile.in" 17806 17807 17808 17809 # Must be done before we can call HELP_MSG_MISSING_DEPENDENCY. 17810 17811 for ac_prog in apt-get yum brew port pkgutil pkgadd 17812 do 17813 # Extract the first word of "$ac_prog", so it can be a program name with args. 17814 set dummy $ac_prog; ac_word=$2 17815 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 17816 $as_echo_n "checking for $ac_word... " >&6; } 17817 if ${ac_cv_prog_PKGHANDLER+:} false; then : 17818 $as_echo_n "(cached) " >&6 17819 else 17820 if test -n "$PKGHANDLER"; then 17821 ac_cv_prog_PKGHANDLER="$PKGHANDLER" # Let the user override the test. 17822 else 17823 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 17824 for as_dir in $PATH 17825 do 17826 IFS=$as_save_IFS 17827 test -z "$as_dir" && as_dir=. 17828 for ac_exec_ext in '' $ac_executable_extensions; do 17829 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 17830 ac_cv_prog_PKGHANDLER="$ac_prog" 17831 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 17832 break 2 17833 fi 17834 done 17835 done 17836 IFS=$as_save_IFS 17837 17838 fi 17839 fi 17840 PKGHANDLER=$ac_cv_prog_PKGHANDLER 17841 if test -n "$PKGHANDLER"; then 17842 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $PKGHANDLER" >&5 17843 $as_echo "$PKGHANDLER" >&6; } 17844 else 17845 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 17846 $as_echo "no" >&6; } 17847 fi 17848 17849 17850 test -n "$PKGHANDLER" && break 17851 done 17852 17853 17854 17855 # Setup tools that requires more complex handling, or that is not needed by the configure script. 17856 17857 17858 17859 # Publish this variable in the help. 17860 17861 17862 if [ -z "${MAKE+x}" ]; then 17863 # The variable is not set by user, try to locate tool using the code snippet 17864 17865 # Try our hardest to locate a correct version of GNU make 17866 for ac_prog in gmake 17867 do 17868 # Extract the first word of "$ac_prog", so it can be a program name with args. 17869 set dummy $ac_prog; ac_word=$2 17870 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 17871 $as_echo_n "checking for $ac_word... " >&6; } 17872 if ${ac_cv_path_CHECK_GMAKE+:} false; then : 17873 $as_echo_n "(cached) " >&6 17874 else 17875 case $CHECK_GMAKE in 17876 [\\/]* | ?:[\\/]*) 17877 ac_cv_path_CHECK_GMAKE="$CHECK_GMAKE" # Let the user override the test with a path. 17878 ;; 17879 *) 17880 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 17881 for as_dir in $PATH 17882 do 17883 IFS=$as_save_IFS 17884 test -z "$as_dir" && as_dir=. 17885 for ac_exec_ext in '' $ac_executable_extensions; do 17886 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 17887 ac_cv_path_CHECK_GMAKE="$as_dir/$ac_word$ac_exec_ext" 17888 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 17889 break 2 17890 fi 17891 done 17892 done 17893 IFS=$as_save_IFS 17894 17895 ;; 17896 esac 17897 fi 17898 CHECK_GMAKE=$ac_cv_path_CHECK_GMAKE 17899 if test -n "$CHECK_GMAKE"; then 17900 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CHECK_GMAKE" >&5 17901 $as_echo "$CHECK_GMAKE" >&6; } 17902 else 17903 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 17904 $as_echo "no" >&6; } 17905 fi 17906 17907 17908 test -n "$CHECK_GMAKE" && break 17909 done 17910 17911 17912 MAKE_CANDIDATE=""$CHECK_GMAKE"" 17913 DESCRIPTION="gmake in PATH" 17914 17915 # On Cygwin, we require a newer version of make than on other platforms 17916 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 17917 MAKE_VERSION_EXPR="-e 4\." 17918 MAKE_REQUIRED_VERSION="4.0" 17919 else 17920 MAKE_VERSION_EXPR="-e 3\.8[12] -e 4\." 17921 MAKE_REQUIRED_VERSION="3.81" 17922 fi 17923 17924 if test "x$MAKE_CANDIDATE" != x; then 17925 { $as_echo "$as_me:${as_lineno-$LINENO}: Testing potential make at $MAKE_CANDIDATE, found using $DESCRIPTION" >&5 17926 $as_echo "$as_me: Testing potential make at $MAKE_CANDIDATE, found using $DESCRIPTION" >&6;} 17927 MAKE_VERSION_STRING=`$MAKE_CANDIDATE --version | $HEAD -n 1` 17928 IS_GNU_MAKE=`$ECHO $MAKE_VERSION_STRING | $GREP 'GNU Make'` 17929 if test "x$IS_GNU_MAKE" = x; then 17930 { $as_echo "$as_me:${as_lineno-$LINENO}: Found potential make at $MAKE_CANDIDATE, however, this is not GNU Make. Ignoring." >&5 17931 $as_echo "$as_me: Found potential make at $MAKE_CANDIDATE, however, this is not GNU Make. Ignoring." >&6;} 17932 else 17933 IS_MODERN_MAKE=`$ECHO $MAKE_VERSION_STRING | $GREP $MAKE_VERSION_EXPR` 17934 if test "x$IS_MODERN_MAKE" = x; then 17935 { $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 17936 $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;} 17937 else 17938 if test "x$OPENJDK_BUILD_OS" = "xwindows"; then 17939 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 17940 MAKE_EXPECTED_ENV='cygwin' 17941 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 17942 MAKE_EXPECTED_ENV='msys' 17943 else 17944 as_fn_error $? "Unknown Windows environment" "$LINENO" 5 17945 fi 17946 MAKE_BUILT_FOR=`$MAKE_CANDIDATE --version | $GREP -i 'built for'` 17947 IS_MAKE_CORRECT_ENV=`$ECHO $MAKE_BUILT_FOR | $GREP $MAKE_EXPECTED_ENV` 17948 else 17949 # Not relevant for non-Windows 17950 IS_MAKE_CORRECT_ENV=true 17951 fi 17952 if test "x$IS_MAKE_CORRECT_ENV" = x; then 17953 { $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 17954 $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;} 17955 else 17956 FOUND_MAKE=$MAKE_CANDIDATE 17957 17958 # Only process if variable expands to non-empty 17959 17960 if test "x$FOUND_MAKE" != x; then 17961 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 17962 17963 # First separate the path from the arguments. This will split at the first 17964 # space. 17965 complete="$FOUND_MAKE" 17966 path="${complete%% *}" 17967 tmp="$complete EOL" 17968 arguments="${tmp#* }" 17969 17970 # Input might be given as Windows format, start by converting to 17971 # unix format. 17972 new_path=`$CYGPATH -u "$path"` 17973 17974 # Now try to locate executable using which 17975 new_path=`$WHICH "$new_path" 2> /dev/null` 17976 # bat and cmd files are not always considered executable in cygwin causing which 17977 # to not find them 17978 if test "x$new_path" = x \ 17979 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 17980 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 17981 new_path=`$CYGPATH -u "$path"` 17982 fi 17983 if test "x$new_path" = x; then 17984 # Oops. Which didn't find the executable. 17985 # The splitting of arguments from the executable at a space might have been incorrect, 17986 # since paths with space are more likely in Windows. Give it another try with the whole 17987 # argument. 17988 path="$complete" 17989 arguments="EOL" 17990 new_path=`$CYGPATH -u "$path"` 17991 new_path=`$WHICH "$new_path" 2> /dev/null` 17992 # bat and cmd files are not always considered executable in cygwin causing which 17993 # to not find them 17994 if test "x$new_path" = x \ 17995 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 17996 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 17997 new_path=`$CYGPATH -u "$path"` 17998 fi 17999 if test "x$new_path" = x; then 18000 # It's still not found. Now this is an unrecoverable error. 18001 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of FOUND_MAKE, which resolves as \"$complete\", is not found." >&5 18002 $as_echo "$as_me: The path of FOUND_MAKE, which resolves as \"$complete\", is not found." >&6;} 18003 has_space=`$ECHO "$complete" | $GREP " "` 18004 if test "x$has_space" != x; then 18005 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 18006 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 18007 fi 18008 as_fn_error $? "Cannot locate the the path of FOUND_MAKE" "$LINENO" 5 18009 fi 18010 fi 18011 18012 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 18013 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 18014 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 18015 # "foo.exe" is OK but "foo" is an error. 18016 # 18017 # This test is therefore slightly more accurate than "test -f" to check for file presence. 18018 # It is also a way to make sure we got the proper file name for the real test later on. 18019 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 18020 if test "x$test_shortpath" = x; then 18021 # Short path failed, file does not exist as specified. 18022 # Try adding .exe or .cmd 18023 if test -f "${new_path}.exe"; then 18024 input_to_shortpath="${new_path}.exe" 18025 elif test -f "${new_path}.cmd"; then 18026 input_to_shortpath="${new_path}.cmd" 18027 else 18028 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of FOUND_MAKE, which resolves as \"$new_path\", is invalid." >&5 18029 $as_echo "$as_me: The path of FOUND_MAKE, which resolves as \"$new_path\", is invalid." >&6;} 18030 { $as_echo "$as_me:${as_lineno-$LINENO}: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&5 18031 $as_echo "$as_me: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&6;} 18032 as_fn_error $? "Cannot locate the the path of FOUND_MAKE" "$LINENO" 5 18033 fi 18034 else 18035 input_to_shortpath="$new_path" 18036 fi 18037 18038 # Call helper function which possibly converts this using DOS-style short mode. 18039 # If so, the updated path is stored in $new_path. 18040 new_path="$input_to_shortpath" 18041 18042 input_path="$input_to_shortpath" 18043 # Check if we need to convert this using DOS-style short mode. If the path 18044 # contains just simple characters, use it. Otherwise (spaces, weird characters), 18045 # take no chances and rewrite it. 18046 # Note: m4 eats our [], so we need to use [ and ] instead. 18047 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 18048 if test "x$has_forbidden_chars" != x; then 18049 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 18050 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 18051 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 18052 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 18053 # Going to short mode and back again did indeed matter. Since short mode is 18054 # case insensitive, let's make it lowercase to improve readability. 18055 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 18056 # Now convert it back to Unix-style (cygpath) 18057 input_path=`$CYGPATH -u "$shortmode_path"` 18058 new_path="$input_path" 18059 fi 18060 fi 18061 18062 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 18063 if test "x$test_cygdrive_prefix" = x; then 18064 # As a simple fix, exclude /usr/bin since it's not a real path. 18065 if test "x`$ECHO $input_to_shortpath | $GREP ^/usr/bin/`" = x; then 18066 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 18067 # a path prefixed by /cygdrive for fixpath to work. 18068 new_path="$CYGWIN_ROOT_PATH$input_path" 18069 fi 18070 fi 18071 18072 # remove trailing .exe if any 18073 new_path="${new_path/%.exe/}" 18074 18075 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 18076 18077 # First separate the path from the arguments. This will split at the first 18078 # space. 18079 complete="$FOUND_MAKE" 18080 path="${complete%% *}" 18081 tmp="$complete EOL" 18082 arguments="${tmp#* }" 18083 18084 # Input might be given as Windows format, start by converting to 18085 # unix format. 18086 new_path="$path" 18087 18088 windows_path="$new_path" 18089 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 18090 unix_path=`$CYGPATH -u "$windows_path"` 18091 new_path="$unix_path" 18092 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 18093 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 18094 new_path="$unix_path" 18095 fi 18096 18097 18098 # Now try to locate executable using which 18099 new_path=`$WHICH "$new_path" 2> /dev/null` 18100 18101 if test "x$new_path" = x; then 18102 # Oops. Which didn't find the executable. 18103 # The splitting of arguments from the executable at a space might have been incorrect, 18104 # since paths with space are more likely in Windows. Give it another try with the whole 18105 # argument. 18106 path="$complete" 18107 arguments="EOL" 18108 new_path="$path" 18109 18110 windows_path="$new_path" 18111 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 18112 unix_path=`$CYGPATH -u "$windows_path"` 18113 new_path="$unix_path" 18114 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 18115 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 18116 new_path="$unix_path" 18117 fi 18118 18119 18120 new_path=`$WHICH "$new_path" 2> /dev/null` 18121 # bat and cmd files are not always considered executable in MSYS causing which 18122 # to not find them 18123 if test "x$new_path" = x \ 18124 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 18125 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 18126 new_path="$path" 18127 18128 windows_path="$new_path" 18129 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 18130 unix_path=`$CYGPATH -u "$windows_path"` 18131 new_path="$unix_path" 18132 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 18133 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 18134 new_path="$unix_path" 18135 fi 18136 18137 fi 18138 18139 if test "x$new_path" = x; then 18140 # It's still not found. Now this is an unrecoverable error. 18141 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of FOUND_MAKE, which resolves as \"$complete\", is not found." >&5 18142 $as_echo "$as_me: The path of FOUND_MAKE, which resolves as \"$complete\", is not found." >&6;} 18143 has_space=`$ECHO "$complete" | $GREP " "` 18144 if test "x$has_space" != x; then 18145 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 18146 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 18147 fi 18148 as_fn_error $? "Cannot locate the the path of FOUND_MAKE" "$LINENO" 5 18149 fi 18150 fi 18151 18152 # Now new_path has a complete unix path to the binary 18153 if test "x`$ECHO $new_path | $GREP ^/bin/`" != x; then 18154 # Keep paths in /bin as-is, but remove trailing .exe if any 18155 new_path="${new_path/%.exe/}" 18156 # Do not save /bin paths to all_fixpath_prefixes! 18157 else 18158 # Not in mixed or Windows style, start by that. 18159 new_path=`cmd //c echo $new_path` 18160 18161 input_path="$new_path" 18162 # Check if we need to convert this using DOS-style short mode. If the path 18163 # contains just simple characters, use it. Otherwise (spaces, weird characters), 18164 # take no chances and rewrite it. 18165 # Note: m4 eats our [], so we need to use [ and ] instead. 18166 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 18167 if test "x$has_forbidden_chars" != x; then 18168 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 18169 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 18170 fi 18171 18172 # Output is in $new_path 18173 18174 windows_path="$new_path" 18175 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 18176 unix_path=`$CYGPATH -u "$windows_path"` 18177 new_path="$unix_path" 18178 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 18179 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 18180 new_path="$unix_path" 18181 fi 18182 18183 # remove trailing .exe if any 18184 new_path="${new_path/%.exe/}" 18185 18186 # Save the first 10 bytes of this path to the storage, so fixpath can work. 18187 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 18188 fi 18189 18190 else 18191 # We're on a unix platform. Hooray! :) 18192 # First separate the path from the arguments. This will split at the first 18193 # space. 18194 complete="$FOUND_MAKE" 18195 path="${complete%% *}" 18196 tmp="$complete EOL" 18197 arguments="${tmp#* }" 18198 18199 # Cannot rely on the command "which" here since it doesn't always work. 18200 is_absolute_path=`$ECHO "$path" | $GREP ^/` 18201 if test -z "$is_absolute_path"; then 18202 # Path to executable is not absolute. Find it. 18203 IFS_save="$IFS" 18204 IFS=: 18205 for p in $PATH; do 18206 if test -f "$p/$path" && test -x "$p/$path"; then 18207 new_path="$p/$path" 18208 break 18209 fi 18210 done 18211 IFS="$IFS_save" 18212 else 18213 # This is an absolute path, we can use it without further modifications. 18214 new_path="$path" 18215 fi 18216 18217 if test "x$new_path" = x; then 18218 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of FOUND_MAKE, which resolves as \"$complete\", is not found." >&5 18219 $as_echo "$as_me: The path of FOUND_MAKE, which resolves as \"$complete\", is not found." >&6;} 18220 has_space=`$ECHO "$complete" | $GREP " "` 18221 if test "x$has_space" != x; then 18222 { $as_echo "$as_me:${as_lineno-$LINENO}: This might be caused by spaces in the path, which is not allowed." >&5 18223 $as_echo "$as_me: This might be caused by spaces in the path, which is not allowed." >&6;} 18224 fi 18225 as_fn_error $? "Cannot locate the the path of FOUND_MAKE" "$LINENO" 5 18226 fi 18227 fi 18228 18229 # Now join together the path and the arguments once again 18230 if test "x$arguments" != xEOL; then 18231 new_complete="$new_path ${arguments% *}" 18232 else 18233 new_complete="$new_path" 18234 fi 18235 18236 if test "x$complete" != "x$new_complete"; then 18237 FOUND_MAKE="$new_complete" 18238 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting FOUND_MAKE to \"$new_complete\"" >&5 18239 $as_echo "$as_me: Rewriting FOUND_MAKE to \"$new_complete\"" >&6;} 18240 fi 18241 fi 18242 18243 fi 18244 fi 18245 fi 18246 fi 18247 18248 18249 if test "x$FOUND_MAKE" = x; then 18250 for ac_prog in make 18251 do 18252 # Extract the first word of "$ac_prog", so it can be a program name with args. 18253 set dummy $ac_prog; ac_word=$2 18254 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 18255 $as_echo_n "checking for $ac_word... " >&6; } 18256 if ${ac_cv_path_CHECK_MAKE+:} false; then : 18257 $as_echo_n "(cached) " >&6 18258 else 18259 case $CHECK_MAKE in 18260 [\\/]* | ?:[\\/]*) 18261 ac_cv_path_CHECK_MAKE="$CHECK_MAKE" # Let the user override the test with a path. 18262 ;; 18263 *) 18264 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 18265 for as_dir in $PATH 18266 do 18267 IFS=$as_save_IFS 18268 test -z "$as_dir" && as_dir=. 18269 for ac_exec_ext in '' $ac_executable_extensions; do 18270 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 18271 ac_cv_path_CHECK_MAKE="$as_dir/$ac_word$ac_exec_ext" 18272 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 18273 break 2 18274 fi 18275 done 18276 done 18277 IFS=$as_save_IFS 18278 18279 ;; 18280 esac 18281 fi 18282 CHECK_MAKE=$ac_cv_path_CHECK_MAKE 18283 if test -n "$CHECK_MAKE"; then 18284 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CHECK_MAKE" >&5 18285 $as_echo "$CHECK_MAKE" >&6; } 18286 else 18287 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 18288 $as_echo "no" >&6; } 18289 fi 18290 18291 18292 test -n "$CHECK_MAKE" && break 18293 done 18294 18295 18296 MAKE_CANDIDATE=""$CHECK_MAKE"" 18297 DESCRIPTION="make in PATH" 18298 18299 # On Cygwin, we require a newer version of make than on other platforms 18300 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 18301 MAKE_VERSION_EXPR="-e 4\." 18302 MAKE_REQUIRED_VERSION="4.0" 18303 else 18304 MAKE_VERSION_EXPR="-e 3\.8[12] -e 4\." 18305 MAKE_REQUIRED_VERSION="3.81" 18306 fi 18307 18308 if test "x$MAKE_CANDIDATE" != x; then 18309 { $as_echo "$as_me:${as_lineno-$LINENO}: Testing potential make at $MAKE_CANDIDATE, found using $DESCRIPTION" >&5 18310 $as_echo "$as_me: Testing potential make at $MAKE_CANDIDATE, found using $DESCRIPTION" >&6;} 18311 MAKE_VERSION_STRING=`$MAKE_CANDIDATE --version | $HEAD -n 1` 18312 IS_GNU_MAKE=`$ECHO $MAKE_VERSION_STRING | $GREP 'GNU Make'` 18313 if test "x$IS_GNU_MAKE" = x; then 18314 { $as_echo "$as_me:${as_lineno-$LINENO}: Found potential make at $MAKE_CANDIDATE, however, this is not GNU Make. Ignoring." >&5 18315 $as_echo "$as_me: Found potential make at $MAKE_CANDIDATE, however, this is not GNU Make. Ignoring." >&6;} 18316 else 18317 IS_MODERN_MAKE=`$ECHO $MAKE_VERSION_STRING | $GREP $MAKE_VERSION_EXPR` 18318 if test "x$IS_MODERN_MAKE" = x; then 18319 { $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 18320 $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;} 18321 else 18322 if test "x$OPENJDK_BUILD_OS" = "xwindows"; then 18323 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 18324 MAKE_EXPECTED_ENV='cygwin' 18325 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 18326 MAKE_EXPECTED_ENV='msys' 18327 else 18328 as_fn_error $? "Unknown Windows environment" "$LINENO" 5 18329 fi 18330 MAKE_BUILT_FOR=`$MAKE_CANDIDATE --version | $GREP -i 'built for'` 18331 IS_MAKE_CORRECT_ENV=`$ECHO $MAKE_BUILT_FOR | $GREP $MAKE_EXPECTED_ENV` 18332 else 18333 # Not relevant for non-Windows 18334 IS_MAKE_CORRECT_ENV=true 18335 fi 18336 if test "x$IS_MAKE_CORRECT_ENV" = x; then 18337 { $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 18338 $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;} 18339 else 18340 FOUND_MAKE=$MAKE_CANDIDATE 18341 18342 # Only process if variable expands to non-empty 18343 18344 if test "x$FOUND_MAKE" != x; then 18345 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 18346 18347 # First separate the path from the arguments. This will split at the first 18348 # space. 18349 complete="$FOUND_MAKE" 18350 path="${complete%% *}" 18351 tmp="$complete EOL" 18352 arguments="${tmp#* }" 18353 18354 # Input might be given as Windows format, start by converting to 18355 # unix format. 18356 new_path=`$CYGPATH -u "$path"` 18357 18358 # Now try to locate executable using which 18359 new_path=`$WHICH "$new_path" 2> /dev/null` 18360 # bat and cmd files are not always considered executable in cygwin causing which 18361 # to not find them 18362 if test "x$new_path" = x \ 18363 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 18364 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 18365 new_path=`$CYGPATH -u "$path"` 18366 fi 18367 if test "x$new_path" = x; then 18368 # Oops. Which didn't find the executable. 18369 # The splitting of arguments from the executable at a space might have been incorrect, 18370 # since paths with space are more likely in Windows. Give it another try with the whole 18371 # argument. 18372 path="$complete" 18373 arguments="EOL" 18374 new_path=`$CYGPATH -u "$path"` 18375 new_path=`$WHICH "$new_path" 2> /dev/null` 18376 # bat and cmd files are not always considered executable in cygwin causing which 18377 # to not find them 18378 if test "x$new_path" = x \ 18379 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 18380 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 18381 new_path=`$CYGPATH -u "$path"` 18382 fi 18383 if test "x$new_path" = x; then 18384 # It's still not found. Now this is an unrecoverable error. 18385 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of FOUND_MAKE, which resolves as \"$complete\", is not found." >&5 18386 $as_echo "$as_me: The path of FOUND_MAKE, which resolves as \"$complete\", is not found." >&6;} 18387 has_space=`$ECHO "$complete" | $GREP " "` 18388 if test "x$has_space" != x; then 18389 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 18390 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 18391 fi 18392 as_fn_error $? "Cannot locate the the path of FOUND_MAKE" "$LINENO" 5 18393 fi 18394 fi 18395 18396 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 18397 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 18398 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 18399 # "foo.exe" is OK but "foo" is an error. 18400 # 18401 # This test is therefore slightly more accurate than "test -f" to check for file presence. 18402 # It is also a way to make sure we got the proper file name for the real test later on. 18403 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 18404 if test "x$test_shortpath" = x; then 18405 # Short path failed, file does not exist as specified. 18406 # Try adding .exe or .cmd 18407 if test -f "${new_path}.exe"; then 18408 input_to_shortpath="${new_path}.exe" 18409 elif test -f "${new_path}.cmd"; then 18410 input_to_shortpath="${new_path}.cmd" 18411 else 18412 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of FOUND_MAKE, which resolves as \"$new_path\", is invalid." >&5 18413 $as_echo "$as_me: The path of FOUND_MAKE, which resolves as \"$new_path\", is invalid." >&6;} 18414 { $as_echo "$as_me:${as_lineno-$LINENO}: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&5 18415 $as_echo "$as_me: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&6;} 18416 as_fn_error $? "Cannot locate the the path of FOUND_MAKE" "$LINENO" 5 18417 fi 18418 else 18419 input_to_shortpath="$new_path" 18420 fi 18421 18422 # Call helper function which possibly converts this using DOS-style short mode. 18423 # If so, the updated path is stored in $new_path. 18424 new_path="$input_to_shortpath" 18425 18426 input_path="$input_to_shortpath" 18427 # Check if we need to convert this using DOS-style short mode. If the path 18428 # contains just simple characters, use it. Otherwise (spaces, weird characters), 18429 # take no chances and rewrite it. 18430 # Note: m4 eats our [], so we need to use [ and ] instead. 18431 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 18432 if test "x$has_forbidden_chars" != x; then 18433 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 18434 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 18435 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 18436 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 18437 # Going to short mode and back again did indeed matter. Since short mode is 18438 # case insensitive, let's make it lowercase to improve readability. 18439 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 18440 # Now convert it back to Unix-style (cygpath) 18441 input_path=`$CYGPATH -u "$shortmode_path"` 18442 new_path="$input_path" 18443 fi 18444 fi 18445 18446 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 18447 if test "x$test_cygdrive_prefix" = x; then 18448 # As a simple fix, exclude /usr/bin since it's not a real path. 18449 if test "x`$ECHO $input_to_shortpath | $GREP ^/usr/bin/`" = x; then 18450 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 18451 # a path prefixed by /cygdrive for fixpath to work. 18452 new_path="$CYGWIN_ROOT_PATH$input_path" 18453 fi 18454 fi 18455 18456 # remove trailing .exe if any 18457 new_path="${new_path/%.exe/}" 18458 18459 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 18460 18461 # First separate the path from the arguments. This will split at the first 18462 # space. 18463 complete="$FOUND_MAKE" 18464 path="${complete%% *}" 18465 tmp="$complete EOL" 18466 arguments="${tmp#* }" 18467 18468 # Input might be given as Windows format, start by converting to 18469 # unix format. 18470 new_path="$path" 18471 18472 windows_path="$new_path" 18473 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 18474 unix_path=`$CYGPATH -u "$windows_path"` 18475 new_path="$unix_path" 18476 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 18477 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 18478 new_path="$unix_path" 18479 fi 18480 18481 18482 # Now try to locate executable using which 18483 new_path=`$WHICH "$new_path" 2> /dev/null` 18484 18485 if test "x$new_path" = x; then 18486 # Oops. Which didn't find the executable. 18487 # The splitting of arguments from the executable at a space might have been incorrect, 18488 # since paths with space are more likely in Windows. Give it another try with the whole 18489 # argument. 18490 path="$complete" 18491 arguments="EOL" 18492 new_path="$path" 18493 18494 windows_path="$new_path" 18495 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 18496 unix_path=`$CYGPATH -u "$windows_path"` 18497 new_path="$unix_path" 18498 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 18499 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 18500 new_path="$unix_path" 18501 fi 18502 18503 18504 new_path=`$WHICH "$new_path" 2> /dev/null` 18505 # bat and cmd files are not always considered executable in MSYS causing which 18506 # to not find them 18507 if test "x$new_path" = x \ 18508 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 18509 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 18510 new_path="$path" 18511 18512 windows_path="$new_path" 18513 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 18514 unix_path=`$CYGPATH -u "$windows_path"` 18515 new_path="$unix_path" 18516 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 18517 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 18518 new_path="$unix_path" 18519 fi 18520 18521 fi 18522 18523 if test "x$new_path" = x; then 18524 # It's still not found. Now this is an unrecoverable error. 18525 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of FOUND_MAKE, which resolves as \"$complete\", is not found." >&5 18526 $as_echo "$as_me: The path of FOUND_MAKE, which resolves as \"$complete\", is not found." >&6;} 18527 has_space=`$ECHO "$complete" | $GREP " "` 18528 if test "x$has_space" != x; then 18529 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 18530 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 18531 fi 18532 as_fn_error $? "Cannot locate the the path of FOUND_MAKE" "$LINENO" 5 18533 fi 18534 fi 18535 18536 # Now new_path has a complete unix path to the binary 18537 if test "x`$ECHO $new_path | $GREP ^/bin/`" != x; then 18538 # Keep paths in /bin as-is, but remove trailing .exe if any 18539 new_path="${new_path/%.exe/}" 18540 # Do not save /bin paths to all_fixpath_prefixes! 18541 else 18542 # Not in mixed or Windows style, start by that. 18543 new_path=`cmd //c echo $new_path` 18544 18545 input_path="$new_path" 18546 # Check if we need to convert this using DOS-style short mode. If the path 18547 # contains just simple characters, use it. Otherwise (spaces, weird characters), 18548 # take no chances and rewrite it. 18549 # Note: m4 eats our [], so we need to use [ and ] instead. 18550 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 18551 if test "x$has_forbidden_chars" != x; then 18552 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 18553 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 18554 fi 18555 18556 # Output is in $new_path 18557 18558 windows_path="$new_path" 18559 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 18560 unix_path=`$CYGPATH -u "$windows_path"` 18561 new_path="$unix_path" 18562 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 18563 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 18564 new_path="$unix_path" 18565 fi 18566 18567 # remove trailing .exe if any 18568 new_path="${new_path/%.exe/}" 18569 18570 # Save the first 10 bytes of this path to the storage, so fixpath can work. 18571 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 18572 fi 18573 18574 else 18575 # We're on a unix platform. Hooray! :) 18576 # First separate the path from the arguments. This will split at the first 18577 # space. 18578 complete="$FOUND_MAKE" 18579 path="${complete%% *}" 18580 tmp="$complete EOL" 18581 arguments="${tmp#* }" 18582 18583 # Cannot rely on the command "which" here since it doesn't always work. 18584 is_absolute_path=`$ECHO "$path" | $GREP ^/` 18585 if test -z "$is_absolute_path"; then 18586 # Path to executable is not absolute. Find it. 18587 IFS_save="$IFS" 18588 IFS=: 18589 for p in $PATH; do 18590 if test -f "$p/$path" && test -x "$p/$path"; then 18591 new_path="$p/$path" 18592 break 18593 fi 18594 done 18595 IFS="$IFS_save" 18596 else 18597 # This is an absolute path, we can use it without further modifications. 18598 new_path="$path" 18599 fi 18600 18601 if test "x$new_path" = x; then 18602 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of FOUND_MAKE, which resolves as \"$complete\", is not found." >&5 18603 $as_echo "$as_me: The path of FOUND_MAKE, which resolves as \"$complete\", is not found." >&6;} 18604 has_space=`$ECHO "$complete" | $GREP " "` 18605 if test "x$has_space" != x; then 18606 { $as_echo "$as_me:${as_lineno-$LINENO}: This might be caused by spaces in the path, which is not allowed." >&5 18607 $as_echo "$as_me: This might be caused by spaces in the path, which is not allowed." >&6;} 18608 fi 18609 as_fn_error $? "Cannot locate the the path of FOUND_MAKE" "$LINENO" 5 18610 fi 18611 fi 18612 18613 # Now join together the path and the arguments once again 18614 if test "x$arguments" != xEOL; then 18615 new_complete="$new_path ${arguments% *}" 18616 else 18617 new_complete="$new_path" 18618 fi 18619 18620 if test "x$complete" != "x$new_complete"; then 18621 FOUND_MAKE="$new_complete" 18622 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting FOUND_MAKE to \"$new_complete\"" >&5 18623 $as_echo "$as_me: Rewriting FOUND_MAKE to \"$new_complete\"" >&6;} 18624 fi 18625 fi 18626 18627 fi 18628 fi 18629 fi 18630 fi 18631 18632 fi 18633 18634 if test "x$FOUND_MAKE" = x; then 18635 if test "x$TOOLCHAIN_PATH" != x; then 18636 # We have a toolchain path, check that as well before giving up. 18637 OLD_PATH=$PATH 18638 PATH=$TOOLCHAIN_PATH:$PATH 18639 for ac_prog in gmake 18640 do 18641 # Extract the first word of "$ac_prog", so it can be a program name with args. 18642 set dummy $ac_prog; ac_word=$2 18643 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 18644 $as_echo_n "checking for $ac_word... " >&6; } 18645 if ${ac_cv_path_CHECK_TOOLSDIR_GMAKE+:} false; then : 18646 $as_echo_n "(cached) " >&6 18647 else 18648 case $CHECK_TOOLSDIR_GMAKE in 18649 [\\/]* | ?:[\\/]*) 18650 ac_cv_path_CHECK_TOOLSDIR_GMAKE="$CHECK_TOOLSDIR_GMAKE" # Let the user override the test with a path. 18651 ;; 18652 *) 18653 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 18654 for as_dir in $PATH 18655 do 18656 IFS=$as_save_IFS 18657 test -z "$as_dir" && as_dir=. 18658 for ac_exec_ext in '' $ac_executable_extensions; do 18659 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 18660 ac_cv_path_CHECK_TOOLSDIR_GMAKE="$as_dir/$ac_word$ac_exec_ext" 18661 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 18662 break 2 18663 fi 18664 done 18665 done 18666 IFS=$as_save_IFS 18667 18668 ;; 18669 esac 18670 fi 18671 CHECK_TOOLSDIR_GMAKE=$ac_cv_path_CHECK_TOOLSDIR_GMAKE 18672 if test -n "$CHECK_TOOLSDIR_GMAKE"; then 18673 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CHECK_TOOLSDIR_GMAKE" >&5 18674 $as_echo "$CHECK_TOOLSDIR_GMAKE" >&6; } 18675 else 18676 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 18677 $as_echo "no" >&6; } 18678 fi 18679 18680 18681 test -n "$CHECK_TOOLSDIR_GMAKE" && break 18682 done 18683 18684 18685 MAKE_CANDIDATE=""$CHECK_TOOLSDIR_GMAKE"" 18686 DESCRIPTION="gmake in tools-dir" 18687 18688 # On Cygwin, we require a newer version of make than on other platforms 18689 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 18690 MAKE_VERSION_EXPR="-e 4\." 18691 MAKE_REQUIRED_VERSION="4.0" 18692 else 18693 MAKE_VERSION_EXPR="-e 3\.8[12] -e 4\." 18694 MAKE_REQUIRED_VERSION="3.81" 18695 fi 18696 18697 if test "x$MAKE_CANDIDATE" != x; then 18698 { $as_echo "$as_me:${as_lineno-$LINENO}: Testing potential make at $MAKE_CANDIDATE, found using $DESCRIPTION" >&5 18699 $as_echo "$as_me: Testing potential make at $MAKE_CANDIDATE, found using $DESCRIPTION" >&6;} 18700 MAKE_VERSION_STRING=`$MAKE_CANDIDATE --version | $HEAD -n 1` 18701 IS_GNU_MAKE=`$ECHO $MAKE_VERSION_STRING | $GREP 'GNU Make'` 18702 if test "x$IS_GNU_MAKE" = x; then 18703 { $as_echo "$as_me:${as_lineno-$LINENO}: Found potential make at $MAKE_CANDIDATE, however, this is not GNU Make. Ignoring." >&5 18704 $as_echo "$as_me: Found potential make at $MAKE_CANDIDATE, however, this is not GNU Make. Ignoring." >&6;} 18705 else 18706 IS_MODERN_MAKE=`$ECHO $MAKE_VERSION_STRING | $GREP $MAKE_VERSION_EXPR` 18707 if test "x$IS_MODERN_MAKE" = x; then 18708 { $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 18709 $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;} 18710 else 18711 if test "x$OPENJDK_BUILD_OS" = "xwindows"; then 18712 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 18713 MAKE_EXPECTED_ENV='cygwin' 18714 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 18715 MAKE_EXPECTED_ENV='msys' 18716 else 18717 as_fn_error $? "Unknown Windows environment" "$LINENO" 5 18718 fi 18719 MAKE_BUILT_FOR=`$MAKE_CANDIDATE --version | $GREP -i 'built for'` 18720 IS_MAKE_CORRECT_ENV=`$ECHO $MAKE_BUILT_FOR | $GREP $MAKE_EXPECTED_ENV` 18721 else 18722 # Not relevant for non-Windows 18723 IS_MAKE_CORRECT_ENV=true 18724 fi 18725 if test "x$IS_MAKE_CORRECT_ENV" = x; then 18726 { $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 18727 $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;} 18728 else 18729 FOUND_MAKE=$MAKE_CANDIDATE 18730 18731 # Only process if variable expands to non-empty 18732 18733 if test "x$FOUND_MAKE" != x; then 18734 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 18735 18736 # First separate the path from the arguments. This will split at the first 18737 # space. 18738 complete="$FOUND_MAKE" 18739 path="${complete%% *}" 18740 tmp="$complete EOL" 18741 arguments="${tmp#* }" 18742 18743 # Input might be given as Windows format, start by converting to 18744 # unix format. 18745 new_path=`$CYGPATH -u "$path"` 18746 18747 # Now try to locate executable using which 18748 new_path=`$WHICH "$new_path" 2> /dev/null` 18749 # bat and cmd files are not always considered executable in cygwin causing which 18750 # to not find them 18751 if test "x$new_path" = x \ 18752 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 18753 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 18754 new_path=`$CYGPATH -u "$path"` 18755 fi 18756 if test "x$new_path" = x; then 18757 # Oops. Which didn't find the executable. 18758 # The splitting of arguments from the executable at a space might have been incorrect, 18759 # since paths with space are more likely in Windows. Give it another try with the whole 18760 # argument. 18761 path="$complete" 18762 arguments="EOL" 18763 new_path=`$CYGPATH -u "$path"` 18764 new_path=`$WHICH "$new_path" 2> /dev/null` 18765 # bat and cmd files are not always considered executable in cygwin causing which 18766 # to not find them 18767 if test "x$new_path" = x \ 18768 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 18769 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 18770 new_path=`$CYGPATH -u "$path"` 18771 fi 18772 if test "x$new_path" = x; then 18773 # It's still not found. Now this is an unrecoverable error. 18774 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of FOUND_MAKE, which resolves as \"$complete\", is not found." >&5 18775 $as_echo "$as_me: The path of FOUND_MAKE, which resolves as \"$complete\", is not found." >&6;} 18776 has_space=`$ECHO "$complete" | $GREP " "` 18777 if test "x$has_space" != x; then 18778 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 18779 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 18780 fi 18781 as_fn_error $? "Cannot locate the the path of FOUND_MAKE" "$LINENO" 5 18782 fi 18783 fi 18784 18785 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 18786 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 18787 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 18788 # "foo.exe" is OK but "foo" is an error. 18789 # 18790 # This test is therefore slightly more accurate than "test -f" to check for file presence. 18791 # It is also a way to make sure we got the proper file name for the real test later on. 18792 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 18793 if test "x$test_shortpath" = x; then 18794 # Short path failed, file does not exist as specified. 18795 # Try adding .exe or .cmd 18796 if test -f "${new_path}.exe"; then 18797 input_to_shortpath="${new_path}.exe" 18798 elif test -f "${new_path}.cmd"; then 18799 input_to_shortpath="${new_path}.cmd" 18800 else 18801 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of FOUND_MAKE, which resolves as \"$new_path\", is invalid." >&5 18802 $as_echo "$as_me: The path of FOUND_MAKE, which resolves as \"$new_path\", is invalid." >&6;} 18803 { $as_echo "$as_me:${as_lineno-$LINENO}: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&5 18804 $as_echo "$as_me: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&6;} 18805 as_fn_error $? "Cannot locate the the path of FOUND_MAKE" "$LINENO" 5 18806 fi 18807 else 18808 input_to_shortpath="$new_path" 18809 fi 18810 18811 # Call helper function which possibly converts this using DOS-style short mode. 18812 # If so, the updated path is stored in $new_path. 18813 new_path="$input_to_shortpath" 18814 18815 input_path="$input_to_shortpath" 18816 # Check if we need to convert this using DOS-style short mode. If the path 18817 # contains just simple characters, use it. Otherwise (spaces, weird characters), 18818 # take no chances and rewrite it. 18819 # Note: m4 eats our [], so we need to use [ and ] instead. 18820 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 18821 if test "x$has_forbidden_chars" != x; then 18822 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 18823 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 18824 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 18825 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 18826 # Going to short mode and back again did indeed matter. Since short mode is 18827 # case insensitive, let's make it lowercase to improve readability. 18828 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 18829 # Now convert it back to Unix-style (cygpath) 18830 input_path=`$CYGPATH -u "$shortmode_path"` 18831 new_path="$input_path" 18832 fi 18833 fi 18834 18835 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 18836 if test "x$test_cygdrive_prefix" = x; then 18837 # As a simple fix, exclude /usr/bin since it's not a real path. 18838 if test "x`$ECHO $input_to_shortpath | $GREP ^/usr/bin/`" = x; then 18839 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 18840 # a path prefixed by /cygdrive for fixpath to work. 18841 new_path="$CYGWIN_ROOT_PATH$input_path" 18842 fi 18843 fi 18844 18845 # remove trailing .exe if any 18846 new_path="${new_path/%.exe/}" 18847 18848 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 18849 18850 # First separate the path from the arguments. This will split at the first 18851 # space. 18852 complete="$FOUND_MAKE" 18853 path="${complete%% *}" 18854 tmp="$complete EOL" 18855 arguments="${tmp#* }" 18856 18857 # Input might be given as Windows format, start by converting to 18858 # unix format. 18859 new_path="$path" 18860 18861 windows_path="$new_path" 18862 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 18863 unix_path=`$CYGPATH -u "$windows_path"` 18864 new_path="$unix_path" 18865 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 18866 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 18867 new_path="$unix_path" 18868 fi 18869 18870 18871 # Now try to locate executable using which 18872 new_path=`$WHICH "$new_path" 2> /dev/null` 18873 18874 if test "x$new_path" = x; then 18875 # Oops. Which didn't find the executable. 18876 # The splitting of arguments from the executable at a space might have been incorrect, 18877 # since paths with space are more likely in Windows. Give it another try with the whole 18878 # argument. 18879 path="$complete" 18880 arguments="EOL" 18881 new_path="$path" 18882 18883 windows_path="$new_path" 18884 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 18885 unix_path=`$CYGPATH -u "$windows_path"` 18886 new_path="$unix_path" 18887 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 18888 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 18889 new_path="$unix_path" 18890 fi 18891 18892 18893 new_path=`$WHICH "$new_path" 2> /dev/null` 18894 # bat and cmd files are not always considered executable in MSYS causing which 18895 # to not find them 18896 if test "x$new_path" = x \ 18897 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 18898 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 18899 new_path="$path" 18900 18901 windows_path="$new_path" 18902 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 18903 unix_path=`$CYGPATH -u "$windows_path"` 18904 new_path="$unix_path" 18905 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 18906 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 18907 new_path="$unix_path" 18908 fi 18909 18910 fi 18911 18912 if test "x$new_path" = x; then 18913 # It's still not found. Now this is an unrecoverable error. 18914 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of FOUND_MAKE, which resolves as \"$complete\", is not found." >&5 18915 $as_echo "$as_me: The path of FOUND_MAKE, which resolves as \"$complete\", is not found." >&6;} 18916 has_space=`$ECHO "$complete" | $GREP " "` 18917 if test "x$has_space" != x; then 18918 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 18919 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 18920 fi 18921 as_fn_error $? "Cannot locate the the path of FOUND_MAKE" "$LINENO" 5 18922 fi 18923 fi 18924 18925 # Now new_path has a complete unix path to the binary 18926 if test "x`$ECHO $new_path | $GREP ^/bin/`" != x; then 18927 # Keep paths in /bin as-is, but remove trailing .exe if any 18928 new_path="${new_path/%.exe/}" 18929 # Do not save /bin paths to all_fixpath_prefixes! 18930 else 18931 # Not in mixed or Windows style, start by that. 18932 new_path=`cmd //c echo $new_path` 18933 18934 input_path="$new_path" 18935 # Check if we need to convert this using DOS-style short mode. If the path 18936 # contains just simple characters, use it. Otherwise (spaces, weird characters), 18937 # take no chances and rewrite it. 18938 # Note: m4 eats our [], so we need to use [ and ] instead. 18939 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 18940 if test "x$has_forbidden_chars" != x; then 18941 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 18942 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 18943 fi 18944 18945 # Output is in $new_path 18946 18947 windows_path="$new_path" 18948 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 18949 unix_path=`$CYGPATH -u "$windows_path"` 18950 new_path="$unix_path" 18951 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 18952 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 18953 new_path="$unix_path" 18954 fi 18955 18956 # remove trailing .exe if any 18957 new_path="${new_path/%.exe/}" 18958 18959 # Save the first 10 bytes of this path to the storage, so fixpath can work. 18960 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 18961 fi 18962 18963 else 18964 # We're on a unix platform. Hooray! :) 18965 # First separate the path from the arguments. This will split at the first 18966 # space. 18967 complete="$FOUND_MAKE" 18968 path="${complete%% *}" 18969 tmp="$complete EOL" 18970 arguments="${tmp#* }" 18971 18972 # Cannot rely on the command "which" here since it doesn't always work. 18973 is_absolute_path=`$ECHO "$path" | $GREP ^/` 18974 if test -z "$is_absolute_path"; then 18975 # Path to executable is not absolute. Find it. 18976 IFS_save="$IFS" 18977 IFS=: 18978 for p in $PATH; do 18979 if test -f "$p/$path" && test -x "$p/$path"; then 18980 new_path="$p/$path" 18981 break 18982 fi 18983 done 18984 IFS="$IFS_save" 18985 else 18986 # This is an absolute path, we can use it without further modifications. 18987 new_path="$path" 18988 fi 18989 18990 if test "x$new_path" = x; then 18991 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of FOUND_MAKE, which resolves as \"$complete\", is not found." >&5 18992 $as_echo "$as_me: The path of FOUND_MAKE, which resolves as \"$complete\", is not found." >&6;} 18993 has_space=`$ECHO "$complete" | $GREP " "` 18994 if test "x$has_space" != x; then 18995 { $as_echo "$as_me:${as_lineno-$LINENO}: This might be caused by spaces in the path, which is not allowed." >&5 18996 $as_echo "$as_me: This might be caused by spaces in the path, which is not allowed." >&6;} 18997 fi 18998 as_fn_error $? "Cannot locate the the path of FOUND_MAKE" "$LINENO" 5 18999 fi 19000 fi 19001 19002 # Now join together the path and the arguments once again 19003 if test "x$arguments" != xEOL; then 19004 new_complete="$new_path ${arguments% *}" 19005 else 19006 new_complete="$new_path" 19007 fi 19008 19009 if test "x$complete" != "x$new_complete"; then 19010 FOUND_MAKE="$new_complete" 19011 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting FOUND_MAKE to \"$new_complete\"" >&5 19012 $as_echo "$as_me: Rewriting FOUND_MAKE to \"$new_complete\"" >&6;} 19013 fi 19014 fi 19015 19016 fi 19017 fi 19018 fi 19019 fi 19020 19021 if test "x$FOUND_MAKE" = x; then 19022 for ac_prog in make 19023 do 19024 # Extract the first word of "$ac_prog", so it can be a program name with args. 19025 set dummy $ac_prog; ac_word=$2 19026 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 19027 $as_echo_n "checking for $ac_word... " >&6; } 19028 if ${ac_cv_path_CHECK_TOOLSDIR_MAKE+:} false; then : 19029 $as_echo_n "(cached) " >&6 19030 else 19031 case $CHECK_TOOLSDIR_MAKE in 19032 [\\/]* | ?:[\\/]*) 19033 ac_cv_path_CHECK_TOOLSDIR_MAKE="$CHECK_TOOLSDIR_MAKE" # Let the user override the test with a path. 19034 ;; 19035 *) 19036 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 19037 for as_dir in $PATH 19038 do 19039 IFS=$as_save_IFS 19040 test -z "$as_dir" && as_dir=. 19041 for ac_exec_ext in '' $ac_executable_extensions; do 19042 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 19043 ac_cv_path_CHECK_TOOLSDIR_MAKE="$as_dir/$ac_word$ac_exec_ext" 19044 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 19045 break 2 19046 fi 19047 done 19048 done 19049 IFS=$as_save_IFS 19050 19051 ;; 19052 esac 19053 fi 19054 CHECK_TOOLSDIR_MAKE=$ac_cv_path_CHECK_TOOLSDIR_MAKE 19055 if test -n "$CHECK_TOOLSDIR_MAKE"; then 19056 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CHECK_TOOLSDIR_MAKE" >&5 19057 $as_echo "$CHECK_TOOLSDIR_MAKE" >&6; } 19058 else 19059 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 19060 $as_echo "no" >&6; } 19061 fi 19062 19063 19064 test -n "$CHECK_TOOLSDIR_MAKE" && break 19065 done 19066 19067 19068 MAKE_CANDIDATE=""$CHECK_TOOLSDIR_MAKE"" 19069 DESCRIPTION="make in tools-dir" 19070 19071 # On Cygwin, we require a newer version of make than on other platforms 19072 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 19073 MAKE_VERSION_EXPR="-e 4\." 19074 MAKE_REQUIRED_VERSION="4.0" 19075 else 19076 MAKE_VERSION_EXPR="-e 3\.8[12] -e 4\." 19077 MAKE_REQUIRED_VERSION="3.81" 19078 fi 19079 19080 if test "x$MAKE_CANDIDATE" != x; then 19081 { $as_echo "$as_me:${as_lineno-$LINENO}: Testing potential make at $MAKE_CANDIDATE, found using $DESCRIPTION" >&5 19082 $as_echo "$as_me: Testing potential make at $MAKE_CANDIDATE, found using $DESCRIPTION" >&6;} 19083 MAKE_VERSION_STRING=`$MAKE_CANDIDATE --version | $HEAD -n 1` 19084 IS_GNU_MAKE=`$ECHO $MAKE_VERSION_STRING | $GREP 'GNU Make'` 19085 if test "x$IS_GNU_MAKE" = x; then 19086 { $as_echo "$as_me:${as_lineno-$LINENO}: Found potential make at $MAKE_CANDIDATE, however, this is not GNU Make. Ignoring." >&5 19087 $as_echo "$as_me: Found potential make at $MAKE_CANDIDATE, however, this is not GNU Make. Ignoring." >&6;} 19088 else 19089 IS_MODERN_MAKE=`$ECHO $MAKE_VERSION_STRING | $GREP $MAKE_VERSION_EXPR` 19090 if test "x$IS_MODERN_MAKE" = x; then 19091 { $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 19092 $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;} 19093 else 19094 if test "x$OPENJDK_BUILD_OS" = "xwindows"; then 19095 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 19096 MAKE_EXPECTED_ENV='cygwin' 19097 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 19098 MAKE_EXPECTED_ENV='msys' 19099 else 19100 as_fn_error $? "Unknown Windows environment" "$LINENO" 5 19101 fi 19102 MAKE_BUILT_FOR=`$MAKE_CANDIDATE --version | $GREP -i 'built for'` 19103 IS_MAKE_CORRECT_ENV=`$ECHO $MAKE_BUILT_FOR | $GREP $MAKE_EXPECTED_ENV` 19104 else 19105 # Not relevant for non-Windows 19106 IS_MAKE_CORRECT_ENV=true 19107 fi 19108 if test "x$IS_MAKE_CORRECT_ENV" = x; then 19109 { $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 19110 $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;} 19111 else 19112 FOUND_MAKE=$MAKE_CANDIDATE 19113 19114 # Only process if variable expands to non-empty 19115 19116 if test "x$FOUND_MAKE" != x; then 19117 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 19118 19119 # First separate the path from the arguments. This will split at the first 19120 # space. 19121 complete="$FOUND_MAKE" 19122 path="${complete%% *}" 19123 tmp="$complete EOL" 19124 arguments="${tmp#* }" 19125 19126 # Input might be given as Windows format, start by converting to 19127 # unix format. 19128 new_path=`$CYGPATH -u "$path"` 19129 19130 # Now try to locate executable using which 19131 new_path=`$WHICH "$new_path" 2> /dev/null` 19132 # bat and cmd files are not always considered executable in cygwin causing which 19133 # to not find them 19134 if test "x$new_path" = x \ 19135 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 19136 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 19137 new_path=`$CYGPATH -u "$path"` 19138 fi 19139 if test "x$new_path" = x; then 19140 # Oops. Which didn't find the executable. 19141 # The splitting of arguments from the executable at a space might have been incorrect, 19142 # since paths with space are more likely in Windows. Give it another try with the whole 19143 # argument. 19144 path="$complete" 19145 arguments="EOL" 19146 new_path=`$CYGPATH -u "$path"` 19147 new_path=`$WHICH "$new_path" 2> /dev/null` 19148 # bat and cmd files are not always considered executable in cygwin causing which 19149 # to not find them 19150 if test "x$new_path" = x \ 19151 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 19152 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 19153 new_path=`$CYGPATH -u "$path"` 19154 fi 19155 if test "x$new_path" = x; then 19156 # It's still not found. Now this is an unrecoverable error. 19157 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of FOUND_MAKE, which resolves as \"$complete\", is not found." >&5 19158 $as_echo "$as_me: The path of FOUND_MAKE, which resolves as \"$complete\", is not found." >&6;} 19159 has_space=`$ECHO "$complete" | $GREP " "` 19160 if test "x$has_space" != x; then 19161 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 19162 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 19163 fi 19164 as_fn_error $? "Cannot locate the the path of FOUND_MAKE" "$LINENO" 5 19165 fi 19166 fi 19167 19168 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 19169 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 19170 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 19171 # "foo.exe" is OK but "foo" is an error. 19172 # 19173 # This test is therefore slightly more accurate than "test -f" to check for file presence. 19174 # It is also a way to make sure we got the proper file name for the real test later on. 19175 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 19176 if test "x$test_shortpath" = x; then 19177 # Short path failed, file does not exist as specified. 19178 # Try adding .exe or .cmd 19179 if test -f "${new_path}.exe"; then 19180 input_to_shortpath="${new_path}.exe" 19181 elif test -f "${new_path}.cmd"; then 19182 input_to_shortpath="${new_path}.cmd" 19183 else 19184 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of FOUND_MAKE, which resolves as \"$new_path\", is invalid." >&5 19185 $as_echo "$as_me: The path of FOUND_MAKE, which resolves as \"$new_path\", is invalid." >&6;} 19186 { $as_echo "$as_me:${as_lineno-$LINENO}: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&5 19187 $as_echo "$as_me: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&6;} 19188 as_fn_error $? "Cannot locate the the path of FOUND_MAKE" "$LINENO" 5 19189 fi 19190 else 19191 input_to_shortpath="$new_path" 19192 fi 19193 19194 # Call helper function which possibly converts this using DOS-style short mode. 19195 # If so, the updated path is stored in $new_path. 19196 new_path="$input_to_shortpath" 19197 19198 input_path="$input_to_shortpath" 19199 # Check if we need to convert this using DOS-style short mode. If the path 19200 # contains just simple characters, use it. Otherwise (spaces, weird characters), 19201 # take no chances and rewrite it. 19202 # Note: m4 eats our [], so we need to use [ and ] instead. 19203 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 19204 if test "x$has_forbidden_chars" != x; then 19205 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 19206 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 19207 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 19208 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 19209 # Going to short mode and back again did indeed matter. Since short mode is 19210 # case insensitive, let's make it lowercase to improve readability. 19211 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 19212 # Now convert it back to Unix-style (cygpath) 19213 input_path=`$CYGPATH -u "$shortmode_path"` 19214 new_path="$input_path" 19215 fi 19216 fi 19217 19218 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 19219 if test "x$test_cygdrive_prefix" = x; then 19220 # As a simple fix, exclude /usr/bin since it's not a real path. 19221 if test "x`$ECHO $input_to_shortpath | $GREP ^/usr/bin/`" = x; then 19222 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 19223 # a path prefixed by /cygdrive for fixpath to work. 19224 new_path="$CYGWIN_ROOT_PATH$input_path" 19225 fi 19226 fi 19227 19228 # remove trailing .exe if any 19229 new_path="${new_path/%.exe/}" 19230 19231 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 19232 19233 # First separate the path from the arguments. This will split at the first 19234 # space. 19235 complete="$FOUND_MAKE" 19236 path="${complete%% *}" 19237 tmp="$complete EOL" 19238 arguments="${tmp#* }" 19239 19240 # Input might be given as Windows format, start by converting to 19241 # unix format. 19242 new_path="$path" 19243 19244 windows_path="$new_path" 19245 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 19246 unix_path=`$CYGPATH -u "$windows_path"` 19247 new_path="$unix_path" 19248 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 19249 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 19250 new_path="$unix_path" 19251 fi 19252 19253 19254 # Now try to locate executable using which 19255 new_path=`$WHICH "$new_path" 2> /dev/null` 19256 19257 if test "x$new_path" = x; then 19258 # Oops. Which didn't find the executable. 19259 # The splitting of arguments from the executable at a space might have been incorrect, 19260 # since paths with space are more likely in Windows. Give it another try with the whole 19261 # argument. 19262 path="$complete" 19263 arguments="EOL" 19264 new_path="$path" 19265 19266 windows_path="$new_path" 19267 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 19268 unix_path=`$CYGPATH -u "$windows_path"` 19269 new_path="$unix_path" 19270 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 19271 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 19272 new_path="$unix_path" 19273 fi 19274 19275 19276 new_path=`$WHICH "$new_path" 2> /dev/null` 19277 # bat and cmd files are not always considered executable in MSYS causing which 19278 # to not find them 19279 if test "x$new_path" = x \ 19280 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 19281 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 19282 new_path="$path" 19283 19284 windows_path="$new_path" 19285 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 19286 unix_path=`$CYGPATH -u "$windows_path"` 19287 new_path="$unix_path" 19288 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 19289 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 19290 new_path="$unix_path" 19291 fi 19292 19293 fi 19294 19295 if test "x$new_path" = x; then 19296 # It's still not found. Now this is an unrecoverable error. 19297 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of FOUND_MAKE, which resolves as \"$complete\", is not found." >&5 19298 $as_echo "$as_me: The path of FOUND_MAKE, which resolves as \"$complete\", is not found." >&6;} 19299 has_space=`$ECHO "$complete" | $GREP " "` 19300 if test "x$has_space" != x; then 19301 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 19302 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 19303 fi 19304 as_fn_error $? "Cannot locate the the path of FOUND_MAKE" "$LINENO" 5 19305 fi 19306 fi 19307 19308 # Now new_path has a complete unix path to the binary 19309 if test "x`$ECHO $new_path | $GREP ^/bin/`" != x; then 19310 # Keep paths in /bin as-is, but remove trailing .exe if any 19311 new_path="${new_path/%.exe/}" 19312 # Do not save /bin paths to all_fixpath_prefixes! 19313 else 19314 # Not in mixed or Windows style, start by that. 19315 new_path=`cmd //c echo $new_path` 19316 19317 input_path="$new_path" 19318 # Check if we need to convert this using DOS-style short mode. If the path 19319 # contains just simple characters, use it. Otherwise (spaces, weird characters), 19320 # take no chances and rewrite it. 19321 # Note: m4 eats our [], so we need to use [ and ] instead. 19322 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 19323 if test "x$has_forbidden_chars" != x; then 19324 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 19325 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 19326 fi 19327 19328 # Output is in $new_path 19329 19330 windows_path="$new_path" 19331 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 19332 unix_path=`$CYGPATH -u "$windows_path"` 19333 new_path="$unix_path" 19334 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 19335 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 19336 new_path="$unix_path" 19337 fi 19338 19339 # remove trailing .exe if any 19340 new_path="${new_path/%.exe/}" 19341 19342 # Save the first 10 bytes of this path to the storage, so fixpath can work. 19343 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 19344 fi 19345 19346 else 19347 # We're on a unix platform. Hooray! :) 19348 # First separate the path from the arguments. This will split at the first 19349 # space. 19350 complete="$FOUND_MAKE" 19351 path="${complete%% *}" 19352 tmp="$complete EOL" 19353 arguments="${tmp#* }" 19354 19355 # Cannot rely on the command "which" here since it doesn't always work. 19356 is_absolute_path=`$ECHO "$path" | $GREP ^/` 19357 if test -z "$is_absolute_path"; then 19358 # Path to executable is not absolute. Find it. 19359 IFS_save="$IFS" 19360 IFS=: 19361 for p in $PATH; do 19362 if test -f "$p/$path" && test -x "$p/$path"; then 19363 new_path="$p/$path" 19364 break 19365 fi 19366 done 19367 IFS="$IFS_save" 19368 else 19369 # This is an absolute path, we can use it without further modifications. 19370 new_path="$path" 19371 fi 19372 19373 if test "x$new_path" = x; then 19374 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of FOUND_MAKE, which resolves as \"$complete\", is not found." >&5 19375 $as_echo "$as_me: The path of FOUND_MAKE, which resolves as \"$complete\", is not found." >&6;} 19376 has_space=`$ECHO "$complete" | $GREP " "` 19377 if test "x$has_space" != x; then 19378 { $as_echo "$as_me:${as_lineno-$LINENO}: This might be caused by spaces in the path, which is not allowed." >&5 19379 $as_echo "$as_me: This might be caused by spaces in the path, which is not allowed." >&6;} 19380 fi 19381 as_fn_error $? "Cannot locate the the path of FOUND_MAKE" "$LINENO" 5 19382 fi 19383 fi 19384 19385 # Now join together the path and the arguments once again 19386 if test "x$arguments" != xEOL; then 19387 new_complete="$new_path ${arguments% *}" 19388 else 19389 new_complete="$new_path" 19390 fi 19391 19392 if test "x$complete" != "x$new_complete"; then 19393 FOUND_MAKE="$new_complete" 19394 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting FOUND_MAKE to \"$new_complete\"" >&5 19395 $as_echo "$as_me: Rewriting FOUND_MAKE to \"$new_complete\"" >&6;} 19396 fi 19397 fi 19398 19399 fi 19400 fi 19401 fi 19402 fi 19403 19404 fi 19405 PATH=$OLD_PATH 19406 fi 19407 fi 19408 19409 if test "x$FOUND_MAKE" = x; then 19410 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 19411 fi 19412 19413 else 19414 # The variable is set, but is it from the command line or the environment? 19415 19416 # Try to remove the string !MAKE! from our list. 19417 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!MAKE!/} 19418 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 19419 # If it failed, the variable was not from the command line. Ignore it, 19420 # but warn the user (except for BASH, which is always set by the calling BASH). 19421 if test "xMAKE" != xBASH; then 19422 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of MAKE from the environment. Use command line variables instead." >&5 19423 $as_echo "$as_me: WARNING: Ignoring value of MAKE from the environment. Use command line variables instead." >&2;} 19424 fi 19425 # Try to locate tool using the code snippet 19426 19427 # Try our hardest to locate a correct version of GNU make 19428 for ac_prog in gmake 19429 do 19430 # Extract the first word of "$ac_prog", so it can be a program name with args. 19431 set dummy $ac_prog; ac_word=$2 19432 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 19433 $as_echo_n "checking for $ac_word... " >&6; } 19434 if ${ac_cv_path_CHECK_GMAKE+:} false; then : 19435 $as_echo_n "(cached) " >&6 19436 else 19437 case $CHECK_GMAKE in 19438 [\\/]* | ?:[\\/]*) 19439 ac_cv_path_CHECK_GMAKE="$CHECK_GMAKE" # Let the user override the test with a path. 19440 ;; 19441 *) 19442 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 19443 for as_dir in $PATH 19444 do 19445 IFS=$as_save_IFS 19446 test -z "$as_dir" && as_dir=. 19447 for ac_exec_ext in '' $ac_executable_extensions; do 19448 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 19449 ac_cv_path_CHECK_GMAKE="$as_dir/$ac_word$ac_exec_ext" 19450 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 19451 break 2 19452 fi 19453 done 19454 done 19455 IFS=$as_save_IFS 19456 19457 ;; 19458 esac 19459 fi 19460 CHECK_GMAKE=$ac_cv_path_CHECK_GMAKE 19461 if test -n "$CHECK_GMAKE"; then 19462 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CHECK_GMAKE" >&5 19463 $as_echo "$CHECK_GMAKE" >&6; } 19464 else 19465 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 19466 $as_echo "no" >&6; } 19467 fi 19468 19469 19470 test -n "$CHECK_GMAKE" && break 19471 done 19472 19473 19474 MAKE_CANDIDATE=""$CHECK_GMAKE"" 19475 DESCRIPTION="gmake in PATH" 19476 19477 # On Cygwin, we require a newer version of make than on other platforms 19478 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 19479 MAKE_VERSION_EXPR="-e 4\." 19480 MAKE_REQUIRED_VERSION="4.0" 19481 else 19482 MAKE_VERSION_EXPR="-e 3\.8[12] -e 4\." 19483 MAKE_REQUIRED_VERSION="3.81" 19484 fi 19485 19486 if test "x$MAKE_CANDIDATE" != x; then 19487 { $as_echo "$as_me:${as_lineno-$LINENO}: Testing potential make at $MAKE_CANDIDATE, found using $DESCRIPTION" >&5 19488 $as_echo "$as_me: Testing potential make at $MAKE_CANDIDATE, found using $DESCRIPTION" >&6;} 19489 MAKE_VERSION_STRING=`$MAKE_CANDIDATE --version | $HEAD -n 1` 19490 IS_GNU_MAKE=`$ECHO $MAKE_VERSION_STRING | $GREP 'GNU Make'` 19491 if test "x$IS_GNU_MAKE" = x; then 19492 { $as_echo "$as_me:${as_lineno-$LINENO}: Found potential make at $MAKE_CANDIDATE, however, this is not GNU Make. Ignoring." >&5 19493 $as_echo "$as_me: Found potential make at $MAKE_CANDIDATE, however, this is not GNU Make. Ignoring." >&6;} 19494 else 19495 IS_MODERN_MAKE=`$ECHO $MAKE_VERSION_STRING | $GREP $MAKE_VERSION_EXPR` 19496 if test "x$IS_MODERN_MAKE" = x; then 19497 { $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 19498 $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;} 19499 else 19500 if test "x$OPENJDK_BUILD_OS" = "xwindows"; then 19501 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 19502 MAKE_EXPECTED_ENV='cygwin' 19503 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 19504 MAKE_EXPECTED_ENV='msys' 19505 else 19506 as_fn_error $? "Unknown Windows environment" "$LINENO" 5 19507 fi 19508 MAKE_BUILT_FOR=`$MAKE_CANDIDATE --version | $GREP -i 'built for'` 19509 IS_MAKE_CORRECT_ENV=`$ECHO $MAKE_BUILT_FOR | $GREP $MAKE_EXPECTED_ENV` 19510 else 19511 # Not relevant for non-Windows 19512 IS_MAKE_CORRECT_ENV=true 19513 fi 19514 if test "x$IS_MAKE_CORRECT_ENV" = x; then 19515 { $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 19516 $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;} 19517 else 19518 FOUND_MAKE=$MAKE_CANDIDATE 19519 19520 # Only process if variable expands to non-empty 19521 19522 if test "x$FOUND_MAKE" != x; then 19523 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 19524 19525 # First separate the path from the arguments. This will split at the first 19526 # space. 19527 complete="$FOUND_MAKE" 19528 path="${complete%% *}" 19529 tmp="$complete EOL" 19530 arguments="${tmp#* }" 19531 19532 # Input might be given as Windows format, start by converting to 19533 # unix format. 19534 new_path=`$CYGPATH -u "$path"` 19535 19536 # Now try to locate executable using which 19537 new_path=`$WHICH "$new_path" 2> /dev/null` 19538 # bat and cmd files are not always considered executable in cygwin causing which 19539 # to not find them 19540 if test "x$new_path" = x \ 19541 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 19542 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 19543 new_path=`$CYGPATH -u "$path"` 19544 fi 19545 if test "x$new_path" = x; then 19546 # Oops. Which didn't find the executable. 19547 # The splitting of arguments from the executable at a space might have been incorrect, 19548 # since paths with space are more likely in Windows. Give it another try with the whole 19549 # argument. 19550 path="$complete" 19551 arguments="EOL" 19552 new_path=`$CYGPATH -u "$path"` 19553 new_path=`$WHICH "$new_path" 2> /dev/null` 19554 # bat and cmd files are not always considered executable in cygwin causing which 19555 # to not find them 19556 if test "x$new_path" = x \ 19557 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 19558 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 19559 new_path=`$CYGPATH -u "$path"` 19560 fi 19561 if test "x$new_path" = x; then 19562 # It's still not found. Now this is an unrecoverable error. 19563 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of FOUND_MAKE, which resolves as \"$complete\", is not found." >&5 19564 $as_echo "$as_me: The path of FOUND_MAKE, which resolves as \"$complete\", is not found." >&6;} 19565 has_space=`$ECHO "$complete" | $GREP " "` 19566 if test "x$has_space" != x; then 19567 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 19568 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 19569 fi 19570 as_fn_error $? "Cannot locate the the path of FOUND_MAKE" "$LINENO" 5 19571 fi 19572 fi 19573 19574 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 19575 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 19576 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 19577 # "foo.exe" is OK but "foo" is an error. 19578 # 19579 # This test is therefore slightly more accurate than "test -f" to check for file presence. 19580 # It is also a way to make sure we got the proper file name for the real test later on. 19581 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 19582 if test "x$test_shortpath" = x; then 19583 # Short path failed, file does not exist as specified. 19584 # Try adding .exe or .cmd 19585 if test -f "${new_path}.exe"; then 19586 input_to_shortpath="${new_path}.exe" 19587 elif test -f "${new_path}.cmd"; then 19588 input_to_shortpath="${new_path}.cmd" 19589 else 19590 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of FOUND_MAKE, which resolves as \"$new_path\", is invalid." >&5 19591 $as_echo "$as_me: The path of FOUND_MAKE, which resolves as \"$new_path\", is invalid." >&6;} 19592 { $as_echo "$as_me:${as_lineno-$LINENO}: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&5 19593 $as_echo "$as_me: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&6;} 19594 as_fn_error $? "Cannot locate the the path of FOUND_MAKE" "$LINENO" 5 19595 fi 19596 else 19597 input_to_shortpath="$new_path" 19598 fi 19599 19600 # Call helper function which possibly converts this using DOS-style short mode. 19601 # If so, the updated path is stored in $new_path. 19602 new_path="$input_to_shortpath" 19603 19604 input_path="$input_to_shortpath" 19605 # Check if we need to convert this using DOS-style short mode. If the path 19606 # contains just simple characters, use it. Otherwise (spaces, weird characters), 19607 # take no chances and rewrite it. 19608 # Note: m4 eats our [], so we need to use [ and ] instead. 19609 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 19610 if test "x$has_forbidden_chars" != x; then 19611 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 19612 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 19613 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 19614 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 19615 # Going to short mode and back again did indeed matter. Since short mode is 19616 # case insensitive, let's make it lowercase to improve readability. 19617 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 19618 # Now convert it back to Unix-style (cygpath) 19619 input_path=`$CYGPATH -u "$shortmode_path"` 19620 new_path="$input_path" 19621 fi 19622 fi 19623 19624 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 19625 if test "x$test_cygdrive_prefix" = x; then 19626 # As a simple fix, exclude /usr/bin since it's not a real path. 19627 if test "x`$ECHO $input_to_shortpath | $GREP ^/usr/bin/`" = x; then 19628 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 19629 # a path prefixed by /cygdrive for fixpath to work. 19630 new_path="$CYGWIN_ROOT_PATH$input_path" 19631 fi 19632 fi 19633 19634 # remove trailing .exe if any 19635 new_path="${new_path/%.exe/}" 19636 19637 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 19638 19639 # First separate the path from the arguments. This will split at the first 19640 # space. 19641 complete="$FOUND_MAKE" 19642 path="${complete%% *}" 19643 tmp="$complete EOL" 19644 arguments="${tmp#* }" 19645 19646 # Input might be given as Windows format, start by converting to 19647 # unix format. 19648 new_path="$path" 19649 19650 windows_path="$new_path" 19651 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 19652 unix_path=`$CYGPATH -u "$windows_path"` 19653 new_path="$unix_path" 19654 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 19655 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 19656 new_path="$unix_path" 19657 fi 19658 19659 19660 # Now try to locate executable using which 19661 new_path=`$WHICH "$new_path" 2> /dev/null` 19662 19663 if test "x$new_path" = x; then 19664 # Oops. Which didn't find the executable. 19665 # The splitting of arguments from the executable at a space might have been incorrect, 19666 # since paths with space are more likely in Windows. Give it another try with the whole 19667 # argument. 19668 path="$complete" 19669 arguments="EOL" 19670 new_path="$path" 19671 19672 windows_path="$new_path" 19673 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 19674 unix_path=`$CYGPATH -u "$windows_path"` 19675 new_path="$unix_path" 19676 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 19677 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 19678 new_path="$unix_path" 19679 fi 19680 19681 19682 new_path=`$WHICH "$new_path" 2> /dev/null` 19683 # bat and cmd files are not always considered executable in MSYS causing which 19684 # to not find them 19685 if test "x$new_path" = x \ 19686 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 19687 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 19688 new_path="$path" 19689 19690 windows_path="$new_path" 19691 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 19692 unix_path=`$CYGPATH -u "$windows_path"` 19693 new_path="$unix_path" 19694 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 19695 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 19696 new_path="$unix_path" 19697 fi 19698 19699 fi 19700 19701 if test "x$new_path" = x; then 19702 # It's still not found. Now this is an unrecoverable error. 19703 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of FOUND_MAKE, which resolves as \"$complete\", is not found." >&5 19704 $as_echo "$as_me: The path of FOUND_MAKE, which resolves as \"$complete\", is not found." >&6;} 19705 has_space=`$ECHO "$complete" | $GREP " "` 19706 if test "x$has_space" != x; then 19707 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 19708 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 19709 fi 19710 as_fn_error $? "Cannot locate the the path of FOUND_MAKE" "$LINENO" 5 19711 fi 19712 fi 19713 19714 # Now new_path has a complete unix path to the binary 19715 if test "x`$ECHO $new_path | $GREP ^/bin/`" != x; then 19716 # Keep paths in /bin as-is, but remove trailing .exe if any 19717 new_path="${new_path/%.exe/}" 19718 # Do not save /bin paths to all_fixpath_prefixes! 19719 else 19720 # Not in mixed or Windows style, start by that. 19721 new_path=`cmd //c echo $new_path` 19722 19723 input_path="$new_path" 19724 # Check if we need to convert this using DOS-style short mode. If the path 19725 # contains just simple characters, use it. Otherwise (spaces, weird characters), 19726 # take no chances and rewrite it. 19727 # Note: m4 eats our [], so we need to use [ and ] instead. 19728 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 19729 if test "x$has_forbidden_chars" != x; then 19730 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 19731 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 19732 fi 19733 19734 # Output is in $new_path 19735 19736 windows_path="$new_path" 19737 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 19738 unix_path=`$CYGPATH -u "$windows_path"` 19739 new_path="$unix_path" 19740 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 19741 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 19742 new_path="$unix_path" 19743 fi 19744 19745 # remove trailing .exe if any 19746 new_path="${new_path/%.exe/}" 19747 19748 # Save the first 10 bytes of this path to the storage, so fixpath can work. 19749 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 19750 fi 19751 19752 else 19753 # We're on a unix platform. Hooray! :) 19754 # First separate the path from the arguments. This will split at the first 19755 # space. 19756 complete="$FOUND_MAKE" 19757 path="${complete%% *}" 19758 tmp="$complete EOL" 19759 arguments="${tmp#* }" 19760 19761 # Cannot rely on the command "which" here since it doesn't always work. 19762 is_absolute_path=`$ECHO "$path" | $GREP ^/` 19763 if test -z "$is_absolute_path"; then 19764 # Path to executable is not absolute. Find it. 19765 IFS_save="$IFS" 19766 IFS=: 19767 for p in $PATH; do 19768 if test -f "$p/$path" && test -x "$p/$path"; then 19769 new_path="$p/$path" 19770 break 19771 fi 19772 done 19773 IFS="$IFS_save" 19774 else 19775 # This is an absolute path, we can use it without further modifications. 19776 new_path="$path" 19777 fi 19778 19779 if test "x$new_path" = x; then 19780 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of FOUND_MAKE, which resolves as \"$complete\", is not found." >&5 19781 $as_echo "$as_me: The path of FOUND_MAKE, which resolves as \"$complete\", is not found." >&6;} 19782 has_space=`$ECHO "$complete" | $GREP " "` 19783 if test "x$has_space" != x; then 19784 { $as_echo "$as_me:${as_lineno-$LINENO}: This might be caused by spaces in the path, which is not allowed." >&5 19785 $as_echo "$as_me: This might be caused by spaces in the path, which is not allowed." >&6;} 19786 fi 19787 as_fn_error $? "Cannot locate the the path of FOUND_MAKE" "$LINENO" 5 19788 fi 19789 fi 19790 19791 # Now join together the path and the arguments once again 19792 if test "x$arguments" != xEOL; then 19793 new_complete="$new_path ${arguments% *}" 19794 else 19795 new_complete="$new_path" 19796 fi 19797 19798 if test "x$complete" != "x$new_complete"; then 19799 FOUND_MAKE="$new_complete" 19800 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting FOUND_MAKE to \"$new_complete\"" >&5 19801 $as_echo "$as_me: Rewriting FOUND_MAKE to \"$new_complete\"" >&6;} 19802 fi 19803 fi 19804 19805 fi 19806 fi 19807 fi 19808 fi 19809 19810 19811 if test "x$FOUND_MAKE" = x; then 19812 for ac_prog in make 19813 do 19814 # Extract the first word of "$ac_prog", so it can be a program name with args. 19815 set dummy $ac_prog; ac_word=$2 19816 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 19817 $as_echo_n "checking for $ac_word... " >&6; } 19818 if ${ac_cv_path_CHECK_MAKE+:} false; then : 19819 $as_echo_n "(cached) " >&6 19820 else 19821 case $CHECK_MAKE in 19822 [\\/]* | ?:[\\/]*) 19823 ac_cv_path_CHECK_MAKE="$CHECK_MAKE" # Let the user override the test with a path. 19824 ;; 19825 *) 19826 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 19827 for as_dir in $PATH 19828 do 19829 IFS=$as_save_IFS 19830 test -z "$as_dir" && as_dir=. 19831 for ac_exec_ext in '' $ac_executable_extensions; do 19832 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 19833 ac_cv_path_CHECK_MAKE="$as_dir/$ac_word$ac_exec_ext" 19834 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 19835 break 2 19836 fi 19837 done 19838 done 19839 IFS=$as_save_IFS 19840 19841 ;; 19842 esac 19843 fi 19844 CHECK_MAKE=$ac_cv_path_CHECK_MAKE 19845 if test -n "$CHECK_MAKE"; then 19846 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CHECK_MAKE" >&5 19847 $as_echo "$CHECK_MAKE" >&6; } 19848 else 19849 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 19850 $as_echo "no" >&6; } 19851 fi 19852 19853 19854 test -n "$CHECK_MAKE" && break 19855 done 19856 19857 19858 MAKE_CANDIDATE=""$CHECK_MAKE"" 19859 DESCRIPTION="make in PATH" 19860 19861 # On Cygwin, we require a newer version of make than on other platforms 19862 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 19863 MAKE_VERSION_EXPR="-e 4\." 19864 MAKE_REQUIRED_VERSION="4.0" 19865 else 19866 MAKE_VERSION_EXPR="-e 3\.8[12] -e 4\." 19867 MAKE_REQUIRED_VERSION="3.81" 19868 fi 19869 19870 if test "x$MAKE_CANDIDATE" != x; then 19871 { $as_echo "$as_me:${as_lineno-$LINENO}: Testing potential make at $MAKE_CANDIDATE, found using $DESCRIPTION" >&5 19872 $as_echo "$as_me: Testing potential make at $MAKE_CANDIDATE, found using $DESCRIPTION" >&6;} 19873 MAKE_VERSION_STRING=`$MAKE_CANDIDATE --version | $HEAD -n 1` 19874 IS_GNU_MAKE=`$ECHO $MAKE_VERSION_STRING | $GREP 'GNU Make'` 19875 if test "x$IS_GNU_MAKE" = x; then 19876 { $as_echo "$as_me:${as_lineno-$LINENO}: Found potential make at $MAKE_CANDIDATE, however, this is not GNU Make. Ignoring." >&5 19877 $as_echo "$as_me: Found potential make at $MAKE_CANDIDATE, however, this is not GNU Make. Ignoring." >&6;} 19878 else 19879 IS_MODERN_MAKE=`$ECHO $MAKE_VERSION_STRING | $GREP $MAKE_VERSION_EXPR` 19880 if test "x$IS_MODERN_MAKE" = x; then 19881 { $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 19882 $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;} 19883 else 19884 if test "x$OPENJDK_BUILD_OS" = "xwindows"; then 19885 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 19886 MAKE_EXPECTED_ENV='cygwin' 19887 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 19888 MAKE_EXPECTED_ENV='msys' 19889 else 19890 as_fn_error $? "Unknown Windows environment" "$LINENO" 5 19891 fi 19892 MAKE_BUILT_FOR=`$MAKE_CANDIDATE --version | $GREP -i 'built for'` 19893 IS_MAKE_CORRECT_ENV=`$ECHO $MAKE_BUILT_FOR | $GREP $MAKE_EXPECTED_ENV` 19894 else 19895 # Not relevant for non-Windows 19896 IS_MAKE_CORRECT_ENV=true 19897 fi 19898 if test "x$IS_MAKE_CORRECT_ENV" = x; then 19899 { $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 19900 $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;} 19901 else 19902 FOUND_MAKE=$MAKE_CANDIDATE 19903 19904 # Only process if variable expands to non-empty 19905 19906 if test "x$FOUND_MAKE" != x; then 19907 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 19908 19909 # First separate the path from the arguments. This will split at the first 19910 # space. 19911 complete="$FOUND_MAKE" 19912 path="${complete%% *}" 19913 tmp="$complete EOL" 19914 arguments="${tmp#* }" 19915 19916 # Input might be given as Windows format, start by converting to 19917 # unix format. 19918 new_path=`$CYGPATH -u "$path"` 19919 19920 # Now try to locate executable using which 19921 new_path=`$WHICH "$new_path" 2> /dev/null` 19922 # bat and cmd files are not always considered executable in cygwin causing which 19923 # to not find them 19924 if test "x$new_path" = x \ 19925 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 19926 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 19927 new_path=`$CYGPATH -u "$path"` 19928 fi 19929 if test "x$new_path" = x; then 19930 # Oops. Which didn't find the executable. 19931 # The splitting of arguments from the executable at a space might have been incorrect, 19932 # since paths with space are more likely in Windows. Give it another try with the whole 19933 # argument. 19934 path="$complete" 19935 arguments="EOL" 19936 new_path=`$CYGPATH -u "$path"` 19937 new_path=`$WHICH "$new_path" 2> /dev/null` 19938 # bat and cmd files are not always considered executable in cygwin causing which 19939 # to not find them 19940 if test "x$new_path" = x \ 19941 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 19942 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 19943 new_path=`$CYGPATH -u "$path"` 19944 fi 19945 if test "x$new_path" = x; then 19946 # It's still not found. Now this is an unrecoverable error. 19947 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of FOUND_MAKE, which resolves as \"$complete\", is not found." >&5 19948 $as_echo "$as_me: The path of FOUND_MAKE, which resolves as \"$complete\", is not found." >&6;} 19949 has_space=`$ECHO "$complete" | $GREP " "` 19950 if test "x$has_space" != x; then 19951 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 19952 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 19953 fi 19954 as_fn_error $? "Cannot locate the the path of FOUND_MAKE" "$LINENO" 5 19955 fi 19956 fi 19957 19958 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 19959 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 19960 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 19961 # "foo.exe" is OK but "foo" is an error. 19962 # 19963 # This test is therefore slightly more accurate than "test -f" to check for file presence. 19964 # It is also a way to make sure we got the proper file name for the real test later on. 19965 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 19966 if test "x$test_shortpath" = x; then 19967 # Short path failed, file does not exist as specified. 19968 # Try adding .exe or .cmd 19969 if test -f "${new_path}.exe"; then 19970 input_to_shortpath="${new_path}.exe" 19971 elif test -f "${new_path}.cmd"; then 19972 input_to_shortpath="${new_path}.cmd" 19973 else 19974 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of FOUND_MAKE, which resolves as \"$new_path\", is invalid." >&5 19975 $as_echo "$as_me: The path of FOUND_MAKE, which resolves as \"$new_path\", is invalid." >&6;} 19976 { $as_echo "$as_me:${as_lineno-$LINENO}: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&5 19977 $as_echo "$as_me: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&6;} 19978 as_fn_error $? "Cannot locate the the path of FOUND_MAKE" "$LINENO" 5 19979 fi 19980 else 19981 input_to_shortpath="$new_path" 19982 fi 19983 19984 # Call helper function which possibly converts this using DOS-style short mode. 19985 # If so, the updated path is stored in $new_path. 19986 new_path="$input_to_shortpath" 19987 19988 input_path="$input_to_shortpath" 19989 # Check if we need to convert this using DOS-style short mode. If the path 19990 # contains just simple characters, use it. Otherwise (spaces, weird characters), 19991 # take no chances and rewrite it. 19992 # Note: m4 eats our [], so we need to use [ and ] instead. 19993 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 19994 if test "x$has_forbidden_chars" != x; then 19995 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 19996 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 19997 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 19998 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 19999 # Going to short mode and back again did indeed matter. Since short mode is 20000 # case insensitive, let's make it lowercase to improve readability. 20001 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 20002 # Now convert it back to Unix-style (cygpath) 20003 input_path=`$CYGPATH -u "$shortmode_path"` 20004 new_path="$input_path" 20005 fi 20006 fi 20007 20008 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 20009 if test "x$test_cygdrive_prefix" = x; then 20010 # As a simple fix, exclude /usr/bin since it's not a real path. 20011 if test "x`$ECHO $input_to_shortpath | $GREP ^/usr/bin/`" = x; then 20012 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 20013 # a path prefixed by /cygdrive for fixpath to work. 20014 new_path="$CYGWIN_ROOT_PATH$input_path" 20015 fi 20016 fi 20017 20018 # remove trailing .exe if any 20019 new_path="${new_path/%.exe/}" 20020 20021 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 20022 20023 # First separate the path from the arguments. This will split at the first 20024 # space. 20025 complete="$FOUND_MAKE" 20026 path="${complete%% *}" 20027 tmp="$complete EOL" 20028 arguments="${tmp#* }" 20029 20030 # Input might be given as Windows format, start by converting to 20031 # unix format. 20032 new_path="$path" 20033 20034 windows_path="$new_path" 20035 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 20036 unix_path=`$CYGPATH -u "$windows_path"` 20037 new_path="$unix_path" 20038 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 20039 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 20040 new_path="$unix_path" 20041 fi 20042 20043 20044 # Now try to locate executable using which 20045 new_path=`$WHICH "$new_path" 2> /dev/null` 20046 20047 if test "x$new_path" = x; then 20048 # Oops. Which didn't find the executable. 20049 # The splitting of arguments from the executable at a space might have been incorrect, 20050 # since paths with space are more likely in Windows. Give it another try with the whole 20051 # argument. 20052 path="$complete" 20053 arguments="EOL" 20054 new_path="$path" 20055 20056 windows_path="$new_path" 20057 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 20058 unix_path=`$CYGPATH -u "$windows_path"` 20059 new_path="$unix_path" 20060 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 20061 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 20062 new_path="$unix_path" 20063 fi 20064 20065 20066 new_path=`$WHICH "$new_path" 2> /dev/null` 20067 # bat and cmd files are not always considered executable in MSYS causing which 20068 # to not find them 20069 if test "x$new_path" = x \ 20070 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 20071 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 20072 new_path="$path" 20073 20074 windows_path="$new_path" 20075 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 20076 unix_path=`$CYGPATH -u "$windows_path"` 20077 new_path="$unix_path" 20078 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 20079 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 20080 new_path="$unix_path" 20081 fi 20082 20083 fi 20084 20085 if test "x$new_path" = x; then 20086 # It's still not found. Now this is an unrecoverable error. 20087 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of FOUND_MAKE, which resolves as \"$complete\", is not found." >&5 20088 $as_echo "$as_me: The path of FOUND_MAKE, which resolves as \"$complete\", is not found." >&6;} 20089 has_space=`$ECHO "$complete" | $GREP " "` 20090 if test "x$has_space" != x; then 20091 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 20092 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 20093 fi 20094 as_fn_error $? "Cannot locate the the path of FOUND_MAKE" "$LINENO" 5 20095 fi 20096 fi 20097 20098 # Now new_path has a complete unix path to the binary 20099 if test "x`$ECHO $new_path | $GREP ^/bin/`" != x; then 20100 # Keep paths in /bin as-is, but remove trailing .exe if any 20101 new_path="${new_path/%.exe/}" 20102 # Do not save /bin paths to all_fixpath_prefixes! 20103 else 20104 # Not in mixed or Windows style, start by that. 20105 new_path=`cmd //c echo $new_path` 20106 20107 input_path="$new_path" 20108 # Check if we need to convert this using DOS-style short mode. If the path 20109 # contains just simple characters, use it. Otherwise (spaces, weird characters), 20110 # take no chances and rewrite it. 20111 # Note: m4 eats our [], so we need to use [ and ] instead. 20112 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 20113 if test "x$has_forbidden_chars" != x; then 20114 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 20115 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 20116 fi 20117 20118 # Output is in $new_path 20119 20120 windows_path="$new_path" 20121 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 20122 unix_path=`$CYGPATH -u "$windows_path"` 20123 new_path="$unix_path" 20124 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 20125 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 20126 new_path="$unix_path" 20127 fi 20128 20129 # remove trailing .exe if any 20130 new_path="${new_path/%.exe/}" 20131 20132 # Save the first 10 bytes of this path to the storage, so fixpath can work. 20133 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 20134 fi 20135 20136 else 20137 # We're on a unix platform. Hooray! :) 20138 # First separate the path from the arguments. This will split at the first 20139 # space. 20140 complete="$FOUND_MAKE" 20141 path="${complete%% *}" 20142 tmp="$complete EOL" 20143 arguments="${tmp#* }" 20144 20145 # Cannot rely on the command "which" here since it doesn't always work. 20146 is_absolute_path=`$ECHO "$path" | $GREP ^/` 20147 if test -z "$is_absolute_path"; then 20148 # Path to executable is not absolute. Find it. 20149 IFS_save="$IFS" 20150 IFS=: 20151 for p in $PATH; do 20152 if test -f "$p/$path" && test -x "$p/$path"; then 20153 new_path="$p/$path" 20154 break 20155 fi 20156 done 20157 IFS="$IFS_save" 20158 else 20159 # This is an absolute path, we can use it without further modifications. 20160 new_path="$path" 20161 fi 20162 20163 if test "x$new_path" = x; then 20164 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of FOUND_MAKE, which resolves as \"$complete\", is not found." >&5 20165 $as_echo "$as_me: The path of FOUND_MAKE, which resolves as \"$complete\", is not found." >&6;} 20166 has_space=`$ECHO "$complete" | $GREP " "` 20167 if test "x$has_space" != x; then 20168 { $as_echo "$as_me:${as_lineno-$LINENO}: This might be caused by spaces in the path, which is not allowed." >&5 20169 $as_echo "$as_me: This might be caused by spaces in the path, which is not allowed." >&6;} 20170 fi 20171 as_fn_error $? "Cannot locate the the path of FOUND_MAKE" "$LINENO" 5 20172 fi 20173 fi 20174 20175 # Now join together the path and the arguments once again 20176 if test "x$arguments" != xEOL; then 20177 new_complete="$new_path ${arguments% *}" 20178 else 20179 new_complete="$new_path" 20180 fi 20181 20182 if test "x$complete" != "x$new_complete"; then 20183 FOUND_MAKE="$new_complete" 20184 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting FOUND_MAKE to \"$new_complete\"" >&5 20185 $as_echo "$as_me: Rewriting FOUND_MAKE to \"$new_complete\"" >&6;} 20186 fi 20187 fi 20188 20189 fi 20190 fi 20191 fi 20192 fi 20193 20194 fi 20195 20196 if test "x$FOUND_MAKE" = x; then 20197 if test "x$TOOLCHAIN_PATH" != x; then 20198 # We have a toolchain path, check that as well before giving up. 20199 OLD_PATH=$PATH 20200 PATH=$TOOLCHAIN_PATH:$PATH 20201 for ac_prog in gmake 20202 do 20203 # Extract the first word of "$ac_prog", so it can be a program name with args. 20204 set dummy $ac_prog; ac_word=$2 20205 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 20206 $as_echo_n "checking for $ac_word... " >&6; } 20207 if ${ac_cv_path_CHECK_TOOLSDIR_GMAKE+:} false; then : 20208 $as_echo_n "(cached) " >&6 20209 else 20210 case $CHECK_TOOLSDIR_GMAKE in 20211 [\\/]* | ?:[\\/]*) 20212 ac_cv_path_CHECK_TOOLSDIR_GMAKE="$CHECK_TOOLSDIR_GMAKE" # Let the user override the test with a path. 20213 ;; 20214 *) 20215 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 20216 for as_dir in $PATH 20217 do 20218 IFS=$as_save_IFS 20219 test -z "$as_dir" && as_dir=. 20220 for ac_exec_ext in '' $ac_executable_extensions; do 20221 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 20222 ac_cv_path_CHECK_TOOLSDIR_GMAKE="$as_dir/$ac_word$ac_exec_ext" 20223 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 20224 break 2 20225 fi 20226 done 20227 done 20228 IFS=$as_save_IFS 20229 20230 ;; 20231 esac 20232 fi 20233 CHECK_TOOLSDIR_GMAKE=$ac_cv_path_CHECK_TOOLSDIR_GMAKE 20234 if test -n "$CHECK_TOOLSDIR_GMAKE"; then 20235 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CHECK_TOOLSDIR_GMAKE" >&5 20236 $as_echo "$CHECK_TOOLSDIR_GMAKE" >&6; } 20237 else 20238 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 20239 $as_echo "no" >&6; } 20240 fi 20241 20242 20243 test -n "$CHECK_TOOLSDIR_GMAKE" && break 20244 done 20245 20246 20247 MAKE_CANDIDATE=""$CHECK_TOOLSDIR_GMAKE"" 20248 DESCRIPTION="gmake in tools-dir" 20249 20250 # On Cygwin, we require a newer version of make than on other platforms 20251 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 20252 MAKE_VERSION_EXPR="-e 4\." 20253 MAKE_REQUIRED_VERSION="4.0" 20254 else 20255 MAKE_VERSION_EXPR="-e 3\.8[12] -e 4\." 20256 MAKE_REQUIRED_VERSION="3.81" 20257 fi 20258 20259 if test "x$MAKE_CANDIDATE" != x; then 20260 { $as_echo "$as_me:${as_lineno-$LINENO}: Testing potential make at $MAKE_CANDIDATE, found using $DESCRIPTION" >&5 20261 $as_echo "$as_me: Testing potential make at $MAKE_CANDIDATE, found using $DESCRIPTION" >&6;} 20262 MAKE_VERSION_STRING=`$MAKE_CANDIDATE --version | $HEAD -n 1` 20263 IS_GNU_MAKE=`$ECHO $MAKE_VERSION_STRING | $GREP 'GNU Make'` 20264 if test "x$IS_GNU_MAKE" = x; then 20265 { $as_echo "$as_me:${as_lineno-$LINENO}: Found potential make at $MAKE_CANDIDATE, however, this is not GNU Make. Ignoring." >&5 20266 $as_echo "$as_me: Found potential make at $MAKE_CANDIDATE, however, this is not GNU Make. Ignoring." >&6;} 20267 else 20268 IS_MODERN_MAKE=`$ECHO $MAKE_VERSION_STRING | $GREP $MAKE_VERSION_EXPR` 20269 if test "x$IS_MODERN_MAKE" = x; then 20270 { $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 20271 $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;} 20272 else 20273 if test "x$OPENJDK_BUILD_OS" = "xwindows"; then 20274 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 20275 MAKE_EXPECTED_ENV='cygwin' 20276 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 20277 MAKE_EXPECTED_ENV='msys' 20278 else 20279 as_fn_error $? "Unknown Windows environment" "$LINENO" 5 20280 fi 20281 MAKE_BUILT_FOR=`$MAKE_CANDIDATE --version | $GREP -i 'built for'` 20282 IS_MAKE_CORRECT_ENV=`$ECHO $MAKE_BUILT_FOR | $GREP $MAKE_EXPECTED_ENV` 20283 else 20284 # Not relevant for non-Windows 20285 IS_MAKE_CORRECT_ENV=true 20286 fi 20287 if test "x$IS_MAKE_CORRECT_ENV" = x; then 20288 { $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 20289 $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;} 20290 else 20291 FOUND_MAKE=$MAKE_CANDIDATE 20292 20293 # Only process if variable expands to non-empty 20294 20295 if test "x$FOUND_MAKE" != x; then 20296 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 20297 20298 # First separate the path from the arguments. This will split at the first 20299 # space. 20300 complete="$FOUND_MAKE" 20301 path="${complete%% *}" 20302 tmp="$complete EOL" 20303 arguments="${tmp#* }" 20304 20305 # Input might be given as Windows format, start by converting to 20306 # unix format. 20307 new_path=`$CYGPATH -u "$path"` 20308 20309 # Now try to locate executable using which 20310 new_path=`$WHICH "$new_path" 2> /dev/null` 20311 # bat and cmd files are not always considered executable in cygwin causing which 20312 # to not find them 20313 if test "x$new_path" = x \ 20314 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 20315 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 20316 new_path=`$CYGPATH -u "$path"` 20317 fi 20318 if test "x$new_path" = x; then 20319 # Oops. Which didn't find the executable. 20320 # The splitting of arguments from the executable at a space might have been incorrect, 20321 # since paths with space are more likely in Windows. Give it another try with the whole 20322 # argument. 20323 path="$complete" 20324 arguments="EOL" 20325 new_path=`$CYGPATH -u "$path"` 20326 new_path=`$WHICH "$new_path" 2> /dev/null` 20327 # bat and cmd files are not always considered executable in cygwin causing which 20328 # to not find them 20329 if test "x$new_path" = x \ 20330 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 20331 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 20332 new_path=`$CYGPATH -u "$path"` 20333 fi 20334 if test "x$new_path" = x; then 20335 # It's still not found. Now this is an unrecoverable error. 20336 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of FOUND_MAKE, which resolves as \"$complete\", is not found." >&5 20337 $as_echo "$as_me: The path of FOUND_MAKE, which resolves as \"$complete\", is not found." >&6;} 20338 has_space=`$ECHO "$complete" | $GREP " "` 20339 if test "x$has_space" != x; then 20340 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 20341 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 20342 fi 20343 as_fn_error $? "Cannot locate the the path of FOUND_MAKE" "$LINENO" 5 20344 fi 20345 fi 20346 20347 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 20348 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 20349 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 20350 # "foo.exe" is OK but "foo" is an error. 20351 # 20352 # This test is therefore slightly more accurate than "test -f" to check for file presence. 20353 # It is also a way to make sure we got the proper file name for the real test later on. 20354 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 20355 if test "x$test_shortpath" = x; then 20356 # Short path failed, file does not exist as specified. 20357 # Try adding .exe or .cmd 20358 if test -f "${new_path}.exe"; then 20359 input_to_shortpath="${new_path}.exe" 20360 elif test -f "${new_path}.cmd"; then 20361 input_to_shortpath="${new_path}.cmd" 20362 else 20363 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of FOUND_MAKE, which resolves as \"$new_path\", is invalid." >&5 20364 $as_echo "$as_me: The path of FOUND_MAKE, which resolves as \"$new_path\", is invalid." >&6;} 20365 { $as_echo "$as_me:${as_lineno-$LINENO}: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&5 20366 $as_echo "$as_me: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&6;} 20367 as_fn_error $? "Cannot locate the the path of FOUND_MAKE" "$LINENO" 5 20368 fi 20369 else 20370 input_to_shortpath="$new_path" 20371 fi 20372 20373 # Call helper function which possibly converts this using DOS-style short mode. 20374 # If so, the updated path is stored in $new_path. 20375 new_path="$input_to_shortpath" 20376 20377 input_path="$input_to_shortpath" 20378 # Check if we need to convert this using DOS-style short mode. If the path 20379 # contains just simple characters, use it. Otherwise (spaces, weird characters), 20380 # take no chances and rewrite it. 20381 # Note: m4 eats our [], so we need to use [ and ] instead. 20382 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 20383 if test "x$has_forbidden_chars" != x; then 20384 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 20385 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 20386 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 20387 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 20388 # Going to short mode and back again did indeed matter. Since short mode is 20389 # case insensitive, let's make it lowercase to improve readability. 20390 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 20391 # Now convert it back to Unix-style (cygpath) 20392 input_path=`$CYGPATH -u "$shortmode_path"` 20393 new_path="$input_path" 20394 fi 20395 fi 20396 20397 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 20398 if test "x$test_cygdrive_prefix" = x; then 20399 # As a simple fix, exclude /usr/bin since it's not a real path. 20400 if test "x`$ECHO $input_to_shortpath | $GREP ^/usr/bin/`" = x; then 20401 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 20402 # a path prefixed by /cygdrive for fixpath to work. 20403 new_path="$CYGWIN_ROOT_PATH$input_path" 20404 fi 20405 fi 20406 20407 # remove trailing .exe if any 20408 new_path="${new_path/%.exe/}" 20409 20410 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 20411 20412 # First separate the path from the arguments. This will split at the first 20413 # space. 20414 complete="$FOUND_MAKE" 20415 path="${complete%% *}" 20416 tmp="$complete EOL" 20417 arguments="${tmp#* }" 20418 20419 # Input might be given as Windows format, start by converting to 20420 # unix format. 20421 new_path="$path" 20422 20423 windows_path="$new_path" 20424 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 20425 unix_path=`$CYGPATH -u "$windows_path"` 20426 new_path="$unix_path" 20427 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 20428 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 20429 new_path="$unix_path" 20430 fi 20431 20432 20433 # Now try to locate executable using which 20434 new_path=`$WHICH "$new_path" 2> /dev/null` 20435 20436 if test "x$new_path" = x; then 20437 # Oops. Which didn't find the executable. 20438 # The splitting of arguments from the executable at a space might have been incorrect, 20439 # since paths with space are more likely in Windows. Give it another try with the whole 20440 # argument. 20441 path="$complete" 20442 arguments="EOL" 20443 new_path="$path" 20444 20445 windows_path="$new_path" 20446 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 20447 unix_path=`$CYGPATH -u "$windows_path"` 20448 new_path="$unix_path" 20449 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 20450 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 20451 new_path="$unix_path" 20452 fi 20453 20454 20455 new_path=`$WHICH "$new_path" 2> /dev/null` 20456 # bat and cmd files are not always considered executable in MSYS causing which 20457 # to not find them 20458 if test "x$new_path" = x \ 20459 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 20460 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 20461 new_path="$path" 20462 20463 windows_path="$new_path" 20464 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 20465 unix_path=`$CYGPATH -u "$windows_path"` 20466 new_path="$unix_path" 20467 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 20468 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 20469 new_path="$unix_path" 20470 fi 20471 20472 fi 20473 20474 if test "x$new_path" = x; then 20475 # It's still not found. Now this is an unrecoverable error. 20476 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of FOUND_MAKE, which resolves as \"$complete\", is not found." >&5 20477 $as_echo "$as_me: The path of FOUND_MAKE, which resolves as \"$complete\", is not found." >&6;} 20478 has_space=`$ECHO "$complete" | $GREP " "` 20479 if test "x$has_space" != x; then 20480 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 20481 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 20482 fi 20483 as_fn_error $? "Cannot locate the the path of FOUND_MAKE" "$LINENO" 5 20484 fi 20485 fi 20486 20487 # Now new_path has a complete unix path to the binary 20488 if test "x`$ECHO $new_path | $GREP ^/bin/`" != x; then 20489 # Keep paths in /bin as-is, but remove trailing .exe if any 20490 new_path="${new_path/%.exe/}" 20491 # Do not save /bin paths to all_fixpath_prefixes! 20492 else 20493 # Not in mixed or Windows style, start by that. 20494 new_path=`cmd //c echo $new_path` 20495 20496 input_path="$new_path" 20497 # Check if we need to convert this using DOS-style short mode. If the path 20498 # contains just simple characters, use it. Otherwise (spaces, weird characters), 20499 # take no chances and rewrite it. 20500 # Note: m4 eats our [], so we need to use [ and ] instead. 20501 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 20502 if test "x$has_forbidden_chars" != x; then 20503 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 20504 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 20505 fi 20506 20507 # Output is in $new_path 20508 20509 windows_path="$new_path" 20510 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 20511 unix_path=`$CYGPATH -u "$windows_path"` 20512 new_path="$unix_path" 20513 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 20514 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 20515 new_path="$unix_path" 20516 fi 20517 20518 # remove trailing .exe if any 20519 new_path="${new_path/%.exe/}" 20520 20521 # Save the first 10 bytes of this path to the storage, so fixpath can work. 20522 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 20523 fi 20524 20525 else 20526 # We're on a unix platform. Hooray! :) 20527 # First separate the path from the arguments. This will split at the first 20528 # space. 20529 complete="$FOUND_MAKE" 20530 path="${complete%% *}" 20531 tmp="$complete EOL" 20532 arguments="${tmp#* }" 20533 20534 # Cannot rely on the command "which" here since it doesn't always work. 20535 is_absolute_path=`$ECHO "$path" | $GREP ^/` 20536 if test -z "$is_absolute_path"; then 20537 # Path to executable is not absolute. Find it. 20538 IFS_save="$IFS" 20539 IFS=: 20540 for p in $PATH; do 20541 if test -f "$p/$path" && test -x "$p/$path"; then 20542 new_path="$p/$path" 20543 break 20544 fi 20545 done 20546 IFS="$IFS_save" 20547 else 20548 # This is an absolute path, we can use it without further modifications. 20549 new_path="$path" 20550 fi 20551 20552 if test "x$new_path" = x; then 20553 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of FOUND_MAKE, which resolves as \"$complete\", is not found." >&5 20554 $as_echo "$as_me: The path of FOUND_MAKE, which resolves as \"$complete\", is not found." >&6;} 20555 has_space=`$ECHO "$complete" | $GREP " "` 20556 if test "x$has_space" != x; then 20557 { $as_echo "$as_me:${as_lineno-$LINENO}: This might be caused by spaces in the path, which is not allowed." >&5 20558 $as_echo "$as_me: This might be caused by spaces in the path, which is not allowed." >&6;} 20559 fi 20560 as_fn_error $? "Cannot locate the the path of FOUND_MAKE" "$LINENO" 5 20561 fi 20562 fi 20563 20564 # Now join together the path and the arguments once again 20565 if test "x$arguments" != xEOL; then 20566 new_complete="$new_path ${arguments% *}" 20567 else 20568 new_complete="$new_path" 20569 fi 20570 20571 if test "x$complete" != "x$new_complete"; then 20572 FOUND_MAKE="$new_complete" 20573 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting FOUND_MAKE to \"$new_complete\"" >&5 20574 $as_echo "$as_me: Rewriting FOUND_MAKE to \"$new_complete\"" >&6;} 20575 fi 20576 fi 20577 20578 fi 20579 fi 20580 fi 20581 fi 20582 20583 if test "x$FOUND_MAKE" = x; then 20584 for ac_prog in make 20585 do 20586 # Extract the first word of "$ac_prog", so it can be a program name with args. 20587 set dummy $ac_prog; ac_word=$2 20588 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 20589 $as_echo_n "checking for $ac_word... " >&6; } 20590 if ${ac_cv_path_CHECK_TOOLSDIR_MAKE+:} false; then : 20591 $as_echo_n "(cached) " >&6 20592 else 20593 case $CHECK_TOOLSDIR_MAKE in 20594 [\\/]* | ?:[\\/]*) 20595 ac_cv_path_CHECK_TOOLSDIR_MAKE="$CHECK_TOOLSDIR_MAKE" # Let the user override the test with a path. 20596 ;; 20597 *) 20598 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 20599 for as_dir in $PATH 20600 do 20601 IFS=$as_save_IFS 20602 test -z "$as_dir" && as_dir=. 20603 for ac_exec_ext in '' $ac_executable_extensions; do 20604 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 20605 ac_cv_path_CHECK_TOOLSDIR_MAKE="$as_dir/$ac_word$ac_exec_ext" 20606 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 20607 break 2 20608 fi 20609 done 20610 done 20611 IFS=$as_save_IFS 20612 20613 ;; 20614 esac 20615 fi 20616 CHECK_TOOLSDIR_MAKE=$ac_cv_path_CHECK_TOOLSDIR_MAKE 20617 if test -n "$CHECK_TOOLSDIR_MAKE"; then 20618 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CHECK_TOOLSDIR_MAKE" >&5 20619 $as_echo "$CHECK_TOOLSDIR_MAKE" >&6; } 20620 else 20621 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 20622 $as_echo "no" >&6; } 20623 fi 20624 20625 20626 test -n "$CHECK_TOOLSDIR_MAKE" && break 20627 done 20628 20629 20630 MAKE_CANDIDATE=""$CHECK_TOOLSDIR_MAKE"" 20631 DESCRIPTION="make in tools-dir" 20632 20633 # On Cygwin, we require a newer version of make than on other platforms 20634 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 20635 MAKE_VERSION_EXPR="-e 4\." 20636 MAKE_REQUIRED_VERSION="4.0" 20637 else 20638 MAKE_VERSION_EXPR="-e 3\.8[12] -e 4\." 20639 MAKE_REQUIRED_VERSION="3.81" 20640 fi 20641 20642 if test "x$MAKE_CANDIDATE" != x; then 20643 { $as_echo "$as_me:${as_lineno-$LINENO}: Testing potential make at $MAKE_CANDIDATE, found using $DESCRIPTION" >&5 20644 $as_echo "$as_me: Testing potential make at $MAKE_CANDIDATE, found using $DESCRIPTION" >&6;} 20645 MAKE_VERSION_STRING=`$MAKE_CANDIDATE --version | $HEAD -n 1` 20646 IS_GNU_MAKE=`$ECHO $MAKE_VERSION_STRING | $GREP 'GNU Make'` 20647 if test "x$IS_GNU_MAKE" = x; then 20648 { $as_echo "$as_me:${as_lineno-$LINENO}: Found potential make at $MAKE_CANDIDATE, however, this is not GNU Make. Ignoring." >&5 20649 $as_echo "$as_me: Found potential make at $MAKE_CANDIDATE, however, this is not GNU Make. Ignoring." >&6;} 20650 else 20651 IS_MODERN_MAKE=`$ECHO $MAKE_VERSION_STRING | $GREP $MAKE_VERSION_EXPR` 20652 if test "x$IS_MODERN_MAKE" = x; then 20653 { $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 20654 $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;} 20655 else 20656 if test "x$OPENJDK_BUILD_OS" = "xwindows"; then 20657 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 20658 MAKE_EXPECTED_ENV='cygwin' 20659 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 20660 MAKE_EXPECTED_ENV='msys' 20661 else 20662 as_fn_error $? "Unknown Windows environment" "$LINENO" 5 20663 fi 20664 MAKE_BUILT_FOR=`$MAKE_CANDIDATE --version | $GREP -i 'built for'` 20665 IS_MAKE_CORRECT_ENV=`$ECHO $MAKE_BUILT_FOR | $GREP $MAKE_EXPECTED_ENV` 20666 else 20667 # Not relevant for non-Windows 20668 IS_MAKE_CORRECT_ENV=true 20669 fi 20670 if test "x$IS_MAKE_CORRECT_ENV" = x; then 20671 { $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 20672 $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;} 20673 else 20674 FOUND_MAKE=$MAKE_CANDIDATE 20675 20676 # Only process if variable expands to non-empty 20677 20678 if test "x$FOUND_MAKE" != x; then 20679 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 20680 20681 # First separate the path from the arguments. This will split at the first 20682 # space. 20683 complete="$FOUND_MAKE" 20684 path="${complete%% *}" 20685 tmp="$complete EOL" 20686 arguments="${tmp#* }" 20687 20688 # Input might be given as Windows format, start by converting to 20689 # unix format. 20690 new_path=`$CYGPATH -u "$path"` 20691 20692 # Now try to locate executable using which 20693 new_path=`$WHICH "$new_path" 2> /dev/null` 20694 # bat and cmd files are not always considered executable in cygwin causing which 20695 # to not find them 20696 if test "x$new_path" = x \ 20697 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 20698 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 20699 new_path=`$CYGPATH -u "$path"` 20700 fi 20701 if test "x$new_path" = x; then 20702 # Oops. Which didn't find the executable. 20703 # The splitting of arguments from the executable at a space might have been incorrect, 20704 # since paths with space are more likely in Windows. Give it another try with the whole 20705 # argument. 20706 path="$complete" 20707 arguments="EOL" 20708 new_path=`$CYGPATH -u "$path"` 20709 new_path=`$WHICH "$new_path" 2> /dev/null` 20710 # bat and cmd files are not always considered executable in cygwin causing which 20711 # to not find them 20712 if test "x$new_path" = x \ 20713 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 20714 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 20715 new_path=`$CYGPATH -u "$path"` 20716 fi 20717 if test "x$new_path" = x; then 20718 # It's still not found. Now this is an unrecoverable error. 20719 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of FOUND_MAKE, which resolves as \"$complete\", is not found." >&5 20720 $as_echo "$as_me: The path of FOUND_MAKE, which resolves as \"$complete\", is not found." >&6;} 20721 has_space=`$ECHO "$complete" | $GREP " "` 20722 if test "x$has_space" != x; then 20723 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 20724 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 20725 fi 20726 as_fn_error $? "Cannot locate the the path of FOUND_MAKE" "$LINENO" 5 20727 fi 20728 fi 20729 20730 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 20731 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 20732 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 20733 # "foo.exe" is OK but "foo" is an error. 20734 # 20735 # This test is therefore slightly more accurate than "test -f" to check for file presence. 20736 # It is also a way to make sure we got the proper file name for the real test later on. 20737 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 20738 if test "x$test_shortpath" = x; then 20739 # Short path failed, file does not exist as specified. 20740 # Try adding .exe or .cmd 20741 if test -f "${new_path}.exe"; then 20742 input_to_shortpath="${new_path}.exe" 20743 elif test -f "${new_path}.cmd"; then 20744 input_to_shortpath="${new_path}.cmd" 20745 else 20746 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of FOUND_MAKE, which resolves as \"$new_path\", is invalid." >&5 20747 $as_echo "$as_me: The path of FOUND_MAKE, which resolves as \"$new_path\", is invalid." >&6;} 20748 { $as_echo "$as_me:${as_lineno-$LINENO}: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&5 20749 $as_echo "$as_me: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&6;} 20750 as_fn_error $? "Cannot locate the the path of FOUND_MAKE" "$LINENO" 5 20751 fi 20752 else 20753 input_to_shortpath="$new_path" 20754 fi 20755 20756 # Call helper function which possibly converts this using DOS-style short mode. 20757 # If so, the updated path is stored in $new_path. 20758 new_path="$input_to_shortpath" 20759 20760 input_path="$input_to_shortpath" 20761 # Check if we need to convert this using DOS-style short mode. If the path 20762 # contains just simple characters, use it. Otherwise (spaces, weird characters), 20763 # take no chances and rewrite it. 20764 # Note: m4 eats our [], so we need to use [ and ] instead. 20765 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 20766 if test "x$has_forbidden_chars" != x; then 20767 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 20768 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 20769 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 20770 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 20771 # Going to short mode and back again did indeed matter. Since short mode is 20772 # case insensitive, let's make it lowercase to improve readability. 20773 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 20774 # Now convert it back to Unix-style (cygpath) 20775 input_path=`$CYGPATH -u "$shortmode_path"` 20776 new_path="$input_path" 20777 fi 20778 fi 20779 20780 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 20781 if test "x$test_cygdrive_prefix" = x; then 20782 # As a simple fix, exclude /usr/bin since it's not a real path. 20783 if test "x`$ECHO $input_to_shortpath | $GREP ^/usr/bin/`" = x; then 20784 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 20785 # a path prefixed by /cygdrive for fixpath to work. 20786 new_path="$CYGWIN_ROOT_PATH$input_path" 20787 fi 20788 fi 20789 20790 # remove trailing .exe if any 20791 new_path="${new_path/%.exe/}" 20792 20793 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 20794 20795 # First separate the path from the arguments. This will split at the first 20796 # space. 20797 complete="$FOUND_MAKE" 20798 path="${complete%% *}" 20799 tmp="$complete EOL" 20800 arguments="${tmp#* }" 20801 20802 # Input might be given as Windows format, start by converting to 20803 # unix format. 20804 new_path="$path" 20805 20806 windows_path="$new_path" 20807 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 20808 unix_path=`$CYGPATH -u "$windows_path"` 20809 new_path="$unix_path" 20810 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 20811 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 20812 new_path="$unix_path" 20813 fi 20814 20815 20816 # Now try to locate executable using which 20817 new_path=`$WHICH "$new_path" 2> /dev/null` 20818 20819 if test "x$new_path" = x; then 20820 # Oops. Which didn't find the executable. 20821 # The splitting of arguments from the executable at a space might have been incorrect, 20822 # since paths with space are more likely in Windows. Give it another try with the whole 20823 # argument. 20824 path="$complete" 20825 arguments="EOL" 20826 new_path="$path" 20827 20828 windows_path="$new_path" 20829 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 20830 unix_path=`$CYGPATH -u "$windows_path"` 20831 new_path="$unix_path" 20832 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 20833 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 20834 new_path="$unix_path" 20835 fi 20836 20837 20838 new_path=`$WHICH "$new_path" 2> /dev/null` 20839 # bat and cmd files are not always considered executable in MSYS causing which 20840 # to not find them 20841 if test "x$new_path" = x \ 20842 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 20843 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 20844 new_path="$path" 20845 20846 windows_path="$new_path" 20847 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 20848 unix_path=`$CYGPATH -u "$windows_path"` 20849 new_path="$unix_path" 20850 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 20851 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 20852 new_path="$unix_path" 20853 fi 20854 20855 fi 20856 20857 if test "x$new_path" = x; then 20858 # It's still not found. Now this is an unrecoverable error. 20859 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of FOUND_MAKE, which resolves as \"$complete\", is not found." >&5 20860 $as_echo "$as_me: The path of FOUND_MAKE, which resolves as \"$complete\", is not found." >&6;} 20861 has_space=`$ECHO "$complete" | $GREP " "` 20862 if test "x$has_space" != x; then 20863 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 20864 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 20865 fi 20866 as_fn_error $? "Cannot locate the the path of FOUND_MAKE" "$LINENO" 5 20867 fi 20868 fi 20869 20870 # Now new_path has a complete unix path to the binary 20871 if test "x`$ECHO $new_path | $GREP ^/bin/`" != x; then 20872 # Keep paths in /bin as-is, but remove trailing .exe if any 20873 new_path="${new_path/%.exe/}" 20874 # Do not save /bin paths to all_fixpath_prefixes! 20875 else 20876 # Not in mixed or Windows style, start by that. 20877 new_path=`cmd //c echo $new_path` 20878 20879 input_path="$new_path" 20880 # Check if we need to convert this using DOS-style short mode. If the path 20881 # contains just simple characters, use it. Otherwise (spaces, weird characters), 20882 # take no chances and rewrite it. 20883 # Note: m4 eats our [], so we need to use [ and ] instead. 20884 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 20885 if test "x$has_forbidden_chars" != x; then 20886 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 20887 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 20888 fi 20889 20890 # Output is in $new_path 20891 20892 windows_path="$new_path" 20893 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 20894 unix_path=`$CYGPATH -u "$windows_path"` 20895 new_path="$unix_path" 20896 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 20897 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 20898 new_path="$unix_path" 20899 fi 20900 20901 # remove trailing .exe if any 20902 new_path="${new_path/%.exe/}" 20903 20904 # Save the first 10 bytes of this path to the storage, so fixpath can work. 20905 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 20906 fi 20907 20908 else 20909 # We're on a unix platform. Hooray! :) 20910 # First separate the path from the arguments. This will split at the first 20911 # space. 20912 complete="$FOUND_MAKE" 20913 path="${complete%% *}" 20914 tmp="$complete EOL" 20915 arguments="${tmp#* }" 20916 20917 # Cannot rely on the command "which" here since it doesn't always work. 20918 is_absolute_path=`$ECHO "$path" | $GREP ^/` 20919 if test -z "$is_absolute_path"; then 20920 # Path to executable is not absolute. Find it. 20921 IFS_save="$IFS" 20922 IFS=: 20923 for p in $PATH; do 20924 if test -f "$p/$path" && test -x "$p/$path"; then 20925 new_path="$p/$path" 20926 break 20927 fi 20928 done 20929 IFS="$IFS_save" 20930 else 20931 # This is an absolute path, we can use it without further modifications. 20932 new_path="$path" 20933 fi 20934 20935 if test "x$new_path" = x; then 20936 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of FOUND_MAKE, which resolves as \"$complete\", is not found." >&5 20937 $as_echo "$as_me: The path of FOUND_MAKE, which resolves as \"$complete\", is not found." >&6;} 20938 has_space=`$ECHO "$complete" | $GREP " "` 20939 if test "x$has_space" != x; then 20940 { $as_echo "$as_me:${as_lineno-$LINENO}: This might be caused by spaces in the path, which is not allowed." >&5 20941 $as_echo "$as_me: This might be caused by spaces in the path, which is not allowed." >&6;} 20942 fi 20943 as_fn_error $? "Cannot locate the the path of FOUND_MAKE" "$LINENO" 5 20944 fi 20945 fi 20946 20947 # Now join together the path and the arguments once again 20948 if test "x$arguments" != xEOL; then 20949 new_complete="$new_path ${arguments% *}" 20950 else 20951 new_complete="$new_path" 20952 fi 20953 20954 if test "x$complete" != "x$new_complete"; then 20955 FOUND_MAKE="$new_complete" 20956 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting FOUND_MAKE to \"$new_complete\"" >&5 20957 $as_echo "$as_me: Rewriting FOUND_MAKE to \"$new_complete\"" >&6;} 20958 fi 20959 fi 20960 20961 fi 20962 fi 20963 fi 20964 fi 20965 20966 fi 20967 PATH=$OLD_PATH 20968 fi 20969 fi 20970 20971 if test "x$FOUND_MAKE" = x; then 20972 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 20973 fi 20974 20975 else 20976 # If it succeeded, then it was overridden by the user. We will use it 20977 # for the tool. 20978 20979 # First remove it from the list of overridden variables, so we can test 20980 # for unknown variables in the end. 20981 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 20982 20983 # Check if we try to supply an empty value 20984 if test "x$MAKE" = x; then 20985 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool MAKE= (no value)" >&5 20986 $as_echo "$as_me: Setting user supplied tool MAKE= (no value)" >&6;} 20987 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for MAKE" >&5 20988 $as_echo_n "checking for MAKE... " >&6; } 20989 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 20990 $as_echo "disabled" >&6; } 20991 else 20992 # Check if the provided tool contains a complete path. 20993 tool_specified="$MAKE" 20994 tool_basename="${tool_specified##*/}" 20995 if test "x$tool_basename" = "x$tool_specified"; then 20996 # A command without a complete path is provided, search $PATH. 20997 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool MAKE=$tool_basename" >&5 20998 $as_echo "$as_me: Will search for user supplied tool MAKE=$tool_basename" >&6;} 20999 # Extract the first word of "$tool_basename", so it can be a program name with args. 21000 set dummy $tool_basename; ac_word=$2 21001 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 21002 $as_echo_n "checking for $ac_word... " >&6; } 21003 if ${ac_cv_path_MAKE+:} false; then : 21004 $as_echo_n "(cached) " >&6 21005 else 21006 case $MAKE in 21007 [\\/]* | ?:[\\/]*) 21008 ac_cv_path_MAKE="$MAKE" # Let the user override the test with a path. 21009 ;; 21010 *) 21011 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 21012 for as_dir in $PATH 21013 do 21014 IFS=$as_save_IFS 21015 test -z "$as_dir" && as_dir=. 21016 for ac_exec_ext in '' $ac_executable_extensions; do 21017 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 21018 ac_cv_path_MAKE="$as_dir/$ac_word$ac_exec_ext" 21019 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 21020 break 2 21021 fi 21022 done 21023 done 21024 IFS=$as_save_IFS 21025 21026 ;; 21027 esac 21028 fi 21029 MAKE=$ac_cv_path_MAKE 21030 if test -n "$MAKE"; then 21031 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MAKE" >&5 21032 $as_echo "$MAKE" >&6; } 21033 else 21034 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 21035 $as_echo "no" >&6; } 21036 fi 21037 21038 21039 if test "x$MAKE" = x; then 21040 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 21041 fi 21042 else 21043 # Otherwise we believe it is a complete path. Use it as it is. 21044 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool MAKE=$tool_specified" >&5 21045 $as_echo "$as_me: Will use user supplied tool MAKE=$tool_specified" >&6;} 21046 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for MAKE" >&5 21047 $as_echo_n "checking for MAKE... " >&6; } 21048 if test ! -x "$tool_specified"; then 21049 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 21050 $as_echo "not found" >&6; } 21051 as_fn_error $? "User supplied tool MAKE=$tool_specified does not exist or is not executable" "$LINENO" 5 21052 fi 21053 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 21054 $as_echo "$tool_specified" >&6; } 21055 fi 21056 fi 21057 fi 21058 21059 # If MAKE was set by user, verify the version 21060 21061 MAKE_CANDIDATE=""$MAKE"" 21062 DESCRIPTION="user supplied MAKE=$MAKE" 21063 21064 # On Cygwin, we require a newer version of make than on other platforms 21065 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 21066 MAKE_VERSION_EXPR="-e 4\." 21067 MAKE_REQUIRED_VERSION="4.0" 21068 else 21069 MAKE_VERSION_EXPR="-e 3\.8[12] -e 4\." 21070 MAKE_REQUIRED_VERSION="3.81" 21071 fi 21072 21073 if test "x$MAKE_CANDIDATE" != x; then 21074 { $as_echo "$as_me:${as_lineno-$LINENO}: Testing potential make at $MAKE_CANDIDATE, found using $DESCRIPTION" >&5 21075 $as_echo "$as_me: Testing potential make at $MAKE_CANDIDATE, found using $DESCRIPTION" >&6;} 21076 MAKE_VERSION_STRING=`$MAKE_CANDIDATE --version | $HEAD -n 1` 21077 IS_GNU_MAKE=`$ECHO $MAKE_VERSION_STRING | $GREP 'GNU Make'` 21078 if test "x$IS_GNU_MAKE" = x; then 21079 { $as_echo "$as_me:${as_lineno-$LINENO}: Found potential make at $MAKE_CANDIDATE, however, this is not GNU Make. Ignoring." >&5 21080 $as_echo "$as_me: Found potential make at $MAKE_CANDIDATE, however, this is not GNU Make. Ignoring." >&6;} 21081 else 21082 IS_MODERN_MAKE=`$ECHO $MAKE_VERSION_STRING | $GREP $MAKE_VERSION_EXPR` 21083 if test "x$IS_MODERN_MAKE" = x; then 21084 { $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 21085 $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;} 21086 else 21087 if test "x$OPENJDK_BUILD_OS" = "xwindows"; then 21088 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 21089 MAKE_EXPECTED_ENV='cygwin' 21090 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 21091 MAKE_EXPECTED_ENV='msys' 21092 else 21093 as_fn_error $? "Unknown Windows environment" "$LINENO" 5 21094 fi 21095 MAKE_BUILT_FOR=`$MAKE_CANDIDATE --version | $GREP -i 'built for'` 21096 IS_MAKE_CORRECT_ENV=`$ECHO $MAKE_BUILT_FOR | $GREP $MAKE_EXPECTED_ENV` 21097 else 21098 # Not relevant for non-Windows 21099 IS_MAKE_CORRECT_ENV=true 21100 fi 21101 if test "x$IS_MAKE_CORRECT_ENV" = x; then 21102 { $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 21103 $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;} 21104 else 21105 FOUND_MAKE=$MAKE_CANDIDATE 21106 21107 # Only process if variable expands to non-empty 21108 21109 if test "x$FOUND_MAKE" != x; then 21110 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 21111 21112 # First separate the path from the arguments. This will split at the first 21113 # space. 21114 complete="$FOUND_MAKE" 21115 path="${complete%% *}" 21116 tmp="$complete EOL" 21117 arguments="${tmp#* }" 21118 21119 # Input might be given as Windows format, start by converting to 21120 # unix format. 21121 new_path=`$CYGPATH -u "$path"` 21122 21123 # Now try to locate executable using which 21124 new_path=`$WHICH "$new_path" 2> /dev/null` 21125 # bat and cmd files are not always considered executable in cygwin causing which 21126 # to not find them 21127 if test "x$new_path" = x \ 21128 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 21129 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 21130 new_path=`$CYGPATH -u "$path"` 21131 fi 21132 if test "x$new_path" = x; then 21133 # Oops. Which didn't find the executable. 21134 # The splitting of arguments from the executable at a space might have been incorrect, 21135 # since paths with space are more likely in Windows. Give it another try with the whole 21136 # argument. 21137 path="$complete" 21138 arguments="EOL" 21139 new_path=`$CYGPATH -u "$path"` 21140 new_path=`$WHICH "$new_path" 2> /dev/null` 21141 # bat and cmd files are not always considered executable in cygwin causing which 21142 # to not find them 21143 if test "x$new_path" = x \ 21144 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 21145 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 21146 new_path=`$CYGPATH -u "$path"` 21147 fi 21148 if test "x$new_path" = x; then 21149 # It's still not found. Now this is an unrecoverable error. 21150 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of FOUND_MAKE, which resolves as \"$complete\", is not found." >&5 21151 $as_echo "$as_me: The path of FOUND_MAKE, which resolves as \"$complete\", is not found." >&6;} 21152 has_space=`$ECHO "$complete" | $GREP " "` 21153 if test "x$has_space" != x; then 21154 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 21155 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 21156 fi 21157 as_fn_error $? "Cannot locate the the path of FOUND_MAKE" "$LINENO" 5 21158 fi 21159 fi 21160 21161 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 21162 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 21163 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 21164 # "foo.exe" is OK but "foo" is an error. 21165 # 21166 # This test is therefore slightly more accurate than "test -f" to check for file presence. 21167 # It is also a way to make sure we got the proper file name for the real test later on. 21168 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 21169 if test "x$test_shortpath" = x; then 21170 # Short path failed, file does not exist as specified. 21171 # Try adding .exe or .cmd 21172 if test -f "${new_path}.exe"; then 21173 input_to_shortpath="${new_path}.exe" 21174 elif test -f "${new_path}.cmd"; then 21175 input_to_shortpath="${new_path}.cmd" 21176 else 21177 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of FOUND_MAKE, which resolves as \"$new_path\", is invalid." >&5 21178 $as_echo "$as_me: The path of FOUND_MAKE, which resolves as \"$new_path\", is invalid." >&6;} 21179 { $as_echo "$as_me:${as_lineno-$LINENO}: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&5 21180 $as_echo "$as_me: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&6;} 21181 as_fn_error $? "Cannot locate the the path of FOUND_MAKE" "$LINENO" 5 21182 fi 21183 else 21184 input_to_shortpath="$new_path" 21185 fi 21186 21187 # Call helper function which possibly converts this using DOS-style short mode. 21188 # If so, the updated path is stored in $new_path. 21189 new_path="$input_to_shortpath" 21190 21191 input_path="$input_to_shortpath" 21192 # Check if we need to convert this using DOS-style short mode. If the path 21193 # contains just simple characters, use it. Otherwise (spaces, weird characters), 21194 # take no chances and rewrite it. 21195 # Note: m4 eats our [], so we need to use [ and ] instead. 21196 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 21197 if test "x$has_forbidden_chars" != x; then 21198 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 21199 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 21200 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 21201 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 21202 # Going to short mode and back again did indeed matter. Since short mode is 21203 # case insensitive, let's make it lowercase to improve readability. 21204 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 21205 # Now convert it back to Unix-style (cygpath) 21206 input_path=`$CYGPATH -u "$shortmode_path"` 21207 new_path="$input_path" 21208 fi 21209 fi 21210 21211 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 21212 if test "x$test_cygdrive_prefix" = x; then 21213 # As a simple fix, exclude /usr/bin since it's not a real path. 21214 if test "x`$ECHO $input_to_shortpath | $GREP ^/usr/bin/`" = x; then 21215 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 21216 # a path prefixed by /cygdrive for fixpath to work. 21217 new_path="$CYGWIN_ROOT_PATH$input_path" 21218 fi 21219 fi 21220 21221 # remove trailing .exe if any 21222 new_path="${new_path/%.exe/}" 21223 21224 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 21225 21226 # First separate the path from the arguments. This will split at the first 21227 # space. 21228 complete="$FOUND_MAKE" 21229 path="${complete%% *}" 21230 tmp="$complete EOL" 21231 arguments="${tmp#* }" 21232 21233 # Input might be given as Windows format, start by converting to 21234 # unix format. 21235 new_path="$path" 21236 21237 windows_path="$new_path" 21238 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 21239 unix_path=`$CYGPATH -u "$windows_path"` 21240 new_path="$unix_path" 21241 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 21242 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 21243 new_path="$unix_path" 21244 fi 21245 21246 21247 # Now try to locate executable using which 21248 new_path=`$WHICH "$new_path" 2> /dev/null` 21249 21250 if test "x$new_path" = x; then 21251 # Oops. Which didn't find the executable. 21252 # The splitting of arguments from the executable at a space might have been incorrect, 21253 # since paths with space are more likely in Windows. Give it another try with the whole 21254 # argument. 21255 path="$complete" 21256 arguments="EOL" 21257 new_path="$path" 21258 21259 windows_path="$new_path" 21260 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 21261 unix_path=`$CYGPATH -u "$windows_path"` 21262 new_path="$unix_path" 21263 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 21264 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 21265 new_path="$unix_path" 21266 fi 21267 21268 21269 new_path=`$WHICH "$new_path" 2> /dev/null` 21270 # bat and cmd files are not always considered executable in MSYS causing which 21271 # to not find them 21272 if test "x$new_path" = x \ 21273 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 21274 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 21275 new_path="$path" 21276 21277 windows_path="$new_path" 21278 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 21279 unix_path=`$CYGPATH -u "$windows_path"` 21280 new_path="$unix_path" 21281 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 21282 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 21283 new_path="$unix_path" 21284 fi 21285 21286 fi 21287 21288 if test "x$new_path" = x; then 21289 # It's still not found. Now this is an unrecoverable error. 21290 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of FOUND_MAKE, which resolves as \"$complete\", is not found." >&5 21291 $as_echo "$as_me: The path of FOUND_MAKE, which resolves as \"$complete\", is not found." >&6;} 21292 has_space=`$ECHO "$complete" | $GREP " "` 21293 if test "x$has_space" != x; then 21294 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 21295 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 21296 fi 21297 as_fn_error $? "Cannot locate the the path of FOUND_MAKE" "$LINENO" 5 21298 fi 21299 fi 21300 21301 # Now new_path has a complete unix path to the binary 21302 if test "x`$ECHO $new_path | $GREP ^/bin/`" != x; then 21303 # Keep paths in /bin as-is, but remove trailing .exe if any 21304 new_path="${new_path/%.exe/}" 21305 # Do not save /bin paths to all_fixpath_prefixes! 21306 else 21307 # Not in mixed or Windows style, start by that. 21308 new_path=`cmd //c echo $new_path` 21309 21310 input_path="$new_path" 21311 # Check if we need to convert this using DOS-style short mode. If the path 21312 # contains just simple characters, use it. Otherwise (spaces, weird characters), 21313 # take no chances and rewrite it. 21314 # Note: m4 eats our [], so we need to use [ and ] instead. 21315 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 21316 if test "x$has_forbidden_chars" != x; then 21317 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 21318 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 21319 fi 21320 21321 # Output is in $new_path 21322 21323 windows_path="$new_path" 21324 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 21325 unix_path=`$CYGPATH -u "$windows_path"` 21326 new_path="$unix_path" 21327 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 21328 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 21329 new_path="$unix_path" 21330 fi 21331 21332 # remove trailing .exe if any 21333 new_path="${new_path/%.exe/}" 21334 21335 # Save the first 10 bytes of this path to the storage, so fixpath can work. 21336 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 21337 fi 21338 21339 else 21340 # We're on a unix platform. Hooray! :) 21341 # First separate the path from the arguments. This will split at the first 21342 # space. 21343 complete="$FOUND_MAKE" 21344 path="${complete%% *}" 21345 tmp="$complete EOL" 21346 arguments="${tmp#* }" 21347 21348 # Cannot rely on the command "which" here since it doesn't always work. 21349 is_absolute_path=`$ECHO "$path" | $GREP ^/` 21350 if test -z "$is_absolute_path"; then 21351 # Path to executable is not absolute. Find it. 21352 IFS_save="$IFS" 21353 IFS=: 21354 for p in $PATH; do 21355 if test -f "$p/$path" && test -x "$p/$path"; then 21356 new_path="$p/$path" 21357 break 21358 fi 21359 done 21360 IFS="$IFS_save" 21361 else 21362 # This is an absolute path, we can use it without further modifications. 21363 new_path="$path" 21364 fi 21365 21366 if test "x$new_path" = x; then 21367 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of FOUND_MAKE, which resolves as \"$complete\", is not found." >&5 21368 $as_echo "$as_me: The path of FOUND_MAKE, which resolves as \"$complete\", is not found." >&6;} 21369 has_space=`$ECHO "$complete" | $GREP " "` 21370 if test "x$has_space" != x; then 21371 { $as_echo "$as_me:${as_lineno-$LINENO}: This might be caused by spaces in the path, which is not allowed." >&5 21372 $as_echo "$as_me: This might be caused by spaces in the path, which is not allowed." >&6;} 21373 fi 21374 as_fn_error $? "Cannot locate the the path of FOUND_MAKE" "$LINENO" 5 21375 fi 21376 fi 21377 21378 # Now join together the path and the arguments once again 21379 if test "x$arguments" != xEOL; then 21380 new_complete="$new_path ${arguments% *}" 21381 else 21382 new_complete="$new_path" 21383 fi 21384 21385 if test "x$complete" != "x$new_complete"; then 21386 FOUND_MAKE="$new_complete" 21387 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting FOUND_MAKE to \"$new_complete\"" >&5 21388 $as_echo "$as_me: Rewriting FOUND_MAKE to \"$new_complete\"" >&6;} 21389 fi 21390 fi 21391 21392 fi 21393 fi 21394 fi 21395 fi 21396 21397 if test "x$FOUND_MAKE" = x; then 21398 as_fn_error $? "The specified make (by MAKE=$MAKE) is not GNU make $MAKE_REQUIRED_VERSION or newer." "$LINENO" 5 21399 fi 21400 21401 fi 21402 21403 21404 MAKE=$FOUND_MAKE 21405 21406 { $as_echo "$as_me:${as_lineno-$LINENO}: Using GNU make at $FOUND_MAKE (version: $MAKE_VERSION_STRING)" >&5 21407 $as_echo "$as_me: Using GNU make at $FOUND_MAKE (version: $MAKE_VERSION_STRING)" >&6;} 21408 21409 21410 # Check if make supports the output sync option and if so, setup using it. 21411 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if make --output-sync is supported" >&5 21412 $as_echo_n "checking if make --output-sync is supported... " >&6; } 21413 if $MAKE --version -O > /dev/null 2>&1; then 21414 OUTPUT_SYNC_SUPPORTED=true 21415 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 21416 $as_echo "yes" >&6; } 21417 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for output-sync value" >&5 21418 $as_echo_n "checking for output-sync value... " >&6; } 21419 21420 # Check whether --with-output-sync was given. 21421 if test "${with_output_sync+set}" = set; then : 21422 withval=$with_output_sync; OUTPUT_SYNC=$with_output_sync 21423 fi 21424 21425 if test "x$OUTPUT_SYNC" = "x"; then 21426 OUTPUT_SYNC=none 21427 fi 21428 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $OUTPUT_SYNC" >&5 21429 $as_echo "$OUTPUT_SYNC" >&6; } 21430 if ! $MAKE --version -O$OUTPUT_SYNC > /dev/null 2>&1; then 21431 as_fn_error $? "Make did not the support the value $OUTPUT_SYNC as output sync type." "$LINENO" 5 21432 fi 21433 else 21434 OUTPUT_SYNC_SUPPORTED=false 21435 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 21436 $as_echo "no" >&6; } 21437 fi 21438 21439 21440 21441 21442 21443 21444 # Test if find supports -delete 21445 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if find supports -delete" >&5 21446 $as_echo_n "checking if find supports -delete... " >&6; } 21447 FIND_DELETE="-delete" 21448 21449 DELETEDIR=`$MKTEMP -d tmp.XXXXXXXXXX` || (echo Could not create temporary directory!; exit $?) 21450 21451 echo Hejsan > $DELETEDIR/TestIfFindSupportsDelete 21452 21453 TEST_DELETE=`$FIND "$DELETEDIR" -name TestIfFindSupportsDelete $FIND_DELETE 2>&1` 21454 if test -f $DELETEDIR/TestIfFindSupportsDelete; then 21455 # No, it does not. 21456 $RM $DELETEDIR/TestIfFindSupportsDelete 21457 if test "x$OPENJDK_TARGET_OS" = "xaix"; then 21458 # AIX 'find' is buggy if called with '-exec {} \+' and an empty file list 21459 FIND_DELETE="-print | $XARGS $RM" 21460 else 21461 FIND_DELETE="-exec $RM \{\} \+" 21462 fi 21463 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 21464 $as_echo "no" >&6; } 21465 else 21466 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 21467 $as_echo "yes" >&6; } 21468 fi 21469 $RMDIR $DELETEDIR 21470 21471 21472 21473 # Test which kind of tar was found 21474 if test "x$($TAR --version | $GREP "GNU tar")" != "x"; then 21475 TAR_TYPE="gnu" 21476 elif test "x$($TAR --version | $GREP "bsdtar")" != "x"; then 21477 TAR_TYPE="bsd" 21478 elif test "x$($TAR -v | $GREP "bsdtar")" != "x"; then 21479 TAR_TYPE="bsd" 21480 elif test "x$OPENJDK_BUILD_OS" = "xsolaris"; then 21481 TAR_TYPE="solaris" 21482 fi 21483 { $as_echo "$as_me:${as_lineno-$LINENO}: checking what type of tar was found" >&5 21484 $as_echo_n "checking what type of tar was found... " >&6; } 21485 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $TAR_TYPE" >&5 21486 $as_echo "$TAR_TYPE" >&6; } 21487 21488 TAR_CREATE_FILE_PARAM="" 21489 21490 if test "x$TAR_TYPE" = "xgnu"; then 21491 TAR_INCLUDE_PARAM="T" 21492 TAR_SUPPORTS_TRANSFORM="true" 21493 if test "x$OPENJDK_TARGET_OS" = "xsolaris"; then 21494 # When using gnu tar for Solaris targets, need to use compatibility mode 21495 TAR_CREATE_EXTRA_PARAM="--format=ustar" 21496 fi 21497 else 21498 TAR_INCLUDE_PARAM="I" 21499 TAR_SUPPORTS_TRANSFORM="false" 21500 fi 21501 21502 21503 21504 21505 21506 21507 # Test that grep supports -Fx with a list of pattern which includes null pattern. 21508 # This is a problem for the grep resident on AIX. 21509 { $as_echo "$as_me:${as_lineno-$LINENO}: checking that grep ($GREP) -Fx handles empty lines in the pattern list correctly" >&5 21510 $as_echo_n "checking that grep ($GREP) -Fx handles empty lines in the pattern list correctly... " >&6; } 21511 # Multiple subsequent spaces.. 21512 STACK_SPACES='aaa bbb ccc' 21513 # ..converted to subsequent newlines, causes STACK_LIST to be a list with some empty 21514 # patterns in it. 21515 STACK_LIST=${STACK_SPACES// /$'\n'} 21516 NEEDLE_SPACES='ccc bbb aaa' 21517 NEEDLE_LIST=${NEEDLE_SPACES// /$'\n'} 21518 RESULT="$($GREP -Fvx "$STACK_LIST" <<< "$NEEDLE_LIST")" 21519 if test "x$RESULT" == "x"; then 21520 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 21521 $as_echo "yes" >&6; } 21522 else 21523 if test "x$OPENJDK_TARGET_OS" = "xaix"; then 21524 ADDINFO="Please make sure you use GNU grep, usually found at /opt/freeware/bin." 21525 fi 21526 as_fn_error $? "grep does not handle -Fx correctly. ${ADDINFO}" "$LINENO" 5 21527 fi 21528 21529 21530 # These tools might not be installed by default, 21531 # need hint on how to install them. 21532 21533 21534 21535 # Publish this variable in the help. 21536 21537 21538 if [ -z "${UNZIP+x}" ]; then 21539 # The variable is not set by user, try to locate tool using the code snippet 21540 for ac_prog in unzip 21541 do 21542 # Extract the first word of "$ac_prog", so it can be a program name with args. 21543 set dummy $ac_prog; ac_word=$2 21544 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 21545 $as_echo_n "checking for $ac_word... " >&6; } 21546 if ${ac_cv_path_UNZIP+:} false; then : 21547 $as_echo_n "(cached) " >&6 21548 else 21549 case $UNZIP in 21550 [\\/]* | ?:[\\/]*) 21551 ac_cv_path_UNZIP="$UNZIP" # Let the user override the test with a path. 21552 ;; 21553 *) 21554 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 21555 for as_dir in $PATH 21556 do 21557 IFS=$as_save_IFS 21558 test -z "$as_dir" && as_dir=. 21559 for ac_exec_ext in '' $ac_executable_extensions; do 21560 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 21561 ac_cv_path_UNZIP="$as_dir/$ac_word$ac_exec_ext" 21562 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 21563 break 2 21564 fi 21565 done 21566 done 21567 IFS=$as_save_IFS 21568 21569 ;; 21570 esac 21571 fi 21572 UNZIP=$ac_cv_path_UNZIP 21573 if test -n "$UNZIP"; then 21574 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $UNZIP" >&5 21575 $as_echo "$UNZIP" >&6; } 21576 else 21577 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 21578 $as_echo "no" >&6; } 21579 fi 21580 21581 21582 test -n "$UNZIP" && break 21583 done 21584 21585 else 21586 # The variable is set, but is it from the command line or the environment? 21587 21588 # Try to remove the string !UNZIP! from our list. 21589 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!UNZIP!/} 21590 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 21591 # If it failed, the variable was not from the command line. Ignore it, 21592 # but warn the user (except for BASH, which is always set by the calling BASH). 21593 if test "xUNZIP" != xBASH; then 21594 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of UNZIP from the environment. Use command line variables instead." >&5 21595 $as_echo "$as_me: WARNING: Ignoring value of UNZIP from the environment. Use command line variables instead." >&2;} 21596 fi 21597 # Try to locate tool using the code snippet 21598 for ac_prog in unzip 21599 do 21600 # Extract the first word of "$ac_prog", so it can be a program name with args. 21601 set dummy $ac_prog; ac_word=$2 21602 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 21603 $as_echo_n "checking for $ac_word... " >&6; } 21604 if ${ac_cv_path_UNZIP+:} false; then : 21605 $as_echo_n "(cached) " >&6 21606 else 21607 case $UNZIP in 21608 [\\/]* | ?:[\\/]*) 21609 ac_cv_path_UNZIP="$UNZIP" # Let the user override the test with a path. 21610 ;; 21611 *) 21612 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 21613 for as_dir in $PATH 21614 do 21615 IFS=$as_save_IFS 21616 test -z "$as_dir" && as_dir=. 21617 for ac_exec_ext in '' $ac_executable_extensions; do 21618 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 21619 ac_cv_path_UNZIP="$as_dir/$ac_word$ac_exec_ext" 21620 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 21621 break 2 21622 fi 21623 done 21624 done 21625 IFS=$as_save_IFS 21626 21627 ;; 21628 esac 21629 fi 21630 UNZIP=$ac_cv_path_UNZIP 21631 if test -n "$UNZIP"; then 21632 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $UNZIP" >&5 21633 $as_echo "$UNZIP" >&6; } 21634 else 21635 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 21636 $as_echo "no" >&6; } 21637 fi 21638 21639 21640 test -n "$UNZIP" && break 21641 done 21642 21643 else 21644 # If it succeeded, then it was overridden by the user. We will use it 21645 # for the tool. 21646 21647 # First remove it from the list of overridden variables, so we can test 21648 # for unknown variables in the end. 21649 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 21650 21651 # Check if we try to supply an empty value 21652 if test "x$UNZIP" = x; then 21653 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool UNZIP= (no value)" >&5 21654 $as_echo "$as_me: Setting user supplied tool UNZIP= (no value)" >&6;} 21655 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for UNZIP" >&5 21656 $as_echo_n "checking for UNZIP... " >&6; } 21657 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 21658 $as_echo "disabled" >&6; } 21659 else 21660 # Check if the provided tool contains a complete path. 21661 tool_specified="$UNZIP" 21662 tool_basename="${tool_specified##*/}" 21663 if test "x$tool_basename" = "x$tool_specified"; then 21664 # A command without a complete path is provided, search $PATH. 21665 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool UNZIP=$tool_basename" >&5 21666 $as_echo "$as_me: Will search for user supplied tool UNZIP=$tool_basename" >&6;} 21667 # Extract the first word of "$tool_basename", so it can be a program name with args. 21668 set dummy $tool_basename; ac_word=$2 21669 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 21670 $as_echo_n "checking for $ac_word... " >&6; } 21671 if ${ac_cv_path_UNZIP+:} false; then : 21672 $as_echo_n "(cached) " >&6 21673 else 21674 case $UNZIP in 21675 [\\/]* | ?:[\\/]*) 21676 ac_cv_path_UNZIP="$UNZIP" # Let the user override the test with a path. 21677 ;; 21678 *) 21679 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 21680 for as_dir in $PATH 21681 do 21682 IFS=$as_save_IFS 21683 test -z "$as_dir" && as_dir=. 21684 for ac_exec_ext in '' $ac_executable_extensions; do 21685 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 21686 ac_cv_path_UNZIP="$as_dir/$ac_word$ac_exec_ext" 21687 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 21688 break 2 21689 fi 21690 done 21691 done 21692 IFS=$as_save_IFS 21693 21694 ;; 21695 esac 21696 fi 21697 UNZIP=$ac_cv_path_UNZIP 21698 if test -n "$UNZIP"; then 21699 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $UNZIP" >&5 21700 $as_echo "$UNZIP" >&6; } 21701 else 21702 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 21703 $as_echo "no" >&6; } 21704 fi 21705 21706 21707 if test "x$UNZIP" = x; then 21708 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 21709 fi 21710 else 21711 # Otherwise we believe it is a complete path. Use it as it is. 21712 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool UNZIP=$tool_specified" >&5 21713 $as_echo "$as_me: Will use user supplied tool UNZIP=$tool_specified" >&6;} 21714 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for UNZIP" >&5 21715 $as_echo_n "checking for UNZIP... " >&6; } 21716 if test ! -x "$tool_specified"; then 21717 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 21718 $as_echo "not found" >&6; } 21719 as_fn_error $? "User supplied tool UNZIP=$tool_specified does not exist or is not executable" "$LINENO" 5 21720 fi 21721 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 21722 $as_echo "$tool_specified" >&6; } 21723 fi 21724 fi 21725 fi 21726 21727 fi 21728 21729 21730 21731 if test "x$UNZIP" = x; then 21732 as_fn_error $? "Could not find required tool for UNZIP" "$LINENO" 5 21733 fi 21734 21735 21736 # Since zip uses "ZIP" as a environment variable for passing options, we need 21737 # to name our variable differently, hence ZIPEXE. 21738 21739 21740 21741 # Publish this variable in the help. 21742 21743 21744 if [ -z "${ZIPEXE+x}" ]; then 21745 # The variable is not set by user, try to locate tool using the code snippet 21746 for ac_prog in zip 21747 do 21748 # Extract the first word of "$ac_prog", so it can be a program name with args. 21749 set dummy $ac_prog; ac_word=$2 21750 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 21751 $as_echo_n "checking for $ac_word... " >&6; } 21752 if ${ac_cv_path_ZIPEXE+:} false; then : 21753 $as_echo_n "(cached) " >&6 21754 else 21755 case $ZIPEXE in 21756 [\\/]* | ?:[\\/]*) 21757 ac_cv_path_ZIPEXE="$ZIPEXE" # Let the user override the test with a path. 21758 ;; 21759 *) 21760 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 21761 for as_dir in $PATH 21762 do 21763 IFS=$as_save_IFS 21764 test -z "$as_dir" && as_dir=. 21765 for ac_exec_ext in '' $ac_executable_extensions; do 21766 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 21767 ac_cv_path_ZIPEXE="$as_dir/$ac_word$ac_exec_ext" 21768 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 21769 break 2 21770 fi 21771 done 21772 done 21773 IFS=$as_save_IFS 21774 21775 ;; 21776 esac 21777 fi 21778 ZIPEXE=$ac_cv_path_ZIPEXE 21779 if test -n "$ZIPEXE"; then 21780 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ZIPEXE" >&5 21781 $as_echo "$ZIPEXE" >&6; } 21782 else 21783 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 21784 $as_echo "no" >&6; } 21785 fi 21786 21787 21788 test -n "$ZIPEXE" && break 21789 done 21790 21791 else 21792 # The variable is set, but is it from the command line or the environment? 21793 21794 # Try to remove the string !ZIPEXE! from our list. 21795 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!ZIPEXE!/} 21796 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 21797 # If it failed, the variable was not from the command line. Ignore it, 21798 # but warn the user (except for BASH, which is always set by the calling BASH). 21799 if test "xZIPEXE" != xBASH; then 21800 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of ZIPEXE from the environment. Use command line variables instead." >&5 21801 $as_echo "$as_me: WARNING: Ignoring value of ZIPEXE from the environment. Use command line variables instead." >&2;} 21802 fi 21803 # Try to locate tool using the code snippet 21804 for ac_prog in zip 21805 do 21806 # Extract the first word of "$ac_prog", so it can be a program name with args. 21807 set dummy $ac_prog; ac_word=$2 21808 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 21809 $as_echo_n "checking for $ac_word... " >&6; } 21810 if ${ac_cv_path_ZIPEXE+:} false; then : 21811 $as_echo_n "(cached) " >&6 21812 else 21813 case $ZIPEXE in 21814 [\\/]* | ?:[\\/]*) 21815 ac_cv_path_ZIPEXE="$ZIPEXE" # Let the user override the test with a path. 21816 ;; 21817 *) 21818 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 21819 for as_dir in $PATH 21820 do 21821 IFS=$as_save_IFS 21822 test -z "$as_dir" && as_dir=. 21823 for ac_exec_ext in '' $ac_executable_extensions; do 21824 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 21825 ac_cv_path_ZIPEXE="$as_dir/$ac_word$ac_exec_ext" 21826 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 21827 break 2 21828 fi 21829 done 21830 done 21831 IFS=$as_save_IFS 21832 21833 ;; 21834 esac 21835 fi 21836 ZIPEXE=$ac_cv_path_ZIPEXE 21837 if test -n "$ZIPEXE"; then 21838 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ZIPEXE" >&5 21839 $as_echo "$ZIPEXE" >&6; } 21840 else 21841 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 21842 $as_echo "no" >&6; } 21843 fi 21844 21845 21846 test -n "$ZIPEXE" && break 21847 done 21848 21849 else 21850 # If it succeeded, then it was overridden by the user. We will use it 21851 # for the tool. 21852 21853 # First remove it from the list of overridden variables, so we can test 21854 # for unknown variables in the end. 21855 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 21856 21857 # Check if we try to supply an empty value 21858 if test "x$ZIPEXE" = x; then 21859 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool ZIPEXE= (no value)" >&5 21860 $as_echo "$as_me: Setting user supplied tool ZIPEXE= (no value)" >&6;} 21861 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ZIPEXE" >&5 21862 $as_echo_n "checking for ZIPEXE... " >&6; } 21863 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 21864 $as_echo "disabled" >&6; } 21865 else 21866 # Check if the provided tool contains a complete path. 21867 tool_specified="$ZIPEXE" 21868 tool_basename="${tool_specified##*/}" 21869 if test "x$tool_basename" = "x$tool_specified"; then 21870 # A command without a complete path is provided, search $PATH. 21871 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool ZIPEXE=$tool_basename" >&5 21872 $as_echo "$as_me: Will search for user supplied tool ZIPEXE=$tool_basename" >&6;} 21873 # Extract the first word of "$tool_basename", so it can be a program name with args. 21874 set dummy $tool_basename; ac_word=$2 21875 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 21876 $as_echo_n "checking for $ac_word... " >&6; } 21877 if ${ac_cv_path_ZIPEXE+:} false; then : 21878 $as_echo_n "(cached) " >&6 21879 else 21880 case $ZIPEXE in 21881 [\\/]* | ?:[\\/]*) 21882 ac_cv_path_ZIPEXE="$ZIPEXE" # Let the user override the test with a path. 21883 ;; 21884 *) 21885 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 21886 for as_dir in $PATH 21887 do 21888 IFS=$as_save_IFS 21889 test -z "$as_dir" && as_dir=. 21890 for ac_exec_ext in '' $ac_executable_extensions; do 21891 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 21892 ac_cv_path_ZIPEXE="$as_dir/$ac_word$ac_exec_ext" 21893 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 21894 break 2 21895 fi 21896 done 21897 done 21898 IFS=$as_save_IFS 21899 21900 ;; 21901 esac 21902 fi 21903 ZIPEXE=$ac_cv_path_ZIPEXE 21904 if test -n "$ZIPEXE"; then 21905 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ZIPEXE" >&5 21906 $as_echo "$ZIPEXE" >&6; } 21907 else 21908 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 21909 $as_echo "no" >&6; } 21910 fi 21911 21912 21913 if test "x$ZIPEXE" = x; then 21914 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 21915 fi 21916 else 21917 # Otherwise we believe it is a complete path. Use it as it is. 21918 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool ZIPEXE=$tool_specified" >&5 21919 $as_echo "$as_me: Will use user supplied tool ZIPEXE=$tool_specified" >&6;} 21920 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ZIPEXE" >&5 21921 $as_echo_n "checking for ZIPEXE... " >&6; } 21922 if test ! -x "$tool_specified"; then 21923 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 21924 $as_echo "not found" >&6; } 21925 as_fn_error $? "User supplied tool ZIPEXE=$tool_specified does not exist or is not executable" "$LINENO" 5 21926 fi 21927 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 21928 $as_echo "$tool_specified" >&6; } 21929 fi 21930 fi 21931 fi 21932 21933 fi 21934 21935 21936 21937 if test "x$ZIPEXE" = x; then 21938 as_fn_error $? "Could not find required tool for ZIPEXE" "$LINENO" 5 21939 fi 21940 21941 21942 21943 # Non-required basic tools 21944 21945 21946 21947 # Publish this variable in the help. 21948 21949 21950 if [ -z "${LDD+x}" ]; then 21951 # The variable is not set by user, try to locate tool using the code snippet 21952 for ac_prog in ldd 21953 do 21954 # Extract the first word of "$ac_prog", so it can be a program name with args. 21955 set dummy $ac_prog; ac_word=$2 21956 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 21957 $as_echo_n "checking for $ac_word... " >&6; } 21958 if ${ac_cv_path_LDD+:} false; then : 21959 $as_echo_n "(cached) " >&6 21960 else 21961 case $LDD in 21962 [\\/]* | ?:[\\/]*) 21963 ac_cv_path_LDD="$LDD" # Let the user override the test with a path. 21964 ;; 21965 *) 21966 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 21967 for as_dir in $PATH 21968 do 21969 IFS=$as_save_IFS 21970 test -z "$as_dir" && as_dir=. 21971 for ac_exec_ext in '' $ac_executable_extensions; do 21972 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 21973 ac_cv_path_LDD="$as_dir/$ac_word$ac_exec_ext" 21974 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 21975 break 2 21976 fi 21977 done 21978 done 21979 IFS=$as_save_IFS 21980 21981 ;; 21982 esac 21983 fi 21984 LDD=$ac_cv_path_LDD 21985 if test -n "$LDD"; then 21986 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $LDD" >&5 21987 $as_echo "$LDD" >&6; } 21988 else 21989 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 21990 $as_echo "no" >&6; } 21991 fi 21992 21993 21994 test -n "$LDD" && break 21995 done 21996 21997 else 21998 # The variable is set, but is it from the command line or the environment? 21999 22000 # Try to remove the string !LDD! from our list. 22001 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!LDD!/} 22002 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 22003 # If it failed, the variable was not from the command line. Ignore it, 22004 # but warn the user (except for BASH, which is always set by the calling BASH). 22005 if test "xLDD" != xBASH; then 22006 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of LDD from the environment. Use command line variables instead." >&5 22007 $as_echo "$as_me: WARNING: Ignoring value of LDD from the environment. Use command line variables instead." >&2;} 22008 fi 22009 # Try to locate tool using the code snippet 22010 for ac_prog in ldd 22011 do 22012 # Extract the first word of "$ac_prog", so it can be a program name with args. 22013 set dummy $ac_prog; ac_word=$2 22014 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 22015 $as_echo_n "checking for $ac_word... " >&6; } 22016 if ${ac_cv_path_LDD+:} false; then : 22017 $as_echo_n "(cached) " >&6 22018 else 22019 case $LDD in 22020 [\\/]* | ?:[\\/]*) 22021 ac_cv_path_LDD="$LDD" # Let the user override the test with a path. 22022 ;; 22023 *) 22024 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 22025 for as_dir in $PATH 22026 do 22027 IFS=$as_save_IFS 22028 test -z "$as_dir" && as_dir=. 22029 for ac_exec_ext in '' $ac_executable_extensions; do 22030 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 22031 ac_cv_path_LDD="$as_dir/$ac_word$ac_exec_ext" 22032 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 22033 break 2 22034 fi 22035 done 22036 done 22037 IFS=$as_save_IFS 22038 22039 ;; 22040 esac 22041 fi 22042 LDD=$ac_cv_path_LDD 22043 if test -n "$LDD"; then 22044 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $LDD" >&5 22045 $as_echo "$LDD" >&6; } 22046 else 22047 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 22048 $as_echo "no" >&6; } 22049 fi 22050 22051 22052 test -n "$LDD" && break 22053 done 22054 22055 else 22056 # If it succeeded, then it was overridden by the user. We will use it 22057 # for the tool. 22058 22059 # First remove it from the list of overridden variables, so we can test 22060 # for unknown variables in the end. 22061 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 22062 22063 # Check if we try to supply an empty value 22064 if test "x$LDD" = x; then 22065 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool LDD= (no value)" >&5 22066 $as_echo "$as_me: Setting user supplied tool LDD= (no value)" >&6;} 22067 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for LDD" >&5 22068 $as_echo_n "checking for LDD... " >&6; } 22069 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 22070 $as_echo "disabled" >&6; } 22071 else 22072 # Check if the provided tool contains a complete path. 22073 tool_specified="$LDD" 22074 tool_basename="${tool_specified##*/}" 22075 if test "x$tool_basename" = "x$tool_specified"; then 22076 # A command without a complete path is provided, search $PATH. 22077 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool LDD=$tool_basename" >&5 22078 $as_echo "$as_me: Will search for user supplied tool LDD=$tool_basename" >&6;} 22079 # Extract the first word of "$tool_basename", so it can be a program name with args. 22080 set dummy $tool_basename; ac_word=$2 22081 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 22082 $as_echo_n "checking for $ac_word... " >&6; } 22083 if ${ac_cv_path_LDD+:} false; then : 22084 $as_echo_n "(cached) " >&6 22085 else 22086 case $LDD in 22087 [\\/]* | ?:[\\/]*) 22088 ac_cv_path_LDD="$LDD" # Let the user override the test with a path. 22089 ;; 22090 *) 22091 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 22092 for as_dir in $PATH 22093 do 22094 IFS=$as_save_IFS 22095 test -z "$as_dir" && as_dir=. 22096 for ac_exec_ext in '' $ac_executable_extensions; do 22097 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 22098 ac_cv_path_LDD="$as_dir/$ac_word$ac_exec_ext" 22099 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 22100 break 2 22101 fi 22102 done 22103 done 22104 IFS=$as_save_IFS 22105 22106 ;; 22107 esac 22108 fi 22109 LDD=$ac_cv_path_LDD 22110 if test -n "$LDD"; then 22111 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $LDD" >&5 22112 $as_echo "$LDD" >&6; } 22113 else 22114 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 22115 $as_echo "no" >&6; } 22116 fi 22117 22118 22119 if test "x$LDD" = x; then 22120 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 22121 fi 22122 else 22123 # Otherwise we believe it is a complete path. Use it as it is. 22124 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool LDD=$tool_specified" >&5 22125 $as_echo "$as_me: Will use user supplied tool LDD=$tool_specified" >&6;} 22126 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for LDD" >&5 22127 $as_echo_n "checking for LDD... " >&6; } 22128 if test ! -x "$tool_specified"; then 22129 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 22130 $as_echo "not found" >&6; } 22131 as_fn_error $? "User supplied tool LDD=$tool_specified does not exist or is not executable" "$LINENO" 5 22132 fi 22133 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 22134 $as_echo "$tool_specified" >&6; } 22135 fi 22136 fi 22137 fi 22138 22139 fi 22140 22141 22142 if test "x$LDD" = "x"; then 22143 # List shared lib dependencies is used for 22144 # debug output and checking for forbidden dependencies. 22145 # We can build without it. 22146 LDD="true" 22147 fi 22148 22149 22150 # Publish this variable in the help. 22151 22152 22153 if [ -z "${READELF+x}" ]; then 22154 # The variable is not set by user, try to locate tool using the code snippet 22155 for ac_prog in greadelf readelf 22156 do 22157 # Extract the first word of "$ac_prog", so it can be a program name with args. 22158 set dummy $ac_prog; ac_word=$2 22159 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 22160 $as_echo_n "checking for $ac_word... " >&6; } 22161 if ${ac_cv_path_READELF+:} false; then : 22162 $as_echo_n "(cached) " >&6 22163 else 22164 case $READELF in 22165 [\\/]* | ?:[\\/]*) 22166 ac_cv_path_READELF="$READELF" # Let the user override the test with a path. 22167 ;; 22168 *) 22169 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 22170 for as_dir in $PATH 22171 do 22172 IFS=$as_save_IFS 22173 test -z "$as_dir" && as_dir=. 22174 for ac_exec_ext in '' $ac_executable_extensions; do 22175 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 22176 ac_cv_path_READELF="$as_dir/$ac_word$ac_exec_ext" 22177 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 22178 break 2 22179 fi 22180 done 22181 done 22182 IFS=$as_save_IFS 22183 22184 ;; 22185 esac 22186 fi 22187 READELF=$ac_cv_path_READELF 22188 if test -n "$READELF"; then 22189 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $READELF" >&5 22190 $as_echo "$READELF" >&6; } 22191 else 22192 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 22193 $as_echo "no" >&6; } 22194 fi 22195 22196 22197 test -n "$READELF" && break 22198 done 22199 22200 else 22201 # The variable is set, but is it from the command line or the environment? 22202 22203 # Try to remove the string !READELF! from our list. 22204 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!READELF!/} 22205 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 22206 # If it failed, the variable was not from the command line. Ignore it, 22207 # but warn the user (except for BASH, which is always set by the calling BASH). 22208 if test "xREADELF" != xBASH; then 22209 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of READELF from the environment. Use command line variables instead." >&5 22210 $as_echo "$as_me: WARNING: Ignoring value of READELF from the environment. Use command line variables instead." >&2;} 22211 fi 22212 # Try to locate tool using the code snippet 22213 for ac_prog in greadelf readelf 22214 do 22215 # Extract the first word of "$ac_prog", so it can be a program name with args. 22216 set dummy $ac_prog; ac_word=$2 22217 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 22218 $as_echo_n "checking for $ac_word... " >&6; } 22219 if ${ac_cv_path_READELF+:} false; then : 22220 $as_echo_n "(cached) " >&6 22221 else 22222 case $READELF in 22223 [\\/]* | ?:[\\/]*) 22224 ac_cv_path_READELF="$READELF" # Let the user override the test with a path. 22225 ;; 22226 *) 22227 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 22228 for as_dir in $PATH 22229 do 22230 IFS=$as_save_IFS 22231 test -z "$as_dir" && as_dir=. 22232 for ac_exec_ext in '' $ac_executable_extensions; do 22233 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 22234 ac_cv_path_READELF="$as_dir/$ac_word$ac_exec_ext" 22235 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 22236 break 2 22237 fi 22238 done 22239 done 22240 IFS=$as_save_IFS 22241 22242 ;; 22243 esac 22244 fi 22245 READELF=$ac_cv_path_READELF 22246 if test -n "$READELF"; then 22247 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $READELF" >&5 22248 $as_echo "$READELF" >&6; } 22249 else 22250 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 22251 $as_echo "no" >&6; } 22252 fi 22253 22254 22255 test -n "$READELF" && break 22256 done 22257 22258 else 22259 # If it succeeded, then it was overridden by the user. We will use it 22260 # for the tool. 22261 22262 # First remove it from the list of overridden variables, so we can test 22263 # for unknown variables in the end. 22264 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 22265 22266 # Check if we try to supply an empty value 22267 if test "x$READELF" = x; then 22268 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool READELF= (no value)" >&5 22269 $as_echo "$as_me: Setting user supplied tool READELF= (no value)" >&6;} 22270 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for READELF" >&5 22271 $as_echo_n "checking for READELF... " >&6; } 22272 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 22273 $as_echo "disabled" >&6; } 22274 else 22275 # Check if the provided tool contains a complete path. 22276 tool_specified="$READELF" 22277 tool_basename="${tool_specified##*/}" 22278 if test "x$tool_basename" = "x$tool_specified"; then 22279 # A command without a complete path is provided, search $PATH. 22280 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool READELF=$tool_basename" >&5 22281 $as_echo "$as_me: Will search for user supplied tool READELF=$tool_basename" >&6;} 22282 # Extract the first word of "$tool_basename", so it can be a program name with args. 22283 set dummy $tool_basename; ac_word=$2 22284 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 22285 $as_echo_n "checking for $ac_word... " >&6; } 22286 if ${ac_cv_path_READELF+:} false; then : 22287 $as_echo_n "(cached) " >&6 22288 else 22289 case $READELF in 22290 [\\/]* | ?:[\\/]*) 22291 ac_cv_path_READELF="$READELF" # Let the user override the test with a path. 22292 ;; 22293 *) 22294 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 22295 for as_dir in $PATH 22296 do 22297 IFS=$as_save_IFS 22298 test -z "$as_dir" && as_dir=. 22299 for ac_exec_ext in '' $ac_executable_extensions; do 22300 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 22301 ac_cv_path_READELF="$as_dir/$ac_word$ac_exec_ext" 22302 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 22303 break 2 22304 fi 22305 done 22306 done 22307 IFS=$as_save_IFS 22308 22309 ;; 22310 esac 22311 fi 22312 READELF=$ac_cv_path_READELF 22313 if test -n "$READELF"; then 22314 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $READELF" >&5 22315 $as_echo "$READELF" >&6; } 22316 else 22317 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 22318 $as_echo "no" >&6; } 22319 fi 22320 22321 22322 if test "x$READELF" = x; then 22323 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 22324 fi 22325 else 22326 # Otherwise we believe it is a complete path. Use it as it is. 22327 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool READELF=$tool_specified" >&5 22328 $as_echo "$as_me: Will use user supplied tool READELF=$tool_specified" >&6;} 22329 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for READELF" >&5 22330 $as_echo_n "checking for READELF... " >&6; } 22331 if test ! -x "$tool_specified"; then 22332 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 22333 $as_echo "not found" >&6; } 22334 as_fn_error $? "User supplied tool READELF=$tool_specified does not exist or is not executable" "$LINENO" 5 22335 fi 22336 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 22337 $as_echo "$tool_specified" >&6; } 22338 fi 22339 fi 22340 fi 22341 22342 fi 22343 22344 22345 22346 22347 # Publish this variable in the help. 22348 22349 22350 if [ -z "${DOT+x}" ]; then 22351 # The variable is not set by user, try to locate tool using the code snippet 22352 for ac_prog in dot 22353 do 22354 # Extract the first word of "$ac_prog", so it can be a program name with args. 22355 set dummy $ac_prog; ac_word=$2 22356 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 22357 $as_echo_n "checking for $ac_word... " >&6; } 22358 if ${ac_cv_path_DOT+:} false; then : 22359 $as_echo_n "(cached) " >&6 22360 else 22361 case $DOT in 22362 [\\/]* | ?:[\\/]*) 22363 ac_cv_path_DOT="$DOT" # Let the user override the test with a path. 22364 ;; 22365 *) 22366 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 22367 for as_dir in $PATH 22368 do 22369 IFS=$as_save_IFS 22370 test -z "$as_dir" && as_dir=. 22371 for ac_exec_ext in '' $ac_executable_extensions; do 22372 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 22373 ac_cv_path_DOT="$as_dir/$ac_word$ac_exec_ext" 22374 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 22375 break 2 22376 fi 22377 done 22378 done 22379 IFS=$as_save_IFS 22380 22381 ;; 22382 esac 22383 fi 22384 DOT=$ac_cv_path_DOT 22385 if test -n "$DOT"; then 22386 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $DOT" >&5 22387 $as_echo "$DOT" >&6; } 22388 else 22389 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 22390 $as_echo "no" >&6; } 22391 fi 22392 22393 22394 test -n "$DOT" && break 22395 done 22396 22397 else 22398 # The variable is set, but is it from the command line or the environment? 22399 22400 # Try to remove the string !DOT! from our list. 22401 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!DOT!/} 22402 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 22403 # If it failed, the variable was not from the command line. Ignore it, 22404 # but warn the user (except for BASH, which is always set by the calling BASH). 22405 if test "xDOT" != xBASH; then 22406 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of DOT from the environment. Use command line variables instead." >&5 22407 $as_echo "$as_me: WARNING: Ignoring value of DOT from the environment. Use command line variables instead." >&2;} 22408 fi 22409 # Try to locate tool using the code snippet 22410 for ac_prog in dot 22411 do 22412 # Extract the first word of "$ac_prog", so it can be a program name with args. 22413 set dummy $ac_prog; ac_word=$2 22414 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 22415 $as_echo_n "checking for $ac_word... " >&6; } 22416 if ${ac_cv_path_DOT+:} false; then : 22417 $as_echo_n "(cached) " >&6 22418 else 22419 case $DOT in 22420 [\\/]* | ?:[\\/]*) 22421 ac_cv_path_DOT="$DOT" # Let the user override the test with a path. 22422 ;; 22423 *) 22424 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 22425 for as_dir in $PATH 22426 do 22427 IFS=$as_save_IFS 22428 test -z "$as_dir" && as_dir=. 22429 for ac_exec_ext in '' $ac_executable_extensions; do 22430 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 22431 ac_cv_path_DOT="$as_dir/$ac_word$ac_exec_ext" 22432 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 22433 break 2 22434 fi 22435 done 22436 done 22437 IFS=$as_save_IFS 22438 22439 ;; 22440 esac 22441 fi 22442 DOT=$ac_cv_path_DOT 22443 if test -n "$DOT"; then 22444 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $DOT" >&5 22445 $as_echo "$DOT" >&6; } 22446 else 22447 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 22448 $as_echo "no" >&6; } 22449 fi 22450 22451 22452 test -n "$DOT" && break 22453 done 22454 22455 else 22456 # If it succeeded, then it was overridden by the user. We will use it 22457 # for the tool. 22458 22459 # First remove it from the list of overridden variables, so we can test 22460 # for unknown variables in the end. 22461 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 22462 22463 # Check if we try to supply an empty value 22464 if test "x$DOT" = x; then 22465 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool DOT= (no value)" >&5 22466 $as_echo "$as_me: Setting user supplied tool DOT= (no value)" >&6;} 22467 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for DOT" >&5 22468 $as_echo_n "checking for DOT... " >&6; } 22469 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 22470 $as_echo "disabled" >&6; } 22471 else 22472 # Check if the provided tool contains a complete path. 22473 tool_specified="$DOT" 22474 tool_basename="${tool_specified##*/}" 22475 if test "x$tool_basename" = "x$tool_specified"; then 22476 # A command without a complete path is provided, search $PATH. 22477 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool DOT=$tool_basename" >&5 22478 $as_echo "$as_me: Will search for user supplied tool DOT=$tool_basename" >&6;} 22479 # Extract the first word of "$tool_basename", so it can be a program name with args. 22480 set dummy $tool_basename; ac_word=$2 22481 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 22482 $as_echo_n "checking for $ac_word... " >&6; } 22483 if ${ac_cv_path_DOT+:} false; then : 22484 $as_echo_n "(cached) " >&6 22485 else 22486 case $DOT in 22487 [\\/]* | ?:[\\/]*) 22488 ac_cv_path_DOT="$DOT" # Let the user override the test with a path. 22489 ;; 22490 *) 22491 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 22492 for as_dir in $PATH 22493 do 22494 IFS=$as_save_IFS 22495 test -z "$as_dir" && as_dir=. 22496 for ac_exec_ext in '' $ac_executable_extensions; do 22497 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 22498 ac_cv_path_DOT="$as_dir/$ac_word$ac_exec_ext" 22499 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 22500 break 2 22501 fi 22502 done 22503 done 22504 IFS=$as_save_IFS 22505 22506 ;; 22507 esac 22508 fi 22509 DOT=$ac_cv_path_DOT 22510 if test -n "$DOT"; then 22511 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $DOT" >&5 22512 $as_echo "$DOT" >&6; } 22513 else 22514 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 22515 $as_echo "no" >&6; } 22516 fi 22517 22518 22519 if test "x$DOT" = x; then 22520 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 22521 fi 22522 else 22523 # Otherwise we believe it is a complete path. Use it as it is. 22524 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool DOT=$tool_specified" >&5 22525 $as_echo "$as_me: Will use user supplied tool DOT=$tool_specified" >&6;} 22526 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for DOT" >&5 22527 $as_echo_n "checking for DOT... " >&6; } 22528 if test ! -x "$tool_specified"; then 22529 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 22530 $as_echo "not found" >&6; } 22531 as_fn_error $? "User supplied tool DOT=$tool_specified does not exist or is not executable" "$LINENO" 5 22532 fi 22533 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 22534 $as_echo "$tool_specified" >&6; } 22535 fi 22536 fi 22537 fi 22538 22539 fi 22540 22541 22542 22543 22544 # Publish this variable in the help. 22545 22546 22547 if [ -z "${HG+x}" ]; then 22548 # The variable is not set by user, try to locate tool using the code snippet 22549 for ac_prog in hg 22550 do 22551 # Extract the first word of "$ac_prog", so it can be a program name with args. 22552 set dummy $ac_prog; ac_word=$2 22553 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 22554 $as_echo_n "checking for $ac_word... " >&6; } 22555 if ${ac_cv_path_HG+:} false; then : 22556 $as_echo_n "(cached) " >&6 22557 else 22558 case $HG in 22559 [\\/]* | ?:[\\/]*) 22560 ac_cv_path_HG="$HG" # Let the user override the test with a path. 22561 ;; 22562 *) 22563 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 22564 for as_dir in $PATH 22565 do 22566 IFS=$as_save_IFS 22567 test -z "$as_dir" && as_dir=. 22568 for ac_exec_ext in '' $ac_executable_extensions; do 22569 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 22570 ac_cv_path_HG="$as_dir/$ac_word$ac_exec_ext" 22571 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 22572 break 2 22573 fi 22574 done 22575 done 22576 IFS=$as_save_IFS 22577 22578 ;; 22579 esac 22580 fi 22581 HG=$ac_cv_path_HG 22582 if test -n "$HG"; then 22583 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $HG" >&5 22584 $as_echo "$HG" >&6; } 22585 else 22586 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 22587 $as_echo "no" >&6; } 22588 fi 22589 22590 22591 test -n "$HG" && break 22592 done 22593 22594 else 22595 # The variable is set, but is it from the command line or the environment? 22596 22597 # Try to remove the string !HG! from our list. 22598 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!HG!/} 22599 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 22600 # If it failed, the variable was not from the command line. Ignore it, 22601 # but warn the user (except for BASH, which is always set by the calling BASH). 22602 if test "xHG" != xBASH; then 22603 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of HG from the environment. Use command line variables instead." >&5 22604 $as_echo "$as_me: WARNING: Ignoring value of HG from the environment. Use command line variables instead." >&2;} 22605 fi 22606 # Try to locate tool using the code snippet 22607 for ac_prog in hg 22608 do 22609 # Extract the first word of "$ac_prog", so it can be a program name with args. 22610 set dummy $ac_prog; ac_word=$2 22611 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 22612 $as_echo_n "checking for $ac_word... " >&6; } 22613 if ${ac_cv_path_HG+:} false; then : 22614 $as_echo_n "(cached) " >&6 22615 else 22616 case $HG in 22617 [\\/]* | ?:[\\/]*) 22618 ac_cv_path_HG="$HG" # Let the user override the test with a path. 22619 ;; 22620 *) 22621 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 22622 for as_dir in $PATH 22623 do 22624 IFS=$as_save_IFS 22625 test -z "$as_dir" && as_dir=. 22626 for ac_exec_ext in '' $ac_executable_extensions; do 22627 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 22628 ac_cv_path_HG="$as_dir/$ac_word$ac_exec_ext" 22629 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 22630 break 2 22631 fi 22632 done 22633 done 22634 IFS=$as_save_IFS 22635 22636 ;; 22637 esac 22638 fi 22639 HG=$ac_cv_path_HG 22640 if test -n "$HG"; then 22641 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $HG" >&5 22642 $as_echo "$HG" >&6; } 22643 else 22644 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 22645 $as_echo "no" >&6; } 22646 fi 22647 22648 22649 test -n "$HG" && break 22650 done 22651 22652 else 22653 # If it succeeded, then it was overridden by the user. We will use it 22654 # for the tool. 22655 22656 # First remove it from the list of overridden variables, so we can test 22657 # for unknown variables in the end. 22658 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 22659 22660 # Check if we try to supply an empty value 22661 if test "x$HG" = x; then 22662 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool HG= (no value)" >&5 22663 $as_echo "$as_me: Setting user supplied tool HG= (no value)" >&6;} 22664 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for HG" >&5 22665 $as_echo_n "checking for HG... " >&6; } 22666 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 22667 $as_echo "disabled" >&6; } 22668 else 22669 # Check if the provided tool contains a complete path. 22670 tool_specified="$HG" 22671 tool_basename="${tool_specified##*/}" 22672 if test "x$tool_basename" = "x$tool_specified"; then 22673 # A command without a complete path is provided, search $PATH. 22674 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool HG=$tool_basename" >&5 22675 $as_echo "$as_me: Will search for user supplied tool HG=$tool_basename" >&6;} 22676 # Extract the first word of "$tool_basename", so it can be a program name with args. 22677 set dummy $tool_basename; ac_word=$2 22678 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 22679 $as_echo_n "checking for $ac_word... " >&6; } 22680 if ${ac_cv_path_HG+:} false; then : 22681 $as_echo_n "(cached) " >&6 22682 else 22683 case $HG in 22684 [\\/]* | ?:[\\/]*) 22685 ac_cv_path_HG="$HG" # Let the user override the test with a path. 22686 ;; 22687 *) 22688 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 22689 for as_dir in $PATH 22690 do 22691 IFS=$as_save_IFS 22692 test -z "$as_dir" && as_dir=. 22693 for ac_exec_ext in '' $ac_executable_extensions; do 22694 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 22695 ac_cv_path_HG="$as_dir/$ac_word$ac_exec_ext" 22696 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 22697 break 2 22698 fi 22699 done 22700 done 22701 IFS=$as_save_IFS 22702 22703 ;; 22704 esac 22705 fi 22706 HG=$ac_cv_path_HG 22707 if test -n "$HG"; then 22708 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $HG" >&5 22709 $as_echo "$HG" >&6; } 22710 else 22711 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 22712 $as_echo "no" >&6; } 22713 fi 22714 22715 22716 if test "x$HG" = x; then 22717 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 22718 fi 22719 else 22720 # Otherwise we believe it is a complete path. Use it as it is. 22721 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool HG=$tool_specified" >&5 22722 $as_echo "$as_me: Will use user supplied tool HG=$tool_specified" >&6;} 22723 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for HG" >&5 22724 $as_echo_n "checking for HG... " >&6; } 22725 if test ! -x "$tool_specified"; then 22726 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 22727 $as_echo "not found" >&6; } 22728 as_fn_error $? "User supplied tool HG=$tool_specified does not exist or is not executable" "$LINENO" 5 22729 fi 22730 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 22731 $as_echo "$tool_specified" >&6; } 22732 fi 22733 fi 22734 fi 22735 22736 fi 22737 22738 22739 22740 22741 # Publish this variable in the help. 22742 22743 22744 if [ -z "${STAT+x}" ]; then 22745 # The variable is not set by user, try to locate tool using the code snippet 22746 for ac_prog in stat 22747 do 22748 # Extract the first word of "$ac_prog", so it can be a program name with args. 22749 set dummy $ac_prog; ac_word=$2 22750 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 22751 $as_echo_n "checking for $ac_word... " >&6; } 22752 if ${ac_cv_path_STAT+:} false; then : 22753 $as_echo_n "(cached) " >&6 22754 else 22755 case $STAT in 22756 [\\/]* | ?:[\\/]*) 22757 ac_cv_path_STAT="$STAT" # Let the user override the test with a path. 22758 ;; 22759 *) 22760 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 22761 for as_dir in $PATH 22762 do 22763 IFS=$as_save_IFS 22764 test -z "$as_dir" && as_dir=. 22765 for ac_exec_ext in '' $ac_executable_extensions; do 22766 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 22767 ac_cv_path_STAT="$as_dir/$ac_word$ac_exec_ext" 22768 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 22769 break 2 22770 fi 22771 done 22772 done 22773 IFS=$as_save_IFS 22774 22775 ;; 22776 esac 22777 fi 22778 STAT=$ac_cv_path_STAT 22779 if test -n "$STAT"; then 22780 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $STAT" >&5 22781 $as_echo "$STAT" >&6; } 22782 else 22783 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 22784 $as_echo "no" >&6; } 22785 fi 22786 22787 22788 test -n "$STAT" && break 22789 done 22790 22791 else 22792 # The variable is set, but is it from the command line or the environment? 22793 22794 # Try to remove the string !STAT! from our list. 22795 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!STAT!/} 22796 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 22797 # If it failed, the variable was not from the command line. Ignore it, 22798 # but warn the user (except for BASH, which is always set by the calling BASH). 22799 if test "xSTAT" != xBASH; then 22800 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of STAT from the environment. Use command line variables instead." >&5 22801 $as_echo "$as_me: WARNING: Ignoring value of STAT from the environment. Use command line variables instead." >&2;} 22802 fi 22803 # Try to locate tool using the code snippet 22804 for ac_prog in stat 22805 do 22806 # Extract the first word of "$ac_prog", so it can be a program name with args. 22807 set dummy $ac_prog; ac_word=$2 22808 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 22809 $as_echo_n "checking for $ac_word... " >&6; } 22810 if ${ac_cv_path_STAT+:} false; then : 22811 $as_echo_n "(cached) " >&6 22812 else 22813 case $STAT in 22814 [\\/]* | ?:[\\/]*) 22815 ac_cv_path_STAT="$STAT" # Let the user override the test with a path. 22816 ;; 22817 *) 22818 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 22819 for as_dir in $PATH 22820 do 22821 IFS=$as_save_IFS 22822 test -z "$as_dir" && as_dir=. 22823 for ac_exec_ext in '' $ac_executable_extensions; do 22824 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 22825 ac_cv_path_STAT="$as_dir/$ac_word$ac_exec_ext" 22826 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 22827 break 2 22828 fi 22829 done 22830 done 22831 IFS=$as_save_IFS 22832 22833 ;; 22834 esac 22835 fi 22836 STAT=$ac_cv_path_STAT 22837 if test -n "$STAT"; then 22838 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $STAT" >&5 22839 $as_echo "$STAT" >&6; } 22840 else 22841 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 22842 $as_echo "no" >&6; } 22843 fi 22844 22845 22846 test -n "$STAT" && break 22847 done 22848 22849 else 22850 # If it succeeded, then it was overridden by the user. We will use it 22851 # for the tool. 22852 22853 # First remove it from the list of overridden variables, so we can test 22854 # for unknown variables in the end. 22855 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 22856 22857 # Check if we try to supply an empty value 22858 if test "x$STAT" = x; then 22859 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool STAT= (no value)" >&5 22860 $as_echo "$as_me: Setting user supplied tool STAT= (no value)" >&6;} 22861 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for STAT" >&5 22862 $as_echo_n "checking for STAT... " >&6; } 22863 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 22864 $as_echo "disabled" >&6; } 22865 else 22866 # Check if the provided tool contains a complete path. 22867 tool_specified="$STAT" 22868 tool_basename="${tool_specified##*/}" 22869 if test "x$tool_basename" = "x$tool_specified"; then 22870 # A command without a complete path is provided, search $PATH. 22871 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool STAT=$tool_basename" >&5 22872 $as_echo "$as_me: Will search for user supplied tool STAT=$tool_basename" >&6;} 22873 # Extract the first word of "$tool_basename", so it can be a program name with args. 22874 set dummy $tool_basename; ac_word=$2 22875 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 22876 $as_echo_n "checking for $ac_word... " >&6; } 22877 if ${ac_cv_path_STAT+:} false; then : 22878 $as_echo_n "(cached) " >&6 22879 else 22880 case $STAT in 22881 [\\/]* | ?:[\\/]*) 22882 ac_cv_path_STAT="$STAT" # Let the user override the test with a path. 22883 ;; 22884 *) 22885 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 22886 for as_dir in $PATH 22887 do 22888 IFS=$as_save_IFS 22889 test -z "$as_dir" && as_dir=. 22890 for ac_exec_ext in '' $ac_executable_extensions; do 22891 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 22892 ac_cv_path_STAT="$as_dir/$ac_word$ac_exec_ext" 22893 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 22894 break 2 22895 fi 22896 done 22897 done 22898 IFS=$as_save_IFS 22899 22900 ;; 22901 esac 22902 fi 22903 STAT=$ac_cv_path_STAT 22904 if test -n "$STAT"; then 22905 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $STAT" >&5 22906 $as_echo "$STAT" >&6; } 22907 else 22908 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 22909 $as_echo "no" >&6; } 22910 fi 22911 22912 22913 if test "x$STAT" = x; then 22914 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 22915 fi 22916 else 22917 # Otherwise we believe it is a complete path. Use it as it is. 22918 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool STAT=$tool_specified" >&5 22919 $as_echo "$as_me: Will use user supplied tool STAT=$tool_specified" >&6;} 22920 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for STAT" >&5 22921 $as_echo_n "checking for STAT... " >&6; } 22922 if test ! -x "$tool_specified"; then 22923 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 22924 $as_echo "not found" >&6; } 22925 as_fn_error $? "User supplied tool STAT=$tool_specified does not exist or is not executable" "$LINENO" 5 22926 fi 22927 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 22928 $as_echo "$tool_specified" >&6; } 22929 fi 22930 fi 22931 fi 22932 22933 fi 22934 22935 22936 22937 22938 # Publish this variable in the help. 22939 22940 22941 if [ -z "${TIME+x}" ]; then 22942 # The variable is not set by user, try to locate tool using the code snippet 22943 for ac_prog in time 22944 do 22945 # Extract the first word of "$ac_prog", so it can be a program name with args. 22946 set dummy $ac_prog; ac_word=$2 22947 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 22948 $as_echo_n "checking for $ac_word... " >&6; } 22949 if ${ac_cv_path_TIME+:} false; then : 22950 $as_echo_n "(cached) " >&6 22951 else 22952 case $TIME in 22953 [\\/]* | ?:[\\/]*) 22954 ac_cv_path_TIME="$TIME" # Let the user override the test with a path. 22955 ;; 22956 *) 22957 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 22958 for as_dir in $PATH 22959 do 22960 IFS=$as_save_IFS 22961 test -z "$as_dir" && as_dir=. 22962 for ac_exec_ext in '' $ac_executable_extensions; do 22963 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 22964 ac_cv_path_TIME="$as_dir/$ac_word$ac_exec_ext" 22965 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 22966 break 2 22967 fi 22968 done 22969 done 22970 IFS=$as_save_IFS 22971 22972 ;; 22973 esac 22974 fi 22975 TIME=$ac_cv_path_TIME 22976 if test -n "$TIME"; then 22977 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $TIME" >&5 22978 $as_echo "$TIME" >&6; } 22979 else 22980 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 22981 $as_echo "no" >&6; } 22982 fi 22983 22984 22985 test -n "$TIME" && break 22986 done 22987 22988 else 22989 # The variable is set, but is it from the command line or the environment? 22990 22991 # Try to remove the string !TIME! from our list. 22992 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!TIME!/} 22993 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 22994 # If it failed, the variable was not from the command line. Ignore it, 22995 # but warn the user (except for BASH, which is always set by the calling BASH). 22996 if test "xTIME" != xBASH; then 22997 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of TIME from the environment. Use command line variables instead." >&5 22998 $as_echo "$as_me: WARNING: Ignoring value of TIME from the environment. Use command line variables instead." >&2;} 22999 fi 23000 # Try to locate tool using the code snippet 23001 for ac_prog in time 23002 do 23003 # Extract the first word of "$ac_prog", so it can be a program name with args. 23004 set dummy $ac_prog; ac_word=$2 23005 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 23006 $as_echo_n "checking for $ac_word... " >&6; } 23007 if ${ac_cv_path_TIME+:} false; then : 23008 $as_echo_n "(cached) " >&6 23009 else 23010 case $TIME in 23011 [\\/]* | ?:[\\/]*) 23012 ac_cv_path_TIME="$TIME" # Let the user override the test with a path. 23013 ;; 23014 *) 23015 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 23016 for as_dir in $PATH 23017 do 23018 IFS=$as_save_IFS 23019 test -z "$as_dir" && as_dir=. 23020 for ac_exec_ext in '' $ac_executable_extensions; do 23021 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 23022 ac_cv_path_TIME="$as_dir/$ac_word$ac_exec_ext" 23023 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 23024 break 2 23025 fi 23026 done 23027 done 23028 IFS=$as_save_IFS 23029 23030 ;; 23031 esac 23032 fi 23033 TIME=$ac_cv_path_TIME 23034 if test -n "$TIME"; then 23035 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $TIME" >&5 23036 $as_echo "$TIME" >&6; } 23037 else 23038 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 23039 $as_echo "no" >&6; } 23040 fi 23041 23042 23043 test -n "$TIME" && break 23044 done 23045 23046 else 23047 # If it succeeded, then it was overridden by the user. We will use it 23048 # for the tool. 23049 23050 # First remove it from the list of overridden variables, so we can test 23051 # for unknown variables in the end. 23052 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 23053 23054 # Check if we try to supply an empty value 23055 if test "x$TIME" = x; then 23056 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool TIME= (no value)" >&5 23057 $as_echo "$as_me: Setting user supplied tool TIME= (no value)" >&6;} 23058 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for TIME" >&5 23059 $as_echo_n "checking for TIME... " >&6; } 23060 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 23061 $as_echo "disabled" >&6; } 23062 else 23063 # Check if the provided tool contains a complete path. 23064 tool_specified="$TIME" 23065 tool_basename="${tool_specified##*/}" 23066 if test "x$tool_basename" = "x$tool_specified"; then 23067 # A command without a complete path is provided, search $PATH. 23068 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool TIME=$tool_basename" >&5 23069 $as_echo "$as_me: Will search for user supplied tool TIME=$tool_basename" >&6;} 23070 # Extract the first word of "$tool_basename", so it can be a program name with args. 23071 set dummy $tool_basename; ac_word=$2 23072 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 23073 $as_echo_n "checking for $ac_word... " >&6; } 23074 if ${ac_cv_path_TIME+:} false; then : 23075 $as_echo_n "(cached) " >&6 23076 else 23077 case $TIME in 23078 [\\/]* | ?:[\\/]*) 23079 ac_cv_path_TIME="$TIME" # Let the user override the test with a path. 23080 ;; 23081 *) 23082 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 23083 for as_dir in $PATH 23084 do 23085 IFS=$as_save_IFS 23086 test -z "$as_dir" && as_dir=. 23087 for ac_exec_ext in '' $ac_executable_extensions; do 23088 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 23089 ac_cv_path_TIME="$as_dir/$ac_word$ac_exec_ext" 23090 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 23091 break 2 23092 fi 23093 done 23094 done 23095 IFS=$as_save_IFS 23096 23097 ;; 23098 esac 23099 fi 23100 TIME=$ac_cv_path_TIME 23101 if test -n "$TIME"; then 23102 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $TIME" >&5 23103 $as_echo "$TIME" >&6; } 23104 else 23105 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 23106 $as_echo "no" >&6; } 23107 fi 23108 23109 23110 if test "x$TIME" = x; then 23111 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 23112 fi 23113 else 23114 # Otherwise we believe it is a complete path. Use it as it is. 23115 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool TIME=$tool_specified" >&5 23116 $as_echo "$as_me: Will use user supplied tool TIME=$tool_specified" >&6;} 23117 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for TIME" >&5 23118 $as_echo_n "checking for TIME... " >&6; } 23119 if test ! -x "$tool_specified"; then 23120 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 23121 $as_echo "not found" >&6; } 23122 as_fn_error $? "User supplied tool TIME=$tool_specified does not exist or is not executable" "$LINENO" 5 23123 fi 23124 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 23125 $as_echo "$tool_specified" >&6; } 23126 fi 23127 fi 23128 fi 23129 23130 fi 23131 23132 23133 23134 23135 # Publish this variable in the help. 23136 23137 23138 if [ -z "${FLOCK+x}" ]; then 23139 # The variable is not set by user, try to locate tool using the code snippet 23140 for ac_prog in flock 23141 do 23142 # Extract the first word of "$ac_prog", so it can be a program name with args. 23143 set dummy $ac_prog; ac_word=$2 23144 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 23145 $as_echo_n "checking for $ac_word... " >&6; } 23146 if ${ac_cv_path_FLOCK+:} false; then : 23147 $as_echo_n "(cached) " >&6 23148 else 23149 case $FLOCK in 23150 [\\/]* | ?:[\\/]*) 23151 ac_cv_path_FLOCK="$FLOCK" # Let the user override the test with a path. 23152 ;; 23153 *) 23154 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 23155 for as_dir in $PATH 23156 do 23157 IFS=$as_save_IFS 23158 test -z "$as_dir" && as_dir=. 23159 for ac_exec_ext in '' $ac_executable_extensions; do 23160 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 23161 ac_cv_path_FLOCK="$as_dir/$ac_word$ac_exec_ext" 23162 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 23163 break 2 23164 fi 23165 done 23166 done 23167 IFS=$as_save_IFS 23168 23169 ;; 23170 esac 23171 fi 23172 FLOCK=$ac_cv_path_FLOCK 23173 if test -n "$FLOCK"; then 23174 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $FLOCK" >&5 23175 $as_echo "$FLOCK" >&6; } 23176 else 23177 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 23178 $as_echo "no" >&6; } 23179 fi 23180 23181 23182 test -n "$FLOCK" && break 23183 done 23184 23185 else 23186 # The variable is set, but is it from the command line or the environment? 23187 23188 # Try to remove the string !FLOCK! from our list. 23189 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!FLOCK!/} 23190 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 23191 # If it failed, the variable was not from the command line. Ignore it, 23192 # but warn the user (except for BASH, which is always set by the calling BASH). 23193 if test "xFLOCK" != xBASH; then 23194 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of FLOCK from the environment. Use command line variables instead." >&5 23195 $as_echo "$as_me: WARNING: Ignoring value of FLOCK from the environment. Use command line variables instead." >&2;} 23196 fi 23197 # Try to locate tool using the code snippet 23198 for ac_prog in flock 23199 do 23200 # Extract the first word of "$ac_prog", so it can be a program name with args. 23201 set dummy $ac_prog; ac_word=$2 23202 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 23203 $as_echo_n "checking for $ac_word... " >&6; } 23204 if ${ac_cv_path_FLOCK+:} false; then : 23205 $as_echo_n "(cached) " >&6 23206 else 23207 case $FLOCK in 23208 [\\/]* | ?:[\\/]*) 23209 ac_cv_path_FLOCK="$FLOCK" # Let the user override the test with a path. 23210 ;; 23211 *) 23212 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 23213 for as_dir in $PATH 23214 do 23215 IFS=$as_save_IFS 23216 test -z "$as_dir" && as_dir=. 23217 for ac_exec_ext in '' $ac_executable_extensions; do 23218 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 23219 ac_cv_path_FLOCK="$as_dir/$ac_word$ac_exec_ext" 23220 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 23221 break 2 23222 fi 23223 done 23224 done 23225 IFS=$as_save_IFS 23226 23227 ;; 23228 esac 23229 fi 23230 FLOCK=$ac_cv_path_FLOCK 23231 if test -n "$FLOCK"; then 23232 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $FLOCK" >&5 23233 $as_echo "$FLOCK" >&6; } 23234 else 23235 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 23236 $as_echo "no" >&6; } 23237 fi 23238 23239 23240 test -n "$FLOCK" && break 23241 done 23242 23243 else 23244 # If it succeeded, then it was overridden by the user. We will use it 23245 # for the tool. 23246 23247 # First remove it from the list of overridden variables, so we can test 23248 # for unknown variables in the end. 23249 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 23250 23251 # Check if we try to supply an empty value 23252 if test "x$FLOCK" = x; then 23253 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool FLOCK= (no value)" >&5 23254 $as_echo "$as_me: Setting user supplied tool FLOCK= (no value)" >&6;} 23255 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for FLOCK" >&5 23256 $as_echo_n "checking for FLOCK... " >&6; } 23257 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 23258 $as_echo "disabled" >&6; } 23259 else 23260 # Check if the provided tool contains a complete path. 23261 tool_specified="$FLOCK" 23262 tool_basename="${tool_specified##*/}" 23263 if test "x$tool_basename" = "x$tool_specified"; then 23264 # A command without a complete path is provided, search $PATH. 23265 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool FLOCK=$tool_basename" >&5 23266 $as_echo "$as_me: Will search for user supplied tool FLOCK=$tool_basename" >&6;} 23267 # Extract the first word of "$tool_basename", so it can be a program name with args. 23268 set dummy $tool_basename; ac_word=$2 23269 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 23270 $as_echo_n "checking for $ac_word... " >&6; } 23271 if ${ac_cv_path_FLOCK+:} false; then : 23272 $as_echo_n "(cached) " >&6 23273 else 23274 case $FLOCK in 23275 [\\/]* | ?:[\\/]*) 23276 ac_cv_path_FLOCK="$FLOCK" # Let the user override the test with a path. 23277 ;; 23278 *) 23279 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 23280 for as_dir in $PATH 23281 do 23282 IFS=$as_save_IFS 23283 test -z "$as_dir" && as_dir=. 23284 for ac_exec_ext in '' $ac_executable_extensions; do 23285 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 23286 ac_cv_path_FLOCK="$as_dir/$ac_word$ac_exec_ext" 23287 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 23288 break 2 23289 fi 23290 done 23291 done 23292 IFS=$as_save_IFS 23293 23294 ;; 23295 esac 23296 fi 23297 FLOCK=$ac_cv_path_FLOCK 23298 if test -n "$FLOCK"; then 23299 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $FLOCK" >&5 23300 $as_echo "$FLOCK" >&6; } 23301 else 23302 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 23303 $as_echo "no" >&6; } 23304 fi 23305 23306 23307 if test "x$FLOCK" = x; then 23308 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 23309 fi 23310 else 23311 # Otherwise we believe it is a complete path. Use it as it is. 23312 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool FLOCK=$tool_specified" >&5 23313 $as_echo "$as_me: Will use user supplied tool FLOCK=$tool_specified" >&6;} 23314 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for FLOCK" >&5 23315 $as_echo_n "checking for FLOCK... " >&6; } 23316 if test ! -x "$tool_specified"; then 23317 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 23318 $as_echo "not found" >&6; } 23319 as_fn_error $? "User supplied tool FLOCK=$tool_specified does not exist or is not executable" "$LINENO" 5 23320 fi 23321 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 23322 $as_echo "$tool_specified" >&6; } 23323 fi 23324 fi 23325 fi 23326 23327 fi 23328 23329 23330 # Dtrace is usually found in /usr/sbin on Solaris, but that directory may not 23331 # be in the user path. 23332 23333 23334 # Publish this variable in the help. 23335 23336 23337 if [ -z "${DTRACE+x}" ]; then 23338 # The variable is not set by user, try to locate tool using the code snippet 23339 for ac_prog in dtrace 23340 do 23341 # Extract the first word of "$ac_prog", so it can be a program name with args. 23342 set dummy $ac_prog; ac_word=$2 23343 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 23344 $as_echo_n "checking for $ac_word... " >&6; } 23345 if ${ac_cv_path_DTRACE+:} false; then : 23346 $as_echo_n "(cached) " >&6 23347 else 23348 case $DTRACE in 23349 [\\/]* | ?:[\\/]*) 23350 ac_cv_path_DTRACE="$DTRACE" # Let the user override the test with a path. 23351 ;; 23352 *) 23353 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 23354 as_dummy="$PATH:/usr/sbin" 23355 for as_dir in $as_dummy 23356 do 23357 IFS=$as_save_IFS 23358 test -z "$as_dir" && as_dir=. 23359 for ac_exec_ext in '' $ac_executable_extensions; do 23360 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 23361 ac_cv_path_DTRACE="$as_dir/$ac_word$ac_exec_ext" 23362 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 23363 break 2 23364 fi 23365 done 23366 done 23367 IFS=$as_save_IFS 23368 23369 ;; 23370 esac 23371 fi 23372 DTRACE=$ac_cv_path_DTRACE 23373 if test -n "$DTRACE"; then 23374 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $DTRACE" >&5 23375 $as_echo "$DTRACE" >&6; } 23376 else 23377 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 23378 $as_echo "no" >&6; } 23379 fi 23380 23381 23382 test -n "$DTRACE" && break 23383 done 23384 23385 else 23386 # The variable is set, but is it from the command line or the environment? 23387 23388 # Try to remove the string !DTRACE! from our list. 23389 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!DTRACE!/} 23390 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 23391 # If it failed, the variable was not from the command line. Ignore it, 23392 # but warn the user (except for BASH, which is always set by the calling BASH). 23393 if test "xDTRACE" != xBASH; then 23394 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of DTRACE from the environment. Use command line variables instead." >&5 23395 $as_echo "$as_me: WARNING: Ignoring value of DTRACE from the environment. Use command line variables instead." >&2;} 23396 fi 23397 # Try to locate tool using the code snippet 23398 for ac_prog in dtrace 23399 do 23400 # Extract the first word of "$ac_prog", so it can be a program name with args. 23401 set dummy $ac_prog; ac_word=$2 23402 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 23403 $as_echo_n "checking for $ac_word... " >&6; } 23404 if ${ac_cv_path_DTRACE+:} false; then : 23405 $as_echo_n "(cached) " >&6 23406 else 23407 case $DTRACE in 23408 [\\/]* | ?:[\\/]*) 23409 ac_cv_path_DTRACE="$DTRACE" # Let the user override the test with a path. 23410 ;; 23411 *) 23412 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 23413 as_dummy="$PATH:/usr/sbin" 23414 for as_dir in $as_dummy 23415 do 23416 IFS=$as_save_IFS 23417 test -z "$as_dir" && as_dir=. 23418 for ac_exec_ext in '' $ac_executable_extensions; do 23419 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 23420 ac_cv_path_DTRACE="$as_dir/$ac_word$ac_exec_ext" 23421 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 23422 break 2 23423 fi 23424 done 23425 done 23426 IFS=$as_save_IFS 23427 23428 ;; 23429 esac 23430 fi 23431 DTRACE=$ac_cv_path_DTRACE 23432 if test -n "$DTRACE"; then 23433 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $DTRACE" >&5 23434 $as_echo "$DTRACE" >&6; } 23435 else 23436 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 23437 $as_echo "no" >&6; } 23438 fi 23439 23440 23441 test -n "$DTRACE" && break 23442 done 23443 23444 else 23445 # If it succeeded, then it was overridden by the user. We will use it 23446 # for the tool. 23447 23448 # First remove it from the list of overridden variables, so we can test 23449 # for unknown variables in the end. 23450 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 23451 23452 # Check if we try to supply an empty value 23453 if test "x$DTRACE" = x; then 23454 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool DTRACE= (no value)" >&5 23455 $as_echo "$as_me: Setting user supplied tool DTRACE= (no value)" >&6;} 23456 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for DTRACE" >&5 23457 $as_echo_n "checking for DTRACE... " >&6; } 23458 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 23459 $as_echo "disabled" >&6; } 23460 else 23461 # Check if the provided tool contains a complete path. 23462 tool_specified="$DTRACE" 23463 tool_basename="${tool_specified##*/}" 23464 if test "x$tool_basename" = "x$tool_specified"; then 23465 # A command without a complete path is provided, search $PATH. 23466 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool DTRACE=$tool_basename" >&5 23467 $as_echo "$as_me: Will search for user supplied tool DTRACE=$tool_basename" >&6;} 23468 # Extract the first word of "$tool_basename", so it can be a program name with args. 23469 set dummy $tool_basename; ac_word=$2 23470 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 23471 $as_echo_n "checking for $ac_word... " >&6; } 23472 if ${ac_cv_path_DTRACE+:} false; then : 23473 $as_echo_n "(cached) " >&6 23474 else 23475 case $DTRACE in 23476 [\\/]* | ?:[\\/]*) 23477 ac_cv_path_DTRACE="$DTRACE" # Let the user override the test with a path. 23478 ;; 23479 *) 23480 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 23481 for as_dir in $PATH 23482 do 23483 IFS=$as_save_IFS 23484 test -z "$as_dir" && as_dir=. 23485 for ac_exec_ext in '' $ac_executable_extensions; do 23486 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 23487 ac_cv_path_DTRACE="$as_dir/$ac_word$ac_exec_ext" 23488 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 23489 break 2 23490 fi 23491 done 23492 done 23493 IFS=$as_save_IFS 23494 23495 ;; 23496 esac 23497 fi 23498 DTRACE=$ac_cv_path_DTRACE 23499 if test -n "$DTRACE"; then 23500 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $DTRACE" >&5 23501 $as_echo "$DTRACE" >&6; } 23502 else 23503 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 23504 $as_echo "no" >&6; } 23505 fi 23506 23507 23508 if test "x$DTRACE" = x; then 23509 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 23510 fi 23511 else 23512 # Otherwise we believe it is a complete path. Use it as it is. 23513 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool DTRACE=$tool_specified" >&5 23514 $as_echo "$as_me: Will use user supplied tool DTRACE=$tool_specified" >&6;} 23515 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for DTRACE" >&5 23516 $as_echo_n "checking for DTRACE... " >&6; } 23517 if test ! -x "$tool_specified"; then 23518 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 23519 $as_echo "not found" >&6; } 23520 as_fn_error $? "User supplied tool DTRACE=$tool_specified does not exist or is not executable" "$LINENO" 5 23521 fi 23522 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 23523 $as_echo "$tool_specified" >&6; } 23524 fi 23525 fi 23526 fi 23527 23528 fi 23529 23530 23531 23532 23533 # Publish this variable in the help. 23534 23535 23536 if [ -z "${PATCH+x}" ]; then 23537 # The variable is not set by user, try to locate tool using the code snippet 23538 for ac_prog in gpatch patch 23539 do 23540 # Extract the first word of "$ac_prog", so it can be a program name with args. 23541 set dummy $ac_prog; ac_word=$2 23542 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 23543 $as_echo_n "checking for $ac_word... " >&6; } 23544 if ${ac_cv_path_PATCH+:} false; then : 23545 $as_echo_n "(cached) " >&6 23546 else 23547 case $PATCH in 23548 [\\/]* | ?:[\\/]*) 23549 ac_cv_path_PATCH="$PATCH" # Let the user override the test with a path. 23550 ;; 23551 *) 23552 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 23553 for as_dir in $PATH 23554 do 23555 IFS=$as_save_IFS 23556 test -z "$as_dir" && as_dir=. 23557 for ac_exec_ext in '' $ac_executable_extensions; do 23558 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 23559 ac_cv_path_PATCH="$as_dir/$ac_word$ac_exec_ext" 23560 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 23561 break 2 23562 fi 23563 done 23564 done 23565 IFS=$as_save_IFS 23566 23567 ;; 23568 esac 23569 fi 23570 PATCH=$ac_cv_path_PATCH 23571 if test -n "$PATCH"; then 23572 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $PATCH" >&5 23573 $as_echo "$PATCH" >&6; } 23574 else 23575 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 23576 $as_echo "no" >&6; } 23577 fi 23578 23579 23580 test -n "$PATCH" && break 23581 done 23582 23583 else 23584 # The variable is set, but is it from the command line or the environment? 23585 23586 # Try to remove the string !PATCH! from our list. 23587 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!PATCH!/} 23588 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 23589 # If it failed, the variable was not from the command line. Ignore it, 23590 # but warn the user (except for BASH, which is always set by the calling BASH). 23591 if test "xPATCH" != xBASH; then 23592 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of PATCH from the environment. Use command line variables instead." >&5 23593 $as_echo "$as_me: WARNING: Ignoring value of PATCH from the environment. Use command line variables instead." >&2;} 23594 fi 23595 # Try to locate tool using the code snippet 23596 for ac_prog in gpatch patch 23597 do 23598 # Extract the first word of "$ac_prog", so it can be a program name with args. 23599 set dummy $ac_prog; ac_word=$2 23600 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 23601 $as_echo_n "checking for $ac_word... " >&6; } 23602 if ${ac_cv_path_PATCH+:} false; then : 23603 $as_echo_n "(cached) " >&6 23604 else 23605 case $PATCH in 23606 [\\/]* | ?:[\\/]*) 23607 ac_cv_path_PATCH="$PATCH" # Let the user override the test with a path. 23608 ;; 23609 *) 23610 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 23611 for as_dir in $PATH 23612 do 23613 IFS=$as_save_IFS 23614 test -z "$as_dir" && as_dir=. 23615 for ac_exec_ext in '' $ac_executable_extensions; do 23616 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 23617 ac_cv_path_PATCH="$as_dir/$ac_word$ac_exec_ext" 23618 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 23619 break 2 23620 fi 23621 done 23622 done 23623 IFS=$as_save_IFS 23624 23625 ;; 23626 esac 23627 fi 23628 PATCH=$ac_cv_path_PATCH 23629 if test -n "$PATCH"; then 23630 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $PATCH" >&5 23631 $as_echo "$PATCH" >&6; } 23632 else 23633 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 23634 $as_echo "no" >&6; } 23635 fi 23636 23637 23638 test -n "$PATCH" && break 23639 done 23640 23641 else 23642 # If it succeeded, then it was overridden by the user. We will use it 23643 # for the tool. 23644 23645 # First remove it from the list of overridden variables, so we can test 23646 # for unknown variables in the end. 23647 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 23648 23649 # Check if we try to supply an empty value 23650 if test "x$PATCH" = x; then 23651 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool PATCH= (no value)" >&5 23652 $as_echo "$as_me: Setting user supplied tool PATCH= (no value)" >&6;} 23653 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for PATCH" >&5 23654 $as_echo_n "checking for PATCH... " >&6; } 23655 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 23656 $as_echo "disabled" >&6; } 23657 else 23658 # Check if the provided tool contains a complete path. 23659 tool_specified="$PATCH" 23660 tool_basename="${tool_specified##*/}" 23661 if test "x$tool_basename" = "x$tool_specified"; then 23662 # A command without a complete path is provided, search $PATH. 23663 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool PATCH=$tool_basename" >&5 23664 $as_echo "$as_me: Will search for user supplied tool PATCH=$tool_basename" >&6;} 23665 # Extract the first word of "$tool_basename", so it can be a program name with args. 23666 set dummy $tool_basename; ac_word=$2 23667 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 23668 $as_echo_n "checking for $ac_word... " >&6; } 23669 if ${ac_cv_path_PATCH+:} false; then : 23670 $as_echo_n "(cached) " >&6 23671 else 23672 case $PATCH in 23673 [\\/]* | ?:[\\/]*) 23674 ac_cv_path_PATCH="$PATCH" # Let the user override the test with a path. 23675 ;; 23676 *) 23677 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 23678 for as_dir in $PATH 23679 do 23680 IFS=$as_save_IFS 23681 test -z "$as_dir" && as_dir=. 23682 for ac_exec_ext in '' $ac_executable_extensions; do 23683 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 23684 ac_cv_path_PATCH="$as_dir/$ac_word$ac_exec_ext" 23685 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 23686 break 2 23687 fi 23688 done 23689 done 23690 IFS=$as_save_IFS 23691 23692 ;; 23693 esac 23694 fi 23695 PATCH=$ac_cv_path_PATCH 23696 if test -n "$PATCH"; then 23697 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $PATCH" >&5 23698 $as_echo "$PATCH" >&6; } 23699 else 23700 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 23701 $as_echo "no" >&6; } 23702 fi 23703 23704 23705 if test "x$PATCH" = x; then 23706 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 23707 fi 23708 else 23709 # Otherwise we believe it is a complete path. Use it as it is. 23710 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool PATCH=$tool_specified" >&5 23711 $as_echo "$as_me: Will use user supplied tool PATCH=$tool_specified" >&6;} 23712 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for PATCH" >&5 23713 $as_echo_n "checking for PATCH... " >&6; } 23714 if test ! -x "$tool_specified"; then 23715 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 23716 $as_echo "not found" >&6; } 23717 as_fn_error $? "User supplied tool PATCH=$tool_specified does not exist or is not executable" "$LINENO" 5 23718 fi 23719 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 23720 $as_echo "$tool_specified" >&6; } 23721 fi 23722 fi 23723 fi 23724 23725 fi 23726 23727 23728 # Check if it's GNU time 23729 IS_GNU_TIME=`$TIME --version 2>&1 | $GREP 'GNU time'` 23730 if test "x$IS_GNU_TIME" != x; then 23731 IS_GNU_TIME=yes 23732 else 23733 IS_GNU_TIME=no 23734 fi 23735 23736 23737 if test "x$OPENJDK_TARGET_OS" = "xmacosx"; then 23738 23739 23740 23741 # Publish this variable in the help. 23742 23743 23744 if [ -z "${DSYMUTIL+x}" ]; then 23745 # The variable is not set by user, try to locate tool using the code snippet 23746 for ac_prog in dsymutil 23747 do 23748 # Extract the first word of "$ac_prog", so it can be a program name with args. 23749 set dummy $ac_prog; ac_word=$2 23750 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 23751 $as_echo_n "checking for $ac_word... " >&6; } 23752 if ${ac_cv_path_DSYMUTIL+:} false; then : 23753 $as_echo_n "(cached) " >&6 23754 else 23755 case $DSYMUTIL in 23756 [\\/]* | ?:[\\/]*) 23757 ac_cv_path_DSYMUTIL="$DSYMUTIL" # Let the user override the test with a path. 23758 ;; 23759 *) 23760 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 23761 for as_dir in $PATH 23762 do 23763 IFS=$as_save_IFS 23764 test -z "$as_dir" && as_dir=. 23765 for ac_exec_ext in '' $ac_executable_extensions; do 23766 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 23767 ac_cv_path_DSYMUTIL="$as_dir/$ac_word$ac_exec_ext" 23768 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 23769 break 2 23770 fi 23771 done 23772 done 23773 IFS=$as_save_IFS 23774 23775 ;; 23776 esac 23777 fi 23778 DSYMUTIL=$ac_cv_path_DSYMUTIL 23779 if test -n "$DSYMUTIL"; then 23780 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $DSYMUTIL" >&5 23781 $as_echo "$DSYMUTIL" >&6; } 23782 else 23783 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 23784 $as_echo "no" >&6; } 23785 fi 23786 23787 23788 test -n "$DSYMUTIL" && break 23789 done 23790 23791 else 23792 # The variable is set, but is it from the command line or the environment? 23793 23794 # Try to remove the string !DSYMUTIL! from our list. 23795 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!DSYMUTIL!/} 23796 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 23797 # If it failed, the variable was not from the command line. Ignore it, 23798 # but warn the user (except for BASH, which is always set by the calling BASH). 23799 if test "xDSYMUTIL" != xBASH; then 23800 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of DSYMUTIL from the environment. Use command line variables instead." >&5 23801 $as_echo "$as_me: WARNING: Ignoring value of DSYMUTIL from the environment. Use command line variables instead." >&2;} 23802 fi 23803 # Try to locate tool using the code snippet 23804 for ac_prog in dsymutil 23805 do 23806 # Extract the first word of "$ac_prog", so it can be a program name with args. 23807 set dummy $ac_prog; ac_word=$2 23808 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 23809 $as_echo_n "checking for $ac_word... " >&6; } 23810 if ${ac_cv_path_DSYMUTIL+:} false; then : 23811 $as_echo_n "(cached) " >&6 23812 else 23813 case $DSYMUTIL in 23814 [\\/]* | ?:[\\/]*) 23815 ac_cv_path_DSYMUTIL="$DSYMUTIL" # Let the user override the test with a path. 23816 ;; 23817 *) 23818 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 23819 for as_dir in $PATH 23820 do 23821 IFS=$as_save_IFS 23822 test -z "$as_dir" && as_dir=. 23823 for ac_exec_ext in '' $ac_executable_extensions; do 23824 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 23825 ac_cv_path_DSYMUTIL="$as_dir/$ac_word$ac_exec_ext" 23826 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 23827 break 2 23828 fi 23829 done 23830 done 23831 IFS=$as_save_IFS 23832 23833 ;; 23834 esac 23835 fi 23836 DSYMUTIL=$ac_cv_path_DSYMUTIL 23837 if test -n "$DSYMUTIL"; then 23838 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $DSYMUTIL" >&5 23839 $as_echo "$DSYMUTIL" >&6; } 23840 else 23841 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 23842 $as_echo "no" >&6; } 23843 fi 23844 23845 23846 test -n "$DSYMUTIL" && break 23847 done 23848 23849 else 23850 # If it succeeded, then it was overridden by the user. We will use it 23851 # for the tool. 23852 23853 # First remove it from the list of overridden variables, so we can test 23854 # for unknown variables in the end. 23855 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 23856 23857 # Check if we try to supply an empty value 23858 if test "x$DSYMUTIL" = x; then 23859 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool DSYMUTIL= (no value)" >&5 23860 $as_echo "$as_me: Setting user supplied tool DSYMUTIL= (no value)" >&6;} 23861 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for DSYMUTIL" >&5 23862 $as_echo_n "checking for DSYMUTIL... " >&6; } 23863 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 23864 $as_echo "disabled" >&6; } 23865 else 23866 # Check if the provided tool contains a complete path. 23867 tool_specified="$DSYMUTIL" 23868 tool_basename="${tool_specified##*/}" 23869 if test "x$tool_basename" = "x$tool_specified"; then 23870 # A command without a complete path is provided, search $PATH. 23871 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool DSYMUTIL=$tool_basename" >&5 23872 $as_echo "$as_me: Will search for user supplied tool DSYMUTIL=$tool_basename" >&6;} 23873 # Extract the first word of "$tool_basename", so it can be a program name with args. 23874 set dummy $tool_basename; ac_word=$2 23875 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 23876 $as_echo_n "checking for $ac_word... " >&6; } 23877 if ${ac_cv_path_DSYMUTIL+:} false; then : 23878 $as_echo_n "(cached) " >&6 23879 else 23880 case $DSYMUTIL in 23881 [\\/]* | ?:[\\/]*) 23882 ac_cv_path_DSYMUTIL="$DSYMUTIL" # Let the user override the test with a path. 23883 ;; 23884 *) 23885 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 23886 for as_dir in $PATH 23887 do 23888 IFS=$as_save_IFS 23889 test -z "$as_dir" && as_dir=. 23890 for ac_exec_ext in '' $ac_executable_extensions; do 23891 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 23892 ac_cv_path_DSYMUTIL="$as_dir/$ac_word$ac_exec_ext" 23893 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 23894 break 2 23895 fi 23896 done 23897 done 23898 IFS=$as_save_IFS 23899 23900 ;; 23901 esac 23902 fi 23903 DSYMUTIL=$ac_cv_path_DSYMUTIL 23904 if test -n "$DSYMUTIL"; then 23905 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $DSYMUTIL" >&5 23906 $as_echo "$DSYMUTIL" >&6; } 23907 else 23908 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 23909 $as_echo "no" >&6; } 23910 fi 23911 23912 23913 if test "x$DSYMUTIL" = x; then 23914 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 23915 fi 23916 else 23917 # Otherwise we believe it is a complete path. Use it as it is. 23918 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool DSYMUTIL=$tool_specified" >&5 23919 $as_echo "$as_me: Will use user supplied tool DSYMUTIL=$tool_specified" >&6;} 23920 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for DSYMUTIL" >&5 23921 $as_echo_n "checking for DSYMUTIL... " >&6; } 23922 if test ! -x "$tool_specified"; then 23923 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 23924 $as_echo "not found" >&6; } 23925 as_fn_error $? "User supplied tool DSYMUTIL=$tool_specified does not exist or is not executable" "$LINENO" 5 23926 fi 23927 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 23928 $as_echo "$tool_specified" >&6; } 23929 fi 23930 fi 23931 fi 23932 23933 fi 23934 23935 23936 23937 if test "x$DSYMUTIL" = x; then 23938 as_fn_error $? "Could not find required tool for DSYMUTIL" "$LINENO" 5 23939 fi 23940 23941 23942 23943 23944 23945 # Publish this variable in the help. 23946 23947 23948 if [ -z "${XATTR+x}" ]; then 23949 # The variable is not set by user, try to locate tool using the code snippet 23950 for ac_prog in xattr 23951 do 23952 # Extract the first word of "$ac_prog", so it can be a program name with args. 23953 set dummy $ac_prog; ac_word=$2 23954 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 23955 $as_echo_n "checking for $ac_word... " >&6; } 23956 if ${ac_cv_path_XATTR+:} false; then : 23957 $as_echo_n "(cached) " >&6 23958 else 23959 case $XATTR in 23960 [\\/]* | ?:[\\/]*) 23961 ac_cv_path_XATTR="$XATTR" # Let the user override the test with a path. 23962 ;; 23963 *) 23964 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 23965 for as_dir in $PATH 23966 do 23967 IFS=$as_save_IFS 23968 test -z "$as_dir" && as_dir=. 23969 for ac_exec_ext in '' $ac_executable_extensions; do 23970 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 23971 ac_cv_path_XATTR="$as_dir/$ac_word$ac_exec_ext" 23972 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 23973 break 2 23974 fi 23975 done 23976 done 23977 IFS=$as_save_IFS 23978 23979 ;; 23980 esac 23981 fi 23982 XATTR=$ac_cv_path_XATTR 23983 if test -n "$XATTR"; then 23984 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $XATTR" >&5 23985 $as_echo "$XATTR" >&6; } 23986 else 23987 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 23988 $as_echo "no" >&6; } 23989 fi 23990 23991 23992 test -n "$XATTR" && break 23993 done 23994 23995 else 23996 # The variable is set, but is it from the command line or the environment? 23997 23998 # Try to remove the string !XATTR! from our list. 23999 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!XATTR!/} 24000 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 24001 # If it failed, the variable was not from the command line. Ignore it, 24002 # but warn the user (except for BASH, which is always set by the calling BASH). 24003 if test "xXATTR" != xBASH; then 24004 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of XATTR from the environment. Use command line variables instead." >&5 24005 $as_echo "$as_me: WARNING: Ignoring value of XATTR from the environment. Use command line variables instead." >&2;} 24006 fi 24007 # Try to locate tool using the code snippet 24008 for ac_prog in xattr 24009 do 24010 # Extract the first word of "$ac_prog", so it can be a program name with args. 24011 set dummy $ac_prog; ac_word=$2 24012 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 24013 $as_echo_n "checking for $ac_word... " >&6; } 24014 if ${ac_cv_path_XATTR+:} false; then : 24015 $as_echo_n "(cached) " >&6 24016 else 24017 case $XATTR in 24018 [\\/]* | ?:[\\/]*) 24019 ac_cv_path_XATTR="$XATTR" # Let the user override the test with a path. 24020 ;; 24021 *) 24022 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 24023 for as_dir in $PATH 24024 do 24025 IFS=$as_save_IFS 24026 test -z "$as_dir" && as_dir=. 24027 for ac_exec_ext in '' $ac_executable_extensions; do 24028 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 24029 ac_cv_path_XATTR="$as_dir/$ac_word$ac_exec_ext" 24030 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 24031 break 2 24032 fi 24033 done 24034 done 24035 IFS=$as_save_IFS 24036 24037 ;; 24038 esac 24039 fi 24040 XATTR=$ac_cv_path_XATTR 24041 if test -n "$XATTR"; then 24042 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $XATTR" >&5 24043 $as_echo "$XATTR" >&6; } 24044 else 24045 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 24046 $as_echo "no" >&6; } 24047 fi 24048 24049 24050 test -n "$XATTR" && break 24051 done 24052 24053 else 24054 # If it succeeded, then it was overridden by the user. We will use it 24055 # for the tool. 24056 24057 # First remove it from the list of overridden variables, so we can test 24058 # for unknown variables in the end. 24059 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 24060 24061 # Check if we try to supply an empty value 24062 if test "x$XATTR" = x; then 24063 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool XATTR= (no value)" >&5 24064 $as_echo "$as_me: Setting user supplied tool XATTR= (no value)" >&6;} 24065 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for XATTR" >&5 24066 $as_echo_n "checking for XATTR... " >&6; } 24067 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 24068 $as_echo "disabled" >&6; } 24069 else 24070 # Check if the provided tool contains a complete path. 24071 tool_specified="$XATTR" 24072 tool_basename="${tool_specified##*/}" 24073 if test "x$tool_basename" = "x$tool_specified"; then 24074 # A command without a complete path is provided, search $PATH. 24075 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool XATTR=$tool_basename" >&5 24076 $as_echo "$as_me: Will search for user supplied tool XATTR=$tool_basename" >&6;} 24077 # Extract the first word of "$tool_basename", so it can be a program name with args. 24078 set dummy $tool_basename; ac_word=$2 24079 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 24080 $as_echo_n "checking for $ac_word... " >&6; } 24081 if ${ac_cv_path_XATTR+:} false; then : 24082 $as_echo_n "(cached) " >&6 24083 else 24084 case $XATTR in 24085 [\\/]* | ?:[\\/]*) 24086 ac_cv_path_XATTR="$XATTR" # Let the user override the test with a path. 24087 ;; 24088 *) 24089 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 24090 for as_dir in $PATH 24091 do 24092 IFS=$as_save_IFS 24093 test -z "$as_dir" && as_dir=. 24094 for ac_exec_ext in '' $ac_executable_extensions; do 24095 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 24096 ac_cv_path_XATTR="$as_dir/$ac_word$ac_exec_ext" 24097 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 24098 break 2 24099 fi 24100 done 24101 done 24102 IFS=$as_save_IFS 24103 24104 ;; 24105 esac 24106 fi 24107 XATTR=$ac_cv_path_XATTR 24108 if test -n "$XATTR"; then 24109 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $XATTR" >&5 24110 $as_echo "$XATTR" >&6; } 24111 else 24112 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 24113 $as_echo "no" >&6; } 24114 fi 24115 24116 24117 if test "x$XATTR" = x; then 24118 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 24119 fi 24120 else 24121 # Otherwise we believe it is a complete path. Use it as it is. 24122 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool XATTR=$tool_specified" >&5 24123 $as_echo "$as_me: Will use user supplied tool XATTR=$tool_specified" >&6;} 24124 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for XATTR" >&5 24125 $as_echo_n "checking for XATTR... " >&6; } 24126 if test ! -x "$tool_specified"; then 24127 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 24128 $as_echo "not found" >&6; } 24129 as_fn_error $? "User supplied tool XATTR=$tool_specified does not exist or is not executable" "$LINENO" 5 24130 fi 24131 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 24132 $as_echo "$tool_specified" >&6; } 24133 fi 24134 fi 24135 fi 24136 24137 fi 24138 24139 24140 24141 if test "x$XATTR" = x; then 24142 as_fn_error $? "Could not find required tool for XATTR" "$LINENO" 5 24143 fi 24144 24145 24146 24147 24148 # Publish this variable in the help. 24149 24150 24151 if [ -z "${CODESIGN+x}" ]; then 24152 # The variable is not set by user, try to locate tool using the code snippet 24153 for ac_prog in codesign 24154 do 24155 # Extract the first word of "$ac_prog", so it can be a program name with args. 24156 set dummy $ac_prog; ac_word=$2 24157 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 24158 $as_echo_n "checking for $ac_word... " >&6; } 24159 if ${ac_cv_path_CODESIGN+:} false; then : 24160 $as_echo_n "(cached) " >&6 24161 else 24162 case $CODESIGN in 24163 [\\/]* | ?:[\\/]*) 24164 ac_cv_path_CODESIGN="$CODESIGN" # Let the user override the test with a path. 24165 ;; 24166 *) 24167 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 24168 for as_dir in $PATH 24169 do 24170 IFS=$as_save_IFS 24171 test -z "$as_dir" && as_dir=. 24172 for ac_exec_ext in '' $ac_executable_extensions; do 24173 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 24174 ac_cv_path_CODESIGN="$as_dir/$ac_word$ac_exec_ext" 24175 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 24176 break 2 24177 fi 24178 done 24179 done 24180 IFS=$as_save_IFS 24181 24182 ;; 24183 esac 24184 fi 24185 CODESIGN=$ac_cv_path_CODESIGN 24186 if test -n "$CODESIGN"; then 24187 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CODESIGN" >&5 24188 $as_echo "$CODESIGN" >&6; } 24189 else 24190 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 24191 $as_echo "no" >&6; } 24192 fi 24193 24194 24195 test -n "$CODESIGN" && break 24196 done 24197 24198 else 24199 # The variable is set, but is it from the command line or the environment? 24200 24201 # Try to remove the string !CODESIGN! from our list. 24202 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!CODESIGN!/} 24203 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 24204 # If it failed, the variable was not from the command line. Ignore it, 24205 # but warn the user (except for BASH, which is always set by the calling BASH). 24206 if test "xCODESIGN" != xBASH; then 24207 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of CODESIGN from the environment. Use command line variables instead." >&5 24208 $as_echo "$as_me: WARNING: Ignoring value of CODESIGN from the environment. Use command line variables instead." >&2;} 24209 fi 24210 # Try to locate tool using the code snippet 24211 for ac_prog in codesign 24212 do 24213 # Extract the first word of "$ac_prog", so it can be a program name with args. 24214 set dummy $ac_prog; ac_word=$2 24215 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 24216 $as_echo_n "checking for $ac_word... " >&6; } 24217 if ${ac_cv_path_CODESIGN+:} false; then : 24218 $as_echo_n "(cached) " >&6 24219 else 24220 case $CODESIGN in 24221 [\\/]* | ?:[\\/]*) 24222 ac_cv_path_CODESIGN="$CODESIGN" # Let the user override the test with a path. 24223 ;; 24224 *) 24225 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 24226 for as_dir in $PATH 24227 do 24228 IFS=$as_save_IFS 24229 test -z "$as_dir" && as_dir=. 24230 for ac_exec_ext in '' $ac_executable_extensions; do 24231 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 24232 ac_cv_path_CODESIGN="$as_dir/$ac_word$ac_exec_ext" 24233 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 24234 break 2 24235 fi 24236 done 24237 done 24238 IFS=$as_save_IFS 24239 24240 ;; 24241 esac 24242 fi 24243 CODESIGN=$ac_cv_path_CODESIGN 24244 if test -n "$CODESIGN"; then 24245 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CODESIGN" >&5 24246 $as_echo "$CODESIGN" >&6; } 24247 else 24248 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 24249 $as_echo "no" >&6; } 24250 fi 24251 24252 24253 test -n "$CODESIGN" && break 24254 done 24255 24256 else 24257 # If it succeeded, then it was overridden by the user. We will use it 24258 # for the tool. 24259 24260 # First remove it from the list of overridden variables, so we can test 24261 # for unknown variables in the end. 24262 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 24263 24264 # Check if we try to supply an empty value 24265 if test "x$CODESIGN" = x; then 24266 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool CODESIGN= (no value)" >&5 24267 $as_echo "$as_me: Setting user supplied tool CODESIGN= (no value)" >&6;} 24268 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for CODESIGN" >&5 24269 $as_echo_n "checking for CODESIGN... " >&6; } 24270 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 24271 $as_echo "disabled" >&6; } 24272 else 24273 # Check if the provided tool contains a complete path. 24274 tool_specified="$CODESIGN" 24275 tool_basename="${tool_specified##*/}" 24276 if test "x$tool_basename" = "x$tool_specified"; then 24277 # A command without a complete path is provided, search $PATH. 24278 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool CODESIGN=$tool_basename" >&5 24279 $as_echo "$as_me: Will search for user supplied tool CODESIGN=$tool_basename" >&6;} 24280 # Extract the first word of "$tool_basename", so it can be a program name with args. 24281 set dummy $tool_basename; ac_word=$2 24282 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 24283 $as_echo_n "checking for $ac_word... " >&6; } 24284 if ${ac_cv_path_CODESIGN+:} false; then : 24285 $as_echo_n "(cached) " >&6 24286 else 24287 case $CODESIGN in 24288 [\\/]* | ?:[\\/]*) 24289 ac_cv_path_CODESIGN="$CODESIGN" # Let the user override the test with a path. 24290 ;; 24291 *) 24292 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 24293 for as_dir in $PATH 24294 do 24295 IFS=$as_save_IFS 24296 test -z "$as_dir" && as_dir=. 24297 for ac_exec_ext in '' $ac_executable_extensions; do 24298 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 24299 ac_cv_path_CODESIGN="$as_dir/$ac_word$ac_exec_ext" 24300 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 24301 break 2 24302 fi 24303 done 24304 done 24305 IFS=$as_save_IFS 24306 24307 ;; 24308 esac 24309 fi 24310 CODESIGN=$ac_cv_path_CODESIGN 24311 if test -n "$CODESIGN"; then 24312 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CODESIGN" >&5 24313 $as_echo "$CODESIGN" >&6; } 24314 else 24315 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 24316 $as_echo "no" >&6; } 24317 fi 24318 24319 24320 if test "x$CODESIGN" = x; then 24321 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 24322 fi 24323 else 24324 # Otherwise we believe it is a complete path. Use it as it is. 24325 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool CODESIGN=$tool_specified" >&5 24326 $as_echo "$as_me: Will use user supplied tool CODESIGN=$tool_specified" >&6;} 24327 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for CODESIGN" >&5 24328 $as_echo_n "checking for CODESIGN... " >&6; } 24329 if test ! -x "$tool_specified"; then 24330 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 24331 $as_echo "not found" >&6; } 24332 as_fn_error $? "User supplied tool CODESIGN=$tool_specified does not exist or is not executable" "$LINENO" 5 24333 fi 24334 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 24335 $as_echo "$tool_specified" >&6; } 24336 fi 24337 fi 24338 fi 24339 24340 fi 24341 24342 24343 if test "x$CODESIGN" != "x"; then 24344 # Verify that the openjdk_codesign certificate is present 24345 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if openjdk_codesign certificate is present" >&5 24346 $as_echo_n "checking if openjdk_codesign certificate is present... " >&6; } 24347 $RM codesign-testfile 24348 $TOUCH codesign-testfile 24349 $CODESIGN -s openjdk_codesign codesign-testfile 2>&5 >&5 || CODESIGN= 24350 $RM codesign-testfile 24351 if test "x$CODESIGN" = x; then 24352 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 24353 $as_echo "no" >&6; } 24354 else 24355 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 24356 $as_echo "yes" >&6; } 24357 fi 24358 fi 24359 24360 24361 24362 # Publish this variable in the help. 24363 24364 24365 if [ -z "${SETFILE+x}" ]; then 24366 # The variable is not set by user, try to locate tool using the code snippet 24367 for ac_prog in SetFile 24368 do 24369 # Extract the first word of "$ac_prog", so it can be a program name with args. 24370 set dummy $ac_prog; ac_word=$2 24371 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 24372 $as_echo_n "checking for $ac_word... " >&6; } 24373 if ${ac_cv_path_SETFILE+:} false; then : 24374 $as_echo_n "(cached) " >&6 24375 else 24376 case $SETFILE in 24377 [\\/]* | ?:[\\/]*) 24378 ac_cv_path_SETFILE="$SETFILE" # Let the user override the test with a path. 24379 ;; 24380 *) 24381 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 24382 for as_dir in $PATH 24383 do 24384 IFS=$as_save_IFS 24385 test -z "$as_dir" && as_dir=. 24386 for ac_exec_ext in '' $ac_executable_extensions; do 24387 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 24388 ac_cv_path_SETFILE="$as_dir/$ac_word$ac_exec_ext" 24389 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 24390 break 2 24391 fi 24392 done 24393 done 24394 IFS=$as_save_IFS 24395 24396 ;; 24397 esac 24398 fi 24399 SETFILE=$ac_cv_path_SETFILE 24400 if test -n "$SETFILE"; then 24401 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $SETFILE" >&5 24402 $as_echo "$SETFILE" >&6; } 24403 else 24404 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 24405 $as_echo "no" >&6; } 24406 fi 24407 24408 24409 test -n "$SETFILE" && break 24410 done 24411 24412 else 24413 # The variable is set, but is it from the command line or the environment? 24414 24415 # Try to remove the string !SETFILE! from our list. 24416 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!SETFILE!/} 24417 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 24418 # If it failed, the variable was not from the command line. Ignore it, 24419 # but warn the user (except for BASH, which is always set by the calling BASH). 24420 if test "xSETFILE" != xBASH; then 24421 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of SETFILE from the environment. Use command line variables instead." >&5 24422 $as_echo "$as_me: WARNING: Ignoring value of SETFILE from the environment. Use command line variables instead." >&2;} 24423 fi 24424 # Try to locate tool using the code snippet 24425 for ac_prog in SetFile 24426 do 24427 # Extract the first word of "$ac_prog", so it can be a program name with args. 24428 set dummy $ac_prog; ac_word=$2 24429 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 24430 $as_echo_n "checking for $ac_word... " >&6; } 24431 if ${ac_cv_path_SETFILE+:} false; then : 24432 $as_echo_n "(cached) " >&6 24433 else 24434 case $SETFILE in 24435 [\\/]* | ?:[\\/]*) 24436 ac_cv_path_SETFILE="$SETFILE" # Let the user override the test with a path. 24437 ;; 24438 *) 24439 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 24440 for as_dir in $PATH 24441 do 24442 IFS=$as_save_IFS 24443 test -z "$as_dir" && as_dir=. 24444 for ac_exec_ext in '' $ac_executable_extensions; do 24445 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 24446 ac_cv_path_SETFILE="$as_dir/$ac_word$ac_exec_ext" 24447 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 24448 break 2 24449 fi 24450 done 24451 done 24452 IFS=$as_save_IFS 24453 24454 ;; 24455 esac 24456 fi 24457 SETFILE=$ac_cv_path_SETFILE 24458 if test -n "$SETFILE"; then 24459 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $SETFILE" >&5 24460 $as_echo "$SETFILE" >&6; } 24461 else 24462 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 24463 $as_echo "no" >&6; } 24464 fi 24465 24466 24467 test -n "$SETFILE" && break 24468 done 24469 24470 else 24471 # If it succeeded, then it was overridden by the user. We will use it 24472 # for the tool. 24473 24474 # First remove it from the list of overridden variables, so we can test 24475 # for unknown variables in the end. 24476 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 24477 24478 # Check if we try to supply an empty value 24479 if test "x$SETFILE" = x; then 24480 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool SETFILE= (no value)" >&5 24481 $as_echo "$as_me: Setting user supplied tool SETFILE= (no value)" >&6;} 24482 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for SETFILE" >&5 24483 $as_echo_n "checking for SETFILE... " >&6; } 24484 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 24485 $as_echo "disabled" >&6; } 24486 else 24487 # Check if the provided tool contains a complete path. 24488 tool_specified="$SETFILE" 24489 tool_basename="${tool_specified##*/}" 24490 if test "x$tool_basename" = "x$tool_specified"; then 24491 # A command without a complete path is provided, search $PATH. 24492 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool SETFILE=$tool_basename" >&5 24493 $as_echo "$as_me: Will search for user supplied tool SETFILE=$tool_basename" >&6;} 24494 # Extract the first word of "$tool_basename", so it can be a program name with args. 24495 set dummy $tool_basename; ac_word=$2 24496 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 24497 $as_echo_n "checking for $ac_word... " >&6; } 24498 if ${ac_cv_path_SETFILE+:} false; then : 24499 $as_echo_n "(cached) " >&6 24500 else 24501 case $SETFILE in 24502 [\\/]* | ?:[\\/]*) 24503 ac_cv_path_SETFILE="$SETFILE" # Let the user override the test with a path. 24504 ;; 24505 *) 24506 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 24507 for as_dir in $PATH 24508 do 24509 IFS=$as_save_IFS 24510 test -z "$as_dir" && as_dir=. 24511 for ac_exec_ext in '' $ac_executable_extensions; do 24512 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 24513 ac_cv_path_SETFILE="$as_dir/$ac_word$ac_exec_ext" 24514 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 24515 break 2 24516 fi 24517 done 24518 done 24519 IFS=$as_save_IFS 24520 24521 ;; 24522 esac 24523 fi 24524 SETFILE=$ac_cv_path_SETFILE 24525 if test -n "$SETFILE"; then 24526 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $SETFILE" >&5 24527 $as_echo "$SETFILE" >&6; } 24528 else 24529 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 24530 $as_echo "no" >&6; } 24531 fi 24532 24533 24534 if test "x$SETFILE" = x; then 24535 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 24536 fi 24537 else 24538 # Otherwise we believe it is a complete path. Use it as it is. 24539 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool SETFILE=$tool_specified" >&5 24540 $as_echo "$as_me: Will use user supplied tool SETFILE=$tool_specified" >&6;} 24541 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for SETFILE" >&5 24542 $as_echo_n "checking for SETFILE... " >&6; } 24543 if test ! -x "$tool_specified"; then 24544 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 24545 $as_echo "not found" >&6; } 24546 as_fn_error $? "User supplied tool SETFILE=$tool_specified does not exist or is not executable" "$LINENO" 5 24547 fi 24548 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 24549 $as_echo "$tool_specified" >&6; } 24550 fi 24551 fi 24552 fi 24553 24554 fi 24555 24556 24557 24558 if test "x$SETFILE" = x; then 24559 as_fn_error $? "Could not find required tool for SETFILE" "$LINENO" 5 24560 fi 24561 24562 24563 fi 24564 24565 24566 # Check bash version 24567 # Extra [ ] to stop m4 mangling 24568 BASH_VER=`$BASH --version | $SED -n -e 's/^.*bash.*ersion *\([0-9.]*\).*$/\1/ p'` 24569 { $as_echo "$as_me:${as_lineno-$LINENO}: checking bash version" >&5 24570 $as_echo_n "checking bash version... " >&6; } 24571 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BASH_VER" >&5 24572 $as_echo "$BASH_VER" >&6; } 24573 24574 BASH_MAJOR=`$ECHO $BASH_VER | $CUT -d . -f 1` 24575 BASH_MINOR=`$ECHO $BASH_VER | $CUT -d . -f 2` 24576 if test $BASH_MAJOR -lt 3 || (test $BASH_MAJOR -eq 3 && test $BASH_MINOR -lt 2); then 24577 as_fn_error $? "bash version 3.2 or better is required" "$LINENO" 5 24578 fi 24579 24580 # Test if bash supports pipefail. 24581 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if bash supports pipefail" >&5 24582 $as_echo_n "checking if bash supports pipefail... " >&6; } 24583 if ${BASH} -c 'set -o pipefail'; then 24584 BASH_ARGS="$BASH_ARGS -o pipefail" 24585 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 24586 $as_echo "yes" >&6; } 24587 else 24588 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 24589 $as_echo "no" >&6; } 24590 fi 24591 24592 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if bash supports errexit (-e)" >&5 24593 $as_echo_n "checking if bash supports errexit (-e)... " >&6; } 24594 if ${BASH} -e -c 'true'; then 24595 BASH_ARGS="$BASH_ARGS -e" 24596 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 24597 $as_echo "yes" >&6; } 24598 else 24599 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 24600 $as_echo "no" >&6; } 24601 fi 24602 24603 24604 24605 24606 # Check if pkg-config is available. 24607 24608 24609 if test "x$ac_cv_env_PKG_CONFIG_set" != "xset"; then 24610 if test -n "$ac_tool_prefix"; then 24611 # Extract the first word of "${ac_tool_prefix}pkg-config", so it can be a program name with args. 24612 set dummy ${ac_tool_prefix}pkg-config; ac_word=$2 24613 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 24614 $as_echo_n "checking for $ac_word... " >&6; } 24615 if ${ac_cv_path_PKG_CONFIG+:} false; then : 24616 $as_echo_n "(cached) " >&6 24617 else 24618 case $PKG_CONFIG in 24619 [\\/]* | ?:[\\/]*) 24620 ac_cv_path_PKG_CONFIG="$PKG_CONFIG" # Let the user override the test with a path. 24621 ;; 24622 *) 24623 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 24624 for as_dir in $PATH 24625 do 24626 IFS=$as_save_IFS 24627 test -z "$as_dir" && as_dir=. 24628 for ac_exec_ext in '' $ac_executable_extensions; do 24629 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 24630 ac_cv_path_PKG_CONFIG="$as_dir/$ac_word$ac_exec_ext" 24631 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 24632 break 2 24633 fi 24634 done 24635 done 24636 IFS=$as_save_IFS 24637 24638 ;; 24639 esac 24640 fi 24641 PKG_CONFIG=$ac_cv_path_PKG_CONFIG 24642 if test -n "$PKG_CONFIG"; then 24643 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $PKG_CONFIG" >&5 24644 $as_echo "$PKG_CONFIG" >&6; } 24645 else 24646 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 24647 $as_echo "no" >&6; } 24648 fi 24649 24650 24651 fi 24652 if test -z "$ac_cv_path_PKG_CONFIG"; then 24653 ac_pt_PKG_CONFIG=$PKG_CONFIG 24654 # Extract the first word of "pkg-config", so it can be a program name with args. 24655 set dummy pkg-config; ac_word=$2 24656 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 24657 $as_echo_n "checking for $ac_word... " >&6; } 24658 if ${ac_cv_path_ac_pt_PKG_CONFIG+:} false; then : 24659 $as_echo_n "(cached) " >&6 24660 else 24661 case $ac_pt_PKG_CONFIG in 24662 [\\/]* | ?:[\\/]*) 24663 ac_cv_path_ac_pt_PKG_CONFIG="$ac_pt_PKG_CONFIG" # Let the user override the test with a path. 24664 ;; 24665 *) 24666 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 24667 for as_dir in $PATH 24668 do 24669 IFS=$as_save_IFS 24670 test -z "$as_dir" && as_dir=. 24671 for ac_exec_ext in '' $ac_executable_extensions; do 24672 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 24673 ac_cv_path_ac_pt_PKG_CONFIG="$as_dir/$ac_word$ac_exec_ext" 24674 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 24675 break 2 24676 fi 24677 done 24678 done 24679 IFS=$as_save_IFS 24680 24681 ;; 24682 esac 24683 fi 24684 ac_pt_PKG_CONFIG=$ac_cv_path_ac_pt_PKG_CONFIG 24685 if test -n "$ac_pt_PKG_CONFIG"; then 24686 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_pt_PKG_CONFIG" >&5 24687 $as_echo "$ac_pt_PKG_CONFIG" >&6; } 24688 else 24689 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 24690 $as_echo "no" >&6; } 24691 fi 24692 24693 if test "x$ac_pt_PKG_CONFIG" = x; then 24694 PKG_CONFIG="" 24695 else 24696 case $cross_compiling:$ac_tool_warned in 24697 yes:) 24698 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5 24699 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;} 24700 ac_tool_warned=yes ;; 24701 esac 24702 PKG_CONFIG=$ac_pt_PKG_CONFIG 24703 fi 24704 else 24705 PKG_CONFIG="$ac_cv_path_PKG_CONFIG" 24706 fi 24707 24708 fi 24709 if test -n "$PKG_CONFIG"; then 24710 _pkg_min_version=0.9.0 24711 { $as_echo "$as_me:${as_lineno-$LINENO}: checking pkg-config is at least version $_pkg_min_version" >&5 24712 $as_echo_n "checking pkg-config is at least version $_pkg_min_version... " >&6; } 24713 if $PKG_CONFIG --atleast-pkgconfig-version $_pkg_min_version; then 24714 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 24715 $as_echo "yes" >&6; } 24716 else 24717 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 24718 $as_echo "no" >&6; } 24719 PKG_CONFIG="" 24720 fi 24721 24722 fi 24723 24724 # After basic tools have been setup, we can check build os specific details. 24725 24726 ############################################################################### 24727 24728 # Note that this is the build platform OS version! 24729 24730 OS_VERSION="`uname -r | ${SED} 's!\.! !g' | ${SED} 's!-! !g'`" 24731 OS_VERSION_MAJOR="`${ECHO} ${OS_VERSION} | ${CUT} -f 1 -d ' '`" 24732 OS_VERSION_MINOR="`${ECHO} ${OS_VERSION} | ${CUT} -f 2 -d ' '`" 24733 OS_VERSION_MICRO="`${ECHO} ${OS_VERSION} | ${CUT} -f 3 -d ' '`" 24734 24735 24736 24737 24738 24739 # Misc basic settings 24740 24741 24742 # Check whether --with-default-make-target was given. 24743 if test "${with_default_make_target+set}" = set; then : 24744 withval=$with_default_make_target; 24745 fi 24746 24747 if test "x$with_default_make_target" = "x" \ 24748 || test "x$with_default_make_target" = "xyes"; then 24749 DEFAULT_MAKE_TARGET="exploded-image" 24750 elif test "x$with_default_make_target" = "xno"; then 24751 as_fn_error $? "--without-default-make-target is not a valid option" "$LINENO" 5 24752 else 24753 DEFAULT_MAKE_TARGET="$with_default_make_target" 24754 fi 24755 24756 24757 24758 24759 ############################################################################### 24760 # 24761 # Determine OpenJDK variants, options and version numbers. 24762 # 24763 ############################################################################### 24764 24765 # We need build & target for this. 24766 24767 # Should we build a JDK without a graphical UI? 24768 { $as_echo "$as_me:${as_lineno-$LINENO}: checking headless only" >&5 24769 $as_echo_n "checking headless only... " >&6; } 24770 # Check whether --enable-headless-only was given. 24771 if test "${enable_headless_only+set}" = set; then : 24772 enableval=$enable_headless_only; 24773 fi 24774 24775 24776 if test "x$enable_headless_only" = "xyes"; then 24777 ENABLE_HEADLESS_ONLY="true" 24778 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 24779 $as_echo "yes" >&6; } 24780 elif test "x$enable_headless_only" = "xno"; then 24781 ENABLE_HEADLESS_ONLY="false" 24782 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 24783 $as_echo "no" >&6; } 24784 elif test "x$enable_headless_only" = "x"; then 24785 ENABLE_HEADLESS_ONLY="false" 24786 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 24787 $as_echo "no" >&6; } 24788 else 24789 as_fn_error $? "--enable-headless-only can only take yes or no" "$LINENO" 5 24790 fi 24791 24792 24793 24794 # Should we build the complete docs, or just a lightweight version? 24795 # Check whether --enable-full-docs was given. 24796 if test "${enable_full_docs+set}" = set; then : 24797 enableval=$enable_full_docs; 24798 fi 24799 24800 24801 # Verify dependencies 24802 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for graphviz dot" >&5 24803 $as_echo_n "checking for graphviz dot... " >&6; } 24804 if test "x$DOT" != "x"; then 24805 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 24806 $as_echo "yes" >&6; } 24807 else 24808 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no, cannot generate full docs" >&5 24809 $as_echo "no, cannot generate full docs" >&6; } 24810 FULL_DOCS_DEP_MISSING=true 24811 fi 24812 24813 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for pandoc" >&5 24814 $as_echo_n "checking for pandoc... " >&6; } 24815 if test "x$PANDOC" != "x"; then 24816 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 24817 $as_echo "yes" >&6; } 24818 else 24819 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no, cannot generate full docs" >&5 24820 $as_echo "no, cannot generate full docs" >&6; } 24821 FULL_DOCS_DEP_MISSING=true 24822 fi 24823 24824 { $as_echo "$as_me:${as_lineno-$LINENO}: checking full docs" >&5 24825 $as_echo_n "checking full docs... " >&6; } 24826 if test "x$enable_full_docs" = xyes; then 24827 if test "x$FULL_DOCS_DEP_MISSING" = "xtrue"; then 24828 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no, missing dependencies" >&5 24829 $as_echo "no, missing dependencies" >&6; } 24830 24831 # Print a helpful message on how to acquire the necessary build dependency. 24832 # dot is the help tag: freetype, cups, alsa etc 24833 MISSING_DEPENDENCY=dot 24834 24835 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 24836 cygwin_help $MISSING_DEPENDENCY 24837 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 24838 msys_help $MISSING_DEPENDENCY 24839 else 24840 PKGHANDLER_COMMAND= 24841 24842 case $PKGHANDLER in 24843 apt-get) 24844 apt_help $MISSING_DEPENDENCY ;; 24845 yum) 24846 yum_help $MISSING_DEPENDENCY ;; 24847 brew) 24848 brew_help $MISSING_DEPENDENCY ;; 24849 port) 24850 port_help $MISSING_DEPENDENCY ;; 24851 pkgutil) 24852 pkgutil_help $MISSING_DEPENDENCY ;; 24853 pkgadd) 24854 pkgadd_help $MISSING_DEPENDENCY ;; 24855 esac 24856 24857 if test "x$PKGHANDLER_COMMAND" != x; then 24858 HELP_MSG="You might be able to fix this by running '$PKGHANDLER_COMMAND'." 24859 fi 24860 fi 24861 24862 as_fn_error $? "Cannot enable full docs with missing dependencies. See above. $HELP_MSG" "$LINENO" 5 24863 else 24864 ENABLE_FULL_DOCS=true 24865 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes, forced" >&5 24866 $as_echo "yes, forced" >&6; } 24867 fi 24868 elif test "x$enable_full_docs" = xno; then 24869 ENABLE_FULL_DOCS=false 24870 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no, forced" >&5 24871 $as_echo "no, forced" >&6; } 24872 elif test "x$enable_full_docs" = x; then 24873 # Check for prerequisites 24874 if test "x$FULL_DOCS_DEP_MISSING" = xtrue; then 24875 ENABLE_FULL_DOCS=false 24876 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no, missing dependencies" >&5 24877 $as_echo "no, missing dependencies" >&6; } 24878 else 24879 ENABLE_FULL_DOCS=true 24880 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes, dependencies present" >&5 24881 $as_echo "yes, dependencies present" >&6; } 24882 fi 24883 else 24884 as_fn_error $? "--enable-full-docs can only take yes or no" "$LINENO" 5 24885 fi 24886 24887 24888 24889 # Choose cacerts source file 24890 24891 # Check whether --with-cacerts-file was given. 24892 if test "${with_cacerts_file+set}" = set; then : 24893 withval=$with_cacerts_file; 24894 fi 24895 24896 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for cacerts file" >&5 24897 $as_echo_n "checking for cacerts file... " >&6; } 24898 if test "x$with_cacerts_file" == x; then 24899 { $as_echo "$as_me:${as_lineno-$LINENO}: result: default" >&5 24900 $as_echo "default" >&6; } 24901 else 24902 CACERTS_FILE=$with_cacerts_file 24903 if test ! -f "$CACERTS_FILE"; then 24904 { $as_echo "$as_me:${as_lineno-$LINENO}: result: fail" >&5 24905 $as_echo "fail" >&6; } 24906 as_fn_error $? "Specified cacerts file \"$CACERTS_FILE\" does not exist" "$LINENO" 5 24907 fi 24908 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CACERTS_FILE" >&5 24909 $as_echo "$CACERTS_FILE" >&6; } 24910 fi 24911 24912 24913 # Enable or disable unlimited crypto 24914 # Check whether --enable-unlimited-crypto was given. 24915 if test "${enable_unlimited_crypto+set}" = set; then : 24916 enableval=$enable_unlimited_crypto; 24917 else 24918 enable_unlimited_crypto=yes 24919 fi 24920 24921 if test "x$enable_unlimited_crypto" = "xyes"; then 24922 UNLIMITED_CRYPTO=true 24923 else 24924 UNLIMITED_CRYPTO=false 24925 fi 24926 24927 24928 # Should we build the serviceability agent (SA)? 24929 INCLUDE_SA=true 24930 if [[ " $JVM_VARIANTS " =~ " zero " ]] ; then 24931 INCLUDE_SA=false 24932 fi 24933 if test "x$OPENJDK_TARGET_OS" = xaix ; then 24934 INCLUDE_SA=false 24935 fi 24936 24937 24938 # Compress jars 24939 COMPRESS_JARS=false 24940 24941 24942 24943 # Setup default copyright year. Mostly overridden when building close to a new year. 24944 24945 # Check whether --with-copyright-year was given. 24946 if test "${with_copyright_year+set}" = set; then : 24947 withval=$with_copyright_year; 24948 fi 24949 24950 if test "x$with_copyright_year" = xyes; then 24951 as_fn_error $? "Copyright year must have a value" "$LINENO" 5 24952 elif test "x$with_copyright_year" != x; then 24953 COPYRIGHT_YEAR="$with_copyright_year" 24954 else 24955 COPYRIGHT_YEAR=`$DATE +'%Y'` 24956 fi 24957 24958 24959 24960 # Check whether --enable-keep-packaged-modules was given. 24961 if test "${enable_keep_packaged_modules+set}" = set; then : 24962 enableval=$enable_keep_packaged_modules; 24963 fi 24964 24965 24966 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if packaged modules are kept" >&5 24967 $as_echo_n "checking if packaged modules are kept... " >&6; } 24968 if test "x$enable_keep_packaged_modules" = "xyes"; then 24969 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 24970 $as_echo "yes" >&6; } 24971 JLINK_KEEP_PACKAGED_MODULES=true 24972 elif test "x$enable_keep_packaged_modules" = "xno"; then 24973 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 24974 $as_echo "no" >&6; } 24975 JLINK_KEEP_PACKAGED_MODULES=false 24976 elif test "x$enable_keep_packaged_modules" = "x"; then 24977 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes (default)" >&5 24978 $as_echo "yes (default)" >&6; } 24979 JLINK_KEEP_PACKAGED_MODULES=true 24980 else 24981 { $as_echo "$as_me:${as_lineno-$LINENO}: result: error" >&5 24982 $as_echo "error" >&6; } 24983 as_fn_error $? "--enable-keep-packaged-modules accepts no argument" "$LINENO" 5 24984 fi 24985 24986 24987 24988 24989 # Warn user that old version arguments are deprecated. 24990 24991 24992 # Check whether --with-milestone was given. 24993 if test "${with_milestone+set}" = set; then : 24994 withval=$with_milestone; { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Option --with-milestone is deprecated and will be ignored." >&5 24995 $as_echo "$as_me: WARNING: Option --with-milestone is deprecated and will be ignored." >&2;} 24996 fi 24997 24998 24999 25000 25001 # Check whether --with-update-version was given. 25002 if test "${with_update_version+set}" = set; then : 25003 withval=$with_update_version; { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Option --with-update-version is deprecated and will be ignored." >&5 25004 $as_echo "$as_me: WARNING: Option --with-update-version is deprecated and will be ignored." >&2;} 25005 fi 25006 25007 25008 25009 25010 # Check whether --with-user-release-suffix was given. 25011 if test "${with_user_release_suffix+set}" = set; then : 25012 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 25013 $as_echo "$as_me: WARNING: Option --with-user-release-suffix is deprecated and will be ignored." >&2;} 25014 fi 25015 25016 25017 25018 25019 # Check whether --with-build-number was given. 25020 if test "${with_build_number+set}" = set; then : 25021 withval=$with_build_number; { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Option --with-build-number is deprecated and will be ignored." >&5 25022 $as_echo "$as_me: WARNING: Option --with-build-number is deprecated and will be ignored." >&2;} 25023 fi 25024 25025 25026 25027 25028 # Check whether --with-version-major was given. 25029 if test "${with_version_major+set}" = set; then : 25030 withval=$with_version_major; { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Option --with-version-major is deprecated and will be ignored." >&5 25031 $as_echo "$as_me: WARNING: Option --with-version-major is deprecated and will be ignored." >&2;} 25032 fi 25033 25034 25035 25036 25037 # Check whether --with-version-minor was given. 25038 if test "${with_version_minor+set}" = set; then : 25039 withval=$with_version_minor; { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Option --with-version-minor is deprecated and will be ignored." >&5 25040 $as_echo "$as_me: WARNING: Option --with-version-minor is deprecated and will be ignored." >&2;} 25041 fi 25042 25043 25044 25045 25046 # Check whether --with-version-security was given. 25047 if test "${with_version_security+set}" = set; then : 25048 withval=$with_version_security; { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Option --with-version-security is deprecated and will be ignored." >&5 25049 $as_echo "$as_me: WARNING: Option --with-version-security is deprecated and will be ignored." >&2;} 25050 fi 25051 25052 25053 25054 # Source the version numbers file 25055 . $AUTOCONF_DIR/version-numbers 25056 25057 # Some non-version number information is set in that file 25058 25059 25060 25061 25062 25063 25064 25065 25066 25067 # Override version from arguments 25068 25069 # If --with-version-string is set, process it first. It is possible to 25070 # override parts with more specific flags, since these are processed later. 25071 25072 # Check whether --with-version-string was given. 25073 if test "${with_version_string+set}" = set; then : 25074 withval=$with_version_string; 25075 fi 25076 25077 if test "x$with_version_string" = xyes; then 25078 as_fn_error $? "--with-version-string must have a value" "$LINENO" 5 25079 elif test "x$with_version_string" != x; then 25080 # Additional [] needed to keep m4 from mangling shell constructs. 25081 if [[ $with_version_string =~ ^([0-9]+)(\.([0-9]+))?(\.([0-9]+))?(\.([0-9]+))?(-([a-zA-Z]+))?((\+)([0-9]+)?(-([-a-zA-Z0-9.]+))?)?$ ]] ; then 25082 VERSION_FEATURE=${BASH_REMATCH[1]} 25083 VERSION_INTERIM=${BASH_REMATCH[3]} 25084 VERSION_UPDATE=${BASH_REMATCH[5]} 25085 VERSION_PATCH=${BASH_REMATCH[7]} 25086 VERSION_PRE=${BASH_REMATCH[9]} 25087 version_plus_separator=${BASH_REMATCH[11]} 25088 VERSION_BUILD=${BASH_REMATCH[12]} 25089 VERSION_OPT=${BASH_REMATCH[14]} 25090 # Unspecified numerical fields are interpreted as 0. 25091 if test "x$VERSION_INTERIM" = x; then 25092 VERSION_INTERIM=0 25093 fi 25094 if test "x$VERSION_UPDATE" = x; then 25095 VERSION_UPDATE=0 25096 fi 25097 if test "x$VERSION_PATCH" = x; then 25098 VERSION_PATCH=0 25099 fi 25100 if test "x$version_plus_separator" != x \ 25101 && test "x$VERSION_BUILD$VERSION_OPT" = x; then 25102 as_fn_error $? "Version string contains + but both 'BUILD' and 'OPT' are missing" "$LINENO" 5 25103 fi 25104 # Stop the version part process from setting default values. 25105 # We still allow them to explicitly override though. 25106 NO_DEFAULT_VERSION_PARTS=true 25107 else 25108 as_fn_error $? "--with-version-string fails to parse as a valid version string: $with_version_string" "$LINENO" 5 25109 fi 25110 fi 25111 25112 25113 # Check whether --with-version-pre was given. 25114 if test "${with_version_pre+set}" = set; then : 25115 withval=$with_version_pre; with_version_pre_present=true 25116 else 25117 with_version_pre_present=false 25118 fi 25119 25120 25121 if test "x$with_version_pre_present" = xtrue; then 25122 if test "x$with_version_pre" = xyes; then 25123 as_fn_error $? "--with-version-pre must have a value" "$LINENO" 5 25124 elif test "x$with_version_pre" = xno; then 25125 # Interpret --without-* as empty string instead of the literal "no" 25126 VERSION_PRE= 25127 else 25128 # Only [a-zA-Z] is allowed in the VERSION_PRE. Outer [ ] to quote m4. 25129 VERSION_PRE=`$ECHO "$with_version_pre" | $TR -c -d '[a-z][A-Z]'` 25130 if test "x$VERSION_PRE" != "x$with_version_pre"; then 25131 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: --with-version-pre value has been sanitized from '$with_version_pre' to '$VERSION_PRE'" >&5 25132 $as_echo "$as_me: WARNING: --with-version-pre value has been sanitized from '$with_version_pre' to '$VERSION_PRE'" >&2;} 25133 fi 25134 fi 25135 else 25136 if test "x$NO_DEFAULT_VERSION_PARTS" != xtrue; then 25137 # Default is to use "internal" as pre 25138 VERSION_PRE="internal" 25139 fi 25140 fi 25141 25142 25143 # Check whether --with-version-opt was given. 25144 if test "${with_version_opt+set}" = set; then : 25145 withval=$with_version_opt; with_version_opt_present=true 25146 else 25147 with_version_opt_present=false 25148 fi 25149 25150 25151 if test "x$with_version_opt_present" = xtrue; then 25152 if test "x$with_version_opt" = xyes; then 25153 as_fn_error $? "--with-version-opt must have a value" "$LINENO" 5 25154 elif test "x$with_version_opt" = xno; then 25155 # Interpret --without-* as empty string instead of the literal "no" 25156 VERSION_OPT= 25157 else 25158 # Only [-.a-zA-Z0-9] is allowed in the VERSION_OPT. Outer [ ] to quote m4. 25159 VERSION_OPT=`$ECHO "$with_version_opt" | $TR -c -d '[a-z][A-Z][0-9].-'` 25160 if test "x$VERSION_OPT" != "x$with_version_opt"; then 25161 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: --with-version-opt value has been sanitized from '$with_version_opt' to '$VERSION_OPT'" >&5 25162 $as_echo "$as_me: WARNING: --with-version-opt value has been sanitized from '$with_version_opt' to '$VERSION_OPT'" >&2;} 25163 fi 25164 fi 25165 else 25166 if test "x$NO_DEFAULT_VERSION_PARTS" != xtrue; then 25167 # Default is to calculate a string like this 'adhoc.<username>.<base dir name>' 25168 # Outer [ ] to quote m4. 25169 basedirname=`$BASENAME "$TOPDIR" | $TR -d -c '[a-z][A-Z][0-9].-'` 25170 VERSION_OPT="adhoc.$USERNAME.$basedirname" 25171 fi 25172 fi 25173 25174 25175 # Check whether --with-version-build was given. 25176 if test "${with_version_build+set}" = set; then : 25177 withval=$with_version_build; with_version_build_present=true 25178 else 25179 with_version_build_present=false 25180 fi 25181 25182 25183 if test "x$with_version_build_present" = xtrue; then 25184 if test "x$with_version_build" = xyes; then 25185 as_fn_error $? "--with-version-build must have a value" "$LINENO" 5 25186 elif test "x$with_version_build" = xno; then 25187 # Interpret --without-* as empty string instead of the literal "no" 25188 VERSION_BUILD= 25189 elif test "x$with_version_build" = x; then 25190 VERSION_BUILD= 25191 else 25192 25193 # Additional [] needed to keep m4 from mangling shell constructs. 25194 if ! [[ "$with_version_build" =~ ^0*([1-9][0-9]*)|(0)$ ]] ; then 25195 as_fn_error $? "\"$with_version_build\" is not a valid numerical value for VERSION_BUILD" "$LINENO" 5 25196 fi 25197 # Extract the version number without leading zeros. 25198 cleaned_value=${BASH_REMATCH[1]} 25199 if test "x$cleaned_value" = x; then 25200 # Special case for zero 25201 cleaned_value=${BASH_REMATCH[2]} 25202 fi 25203 25204 if test $cleaned_value -gt 255; then 25205 as_fn_error $? "VERSION_BUILD is given as $with_version_build. This is greater than 255 which is not allowed." "$LINENO" 5 25206 fi 25207 if test "x$cleaned_value" != "x$with_version_build"; then 25208 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Value for VERSION_BUILD has been sanitized from '$with_version_build' to '$cleaned_value'" >&5 25209 $as_echo "$as_me: WARNING: Value for VERSION_BUILD has been sanitized from '$with_version_build' to '$cleaned_value'" >&2;} 25210 fi 25211 VERSION_BUILD=$cleaned_value 25212 25213 fi 25214 else 25215 if test "x$NO_DEFAULT_VERSION_PARTS" != xtrue; then 25216 # Default is to not have a build number. 25217 VERSION_BUILD="" 25218 # FIXME: Until all code can cope with an empty VERSION_BUILD, set it to 0. 25219 VERSION_BUILD=0 25220 fi 25221 fi 25222 25223 25224 # Check whether --with-version-feature was given. 25225 if test "${with_version_feature+set}" = set; then : 25226 withval=$with_version_feature; with_version_feature_present=true 25227 else 25228 with_version_feature_present=false 25229 fi 25230 25231 25232 if test "x$with_version_feature_present" = xtrue; then 25233 if test "x$with_version_feature" = xyes; then 25234 as_fn_error $? "--with-version-feature must have a value" "$LINENO" 5 25235 else 25236 25237 # Additional [] needed to keep m4 from mangling shell constructs. 25238 if ! [[ "$with_version_feature" =~ ^0*([1-9][0-9]*)|(0)$ ]] ; then 25239 as_fn_error $? "\"$with_version_feature\" is not a valid numerical value for VERSION_FEATURE" "$LINENO" 5 25240 fi 25241 # Extract the version number without leading zeros. 25242 cleaned_value=${BASH_REMATCH[1]} 25243 if test "x$cleaned_value" = x; then 25244 # Special case for zero 25245 cleaned_value=${BASH_REMATCH[2]} 25246 fi 25247 25248 if test $cleaned_value -gt 255; then 25249 as_fn_error $? "VERSION_FEATURE is given as $with_version_feature. This is greater than 255 which is not allowed." "$LINENO" 5 25250 fi 25251 if test "x$cleaned_value" != "x$with_version_feature"; then 25252 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Value for VERSION_FEATURE has been sanitized from '$with_version_feature' to '$cleaned_value'" >&5 25253 $as_echo "$as_me: WARNING: Value for VERSION_FEATURE has been sanitized from '$with_version_feature' to '$cleaned_value'" >&2;} 25254 fi 25255 VERSION_FEATURE=$cleaned_value 25256 25257 fi 25258 else 25259 if test "x$NO_DEFAULT_VERSION_PARTS" != xtrue; then 25260 # Default is to get value from version-numbers 25261 VERSION_FEATURE="$DEFAULT_VERSION_FEATURE" 25262 fi 25263 fi 25264 25265 25266 # Check whether --with-version-interim was given. 25267 if test "${with_version_interim+set}" = set; then : 25268 withval=$with_version_interim; with_version_interim_present=true 25269 else 25270 with_version_interim_present=false 25271 fi 25272 25273 25274 if test "x$with_version_interim_present" = xtrue; then 25275 if test "x$with_version_interim" = xyes; then 25276 as_fn_error $? "--with-version-interim must have a value" "$LINENO" 5 25277 elif test "x$with_version_interim" = xno; then 25278 # Interpret --without-* as empty string (i.e. 0) instead of the literal "no" 25279 VERSION_INTERIM=0 25280 elif test "x$with_version_interim" = x; then 25281 VERSION_INTERIM=0 25282 else 25283 25284 # Additional [] needed to keep m4 from mangling shell constructs. 25285 if ! [[ "$with_version_interim" =~ ^0*([1-9][0-9]*)|(0)$ ]] ; then 25286 as_fn_error $? "\"$with_version_interim\" is not a valid numerical value for VERSION_INTERIM" "$LINENO" 5 25287 fi 25288 # Extract the version number without leading zeros. 25289 cleaned_value=${BASH_REMATCH[1]} 25290 if test "x$cleaned_value" = x; then 25291 # Special case for zero 25292 cleaned_value=${BASH_REMATCH[2]} 25293 fi 25294 25295 if test $cleaned_value -gt 255; then 25296 as_fn_error $? "VERSION_INTERIM is given as $with_version_interim. This is greater than 255 which is not allowed." "$LINENO" 5 25297 fi 25298 if test "x$cleaned_value" != "x$with_version_interim"; then 25299 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Value for VERSION_INTERIM has been sanitized from '$with_version_interim' to '$cleaned_value'" >&5 25300 $as_echo "$as_me: WARNING: Value for VERSION_INTERIM has been sanitized from '$with_version_interim' to '$cleaned_value'" >&2;} 25301 fi 25302 VERSION_INTERIM=$cleaned_value 25303 25304 fi 25305 else 25306 if test "x$NO_DEFAULT_VERSION_PARTS" != xtrue; then 25307 # Default is 0, if unspecified 25308 VERSION_INTERIM=$DEFAULT_VERSION_INTERIM 25309 fi 25310 fi 25311 25312 25313 # Check whether --with-version-update was given. 25314 if test "${with_version_update+set}" = set; then : 25315 withval=$with_version_update; with_version_update_present=true 25316 else 25317 with_version_update_present=false 25318 fi 25319 25320 25321 if test "x$with_version_update_present" = xtrue; then 25322 if test "x$with_version_update" = xyes; then 25323 as_fn_error $? "--with-version-update must have a value" "$LINENO" 5 25324 elif test "x$with_version_update" = xno; then 25325 # Interpret --without-* as empty string (i.e. 0) instead of the literal "no" 25326 VERSION_UPDATE=0 25327 elif test "x$with_version_update" = x; then 25328 VERSION_UPDATE=0 25329 else 25330 25331 # Additional [] needed to keep m4 from mangling shell constructs. 25332 if ! [[ "$with_version_update" =~ ^0*([1-9][0-9]*)|(0)$ ]] ; then 25333 as_fn_error $? "\"$with_version_update\" is not a valid numerical value for VERSION_UPDATE" "$LINENO" 5 25334 fi 25335 # Extract the version number without leading zeros. 25336 cleaned_value=${BASH_REMATCH[1]} 25337 if test "x$cleaned_value" = x; then 25338 # Special case for zero 25339 cleaned_value=${BASH_REMATCH[2]} 25340 fi 25341 25342 if test $cleaned_value -gt 255; then 25343 as_fn_error $? "VERSION_UPDATE is given as $with_version_update. This is greater than 255 which is not allowed." "$LINENO" 5 25344 fi 25345 if test "x$cleaned_value" != "x$with_version_update"; then 25346 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Value for VERSION_UPDATE has been sanitized from '$with_version_update' to '$cleaned_value'" >&5 25347 $as_echo "$as_me: WARNING: Value for VERSION_UPDATE has been sanitized from '$with_version_update' to '$cleaned_value'" >&2;} 25348 fi 25349 VERSION_UPDATE=$cleaned_value 25350 25351 fi 25352 else 25353 if test "x$NO_DEFAULT_VERSION_PARTS" != xtrue; then 25354 # Default is 0, if unspecified 25355 VERSION_UPDATE=$DEFAULT_VERSION_UPDATE 25356 fi 25357 fi 25358 25359 25360 # Check whether --with-version-patch was given. 25361 if test "${with_version_patch+set}" = set; then : 25362 withval=$with_version_patch; with_version_patch_present=true 25363 else 25364 with_version_patch_present=false 25365 fi 25366 25367 25368 if test "x$with_version_patch_present" = xtrue; then 25369 if test "x$with_version_patch" = xyes; then 25370 as_fn_error $? "--with-version-patch must have a value" "$LINENO" 5 25371 elif test "x$with_version_patch" = xno; then 25372 # Interpret --without-* as empty string (i.e. 0) instead of the literal "no" 25373 VERSION_PATCH=0 25374 elif test "x$with_version_patch" = x; then 25375 VERSION_PATCH=0 25376 else 25377 25378 # Additional [] needed to keep m4 from mangling shell constructs. 25379 if ! [[ "$with_version_patch" =~ ^0*([1-9][0-9]*)|(0)$ ]] ; then 25380 as_fn_error $? "\"$with_version_patch\" is not a valid numerical value for VERSION_PATCH" "$LINENO" 5 25381 fi 25382 # Extract the version number without leading zeros. 25383 cleaned_value=${BASH_REMATCH[1]} 25384 if test "x$cleaned_value" = x; then 25385 # Special case for zero 25386 cleaned_value=${BASH_REMATCH[2]} 25387 fi 25388 25389 if test $cleaned_value -gt 255; then 25390 as_fn_error $? "VERSION_PATCH is given as $with_version_patch. This is greater than 255 which is not allowed." "$LINENO" 5 25391 fi 25392 if test "x$cleaned_value" != "x$with_version_patch"; then 25393 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Value for VERSION_PATCH has been sanitized from '$with_version_patch' to '$cleaned_value'" >&5 25394 $as_echo "$as_me: WARNING: Value for VERSION_PATCH has been sanitized from '$with_version_patch' to '$cleaned_value'" >&2;} 25395 fi 25396 VERSION_PATCH=$cleaned_value 25397 25398 fi 25399 else 25400 if test "x$NO_DEFAULT_VERSION_PARTS" != xtrue; then 25401 # Default is 0, if unspecified 25402 VERSION_PATCH=$DEFAULT_VERSION_PATCH 25403 fi 25404 fi 25405 25406 # Calculate derived version properties 25407 25408 # Set VERSION_IS_GA based on if VERSION_PRE has a value 25409 if test "x$VERSION_PRE" = x; then 25410 VERSION_IS_GA=true 25411 else 25412 VERSION_IS_GA=false 25413 fi 25414 25415 # VERSION_NUMBER but always with exactly 4 positions, with 0 for empty positions. 25416 VERSION_NUMBER_FOUR_POSITIONS=$VERSION_FEATURE.$VERSION_INTERIM.$VERSION_UPDATE.$VERSION_PATCH 25417 25418 stripped_version_number=$VERSION_NUMBER_FOUR_POSITIONS 25419 # Strip trailing zeroes from stripped_version_number 25420 for i in 1 2 3 ; do stripped_version_number=${stripped_version_number%.0} ; done 25421 VERSION_NUMBER=$stripped_version_number 25422 25423 # The complete version string, with additional build information 25424 if test "x$VERSION_BUILD$VERSION_OPT" = x; then 25425 VERSION_STRING=$VERSION_NUMBER${VERSION_PRE:+-$VERSION_PRE} 25426 else 25427 # If either build or opt is set, we need a + separator 25428 VERSION_STRING=$VERSION_NUMBER${VERSION_PRE:+-$VERSION_PRE}+$VERSION_BUILD${VERSION_OPT:+-$VERSION_OPT} 25429 fi 25430 25431 # The short version string, just VERSION_NUMBER and PRE, if present. 25432 VERSION_SHORT=$VERSION_NUMBER${VERSION_PRE:+-$VERSION_PRE} 25433 25434 # The version date 25435 25436 # Check whether --with-version-date was given. 25437 if test "${with_version_date+set}" = set; then : 25438 withval=$with_version_date; 25439 fi 25440 25441 if test "x$with_version_date" = xyes; then 25442 as_fn_error $? "--with-version-date must have a value" "$LINENO" 5 25443 elif test "x$with_version_date" != x; then 25444 if ! [[ $with_version_date =~ ^[0-9]{4}-[0-9]{2}-[0-9]{2}$ ]] ; then 25445 as_fn_error $? "\"$with_version_date\" is not a valid version date" "$LINENO" 5 25446 else 25447 VERSION_DATE="$with_version_date" 25448 fi 25449 else 25450 VERSION_DATE="$DEFAULT_VERSION_DATE" 25451 fi 25452 25453 # The vendor version string, if any 25454 25455 # Check whether --with-vendor-version-string was given. 25456 if test "${with_vendor_version_string+set}" = set; then : 25457 withval=$with_vendor_version_string; 25458 fi 25459 25460 if test "x$with_vendor_version_string" = xyes; then 25461 as_fn_error $? "--with-vendor-version-string must have a value" "$LINENO" 5 25462 elif ! [[ $with_vendor_version_string =~ ^[[:graph:]]*$ ]] ; then 25463 as_fn_error $? "--with--vendor-version-string contains non-graphical characters: $with_vendor_version_string" "$LINENO" 5 25464 else 25465 VENDOR_VERSION_STRING="$with_vendor_version_string" 25466 fi 25467 25468 # We could define --with flags for these, if really needed 25469 VERSION_CLASSFILE_MAJOR="$DEFAULT_VERSION_CLASSFILE_MAJOR" 25470 VERSION_CLASSFILE_MINOR="$DEFAULT_VERSION_CLASSFILE_MINOR" 25471 25472 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for version string" >&5 25473 $as_echo_n "checking for version string... " >&6; } 25474 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $VERSION_STRING" >&5 25475 $as_echo "$VERSION_STRING" >&6; } 25476 25477 25478 25479 25480 25481 25482 25483 25484 25485 25486 25487 25488 25489 25490 25491 25492 25493 25494 25495 25496 ############################################################################### 25497 # 25498 # Setup BootJDK, used to bootstrap the build. 25499 # 25500 ############################################################################### 25501 25502 25503 BOOT_JDK_FOUND=no 25504 25505 # Check whether --with-boot-jdk was given. 25506 if test "${with_boot_jdk+set}" = set; then : 25507 withval=$with_boot_jdk; 25508 fi 25509 25510 25511 # We look for the Boot JDK through various means, going from more certain to 25512 # more of a guess-work. After each test, BOOT_JDK_FOUND is set to "yes" if 25513 # we detected something (if so, the path to the jdk is in BOOT_JDK). But we 25514 # must check if this is indeed valid; otherwise we'll continue looking. 25515 25516 # Test: Is bootjdk explicitly set by command line arguments? 25517 25518 if test "x$BOOT_JDK_FOUND" = xno; then 25519 # Now execute the test 25520 25521 if test "x$with_boot_jdk" != x; then 25522 BOOT_JDK=$with_boot_jdk 25523 BOOT_JDK_FOUND=maybe 25524 { $as_echo "$as_me:${as_lineno-$LINENO}: Found potential Boot JDK using configure arguments" >&5 25525 $as_echo "$as_me: Found potential Boot JDK using configure arguments" >&6;} 25526 fi 25527 25528 25529 # If previous step claimed to have found a JDK, check it to see if it seems to be valid. 25530 if test "x$BOOT_JDK_FOUND" = xmaybe; then 25531 # Do we have a bin/java? 25532 if test ! -x "$BOOT_JDK/bin/java"; then 25533 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&5 25534 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&6;} 25535 BOOT_JDK_FOUND=no 25536 else 25537 # Do we have a bin/javac? 25538 if test ! -x "$BOOT_JDK/bin/javac"; then 25539 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&5 25540 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&6;} 25541 { $as_echo "$as_me:${as_lineno-$LINENO}: (This might be an JRE instead of an JDK)" >&5 25542 $as_echo "$as_me: (This might be an JRE instead of an JDK)" >&6;} 25543 BOOT_JDK_FOUND=no 25544 else 25545 # Oh, this is looking good! We probably have found a proper JDK. Is it the correct version? 25546 BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | $HEAD -n 1` 25547 25548 # Extra M4 quote needed to protect [] in grep expression. 25549 FOUND_CORRECT_VERSION=`$ECHO $BOOT_JDK_VERSION | $EGREP '\"10([\.+-].*)?\"|\"9([\.+-].*)?\"'` 25550 if test "x$FOUND_CORRECT_VERSION" = x; then 25551 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&5 25552 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&6;} 25553 { $as_echo "$as_me:${as_lineno-$LINENO}: (Your Boot JDK must be version 9 or 10)" >&5 25554 $as_echo "$as_me: (Your Boot JDK must be version 9 or 10)" >&6;} 25555 BOOT_JDK_FOUND=no 25556 else 25557 # We're done! :-) 25558 BOOT_JDK_FOUND=yes 25559 25560 # Only process if variable expands to non-empty 25561 25562 if test "x$BOOT_JDK" != x; then 25563 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 25564 25565 # Input might be given as Windows format, start by converting to 25566 # unix format. 25567 path="$BOOT_JDK" 25568 new_path=`$CYGPATH -u "$path"` 25569 25570 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 25571 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 25572 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 25573 # "foo.exe" is OK but "foo" is an error. 25574 # 25575 # This test is therefore slightly more accurate than "test -f" to check for file precense. 25576 # It is also a way to make sure we got the proper file name for the real test later on. 25577 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 25578 if test "x$test_shortpath" = x; then 25579 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5 25580 $as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;} 25581 as_fn_error $? "Cannot locate the the path of BOOT_JDK" "$LINENO" 5 25582 fi 25583 25584 # Call helper function which possibly converts this using DOS-style short mode. 25585 # If so, the updated path is stored in $new_path. 25586 25587 input_path="$new_path" 25588 # Check if we need to convert this using DOS-style short mode. If the path 25589 # contains just simple characters, use it. Otherwise (spaces, weird characters), 25590 # take no chances and rewrite it. 25591 # Note: m4 eats our [], so we need to use [ and ] instead. 25592 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 25593 if test "x$has_forbidden_chars" != x; then 25594 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 25595 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 25596 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 25597 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 25598 # Going to short mode and back again did indeed matter. Since short mode is 25599 # case insensitive, let's make it lowercase to improve readability. 25600 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 25601 # Now convert it back to Unix-style (cygpath) 25602 input_path=`$CYGPATH -u "$shortmode_path"` 25603 new_path="$input_path" 25604 fi 25605 fi 25606 25607 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 25608 if test "x$test_cygdrive_prefix" = x; then 25609 # As a simple fix, exclude /usr/bin since it's not a real path. 25610 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 25611 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 25612 # a path prefixed by /cygdrive for fixpath to work. 25613 new_path="$CYGWIN_ROOT_PATH$input_path" 25614 fi 25615 fi 25616 25617 25618 if test "x$path" != "x$new_path"; then 25619 BOOT_JDK="$new_path" 25620 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5 25621 $as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;} 25622 fi 25623 25624 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 25625 25626 path="$BOOT_JDK" 25627 has_colon=`$ECHO $path | $GREP ^.:` 25628 new_path="$path" 25629 if test "x$has_colon" = x; then 25630 # Not in mixed or Windows style, start by that. 25631 new_path=`cmd //c echo $path` 25632 fi 25633 25634 25635 input_path="$new_path" 25636 # Check if we need to convert this using DOS-style short mode. If the path 25637 # contains just simple characters, use it. Otherwise (spaces, weird characters), 25638 # take no chances and rewrite it. 25639 # Note: m4 eats our [], so we need to use [ and ] instead. 25640 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 25641 if test "x$has_forbidden_chars" != x; then 25642 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 25643 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 25644 fi 25645 25646 25647 windows_path="$new_path" 25648 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 25649 unix_path=`$CYGPATH -u "$windows_path"` 25650 new_path="$unix_path" 25651 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 25652 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 25653 new_path="$unix_path" 25654 fi 25655 25656 if test "x$path" != "x$new_path"; then 25657 BOOT_JDK="$new_path" 25658 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5 25659 $as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;} 25660 fi 25661 25662 # Save the first 10 bytes of this path to the storage, so fixpath can work. 25663 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 25664 25665 else 25666 # We're on a unix platform. Hooray! :) 25667 path="$BOOT_JDK" 25668 has_space=`$ECHO "$path" | $GREP " "` 25669 if test "x$has_space" != x; then 25670 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5 25671 $as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;} 25672 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 25673 fi 25674 25675 # Use eval to expand a potential ~ 25676 eval path="$path" 25677 if test ! -f "$path" && test ! -d "$path"; then 25678 as_fn_error $? "The path of BOOT_JDK, which resolves as \"$path\", is not found." "$LINENO" 5 25679 fi 25680 25681 if test -d "$path"; then 25682 BOOT_JDK="`cd "$path"; $THEPWDCMD -L`" 25683 else 25684 dir="`$DIRNAME "$path"`" 25685 base="`$BASENAME "$path"`" 25686 BOOT_JDK="`cd "$dir"; $THEPWDCMD -L`/$base" 25687 fi 25688 fi 25689 fi 25690 25691 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for Boot JDK" >&5 25692 $as_echo_n "checking for Boot JDK... " >&6; } 25693 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK" >&5 25694 $as_echo "$BOOT_JDK" >&6; } 25695 { $as_echo "$as_me:${as_lineno-$LINENO}: checking Boot JDK version" >&5 25696 $as_echo_n "checking Boot JDK version... " >&6; } 25697 BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | $TR '\n\r' ' '` 25698 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK_VERSION" >&5 25699 $as_echo "$BOOT_JDK_VERSION" >&6; } 25700 fi # end check jdk version 25701 fi # end check javac 25702 fi # end check java 25703 fi # end check boot jdk found 25704 fi 25705 25706 if test "x$with_boot_jdk" != x && test "x$BOOT_JDK_FOUND" = xno; then 25707 # Having specified an argument which is incorrect will produce an instant failure; 25708 # we should not go on looking 25709 as_fn_error $? "The path given by --with-boot-jdk does not contain a valid Boot JDK" "$LINENO" 5 25710 fi 25711 25712 # Test: On MacOS X, can we find a boot jdk using /usr/libexec/java_home? 25713 25714 if test "x$BOOT_JDK_FOUND" = xno; then 25715 # Now execute the test 25716 25717 if test "x$OPENJDK_TARGET_OS" = xmacosx; then 25718 # First check at user selected default 25719 25720 if test "x$BOOT_JDK_FOUND" = xno; then 25721 # Now execute the test 25722 25723 if test -x /usr/libexec/java_home; then 25724 BOOT_JDK=`/usr/libexec/java_home ` 25725 BOOT_JDK_FOUND=maybe 25726 { $as_echo "$as_me:${as_lineno-$LINENO}: Found potential Boot JDK using /usr/libexec/java_home " >&5 25727 $as_echo "$as_me: Found potential Boot JDK using /usr/libexec/java_home " >&6;} 25728 fi 25729 25730 25731 # If previous step claimed to have found a JDK, check it to see if it seems to be valid. 25732 if test "x$BOOT_JDK_FOUND" = xmaybe; then 25733 # Do we have a bin/java? 25734 if test ! -x "$BOOT_JDK/bin/java"; then 25735 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&5 25736 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&6;} 25737 BOOT_JDK_FOUND=no 25738 else 25739 # Do we have a bin/javac? 25740 if test ! -x "$BOOT_JDK/bin/javac"; then 25741 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&5 25742 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&6;} 25743 { $as_echo "$as_me:${as_lineno-$LINENO}: (This might be an JRE instead of an JDK)" >&5 25744 $as_echo "$as_me: (This might be an JRE instead of an JDK)" >&6;} 25745 BOOT_JDK_FOUND=no 25746 else 25747 # Oh, this is looking good! We probably have found a proper JDK. Is it the correct version? 25748 BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | $HEAD -n 1` 25749 25750 # Extra M4 quote needed to protect [] in grep expression. 25751 FOUND_CORRECT_VERSION=`$ECHO $BOOT_JDK_VERSION | $EGREP '\"10([\.+-].*)?\"|\"9([\.+-].*)?\"'` 25752 if test "x$FOUND_CORRECT_VERSION" = x; then 25753 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&5 25754 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&6;} 25755 { $as_echo "$as_me:${as_lineno-$LINENO}: (Your Boot JDK must be version 9 or 10)" >&5 25756 $as_echo "$as_me: (Your Boot JDK must be version 9 or 10)" >&6;} 25757 BOOT_JDK_FOUND=no 25758 else 25759 # We're done! :-) 25760 BOOT_JDK_FOUND=yes 25761 25762 # Only process if variable expands to non-empty 25763 25764 if test "x$BOOT_JDK" != x; then 25765 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 25766 25767 # Input might be given as Windows format, start by converting to 25768 # unix format. 25769 path="$BOOT_JDK" 25770 new_path=`$CYGPATH -u "$path"` 25771 25772 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 25773 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 25774 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 25775 # "foo.exe" is OK but "foo" is an error. 25776 # 25777 # This test is therefore slightly more accurate than "test -f" to check for file precense. 25778 # It is also a way to make sure we got the proper file name for the real test later on. 25779 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 25780 if test "x$test_shortpath" = x; then 25781 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5 25782 $as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;} 25783 as_fn_error $? "Cannot locate the the path of BOOT_JDK" "$LINENO" 5 25784 fi 25785 25786 # Call helper function which possibly converts this using DOS-style short mode. 25787 # If so, the updated path is stored in $new_path. 25788 25789 input_path="$new_path" 25790 # Check if we need to convert this using DOS-style short mode. If the path 25791 # contains just simple characters, use it. Otherwise (spaces, weird characters), 25792 # take no chances and rewrite it. 25793 # Note: m4 eats our [], so we need to use [ and ] instead. 25794 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 25795 if test "x$has_forbidden_chars" != x; then 25796 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 25797 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 25798 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 25799 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 25800 # Going to short mode and back again did indeed matter. Since short mode is 25801 # case insensitive, let's make it lowercase to improve readability. 25802 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 25803 # Now convert it back to Unix-style (cygpath) 25804 input_path=`$CYGPATH -u "$shortmode_path"` 25805 new_path="$input_path" 25806 fi 25807 fi 25808 25809 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 25810 if test "x$test_cygdrive_prefix" = x; then 25811 # As a simple fix, exclude /usr/bin since it's not a real path. 25812 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 25813 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 25814 # a path prefixed by /cygdrive for fixpath to work. 25815 new_path="$CYGWIN_ROOT_PATH$input_path" 25816 fi 25817 fi 25818 25819 25820 if test "x$path" != "x$new_path"; then 25821 BOOT_JDK="$new_path" 25822 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5 25823 $as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;} 25824 fi 25825 25826 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 25827 25828 path="$BOOT_JDK" 25829 has_colon=`$ECHO $path | $GREP ^.:` 25830 new_path="$path" 25831 if test "x$has_colon" = x; then 25832 # Not in mixed or Windows style, start by that. 25833 new_path=`cmd //c echo $path` 25834 fi 25835 25836 25837 input_path="$new_path" 25838 # Check if we need to convert this using DOS-style short mode. If the path 25839 # contains just simple characters, use it. Otherwise (spaces, weird characters), 25840 # take no chances and rewrite it. 25841 # Note: m4 eats our [], so we need to use [ and ] instead. 25842 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 25843 if test "x$has_forbidden_chars" != x; then 25844 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 25845 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 25846 fi 25847 25848 25849 windows_path="$new_path" 25850 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 25851 unix_path=`$CYGPATH -u "$windows_path"` 25852 new_path="$unix_path" 25853 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 25854 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 25855 new_path="$unix_path" 25856 fi 25857 25858 if test "x$path" != "x$new_path"; then 25859 BOOT_JDK="$new_path" 25860 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5 25861 $as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;} 25862 fi 25863 25864 # Save the first 10 bytes of this path to the storage, so fixpath can work. 25865 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 25866 25867 else 25868 # We're on a unix platform. Hooray! :) 25869 path="$BOOT_JDK" 25870 has_space=`$ECHO "$path" | $GREP " "` 25871 if test "x$has_space" != x; then 25872 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5 25873 $as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;} 25874 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 25875 fi 25876 25877 # Use eval to expand a potential ~ 25878 eval path="$path" 25879 if test ! -f "$path" && test ! -d "$path"; then 25880 as_fn_error $? "The path of BOOT_JDK, which resolves as \"$path\", is not found." "$LINENO" 5 25881 fi 25882 25883 if test -d "$path"; then 25884 BOOT_JDK="`cd "$path"; $THEPWDCMD -L`" 25885 else 25886 dir="`$DIRNAME "$path"`" 25887 base="`$BASENAME "$path"`" 25888 BOOT_JDK="`cd "$dir"; $THEPWDCMD -L`/$base" 25889 fi 25890 fi 25891 fi 25892 25893 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for Boot JDK" >&5 25894 $as_echo_n "checking for Boot JDK... " >&6; } 25895 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK" >&5 25896 $as_echo "$BOOT_JDK" >&6; } 25897 { $as_echo "$as_me:${as_lineno-$LINENO}: checking Boot JDK version" >&5 25898 $as_echo_n "checking Boot JDK version... " >&6; } 25899 BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | $TR '\n\r' ' '` 25900 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK_VERSION" >&5 25901 $as_echo "$BOOT_JDK_VERSION" >&6; } 25902 fi # end check jdk version 25903 fi # end check javac 25904 fi # end check java 25905 fi # end check boot jdk found 25906 fi 25907 25908 # If that did not work out (e.g. too old), try explicit versions instead 25909 25910 if test "x$BOOT_JDK_FOUND" = xno; then 25911 # Now execute the test 25912 25913 if test -x /usr/libexec/java_home; then 25914 BOOT_JDK=`/usr/libexec/java_home -v 1.9` 25915 BOOT_JDK_FOUND=maybe 25916 { $as_echo "$as_me:${as_lineno-$LINENO}: Found potential Boot JDK using /usr/libexec/java_home -v 1.9" >&5 25917 $as_echo "$as_me: Found potential Boot JDK using /usr/libexec/java_home -v 1.9" >&6;} 25918 fi 25919 25920 25921 # If previous step claimed to have found a JDK, check it to see if it seems to be valid. 25922 if test "x$BOOT_JDK_FOUND" = xmaybe; then 25923 # Do we have a bin/java? 25924 if test ! -x "$BOOT_JDK/bin/java"; then 25925 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&5 25926 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&6;} 25927 BOOT_JDK_FOUND=no 25928 else 25929 # Do we have a bin/javac? 25930 if test ! -x "$BOOT_JDK/bin/javac"; then 25931 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&5 25932 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&6;} 25933 { $as_echo "$as_me:${as_lineno-$LINENO}: (This might be an JRE instead of an JDK)" >&5 25934 $as_echo "$as_me: (This might be an JRE instead of an JDK)" >&6;} 25935 BOOT_JDK_FOUND=no 25936 else 25937 # Oh, this is looking good! We probably have found a proper JDK. Is it the correct version? 25938 BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | $HEAD -n 1` 25939 25940 # Extra M4 quote needed to protect [] in grep expression. 25941 FOUND_CORRECT_VERSION=`$ECHO $BOOT_JDK_VERSION | $EGREP '\"10([\.+-].*)?\"|\"9([\.+-].*)?\"'` 25942 if test "x$FOUND_CORRECT_VERSION" = x; then 25943 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&5 25944 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&6;} 25945 { $as_echo "$as_me:${as_lineno-$LINENO}: (Your Boot JDK must be version 9 or 10)" >&5 25946 $as_echo "$as_me: (Your Boot JDK must be version 9 or 10)" >&6;} 25947 BOOT_JDK_FOUND=no 25948 else 25949 # We're done! :-) 25950 BOOT_JDK_FOUND=yes 25951 25952 # Only process if variable expands to non-empty 25953 25954 if test "x$BOOT_JDK" != x; then 25955 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 25956 25957 # Input might be given as Windows format, start by converting to 25958 # unix format. 25959 path="$BOOT_JDK" 25960 new_path=`$CYGPATH -u "$path"` 25961 25962 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 25963 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 25964 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 25965 # "foo.exe" is OK but "foo" is an error. 25966 # 25967 # This test is therefore slightly more accurate than "test -f" to check for file precense. 25968 # It is also a way to make sure we got the proper file name for the real test later on. 25969 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 25970 if test "x$test_shortpath" = x; then 25971 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5 25972 $as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;} 25973 as_fn_error $? "Cannot locate the the path of BOOT_JDK" "$LINENO" 5 25974 fi 25975 25976 # Call helper function which possibly converts this using DOS-style short mode. 25977 # If so, the updated path is stored in $new_path. 25978 25979 input_path="$new_path" 25980 # Check if we need to convert this using DOS-style short mode. If the path 25981 # contains just simple characters, use it. Otherwise (spaces, weird characters), 25982 # take no chances and rewrite it. 25983 # Note: m4 eats our [], so we need to use [ and ] instead. 25984 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 25985 if test "x$has_forbidden_chars" != x; then 25986 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 25987 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 25988 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 25989 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 25990 # Going to short mode and back again did indeed matter. Since short mode is 25991 # case insensitive, let's make it lowercase to improve readability. 25992 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 25993 # Now convert it back to Unix-style (cygpath) 25994 input_path=`$CYGPATH -u "$shortmode_path"` 25995 new_path="$input_path" 25996 fi 25997 fi 25998 25999 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 26000 if test "x$test_cygdrive_prefix" = x; then 26001 # As a simple fix, exclude /usr/bin since it's not a real path. 26002 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 26003 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 26004 # a path prefixed by /cygdrive for fixpath to work. 26005 new_path="$CYGWIN_ROOT_PATH$input_path" 26006 fi 26007 fi 26008 26009 26010 if test "x$path" != "x$new_path"; then 26011 BOOT_JDK="$new_path" 26012 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5 26013 $as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;} 26014 fi 26015 26016 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 26017 26018 path="$BOOT_JDK" 26019 has_colon=`$ECHO $path | $GREP ^.:` 26020 new_path="$path" 26021 if test "x$has_colon" = x; then 26022 # Not in mixed or Windows style, start by that. 26023 new_path=`cmd //c echo $path` 26024 fi 26025 26026 26027 input_path="$new_path" 26028 # Check if we need to convert this using DOS-style short mode. If the path 26029 # contains just simple characters, use it. Otherwise (spaces, weird characters), 26030 # take no chances and rewrite it. 26031 # Note: m4 eats our [], so we need to use [ and ] instead. 26032 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 26033 if test "x$has_forbidden_chars" != x; then 26034 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 26035 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 26036 fi 26037 26038 26039 windows_path="$new_path" 26040 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 26041 unix_path=`$CYGPATH -u "$windows_path"` 26042 new_path="$unix_path" 26043 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 26044 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 26045 new_path="$unix_path" 26046 fi 26047 26048 if test "x$path" != "x$new_path"; then 26049 BOOT_JDK="$new_path" 26050 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5 26051 $as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;} 26052 fi 26053 26054 # Save the first 10 bytes of this path to the storage, so fixpath can work. 26055 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 26056 26057 else 26058 # We're on a unix platform. Hooray! :) 26059 path="$BOOT_JDK" 26060 has_space=`$ECHO "$path" | $GREP " "` 26061 if test "x$has_space" != x; then 26062 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5 26063 $as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;} 26064 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 26065 fi 26066 26067 # Use eval to expand a potential ~ 26068 eval path="$path" 26069 if test ! -f "$path" && test ! -d "$path"; then 26070 as_fn_error $? "The path of BOOT_JDK, which resolves as \"$path\", is not found." "$LINENO" 5 26071 fi 26072 26073 if test -d "$path"; then 26074 BOOT_JDK="`cd "$path"; $THEPWDCMD -L`" 26075 else 26076 dir="`$DIRNAME "$path"`" 26077 base="`$BASENAME "$path"`" 26078 BOOT_JDK="`cd "$dir"; $THEPWDCMD -L`/$base" 26079 fi 26080 fi 26081 fi 26082 26083 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for Boot JDK" >&5 26084 $as_echo_n "checking for Boot JDK... " >&6; } 26085 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK" >&5 26086 $as_echo "$BOOT_JDK" >&6; } 26087 { $as_echo "$as_me:${as_lineno-$LINENO}: checking Boot JDK version" >&5 26088 $as_echo_n "checking Boot JDK version... " >&6; } 26089 BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | $TR '\n\r' ' '` 26090 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK_VERSION" >&5 26091 $as_echo "$BOOT_JDK_VERSION" >&6; } 26092 fi # end check jdk version 26093 fi # end check javac 26094 fi # end check java 26095 fi # end check boot jdk found 26096 fi 26097 26098 26099 if test "x$BOOT_JDK_FOUND" = xno; then 26100 # Now execute the test 26101 26102 if test -x /usr/libexec/java_home; then 26103 BOOT_JDK=`/usr/libexec/java_home -v 1.8` 26104 BOOT_JDK_FOUND=maybe 26105 { $as_echo "$as_me:${as_lineno-$LINENO}: Found potential Boot JDK using /usr/libexec/java_home -v 1.8" >&5 26106 $as_echo "$as_me: Found potential Boot JDK using /usr/libexec/java_home -v 1.8" >&6;} 26107 fi 26108 26109 26110 # If previous step claimed to have found a JDK, check it to see if it seems to be valid. 26111 if test "x$BOOT_JDK_FOUND" = xmaybe; then 26112 # Do we have a bin/java? 26113 if test ! -x "$BOOT_JDK/bin/java"; then 26114 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&5 26115 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&6;} 26116 BOOT_JDK_FOUND=no 26117 else 26118 # Do we have a bin/javac? 26119 if test ! -x "$BOOT_JDK/bin/javac"; then 26120 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&5 26121 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&6;} 26122 { $as_echo "$as_me:${as_lineno-$LINENO}: (This might be an JRE instead of an JDK)" >&5 26123 $as_echo "$as_me: (This might be an JRE instead of an JDK)" >&6;} 26124 BOOT_JDK_FOUND=no 26125 else 26126 # Oh, this is looking good! We probably have found a proper JDK. Is it the correct version? 26127 BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | $HEAD -n 1` 26128 26129 # Extra M4 quote needed to protect [] in grep expression. 26130 FOUND_CORRECT_VERSION=`$ECHO $BOOT_JDK_VERSION | $EGREP '\"10([\.+-].*)?\"|\"9([\.+-].*)?\"'` 26131 if test "x$FOUND_CORRECT_VERSION" = x; then 26132 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&5 26133 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&6;} 26134 { $as_echo "$as_me:${as_lineno-$LINENO}: (Your Boot JDK must be version 9 or 10)" >&5 26135 $as_echo "$as_me: (Your Boot JDK must be version 9 or 10)" >&6;} 26136 BOOT_JDK_FOUND=no 26137 else 26138 # We're done! :-) 26139 BOOT_JDK_FOUND=yes 26140 26141 # Only process if variable expands to non-empty 26142 26143 if test "x$BOOT_JDK" != x; then 26144 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 26145 26146 # Input might be given as Windows format, start by converting to 26147 # unix format. 26148 path="$BOOT_JDK" 26149 new_path=`$CYGPATH -u "$path"` 26150 26151 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 26152 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 26153 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 26154 # "foo.exe" is OK but "foo" is an error. 26155 # 26156 # This test is therefore slightly more accurate than "test -f" to check for file precense. 26157 # It is also a way to make sure we got the proper file name for the real test later on. 26158 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 26159 if test "x$test_shortpath" = x; then 26160 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5 26161 $as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;} 26162 as_fn_error $? "Cannot locate the the path of BOOT_JDK" "$LINENO" 5 26163 fi 26164 26165 # Call helper function which possibly converts this using DOS-style short mode. 26166 # If so, the updated path is stored in $new_path. 26167 26168 input_path="$new_path" 26169 # Check if we need to convert this using DOS-style short mode. If the path 26170 # contains just simple characters, use it. Otherwise (spaces, weird characters), 26171 # take no chances and rewrite it. 26172 # Note: m4 eats our [], so we need to use [ and ] instead. 26173 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 26174 if test "x$has_forbidden_chars" != x; then 26175 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 26176 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 26177 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 26178 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 26179 # Going to short mode and back again did indeed matter. Since short mode is 26180 # case insensitive, let's make it lowercase to improve readability. 26181 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 26182 # Now convert it back to Unix-style (cygpath) 26183 input_path=`$CYGPATH -u "$shortmode_path"` 26184 new_path="$input_path" 26185 fi 26186 fi 26187 26188 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 26189 if test "x$test_cygdrive_prefix" = x; then 26190 # As a simple fix, exclude /usr/bin since it's not a real path. 26191 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 26192 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 26193 # a path prefixed by /cygdrive for fixpath to work. 26194 new_path="$CYGWIN_ROOT_PATH$input_path" 26195 fi 26196 fi 26197 26198 26199 if test "x$path" != "x$new_path"; then 26200 BOOT_JDK="$new_path" 26201 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5 26202 $as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;} 26203 fi 26204 26205 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 26206 26207 path="$BOOT_JDK" 26208 has_colon=`$ECHO $path | $GREP ^.:` 26209 new_path="$path" 26210 if test "x$has_colon" = x; then 26211 # Not in mixed or Windows style, start by that. 26212 new_path=`cmd //c echo $path` 26213 fi 26214 26215 26216 input_path="$new_path" 26217 # Check if we need to convert this using DOS-style short mode. If the path 26218 # contains just simple characters, use it. Otherwise (spaces, weird characters), 26219 # take no chances and rewrite it. 26220 # Note: m4 eats our [], so we need to use [ and ] instead. 26221 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 26222 if test "x$has_forbidden_chars" != x; then 26223 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 26224 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 26225 fi 26226 26227 26228 windows_path="$new_path" 26229 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 26230 unix_path=`$CYGPATH -u "$windows_path"` 26231 new_path="$unix_path" 26232 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 26233 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 26234 new_path="$unix_path" 26235 fi 26236 26237 if test "x$path" != "x$new_path"; then 26238 BOOT_JDK="$new_path" 26239 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5 26240 $as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;} 26241 fi 26242 26243 # Save the first 10 bytes of this path to the storage, so fixpath can work. 26244 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 26245 26246 else 26247 # We're on a unix platform. Hooray! :) 26248 path="$BOOT_JDK" 26249 has_space=`$ECHO "$path" | $GREP " "` 26250 if test "x$has_space" != x; then 26251 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5 26252 $as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;} 26253 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 26254 fi 26255 26256 # Use eval to expand a potential ~ 26257 eval path="$path" 26258 if test ! -f "$path" && test ! -d "$path"; then 26259 as_fn_error $? "The path of BOOT_JDK, which resolves as \"$path\", is not found." "$LINENO" 5 26260 fi 26261 26262 if test -d "$path"; then 26263 BOOT_JDK="`cd "$path"; $THEPWDCMD -L`" 26264 else 26265 dir="`$DIRNAME "$path"`" 26266 base="`$BASENAME "$path"`" 26267 BOOT_JDK="`cd "$dir"; $THEPWDCMD -L`/$base" 26268 fi 26269 fi 26270 fi 26271 26272 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for Boot JDK" >&5 26273 $as_echo_n "checking for Boot JDK... " >&6; } 26274 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK" >&5 26275 $as_echo "$BOOT_JDK" >&6; } 26276 { $as_echo "$as_me:${as_lineno-$LINENO}: checking Boot JDK version" >&5 26277 $as_echo_n "checking Boot JDK version... " >&6; } 26278 BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | $TR '\n\r' ' '` 26279 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK_VERSION" >&5 26280 $as_echo "$BOOT_JDK_VERSION" >&6; } 26281 fi # end check jdk version 26282 fi # end check javac 26283 fi # end check java 26284 fi # end check boot jdk found 26285 fi 26286 26287 26288 if test "x$BOOT_JDK_FOUND" = xno; then 26289 # Now execute the test 26290 26291 if test -x /usr/libexec/java_home; then 26292 BOOT_JDK=`/usr/libexec/java_home -v 1.7` 26293 BOOT_JDK_FOUND=maybe 26294 { $as_echo "$as_me:${as_lineno-$LINENO}: Found potential Boot JDK using /usr/libexec/java_home -v 1.7" >&5 26295 $as_echo "$as_me: Found potential Boot JDK using /usr/libexec/java_home -v 1.7" >&6;} 26296 fi 26297 26298 26299 # If previous step claimed to have found a JDK, check it to see if it seems to be valid. 26300 if test "x$BOOT_JDK_FOUND" = xmaybe; then 26301 # Do we have a bin/java? 26302 if test ! -x "$BOOT_JDK/bin/java"; then 26303 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&5 26304 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&6;} 26305 BOOT_JDK_FOUND=no 26306 else 26307 # Do we have a bin/javac? 26308 if test ! -x "$BOOT_JDK/bin/javac"; then 26309 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&5 26310 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&6;} 26311 { $as_echo "$as_me:${as_lineno-$LINENO}: (This might be an JRE instead of an JDK)" >&5 26312 $as_echo "$as_me: (This might be an JRE instead of an JDK)" >&6;} 26313 BOOT_JDK_FOUND=no 26314 else 26315 # Oh, this is looking good! We probably have found a proper JDK. Is it the correct version? 26316 BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | $HEAD -n 1` 26317 26318 # Extra M4 quote needed to protect [] in grep expression. 26319 FOUND_CORRECT_VERSION=`$ECHO $BOOT_JDK_VERSION | $EGREP '\"10([\.+-].*)?\"|\"9([\.+-].*)?\"'` 26320 if test "x$FOUND_CORRECT_VERSION" = x; then 26321 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&5 26322 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&6;} 26323 { $as_echo "$as_me:${as_lineno-$LINENO}: (Your Boot JDK must be version 9 or 10)" >&5 26324 $as_echo "$as_me: (Your Boot JDK must be version 9 or 10)" >&6;} 26325 BOOT_JDK_FOUND=no 26326 else 26327 # We're done! :-) 26328 BOOT_JDK_FOUND=yes 26329 26330 # Only process if variable expands to non-empty 26331 26332 if test "x$BOOT_JDK" != x; then 26333 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 26334 26335 # Input might be given as Windows format, start by converting to 26336 # unix format. 26337 path="$BOOT_JDK" 26338 new_path=`$CYGPATH -u "$path"` 26339 26340 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 26341 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 26342 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 26343 # "foo.exe" is OK but "foo" is an error. 26344 # 26345 # This test is therefore slightly more accurate than "test -f" to check for file precense. 26346 # It is also a way to make sure we got the proper file name for the real test later on. 26347 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 26348 if test "x$test_shortpath" = x; then 26349 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5 26350 $as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;} 26351 as_fn_error $? "Cannot locate the the path of BOOT_JDK" "$LINENO" 5 26352 fi 26353 26354 # Call helper function which possibly converts this using DOS-style short mode. 26355 # If so, the updated path is stored in $new_path. 26356 26357 input_path="$new_path" 26358 # Check if we need to convert this using DOS-style short mode. If the path 26359 # contains just simple characters, use it. Otherwise (spaces, weird characters), 26360 # take no chances and rewrite it. 26361 # Note: m4 eats our [], so we need to use [ and ] instead. 26362 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 26363 if test "x$has_forbidden_chars" != x; then 26364 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 26365 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 26366 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 26367 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 26368 # Going to short mode and back again did indeed matter. Since short mode is 26369 # case insensitive, let's make it lowercase to improve readability. 26370 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 26371 # Now convert it back to Unix-style (cygpath) 26372 input_path=`$CYGPATH -u "$shortmode_path"` 26373 new_path="$input_path" 26374 fi 26375 fi 26376 26377 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 26378 if test "x$test_cygdrive_prefix" = x; then 26379 # As a simple fix, exclude /usr/bin since it's not a real path. 26380 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 26381 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 26382 # a path prefixed by /cygdrive for fixpath to work. 26383 new_path="$CYGWIN_ROOT_PATH$input_path" 26384 fi 26385 fi 26386 26387 26388 if test "x$path" != "x$new_path"; then 26389 BOOT_JDK="$new_path" 26390 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5 26391 $as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;} 26392 fi 26393 26394 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 26395 26396 path="$BOOT_JDK" 26397 has_colon=`$ECHO $path | $GREP ^.:` 26398 new_path="$path" 26399 if test "x$has_colon" = x; then 26400 # Not in mixed or Windows style, start by that. 26401 new_path=`cmd //c echo $path` 26402 fi 26403 26404 26405 input_path="$new_path" 26406 # Check if we need to convert this using DOS-style short mode. If the path 26407 # contains just simple characters, use it. Otherwise (spaces, weird characters), 26408 # take no chances and rewrite it. 26409 # Note: m4 eats our [], so we need to use [ and ] instead. 26410 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 26411 if test "x$has_forbidden_chars" != x; then 26412 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 26413 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 26414 fi 26415 26416 26417 windows_path="$new_path" 26418 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 26419 unix_path=`$CYGPATH -u "$windows_path"` 26420 new_path="$unix_path" 26421 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 26422 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 26423 new_path="$unix_path" 26424 fi 26425 26426 if test "x$path" != "x$new_path"; then 26427 BOOT_JDK="$new_path" 26428 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5 26429 $as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;} 26430 fi 26431 26432 # Save the first 10 bytes of this path to the storage, so fixpath can work. 26433 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 26434 26435 else 26436 # We're on a unix platform. Hooray! :) 26437 path="$BOOT_JDK" 26438 has_space=`$ECHO "$path" | $GREP " "` 26439 if test "x$has_space" != 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 $? "Spaces are not allowed in this path." "$LINENO" 5 26443 fi 26444 26445 # Use eval to expand a potential ~ 26446 eval path="$path" 26447 if test ! -f "$path" && test ! -d "$path"; then 26448 as_fn_error $? "The path of BOOT_JDK, which resolves as \"$path\", is not found." "$LINENO" 5 26449 fi 26450 26451 if test -d "$path"; then 26452 BOOT_JDK="`cd "$path"; $THEPWDCMD -L`" 26453 else 26454 dir="`$DIRNAME "$path"`" 26455 base="`$BASENAME "$path"`" 26456 BOOT_JDK="`cd "$dir"; $THEPWDCMD -L`/$base" 26457 fi 26458 fi 26459 fi 26460 26461 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for Boot JDK" >&5 26462 $as_echo_n "checking for Boot JDK... " >&6; } 26463 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK" >&5 26464 $as_echo "$BOOT_JDK" >&6; } 26465 { $as_echo "$as_me:${as_lineno-$LINENO}: checking Boot JDK version" >&5 26466 $as_echo_n "checking Boot JDK version... " >&6; } 26467 BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | $TR '\n\r' ' '` 26468 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK_VERSION" >&5 26469 $as_echo "$BOOT_JDK_VERSION" >&6; } 26470 fi # end check jdk version 26471 fi # end check javac 26472 fi # end check java 26473 fi # end check boot jdk found 26474 fi 26475 26476 fi 26477 26478 26479 # If previous step claimed to have found a JDK, check it to see if it seems to be valid. 26480 if test "x$BOOT_JDK_FOUND" = xmaybe; then 26481 # Do we have a bin/java? 26482 if test ! -x "$BOOT_JDK/bin/java"; then 26483 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&5 26484 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&6;} 26485 BOOT_JDK_FOUND=no 26486 else 26487 # Do we have a bin/javac? 26488 if test ! -x "$BOOT_JDK/bin/javac"; then 26489 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&5 26490 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&6;} 26491 { $as_echo "$as_me:${as_lineno-$LINENO}: (This might be an JRE instead of an JDK)" >&5 26492 $as_echo "$as_me: (This might be an JRE instead of an JDK)" >&6;} 26493 BOOT_JDK_FOUND=no 26494 else 26495 # Oh, this is looking good! We probably have found a proper JDK. Is it the correct version? 26496 BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | $HEAD -n 1` 26497 26498 # Extra M4 quote needed to protect [] in grep expression. 26499 FOUND_CORRECT_VERSION=`$ECHO $BOOT_JDK_VERSION | $EGREP '\"10([\.+-].*)?\"|\"9([\.+-].*)?\"'` 26500 if test "x$FOUND_CORRECT_VERSION" = x; then 26501 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&5 26502 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&6;} 26503 { $as_echo "$as_me:${as_lineno-$LINENO}: (Your Boot JDK must be version 9 or 10)" >&5 26504 $as_echo "$as_me: (Your Boot JDK must be version 9 or 10)" >&6;} 26505 BOOT_JDK_FOUND=no 26506 else 26507 # We're done! :-) 26508 BOOT_JDK_FOUND=yes 26509 26510 # Only process if variable expands to non-empty 26511 26512 if test "x$BOOT_JDK" != x; then 26513 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 26514 26515 # Input might be given as Windows format, start by converting to 26516 # unix format. 26517 path="$BOOT_JDK" 26518 new_path=`$CYGPATH -u "$path"` 26519 26520 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 26521 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 26522 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 26523 # "foo.exe" is OK but "foo" is an error. 26524 # 26525 # This test is therefore slightly more accurate than "test -f" to check for file precense. 26526 # It is also a way to make sure we got the proper file name for the real test later on. 26527 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 26528 if test "x$test_shortpath" = x; then 26529 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5 26530 $as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;} 26531 as_fn_error $? "Cannot locate the the path of BOOT_JDK" "$LINENO" 5 26532 fi 26533 26534 # Call helper function which possibly converts this using DOS-style short mode. 26535 # If so, the updated path is stored in $new_path. 26536 26537 input_path="$new_path" 26538 # Check if we need to convert this using DOS-style short mode. If the path 26539 # contains just simple characters, use it. Otherwise (spaces, weird characters), 26540 # take no chances and rewrite it. 26541 # Note: m4 eats our [], so we need to use [ and ] instead. 26542 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 26543 if test "x$has_forbidden_chars" != x; then 26544 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 26545 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 26546 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 26547 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 26548 # Going to short mode and back again did indeed matter. Since short mode is 26549 # case insensitive, let's make it lowercase to improve readability. 26550 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 26551 # Now convert it back to Unix-style (cygpath) 26552 input_path=`$CYGPATH -u "$shortmode_path"` 26553 new_path="$input_path" 26554 fi 26555 fi 26556 26557 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 26558 if test "x$test_cygdrive_prefix" = x; then 26559 # As a simple fix, exclude /usr/bin since it's not a real path. 26560 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 26561 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 26562 # a path prefixed by /cygdrive for fixpath to work. 26563 new_path="$CYGWIN_ROOT_PATH$input_path" 26564 fi 26565 fi 26566 26567 26568 if test "x$path" != "x$new_path"; then 26569 BOOT_JDK="$new_path" 26570 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5 26571 $as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;} 26572 fi 26573 26574 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 26575 26576 path="$BOOT_JDK" 26577 has_colon=`$ECHO $path | $GREP ^.:` 26578 new_path="$path" 26579 if test "x$has_colon" = x; then 26580 # Not in mixed or Windows style, start by that. 26581 new_path=`cmd //c echo $path` 26582 fi 26583 26584 26585 input_path="$new_path" 26586 # Check if we need to convert this using DOS-style short mode. If the path 26587 # contains just simple characters, use it. Otherwise (spaces, weird characters), 26588 # take no chances and rewrite it. 26589 # Note: m4 eats our [], so we need to use [ and ] instead. 26590 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 26591 if test "x$has_forbidden_chars" != x; then 26592 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 26593 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 26594 fi 26595 26596 26597 windows_path="$new_path" 26598 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 26599 unix_path=`$CYGPATH -u "$windows_path"` 26600 new_path="$unix_path" 26601 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 26602 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 26603 new_path="$unix_path" 26604 fi 26605 26606 if test "x$path" != "x$new_path"; then 26607 BOOT_JDK="$new_path" 26608 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5 26609 $as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;} 26610 fi 26611 26612 # Save the first 10 bytes of this path to the storage, so fixpath can work. 26613 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 26614 26615 else 26616 # We're on a unix platform. Hooray! :) 26617 path="$BOOT_JDK" 26618 has_space=`$ECHO "$path" | $GREP " "` 26619 if test "x$has_space" != x; then 26620 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5 26621 $as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;} 26622 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 26623 fi 26624 26625 # Use eval to expand a potential ~ 26626 eval path="$path" 26627 if test ! -f "$path" && test ! -d "$path"; then 26628 as_fn_error $? "The path of BOOT_JDK, which resolves as \"$path\", is not found." "$LINENO" 5 26629 fi 26630 26631 if test -d "$path"; then 26632 BOOT_JDK="`cd "$path"; $THEPWDCMD -L`" 26633 else 26634 dir="`$DIRNAME "$path"`" 26635 base="`$BASENAME "$path"`" 26636 BOOT_JDK="`cd "$dir"; $THEPWDCMD -L`/$base" 26637 fi 26638 fi 26639 fi 26640 26641 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for Boot JDK" >&5 26642 $as_echo_n "checking for Boot JDK... " >&6; } 26643 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK" >&5 26644 $as_echo "$BOOT_JDK" >&6; } 26645 { $as_echo "$as_me:${as_lineno-$LINENO}: checking Boot JDK version" >&5 26646 $as_echo_n "checking Boot JDK version... " >&6; } 26647 BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | $TR '\n\r' ' '` 26648 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK_VERSION" >&5 26649 $as_echo "$BOOT_JDK_VERSION" >&6; } 26650 fi # end check jdk version 26651 fi # end check javac 26652 fi # end check java 26653 fi # end check boot jdk found 26654 fi 26655 26656 26657 # Test: Is $JAVA_HOME set? 26658 26659 if test "x$BOOT_JDK_FOUND" = xno; then 26660 # Now execute the test 26661 26662 if test "x$JAVA_HOME" != x; then 26663 JAVA_HOME_PROCESSED="$JAVA_HOME" 26664 26665 # Only process if variable expands to non-empty 26666 26667 if test "x$JAVA_HOME_PROCESSED" != x; then 26668 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 26669 26670 # Input might be given as Windows format, start by converting to 26671 # unix format. 26672 path="$JAVA_HOME_PROCESSED" 26673 new_path=`$CYGPATH -u "$path"` 26674 26675 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 26676 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 26677 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 26678 # "foo.exe" is OK but "foo" is an error. 26679 # 26680 # This test is therefore slightly more accurate than "test -f" to check for file precense. 26681 # It is also a way to make sure we got the proper file name for the real test later on. 26682 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 26683 if test "x$test_shortpath" = x; then 26684 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of JAVA_HOME_PROCESSED, which resolves as \"$path\", is invalid." >&5 26685 $as_echo "$as_me: The path of JAVA_HOME_PROCESSED, which resolves as \"$path\", is invalid." >&6;} 26686 as_fn_error $? "Cannot locate the the path of JAVA_HOME_PROCESSED" "$LINENO" 5 26687 fi 26688 26689 # Call helper function which possibly converts this using DOS-style short mode. 26690 # If so, the updated path is stored in $new_path. 26691 26692 input_path="$new_path" 26693 # Check if we need to convert this using DOS-style short mode. If the path 26694 # contains just simple characters, use it. Otherwise (spaces, weird characters), 26695 # take no chances and rewrite it. 26696 # Note: m4 eats our [], so we need to use [ and ] instead. 26697 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 26698 if test "x$has_forbidden_chars" != x; then 26699 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 26700 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 26701 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 26702 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 26703 # Going to short mode and back again did indeed matter. Since short mode is 26704 # case insensitive, let's make it lowercase to improve readability. 26705 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 26706 # Now convert it back to Unix-style (cygpath) 26707 input_path=`$CYGPATH -u "$shortmode_path"` 26708 new_path="$input_path" 26709 fi 26710 fi 26711 26712 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 26713 if test "x$test_cygdrive_prefix" = x; then 26714 # As a simple fix, exclude /usr/bin since it's not a real path. 26715 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 26716 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 26717 # a path prefixed by /cygdrive for fixpath to work. 26718 new_path="$CYGWIN_ROOT_PATH$input_path" 26719 fi 26720 fi 26721 26722 26723 if test "x$path" != "x$new_path"; then 26724 JAVA_HOME_PROCESSED="$new_path" 26725 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting JAVA_HOME_PROCESSED to \"$new_path\"" >&5 26726 $as_echo "$as_me: Rewriting JAVA_HOME_PROCESSED to \"$new_path\"" >&6;} 26727 fi 26728 26729 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 26730 26731 path="$JAVA_HOME_PROCESSED" 26732 has_colon=`$ECHO $path | $GREP ^.:` 26733 new_path="$path" 26734 if test "x$has_colon" = x; then 26735 # Not in mixed or Windows style, start by that. 26736 new_path=`cmd //c echo $path` 26737 fi 26738 26739 26740 input_path="$new_path" 26741 # Check if we need to convert this using DOS-style short mode. If the path 26742 # contains just simple characters, use it. Otherwise (spaces, weird characters), 26743 # take no chances and rewrite it. 26744 # Note: m4 eats our [], so we need to use [ and ] instead. 26745 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 26746 if test "x$has_forbidden_chars" != x; then 26747 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 26748 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 26749 fi 26750 26751 26752 windows_path="$new_path" 26753 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 26754 unix_path=`$CYGPATH -u "$windows_path"` 26755 new_path="$unix_path" 26756 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 26757 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 26758 new_path="$unix_path" 26759 fi 26760 26761 if test "x$path" != "x$new_path"; then 26762 JAVA_HOME_PROCESSED="$new_path" 26763 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting JAVA_HOME_PROCESSED to \"$new_path\"" >&5 26764 $as_echo "$as_me: Rewriting JAVA_HOME_PROCESSED to \"$new_path\"" >&6;} 26765 fi 26766 26767 # Save the first 10 bytes of this path to the storage, so fixpath can work. 26768 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 26769 26770 else 26771 # We're on a unix platform. Hooray! :) 26772 path="$JAVA_HOME_PROCESSED" 26773 has_space=`$ECHO "$path" | $GREP " "` 26774 if test "x$has_space" != x; then 26775 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of JAVA_HOME_PROCESSED, which resolves as \"$path\", is invalid." >&5 26776 $as_echo "$as_me: The path of JAVA_HOME_PROCESSED, which resolves as \"$path\", is invalid." >&6;} 26777 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 26778 fi 26779 26780 # Use eval to expand a potential ~ 26781 eval path="$path" 26782 if test ! -f "$path" && test ! -d "$path"; then 26783 as_fn_error $? "The path of JAVA_HOME_PROCESSED, which resolves as \"$path\", is not found." "$LINENO" 5 26784 fi 26785 26786 if test -d "$path"; then 26787 JAVA_HOME_PROCESSED="`cd "$path"; $THEPWDCMD -L`" 26788 else 26789 dir="`$DIRNAME "$path"`" 26790 base="`$BASENAME "$path"`" 26791 JAVA_HOME_PROCESSED="`cd "$dir"; $THEPWDCMD -L`/$base" 26792 fi 26793 fi 26794 fi 26795 26796 if test ! -d "$JAVA_HOME_PROCESSED"; then 26797 { $as_echo "$as_me:${as_lineno-$LINENO}: Your JAVA_HOME points to a non-existing directory!" >&5 26798 $as_echo "$as_me: Your JAVA_HOME points to a non-existing directory!" >&6;} 26799 else 26800 # Aha, the user has set a JAVA_HOME 26801 # let us use that as the Boot JDK. 26802 BOOT_JDK="$JAVA_HOME_PROCESSED" 26803 BOOT_JDK_FOUND=maybe 26804 { $as_echo "$as_me:${as_lineno-$LINENO}: Found potential Boot JDK using JAVA_HOME" >&5 26805 $as_echo "$as_me: Found potential Boot JDK using JAVA_HOME" >&6;} 26806 fi 26807 fi 26808 26809 26810 # If previous step claimed to have found a JDK, check it to see if it seems to be valid. 26811 if test "x$BOOT_JDK_FOUND" = xmaybe; then 26812 # Do we have a bin/java? 26813 if test ! -x "$BOOT_JDK/bin/java"; then 26814 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&5 26815 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&6;} 26816 BOOT_JDK_FOUND=no 26817 else 26818 # Do we have a bin/javac? 26819 if test ! -x "$BOOT_JDK/bin/javac"; then 26820 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&5 26821 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&6;} 26822 { $as_echo "$as_me:${as_lineno-$LINENO}: (This might be an JRE instead of an JDK)" >&5 26823 $as_echo "$as_me: (This might be an JRE instead of an JDK)" >&6;} 26824 BOOT_JDK_FOUND=no 26825 else 26826 # Oh, this is looking good! We probably have found a proper JDK. Is it the correct version? 26827 BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | $HEAD -n 1` 26828 26829 # Extra M4 quote needed to protect [] in grep expression. 26830 FOUND_CORRECT_VERSION=`$ECHO $BOOT_JDK_VERSION | $EGREP '\"10([\.+-].*)?\"|\"9([\.+-].*)?\"'` 26831 if test "x$FOUND_CORRECT_VERSION" = x; then 26832 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&5 26833 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&6;} 26834 { $as_echo "$as_me:${as_lineno-$LINENO}: (Your Boot JDK must be version 9 or 10)" >&5 26835 $as_echo "$as_me: (Your Boot JDK must be version 9 or 10)" >&6;} 26836 BOOT_JDK_FOUND=no 26837 else 26838 # We're done! :-) 26839 BOOT_JDK_FOUND=yes 26840 26841 # Only process if variable expands to non-empty 26842 26843 if test "x$BOOT_JDK" != x; then 26844 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 26845 26846 # Input might be given as Windows format, start by converting to 26847 # unix format. 26848 path="$BOOT_JDK" 26849 new_path=`$CYGPATH -u "$path"` 26850 26851 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 26852 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 26853 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 26854 # "foo.exe" is OK but "foo" is an error. 26855 # 26856 # This test is therefore slightly more accurate than "test -f" to check for file precense. 26857 # It is also a way to make sure we got the proper file name for the real test later on. 26858 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 26859 if test "x$test_shortpath" = x; then 26860 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5 26861 $as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;} 26862 as_fn_error $? "Cannot locate the the path of BOOT_JDK" "$LINENO" 5 26863 fi 26864 26865 # Call helper function which possibly converts this using DOS-style short mode. 26866 # If so, the updated path is stored in $new_path. 26867 26868 input_path="$new_path" 26869 # Check if we need to convert this using DOS-style short mode. If the path 26870 # contains just simple characters, use it. Otherwise (spaces, weird characters), 26871 # take no chances and rewrite it. 26872 # Note: m4 eats our [], so we need to use [ and ] instead. 26873 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 26874 if test "x$has_forbidden_chars" != x; then 26875 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 26876 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 26877 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 26878 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 26879 # Going to short mode and back again did indeed matter. Since short mode is 26880 # case insensitive, let's make it lowercase to improve readability. 26881 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 26882 # Now convert it back to Unix-style (cygpath) 26883 input_path=`$CYGPATH -u "$shortmode_path"` 26884 new_path="$input_path" 26885 fi 26886 fi 26887 26888 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 26889 if test "x$test_cygdrive_prefix" = x; then 26890 # As a simple fix, exclude /usr/bin since it's not a real path. 26891 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 26892 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 26893 # a path prefixed by /cygdrive for fixpath to work. 26894 new_path="$CYGWIN_ROOT_PATH$input_path" 26895 fi 26896 fi 26897 26898 26899 if test "x$path" != "x$new_path"; then 26900 BOOT_JDK="$new_path" 26901 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5 26902 $as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;} 26903 fi 26904 26905 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 26906 26907 path="$BOOT_JDK" 26908 has_colon=`$ECHO $path | $GREP ^.:` 26909 new_path="$path" 26910 if test "x$has_colon" = x; then 26911 # Not in mixed or Windows style, start by that. 26912 new_path=`cmd //c echo $path` 26913 fi 26914 26915 26916 input_path="$new_path" 26917 # Check if we need to convert this using DOS-style short mode. If the path 26918 # contains just simple characters, use it. Otherwise (spaces, weird characters), 26919 # take no chances and rewrite it. 26920 # Note: m4 eats our [], so we need to use [ and ] instead. 26921 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 26922 if test "x$has_forbidden_chars" != x; then 26923 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 26924 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 26925 fi 26926 26927 26928 windows_path="$new_path" 26929 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 26930 unix_path=`$CYGPATH -u "$windows_path"` 26931 new_path="$unix_path" 26932 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 26933 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 26934 new_path="$unix_path" 26935 fi 26936 26937 if test "x$path" != "x$new_path"; then 26938 BOOT_JDK="$new_path" 26939 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5 26940 $as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;} 26941 fi 26942 26943 # Save the first 10 bytes of this path to the storage, so fixpath can work. 26944 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 26945 26946 else 26947 # We're on a unix platform. Hooray! :) 26948 path="$BOOT_JDK" 26949 has_space=`$ECHO "$path" | $GREP " "` 26950 if test "x$has_space" != x; then 26951 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5 26952 $as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;} 26953 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 26954 fi 26955 26956 # Use eval to expand a potential ~ 26957 eval path="$path" 26958 if test ! -f "$path" && test ! -d "$path"; then 26959 as_fn_error $? "The path of BOOT_JDK, which resolves as \"$path\", is not found." "$LINENO" 5 26960 fi 26961 26962 if test -d "$path"; then 26963 BOOT_JDK="`cd "$path"; $THEPWDCMD -L`" 26964 else 26965 dir="`$DIRNAME "$path"`" 26966 base="`$BASENAME "$path"`" 26967 BOOT_JDK="`cd "$dir"; $THEPWDCMD -L`/$base" 26968 fi 26969 fi 26970 fi 26971 26972 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for Boot JDK" >&5 26973 $as_echo_n "checking for Boot JDK... " >&6; } 26974 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK" >&5 26975 $as_echo "$BOOT_JDK" >&6; } 26976 { $as_echo "$as_me:${as_lineno-$LINENO}: checking Boot JDK version" >&5 26977 $as_echo_n "checking Boot JDK version... " >&6; } 26978 BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | $TR '\n\r' ' '` 26979 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK_VERSION" >&5 26980 $as_echo "$BOOT_JDK_VERSION" >&6; } 26981 fi # end check jdk version 26982 fi # end check javac 26983 fi # end check java 26984 fi # end check boot jdk found 26985 fi 26986 26987 26988 # Test: Is there a java or javac in the PATH, which is a symlink to the JDK? 26989 26990 if test "x$BOOT_JDK_FOUND" = xno; then 26991 # Now execute the test 26992 26993 # Extract the first word of "javac", so it can be a program name with args. 26994 set dummy javac; ac_word=$2 26995 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 26996 $as_echo_n "checking for $ac_word... " >&6; } 26997 if ${ac_cv_path_JAVAC_CHECK+:} false; then : 26998 $as_echo_n "(cached) " >&6 26999 else 27000 case $JAVAC_CHECK in 27001 [\\/]* | ?:[\\/]*) 27002 ac_cv_path_JAVAC_CHECK="$JAVAC_CHECK" # Let the user override the test with a path. 27003 ;; 27004 *) 27005 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 27006 for as_dir in $PATH 27007 do 27008 IFS=$as_save_IFS 27009 test -z "$as_dir" && as_dir=. 27010 for ac_exec_ext in '' $ac_executable_extensions; do 27011 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 27012 ac_cv_path_JAVAC_CHECK="$as_dir/$ac_word$ac_exec_ext" 27013 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 27014 break 2 27015 fi 27016 done 27017 done 27018 IFS=$as_save_IFS 27019 27020 ;; 27021 esac 27022 fi 27023 JAVAC_CHECK=$ac_cv_path_JAVAC_CHECK 27024 if test -n "$JAVAC_CHECK"; then 27025 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $JAVAC_CHECK" >&5 27026 $as_echo "$JAVAC_CHECK" >&6; } 27027 else 27028 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 27029 $as_echo "no" >&6; } 27030 fi 27031 27032 27033 # Extract the first word of "java", so it can be a program name with args. 27034 set dummy java; ac_word=$2 27035 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 27036 $as_echo_n "checking for $ac_word... " >&6; } 27037 if ${ac_cv_path_JAVA_CHECK+:} false; then : 27038 $as_echo_n "(cached) " >&6 27039 else 27040 case $JAVA_CHECK in 27041 [\\/]* | ?:[\\/]*) 27042 ac_cv_path_JAVA_CHECK="$JAVA_CHECK" # Let the user override the test with a path. 27043 ;; 27044 *) 27045 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 27046 for as_dir in $PATH 27047 do 27048 IFS=$as_save_IFS 27049 test -z "$as_dir" && as_dir=. 27050 for ac_exec_ext in '' $ac_executable_extensions; do 27051 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 27052 ac_cv_path_JAVA_CHECK="$as_dir/$ac_word$ac_exec_ext" 27053 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 27054 break 2 27055 fi 27056 done 27057 done 27058 IFS=$as_save_IFS 27059 27060 ;; 27061 esac 27062 fi 27063 JAVA_CHECK=$ac_cv_path_JAVA_CHECK 27064 if test -n "$JAVA_CHECK"; then 27065 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $JAVA_CHECK" >&5 27066 $as_echo "$JAVA_CHECK" >&6; } 27067 else 27068 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 27069 $as_echo "no" >&6; } 27070 fi 27071 27072 27073 BINARY="$JAVAC_CHECK" 27074 if test "x$JAVAC_CHECK" = x; then 27075 BINARY="$JAVA_CHECK" 27076 fi 27077 if test "x$BINARY" != x; then 27078 # So there is a java(c) binary, it might be part of a JDK. 27079 # Lets find the JDK/JRE directory by following symbolic links. 27080 # Linux/GNU systems often have links from /usr/bin/java to 27081 # /etc/alternatives/java to the real JDK binary. 27082 27083 if test "x$OPENJDK_BUILD_OS" != xwindows; then 27084 # Follow a chain of symbolic links. Use readlink 27085 # where it exists, else fall back to horribly 27086 # complicated shell code. 27087 if test "x$READLINK_TESTED" != yes; then 27088 # On MacOSX there is a readlink tool with a different 27089 # purpose than the GNU readlink tool. Check the found readlink. 27090 ISGNU=`$READLINK --version 2>&1 | $GREP GNU` 27091 if test "x$ISGNU" = x; then 27092 # A readlink that we do not know how to use. 27093 # Are there other non-GNU readlinks out there? 27094 READLINK_TESTED=yes 27095 READLINK= 27096 fi 27097 fi 27098 27099 if test "x$READLINK" != x; then 27100 BINARY=`$READLINK -f $BINARY` 27101 else 27102 # Save the current directory for restoring afterwards 27103 STARTDIR=$PWD 27104 COUNTER=0 27105 sym_link_dir=`$DIRNAME $BINARY` 27106 sym_link_file=`$BASENAME $BINARY` 27107 cd $sym_link_dir 27108 # Use -P flag to resolve symlinks in directories. 27109 cd `$THEPWDCMD -P` 27110 sym_link_dir=`$THEPWDCMD -P` 27111 # Resolve file symlinks 27112 while test $COUNTER -lt 20; do 27113 ISLINK=`$LS -l $sym_link_dir/$sym_link_file | $GREP '\->' | $SED -e 's/.*-> \(.*\)/\1/'` 27114 if test "x$ISLINK" == x; then 27115 # This is not a symbolic link! We are done! 27116 break 27117 fi 27118 # Again resolve directory symlinks since the target of the just found 27119 # link could be in a different directory 27120 cd `$DIRNAME $ISLINK` 27121 sym_link_dir=`$THEPWDCMD -P` 27122 sym_link_file=`$BASENAME $ISLINK` 27123 let COUNTER=COUNTER+1 27124 done 27125 cd $STARTDIR 27126 BINARY=$sym_link_dir/$sym_link_file 27127 fi 27128 fi 27129 27130 BOOT_JDK=`dirname "$BINARY"` 27131 BOOT_JDK=`cd "$BOOT_JDK/.."; pwd` 27132 if test -x "$BOOT_JDK/bin/javac" && test -x "$BOOT_JDK/bin/java"; then 27133 # Looks like we found ourselves an JDK 27134 BOOT_JDK_FOUND=maybe 27135 { $as_echo "$as_me:${as_lineno-$LINENO}: Found potential Boot JDK using java(c) in PATH" >&5 27136 $as_echo "$as_me: Found potential Boot JDK using java(c) in PATH" >&6;} 27137 fi 27138 fi 27139 27140 27141 # If previous step claimed to have found a JDK, check it to see if it seems to be valid. 27142 if test "x$BOOT_JDK_FOUND" = xmaybe; then 27143 # Do we have a bin/java? 27144 if test ! -x "$BOOT_JDK/bin/java"; then 27145 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&5 27146 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&6;} 27147 BOOT_JDK_FOUND=no 27148 else 27149 # Do we have a bin/javac? 27150 if test ! -x "$BOOT_JDK/bin/javac"; then 27151 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&5 27152 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&6;} 27153 { $as_echo "$as_me:${as_lineno-$LINENO}: (This might be an JRE instead of an JDK)" >&5 27154 $as_echo "$as_me: (This might be an JRE instead of an JDK)" >&6;} 27155 BOOT_JDK_FOUND=no 27156 else 27157 # Oh, this is looking good! We probably have found a proper JDK. Is it the correct version? 27158 BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | $HEAD -n 1` 27159 27160 # Extra M4 quote needed to protect [] in grep expression. 27161 FOUND_CORRECT_VERSION=`$ECHO $BOOT_JDK_VERSION | $EGREP '\"10([\.+-].*)?\"|\"9([\.+-].*)?\"'` 27162 if test "x$FOUND_CORRECT_VERSION" = x; then 27163 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&5 27164 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&6;} 27165 { $as_echo "$as_me:${as_lineno-$LINENO}: (Your Boot JDK must be version 9 or 10)" >&5 27166 $as_echo "$as_me: (Your Boot JDK must be version 9 or 10)" >&6;} 27167 BOOT_JDK_FOUND=no 27168 else 27169 # We're done! :-) 27170 BOOT_JDK_FOUND=yes 27171 27172 # Only process if variable expands to non-empty 27173 27174 if test "x$BOOT_JDK" != x; then 27175 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 27176 27177 # Input might be given as Windows format, start by converting to 27178 # unix format. 27179 path="$BOOT_JDK" 27180 new_path=`$CYGPATH -u "$path"` 27181 27182 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 27183 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 27184 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 27185 # "foo.exe" is OK but "foo" is an error. 27186 # 27187 # This test is therefore slightly more accurate than "test -f" to check for file precense. 27188 # It is also a way to make sure we got the proper file name for the real test later on. 27189 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 27190 if test "x$test_shortpath" = x; then 27191 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5 27192 $as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;} 27193 as_fn_error $? "Cannot locate the the path of BOOT_JDK" "$LINENO" 5 27194 fi 27195 27196 # Call helper function which possibly converts this using DOS-style short mode. 27197 # If so, the updated path is stored in $new_path. 27198 27199 input_path="$new_path" 27200 # Check if we need to convert this using DOS-style short mode. If the path 27201 # contains just simple characters, use it. Otherwise (spaces, weird characters), 27202 # take no chances and rewrite it. 27203 # Note: m4 eats our [], so we need to use [ and ] instead. 27204 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 27205 if test "x$has_forbidden_chars" != x; then 27206 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 27207 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 27208 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 27209 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 27210 # Going to short mode and back again did indeed matter. Since short mode is 27211 # case insensitive, let's make it lowercase to improve readability. 27212 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 27213 # Now convert it back to Unix-style (cygpath) 27214 input_path=`$CYGPATH -u "$shortmode_path"` 27215 new_path="$input_path" 27216 fi 27217 fi 27218 27219 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 27220 if test "x$test_cygdrive_prefix" = x; then 27221 # As a simple fix, exclude /usr/bin since it's not a real path. 27222 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 27223 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 27224 # a path prefixed by /cygdrive for fixpath to work. 27225 new_path="$CYGWIN_ROOT_PATH$input_path" 27226 fi 27227 fi 27228 27229 27230 if test "x$path" != "x$new_path"; then 27231 BOOT_JDK="$new_path" 27232 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5 27233 $as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;} 27234 fi 27235 27236 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 27237 27238 path="$BOOT_JDK" 27239 has_colon=`$ECHO $path | $GREP ^.:` 27240 new_path="$path" 27241 if test "x$has_colon" = x; then 27242 # Not in mixed or Windows style, start by that. 27243 new_path=`cmd //c echo $path` 27244 fi 27245 27246 27247 input_path="$new_path" 27248 # Check if we need to convert this using DOS-style short mode. If the path 27249 # contains just simple characters, use it. Otherwise (spaces, weird characters), 27250 # take no chances and rewrite it. 27251 # Note: m4 eats our [], so we need to use [ and ] instead. 27252 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 27253 if test "x$has_forbidden_chars" != x; then 27254 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 27255 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 27256 fi 27257 27258 27259 windows_path="$new_path" 27260 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 27261 unix_path=`$CYGPATH -u "$windows_path"` 27262 new_path="$unix_path" 27263 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 27264 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 27265 new_path="$unix_path" 27266 fi 27267 27268 if test "x$path" != "x$new_path"; then 27269 BOOT_JDK="$new_path" 27270 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5 27271 $as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;} 27272 fi 27273 27274 # Save the first 10 bytes of this path to the storage, so fixpath can work. 27275 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 27276 27277 else 27278 # We're on a unix platform. Hooray! :) 27279 path="$BOOT_JDK" 27280 has_space=`$ECHO "$path" | $GREP " "` 27281 if test "x$has_space" != x; then 27282 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5 27283 $as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;} 27284 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 27285 fi 27286 27287 # Use eval to expand a potential ~ 27288 eval path="$path" 27289 if test ! -f "$path" && test ! -d "$path"; then 27290 as_fn_error $? "The path of BOOT_JDK, which resolves as \"$path\", is not found." "$LINENO" 5 27291 fi 27292 27293 if test -d "$path"; then 27294 BOOT_JDK="`cd "$path"; $THEPWDCMD -L`" 27295 else 27296 dir="`$DIRNAME "$path"`" 27297 base="`$BASENAME "$path"`" 27298 BOOT_JDK="`cd "$dir"; $THEPWDCMD -L`/$base" 27299 fi 27300 fi 27301 fi 27302 27303 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for Boot JDK" >&5 27304 $as_echo_n "checking for Boot JDK... " >&6; } 27305 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK" >&5 27306 $as_echo "$BOOT_JDK" >&6; } 27307 { $as_echo "$as_me:${as_lineno-$LINENO}: checking Boot JDK version" >&5 27308 $as_echo_n "checking Boot JDK version... " >&6; } 27309 BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | $TR '\n\r' ' '` 27310 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK_VERSION" >&5 27311 $as_echo "$BOOT_JDK_VERSION" >&6; } 27312 fi # end check jdk version 27313 fi # end check javac 27314 fi # end check java 27315 fi # end check boot jdk found 27316 fi 27317 27318 27319 # Test: Is there a JDK installed in default, well-known locations? 27320 27321 if test "x$BOOT_JDK_FOUND" = xno; then 27322 # Now execute the test 27323 27324 if test "x$OPENJDK_TARGET_OS" = xwindows; then 27325 27326 if test "x$BOOT_JDK_FOUND" = xno; then 27327 # Now execute the test 27328 27329 if test "x$ProgramW6432" != x; then 27330 VIRTUAL_DIR="$ProgramW6432/Java" 27331 27332 windows_path="$VIRTUAL_DIR" 27333 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 27334 unix_path=`$CYGPATH -u "$windows_path"` 27335 VIRTUAL_DIR="$unix_path" 27336 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 27337 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 27338 VIRTUAL_DIR="$unix_path" 27339 fi 27340 27341 27342 BOOT_JDK_PREFIX="$VIRTUAL_DIR" 27343 BOOT_JDK_SUFFIX="" 27344 ALL_JDKS_FOUND=`$LS "$BOOT_JDK_PREFIX" 2> /dev/null | $SORT -r` 27345 if test "x$ALL_JDKS_FOUND" != x; then 27346 for JDK_TO_TRY in $ALL_JDKS_FOUND ; do 27347 27348 if test "x$BOOT_JDK_FOUND" = xno; then 27349 # Now execute the test 27350 27351 BOOT_JDK="${BOOT_JDK_PREFIX}/${JDK_TO_TRY}${BOOT_JDK_SUFFIX}" 27352 if test -d "$BOOT_JDK"; then 27353 BOOT_JDK_FOUND=maybe 27354 { $as_echo "$as_me:${as_lineno-$LINENO}: Found potential Boot JDK using well-known locations (in $BOOT_JDK_PREFIX/$JDK_TO_TRY)" >&5 27355 $as_echo "$as_me: Found potential Boot JDK using well-known locations (in $BOOT_JDK_PREFIX/$JDK_TO_TRY)" >&6;} 27356 fi 27357 27358 27359 # If previous step claimed to have found a JDK, check it to see if it seems to be valid. 27360 if test "x$BOOT_JDK_FOUND" = xmaybe; then 27361 # Do we have a bin/java? 27362 if test ! -x "$BOOT_JDK/bin/java"; then 27363 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&5 27364 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&6;} 27365 BOOT_JDK_FOUND=no 27366 else 27367 # Do we have a bin/javac? 27368 if test ! -x "$BOOT_JDK/bin/javac"; then 27369 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&5 27370 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&6;} 27371 { $as_echo "$as_me:${as_lineno-$LINENO}: (This might be an JRE instead of an JDK)" >&5 27372 $as_echo "$as_me: (This might be an JRE instead of an JDK)" >&6;} 27373 BOOT_JDK_FOUND=no 27374 else 27375 # Oh, this is looking good! We probably have found a proper JDK. Is it the correct version? 27376 BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | $HEAD -n 1` 27377 27378 # Extra M4 quote needed to protect [] in grep expression. 27379 FOUND_CORRECT_VERSION=`$ECHO $BOOT_JDK_VERSION | $EGREP '\"10([\.+-].*)?\"|\"9([\.+-].*)?\"'` 27380 if test "x$FOUND_CORRECT_VERSION" = x; then 27381 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&5 27382 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&6;} 27383 { $as_echo "$as_me:${as_lineno-$LINENO}: (Your Boot JDK must be version 9 or 10)" >&5 27384 $as_echo "$as_me: (Your Boot JDK must be version 9 or 10)" >&6;} 27385 BOOT_JDK_FOUND=no 27386 else 27387 # We're done! :-) 27388 BOOT_JDK_FOUND=yes 27389 27390 # Only process if variable expands to non-empty 27391 27392 if test "x$BOOT_JDK" != x; then 27393 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 27394 27395 # Input might be given as Windows format, start by converting to 27396 # unix format. 27397 path="$BOOT_JDK" 27398 new_path=`$CYGPATH -u "$path"` 27399 27400 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 27401 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 27402 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 27403 # "foo.exe" is OK but "foo" is an error. 27404 # 27405 # This test is therefore slightly more accurate than "test -f" to check for file precense. 27406 # It is also a way to make sure we got the proper file name for the real test later on. 27407 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 27408 if test "x$test_shortpath" = x; then 27409 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5 27410 $as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;} 27411 as_fn_error $? "Cannot locate the the path of BOOT_JDK" "$LINENO" 5 27412 fi 27413 27414 # Call helper function which possibly converts this using DOS-style short mode. 27415 # If so, the updated path is stored in $new_path. 27416 27417 input_path="$new_path" 27418 # Check if we need to convert this using DOS-style short mode. If the path 27419 # contains just simple characters, use it. Otherwise (spaces, weird characters), 27420 # take no chances and rewrite it. 27421 # Note: m4 eats our [], so we need to use [ and ] instead. 27422 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 27423 if test "x$has_forbidden_chars" != x; then 27424 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 27425 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 27426 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 27427 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 27428 # Going to short mode and back again did indeed matter. Since short mode is 27429 # case insensitive, let's make it lowercase to improve readability. 27430 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 27431 # Now convert it back to Unix-style (cygpath) 27432 input_path=`$CYGPATH -u "$shortmode_path"` 27433 new_path="$input_path" 27434 fi 27435 fi 27436 27437 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 27438 if test "x$test_cygdrive_prefix" = x; then 27439 # As a simple fix, exclude /usr/bin since it's not a real path. 27440 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 27441 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 27442 # a path prefixed by /cygdrive for fixpath to work. 27443 new_path="$CYGWIN_ROOT_PATH$input_path" 27444 fi 27445 fi 27446 27447 27448 if test "x$path" != "x$new_path"; then 27449 BOOT_JDK="$new_path" 27450 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5 27451 $as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;} 27452 fi 27453 27454 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 27455 27456 path="$BOOT_JDK" 27457 has_colon=`$ECHO $path | $GREP ^.:` 27458 new_path="$path" 27459 if test "x$has_colon" = x; then 27460 # Not in mixed or Windows style, start by that. 27461 new_path=`cmd //c echo $path` 27462 fi 27463 27464 27465 input_path="$new_path" 27466 # Check if we need to convert this using DOS-style short mode. If the path 27467 # contains just simple characters, use it. Otherwise (spaces, weird characters), 27468 # take no chances and rewrite it. 27469 # Note: m4 eats our [], so we need to use [ and ] instead. 27470 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 27471 if test "x$has_forbidden_chars" != x; then 27472 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 27473 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 27474 fi 27475 27476 27477 windows_path="$new_path" 27478 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 27479 unix_path=`$CYGPATH -u "$windows_path"` 27480 new_path="$unix_path" 27481 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 27482 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 27483 new_path="$unix_path" 27484 fi 27485 27486 if test "x$path" != "x$new_path"; then 27487 BOOT_JDK="$new_path" 27488 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5 27489 $as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;} 27490 fi 27491 27492 # Save the first 10 bytes of this path to the storage, so fixpath can work. 27493 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 27494 27495 else 27496 # We're on a unix platform. Hooray! :) 27497 path="$BOOT_JDK" 27498 has_space=`$ECHO "$path" | $GREP " "` 27499 if test "x$has_space" != x; then 27500 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5 27501 $as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;} 27502 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 27503 fi 27504 27505 # Use eval to expand a potential ~ 27506 eval path="$path" 27507 if test ! -f "$path" && test ! -d "$path"; then 27508 as_fn_error $? "The path of BOOT_JDK, which resolves as \"$path\", is not found." "$LINENO" 5 27509 fi 27510 27511 if test -d "$path"; then 27512 BOOT_JDK="`cd "$path"; $THEPWDCMD -L`" 27513 else 27514 dir="`$DIRNAME "$path"`" 27515 base="`$BASENAME "$path"`" 27516 BOOT_JDK="`cd "$dir"; $THEPWDCMD -L`/$base" 27517 fi 27518 fi 27519 fi 27520 27521 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for Boot JDK" >&5 27522 $as_echo_n "checking for Boot JDK... " >&6; } 27523 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK" >&5 27524 $as_echo "$BOOT_JDK" >&6; } 27525 { $as_echo "$as_me:${as_lineno-$LINENO}: checking Boot JDK version" >&5 27526 $as_echo_n "checking Boot JDK version... " >&6; } 27527 BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | $TR '\n\r' ' '` 27528 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK_VERSION" >&5 27529 $as_echo "$BOOT_JDK_VERSION" >&6; } 27530 fi # end check jdk version 27531 fi # end check javac 27532 fi # end check java 27533 fi # end check boot jdk found 27534 fi 27535 27536 done 27537 fi 27538 27539 fi 27540 27541 27542 # If previous step claimed to have found a JDK, check it to see if it seems to be valid. 27543 if test "x$BOOT_JDK_FOUND" = xmaybe; then 27544 # Do we have a bin/java? 27545 if test ! -x "$BOOT_JDK/bin/java"; then 27546 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&5 27547 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&6;} 27548 BOOT_JDK_FOUND=no 27549 else 27550 # Do we have a bin/javac? 27551 if test ! -x "$BOOT_JDK/bin/javac"; then 27552 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&5 27553 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&6;} 27554 { $as_echo "$as_me:${as_lineno-$LINENO}: (This might be an JRE instead of an JDK)" >&5 27555 $as_echo "$as_me: (This might be an JRE instead of an JDK)" >&6;} 27556 BOOT_JDK_FOUND=no 27557 else 27558 # Oh, this is looking good! We probably have found a proper JDK. Is it the correct version? 27559 BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | $HEAD -n 1` 27560 27561 # Extra M4 quote needed to protect [] in grep expression. 27562 FOUND_CORRECT_VERSION=`$ECHO $BOOT_JDK_VERSION | $EGREP '\"10([\.+-].*)?\"|\"9([\.+-].*)?\"'` 27563 if test "x$FOUND_CORRECT_VERSION" = x; then 27564 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&5 27565 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&6;} 27566 { $as_echo "$as_me:${as_lineno-$LINENO}: (Your Boot JDK must be version 9 or 10)" >&5 27567 $as_echo "$as_me: (Your Boot JDK must be version 9 or 10)" >&6;} 27568 BOOT_JDK_FOUND=no 27569 else 27570 # We're done! :-) 27571 BOOT_JDK_FOUND=yes 27572 27573 # Only process if variable expands to non-empty 27574 27575 if test "x$BOOT_JDK" != x; then 27576 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 27577 27578 # Input might be given as Windows format, start by converting to 27579 # unix format. 27580 path="$BOOT_JDK" 27581 new_path=`$CYGPATH -u "$path"` 27582 27583 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 27584 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 27585 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 27586 # "foo.exe" is OK but "foo" is an error. 27587 # 27588 # This test is therefore slightly more accurate than "test -f" to check for file precense. 27589 # It is also a way to make sure we got the proper file name for the real test later on. 27590 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 27591 if test "x$test_shortpath" = x; then 27592 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5 27593 $as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;} 27594 as_fn_error $? "Cannot locate the the path of BOOT_JDK" "$LINENO" 5 27595 fi 27596 27597 # Call helper function which possibly converts this using DOS-style short mode. 27598 # If so, the updated path is stored in $new_path. 27599 27600 input_path="$new_path" 27601 # Check if we need to convert this using DOS-style short mode. If the path 27602 # contains just simple characters, use it. Otherwise (spaces, weird characters), 27603 # take no chances and rewrite it. 27604 # Note: m4 eats our [], so we need to use [ and ] instead. 27605 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 27606 if test "x$has_forbidden_chars" != x; then 27607 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 27608 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 27609 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 27610 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 27611 # Going to short mode and back again did indeed matter. Since short mode is 27612 # case insensitive, let's make it lowercase to improve readability. 27613 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 27614 # Now convert it back to Unix-style (cygpath) 27615 input_path=`$CYGPATH -u "$shortmode_path"` 27616 new_path="$input_path" 27617 fi 27618 fi 27619 27620 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 27621 if test "x$test_cygdrive_prefix" = x; then 27622 # As a simple fix, exclude /usr/bin since it's not a real path. 27623 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 27624 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 27625 # a path prefixed by /cygdrive for fixpath to work. 27626 new_path="$CYGWIN_ROOT_PATH$input_path" 27627 fi 27628 fi 27629 27630 27631 if test "x$path" != "x$new_path"; then 27632 BOOT_JDK="$new_path" 27633 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5 27634 $as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;} 27635 fi 27636 27637 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 27638 27639 path="$BOOT_JDK" 27640 has_colon=`$ECHO $path | $GREP ^.:` 27641 new_path="$path" 27642 if test "x$has_colon" = x; then 27643 # Not in mixed or Windows style, start by that. 27644 new_path=`cmd //c echo $path` 27645 fi 27646 27647 27648 input_path="$new_path" 27649 # Check if we need to convert this using DOS-style short mode. If the path 27650 # contains just simple characters, use it. Otherwise (spaces, weird characters), 27651 # take no chances and rewrite it. 27652 # Note: m4 eats our [], so we need to use [ and ] instead. 27653 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 27654 if test "x$has_forbidden_chars" != x; then 27655 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 27656 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 27657 fi 27658 27659 27660 windows_path="$new_path" 27661 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 27662 unix_path=`$CYGPATH -u "$windows_path"` 27663 new_path="$unix_path" 27664 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 27665 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 27666 new_path="$unix_path" 27667 fi 27668 27669 if test "x$path" != "x$new_path"; then 27670 BOOT_JDK="$new_path" 27671 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5 27672 $as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;} 27673 fi 27674 27675 # Save the first 10 bytes of this path to the storage, so fixpath can work. 27676 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 27677 27678 else 27679 # We're on a unix platform. Hooray! :) 27680 path="$BOOT_JDK" 27681 has_space=`$ECHO "$path" | $GREP " "` 27682 if test "x$has_space" != x; then 27683 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5 27684 $as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;} 27685 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 27686 fi 27687 27688 # Use eval to expand a potential ~ 27689 eval path="$path" 27690 if test ! -f "$path" && test ! -d "$path"; then 27691 as_fn_error $? "The path of BOOT_JDK, which resolves as \"$path\", is not found." "$LINENO" 5 27692 fi 27693 27694 if test -d "$path"; then 27695 BOOT_JDK="`cd "$path"; $THEPWDCMD -L`" 27696 else 27697 dir="`$DIRNAME "$path"`" 27698 base="`$BASENAME "$path"`" 27699 BOOT_JDK="`cd "$dir"; $THEPWDCMD -L`/$base" 27700 fi 27701 fi 27702 fi 27703 27704 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for Boot JDK" >&5 27705 $as_echo_n "checking for Boot JDK... " >&6; } 27706 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK" >&5 27707 $as_echo "$BOOT_JDK" >&6; } 27708 { $as_echo "$as_me:${as_lineno-$LINENO}: checking Boot JDK version" >&5 27709 $as_echo_n "checking Boot JDK version... " >&6; } 27710 BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | $TR '\n\r' ' '` 27711 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK_VERSION" >&5 27712 $as_echo "$BOOT_JDK_VERSION" >&6; } 27713 fi # end check jdk version 27714 fi # end check javac 27715 fi # end check java 27716 fi # end check boot jdk found 27717 fi 27718 27719 27720 if test "x$BOOT_JDK_FOUND" = xno; then 27721 # Now execute the test 27722 27723 if test "x$PROGRAMW6432" != x; then 27724 VIRTUAL_DIR="$PROGRAMW6432/Java" 27725 27726 windows_path="$VIRTUAL_DIR" 27727 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 27728 unix_path=`$CYGPATH -u "$windows_path"` 27729 VIRTUAL_DIR="$unix_path" 27730 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 27731 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 27732 VIRTUAL_DIR="$unix_path" 27733 fi 27734 27735 27736 BOOT_JDK_PREFIX="$VIRTUAL_DIR" 27737 BOOT_JDK_SUFFIX="" 27738 ALL_JDKS_FOUND=`$LS "$BOOT_JDK_PREFIX" 2> /dev/null | $SORT -r` 27739 if test "x$ALL_JDKS_FOUND" != x; then 27740 for JDK_TO_TRY in $ALL_JDKS_FOUND ; do 27741 27742 if test "x$BOOT_JDK_FOUND" = xno; then 27743 # Now execute the test 27744 27745 BOOT_JDK="${BOOT_JDK_PREFIX}/${JDK_TO_TRY}${BOOT_JDK_SUFFIX}" 27746 if test -d "$BOOT_JDK"; then 27747 BOOT_JDK_FOUND=maybe 27748 { $as_echo "$as_me:${as_lineno-$LINENO}: Found potential Boot JDK using well-known locations (in $BOOT_JDK_PREFIX/$JDK_TO_TRY)" >&5 27749 $as_echo "$as_me: Found potential Boot JDK using well-known locations (in $BOOT_JDK_PREFIX/$JDK_TO_TRY)" >&6;} 27750 fi 27751 27752 27753 # If previous step claimed to have found a JDK, check it to see if it seems to be valid. 27754 if test "x$BOOT_JDK_FOUND" = xmaybe; then 27755 # Do we have a bin/java? 27756 if test ! -x "$BOOT_JDK/bin/java"; then 27757 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&5 27758 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&6;} 27759 BOOT_JDK_FOUND=no 27760 else 27761 # Do we have a bin/javac? 27762 if test ! -x "$BOOT_JDK/bin/javac"; then 27763 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&5 27764 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&6;} 27765 { $as_echo "$as_me:${as_lineno-$LINENO}: (This might be an JRE instead of an JDK)" >&5 27766 $as_echo "$as_me: (This might be an JRE instead of an JDK)" >&6;} 27767 BOOT_JDK_FOUND=no 27768 else 27769 # Oh, this is looking good! We probably have found a proper JDK. Is it the correct version? 27770 BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | $HEAD -n 1` 27771 27772 # Extra M4 quote needed to protect [] in grep expression. 27773 FOUND_CORRECT_VERSION=`$ECHO $BOOT_JDK_VERSION | $EGREP '\"10([\.+-].*)?\"|\"9([\.+-].*)?\"'` 27774 if test "x$FOUND_CORRECT_VERSION" = x; then 27775 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&5 27776 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&6;} 27777 { $as_echo "$as_me:${as_lineno-$LINENO}: (Your Boot JDK must be version 9 or 10)" >&5 27778 $as_echo "$as_me: (Your Boot JDK must be version 9 or 10)" >&6;} 27779 BOOT_JDK_FOUND=no 27780 else 27781 # We're done! :-) 27782 BOOT_JDK_FOUND=yes 27783 27784 # Only process if variable expands to non-empty 27785 27786 if test "x$BOOT_JDK" != x; then 27787 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 27788 27789 # Input might be given as Windows format, start by converting to 27790 # unix format. 27791 path="$BOOT_JDK" 27792 new_path=`$CYGPATH -u "$path"` 27793 27794 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 27795 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 27796 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 27797 # "foo.exe" is OK but "foo" is an error. 27798 # 27799 # This test is therefore slightly more accurate than "test -f" to check for file precense. 27800 # It is also a way to make sure we got the proper file name for the real test later on. 27801 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 27802 if test "x$test_shortpath" = x; then 27803 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5 27804 $as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;} 27805 as_fn_error $? "Cannot locate the the path of BOOT_JDK" "$LINENO" 5 27806 fi 27807 27808 # Call helper function which possibly converts this using DOS-style short mode. 27809 # If so, the updated path is stored in $new_path. 27810 27811 input_path="$new_path" 27812 # Check if we need to convert this using DOS-style short mode. If the path 27813 # contains just simple characters, use it. Otherwise (spaces, weird characters), 27814 # take no chances and rewrite it. 27815 # Note: m4 eats our [], so we need to use [ and ] instead. 27816 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 27817 if test "x$has_forbidden_chars" != x; then 27818 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 27819 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 27820 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 27821 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 27822 # Going to short mode and back again did indeed matter. Since short mode is 27823 # case insensitive, let's make it lowercase to improve readability. 27824 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 27825 # Now convert it back to Unix-style (cygpath) 27826 input_path=`$CYGPATH -u "$shortmode_path"` 27827 new_path="$input_path" 27828 fi 27829 fi 27830 27831 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 27832 if test "x$test_cygdrive_prefix" = x; then 27833 # As a simple fix, exclude /usr/bin since it's not a real path. 27834 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 27835 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 27836 # a path prefixed by /cygdrive for fixpath to work. 27837 new_path="$CYGWIN_ROOT_PATH$input_path" 27838 fi 27839 fi 27840 27841 27842 if test "x$path" != "x$new_path"; then 27843 BOOT_JDK="$new_path" 27844 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5 27845 $as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;} 27846 fi 27847 27848 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 27849 27850 path="$BOOT_JDK" 27851 has_colon=`$ECHO $path | $GREP ^.:` 27852 new_path="$path" 27853 if test "x$has_colon" = x; then 27854 # Not in mixed or Windows style, start by that. 27855 new_path=`cmd //c echo $path` 27856 fi 27857 27858 27859 input_path="$new_path" 27860 # Check if we need to convert this using DOS-style short mode. If the path 27861 # contains just simple characters, use it. Otherwise (spaces, weird characters), 27862 # take no chances and rewrite it. 27863 # Note: m4 eats our [], so we need to use [ and ] instead. 27864 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 27865 if test "x$has_forbidden_chars" != x; then 27866 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 27867 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 27868 fi 27869 27870 27871 windows_path="$new_path" 27872 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 27873 unix_path=`$CYGPATH -u "$windows_path"` 27874 new_path="$unix_path" 27875 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 27876 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 27877 new_path="$unix_path" 27878 fi 27879 27880 if test "x$path" != "x$new_path"; then 27881 BOOT_JDK="$new_path" 27882 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5 27883 $as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;} 27884 fi 27885 27886 # Save the first 10 bytes of this path to the storage, so fixpath can work. 27887 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 27888 27889 else 27890 # We're on a unix platform. Hooray! :) 27891 path="$BOOT_JDK" 27892 has_space=`$ECHO "$path" | $GREP " "` 27893 if test "x$has_space" != x; then 27894 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5 27895 $as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;} 27896 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 27897 fi 27898 27899 # Use eval to expand a potential ~ 27900 eval path="$path" 27901 if test ! -f "$path" && test ! -d "$path"; then 27902 as_fn_error $? "The path of BOOT_JDK, which resolves as \"$path\", is not found." "$LINENO" 5 27903 fi 27904 27905 if test -d "$path"; then 27906 BOOT_JDK="`cd "$path"; $THEPWDCMD -L`" 27907 else 27908 dir="`$DIRNAME "$path"`" 27909 base="`$BASENAME "$path"`" 27910 BOOT_JDK="`cd "$dir"; $THEPWDCMD -L`/$base" 27911 fi 27912 fi 27913 fi 27914 27915 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for Boot JDK" >&5 27916 $as_echo_n "checking for Boot JDK... " >&6; } 27917 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK" >&5 27918 $as_echo "$BOOT_JDK" >&6; } 27919 { $as_echo "$as_me:${as_lineno-$LINENO}: checking Boot JDK version" >&5 27920 $as_echo_n "checking Boot JDK version... " >&6; } 27921 BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | $TR '\n\r' ' '` 27922 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK_VERSION" >&5 27923 $as_echo "$BOOT_JDK_VERSION" >&6; } 27924 fi # end check jdk version 27925 fi # end check javac 27926 fi # end check java 27927 fi # end check boot jdk found 27928 fi 27929 27930 done 27931 fi 27932 27933 fi 27934 27935 27936 # If previous step claimed to have found a JDK, check it to see if it seems to be valid. 27937 if test "x$BOOT_JDK_FOUND" = xmaybe; then 27938 # Do we have a bin/java? 27939 if test ! -x "$BOOT_JDK/bin/java"; then 27940 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&5 27941 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&6;} 27942 BOOT_JDK_FOUND=no 27943 else 27944 # Do we have a bin/javac? 27945 if test ! -x "$BOOT_JDK/bin/javac"; then 27946 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&5 27947 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&6;} 27948 { $as_echo "$as_me:${as_lineno-$LINENO}: (This might be an JRE instead of an JDK)" >&5 27949 $as_echo "$as_me: (This might be an JRE instead of an JDK)" >&6;} 27950 BOOT_JDK_FOUND=no 27951 else 27952 # Oh, this is looking good! We probably have found a proper JDK. Is it the correct version? 27953 BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | $HEAD -n 1` 27954 27955 # Extra M4 quote needed to protect [] in grep expression. 27956 FOUND_CORRECT_VERSION=`$ECHO $BOOT_JDK_VERSION | $EGREP '\"10([\.+-].*)?\"|\"9([\.+-].*)?\"'` 27957 if test "x$FOUND_CORRECT_VERSION" = x; then 27958 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&5 27959 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&6;} 27960 { $as_echo "$as_me:${as_lineno-$LINENO}: (Your Boot JDK must be version 9 or 10)" >&5 27961 $as_echo "$as_me: (Your Boot JDK must be version 9 or 10)" >&6;} 27962 BOOT_JDK_FOUND=no 27963 else 27964 # We're done! :-) 27965 BOOT_JDK_FOUND=yes 27966 27967 # Only process if variable expands to non-empty 27968 27969 if test "x$BOOT_JDK" != x; then 27970 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 27971 27972 # Input might be given as Windows format, start by converting to 27973 # unix format. 27974 path="$BOOT_JDK" 27975 new_path=`$CYGPATH -u "$path"` 27976 27977 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 27978 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 27979 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 27980 # "foo.exe" is OK but "foo" is an error. 27981 # 27982 # This test is therefore slightly more accurate than "test -f" to check for file precense. 27983 # It is also a way to make sure we got the proper file name for the real test later on. 27984 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 27985 if test "x$test_shortpath" = x; then 27986 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5 27987 $as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;} 27988 as_fn_error $? "Cannot locate the the path of BOOT_JDK" "$LINENO" 5 27989 fi 27990 27991 # Call helper function which possibly converts this using DOS-style short mode. 27992 # If so, the updated path is stored in $new_path. 27993 27994 input_path="$new_path" 27995 # Check if we need to convert this using DOS-style short mode. If the path 27996 # contains just simple characters, use it. Otherwise (spaces, weird characters), 27997 # take no chances and rewrite it. 27998 # Note: m4 eats our [], so we need to use [ and ] instead. 27999 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 28000 if test "x$has_forbidden_chars" != x; then 28001 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 28002 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 28003 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 28004 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 28005 # Going to short mode and back again did indeed matter. Since short mode is 28006 # case insensitive, let's make it lowercase to improve readability. 28007 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 28008 # Now convert it back to Unix-style (cygpath) 28009 input_path=`$CYGPATH -u "$shortmode_path"` 28010 new_path="$input_path" 28011 fi 28012 fi 28013 28014 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 28015 if test "x$test_cygdrive_prefix" = x; then 28016 # As a simple fix, exclude /usr/bin since it's not a real path. 28017 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 28018 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 28019 # a path prefixed by /cygdrive for fixpath to work. 28020 new_path="$CYGWIN_ROOT_PATH$input_path" 28021 fi 28022 fi 28023 28024 28025 if test "x$path" != "x$new_path"; then 28026 BOOT_JDK="$new_path" 28027 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5 28028 $as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;} 28029 fi 28030 28031 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 28032 28033 path="$BOOT_JDK" 28034 has_colon=`$ECHO $path | $GREP ^.:` 28035 new_path="$path" 28036 if test "x$has_colon" = x; then 28037 # Not in mixed or Windows style, start by that. 28038 new_path=`cmd //c echo $path` 28039 fi 28040 28041 28042 input_path="$new_path" 28043 # Check if we need to convert this using DOS-style short mode. If the path 28044 # contains just simple characters, use it. Otherwise (spaces, weird characters), 28045 # take no chances and rewrite it. 28046 # Note: m4 eats our [], so we need to use [ and ] instead. 28047 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 28048 if test "x$has_forbidden_chars" != x; then 28049 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 28050 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 28051 fi 28052 28053 28054 windows_path="$new_path" 28055 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 28056 unix_path=`$CYGPATH -u "$windows_path"` 28057 new_path="$unix_path" 28058 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 28059 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 28060 new_path="$unix_path" 28061 fi 28062 28063 if test "x$path" != "x$new_path"; then 28064 BOOT_JDK="$new_path" 28065 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5 28066 $as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;} 28067 fi 28068 28069 # Save the first 10 bytes of this path to the storage, so fixpath can work. 28070 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 28071 28072 else 28073 # We're on a unix platform. Hooray! :) 28074 path="$BOOT_JDK" 28075 has_space=`$ECHO "$path" | $GREP " "` 28076 if test "x$has_space" != x; then 28077 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5 28078 $as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;} 28079 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 28080 fi 28081 28082 # Use eval to expand a potential ~ 28083 eval path="$path" 28084 if test ! -f "$path" && test ! -d "$path"; then 28085 as_fn_error $? "The path of BOOT_JDK, which resolves as \"$path\", is not found." "$LINENO" 5 28086 fi 28087 28088 if test -d "$path"; then 28089 BOOT_JDK="`cd "$path"; $THEPWDCMD -L`" 28090 else 28091 dir="`$DIRNAME "$path"`" 28092 base="`$BASENAME "$path"`" 28093 BOOT_JDK="`cd "$dir"; $THEPWDCMD -L`/$base" 28094 fi 28095 fi 28096 fi 28097 28098 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for Boot JDK" >&5 28099 $as_echo_n "checking for Boot JDK... " >&6; } 28100 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK" >&5 28101 $as_echo "$BOOT_JDK" >&6; } 28102 { $as_echo "$as_me:${as_lineno-$LINENO}: checking Boot JDK version" >&5 28103 $as_echo_n "checking Boot JDK version... " >&6; } 28104 BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | $TR '\n\r' ' '` 28105 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK_VERSION" >&5 28106 $as_echo "$BOOT_JDK_VERSION" >&6; } 28107 fi # end check jdk version 28108 fi # end check javac 28109 fi # end check java 28110 fi # end check boot jdk found 28111 fi 28112 28113 28114 if test "x$BOOT_JDK_FOUND" = xno; then 28115 # Now execute the test 28116 28117 if test "x$PROGRAMFILES" != x; then 28118 VIRTUAL_DIR="$PROGRAMFILES/Java" 28119 28120 windows_path="$VIRTUAL_DIR" 28121 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 28122 unix_path=`$CYGPATH -u "$windows_path"` 28123 VIRTUAL_DIR="$unix_path" 28124 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 28125 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 28126 VIRTUAL_DIR="$unix_path" 28127 fi 28128 28129 28130 BOOT_JDK_PREFIX="$VIRTUAL_DIR" 28131 BOOT_JDK_SUFFIX="" 28132 ALL_JDKS_FOUND=`$LS "$BOOT_JDK_PREFIX" 2> /dev/null | $SORT -r` 28133 if test "x$ALL_JDKS_FOUND" != x; then 28134 for JDK_TO_TRY in $ALL_JDKS_FOUND ; do 28135 28136 if test "x$BOOT_JDK_FOUND" = xno; then 28137 # Now execute the test 28138 28139 BOOT_JDK="${BOOT_JDK_PREFIX}/${JDK_TO_TRY}${BOOT_JDK_SUFFIX}" 28140 if test -d "$BOOT_JDK"; then 28141 BOOT_JDK_FOUND=maybe 28142 { $as_echo "$as_me:${as_lineno-$LINENO}: Found potential Boot JDK using well-known locations (in $BOOT_JDK_PREFIX/$JDK_TO_TRY)" >&5 28143 $as_echo "$as_me: Found potential Boot JDK using well-known locations (in $BOOT_JDK_PREFIX/$JDK_TO_TRY)" >&6;} 28144 fi 28145 28146 28147 # If previous step claimed to have found a JDK, check it to see if it seems to be valid. 28148 if test "x$BOOT_JDK_FOUND" = xmaybe; then 28149 # Do we have a bin/java? 28150 if test ! -x "$BOOT_JDK/bin/java"; then 28151 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&5 28152 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&6;} 28153 BOOT_JDK_FOUND=no 28154 else 28155 # Do we have a bin/javac? 28156 if test ! -x "$BOOT_JDK/bin/javac"; then 28157 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&5 28158 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&6;} 28159 { $as_echo "$as_me:${as_lineno-$LINENO}: (This might be an JRE instead of an JDK)" >&5 28160 $as_echo "$as_me: (This might be an JRE instead of an JDK)" >&6;} 28161 BOOT_JDK_FOUND=no 28162 else 28163 # Oh, this is looking good! We probably have found a proper JDK. Is it the correct version? 28164 BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | $HEAD -n 1` 28165 28166 # Extra M4 quote needed to protect [] in grep expression. 28167 FOUND_CORRECT_VERSION=`$ECHO $BOOT_JDK_VERSION | $EGREP '\"10([\.+-].*)?\"|\"9([\.+-].*)?\"'` 28168 if test "x$FOUND_CORRECT_VERSION" = x; then 28169 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&5 28170 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&6;} 28171 { $as_echo "$as_me:${as_lineno-$LINENO}: (Your Boot JDK must be version 9 or 10)" >&5 28172 $as_echo "$as_me: (Your Boot JDK must be version 9 or 10)" >&6;} 28173 BOOT_JDK_FOUND=no 28174 else 28175 # We're done! :-) 28176 BOOT_JDK_FOUND=yes 28177 28178 # Only process if variable expands to non-empty 28179 28180 if test "x$BOOT_JDK" != x; then 28181 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 28182 28183 # Input might be given as Windows format, start by converting to 28184 # unix format. 28185 path="$BOOT_JDK" 28186 new_path=`$CYGPATH -u "$path"` 28187 28188 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 28189 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 28190 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 28191 # "foo.exe" is OK but "foo" is an error. 28192 # 28193 # This test is therefore slightly more accurate than "test -f" to check for file precense. 28194 # It is also a way to make sure we got the proper file name for the real test later on. 28195 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 28196 if test "x$test_shortpath" = x; then 28197 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5 28198 $as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;} 28199 as_fn_error $? "Cannot locate the the path of BOOT_JDK" "$LINENO" 5 28200 fi 28201 28202 # Call helper function which possibly converts this using DOS-style short mode. 28203 # If so, the updated path is stored in $new_path. 28204 28205 input_path="$new_path" 28206 # Check if we need to convert this using DOS-style short mode. If the path 28207 # contains just simple characters, use it. Otherwise (spaces, weird characters), 28208 # take no chances and rewrite it. 28209 # Note: m4 eats our [], so we need to use [ and ] instead. 28210 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 28211 if test "x$has_forbidden_chars" != x; then 28212 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 28213 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 28214 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 28215 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 28216 # Going to short mode and back again did indeed matter. Since short mode is 28217 # case insensitive, let's make it lowercase to improve readability. 28218 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 28219 # Now convert it back to Unix-style (cygpath) 28220 input_path=`$CYGPATH -u "$shortmode_path"` 28221 new_path="$input_path" 28222 fi 28223 fi 28224 28225 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 28226 if test "x$test_cygdrive_prefix" = x; then 28227 # As a simple fix, exclude /usr/bin since it's not a real path. 28228 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 28229 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 28230 # a path prefixed by /cygdrive for fixpath to work. 28231 new_path="$CYGWIN_ROOT_PATH$input_path" 28232 fi 28233 fi 28234 28235 28236 if test "x$path" != "x$new_path"; then 28237 BOOT_JDK="$new_path" 28238 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5 28239 $as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;} 28240 fi 28241 28242 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 28243 28244 path="$BOOT_JDK" 28245 has_colon=`$ECHO $path | $GREP ^.:` 28246 new_path="$path" 28247 if test "x$has_colon" = x; then 28248 # Not in mixed or Windows style, start by that. 28249 new_path=`cmd //c echo $path` 28250 fi 28251 28252 28253 input_path="$new_path" 28254 # Check if we need to convert this using DOS-style short mode. If the path 28255 # contains just simple characters, use it. Otherwise (spaces, weird characters), 28256 # take no chances and rewrite it. 28257 # Note: m4 eats our [], so we need to use [ and ] instead. 28258 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 28259 if test "x$has_forbidden_chars" != x; then 28260 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 28261 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 28262 fi 28263 28264 28265 windows_path="$new_path" 28266 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 28267 unix_path=`$CYGPATH -u "$windows_path"` 28268 new_path="$unix_path" 28269 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 28270 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 28271 new_path="$unix_path" 28272 fi 28273 28274 if test "x$path" != "x$new_path"; then 28275 BOOT_JDK="$new_path" 28276 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5 28277 $as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;} 28278 fi 28279 28280 # Save the first 10 bytes of this path to the storage, so fixpath can work. 28281 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 28282 28283 else 28284 # We're on a unix platform. Hooray! :) 28285 path="$BOOT_JDK" 28286 has_space=`$ECHO "$path" | $GREP " "` 28287 if test "x$has_space" != x; then 28288 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5 28289 $as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;} 28290 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 28291 fi 28292 28293 # Use eval to expand a potential ~ 28294 eval path="$path" 28295 if test ! -f "$path" && test ! -d "$path"; then 28296 as_fn_error $? "The path of BOOT_JDK, which resolves as \"$path\", is not found." "$LINENO" 5 28297 fi 28298 28299 if test -d "$path"; then 28300 BOOT_JDK="`cd "$path"; $THEPWDCMD -L`" 28301 else 28302 dir="`$DIRNAME "$path"`" 28303 base="`$BASENAME "$path"`" 28304 BOOT_JDK="`cd "$dir"; $THEPWDCMD -L`/$base" 28305 fi 28306 fi 28307 fi 28308 28309 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for Boot JDK" >&5 28310 $as_echo_n "checking for Boot JDK... " >&6; } 28311 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK" >&5 28312 $as_echo "$BOOT_JDK" >&6; } 28313 { $as_echo "$as_me:${as_lineno-$LINENO}: checking Boot JDK version" >&5 28314 $as_echo_n "checking Boot JDK version... " >&6; } 28315 BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | $TR '\n\r' ' '` 28316 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK_VERSION" >&5 28317 $as_echo "$BOOT_JDK_VERSION" >&6; } 28318 fi # end check jdk version 28319 fi # end check javac 28320 fi # end check java 28321 fi # end check boot jdk found 28322 fi 28323 28324 done 28325 fi 28326 28327 fi 28328 28329 28330 # If previous step claimed to have found a JDK, check it to see if it seems to be valid. 28331 if test "x$BOOT_JDK_FOUND" = xmaybe; then 28332 # Do we have a bin/java? 28333 if test ! -x "$BOOT_JDK/bin/java"; then 28334 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&5 28335 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&6;} 28336 BOOT_JDK_FOUND=no 28337 else 28338 # Do we have a bin/javac? 28339 if test ! -x "$BOOT_JDK/bin/javac"; then 28340 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&5 28341 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&6;} 28342 { $as_echo "$as_me:${as_lineno-$LINENO}: (This might be an JRE instead of an JDK)" >&5 28343 $as_echo "$as_me: (This might be an JRE instead of an JDK)" >&6;} 28344 BOOT_JDK_FOUND=no 28345 else 28346 # Oh, this is looking good! We probably have found a proper JDK. Is it the correct version? 28347 BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | $HEAD -n 1` 28348 28349 # Extra M4 quote needed to protect [] in grep expression. 28350 FOUND_CORRECT_VERSION=`$ECHO $BOOT_JDK_VERSION | $EGREP '\"10([\.+-].*)?\"|\"9([\.+-].*)?\"'` 28351 if test "x$FOUND_CORRECT_VERSION" = x; then 28352 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&5 28353 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&6;} 28354 { $as_echo "$as_me:${as_lineno-$LINENO}: (Your Boot JDK must be version 9 or 10)" >&5 28355 $as_echo "$as_me: (Your Boot JDK must be version 9 or 10)" >&6;} 28356 BOOT_JDK_FOUND=no 28357 else 28358 # We're done! :-) 28359 BOOT_JDK_FOUND=yes 28360 28361 # Only process if variable expands to non-empty 28362 28363 if test "x$BOOT_JDK" != x; then 28364 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 28365 28366 # Input might be given as Windows format, start by converting to 28367 # unix format. 28368 path="$BOOT_JDK" 28369 new_path=`$CYGPATH -u "$path"` 28370 28371 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 28372 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 28373 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 28374 # "foo.exe" is OK but "foo" is an error. 28375 # 28376 # This test is therefore slightly more accurate than "test -f" to check for file precense. 28377 # It is also a way to make sure we got the proper file name for the real test later on. 28378 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 28379 if test "x$test_shortpath" = x; then 28380 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5 28381 $as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;} 28382 as_fn_error $? "Cannot locate the the path of BOOT_JDK" "$LINENO" 5 28383 fi 28384 28385 # Call helper function which possibly converts this using DOS-style short mode. 28386 # If so, the updated path is stored in $new_path. 28387 28388 input_path="$new_path" 28389 # Check if we need to convert this using DOS-style short mode. If the path 28390 # contains just simple characters, use it. Otherwise (spaces, weird characters), 28391 # take no chances and rewrite it. 28392 # Note: m4 eats our [], so we need to use [ and ] instead. 28393 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 28394 if test "x$has_forbidden_chars" != x; then 28395 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 28396 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 28397 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 28398 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 28399 # Going to short mode and back again did indeed matter. Since short mode is 28400 # case insensitive, let's make it lowercase to improve readability. 28401 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 28402 # Now convert it back to Unix-style (cygpath) 28403 input_path=`$CYGPATH -u "$shortmode_path"` 28404 new_path="$input_path" 28405 fi 28406 fi 28407 28408 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 28409 if test "x$test_cygdrive_prefix" = x; then 28410 # As a simple fix, exclude /usr/bin since it's not a real path. 28411 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 28412 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 28413 # a path prefixed by /cygdrive for fixpath to work. 28414 new_path="$CYGWIN_ROOT_PATH$input_path" 28415 fi 28416 fi 28417 28418 28419 if test "x$path" != "x$new_path"; then 28420 BOOT_JDK="$new_path" 28421 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5 28422 $as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;} 28423 fi 28424 28425 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 28426 28427 path="$BOOT_JDK" 28428 has_colon=`$ECHO $path | $GREP ^.:` 28429 new_path="$path" 28430 if test "x$has_colon" = x; then 28431 # Not in mixed or Windows style, start by that. 28432 new_path=`cmd //c echo $path` 28433 fi 28434 28435 28436 input_path="$new_path" 28437 # Check if we need to convert this using DOS-style short mode. If the path 28438 # contains just simple characters, use it. Otherwise (spaces, weird characters), 28439 # take no chances and rewrite it. 28440 # Note: m4 eats our [], so we need to use [ and ] instead. 28441 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 28442 if test "x$has_forbidden_chars" != x; then 28443 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 28444 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 28445 fi 28446 28447 28448 windows_path="$new_path" 28449 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 28450 unix_path=`$CYGPATH -u "$windows_path"` 28451 new_path="$unix_path" 28452 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 28453 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 28454 new_path="$unix_path" 28455 fi 28456 28457 if test "x$path" != "x$new_path"; then 28458 BOOT_JDK="$new_path" 28459 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5 28460 $as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;} 28461 fi 28462 28463 # Save the first 10 bytes of this path to the storage, so fixpath can work. 28464 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 28465 28466 else 28467 # We're on a unix platform. Hooray! :) 28468 path="$BOOT_JDK" 28469 has_space=`$ECHO "$path" | $GREP " "` 28470 if test "x$has_space" != x; then 28471 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5 28472 $as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;} 28473 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 28474 fi 28475 28476 # Use eval to expand a potential ~ 28477 eval path="$path" 28478 if test ! -f "$path" && test ! -d "$path"; then 28479 as_fn_error $? "The path of BOOT_JDK, which resolves as \"$path\", is not found." "$LINENO" 5 28480 fi 28481 28482 if test -d "$path"; then 28483 BOOT_JDK="`cd "$path"; $THEPWDCMD -L`" 28484 else 28485 dir="`$DIRNAME "$path"`" 28486 base="`$BASENAME "$path"`" 28487 BOOT_JDK="`cd "$dir"; $THEPWDCMD -L`/$base" 28488 fi 28489 fi 28490 fi 28491 28492 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for Boot JDK" >&5 28493 $as_echo_n "checking for Boot JDK... " >&6; } 28494 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK" >&5 28495 $as_echo "$BOOT_JDK" >&6; } 28496 { $as_echo "$as_me:${as_lineno-$LINENO}: checking Boot JDK version" >&5 28497 $as_echo_n "checking Boot JDK version... " >&6; } 28498 BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | $TR '\n\r' ' '` 28499 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK_VERSION" >&5 28500 $as_echo "$BOOT_JDK_VERSION" >&6; } 28501 fi # end check jdk version 28502 fi # end check javac 28503 fi # end check java 28504 fi # end check boot jdk found 28505 fi 28506 28507 28508 if test "x$BOOT_JDK_FOUND" = xno; then 28509 # Now execute the test 28510 28511 if test "x$ProgramFiles" != x; then 28512 VIRTUAL_DIR="$ProgramFiles/Java" 28513 28514 windows_path="$VIRTUAL_DIR" 28515 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 28516 unix_path=`$CYGPATH -u "$windows_path"` 28517 VIRTUAL_DIR="$unix_path" 28518 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 28519 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 28520 VIRTUAL_DIR="$unix_path" 28521 fi 28522 28523 28524 BOOT_JDK_PREFIX="$VIRTUAL_DIR" 28525 BOOT_JDK_SUFFIX="" 28526 ALL_JDKS_FOUND=`$LS "$BOOT_JDK_PREFIX" 2> /dev/null | $SORT -r` 28527 if test "x$ALL_JDKS_FOUND" != x; then 28528 for JDK_TO_TRY in $ALL_JDKS_FOUND ; do 28529 28530 if test "x$BOOT_JDK_FOUND" = xno; then 28531 # Now execute the test 28532 28533 BOOT_JDK="${BOOT_JDK_PREFIX}/${JDK_TO_TRY}${BOOT_JDK_SUFFIX}" 28534 if test -d "$BOOT_JDK"; then 28535 BOOT_JDK_FOUND=maybe 28536 { $as_echo "$as_me:${as_lineno-$LINENO}: Found potential Boot JDK using well-known locations (in $BOOT_JDK_PREFIX/$JDK_TO_TRY)" >&5 28537 $as_echo "$as_me: Found potential Boot JDK using well-known locations (in $BOOT_JDK_PREFIX/$JDK_TO_TRY)" >&6;} 28538 fi 28539 28540 28541 # If previous step claimed to have found a JDK, check it to see if it seems to be valid. 28542 if test "x$BOOT_JDK_FOUND" = xmaybe; then 28543 # Do we have a bin/java? 28544 if test ! -x "$BOOT_JDK/bin/java"; then 28545 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&5 28546 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&6;} 28547 BOOT_JDK_FOUND=no 28548 else 28549 # Do we have a bin/javac? 28550 if test ! -x "$BOOT_JDK/bin/javac"; then 28551 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&5 28552 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&6;} 28553 { $as_echo "$as_me:${as_lineno-$LINENO}: (This might be an JRE instead of an JDK)" >&5 28554 $as_echo "$as_me: (This might be an JRE instead of an JDK)" >&6;} 28555 BOOT_JDK_FOUND=no 28556 else 28557 # Oh, this is looking good! We probably have found a proper JDK. Is it the correct version? 28558 BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | $HEAD -n 1` 28559 28560 # Extra M4 quote needed to protect [] in grep expression. 28561 FOUND_CORRECT_VERSION=`$ECHO $BOOT_JDK_VERSION | $EGREP '\"10([\.+-].*)?\"|\"9([\.+-].*)?\"'` 28562 if test "x$FOUND_CORRECT_VERSION" = x; then 28563 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&5 28564 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&6;} 28565 { $as_echo "$as_me:${as_lineno-$LINENO}: (Your Boot JDK must be version 9 or 10)" >&5 28566 $as_echo "$as_me: (Your Boot JDK must be version 9 or 10)" >&6;} 28567 BOOT_JDK_FOUND=no 28568 else 28569 # We're done! :-) 28570 BOOT_JDK_FOUND=yes 28571 28572 # Only process if variable expands to non-empty 28573 28574 if test "x$BOOT_JDK" != x; then 28575 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 28576 28577 # Input might be given as Windows format, start by converting to 28578 # unix format. 28579 path="$BOOT_JDK" 28580 new_path=`$CYGPATH -u "$path"` 28581 28582 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 28583 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 28584 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 28585 # "foo.exe" is OK but "foo" is an error. 28586 # 28587 # This test is therefore slightly more accurate than "test -f" to check for file precense. 28588 # It is also a way to make sure we got the proper file name for the real test later on. 28589 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 28590 if test "x$test_shortpath" = x; then 28591 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5 28592 $as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;} 28593 as_fn_error $? "Cannot locate the the path of BOOT_JDK" "$LINENO" 5 28594 fi 28595 28596 # Call helper function which possibly converts this using DOS-style short mode. 28597 # If so, the updated path is stored in $new_path. 28598 28599 input_path="$new_path" 28600 # Check if we need to convert this using DOS-style short mode. If the path 28601 # contains just simple characters, use it. Otherwise (spaces, weird characters), 28602 # take no chances and rewrite it. 28603 # Note: m4 eats our [], so we need to use [ and ] instead. 28604 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 28605 if test "x$has_forbidden_chars" != x; then 28606 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 28607 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 28608 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 28609 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 28610 # Going to short mode and back again did indeed matter. Since short mode is 28611 # case insensitive, let's make it lowercase to improve readability. 28612 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 28613 # Now convert it back to Unix-style (cygpath) 28614 input_path=`$CYGPATH -u "$shortmode_path"` 28615 new_path="$input_path" 28616 fi 28617 fi 28618 28619 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 28620 if test "x$test_cygdrive_prefix" = x; then 28621 # As a simple fix, exclude /usr/bin since it's not a real path. 28622 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 28623 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 28624 # a path prefixed by /cygdrive for fixpath to work. 28625 new_path="$CYGWIN_ROOT_PATH$input_path" 28626 fi 28627 fi 28628 28629 28630 if test "x$path" != "x$new_path"; then 28631 BOOT_JDK="$new_path" 28632 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5 28633 $as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;} 28634 fi 28635 28636 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 28637 28638 path="$BOOT_JDK" 28639 has_colon=`$ECHO $path | $GREP ^.:` 28640 new_path="$path" 28641 if test "x$has_colon" = x; then 28642 # Not in mixed or Windows style, start by that. 28643 new_path=`cmd //c echo $path` 28644 fi 28645 28646 28647 input_path="$new_path" 28648 # Check if we need to convert this using DOS-style short mode. If the path 28649 # contains just simple characters, use it. Otherwise (spaces, weird characters), 28650 # take no chances and rewrite it. 28651 # Note: m4 eats our [], so we need to use [ and ] instead. 28652 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 28653 if test "x$has_forbidden_chars" != x; then 28654 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 28655 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 28656 fi 28657 28658 28659 windows_path="$new_path" 28660 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 28661 unix_path=`$CYGPATH -u "$windows_path"` 28662 new_path="$unix_path" 28663 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 28664 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 28665 new_path="$unix_path" 28666 fi 28667 28668 if test "x$path" != "x$new_path"; then 28669 BOOT_JDK="$new_path" 28670 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5 28671 $as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;} 28672 fi 28673 28674 # Save the first 10 bytes of this path to the storage, so fixpath can work. 28675 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 28676 28677 else 28678 # We're on a unix platform. Hooray! :) 28679 path="$BOOT_JDK" 28680 has_space=`$ECHO "$path" | $GREP " "` 28681 if test "x$has_space" != x; then 28682 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5 28683 $as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;} 28684 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 28685 fi 28686 28687 # Use eval to expand a potential ~ 28688 eval path="$path" 28689 if test ! -f "$path" && test ! -d "$path"; then 28690 as_fn_error $? "The path of BOOT_JDK, which resolves as \"$path\", is not found." "$LINENO" 5 28691 fi 28692 28693 if test -d "$path"; then 28694 BOOT_JDK="`cd "$path"; $THEPWDCMD -L`" 28695 else 28696 dir="`$DIRNAME "$path"`" 28697 base="`$BASENAME "$path"`" 28698 BOOT_JDK="`cd "$dir"; $THEPWDCMD -L`/$base" 28699 fi 28700 fi 28701 fi 28702 28703 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for Boot JDK" >&5 28704 $as_echo_n "checking for Boot JDK... " >&6; } 28705 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK" >&5 28706 $as_echo "$BOOT_JDK" >&6; } 28707 { $as_echo "$as_me:${as_lineno-$LINENO}: checking Boot JDK version" >&5 28708 $as_echo_n "checking Boot JDK version... " >&6; } 28709 BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | $TR '\n\r' ' '` 28710 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK_VERSION" >&5 28711 $as_echo "$BOOT_JDK_VERSION" >&6; } 28712 fi # end check jdk version 28713 fi # end check javac 28714 fi # end check java 28715 fi # end check boot jdk found 28716 fi 28717 28718 done 28719 fi 28720 28721 fi 28722 28723 28724 # If previous step claimed to have found a JDK, check it to see if it seems to be valid. 28725 if test "x$BOOT_JDK_FOUND" = xmaybe; then 28726 # Do we have a bin/java? 28727 if test ! -x "$BOOT_JDK/bin/java"; then 28728 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&5 28729 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&6;} 28730 BOOT_JDK_FOUND=no 28731 else 28732 # Do we have a bin/javac? 28733 if test ! -x "$BOOT_JDK/bin/javac"; then 28734 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&5 28735 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&6;} 28736 { $as_echo "$as_me:${as_lineno-$LINENO}: (This might be an JRE instead of an JDK)" >&5 28737 $as_echo "$as_me: (This might be an JRE instead of an JDK)" >&6;} 28738 BOOT_JDK_FOUND=no 28739 else 28740 # Oh, this is looking good! We probably have found a proper JDK. Is it the correct version? 28741 BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | $HEAD -n 1` 28742 28743 # Extra M4 quote needed to protect [] in grep expression. 28744 FOUND_CORRECT_VERSION=`$ECHO $BOOT_JDK_VERSION | $EGREP '\"10([\.+-].*)?\"|\"9([\.+-].*)?\"'` 28745 if test "x$FOUND_CORRECT_VERSION" = x; then 28746 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&5 28747 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&6;} 28748 { $as_echo "$as_me:${as_lineno-$LINENO}: (Your Boot JDK must be version 9 or 10)" >&5 28749 $as_echo "$as_me: (Your Boot JDK must be version 9 or 10)" >&6;} 28750 BOOT_JDK_FOUND=no 28751 else 28752 # We're done! :-) 28753 BOOT_JDK_FOUND=yes 28754 28755 # Only process if variable expands to non-empty 28756 28757 if test "x$BOOT_JDK" != x; then 28758 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 28759 28760 # Input might be given as Windows format, start by converting to 28761 # unix format. 28762 path="$BOOT_JDK" 28763 new_path=`$CYGPATH -u "$path"` 28764 28765 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 28766 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 28767 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 28768 # "foo.exe" is OK but "foo" is an error. 28769 # 28770 # This test is therefore slightly more accurate than "test -f" to check for file precense. 28771 # It is also a way to make sure we got the proper file name for the real test later on. 28772 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 28773 if test "x$test_shortpath" = x; then 28774 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5 28775 $as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;} 28776 as_fn_error $? "Cannot locate the the path of BOOT_JDK" "$LINENO" 5 28777 fi 28778 28779 # Call helper function which possibly converts this using DOS-style short mode. 28780 # If so, the updated path is stored in $new_path. 28781 28782 input_path="$new_path" 28783 # Check if we need to convert this using DOS-style short mode. If the path 28784 # contains just simple characters, use it. Otherwise (spaces, weird characters), 28785 # take no chances and rewrite it. 28786 # Note: m4 eats our [], so we need to use [ and ] instead. 28787 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 28788 if test "x$has_forbidden_chars" != x; then 28789 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 28790 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 28791 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 28792 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 28793 # Going to short mode and back again did indeed matter. Since short mode is 28794 # case insensitive, let's make it lowercase to improve readability. 28795 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 28796 # Now convert it back to Unix-style (cygpath) 28797 input_path=`$CYGPATH -u "$shortmode_path"` 28798 new_path="$input_path" 28799 fi 28800 fi 28801 28802 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 28803 if test "x$test_cygdrive_prefix" = x; then 28804 # As a simple fix, exclude /usr/bin since it's not a real path. 28805 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 28806 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 28807 # a path prefixed by /cygdrive for fixpath to work. 28808 new_path="$CYGWIN_ROOT_PATH$input_path" 28809 fi 28810 fi 28811 28812 28813 if test "x$path" != "x$new_path"; then 28814 BOOT_JDK="$new_path" 28815 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5 28816 $as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;} 28817 fi 28818 28819 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 28820 28821 path="$BOOT_JDK" 28822 has_colon=`$ECHO $path | $GREP ^.:` 28823 new_path="$path" 28824 if test "x$has_colon" = x; then 28825 # Not in mixed or Windows style, start by that. 28826 new_path=`cmd //c echo $path` 28827 fi 28828 28829 28830 input_path="$new_path" 28831 # Check if we need to convert this using DOS-style short mode. If the path 28832 # contains just simple characters, use it. Otherwise (spaces, weird characters), 28833 # take no chances and rewrite it. 28834 # Note: m4 eats our [], so we need to use [ and ] instead. 28835 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 28836 if test "x$has_forbidden_chars" != x; then 28837 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 28838 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 28839 fi 28840 28841 28842 windows_path="$new_path" 28843 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 28844 unix_path=`$CYGPATH -u "$windows_path"` 28845 new_path="$unix_path" 28846 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 28847 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 28848 new_path="$unix_path" 28849 fi 28850 28851 if test "x$path" != "x$new_path"; then 28852 BOOT_JDK="$new_path" 28853 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5 28854 $as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;} 28855 fi 28856 28857 # Save the first 10 bytes of this path to the storage, so fixpath can work. 28858 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 28859 28860 else 28861 # We're on a unix platform. Hooray! :) 28862 path="$BOOT_JDK" 28863 has_space=`$ECHO "$path" | $GREP " "` 28864 if test "x$has_space" != x; then 28865 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5 28866 $as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;} 28867 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 28868 fi 28869 28870 # Use eval to expand a potential ~ 28871 eval path="$path" 28872 if test ! -f "$path" && test ! -d "$path"; then 28873 as_fn_error $? "The path of BOOT_JDK, which resolves as \"$path\", is not found." "$LINENO" 5 28874 fi 28875 28876 if test -d "$path"; then 28877 BOOT_JDK="`cd "$path"; $THEPWDCMD -L`" 28878 else 28879 dir="`$DIRNAME "$path"`" 28880 base="`$BASENAME "$path"`" 28881 BOOT_JDK="`cd "$dir"; $THEPWDCMD -L`/$base" 28882 fi 28883 fi 28884 fi 28885 28886 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for Boot JDK" >&5 28887 $as_echo_n "checking for Boot JDK... " >&6; } 28888 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK" >&5 28889 $as_echo "$BOOT_JDK" >&6; } 28890 { $as_echo "$as_me:${as_lineno-$LINENO}: checking Boot JDK version" >&5 28891 $as_echo_n "checking Boot JDK version... " >&6; } 28892 BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | $TR '\n\r' ' '` 28893 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK_VERSION" >&5 28894 $as_echo "$BOOT_JDK_VERSION" >&6; } 28895 fi # end check jdk version 28896 fi # end check javac 28897 fi # end check java 28898 fi # end check boot jdk found 28899 fi 28900 28901 28902 if test "x$BOOT_JDK_FOUND" = xno; then 28903 # Now execute the test 28904 28905 BOOT_JDK_PREFIX="/cygdrive/c/Program Files/Java" 28906 BOOT_JDK_SUFFIX="" 28907 ALL_JDKS_FOUND=`$LS "$BOOT_JDK_PREFIX" 2> /dev/null | $SORT -r` 28908 if test "x$ALL_JDKS_FOUND" != x; then 28909 for JDK_TO_TRY in $ALL_JDKS_FOUND ; do 28910 28911 if test "x$BOOT_JDK_FOUND" = xno; then 28912 # Now execute the test 28913 28914 BOOT_JDK="${BOOT_JDK_PREFIX}/${JDK_TO_TRY}${BOOT_JDK_SUFFIX}" 28915 if test -d "$BOOT_JDK"; then 28916 BOOT_JDK_FOUND=maybe 28917 { $as_echo "$as_me:${as_lineno-$LINENO}: Found potential Boot JDK using well-known locations (in $BOOT_JDK_PREFIX/$JDK_TO_TRY)" >&5 28918 $as_echo "$as_me: Found potential Boot JDK using well-known locations (in $BOOT_JDK_PREFIX/$JDK_TO_TRY)" >&6;} 28919 fi 28920 28921 28922 # If previous step claimed to have found a JDK, check it to see if it seems to be valid. 28923 if test "x$BOOT_JDK_FOUND" = xmaybe; then 28924 # Do we have a bin/java? 28925 if test ! -x "$BOOT_JDK/bin/java"; then 28926 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&5 28927 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&6;} 28928 BOOT_JDK_FOUND=no 28929 else 28930 # Do we have a bin/javac? 28931 if test ! -x "$BOOT_JDK/bin/javac"; then 28932 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&5 28933 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&6;} 28934 { $as_echo "$as_me:${as_lineno-$LINENO}: (This might be an JRE instead of an JDK)" >&5 28935 $as_echo "$as_me: (This might be an JRE instead of an JDK)" >&6;} 28936 BOOT_JDK_FOUND=no 28937 else 28938 # Oh, this is looking good! We probably have found a proper JDK. Is it the correct version? 28939 BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | $HEAD -n 1` 28940 28941 # Extra M4 quote needed to protect [] in grep expression. 28942 FOUND_CORRECT_VERSION=`$ECHO $BOOT_JDK_VERSION | $EGREP '\"10([\.+-].*)?\"|\"9([\.+-].*)?\"'` 28943 if test "x$FOUND_CORRECT_VERSION" = x; then 28944 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&5 28945 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&6;} 28946 { $as_echo "$as_me:${as_lineno-$LINENO}: (Your Boot JDK must be version 9 or 10)" >&5 28947 $as_echo "$as_me: (Your Boot JDK must be version 9 or 10)" >&6;} 28948 BOOT_JDK_FOUND=no 28949 else 28950 # We're done! :-) 28951 BOOT_JDK_FOUND=yes 28952 28953 # Only process if variable expands to non-empty 28954 28955 if test "x$BOOT_JDK" != x; then 28956 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 28957 28958 # Input might be given as Windows format, start by converting to 28959 # unix format. 28960 path="$BOOT_JDK" 28961 new_path=`$CYGPATH -u "$path"` 28962 28963 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 28964 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 28965 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 28966 # "foo.exe" is OK but "foo" is an error. 28967 # 28968 # This test is therefore slightly more accurate than "test -f" to check for file precense. 28969 # It is also a way to make sure we got the proper file name for the real test later on. 28970 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 28971 if test "x$test_shortpath" = x; then 28972 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5 28973 $as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;} 28974 as_fn_error $? "Cannot locate the the path of BOOT_JDK" "$LINENO" 5 28975 fi 28976 28977 # Call helper function which possibly converts this using DOS-style short mode. 28978 # If so, the updated path is stored in $new_path. 28979 28980 input_path="$new_path" 28981 # Check if we need to convert this using DOS-style short mode. If the path 28982 # contains just simple characters, use it. Otherwise (spaces, weird characters), 28983 # take no chances and rewrite it. 28984 # Note: m4 eats our [], so we need to use [ and ] instead. 28985 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 28986 if test "x$has_forbidden_chars" != x; then 28987 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 28988 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 28989 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 28990 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 28991 # Going to short mode and back again did indeed matter. Since short mode is 28992 # case insensitive, let's make it lowercase to improve readability. 28993 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 28994 # Now convert it back to Unix-style (cygpath) 28995 input_path=`$CYGPATH -u "$shortmode_path"` 28996 new_path="$input_path" 28997 fi 28998 fi 28999 29000 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 29001 if test "x$test_cygdrive_prefix" = x; then 29002 # As a simple fix, exclude /usr/bin since it's not a real path. 29003 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 29004 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 29005 # a path prefixed by /cygdrive for fixpath to work. 29006 new_path="$CYGWIN_ROOT_PATH$input_path" 29007 fi 29008 fi 29009 29010 29011 if test "x$path" != "x$new_path"; then 29012 BOOT_JDK="$new_path" 29013 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5 29014 $as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;} 29015 fi 29016 29017 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 29018 29019 path="$BOOT_JDK" 29020 has_colon=`$ECHO $path | $GREP ^.:` 29021 new_path="$path" 29022 if test "x$has_colon" = x; then 29023 # Not in mixed or Windows style, start by that. 29024 new_path=`cmd //c echo $path` 29025 fi 29026 29027 29028 input_path="$new_path" 29029 # Check if we need to convert this using DOS-style short mode. If the path 29030 # contains just simple characters, use it. Otherwise (spaces, weird characters), 29031 # take no chances and rewrite it. 29032 # Note: m4 eats our [], so we need to use [ and ] instead. 29033 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 29034 if test "x$has_forbidden_chars" != x; then 29035 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 29036 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 29037 fi 29038 29039 29040 windows_path="$new_path" 29041 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 29042 unix_path=`$CYGPATH -u "$windows_path"` 29043 new_path="$unix_path" 29044 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 29045 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 29046 new_path="$unix_path" 29047 fi 29048 29049 if test "x$path" != "x$new_path"; then 29050 BOOT_JDK="$new_path" 29051 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5 29052 $as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;} 29053 fi 29054 29055 # Save the first 10 bytes of this path to the storage, so fixpath can work. 29056 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 29057 29058 else 29059 # We're on a unix platform. Hooray! :) 29060 path="$BOOT_JDK" 29061 has_space=`$ECHO "$path" | $GREP " "` 29062 if test "x$has_space" != x; then 29063 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5 29064 $as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;} 29065 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 29066 fi 29067 29068 # Use eval to expand a potential ~ 29069 eval path="$path" 29070 if test ! -f "$path" && test ! -d "$path"; then 29071 as_fn_error $? "The path of BOOT_JDK, which resolves as \"$path\", is not found." "$LINENO" 5 29072 fi 29073 29074 if test -d "$path"; then 29075 BOOT_JDK="`cd "$path"; $THEPWDCMD -L`" 29076 else 29077 dir="`$DIRNAME "$path"`" 29078 base="`$BASENAME "$path"`" 29079 BOOT_JDK="`cd "$dir"; $THEPWDCMD -L`/$base" 29080 fi 29081 fi 29082 fi 29083 29084 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for Boot JDK" >&5 29085 $as_echo_n "checking for Boot JDK... " >&6; } 29086 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK" >&5 29087 $as_echo "$BOOT_JDK" >&6; } 29088 { $as_echo "$as_me:${as_lineno-$LINENO}: checking Boot JDK version" >&5 29089 $as_echo_n "checking Boot JDK version... " >&6; } 29090 BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | $TR '\n\r' ' '` 29091 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK_VERSION" >&5 29092 $as_echo "$BOOT_JDK_VERSION" >&6; } 29093 fi # end check jdk version 29094 fi # end check javac 29095 fi # end check java 29096 fi # end check boot jdk found 29097 fi 29098 29099 done 29100 fi 29101 29102 29103 # If previous step claimed to have found a JDK, check it to see if it seems to be valid. 29104 if test "x$BOOT_JDK_FOUND" = xmaybe; then 29105 # Do we have a bin/java? 29106 if test ! -x "$BOOT_JDK/bin/java"; then 29107 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&5 29108 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&6;} 29109 BOOT_JDK_FOUND=no 29110 else 29111 # Do we have a bin/javac? 29112 if test ! -x "$BOOT_JDK/bin/javac"; then 29113 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&5 29114 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&6;} 29115 { $as_echo "$as_me:${as_lineno-$LINENO}: (This might be an JRE instead of an JDK)" >&5 29116 $as_echo "$as_me: (This might be an JRE instead of an JDK)" >&6;} 29117 BOOT_JDK_FOUND=no 29118 else 29119 # Oh, this is looking good! We probably have found a proper JDK. Is it the correct version? 29120 BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | $HEAD -n 1` 29121 29122 # Extra M4 quote needed to protect [] in grep expression. 29123 FOUND_CORRECT_VERSION=`$ECHO $BOOT_JDK_VERSION | $EGREP '\"10([\.+-].*)?\"|\"9([\.+-].*)?\"'` 29124 if test "x$FOUND_CORRECT_VERSION" = x; then 29125 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&5 29126 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&6;} 29127 { $as_echo "$as_me:${as_lineno-$LINENO}: (Your Boot JDK must be version 9 or 10)" >&5 29128 $as_echo "$as_me: (Your Boot JDK must be version 9 or 10)" >&6;} 29129 BOOT_JDK_FOUND=no 29130 else 29131 # We're done! :-) 29132 BOOT_JDK_FOUND=yes 29133 29134 # Only process if variable expands to non-empty 29135 29136 if test "x$BOOT_JDK" != x; then 29137 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 29138 29139 # Input might be given as Windows format, start by converting to 29140 # unix format. 29141 path="$BOOT_JDK" 29142 new_path=`$CYGPATH -u "$path"` 29143 29144 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 29145 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 29146 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 29147 # "foo.exe" is OK but "foo" is an error. 29148 # 29149 # This test is therefore slightly more accurate than "test -f" to check for file precense. 29150 # It is also a way to make sure we got the proper file name for the real test later on. 29151 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 29152 if test "x$test_shortpath" = x; then 29153 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5 29154 $as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;} 29155 as_fn_error $? "Cannot locate the the path of BOOT_JDK" "$LINENO" 5 29156 fi 29157 29158 # Call helper function which possibly converts this using DOS-style short mode. 29159 # If so, the updated path is stored in $new_path. 29160 29161 input_path="$new_path" 29162 # Check if we need to convert this using DOS-style short mode. If the path 29163 # contains just simple characters, use it. Otherwise (spaces, weird characters), 29164 # take no chances and rewrite it. 29165 # Note: m4 eats our [], so we need to use [ and ] instead. 29166 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 29167 if test "x$has_forbidden_chars" != x; then 29168 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 29169 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 29170 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 29171 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 29172 # Going to short mode and back again did indeed matter. Since short mode is 29173 # case insensitive, let's make it lowercase to improve readability. 29174 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 29175 # Now convert it back to Unix-style (cygpath) 29176 input_path=`$CYGPATH -u "$shortmode_path"` 29177 new_path="$input_path" 29178 fi 29179 fi 29180 29181 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 29182 if test "x$test_cygdrive_prefix" = x; then 29183 # As a simple fix, exclude /usr/bin since it's not a real path. 29184 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 29185 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 29186 # a path prefixed by /cygdrive for fixpath to work. 29187 new_path="$CYGWIN_ROOT_PATH$input_path" 29188 fi 29189 fi 29190 29191 29192 if test "x$path" != "x$new_path"; then 29193 BOOT_JDK="$new_path" 29194 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5 29195 $as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;} 29196 fi 29197 29198 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 29199 29200 path="$BOOT_JDK" 29201 has_colon=`$ECHO $path | $GREP ^.:` 29202 new_path="$path" 29203 if test "x$has_colon" = x; then 29204 # Not in mixed or Windows style, start by that. 29205 new_path=`cmd //c echo $path` 29206 fi 29207 29208 29209 input_path="$new_path" 29210 # Check if we need to convert this using DOS-style short mode. If the path 29211 # contains just simple characters, use it. Otherwise (spaces, weird characters), 29212 # take no chances and rewrite it. 29213 # Note: m4 eats our [], so we need to use [ and ] instead. 29214 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 29215 if test "x$has_forbidden_chars" != x; then 29216 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 29217 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 29218 fi 29219 29220 29221 windows_path="$new_path" 29222 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 29223 unix_path=`$CYGPATH -u "$windows_path"` 29224 new_path="$unix_path" 29225 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 29226 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 29227 new_path="$unix_path" 29228 fi 29229 29230 if test "x$path" != "x$new_path"; then 29231 BOOT_JDK="$new_path" 29232 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5 29233 $as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;} 29234 fi 29235 29236 # Save the first 10 bytes of this path to the storage, so fixpath can work. 29237 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 29238 29239 else 29240 # We're on a unix platform. Hooray! :) 29241 path="$BOOT_JDK" 29242 has_space=`$ECHO "$path" | $GREP " "` 29243 if test "x$has_space" != x; then 29244 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5 29245 $as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;} 29246 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 29247 fi 29248 29249 # Use eval to expand a potential ~ 29250 eval path="$path" 29251 if test ! -f "$path" && test ! -d "$path"; then 29252 as_fn_error $? "The path of BOOT_JDK, which resolves as \"$path\", is not found." "$LINENO" 5 29253 fi 29254 29255 if test -d "$path"; then 29256 BOOT_JDK="`cd "$path"; $THEPWDCMD -L`" 29257 else 29258 dir="`$DIRNAME "$path"`" 29259 base="`$BASENAME "$path"`" 29260 BOOT_JDK="`cd "$dir"; $THEPWDCMD -L`/$base" 29261 fi 29262 fi 29263 fi 29264 29265 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for Boot JDK" >&5 29266 $as_echo_n "checking for Boot JDK... " >&6; } 29267 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK" >&5 29268 $as_echo "$BOOT_JDK" >&6; } 29269 { $as_echo "$as_me:${as_lineno-$LINENO}: checking Boot JDK version" >&5 29270 $as_echo_n "checking Boot JDK version... " >&6; } 29271 BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | $TR '\n\r' ' '` 29272 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK_VERSION" >&5 29273 $as_echo "$BOOT_JDK_VERSION" >&6; } 29274 fi # end check jdk version 29275 fi # end check javac 29276 fi # end check java 29277 fi # end check boot jdk found 29278 fi 29279 29280 elif test "x$OPENJDK_TARGET_OS" = xmacosx; then 29281 29282 if test "x$BOOT_JDK_FOUND" = xno; then 29283 # Now execute the test 29284 29285 BOOT_JDK_PREFIX="/Library/Java/JavaVirtualMachines" 29286 BOOT_JDK_SUFFIX="/Contents/Home" 29287 ALL_JDKS_FOUND=`$LS "$BOOT_JDK_PREFIX" 2> /dev/null | $SORT -r` 29288 if test "x$ALL_JDKS_FOUND" != x; then 29289 for JDK_TO_TRY in $ALL_JDKS_FOUND ; do 29290 29291 if test "x$BOOT_JDK_FOUND" = xno; then 29292 # Now execute the test 29293 29294 BOOT_JDK="${BOOT_JDK_PREFIX}/${JDK_TO_TRY}${BOOT_JDK_SUFFIX}" 29295 if test -d "$BOOT_JDK"; then 29296 BOOT_JDK_FOUND=maybe 29297 { $as_echo "$as_me:${as_lineno-$LINENO}: Found potential Boot JDK using well-known locations (in $BOOT_JDK_PREFIX/$JDK_TO_TRY)" >&5 29298 $as_echo "$as_me: Found potential Boot JDK using well-known locations (in $BOOT_JDK_PREFIX/$JDK_TO_TRY)" >&6;} 29299 fi 29300 29301 29302 # If previous step claimed to have found a JDK, check it to see if it seems to be valid. 29303 if test "x$BOOT_JDK_FOUND" = xmaybe; then 29304 # Do we have a bin/java? 29305 if test ! -x "$BOOT_JDK/bin/java"; then 29306 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&5 29307 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&6;} 29308 BOOT_JDK_FOUND=no 29309 else 29310 # Do we have a bin/javac? 29311 if test ! -x "$BOOT_JDK/bin/javac"; then 29312 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&5 29313 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&6;} 29314 { $as_echo "$as_me:${as_lineno-$LINENO}: (This might be an JRE instead of an JDK)" >&5 29315 $as_echo "$as_me: (This might be an JRE instead of an JDK)" >&6;} 29316 BOOT_JDK_FOUND=no 29317 else 29318 # Oh, this is looking good! We probably have found a proper JDK. Is it the correct version? 29319 BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | $HEAD -n 1` 29320 29321 # Extra M4 quote needed to protect [] in grep expression. 29322 FOUND_CORRECT_VERSION=`$ECHO $BOOT_JDK_VERSION | $EGREP '\"10([\.+-].*)?\"|\"9([\.+-].*)?\"'` 29323 if test "x$FOUND_CORRECT_VERSION" = x; then 29324 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&5 29325 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&6;} 29326 { $as_echo "$as_me:${as_lineno-$LINENO}: (Your Boot JDK must be version 9 or 10)" >&5 29327 $as_echo "$as_me: (Your Boot JDK must be version 9 or 10)" >&6;} 29328 BOOT_JDK_FOUND=no 29329 else 29330 # We're done! :-) 29331 BOOT_JDK_FOUND=yes 29332 29333 # Only process if variable expands to non-empty 29334 29335 if test "x$BOOT_JDK" != x; then 29336 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 29337 29338 # Input might be given as Windows format, start by converting to 29339 # unix format. 29340 path="$BOOT_JDK" 29341 new_path=`$CYGPATH -u "$path"` 29342 29343 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 29344 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 29345 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 29346 # "foo.exe" is OK but "foo" is an error. 29347 # 29348 # This test is therefore slightly more accurate than "test -f" to check for file precense. 29349 # It is also a way to make sure we got the proper file name for the real test later on. 29350 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 29351 if test "x$test_shortpath" = x; then 29352 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5 29353 $as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;} 29354 as_fn_error $? "Cannot locate the the path of BOOT_JDK" "$LINENO" 5 29355 fi 29356 29357 # Call helper function which possibly converts this using DOS-style short mode. 29358 # If so, the updated path is stored in $new_path. 29359 29360 input_path="$new_path" 29361 # Check if we need to convert this using DOS-style short mode. If the path 29362 # contains just simple characters, use it. Otherwise (spaces, weird characters), 29363 # take no chances and rewrite it. 29364 # Note: m4 eats our [], so we need to use [ and ] instead. 29365 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 29366 if test "x$has_forbidden_chars" != x; then 29367 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 29368 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 29369 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 29370 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 29371 # Going to short mode and back again did indeed matter. Since short mode is 29372 # case insensitive, let's make it lowercase to improve readability. 29373 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 29374 # Now convert it back to Unix-style (cygpath) 29375 input_path=`$CYGPATH -u "$shortmode_path"` 29376 new_path="$input_path" 29377 fi 29378 fi 29379 29380 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 29381 if test "x$test_cygdrive_prefix" = x; then 29382 # As a simple fix, exclude /usr/bin since it's not a real path. 29383 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 29384 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 29385 # a path prefixed by /cygdrive for fixpath to work. 29386 new_path="$CYGWIN_ROOT_PATH$input_path" 29387 fi 29388 fi 29389 29390 29391 if test "x$path" != "x$new_path"; then 29392 BOOT_JDK="$new_path" 29393 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5 29394 $as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;} 29395 fi 29396 29397 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 29398 29399 path="$BOOT_JDK" 29400 has_colon=`$ECHO $path | $GREP ^.:` 29401 new_path="$path" 29402 if test "x$has_colon" = x; then 29403 # Not in mixed or Windows style, start by that. 29404 new_path=`cmd //c echo $path` 29405 fi 29406 29407 29408 input_path="$new_path" 29409 # Check if we need to convert this using DOS-style short mode. If the path 29410 # contains just simple characters, use it. Otherwise (spaces, weird characters), 29411 # take no chances and rewrite it. 29412 # Note: m4 eats our [], so we need to use [ and ] instead. 29413 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 29414 if test "x$has_forbidden_chars" != x; then 29415 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 29416 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 29417 fi 29418 29419 29420 windows_path="$new_path" 29421 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 29422 unix_path=`$CYGPATH -u "$windows_path"` 29423 new_path="$unix_path" 29424 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 29425 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 29426 new_path="$unix_path" 29427 fi 29428 29429 if test "x$path" != "x$new_path"; then 29430 BOOT_JDK="$new_path" 29431 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5 29432 $as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;} 29433 fi 29434 29435 # Save the first 10 bytes of this path to the storage, so fixpath can work. 29436 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 29437 29438 else 29439 # We're on a unix platform. Hooray! :) 29440 path="$BOOT_JDK" 29441 has_space=`$ECHO "$path" | $GREP " "` 29442 if test "x$has_space" != x; then 29443 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5 29444 $as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;} 29445 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 29446 fi 29447 29448 # Use eval to expand a potential ~ 29449 eval path="$path" 29450 if test ! -f "$path" && test ! -d "$path"; then 29451 as_fn_error $? "The path of BOOT_JDK, which resolves as \"$path\", is not found." "$LINENO" 5 29452 fi 29453 29454 if test -d "$path"; then 29455 BOOT_JDK="`cd "$path"; $THEPWDCMD -L`" 29456 else 29457 dir="`$DIRNAME "$path"`" 29458 base="`$BASENAME "$path"`" 29459 BOOT_JDK="`cd "$dir"; $THEPWDCMD -L`/$base" 29460 fi 29461 fi 29462 fi 29463 29464 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for Boot JDK" >&5 29465 $as_echo_n "checking for Boot JDK... " >&6; } 29466 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK" >&5 29467 $as_echo "$BOOT_JDK" >&6; } 29468 { $as_echo "$as_me:${as_lineno-$LINENO}: checking Boot JDK version" >&5 29469 $as_echo_n "checking Boot JDK version... " >&6; } 29470 BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | $TR '\n\r' ' '` 29471 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK_VERSION" >&5 29472 $as_echo "$BOOT_JDK_VERSION" >&6; } 29473 fi # end check jdk version 29474 fi # end check javac 29475 fi # end check java 29476 fi # end check boot jdk found 29477 fi 29478 29479 done 29480 fi 29481 29482 29483 # If previous step claimed to have found a JDK, check it to see if it seems to be valid. 29484 if test "x$BOOT_JDK_FOUND" = xmaybe; then 29485 # Do we have a bin/java? 29486 if test ! -x "$BOOT_JDK/bin/java"; then 29487 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&5 29488 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&6;} 29489 BOOT_JDK_FOUND=no 29490 else 29491 # Do we have a bin/javac? 29492 if test ! -x "$BOOT_JDK/bin/javac"; then 29493 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&5 29494 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&6;} 29495 { $as_echo "$as_me:${as_lineno-$LINENO}: (This might be an JRE instead of an JDK)" >&5 29496 $as_echo "$as_me: (This might be an JRE instead of an JDK)" >&6;} 29497 BOOT_JDK_FOUND=no 29498 else 29499 # Oh, this is looking good! We probably have found a proper JDK. Is it the correct version? 29500 BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | $HEAD -n 1` 29501 29502 # Extra M4 quote needed to protect [] in grep expression. 29503 FOUND_CORRECT_VERSION=`$ECHO $BOOT_JDK_VERSION | $EGREP '\"10([\.+-].*)?\"|\"9([\.+-].*)?\"'` 29504 if test "x$FOUND_CORRECT_VERSION" = x; then 29505 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&5 29506 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&6;} 29507 { $as_echo "$as_me:${as_lineno-$LINENO}: (Your Boot JDK must be version 9 or 10)" >&5 29508 $as_echo "$as_me: (Your Boot JDK must be version 9 or 10)" >&6;} 29509 BOOT_JDK_FOUND=no 29510 else 29511 # We're done! :-) 29512 BOOT_JDK_FOUND=yes 29513 29514 # Only process if variable expands to non-empty 29515 29516 if test "x$BOOT_JDK" != x; then 29517 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 29518 29519 # Input might be given as Windows format, start by converting to 29520 # unix format. 29521 path="$BOOT_JDK" 29522 new_path=`$CYGPATH -u "$path"` 29523 29524 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 29525 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 29526 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 29527 # "foo.exe" is OK but "foo" is an error. 29528 # 29529 # This test is therefore slightly more accurate than "test -f" to check for file precense. 29530 # It is also a way to make sure we got the proper file name for the real test later on. 29531 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 29532 if test "x$test_shortpath" = x; then 29533 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5 29534 $as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;} 29535 as_fn_error $? "Cannot locate the the path of BOOT_JDK" "$LINENO" 5 29536 fi 29537 29538 # Call helper function which possibly converts this using DOS-style short mode. 29539 # If so, the updated path is stored in $new_path. 29540 29541 input_path="$new_path" 29542 # Check if we need to convert this using DOS-style short mode. If the path 29543 # contains just simple characters, use it. Otherwise (spaces, weird characters), 29544 # take no chances and rewrite it. 29545 # Note: m4 eats our [], so we need to use [ and ] instead. 29546 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 29547 if test "x$has_forbidden_chars" != x; then 29548 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 29549 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 29550 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 29551 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 29552 # Going to short mode and back again did indeed matter. Since short mode is 29553 # case insensitive, let's make it lowercase to improve readability. 29554 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 29555 # Now convert it back to Unix-style (cygpath) 29556 input_path=`$CYGPATH -u "$shortmode_path"` 29557 new_path="$input_path" 29558 fi 29559 fi 29560 29561 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 29562 if test "x$test_cygdrive_prefix" = x; then 29563 # As a simple fix, exclude /usr/bin since it's not a real path. 29564 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 29565 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 29566 # a path prefixed by /cygdrive for fixpath to work. 29567 new_path="$CYGWIN_ROOT_PATH$input_path" 29568 fi 29569 fi 29570 29571 29572 if test "x$path" != "x$new_path"; then 29573 BOOT_JDK="$new_path" 29574 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5 29575 $as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;} 29576 fi 29577 29578 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 29579 29580 path="$BOOT_JDK" 29581 has_colon=`$ECHO $path | $GREP ^.:` 29582 new_path="$path" 29583 if test "x$has_colon" = x; then 29584 # Not in mixed or Windows style, start by that. 29585 new_path=`cmd //c echo $path` 29586 fi 29587 29588 29589 input_path="$new_path" 29590 # Check if we need to convert this using DOS-style short mode. If the path 29591 # contains just simple characters, use it. Otherwise (spaces, weird characters), 29592 # take no chances and rewrite it. 29593 # Note: m4 eats our [], so we need to use [ and ] instead. 29594 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 29595 if test "x$has_forbidden_chars" != x; then 29596 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 29597 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 29598 fi 29599 29600 29601 windows_path="$new_path" 29602 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 29603 unix_path=`$CYGPATH -u "$windows_path"` 29604 new_path="$unix_path" 29605 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 29606 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 29607 new_path="$unix_path" 29608 fi 29609 29610 if test "x$path" != "x$new_path"; then 29611 BOOT_JDK="$new_path" 29612 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5 29613 $as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;} 29614 fi 29615 29616 # Save the first 10 bytes of this path to the storage, so fixpath can work. 29617 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 29618 29619 else 29620 # We're on a unix platform. Hooray! :) 29621 path="$BOOT_JDK" 29622 has_space=`$ECHO "$path" | $GREP " "` 29623 if test "x$has_space" != x; then 29624 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5 29625 $as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;} 29626 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 29627 fi 29628 29629 # Use eval to expand a potential ~ 29630 eval path="$path" 29631 if test ! -f "$path" && test ! -d "$path"; then 29632 as_fn_error $? "The path of BOOT_JDK, which resolves as \"$path\", is not found." "$LINENO" 5 29633 fi 29634 29635 if test -d "$path"; then 29636 BOOT_JDK="`cd "$path"; $THEPWDCMD -L`" 29637 else 29638 dir="`$DIRNAME "$path"`" 29639 base="`$BASENAME "$path"`" 29640 BOOT_JDK="`cd "$dir"; $THEPWDCMD -L`/$base" 29641 fi 29642 fi 29643 fi 29644 29645 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for Boot JDK" >&5 29646 $as_echo_n "checking for Boot JDK... " >&6; } 29647 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK" >&5 29648 $as_echo "$BOOT_JDK" >&6; } 29649 { $as_echo "$as_me:${as_lineno-$LINENO}: checking Boot JDK version" >&5 29650 $as_echo_n "checking Boot JDK version... " >&6; } 29651 BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | $TR '\n\r' ' '` 29652 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK_VERSION" >&5 29653 $as_echo "$BOOT_JDK_VERSION" >&6; } 29654 fi # end check jdk version 29655 fi # end check javac 29656 fi # end check java 29657 fi # end check boot jdk found 29658 fi 29659 29660 29661 if test "x$BOOT_JDK_FOUND" = xno; then 29662 # Now execute the test 29663 29664 BOOT_JDK_PREFIX="/System/Library/Java/JavaVirtualMachines" 29665 BOOT_JDK_SUFFIX="/Contents/Home" 29666 ALL_JDKS_FOUND=`$LS "$BOOT_JDK_PREFIX" 2> /dev/null | $SORT -r` 29667 if test "x$ALL_JDKS_FOUND" != x; then 29668 for JDK_TO_TRY in $ALL_JDKS_FOUND ; do 29669 29670 if test "x$BOOT_JDK_FOUND" = xno; then 29671 # Now execute the test 29672 29673 BOOT_JDK="${BOOT_JDK_PREFIX}/${JDK_TO_TRY}${BOOT_JDK_SUFFIX}" 29674 if test -d "$BOOT_JDK"; then 29675 BOOT_JDK_FOUND=maybe 29676 { $as_echo "$as_me:${as_lineno-$LINENO}: Found potential Boot JDK using well-known locations (in $BOOT_JDK_PREFIX/$JDK_TO_TRY)" >&5 29677 $as_echo "$as_me: Found potential Boot JDK using well-known locations (in $BOOT_JDK_PREFIX/$JDK_TO_TRY)" >&6;} 29678 fi 29679 29680 29681 # If previous step claimed to have found a JDK, check it to see if it seems to be valid. 29682 if test "x$BOOT_JDK_FOUND" = xmaybe; then 29683 # Do we have a bin/java? 29684 if test ! -x "$BOOT_JDK/bin/java"; then 29685 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&5 29686 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&6;} 29687 BOOT_JDK_FOUND=no 29688 else 29689 # Do we have a bin/javac? 29690 if test ! -x "$BOOT_JDK/bin/javac"; then 29691 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&5 29692 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&6;} 29693 { $as_echo "$as_me:${as_lineno-$LINENO}: (This might be an JRE instead of an JDK)" >&5 29694 $as_echo "$as_me: (This might be an JRE instead of an JDK)" >&6;} 29695 BOOT_JDK_FOUND=no 29696 else 29697 # Oh, this is looking good! We probably have found a proper JDK. Is it the correct version? 29698 BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | $HEAD -n 1` 29699 29700 # Extra M4 quote needed to protect [] in grep expression. 29701 FOUND_CORRECT_VERSION=`$ECHO $BOOT_JDK_VERSION | $EGREP '\"10([\.+-].*)?\"|\"9([\.+-].*)?\"'` 29702 if test "x$FOUND_CORRECT_VERSION" = x; then 29703 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&5 29704 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&6;} 29705 { $as_echo "$as_me:${as_lineno-$LINENO}: (Your Boot JDK must be version 9 or 10)" >&5 29706 $as_echo "$as_me: (Your Boot JDK must be version 9 or 10)" >&6;} 29707 BOOT_JDK_FOUND=no 29708 else 29709 # We're done! :-) 29710 BOOT_JDK_FOUND=yes 29711 29712 # Only process if variable expands to non-empty 29713 29714 if test "x$BOOT_JDK" != x; then 29715 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 29716 29717 # Input might be given as Windows format, start by converting to 29718 # unix format. 29719 path="$BOOT_JDK" 29720 new_path=`$CYGPATH -u "$path"` 29721 29722 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 29723 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 29724 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 29725 # "foo.exe" is OK but "foo" is an error. 29726 # 29727 # This test is therefore slightly more accurate than "test -f" to check for file precense. 29728 # It is also a way to make sure we got the proper file name for the real test later on. 29729 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 29730 if test "x$test_shortpath" = x; then 29731 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5 29732 $as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;} 29733 as_fn_error $? "Cannot locate the the path of BOOT_JDK" "$LINENO" 5 29734 fi 29735 29736 # Call helper function which possibly converts this using DOS-style short mode. 29737 # If so, the updated path is stored in $new_path. 29738 29739 input_path="$new_path" 29740 # Check if we need to convert this using DOS-style short mode. If the path 29741 # contains just simple characters, use it. Otherwise (spaces, weird characters), 29742 # take no chances and rewrite it. 29743 # Note: m4 eats our [], so we need to use [ and ] instead. 29744 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 29745 if test "x$has_forbidden_chars" != x; then 29746 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 29747 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 29748 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 29749 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 29750 # Going to short mode and back again did indeed matter. Since short mode is 29751 # case insensitive, let's make it lowercase to improve readability. 29752 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 29753 # Now convert it back to Unix-style (cygpath) 29754 input_path=`$CYGPATH -u "$shortmode_path"` 29755 new_path="$input_path" 29756 fi 29757 fi 29758 29759 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 29760 if test "x$test_cygdrive_prefix" = x; then 29761 # As a simple fix, exclude /usr/bin since it's not a real path. 29762 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 29763 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 29764 # a path prefixed by /cygdrive for fixpath to work. 29765 new_path="$CYGWIN_ROOT_PATH$input_path" 29766 fi 29767 fi 29768 29769 29770 if test "x$path" != "x$new_path"; then 29771 BOOT_JDK="$new_path" 29772 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5 29773 $as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;} 29774 fi 29775 29776 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 29777 29778 path="$BOOT_JDK" 29779 has_colon=`$ECHO $path | $GREP ^.:` 29780 new_path="$path" 29781 if test "x$has_colon" = x; then 29782 # Not in mixed or Windows style, start by that. 29783 new_path=`cmd //c echo $path` 29784 fi 29785 29786 29787 input_path="$new_path" 29788 # Check if we need to convert this using DOS-style short mode. If the path 29789 # contains just simple characters, use it. Otherwise (spaces, weird characters), 29790 # take no chances and rewrite it. 29791 # Note: m4 eats our [], so we need to use [ and ] instead. 29792 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 29793 if test "x$has_forbidden_chars" != x; then 29794 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 29795 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 29796 fi 29797 29798 29799 windows_path="$new_path" 29800 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 29801 unix_path=`$CYGPATH -u "$windows_path"` 29802 new_path="$unix_path" 29803 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 29804 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 29805 new_path="$unix_path" 29806 fi 29807 29808 if test "x$path" != "x$new_path"; then 29809 BOOT_JDK="$new_path" 29810 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5 29811 $as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;} 29812 fi 29813 29814 # Save the first 10 bytes of this path to the storage, so fixpath can work. 29815 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 29816 29817 else 29818 # We're on a unix platform. Hooray! :) 29819 path="$BOOT_JDK" 29820 has_space=`$ECHO "$path" | $GREP " "` 29821 if test "x$has_space" != x; then 29822 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5 29823 $as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;} 29824 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 29825 fi 29826 29827 # Use eval to expand a potential ~ 29828 eval path="$path" 29829 if test ! -f "$path" && test ! -d "$path"; then 29830 as_fn_error $? "The path of BOOT_JDK, which resolves as \"$path\", is not found." "$LINENO" 5 29831 fi 29832 29833 if test -d "$path"; then 29834 BOOT_JDK="`cd "$path"; $THEPWDCMD -L`" 29835 else 29836 dir="`$DIRNAME "$path"`" 29837 base="`$BASENAME "$path"`" 29838 BOOT_JDK="`cd "$dir"; $THEPWDCMD -L`/$base" 29839 fi 29840 fi 29841 fi 29842 29843 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for Boot JDK" >&5 29844 $as_echo_n "checking for Boot JDK... " >&6; } 29845 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK" >&5 29846 $as_echo "$BOOT_JDK" >&6; } 29847 { $as_echo "$as_me:${as_lineno-$LINENO}: checking Boot JDK version" >&5 29848 $as_echo_n "checking Boot JDK version... " >&6; } 29849 BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | $TR '\n\r' ' '` 29850 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK_VERSION" >&5 29851 $as_echo "$BOOT_JDK_VERSION" >&6; } 29852 fi # end check jdk version 29853 fi # end check javac 29854 fi # end check java 29855 fi # end check boot jdk found 29856 fi 29857 29858 done 29859 fi 29860 29861 29862 # If previous step claimed to have found a JDK, check it to see if it seems to be valid. 29863 if test "x$BOOT_JDK_FOUND" = xmaybe; then 29864 # Do we have a bin/java? 29865 if test ! -x "$BOOT_JDK/bin/java"; then 29866 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&5 29867 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&6;} 29868 BOOT_JDK_FOUND=no 29869 else 29870 # Do we have a bin/javac? 29871 if test ! -x "$BOOT_JDK/bin/javac"; then 29872 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&5 29873 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&6;} 29874 { $as_echo "$as_me:${as_lineno-$LINENO}: (This might be an JRE instead of an JDK)" >&5 29875 $as_echo "$as_me: (This might be an JRE instead of an JDK)" >&6;} 29876 BOOT_JDK_FOUND=no 29877 else 29878 # Oh, this is looking good! We probably have found a proper JDK. Is it the correct version? 29879 BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | $HEAD -n 1` 29880 29881 # Extra M4 quote needed to protect [] in grep expression. 29882 FOUND_CORRECT_VERSION=`$ECHO $BOOT_JDK_VERSION | $EGREP '\"10([\.+-].*)?\"|\"9([\.+-].*)?\"'` 29883 if test "x$FOUND_CORRECT_VERSION" = x; then 29884 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&5 29885 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&6;} 29886 { $as_echo "$as_me:${as_lineno-$LINENO}: (Your Boot JDK must be version 9 or 10)" >&5 29887 $as_echo "$as_me: (Your Boot JDK must be version 9 or 10)" >&6;} 29888 BOOT_JDK_FOUND=no 29889 else 29890 # We're done! :-) 29891 BOOT_JDK_FOUND=yes 29892 29893 # Only process if variable expands to non-empty 29894 29895 if test "x$BOOT_JDK" != x; then 29896 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 29897 29898 # Input might be given as Windows format, start by converting to 29899 # unix format. 29900 path="$BOOT_JDK" 29901 new_path=`$CYGPATH -u "$path"` 29902 29903 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 29904 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 29905 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 29906 # "foo.exe" is OK but "foo" is an error. 29907 # 29908 # This test is therefore slightly more accurate than "test -f" to check for file precense. 29909 # It is also a way to make sure we got the proper file name for the real test later on. 29910 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 29911 if test "x$test_shortpath" = x; then 29912 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5 29913 $as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;} 29914 as_fn_error $? "Cannot locate the the path of BOOT_JDK" "$LINENO" 5 29915 fi 29916 29917 # Call helper function which possibly converts this using DOS-style short mode. 29918 # If so, the updated path is stored in $new_path. 29919 29920 input_path="$new_path" 29921 # Check if we need to convert this using DOS-style short mode. If the path 29922 # contains just simple characters, use it. Otherwise (spaces, weird characters), 29923 # take no chances and rewrite it. 29924 # Note: m4 eats our [], so we need to use [ and ] instead. 29925 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 29926 if test "x$has_forbidden_chars" != x; then 29927 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 29928 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 29929 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 29930 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 29931 # Going to short mode and back again did indeed matter. Since short mode is 29932 # case insensitive, let's make it lowercase to improve readability. 29933 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 29934 # Now convert it back to Unix-style (cygpath) 29935 input_path=`$CYGPATH -u "$shortmode_path"` 29936 new_path="$input_path" 29937 fi 29938 fi 29939 29940 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 29941 if test "x$test_cygdrive_prefix" = x; then 29942 # As a simple fix, exclude /usr/bin since it's not a real path. 29943 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 29944 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 29945 # a path prefixed by /cygdrive for fixpath to work. 29946 new_path="$CYGWIN_ROOT_PATH$input_path" 29947 fi 29948 fi 29949 29950 29951 if test "x$path" != "x$new_path"; then 29952 BOOT_JDK="$new_path" 29953 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5 29954 $as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;} 29955 fi 29956 29957 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 29958 29959 path="$BOOT_JDK" 29960 has_colon=`$ECHO $path | $GREP ^.:` 29961 new_path="$path" 29962 if test "x$has_colon" = x; then 29963 # Not in mixed or Windows style, start by that. 29964 new_path=`cmd //c echo $path` 29965 fi 29966 29967 29968 input_path="$new_path" 29969 # Check if we need to convert this using DOS-style short mode. If the path 29970 # contains just simple characters, use it. Otherwise (spaces, weird characters), 29971 # take no chances and rewrite it. 29972 # Note: m4 eats our [], so we need to use [ and ] instead. 29973 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 29974 if test "x$has_forbidden_chars" != x; then 29975 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 29976 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 29977 fi 29978 29979 29980 windows_path="$new_path" 29981 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 29982 unix_path=`$CYGPATH -u "$windows_path"` 29983 new_path="$unix_path" 29984 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 29985 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 29986 new_path="$unix_path" 29987 fi 29988 29989 if test "x$path" != "x$new_path"; then 29990 BOOT_JDK="$new_path" 29991 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5 29992 $as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;} 29993 fi 29994 29995 # Save the first 10 bytes of this path to the storage, so fixpath can work. 29996 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 29997 29998 else 29999 # We're on a unix platform. Hooray! :) 30000 path="$BOOT_JDK" 30001 has_space=`$ECHO "$path" | $GREP " "` 30002 if test "x$has_space" != x; then 30003 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5 30004 $as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;} 30005 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 30006 fi 30007 30008 # Use eval to expand a potential ~ 30009 eval path="$path" 30010 if test ! -f "$path" && test ! -d "$path"; then 30011 as_fn_error $? "The path of BOOT_JDK, which resolves as \"$path\", is not found." "$LINENO" 5 30012 fi 30013 30014 if test -d "$path"; then 30015 BOOT_JDK="`cd "$path"; $THEPWDCMD -L`" 30016 else 30017 dir="`$DIRNAME "$path"`" 30018 base="`$BASENAME "$path"`" 30019 BOOT_JDK="`cd "$dir"; $THEPWDCMD -L`/$base" 30020 fi 30021 fi 30022 fi 30023 30024 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for Boot JDK" >&5 30025 $as_echo_n "checking for Boot JDK... " >&6; } 30026 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK" >&5 30027 $as_echo "$BOOT_JDK" >&6; } 30028 { $as_echo "$as_me:${as_lineno-$LINENO}: checking Boot JDK version" >&5 30029 $as_echo_n "checking Boot JDK version... " >&6; } 30030 BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | $TR '\n\r' ' '` 30031 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK_VERSION" >&5 30032 $as_echo "$BOOT_JDK_VERSION" >&6; } 30033 fi # end check jdk version 30034 fi # end check javac 30035 fi # end check java 30036 fi # end check boot jdk found 30037 fi 30038 30039 elif test "x$OPENJDK_TARGET_OS" = xlinux; then 30040 30041 if test "x$BOOT_JDK_FOUND" = xno; then 30042 # Now execute the test 30043 30044 BOOT_JDK_PREFIX="/usr/lib/jvm" 30045 BOOT_JDK_SUFFIX="" 30046 ALL_JDKS_FOUND=`$LS "$BOOT_JDK_PREFIX" 2> /dev/null | $SORT -r` 30047 if test "x$ALL_JDKS_FOUND" != x; then 30048 for JDK_TO_TRY in $ALL_JDKS_FOUND ; do 30049 30050 if test "x$BOOT_JDK_FOUND" = xno; then 30051 # Now execute the test 30052 30053 BOOT_JDK="${BOOT_JDK_PREFIX}/${JDK_TO_TRY}${BOOT_JDK_SUFFIX}" 30054 if test -d "$BOOT_JDK"; then 30055 BOOT_JDK_FOUND=maybe 30056 { $as_echo "$as_me:${as_lineno-$LINENO}: Found potential Boot JDK using well-known locations (in $BOOT_JDK_PREFIX/$JDK_TO_TRY)" >&5 30057 $as_echo "$as_me: Found potential Boot JDK using well-known locations (in $BOOT_JDK_PREFIX/$JDK_TO_TRY)" >&6;} 30058 fi 30059 30060 30061 # If previous step claimed to have found a JDK, check it to see if it seems to be valid. 30062 if test "x$BOOT_JDK_FOUND" = xmaybe; then 30063 # Do we have a bin/java? 30064 if test ! -x "$BOOT_JDK/bin/java"; then 30065 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&5 30066 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&6;} 30067 BOOT_JDK_FOUND=no 30068 else 30069 # Do we have a bin/javac? 30070 if test ! -x "$BOOT_JDK/bin/javac"; then 30071 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&5 30072 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&6;} 30073 { $as_echo "$as_me:${as_lineno-$LINENO}: (This might be an JRE instead of an JDK)" >&5 30074 $as_echo "$as_me: (This might be an JRE instead of an JDK)" >&6;} 30075 BOOT_JDK_FOUND=no 30076 else 30077 # Oh, this is looking good! We probably have found a proper JDK. Is it the correct version? 30078 BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | $HEAD -n 1` 30079 30080 # Extra M4 quote needed to protect [] in grep expression. 30081 FOUND_CORRECT_VERSION=`$ECHO $BOOT_JDK_VERSION | $EGREP '\"10([\.+-].*)?\"|\"9([\.+-].*)?\"'` 30082 if test "x$FOUND_CORRECT_VERSION" = x; then 30083 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&5 30084 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&6;} 30085 { $as_echo "$as_me:${as_lineno-$LINENO}: (Your Boot JDK must be version 9 or 10)" >&5 30086 $as_echo "$as_me: (Your Boot JDK must be version 9 or 10)" >&6;} 30087 BOOT_JDK_FOUND=no 30088 else 30089 # We're done! :-) 30090 BOOT_JDK_FOUND=yes 30091 30092 # Only process if variable expands to non-empty 30093 30094 if test "x$BOOT_JDK" != x; then 30095 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 30096 30097 # Input might be given as Windows format, start by converting to 30098 # unix format. 30099 path="$BOOT_JDK" 30100 new_path=`$CYGPATH -u "$path"` 30101 30102 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 30103 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 30104 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 30105 # "foo.exe" is OK but "foo" is an error. 30106 # 30107 # This test is therefore slightly more accurate than "test -f" to check for file precense. 30108 # It is also a way to make sure we got the proper file name for the real test later on. 30109 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 30110 if test "x$test_shortpath" = x; then 30111 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5 30112 $as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;} 30113 as_fn_error $? "Cannot locate the the path of BOOT_JDK" "$LINENO" 5 30114 fi 30115 30116 # Call helper function which possibly converts this using DOS-style short mode. 30117 # If so, the updated path is stored in $new_path. 30118 30119 input_path="$new_path" 30120 # Check if we need to convert this using DOS-style short mode. If the path 30121 # contains just simple characters, use it. Otherwise (spaces, weird characters), 30122 # take no chances and rewrite it. 30123 # Note: m4 eats our [], so we need to use [ and ] instead. 30124 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 30125 if test "x$has_forbidden_chars" != x; then 30126 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 30127 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 30128 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 30129 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 30130 # Going to short mode and back again did indeed matter. Since short mode is 30131 # case insensitive, let's make it lowercase to improve readability. 30132 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 30133 # Now convert it back to Unix-style (cygpath) 30134 input_path=`$CYGPATH -u "$shortmode_path"` 30135 new_path="$input_path" 30136 fi 30137 fi 30138 30139 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 30140 if test "x$test_cygdrive_prefix" = x; then 30141 # As a simple fix, exclude /usr/bin since it's not a real path. 30142 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 30143 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 30144 # a path prefixed by /cygdrive for fixpath to work. 30145 new_path="$CYGWIN_ROOT_PATH$input_path" 30146 fi 30147 fi 30148 30149 30150 if test "x$path" != "x$new_path"; then 30151 BOOT_JDK="$new_path" 30152 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5 30153 $as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;} 30154 fi 30155 30156 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 30157 30158 path="$BOOT_JDK" 30159 has_colon=`$ECHO $path | $GREP ^.:` 30160 new_path="$path" 30161 if test "x$has_colon" = x; then 30162 # Not in mixed or Windows style, start by that. 30163 new_path=`cmd //c echo $path` 30164 fi 30165 30166 30167 input_path="$new_path" 30168 # Check if we need to convert this using DOS-style short mode. If the path 30169 # contains just simple characters, use it. Otherwise (spaces, weird characters), 30170 # take no chances and rewrite it. 30171 # Note: m4 eats our [], so we need to use [ and ] instead. 30172 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 30173 if test "x$has_forbidden_chars" != x; then 30174 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 30175 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 30176 fi 30177 30178 30179 windows_path="$new_path" 30180 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 30181 unix_path=`$CYGPATH -u "$windows_path"` 30182 new_path="$unix_path" 30183 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 30184 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 30185 new_path="$unix_path" 30186 fi 30187 30188 if test "x$path" != "x$new_path"; then 30189 BOOT_JDK="$new_path" 30190 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5 30191 $as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;} 30192 fi 30193 30194 # Save the first 10 bytes of this path to the storage, so fixpath can work. 30195 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 30196 30197 else 30198 # We're on a unix platform. Hooray! :) 30199 path="$BOOT_JDK" 30200 has_space=`$ECHO "$path" | $GREP " "` 30201 if test "x$has_space" != x; then 30202 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5 30203 $as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;} 30204 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 30205 fi 30206 30207 # Use eval to expand a potential ~ 30208 eval path="$path" 30209 if test ! -f "$path" && test ! -d "$path"; then 30210 as_fn_error $? "The path of BOOT_JDK, which resolves as \"$path\", is not found." "$LINENO" 5 30211 fi 30212 30213 if test -d "$path"; then 30214 BOOT_JDK="`cd "$path"; $THEPWDCMD -L`" 30215 else 30216 dir="`$DIRNAME "$path"`" 30217 base="`$BASENAME "$path"`" 30218 BOOT_JDK="`cd "$dir"; $THEPWDCMD -L`/$base" 30219 fi 30220 fi 30221 fi 30222 30223 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for Boot JDK" >&5 30224 $as_echo_n "checking for Boot JDK... " >&6; } 30225 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK" >&5 30226 $as_echo "$BOOT_JDK" >&6; } 30227 { $as_echo "$as_me:${as_lineno-$LINENO}: checking Boot JDK version" >&5 30228 $as_echo_n "checking Boot JDK version... " >&6; } 30229 BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | $TR '\n\r' ' '` 30230 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK_VERSION" >&5 30231 $as_echo "$BOOT_JDK_VERSION" >&6; } 30232 fi # end check jdk version 30233 fi # end check javac 30234 fi # end check java 30235 fi # end check boot jdk found 30236 fi 30237 30238 done 30239 fi 30240 30241 30242 # If previous step claimed to have found a JDK, check it to see if it seems to be valid. 30243 if test "x$BOOT_JDK_FOUND" = xmaybe; then 30244 # Do we have a bin/java? 30245 if test ! -x "$BOOT_JDK/bin/java"; then 30246 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&5 30247 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&6;} 30248 BOOT_JDK_FOUND=no 30249 else 30250 # Do we have a bin/javac? 30251 if test ! -x "$BOOT_JDK/bin/javac"; then 30252 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&5 30253 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&6;} 30254 { $as_echo "$as_me:${as_lineno-$LINENO}: (This might be an JRE instead of an JDK)" >&5 30255 $as_echo "$as_me: (This might be an JRE instead of an JDK)" >&6;} 30256 BOOT_JDK_FOUND=no 30257 else 30258 # Oh, this is looking good! We probably have found a proper JDK. Is it the correct version? 30259 BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | $HEAD -n 1` 30260 30261 # Extra M4 quote needed to protect [] in grep expression. 30262 FOUND_CORRECT_VERSION=`$ECHO $BOOT_JDK_VERSION | $EGREP '\"10([\.+-].*)?\"|\"9([\.+-].*)?\"'` 30263 if test "x$FOUND_CORRECT_VERSION" = x; then 30264 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&5 30265 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&6;} 30266 { $as_echo "$as_me:${as_lineno-$LINENO}: (Your Boot JDK must be version 9 or 10)" >&5 30267 $as_echo "$as_me: (Your Boot JDK must be version 9 or 10)" >&6;} 30268 BOOT_JDK_FOUND=no 30269 else 30270 # We're done! :-) 30271 BOOT_JDK_FOUND=yes 30272 30273 # Only process if variable expands to non-empty 30274 30275 if test "x$BOOT_JDK" != x; then 30276 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 30277 30278 # Input might be given as Windows format, start by converting to 30279 # unix format. 30280 path="$BOOT_JDK" 30281 new_path=`$CYGPATH -u "$path"` 30282 30283 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 30284 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 30285 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 30286 # "foo.exe" is OK but "foo" is an error. 30287 # 30288 # This test is therefore slightly more accurate than "test -f" to check for file precense. 30289 # It is also a way to make sure we got the proper file name for the real test later on. 30290 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 30291 if test "x$test_shortpath" = x; then 30292 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5 30293 $as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;} 30294 as_fn_error $? "Cannot locate the the path of BOOT_JDK" "$LINENO" 5 30295 fi 30296 30297 # Call helper function which possibly converts this using DOS-style short mode. 30298 # If so, the updated path is stored in $new_path. 30299 30300 input_path="$new_path" 30301 # Check if we need to convert this using DOS-style short mode. If the path 30302 # contains just simple characters, use it. Otherwise (spaces, weird characters), 30303 # take no chances and rewrite it. 30304 # Note: m4 eats our [], so we need to use [ and ] instead. 30305 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 30306 if test "x$has_forbidden_chars" != x; then 30307 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 30308 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 30309 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 30310 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 30311 # Going to short mode and back again did indeed matter. Since short mode is 30312 # case insensitive, let's make it lowercase to improve readability. 30313 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 30314 # Now convert it back to Unix-style (cygpath) 30315 input_path=`$CYGPATH -u "$shortmode_path"` 30316 new_path="$input_path" 30317 fi 30318 fi 30319 30320 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 30321 if test "x$test_cygdrive_prefix" = x; then 30322 # As a simple fix, exclude /usr/bin since it's not a real path. 30323 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 30324 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 30325 # a path prefixed by /cygdrive for fixpath to work. 30326 new_path="$CYGWIN_ROOT_PATH$input_path" 30327 fi 30328 fi 30329 30330 30331 if test "x$path" != "x$new_path"; then 30332 BOOT_JDK="$new_path" 30333 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5 30334 $as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;} 30335 fi 30336 30337 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 30338 30339 path="$BOOT_JDK" 30340 has_colon=`$ECHO $path | $GREP ^.:` 30341 new_path="$path" 30342 if test "x$has_colon" = x; then 30343 # Not in mixed or Windows style, start by that. 30344 new_path=`cmd //c echo $path` 30345 fi 30346 30347 30348 input_path="$new_path" 30349 # Check if we need to convert this using DOS-style short mode. If the path 30350 # contains just simple characters, use it. Otherwise (spaces, weird characters), 30351 # take no chances and rewrite it. 30352 # Note: m4 eats our [], so we need to use [ and ] instead. 30353 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 30354 if test "x$has_forbidden_chars" != x; then 30355 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 30356 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 30357 fi 30358 30359 30360 windows_path="$new_path" 30361 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 30362 unix_path=`$CYGPATH -u "$windows_path"` 30363 new_path="$unix_path" 30364 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 30365 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 30366 new_path="$unix_path" 30367 fi 30368 30369 if test "x$path" != "x$new_path"; then 30370 BOOT_JDK="$new_path" 30371 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5 30372 $as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;} 30373 fi 30374 30375 # Save the first 10 bytes of this path to the storage, so fixpath can work. 30376 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 30377 30378 else 30379 # We're on a unix platform. Hooray! :) 30380 path="$BOOT_JDK" 30381 has_space=`$ECHO "$path" | $GREP " "` 30382 if test "x$has_space" != x; then 30383 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5 30384 $as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;} 30385 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 30386 fi 30387 30388 # Use eval to expand a potential ~ 30389 eval path="$path" 30390 if test ! -f "$path" && test ! -d "$path"; then 30391 as_fn_error $? "The path of BOOT_JDK, which resolves as \"$path\", is not found." "$LINENO" 5 30392 fi 30393 30394 if test -d "$path"; then 30395 BOOT_JDK="`cd "$path"; $THEPWDCMD -L`" 30396 else 30397 dir="`$DIRNAME "$path"`" 30398 base="`$BASENAME "$path"`" 30399 BOOT_JDK="`cd "$dir"; $THEPWDCMD -L`/$base" 30400 fi 30401 fi 30402 fi 30403 30404 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for Boot JDK" >&5 30405 $as_echo_n "checking for Boot JDK... " >&6; } 30406 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK" >&5 30407 $as_echo "$BOOT_JDK" >&6; } 30408 { $as_echo "$as_me:${as_lineno-$LINENO}: checking Boot JDK version" >&5 30409 $as_echo_n "checking Boot JDK version... " >&6; } 30410 BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | $TR '\n\r' ' '` 30411 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK_VERSION" >&5 30412 $as_echo "$BOOT_JDK_VERSION" >&6; } 30413 fi # end check jdk version 30414 fi # end check javac 30415 fi # end check java 30416 fi # end check boot jdk found 30417 fi 30418 30419 fi 30420 30421 30422 # If previous step claimed to have found a JDK, check it to see if it seems to be valid. 30423 if test "x$BOOT_JDK_FOUND" = xmaybe; then 30424 # Do we have a bin/java? 30425 if test ! -x "$BOOT_JDK/bin/java"; then 30426 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&5 30427 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&6;} 30428 BOOT_JDK_FOUND=no 30429 else 30430 # Do we have a bin/javac? 30431 if test ! -x "$BOOT_JDK/bin/javac"; then 30432 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&5 30433 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&6;} 30434 { $as_echo "$as_me:${as_lineno-$LINENO}: (This might be an JRE instead of an JDK)" >&5 30435 $as_echo "$as_me: (This might be an JRE instead of an JDK)" >&6;} 30436 BOOT_JDK_FOUND=no 30437 else 30438 # Oh, this is looking good! We probably have found a proper JDK. Is it the correct version? 30439 BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | $HEAD -n 1` 30440 30441 # Extra M4 quote needed to protect [] in grep expression. 30442 FOUND_CORRECT_VERSION=`$ECHO $BOOT_JDK_VERSION | $EGREP '\"10([\.+-].*)?\"|\"9([\.+-].*)?\"'` 30443 if test "x$FOUND_CORRECT_VERSION" = x; then 30444 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&5 30445 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&6;} 30446 { $as_echo "$as_me:${as_lineno-$LINENO}: (Your Boot JDK must be version 9 or 10)" >&5 30447 $as_echo "$as_me: (Your Boot JDK must be version 9 or 10)" >&6;} 30448 BOOT_JDK_FOUND=no 30449 else 30450 # We're done! :-) 30451 BOOT_JDK_FOUND=yes 30452 30453 # Only process if variable expands to non-empty 30454 30455 if test "x$BOOT_JDK" != x; then 30456 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 30457 30458 # Input might be given as Windows format, start by converting to 30459 # unix format. 30460 path="$BOOT_JDK" 30461 new_path=`$CYGPATH -u "$path"` 30462 30463 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 30464 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 30465 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 30466 # "foo.exe" is OK but "foo" is an error. 30467 # 30468 # This test is therefore slightly more accurate than "test -f" to check for file precense. 30469 # It is also a way to make sure we got the proper file name for the real test later on. 30470 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 30471 if test "x$test_shortpath" = x; then 30472 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5 30473 $as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;} 30474 as_fn_error $? "Cannot locate the the path of BOOT_JDK" "$LINENO" 5 30475 fi 30476 30477 # Call helper function which possibly converts this using DOS-style short mode. 30478 # If so, the updated path is stored in $new_path. 30479 30480 input_path="$new_path" 30481 # Check if we need to convert this using DOS-style short mode. If the path 30482 # contains just simple characters, use it. Otherwise (spaces, weird characters), 30483 # take no chances and rewrite it. 30484 # Note: m4 eats our [], so we need to use [ and ] instead. 30485 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 30486 if test "x$has_forbidden_chars" != x; then 30487 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 30488 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 30489 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 30490 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 30491 # Going to short mode and back again did indeed matter. Since short mode is 30492 # case insensitive, let's make it lowercase to improve readability. 30493 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 30494 # Now convert it back to Unix-style (cygpath) 30495 input_path=`$CYGPATH -u "$shortmode_path"` 30496 new_path="$input_path" 30497 fi 30498 fi 30499 30500 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 30501 if test "x$test_cygdrive_prefix" = x; then 30502 # As a simple fix, exclude /usr/bin since it's not a real path. 30503 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 30504 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 30505 # a path prefixed by /cygdrive for fixpath to work. 30506 new_path="$CYGWIN_ROOT_PATH$input_path" 30507 fi 30508 fi 30509 30510 30511 if test "x$path" != "x$new_path"; then 30512 BOOT_JDK="$new_path" 30513 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5 30514 $as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;} 30515 fi 30516 30517 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 30518 30519 path="$BOOT_JDK" 30520 has_colon=`$ECHO $path | $GREP ^.:` 30521 new_path="$path" 30522 if test "x$has_colon" = x; then 30523 # Not in mixed or Windows style, start by that. 30524 new_path=`cmd //c echo $path` 30525 fi 30526 30527 30528 input_path="$new_path" 30529 # Check if we need to convert this using DOS-style short mode. If the path 30530 # contains just simple characters, use it. Otherwise (spaces, weird characters), 30531 # take no chances and rewrite it. 30532 # Note: m4 eats our [], so we need to use [ and ] instead. 30533 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 30534 if test "x$has_forbidden_chars" != x; then 30535 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 30536 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 30537 fi 30538 30539 30540 windows_path="$new_path" 30541 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 30542 unix_path=`$CYGPATH -u "$windows_path"` 30543 new_path="$unix_path" 30544 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 30545 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 30546 new_path="$unix_path" 30547 fi 30548 30549 if test "x$path" != "x$new_path"; then 30550 BOOT_JDK="$new_path" 30551 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5 30552 $as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;} 30553 fi 30554 30555 # Save the first 10 bytes of this path to the storage, so fixpath can work. 30556 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 30557 30558 else 30559 # We're on a unix platform. Hooray! :) 30560 path="$BOOT_JDK" 30561 has_space=`$ECHO "$path" | $GREP " "` 30562 if test "x$has_space" != x; then 30563 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5 30564 $as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;} 30565 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 30566 fi 30567 30568 # Use eval to expand a potential ~ 30569 eval path="$path" 30570 if test ! -f "$path" && test ! -d "$path"; then 30571 as_fn_error $? "The path of BOOT_JDK, which resolves as \"$path\", is not found." "$LINENO" 5 30572 fi 30573 30574 if test -d "$path"; then 30575 BOOT_JDK="`cd "$path"; $THEPWDCMD -L`" 30576 else 30577 dir="`$DIRNAME "$path"`" 30578 base="`$BASENAME "$path"`" 30579 BOOT_JDK="`cd "$dir"; $THEPWDCMD -L`/$base" 30580 fi 30581 fi 30582 fi 30583 30584 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for Boot JDK" >&5 30585 $as_echo_n "checking for Boot JDK... " >&6; } 30586 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK" >&5 30587 $as_echo "$BOOT_JDK" >&6; } 30588 { $as_echo "$as_me:${as_lineno-$LINENO}: checking Boot JDK version" >&5 30589 $as_echo_n "checking Boot JDK version... " >&6; } 30590 BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | $TR '\n\r' ' '` 30591 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK_VERSION" >&5 30592 $as_echo "$BOOT_JDK_VERSION" >&6; } 30593 fi # end check jdk version 30594 fi # end check javac 30595 fi # end check java 30596 fi # end check boot jdk found 30597 fi 30598 30599 30600 # If we haven't found anything yet, we've truly lost. Give up. 30601 if test "x$BOOT_JDK_FOUND" = xno; then 30602 30603 # Print a helpful message on how to acquire the necessary build dependency. 30604 # openjdk is the help tag: freetype, cups, alsa etc 30605 MISSING_DEPENDENCY=openjdk 30606 30607 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 30608 cygwin_help $MISSING_DEPENDENCY 30609 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 30610 msys_help $MISSING_DEPENDENCY 30611 else 30612 PKGHANDLER_COMMAND= 30613 30614 case $PKGHANDLER in 30615 apt-get) 30616 apt_help $MISSING_DEPENDENCY ;; 30617 yum) 30618 yum_help $MISSING_DEPENDENCY ;; 30619 brew) 30620 brew_help $MISSING_DEPENDENCY ;; 30621 port) 30622 port_help $MISSING_DEPENDENCY ;; 30623 pkgutil) 30624 pkgutil_help $MISSING_DEPENDENCY ;; 30625 pkgadd) 30626 pkgadd_help $MISSING_DEPENDENCY ;; 30627 esac 30628 30629 if test "x$PKGHANDLER_COMMAND" != x; then 30630 HELP_MSG="You might be able to fix this by running '$PKGHANDLER_COMMAND'." 30631 fi 30632 fi 30633 30634 { $as_echo "$as_me:${as_lineno-$LINENO}: Could not find a valid Boot JDK. $HELP_MSG" >&5 30635 $as_echo "$as_me: Could not find a valid Boot JDK. $HELP_MSG" >&6;} 30636 { $as_echo "$as_me:${as_lineno-$LINENO}: This might be fixed by explicitly setting --with-boot-jdk" >&5 30637 $as_echo "$as_me: This might be fixed by explicitly setting --with-boot-jdk" >&6;} 30638 as_fn_error $? "Cannot continue" "$LINENO" 5 30639 fi 30640 30641 30642 30643 # Setup tools from the Boot JDK. 30644 30645 # Use user overridden value if available, otherwise locate tool in the Boot JDK. 30646 30647 # Publish this variable in the help. 30648 30649 30650 if [ -z "${JAVA+x}" ]; then 30651 # The variable is not set by user, try to locate tool using the code snippet 30652 30653 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for java in Boot JDK" >&5 30654 $as_echo_n "checking for java in Boot JDK... " >&6; } 30655 JAVA=$BOOT_JDK/bin/java 30656 if test ! -x $JAVA; then 30657 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 30658 $as_echo "not found" >&6; } 30659 { $as_echo "$as_me:${as_lineno-$LINENO}: Your Boot JDK seems broken. This might be fixed by explicitly setting --with-boot-jdk" >&5 30660 $as_echo "$as_me: Your Boot JDK seems broken. This might be fixed by explicitly setting --with-boot-jdk" >&6;} 30661 as_fn_error $? "Could not find java in the Boot JDK" "$LINENO" 5 30662 fi 30663 { $as_echo "$as_me:${as_lineno-$LINENO}: result: ok" >&5 30664 $as_echo "ok" >&6; } 30665 30666 30667 else 30668 # The variable is set, but is it from the command line or the environment? 30669 30670 # Try to remove the string !JAVA! from our list. 30671 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!JAVA!/} 30672 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 30673 # If it failed, the variable was not from the command line. Ignore it, 30674 # but warn the user (except for BASH, which is always set by the calling BASH). 30675 if test "xJAVA" != xBASH; then 30676 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of JAVA from the environment. Use command line variables instead." >&5 30677 $as_echo "$as_me: WARNING: Ignoring value of JAVA from the environment. Use command line variables instead." >&2;} 30678 fi 30679 # Try to locate tool using the code snippet 30680 30681 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for java in Boot JDK" >&5 30682 $as_echo_n "checking for java in Boot JDK... " >&6; } 30683 JAVA=$BOOT_JDK/bin/java 30684 if test ! -x $JAVA; then 30685 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 30686 $as_echo "not found" >&6; } 30687 { $as_echo "$as_me:${as_lineno-$LINENO}: Your Boot JDK seems broken. This might be fixed by explicitly setting --with-boot-jdk" >&5 30688 $as_echo "$as_me: Your Boot JDK seems broken. This might be fixed by explicitly setting --with-boot-jdk" >&6;} 30689 as_fn_error $? "Could not find java in the Boot JDK" "$LINENO" 5 30690 fi 30691 { $as_echo "$as_me:${as_lineno-$LINENO}: result: ok" >&5 30692 $as_echo "ok" >&6; } 30693 30694 30695 else 30696 # If it succeeded, then it was overridden by the user. We will use it 30697 # for the tool. 30698 30699 # First remove it from the list of overridden variables, so we can test 30700 # for unknown variables in the end. 30701 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 30702 30703 # Check if we try to supply an empty value 30704 if test "x$JAVA" = x; then 30705 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool JAVA= (no value)" >&5 30706 $as_echo "$as_me: Setting user supplied tool JAVA= (no value)" >&6;} 30707 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for JAVA" >&5 30708 $as_echo_n "checking for JAVA... " >&6; } 30709 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 30710 $as_echo "disabled" >&6; } 30711 else 30712 # Check if the provided tool contains a complete path. 30713 tool_specified="$JAVA" 30714 tool_basename="${tool_specified##*/}" 30715 if test "x$tool_basename" = "x$tool_specified"; then 30716 # A command without a complete path is provided, search $PATH. 30717 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool JAVA=$tool_basename" >&5 30718 $as_echo "$as_me: Will search for user supplied tool JAVA=$tool_basename" >&6;} 30719 # Extract the first word of "$tool_basename", so it can be a program name with args. 30720 set dummy $tool_basename; ac_word=$2 30721 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 30722 $as_echo_n "checking for $ac_word... " >&6; } 30723 if ${ac_cv_path_JAVA+:} false; then : 30724 $as_echo_n "(cached) " >&6 30725 else 30726 case $JAVA in 30727 [\\/]* | ?:[\\/]*) 30728 ac_cv_path_JAVA="$JAVA" # Let the user override the test with a path. 30729 ;; 30730 *) 30731 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 30732 for as_dir in $PATH 30733 do 30734 IFS=$as_save_IFS 30735 test -z "$as_dir" && as_dir=. 30736 for ac_exec_ext in '' $ac_executable_extensions; do 30737 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 30738 ac_cv_path_JAVA="$as_dir/$ac_word$ac_exec_ext" 30739 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 30740 break 2 30741 fi 30742 done 30743 done 30744 IFS=$as_save_IFS 30745 30746 ;; 30747 esac 30748 fi 30749 JAVA=$ac_cv_path_JAVA 30750 if test -n "$JAVA"; then 30751 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $JAVA" >&5 30752 $as_echo "$JAVA" >&6; } 30753 else 30754 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 30755 $as_echo "no" >&6; } 30756 fi 30757 30758 30759 if test "x$JAVA" = x; then 30760 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 30761 fi 30762 else 30763 # Otherwise we believe it is a complete path. Use it as it is. 30764 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool JAVA=$tool_specified" >&5 30765 $as_echo "$as_me: Will use user supplied tool JAVA=$tool_specified" >&6;} 30766 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for JAVA" >&5 30767 $as_echo_n "checking for JAVA... " >&6; } 30768 if test ! -x "$tool_specified"; then 30769 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 30770 $as_echo "not found" >&6; } 30771 as_fn_error $? "User supplied tool JAVA=$tool_specified does not exist or is not executable" "$LINENO" 5 30772 fi 30773 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 30774 $as_echo "$tool_specified" >&6; } 30775 fi 30776 fi 30777 fi 30778 30779 fi 30780 30781 30782 30783 # Use user overridden value if available, otherwise locate tool in the Boot JDK. 30784 30785 # Publish this variable in the help. 30786 30787 30788 if [ -z "${JAVAC+x}" ]; then 30789 # The variable is not set by user, try to locate tool using the code snippet 30790 30791 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for javac in Boot JDK" >&5 30792 $as_echo_n "checking for javac in Boot JDK... " >&6; } 30793 JAVAC=$BOOT_JDK/bin/javac 30794 if test ! -x $JAVAC; then 30795 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 30796 $as_echo "not found" >&6; } 30797 { $as_echo "$as_me:${as_lineno-$LINENO}: Your Boot JDK seems broken. This might be fixed by explicitly setting --with-boot-jdk" >&5 30798 $as_echo "$as_me: Your Boot JDK seems broken. This might be fixed by explicitly setting --with-boot-jdk" >&6;} 30799 as_fn_error $? "Could not find javac in the Boot JDK" "$LINENO" 5 30800 fi 30801 { $as_echo "$as_me:${as_lineno-$LINENO}: result: ok" >&5 30802 $as_echo "ok" >&6; } 30803 30804 30805 else 30806 # The variable is set, but is it from the command line or the environment? 30807 30808 # Try to remove the string !JAVAC! from our list. 30809 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!JAVAC!/} 30810 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 30811 # If it failed, the variable was not from the command line. Ignore it, 30812 # but warn the user (except for BASH, which is always set by the calling BASH). 30813 if test "xJAVAC" != xBASH; then 30814 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of JAVAC from the environment. Use command line variables instead." >&5 30815 $as_echo "$as_me: WARNING: Ignoring value of JAVAC from the environment. Use command line variables instead." >&2;} 30816 fi 30817 # Try to locate tool using the code snippet 30818 30819 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for javac in Boot JDK" >&5 30820 $as_echo_n "checking for javac in Boot JDK... " >&6; } 30821 JAVAC=$BOOT_JDK/bin/javac 30822 if test ! -x $JAVAC; then 30823 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 30824 $as_echo "not found" >&6; } 30825 { $as_echo "$as_me:${as_lineno-$LINENO}: Your Boot JDK seems broken. This might be fixed by explicitly setting --with-boot-jdk" >&5 30826 $as_echo "$as_me: Your Boot JDK seems broken. This might be fixed by explicitly setting --with-boot-jdk" >&6;} 30827 as_fn_error $? "Could not find javac in the Boot JDK" "$LINENO" 5 30828 fi 30829 { $as_echo "$as_me:${as_lineno-$LINENO}: result: ok" >&5 30830 $as_echo "ok" >&6; } 30831 30832 30833 else 30834 # If it succeeded, then it was overridden by the user. We will use it 30835 # for the tool. 30836 30837 # First remove it from the list of overridden variables, so we can test 30838 # for unknown variables in the end. 30839 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 30840 30841 # Check if we try to supply an empty value 30842 if test "x$JAVAC" = x; then 30843 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool JAVAC= (no value)" >&5 30844 $as_echo "$as_me: Setting user supplied tool JAVAC= (no value)" >&6;} 30845 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for JAVAC" >&5 30846 $as_echo_n "checking for JAVAC... " >&6; } 30847 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 30848 $as_echo "disabled" >&6; } 30849 else 30850 # Check if the provided tool contains a complete path. 30851 tool_specified="$JAVAC" 30852 tool_basename="${tool_specified##*/}" 30853 if test "x$tool_basename" = "x$tool_specified"; then 30854 # A command without a complete path is provided, search $PATH. 30855 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool JAVAC=$tool_basename" >&5 30856 $as_echo "$as_me: Will search for user supplied tool JAVAC=$tool_basename" >&6;} 30857 # Extract the first word of "$tool_basename", so it can be a program name with args. 30858 set dummy $tool_basename; ac_word=$2 30859 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 30860 $as_echo_n "checking for $ac_word... " >&6; } 30861 if ${ac_cv_path_JAVAC+:} false; then : 30862 $as_echo_n "(cached) " >&6 30863 else 30864 case $JAVAC in 30865 [\\/]* | ?:[\\/]*) 30866 ac_cv_path_JAVAC="$JAVAC" # Let the user override the test with a path. 30867 ;; 30868 *) 30869 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 30870 for as_dir in $PATH 30871 do 30872 IFS=$as_save_IFS 30873 test -z "$as_dir" && as_dir=. 30874 for ac_exec_ext in '' $ac_executable_extensions; do 30875 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 30876 ac_cv_path_JAVAC="$as_dir/$ac_word$ac_exec_ext" 30877 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 30878 break 2 30879 fi 30880 done 30881 done 30882 IFS=$as_save_IFS 30883 30884 ;; 30885 esac 30886 fi 30887 JAVAC=$ac_cv_path_JAVAC 30888 if test -n "$JAVAC"; then 30889 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $JAVAC" >&5 30890 $as_echo "$JAVAC" >&6; } 30891 else 30892 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 30893 $as_echo "no" >&6; } 30894 fi 30895 30896 30897 if test "x$JAVAC" = x; then 30898 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 30899 fi 30900 else 30901 # Otherwise we believe it is a complete path. Use it as it is. 30902 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool JAVAC=$tool_specified" >&5 30903 $as_echo "$as_me: Will use user supplied tool JAVAC=$tool_specified" >&6;} 30904 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for JAVAC" >&5 30905 $as_echo_n "checking for JAVAC... " >&6; } 30906 if test ! -x "$tool_specified"; then 30907 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 30908 $as_echo "not found" >&6; } 30909 as_fn_error $? "User supplied tool JAVAC=$tool_specified does not exist or is not executable" "$LINENO" 5 30910 fi 30911 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 30912 $as_echo "$tool_specified" >&6; } 30913 fi 30914 fi 30915 fi 30916 30917 fi 30918 30919 30920 30921 # Use user overridden value if available, otherwise locate tool in the Boot JDK. 30922 30923 # Publish this variable in the help. 30924 30925 30926 if [ -z "${JAVAH+x}" ]; then 30927 # The variable is not set by user, try to locate tool using the code snippet 30928 30929 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for javah in Boot JDK" >&5 30930 $as_echo_n "checking for javah in Boot JDK... " >&6; } 30931 JAVAH=$BOOT_JDK/bin/javah 30932 if test ! -x $JAVAH; then 30933 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 30934 $as_echo "not found" >&6; } 30935 { $as_echo "$as_me:${as_lineno-$LINENO}: Your Boot JDK seems broken. This might be fixed by explicitly setting --with-boot-jdk" >&5 30936 $as_echo "$as_me: Your Boot JDK seems broken. This might be fixed by explicitly setting --with-boot-jdk" >&6;} 30937 as_fn_error $? "Could not find javah in the Boot JDK" "$LINENO" 5 30938 fi 30939 { $as_echo "$as_me:${as_lineno-$LINENO}: result: ok" >&5 30940 $as_echo "ok" >&6; } 30941 30942 30943 else 30944 # The variable is set, but is it from the command line or the environment? 30945 30946 # Try to remove the string !JAVAH! from our list. 30947 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!JAVAH!/} 30948 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 30949 # If it failed, the variable was not from the command line. Ignore it, 30950 # but warn the user (except for BASH, which is always set by the calling BASH). 30951 if test "xJAVAH" != xBASH; then 30952 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of JAVAH from the environment. Use command line variables instead." >&5 30953 $as_echo "$as_me: WARNING: Ignoring value of JAVAH from the environment. Use command line variables instead." >&2;} 30954 fi 30955 # Try to locate tool using the code snippet 30956 30957 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for javah in Boot JDK" >&5 30958 $as_echo_n "checking for javah in Boot JDK... " >&6; } 30959 JAVAH=$BOOT_JDK/bin/javah 30960 if test ! -x $JAVAH; then 30961 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 30962 $as_echo "not found" >&6; } 30963 { $as_echo "$as_me:${as_lineno-$LINENO}: Your Boot JDK seems broken. This might be fixed by explicitly setting --with-boot-jdk" >&5 30964 $as_echo "$as_me: Your Boot JDK seems broken. This might be fixed by explicitly setting --with-boot-jdk" >&6;} 30965 as_fn_error $? "Could not find javah in the Boot JDK" "$LINENO" 5 30966 fi 30967 { $as_echo "$as_me:${as_lineno-$LINENO}: result: ok" >&5 30968 $as_echo "ok" >&6; } 30969 30970 30971 else 30972 # If it succeeded, then it was overridden by the user. We will use it 30973 # for the tool. 30974 30975 # First remove it from the list of overridden variables, so we can test 30976 # for unknown variables in the end. 30977 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 30978 30979 # Check if we try to supply an empty value 30980 if test "x$JAVAH" = x; then 30981 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool JAVAH= (no value)" >&5 30982 $as_echo "$as_me: Setting user supplied tool JAVAH= (no value)" >&6;} 30983 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for JAVAH" >&5 30984 $as_echo_n "checking for JAVAH... " >&6; } 30985 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 30986 $as_echo "disabled" >&6; } 30987 else 30988 # Check if the provided tool contains a complete path. 30989 tool_specified="$JAVAH" 30990 tool_basename="${tool_specified##*/}" 30991 if test "x$tool_basename" = "x$tool_specified"; then 30992 # A command without a complete path is provided, search $PATH. 30993 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool JAVAH=$tool_basename" >&5 30994 $as_echo "$as_me: Will search for user supplied tool JAVAH=$tool_basename" >&6;} 30995 # Extract the first word of "$tool_basename", so it can be a program name with args. 30996 set dummy $tool_basename; ac_word=$2 30997 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 30998 $as_echo_n "checking for $ac_word... " >&6; } 30999 if ${ac_cv_path_JAVAH+:} false; then : 31000 $as_echo_n "(cached) " >&6 31001 else 31002 case $JAVAH in 31003 [\\/]* | ?:[\\/]*) 31004 ac_cv_path_JAVAH="$JAVAH" # Let the user override the test with a path. 31005 ;; 31006 *) 31007 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 31008 for as_dir in $PATH 31009 do 31010 IFS=$as_save_IFS 31011 test -z "$as_dir" && as_dir=. 31012 for ac_exec_ext in '' $ac_executable_extensions; do 31013 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 31014 ac_cv_path_JAVAH="$as_dir/$ac_word$ac_exec_ext" 31015 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 31016 break 2 31017 fi 31018 done 31019 done 31020 IFS=$as_save_IFS 31021 31022 ;; 31023 esac 31024 fi 31025 JAVAH=$ac_cv_path_JAVAH 31026 if test -n "$JAVAH"; then 31027 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $JAVAH" >&5 31028 $as_echo "$JAVAH" >&6; } 31029 else 31030 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 31031 $as_echo "no" >&6; } 31032 fi 31033 31034 31035 if test "x$JAVAH" = x; then 31036 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 31037 fi 31038 else 31039 # Otherwise we believe it is a complete path. Use it as it is. 31040 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool JAVAH=$tool_specified" >&5 31041 $as_echo "$as_me: Will use user supplied tool JAVAH=$tool_specified" >&6;} 31042 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for JAVAH" >&5 31043 $as_echo_n "checking for JAVAH... " >&6; } 31044 if test ! -x "$tool_specified"; then 31045 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 31046 $as_echo "not found" >&6; } 31047 as_fn_error $? "User supplied tool JAVAH=$tool_specified does not exist or is not executable" "$LINENO" 5 31048 fi 31049 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 31050 $as_echo "$tool_specified" >&6; } 31051 fi 31052 fi 31053 fi 31054 31055 fi 31056 31057 31058 31059 # Use user overridden value if available, otherwise locate tool in the Boot JDK. 31060 31061 # Publish this variable in the help. 31062 31063 31064 if [ -z "${JAVADOC+x}" ]; then 31065 # The variable is not set by user, try to locate tool using the code snippet 31066 31067 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for javadoc in Boot JDK" >&5 31068 $as_echo_n "checking for javadoc in Boot JDK... " >&6; } 31069 JAVADOC=$BOOT_JDK/bin/javadoc 31070 if test ! -x $JAVADOC; then 31071 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 31072 $as_echo "not found" >&6; } 31073 { $as_echo "$as_me:${as_lineno-$LINENO}: Your Boot JDK seems broken. This might be fixed by explicitly setting --with-boot-jdk" >&5 31074 $as_echo "$as_me: Your Boot JDK seems broken. This might be fixed by explicitly setting --with-boot-jdk" >&6;} 31075 as_fn_error $? "Could not find javadoc in the Boot JDK" "$LINENO" 5 31076 fi 31077 { $as_echo "$as_me:${as_lineno-$LINENO}: result: ok" >&5 31078 $as_echo "ok" >&6; } 31079 31080 31081 else 31082 # The variable is set, but is it from the command line or the environment? 31083 31084 # Try to remove the string !JAVADOC! from our list. 31085 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!JAVADOC!/} 31086 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 31087 # If it failed, the variable was not from the command line. Ignore it, 31088 # but warn the user (except for BASH, which is always set by the calling BASH). 31089 if test "xJAVADOC" != xBASH; then 31090 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of JAVADOC from the environment. Use command line variables instead." >&5 31091 $as_echo "$as_me: WARNING: Ignoring value of JAVADOC from the environment. Use command line variables instead." >&2;} 31092 fi 31093 # Try to locate tool using the code snippet 31094 31095 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for javadoc in Boot JDK" >&5 31096 $as_echo_n "checking for javadoc in Boot JDK... " >&6; } 31097 JAVADOC=$BOOT_JDK/bin/javadoc 31098 if test ! -x $JAVADOC; then 31099 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 31100 $as_echo "not found" >&6; } 31101 { $as_echo "$as_me:${as_lineno-$LINENO}: Your Boot JDK seems broken. This might be fixed by explicitly setting --with-boot-jdk" >&5 31102 $as_echo "$as_me: Your Boot JDK seems broken. This might be fixed by explicitly setting --with-boot-jdk" >&6;} 31103 as_fn_error $? "Could not find javadoc in the Boot JDK" "$LINENO" 5 31104 fi 31105 { $as_echo "$as_me:${as_lineno-$LINENO}: result: ok" >&5 31106 $as_echo "ok" >&6; } 31107 31108 31109 else 31110 # If it succeeded, then it was overridden by the user. We will use it 31111 # for the tool. 31112 31113 # First remove it from the list of overridden variables, so we can test 31114 # for unknown variables in the end. 31115 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 31116 31117 # Check if we try to supply an empty value 31118 if test "x$JAVADOC" = x; then 31119 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool JAVADOC= (no value)" >&5 31120 $as_echo "$as_me: Setting user supplied tool JAVADOC= (no value)" >&6;} 31121 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for JAVADOC" >&5 31122 $as_echo_n "checking for JAVADOC... " >&6; } 31123 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 31124 $as_echo "disabled" >&6; } 31125 else 31126 # Check if the provided tool contains a complete path. 31127 tool_specified="$JAVADOC" 31128 tool_basename="${tool_specified##*/}" 31129 if test "x$tool_basename" = "x$tool_specified"; then 31130 # A command without a complete path is provided, search $PATH. 31131 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool JAVADOC=$tool_basename" >&5 31132 $as_echo "$as_me: Will search for user supplied tool JAVADOC=$tool_basename" >&6;} 31133 # Extract the first word of "$tool_basename", so it can be a program name with args. 31134 set dummy $tool_basename; ac_word=$2 31135 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 31136 $as_echo_n "checking for $ac_word... " >&6; } 31137 if ${ac_cv_path_JAVADOC+:} false; then : 31138 $as_echo_n "(cached) " >&6 31139 else 31140 case $JAVADOC in 31141 [\\/]* | ?:[\\/]*) 31142 ac_cv_path_JAVADOC="$JAVADOC" # Let the user override the test with a path. 31143 ;; 31144 *) 31145 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 31146 for as_dir in $PATH 31147 do 31148 IFS=$as_save_IFS 31149 test -z "$as_dir" && as_dir=. 31150 for ac_exec_ext in '' $ac_executable_extensions; do 31151 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 31152 ac_cv_path_JAVADOC="$as_dir/$ac_word$ac_exec_ext" 31153 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 31154 break 2 31155 fi 31156 done 31157 done 31158 IFS=$as_save_IFS 31159 31160 ;; 31161 esac 31162 fi 31163 JAVADOC=$ac_cv_path_JAVADOC 31164 if test -n "$JAVADOC"; then 31165 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $JAVADOC" >&5 31166 $as_echo "$JAVADOC" >&6; } 31167 else 31168 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 31169 $as_echo "no" >&6; } 31170 fi 31171 31172 31173 if test "x$JAVADOC" = x; then 31174 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 31175 fi 31176 else 31177 # Otherwise we believe it is a complete path. Use it as it is. 31178 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool JAVADOC=$tool_specified" >&5 31179 $as_echo "$as_me: Will use user supplied tool JAVADOC=$tool_specified" >&6;} 31180 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for JAVADOC" >&5 31181 $as_echo_n "checking for JAVADOC... " >&6; } 31182 if test ! -x "$tool_specified"; then 31183 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 31184 $as_echo "not found" >&6; } 31185 as_fn_error $? "User supplied tool JAVADOC=$tool_specified does not exist or is not executable" "$LINENO" 5 31186 fi 31187 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 31188 $as_echo "$tool_specified" >&6; } 31189 fi 31190 fi 31191 fi 31192 31193 fi 31194 31195 31196 31197 # Use user overridden value if available, otherwise locate tool in the Boot JDK. 31198 31199 # Publish this variable in the help. 31200 31201 31202 if [ -z "${JAR+x}" ]; then 31203 # The variable is not set by user, try to locate tool using the code snippet 31204 31205 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for jar in Boot JDK" >&5 31206 $as_echo_n "checking for jar in Boot JDK... " >&6; } 31207 JAR=$BOOT_JDK/bin/jar 31208 if test ! -x $JAR; then 31209 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 31210 $as_echo "not found" >&6; } 31211 { $as_echo "$as_me:${as_lineno-$LINENO}: Your Boot JDK seems broken. This might be fixed by explicitly setting --with-boot-jdk" >&5 31212 $as_echo "$as_me: Your Boot JDK seems broken. This might be fixed by explicitly setting --with-boot-jdk" >&6;} 31213 as_fn_error $? "Could not find jar in the Boot JDK" "$LINENO" 5 31214 fi 31215 { $as_echo "$as_me:${as_lineno-$LINENO}: result: ok" >&5 31216 $as_echo "ok" >&6; } 31217 31218 31219 else 31220 # The variable is set, but is it from the command line or the environment? 31221 31222 # Try to remove the string !JAR! from our list. 31223 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!JAR!/} 31224 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 31225 # If it failed, the variable was not from the command line. Ignore it, 31226 # but warn the user (except for BASH, which is always set by the calling BASH). 31227 if test "xJAR" != xBASH; then 31228 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of JAR from the environment. Use command line variables instead." >&5 31229 $as_echo "$as_me: WARNING: Ignoring value of JAR from the environment. Use command line variables instead." >&2;} 31230 fi 31231 # Try to locate tool using the code snippet 31232 31233 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for jar in Boot JDK" >&5 31234 $as_echo_n "checking for jar in Boot JDK... " >&6; } 31235 JAR=$BOOT_JDK/bin/jar 31236 if test ! -x $JAR; then 31237 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 31238 $as_echo "not found" >&6; } 31239 { $as_echo "$as_me:${as_lineno-$LINENO}: Your Boot JDK seems broken. This might be fixed by explicitly setting --with-boot-jdk" >&5 31240 $as_echo "$as_me: Your Boot JDK seems broken. This might be fixed by explicitly setting --with-boot-jdk" >&6;} 31241 as_fn_error $? "Could not find jar in the Boot JDK" "$LINENO" 5 31242 fi 31243 { $as_echo "$as_me:${as_lineno-$LINENO}: result: ok" >&5 31244 $as_echo "ok" >&6; } 31245 31246 31247 else 31248 # If it succeeded, then it was overridden by the user. We will use it 31249 # for the tool. 31250 31251 # First remove it from the list of overridden variables, so we can test 31252 # for unknown variables in the end. 31253 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 31254 31255 # Check if we try to supply an empty value 31256 if test "x$JAR" = x; then 31257 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool JAR= (no value)" >&5 31258 $as_echo "$as_me: Setting user supplied tool JAR= (no value)" >&6;} 31259 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for JAR" >&5 31260 $as_echo_n "checking for JAR... " >&6; } 31261 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 31262 $as_echo "disabled" >&6; } 31263 else 31264 # Check if the provided tool contains a complete path. 31265 tool_specified="$JAR" 31266 tool_basename="${tool_specified##*/}" 31267 if test "x$tool_basename" = "x$tool_specified"; then 31268 # A command without a complete path is provided, search $PATH. 31269 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool JAR=$tool_basename" >&5 31270 $as_echo "$as_me: Will search for user supplied tool JAR=$tool_basename" >&6;} 31271 # Extract the first word of "$tool_basename", so it can be a program name with args. 31272 set dummy $tool_basename; ac_word=$2 31273 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 31274 $as_echo_n "checking for $ac_word... " >&6; } 31275 if ${ac_cv_path_JAR+:} false; then : 31276 $as_echo_n "(cached) " >&6 31277 else 31278 case $JAR in 31279 [\\/]* | ?:[\\/]*) 31280 ac_cv_path_JAR="$JAR" # Let the user override the test with a path. 31281 ;; 31282 *) 31283 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 31284 for as_dir in $PATH 31285 do 31286 IFS=$as_save_IFS 31287 test -z "$as_dir" && as_dir=. 31288 for ac_exec_ext in '' $ac_executable_extensions; do 31289 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 31290 ac_cv_path_JAR="$as_dir/$ac_word$ac_exec_ext" 31291 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 31292 break 2 31293 fi 31294 done 31295 done 31296 IFS=$as_save_IFS 31297 31298 ;; 31299 esac 31300 fi 31301 JAR=$ac_cv_path_JAR 31302 if test -n "$JAR"; then 31303 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $JAR" >&5 31304 $as_echo "$JAR" >&6; } 31305 else 31306 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 31307 $as_echo "no" >&6; } 31308 fi 31309 31310 31311 if test "x$JAR" = x; then 31312 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 31313 fi 31314 else 31315 # Otherwise we believe it is a complete path. Use it as it is. 31316 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool JAR=$tool_specified" >&5 31317 $as_echo "$as_me: Will use user supplied tool JAR=$tool_specified" >&6;} 31318 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for JAR" >&5 31319 $as_echo_n "checking for JAR... " >&6; } 31320 if test ! -x "$tool_specified"; then 31321 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 31322 $as_echo "not found" >&6; } 31323 as_fn_error $? "User supplied tool JAR=$tool_specified does not exist or is not executable" "$LINENO" 5 31324 fi 31325 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 31326 $as_echo "$tool_specified" >&6; } 31327 fi 31328 fi 31329 fi 31330 31331 fi 31332 31333 31334 31335 # Use user overridden value if available, otherwise locate tool in the Boot JDK. 31336 31337 # Publish this variable in the help. 31338 31339 31340 if [ -z "${JARSIGNER+x}" ]; then 31341 # The variable is not set by user, try to locate tool using the code snippet 31342 31343 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for jarsigner in Boot JDK" >&5 31344 $as_echo_n "checking for jarsigner in Boot JDK... " >&6; } 31345 JARSIGNER=$BOOT_JDK/bin/jarsigner 31346 if test ! -x $JARSIGNER; then 31347 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 31348 $as_echo "not found" >&6; } 31349 { $as_echo "$as_me:${as_lineno-$LINENO}: Your Boot JDK seems broken. This might be fixed by explicitly setting --with-boot-jdk" >&5 31350 $as_echo "$as_me: Your Boot JDK seems broken. This might be fixed by explicitly setting --with-boot-jdk" >&6;} 31351 as_fn_error $? "Could not find jarsigner in the Boot JDK" "$LINENO" 5 31352 fi 31353 { $as_echo "$as_me:${as_lineno-$LINENO}: result: ok" >&5 31354 $as_echo "ok" >&6; } 31355 31356 31357 else 31358 # The variable is set, but is it from the command line or the environment? 31359 31360 # Try to remove the string !JARSIGNER! from our list. 31361 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!JARSIGNER!/} 31362 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 31363 # If it failed, the variable was not from the command line. Ignore it, 31364 # but warn the user (except for BASH, which is always set by the calling BASH). 31365 if test "xJARSIGNER" != xBASH; then 31366 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of JARSIGNER from the environment. Use command line variables instead." >&5 31367 $as_echo "$as_me: WARNING: Ignoring value of JARSIGNER from the environment. Use command line variables instead." >&2;} 31368 fi 31369 # Try to locate tool using the code snippet 31370 31371 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for jarsigner in Boot JDK" >&5 31372 $as_echo_n "checking for jarsigner in Boot JDK... " >&6; } 31373 JARSIGNER=$BOOT_JDK/bin/jarsigner 31374 if test ! -x $JARSIGNER; then 31375 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 31376 $as_echo "not found" >&6; } 31377 { $as_echo "$as_me:${as_lineno-$LINENO}: Your Boot JDK seems broken. This might be fixed by explicitly setting --with-boot-jdk" >&5 31378 $as_echo "$as_me: Your Boot JDK seems broken. This might be fixed by explicitly setting --with-boot-jdk" >&6;} 31379 as_fn_error $? "Could not find jarsigner in the Boot JDK" "$LINENO" 5 31380 fi 31381 { $as_echo "$as_me:${as_lineno-$LINENO}: result: ok" >&5 31382 $as_echo "ok" >&6; } 31383 31384 31385 else 31386 # If it succeeded, then it was overridden by the user. We will use it 31387 # for the tool. 31388 31389 # First remove it from the list of overridden variables, so we can test 31390 # for unknown variables in the end. 31391 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 31392 31393 # Check if we try to supply an empty value 31394 if test "x$JARSIGNER" = x; then 31395 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool JARSIGNER= (no value)" >&5 31396 $as_echo "$as_me: Setting user supplied tool JARSIGNER= (no value)" >&6;} 31397 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for JARSIGNER" >&5 31398 $as_echo_n "checking for JARSIGNER... " >&6; } 31399 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 31400 $as_echo "disabled" >&6; } 31401 else 31402 # Check if the provided tool contains a complete path. 31403 tool_specified="$JARSIGNER" 31404 tool_basename="${tool_specified##*/}" 31405 if test "x$tool_basename" = "x$tool_specified"; then 31406 # A command without a complete path is provided, search $PATH. 31407 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool JARSIGNER=$tool_basename" >&5 31408 $as_echo "$as_me: Will search for user supplied tool JARSIGNER=$tool_basename" >&6;} 31409 # Extract the first word of "$tool_basename", so it can be a program name with args. 31410 set dummy $tool_basename; ac_word=$2 31411 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 31412 $as_echo_n "checking for $ac_word... " >&6; } 31413 if ${ac_cv_path_JARSIGNER+:} false; then : 31414 $as_echo_n "(cached) " >&6 31415 else 31416 case $JARSIGNER in 31417 [\\/]* | ?:[\\/]*) 31418 ac_cv_path_JARSIGNER="$JARSIGNER" # Let the user override the test with a path. 31419 ;; 31420 *) 31421 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 31422 for as_dir in $PATH 31423 do 31424 IFS=$as_save_IFS 31425 test -z "$as_dir" && as_dir=. 31426 for ac_exec_ext in '' $ac_executable_extensions; do 31427 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 31428 ac_cv_path_JARSIGNER="$as_dir/$ac_word$ac_exec_ext" 31429 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 31430 break 2 31431 fi 31432 done 31433 done 31434 IFS=$as_save_IFS 31435 31436 ;; 31437 esac 31438 fi 31439 JARSIGNER=$ac_cv_path_JARSIGNER 31440 if test -n "$JARSIGNER"; then 31441 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $JARSIGNER" >&5 31442 $as_echo "$JARSIGNER" >&6; } 31443 else 31444 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 31445 $as_echo "no" >&6; } 31446 fi 31447 31448 31449 if test "x$JARSIGNER" = x; then 31450 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 31451 fi 31452 else 31453 # Otherwise we believe it is a complete path. Use it as it is. 31454 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool JARSIGNER=$tool_specified" >&5 31455 $as_echo "$as_me: Will use user supplied tool JARSIGNER=$tool_specified" >&6;} 31456 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for JARSIGNER" >&5 31457 $as_echo_n "checking for JARSIGNER... " >&6; } 31458 if test ! -x "$tool_specified"; then 31459 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 31460 $as_echo "not found" >&6; } 31461 as_fn_error $? "User supplied tool JARSIGNER=$tool_specified does not exist or is not executable" "$LINENO" 5 31462 fi 31463 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 31464 $as_echo "$tool_specified" >&6; } 31465 fi 31466 fi 31467 fi 31468 31469 fi 31470 31471 31472 31473 # Finally, set some other options... 31474 31475 # When compiling code to be executed by the Boot JDK, force compatibility with the 31476 # oldest supported bootjdk. 31477 BOOT_JDK_SOURCETARGET="-source 9 -target 9" 31478 31479 31480 31481 31482 # Check if the boot jdk is 32 or 64 bit 31483 if "$JAVA" -version 2>&1 | $GREP -q "64-Bit"; then 31484 BOOT_JDK_BITS="64" 31485 else 31486 BOOT_JDK_BITS="32" 31487 fi 31488 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if Boot JDK is 32 or 64 bits" >&5 31489 $as_echo_n "checking if Boot JDK is 32 or 64 bits... " >&6; } 31490 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK_BITS" >&5 31491 $as_echo "$BOOT_JDK_BITS" >&6; } 31492 31493 # Try to enable CDS 31494 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for local Boot JDK Class Data Sharing (CDS)" >&5 31495 $as_echo_n "checking for local Boot JDK Class Data Sharing (CDS)... " >&6; } 31496 BOOT_JDK_CDS_ARCHIVE=$CONFIGURESUPPORT_OUTPUTDIR/classes.jsa 31497 31498 $ECHO "Check if jvm arg is ok: -XX:+UnlockDiagnosticVMOptions -XX:-VerifySharedSpaces -XX:SharedArchiveFile=$BOOT_JDK_CDS_ARCHIVE" >&5 31499 $ECHO "Command: $JAVA -XX:+UnlockDiagnosticVMOptions -XX:-VerifySharedSpaces -XX:SharedArchiveFile=$BOOT_JDK_CDS_ARCHIVE -version" >&5 31500 OUTPUT=`$JAVA -XX:+UnlockDiagnosticVMOptions -XX:-VerifySharedSpaces -XX:SharedArchiveFile=$BOOT_JDK_CDS_ARCHIVE -version 2>&1` 31501 FOUND_WARN=`$ECHO "$OUTPUT" | $GREP -i warn` 31502 FOUND_VERSION=`$ECHO $OUTPUT | $GREP " version \""` 31503 if test "x$FOUND_VERSION" != x && test "x$FOUND_WARN" = x; then 31504 boot_jdk_cds_args="$boot_jdk_cds_args -XX:+UnlockDiagnosticVMOptions -XX:-VerifySharedSpaces -XX:SharedArchiveFile=$BOOT_JDK_CDS_ARCHIVE" 31505 JVM_ARG_OK=true 31506 else 31507 $ECHO "Arg failed:" >&5 31508 $ECHO "$OUTPUT" >&5 31509 JVM_ARG_OK=false 31510 fi 31511 31512 31513 if test "x$boot_jdk_cds_args" != x; then 31514 # Try creating a CDS archive 31515 "$JAVA" $boot_jdk_cds_args -Xshare:dump > /dev/null 2>&1 31516 if test $? -eq 0; then 31517 BOOTJDK_USE_LOCAL_CDS=true 31518 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes, created" >&5 31519 $as_echo "yes, created" >&6; } 31520 else 31521 # Generation failed, don't use CDS. 31522 BOOTJDK_USE_LOCAL_CDS=false 31523 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no, creation failed" >&5 31524 $as_echo "no, creation failed" >&6; } 31525 fi 31526 else 31527 BOOTJDK_USE_LOCAL_CDS=false 31528 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no, -XX:SharedArchiveFile not supported" >&5 31529 $as_echo "no, -XX:SharedArchiveFile not supported" >&6; } 31530 fi 31531 31532 31533 31534 # Check whether --with-build-jdk was given. 31535 if test "${with_build_jdk+set}" = set; then : 31536 withval=$with_build_jdk; 31537 fi 31538 31539 31540 CREATE_BUILDJDK=false 31541 EXTERNAL_BUILDJDK=false 31542 BUILD_JDK_FOUND="no" 31543 if test "x$with_build_jdk" != "x"; then 31544 31545 if test "x$BUILD_JDK_FOUND" = xno; then 31546 # Execute the test 31547 31548 if test "x$with_build_jdk" != x; then 31549 BUILD_JDK=$with_build_jdk 31550 BUILD_JDK_FOUND=maybe 31551 { $as_echo "$as_me:${as_lineno-$LINENO}: Found potential Build JDK using configure arguments" >&5 31552 $as_echo "$as_me: Found potential Build JDK using configure arguments" >&6;} 31553 fi 31554 31555 # If previous step claimed to have found a JDK, check it to see if it seems to be valid. 31556 if test "x$BUILD_JDK_FOUND" = xmaybe; then 31557 # Do we have a bin/java? 31558 if test ! -x "$BUILD_JDK/bin/java"; then 31559 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Build JDK found at $BUILD_JDK did not contain bin/java; ignoring" >&5 31560 $as_echo "$as_me: Potential Build JDK found at $BUILD_JDK did not contain bin/java; ignoring" >&6;} 31561 BUILD_JDK_FOUND=no 31562 elif test ! -x "$BUILD_JDK/bin/jlink"; then 31563 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Build JDK found at $BUILD_JDK did not contain bin/jlink; ignoring" >&5 31564 $as_echo "$as_me: Potential Build JDK found at $BUILD_JDK did not contain bin/jlink; ignoring" >&6;} 31565 BUILD_JDK_FOUND=no 31566 elif test ! -x "$BUILD_JDK/bin/jmod"; then 31567 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Build JDK found at $BUILD_JDK did not contain bin/jmod; ignoring" >&5 31568 $as_echo "$as_me: Potential Build JDK found at $BUILD_JDK did not contain bin/jmod; ignoring" >&6;} 31569 BUILD_JDK_FOUND=no 31570 elif test ! -x "$BUILD_JDK/bin/javac"; then 31571 # Do we have a bin/javac? 31572 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Build JDK found at $BUILD_JDK did not contain bin/javac; ignoring" >&5 31573 $as_echo "$as_me: Potential Build JDK found at $BUILD_JDK did not contain bin/javac; ignoring" >&6;} 31574 { $as_echo "$as_me:${as_lineno-$LINENO}: (This might be a JRE instead of an JDK)" >&5 31575 $as_echo "$as_me: (This might be a JRE instead of an JDK)" >&6;} 31576 BUILD_JDK_FOUND=no 31577 else 31578 # Oh, this is looking good! We probably have found a proper JDK. Is it the correct version? 31579 BUILD_JDK_VERSION=`"$BUILD_JDK/bin/java" -version 2>&1 | $HEAD -n 1` 31580 31581 # Extra M4 quote needed to protect [] in grep expression. 31582 FOUND_CORRECT_VERSION=`echo $BUILD_JDK_VERSION | $EGREP '\"10([\.+-].*)?\"'` 31583 if test "x$FOUND_CORRECT_VERSION" = x; then 31584 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Build JDK found at $BUILD_JDK is incorrect JDK version ($BUILD_JDK_VERSION); ignoring" >&5 31585 $as_echo "$as_me: Potential Build JDK found at $BUILD_JDK is incorrect JDK version ($BUILD_JDK_VERSION); ignoring" >&6;} 31586 { $as_echo "$as_me:${as_lineno-$LINENO}: (Your Build JDK must be version 10)" >&5 31587 $as_echo "$as_me: (Your Build JDK must be version 10)" >&6;} 31588 BUILD_JDK_FOUND=no 31589 else 31590 # We're done! 31591 BUILD_JDK_FOUND=yes 31592 31593 # Only process if variable expands to non-empty 31594 31595 if test "x$BUILD_JDK" != x; then 31596 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 31597 31598 # Input might be given as Windows format, start by converting to 31599 # unix format. 31600 path="$BUILD_JDK" 31601 new_path=`$CYGPATH -u "$path"` 31602 31603 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 31604 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 31605 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 31606 # "foo.exe" is OK but "foo" is an error. 31607 # 31608 # This test is therefore slightly more accurate than "test -f" to check for file precense. 31609 # It is also a way to make sure we got the proper file name for the real test later on. 31610 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 31611 if test "x$test_shortpath" = x; then 31612 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BUILD_JDK, which resolves as \"$path\", is invalid." >&5 31613 $as_echo "$as_me: The path of BUILD_JDK, which resolves as \"$path\", is invalid." >&6;} 31614 as_fn_error $? "Cannot locate the the path of BUILD_JDK" "$LINENO" 5 31615 fi 31616 31617 # Call helper function which possibly converts this using DOS-style short mode. 31618 # If so, the updated path is stored in $new_path. 31619 31620 input_path="$new_path" 31621 # Check if we need to convert this using DOS-style short mode. If the path 31622 # contains just simple characters, use it. Otherwise (spaces, weird characters), 31623 # take no chances and rewrite it. 31624 # Note: m4 eats our [], so we need to use [ and ] instead. 31625 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 31626 if test "x$has_forbidden_chars" != x; then 31627 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 31628 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 31629 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 31630 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 31631 # Going to short mode and back again did indeed matter. Since short mode is 31632 # case insensitive, let's make it lowercase to improve readability. 31633 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 31634 # Now convert it back to Unix-style (cygpath) 31635 input_path=`$CYGPATH -u "$shortmode_path"` 31636 new_path="$input_path" 31637 fi 31638 fi 31639 31640 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 31641 if test "x$test_cygdrive_prefix" = x; then 31642 # As a simple fix, exclude /usr/bin since it's not a real path. 31643 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 31644 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 31645 # a path prefixed by /cygdrive for fixpath to work. 31646 new_path="$CYGWIN_ROOT_PATH$input_path" 31647 fi 31648 fi 31649 31650 31651 if test "x$path" != "x$new_path"; then 31652 BUILD_JDK="$new_path" 31653 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BUILD_JDK to \"$new_path\"" >&5 31654 $as_echo "$as_me: Rewriting BUILD_JDK to \"$new_path\"" >&6;} 31655 fi 31656 31657 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 31658 31659 path="$BUILD_JDK" 31660 has_colon=`$ECHO $path | $GREP ^.:` 31661 new_path="$path" 31662 if test "x$has_colon" = x; then 31663 # Not in mixed or Windows style, start by that. 31664 new_path=`cmd //c echo $path` 31665 fi 31666 31667 31668 input_path="$new_path" 31669 # Check if we need to convert this using DOS-style short mode. If the path 31670 # contains just simple characters, use it. Otherwise (spaces, weird characters), 31671 # take no chances and rewrite it. 31672 # Note: m4 eats our [], so we need to use [ and ] instead. 31673 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 31674 if test "x$has_forbidden_chars" != x; then 31675 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 31676 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 31677 fi 31678 31679 31680 windows_path="$new_path" 31681 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 31682 unix_path=`$CYGPATH -u "$windows_path"` 31683 new_path="$unix_path" 31684 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 31685 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 31686 new_path="$unix_path" 31687 fi 31688 31689 if test "x$path" != "x$new_path"; then 31690 BUILD_JDK="$new_path" 31691 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BUILD_JDK to \"$new_path\"" >&5 31692 $as_echo "$as_me: Rewriting BUILD_JDK to \"$new_path\"" >&6;} 31693 fi 31694 31695 # Save the first 10 bytes of this path to the storage, so fixpath can work. 31696 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 31697 31698 else 31699 # We're on a unix platform. Hooray! :) 31700 path="$BUILD_JDK" 31701 has_space=`$ECHO "$path" | $GREP " "` 31702 if test "x$has_space" != x; then 31703 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BUILD_JDK, which resolves as \"$path\", is invalid." >&5 31704 $as_echo "$as_me: The path of BUILD_JDK, which resolves as \"$path\", is invalid." >&6;} 31705 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 31706 fi 31707 31708 # Use eval to expand a potential ~ 31709 eval path="$path" 31710 if test ! -f "$path" && test ! -d "$path"; then 31711 as_fn_error $? "The path of BUILD_JDK, which resolves as \"$path\", is not found." "$LINENO" 5 31712 fi 31713 31714 if test -d "$path"; then 31715 BUILD_JDK="`cd "$path"; $THEPWDCMD -L`" 31716 else 31717 dir="`$DIRNAME "$path"`" 31718 base="`$BASENAME "$path"`" 31719 BUILD_JDK="`cd "$dir"; $THEPWDCMD -L`/$base" 31720 fi 31721 fi 31722 fi 31723 31724 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for Build JDK" >&5 31725 $as_echo_n "checking for Build JDK... " >&6; } 31726 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BUILD_JDK" >&5 31727 $as_echo "$BUILD_JDK" >&6; } 31728 { $as_echo "$as_me:${as_lineno-$LINENO}: checking Build JDK version" >&5 31729 $as_echo_n "checking Build JDK version... " >&6; } 31730 BUILD_JDK_VERSION=`"$BUILD_JDK/bin/java" -version 2>&1 | $TR '\n\r' ' '` 31731 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BUILD_JDK_VERSION" >&5 31732 $as_echo "$BUILD_JDK_VERSION" >&6; } 31733 fi # end check jdk version 31734 fi # end check java 31735 fi # end check build jdk found 31736 fi 31737 31738 EXTERNAL_BUILDJDK=true 31739 else 31740 if test "x$COMPILE_TYPE" = "xcross"; then 31741 BUILD_JDK="\$(BUILDJDK_OUTPUTDIR)/jdk" 31742 BUILD_JDK_FOUND=yes 31743 CREATE_BUILDJDK=true 31744 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for Build JDK" >&5 31745 $as_echo_n "checking for Build JDK... " >&6; } 31746 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes, will build it for the host platform" >&5 31747 $as_echo "yes, will build it for the host platform" >&6; } 31748 else 31749 BUILD_JDK="\$(JDK_OUTPUTDIR)" 31750 BUILD_JDK_FOUND=yes 31751 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for Build JDK" >&5 31752 $as_echo_n "checking for Build JDK... " >&6; } 31753 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes, will use output dir" >&5 31754 $as_echo "yes, will use output dir" >&6; } 31755 fi 31756 fi 31757 31758 JMOD="$BUILD_JDK/bin/jmod" 31759 JLINK="$BUILD_JDK/bin/jlink" 31760 31761 31762 31763 if test "x$BUILD_JDK_FOUND" != "xyes"; then 31764 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for Build JDK" >&5 31765 $as_echo_n "checking for Build JDK... " >&6; } 31766 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 31767 $as_echo "no" >&6; } 31768 as_fn_error $? "Could not find a suitable Build JDK" "$LINENO" 5 31769 fi 31770 31771 31772 31773 31774 31775 31776 ############################################################################### 31777 # 31778 # Configure the sources to use. We can add or override individual directories. 31779 # 31780 ############################################################################### 31781 31782 31783 OUTPUTDIR="$OUTPUTDIR" 31784 31785 JDK_OUTPUTDIR="$OUTPUTDIR/jdk" 31786 31787 # Where are the sources. 31788 31789 31790 31791 31792 # Check whether --with-import-modules was given. 31793 if test "${with_import_modules+set}" = set; then : 31794 withval=$with_import_modules; 31795 fi 31796 31797 31798 if test "x$with_import_modules" != x \ 31799 && test "x$with_import_modules" != "xno"; then 31800 if test -d "$with_import_modules"; then 31801 IMPORT_MODULES_TOPDIR="$with_import_modules" 31802 31803 # Only process if variable expands to non-empty 31804 31805 if test "x$IMPORT_MODULES_TOPDIR" != x; then 31806 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 31807 31808 # Input might be given as Windows format, start by converting to 31809 # unix format. 31810 path="$IMPORT_MODULES_TOPDIR" 31811 new_path=`$CYGPATH -u "$path"` 31812 31813 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 31814 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 31815 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 31816 # "foo.exe" is OK but "foo" is an error. 31817 # 31818 # This test is therefore slightly more accurate than "test -f" to check for file precense. 31819 # It is also a way to make sure we got the proper file name for the real test later on. 31820 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 31821 if test "x$test_shortpath" = x; then 31822 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of IMPORT_MODULES_TOPDIR, which resolves as \"$path\", is invalid." >&5 31823 $as_echo "$as_me: The path of IMPORT_MODULES_TOPDIR, which resolves as \"$path\", is invalid." >&6;} 31824 as_fn_error $? "Cannot locate the the path of IMPORT_MODULES_TOPDIR" "$LINENO" 5 31825 fi 31826 31827 # Call helper function which possibly converts this using DOS-style short mode. 31828 # If so, the updated path is stored in $new_path. 31829 31830 input_path="$new_path" 31831 # Check if we need to convert this using DOS-style short mode. If the path 31832 # contains just simple characters, use it. Otherwise (spaces, weird characters), 31833 # take no chances and rewrite it. 31834 # Note: m4 eats our [], so we need to use [ and ] instead. 31835 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 31836 if test "x$has_forbidden_chars" != x; then 31837 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 31838 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 31839 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 31840 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 31841 # Going to short mode and back again did indeed matter. Since short mode is 31842 # case insensitive, let's make it lowercase to improve readability. 31843 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 31844 # Now convert it back to Unix-style (cygpath) 31845 input_path=`$CYGPATH -u "$shortmode_path"` 31846 new_path="$input_path" 31847 fi 31848 fi 31849 31850 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 31851 if test "x$test_cygdrive_prefix" = x; then 31852 # As a simple fix, exclude /usr/bin since it's not a real path. 31853 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 31854 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 31855 # a path prefixed by /cygdrive for fixpath to work. 31856 new_path="$CYGWIN_ROOT_PATH$input_path" 31857 fi 31858 fi 31859 31860 31861 if test "x$path" != "x$new_path"; then 31862 IMPORT_MODULES_TOPDIR="$new_path" 31863 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting IMPORT_MODULES_TOPDIR to \"$new_path\"" >&5 31864 $as_echo "$as_me: Rewriting IMPORT_MODULES_TOPDIR to \"$new_path\"" >&6;} 31865 fi 31866 31867 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 31868 31869 path="$IMPORT_MODULES_TOPDIR" 31870 has_colon=`$ECHO $path | $GREP ^.:` 31871 new_path="$path" 31872 if test "x$has_colon" = x; then 31873 # Not in mixed or Windows style, start by that. 31874 new_path=`cmd //c echo $path` 31875 fi 31876 31877 31878 input_path="$new_path" 31879 # Check if we need to convert this using DOS-style short mode. If the path 31880 # contains just simple characters, use it. Otherwise (spaces, weird characters), 31881 # take no chances and rewrite it. 31882 # Note: m4 eats our [], so we need to use [ and ] instead. 31883 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 31884 if test "x$has_forbidden_chars" != x; then 31885 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 31886 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 31887 fi 31888 31889 31890 windows_path="$new_path" 31891 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 31892 unix_path=`$CYGPATH -u "$windows_path"` 31893 new_path="$unix_path" 31894 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 31895 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 31896 new_path="$unix_path" 31897 fi 31898 31899 if test "x$path" != "x$new_path"; then 31900 IMPORT_MODULES_TOPDIR="$new_path" 31901 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting IMPORT_MODULES_TOPDIR to \"$new_path\"" >&5 31902 $as_echo "$as_me: Rewriting IMPORT_MODULES_TOPDIR to \"$new_path\"" >&6;} 31903 fi 31904 31905 # Save the first 10 bytes of this path to the storage, so fixpath can work. 31906 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 31907 31908 else 31909 # We're on a unix platform. Hooray! :) 31910 path="$IMPORT_MODULES_TOPDIR" 31911 has_space=`$ECHO "$path" | $GREP " "` 31912 if test "x$has_space" != x; then 31913 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of IMPORT_MODULES_TOPDIR, which resolves as \"$path\", is invalid." >&5 31914 $as_echo "$as_me: The path of IMPORT_MODULES_TOPDIR, which resolves as \"$path\", is invalid." >&6;} 31915 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 31916 fi 31917 31918 # Use eval to expand a potential ~ 31919 eval path="$path" 31920 if test ! -f "$path" && test ! -d "$path"; then 31921 as_fn_error $? "The path of IMPORT_MODULES_TOPDIR, which resolves as \"$path\", is not found." "$LINENO" 5 31922 fi 31923 31924 if test -d "$path"; then 31925 IMPORT_MODULES_TOPDIR="`cd "$path"; $THEPWDCMD -L`" 31926 else 31927 dir="`$DIRNAME "$path"`" 31928 base="`$BASENAME "$path"`" 31929 IMPORT_MODULES_TOPDIR="`cd "$dir"; $THEPWDCMD -L`/$base" 31930 fi 31931 fi 31932 fi 31933 31934 elif test -e "$with_import_modules"; then 31935 IMPORT_MODULES_TOPDIR="$CONFIGURESUPPORT_OUTPUTDIR/import-modules" 31936 $RM -rf "$IMPORT_MODULES_TOPDIR" 31937 $MKDIR -p "$IMPORT_MODULES_TOPDIR" 31938 if ! $UNZIP -q "$with_import_modules" -d "$IMPORT_MODULES_TOPDIR"; then 31939 as_fn_error $? "--with-import-modules=\"$with_import_modules\" must point to a dir or a zip file" "$LINENO" 5 31940 fi 31941 else 31942 as_fn_error $? "--with-import-modules=\"$with_import_modules\" must point to a dir or a zip file" "$LINENO" 5 31943 fi 31944 fi 31945 31946 if test -d "$IMPORT_MODULES_TOPDIR/modules"; then 31947 IMPORT_MODULES_CLASSES="$IMPORT_MODULES_TOPDIR/modules" 31948 fi 31949 if test -d "$IMPORT_MODULES_TOPDIR/modules_cmds"; then 31950 IMPORT_MODULES_CMDS="$IMPORT_MODULES_TOPDIR/modules_cmds" 31951 fi 31952 if test -d "$IMPORT_MODULES_TOPDIR/modules_libs"; then 31953 IMPORT_MODULES_LIBS="$IMPORT_MODULES_TOPDIR/modules_libs" 31954 fi 31955 if test -d "$IMPORT_MODULES_TOPDIR/modules_conf"; then 31956 IMPORT_MODULES_CONF="$IMPORT_MODULES_TOPDIR/modules_conf" 31957 fi 31958 if test -d "$IMPORT_MODULES_TOPDIR/modules_legal"; then 31959 IMPORT_MODULES_LEGAL="$IMPORT_MODULES_TOPDIR/modules_legal" 31960 fi 31961 if test -d "$IMPORT_MODULES_TOPDIR/modules_man"; then 31962 IMPORT_MODULES_MAN="$IMPORT_MODULES_TOPDIR/modules_man" 31963 fi 31964 if test -d "$IMPORT_MODULES_TOPDIR/modules_src"; then 31965 IMPORT_MODULES_SRC="$IMPORT_MODULES_TOPDIR/modules_src" 31966 fi 31967 if test -d "$IMPORT_MODULES_TOPDIR/make"; then 31968 IMPORT_MODULES_MAKE="$IMPORT_MODULES_TOPDIR/make" 31969 fi 31970 31971 31972 31973 31974 31975 31976 31977 31978 31979 31980 31981 ############################################################################### 31982 # 31983 # Setup the toolchain (compilers etc), i.e. tools used to compile and process 31984 # native code. 31985 # 31986 ############################################################################### 31987 31988 # See if we are doing a complete static build or not 31989 31990 # Check whether --enable-static-build was given. 31991 if test "${enable_static_build+set}" = set; then : 31992 enableval=$enable_static_build; 31993 fi 31994 31995 STATIC_BUILD=false 31996 if test "x$enable_static_build" = "xyes"; then 31997 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if static build is enabled" >&5 31998 $as_echo_n "checking if static build is enabled... " >&6; } 31999 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 32000 $as_echo "yes" >&6; } 32001 if test "x$OPENJDK_TARGET_OS" != "xmacosx"; then 32002 as_fn_error $? "--enable-static-build is only supported for macosx builds" "$LINENO" 5 32003 fi 32004 STATIC_BUILD_CFLAGS="-DSTATIC_BUILD=1" 32005 CFLAGS_JDKLIB_EXTRA="$CFLAGS_JDKLIB_EXTRA $STATIC_BUILD_CFLAGS" 32006 CXXFLAGS_JDKLIB_EXTRA="$CXXFLAGS_JDKLIB_EXTRA $STATIC_BUILD_CFLAGS" 32007 STATIC_BUILD=true 32008 elif test "x$enable_static_build" = "xno"; then 32009 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if static build is enabled" >&5 32010 $as_echo_n "checking if static build is enabled... " >&6; } 32011 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 32012 $as_echo "no" >&6; } 32013 elif test "x$enable_static_build" != "x"; then 32014 as_fn_error $? "--enable-static-build can only be assigned \"yes\" or \"no\"" "$LINENO" 5 32015 fi 32016 32017 32018 32019 32020 # First determine the toolchain type (compiler family) 32021 32022 32023 # Check whether --with-toolchain-type was given. 32024 if test "${with_toolchain_type+set}" = set; then : 32025 withval=$with_toolchain_type; 32026 fi 32027 32028 32029 # Use indirect variable referencing 32030 toolchain_var_name=VALID_TOOLCHAINS_$OPENJDK_BUILD_OS 32031 VALID_TOOLCHAINS=${!toolchain_var_name} 32032 32033 if test "x$OPENJDK_TARGET_OS" = xmacosx; then 32034 if test -n "$XCODEBUILD"; then 32035 # On Mac OS X, default toolchain to clang after Xcode 5 32036 XCODE_VERSION_OUTPUT=`"$XCODEBUILD" -version 2>&1 | $HEAD -n 1` 32037 $ECHO "$XCODE_VERSION_OUTPUT" | $GREP "Xcode " > /dev/null 32038 if test $? -ne 0; then 32039 as_fn_error $? "Failed to determine Xcode version." "$LINENO" 5 32040 fi 32041 XCODE_MAJOR_VERSION=`$ECHO $XCODE_VERSION_OUTPUT | \ 32042 $SED -e 's/^Xcode \([1-9][0-9.]*\)/\1/' | \ 32043 $CUT -f 1 -d .` 32044 { $as_echo "$as_me:${as_lineno-$LINENO}: Xcode major version: $XCODE_MAJOR_VERSION" >&5 32045 $as_echo "$as_me: Xcode major version: $XCODE_MAJOR_VERSION" >&6;} 32046 if test $XCODE_MAJOR_VERSION -ge 5; then 32047 DEFAULT_TOOLCHAIN="clang" 32048 else 32049 DEFAULT_TOOLCHAIN="gcc" 32050 fi 32051 else 32052 # If Xcode is not installed, but the command line tools are 32053 # then we can't run xcodebuild. On these systems we should 32054 # default to clang 32055 DEFAULT_TOOLCHAIN="clang" 32056 fi 32057 else 32058 # First toolchain type in the list is the default 32059 DEFAULT_TOOLCHAIN=${VALID_TOOLCHAINS%% *} 32060 fi 32061 32062 if test "x$with_toolchain_type" = xlist; then 32063 # List all toolchains 32064 { $as_echo "$as_me:${as_lineno-$LINENO}: The following toolchains are valid on this platform:" >&5 32065 $as_echo "$as_me: The following toolchains are valid on this platform:" >&6;} 32066 for toolchain in $VALID_TOOLCHAINS; do 32067 toolchain_var_name=TOOLCHAIN_DESCRIPTION_$toolchain 32068 TOOLCHAIN_DESCRIPTION=${!toolchain_var_name} 32069 $PRINTF " %-10s %s\n" $toolchain "$TOOLCHAIN_DESCRIPTION" 32070 done 32071 32072 exit 0 32073 elif test "x$with_toolchain_type" != x; then 32074 # User override; check that it is valid 32075 if test "x${VALID_TOOLCHAINS/$with_toolchain_type/}" = "x${VALID_TOOLCHAINS}"; then 32076 { $as_echo "$as_me:${as_lineno-$LINENO}: Toolchain type $with_toolchain_type is not valid on this platform." >&5 32077 $as_echo "$as_me: Toolchain type $with_toolchain_type is not valid on this platform." >&6;} 32078 { $as_echo "$as_me:${as_lineno-$LINENO}: Valid toolchains: $VALID_TOOLCHAINS." >&5 32079 $as_echo "$as_me: Valid toolchains: $VALID_TOOLCHAINS." >&6;} 32080 as_fn_error $? "Cannot continue." "$LINENO" 5 32081 fi 32082 TOOLCHAIN_TYPE=$with_toolchain_type 32083 else 32084 # No flag given, use default 32085 TOOLCHAIN_TYPE=$DEFAULT_TOOLCHAIN 32086 fi 32087 32088 32089 TOOLCHAIN_CC_BINARY_clang="clang" 32090 TOOLCHAIN_CC_BINARY_gcc="gcc" 32091 TOOLCHAIN_CC_BINARY_microsoft="cl" 32092 TOOLCHAIN_CC_BINARY_solstudio="cc" 32093 TOOLCHAIN_CC_BINARY_xlc="xlc_r" 32094 32095 TOOLCHAIN_CXX_BINARY_clang="clang++" 32096 TOOLCHAIN_CXX_BINARY_gcc="g++" 32097 TOOLCHAIN_CXX_BINARY_microsoft="cl" 32098 TOOLCHAIN_CXX_BINARY_solstudio="CC" 32099 TOOLCHAIN_CXX_BINARY_xlc="xlC_r" 32100 32101 # Use indirect variable referencing 32102 toolchain_var_name=TOOLCHAIN_DESCRIPTION_$TOOLCHAIN_TYPE 32103 TOOLCHAIN_DESCRIPTION=${!toolchain_var_name} 32104 toolchain_var_name=TOOLCHAIN_MINIMUM_VERSION_$TOOLCHAIN_TYPE 32105 TOOLCHAIN_MINIMUM_VERSION=${!toolchain_var_name} 32106 toolchain_var_name=TOOLCHAIN_CC_BINARY_$TOOLCHAIN_TYPE 32107 TOOLCHAIN_CC_BINARY=${!toolchain_var_name} 32108 toolchain_var_name=TOOLCHAIN_CXX_BINARY_$TOOLCHAIN_TYPE 32109 TOOLCHAIN_CXX_BINARY=${!toolchain_var_name} 32110 32111 32112 # Define filename patterns 32113 if test "x$OPENJDK_TARGET_OS" = xwindows; then 32114 LIBRARY_PREFIX= 32115 SHARED_LIBRARY_SUFFIX='.dll' 32116 STATIC_LIBRARY_SUFFIX='.lib' 32117 SHARED_LIBRARY='$1.dll' 32118 STATIC_LIBRARY='$1.lib' 32119 OBJ_SUFFIX='.obj' 32120 EXE_SUFFIX='.exe' 32121 else 32122 LIBRARY_PREFIX=lib 32123 SHARED_LIBRARY_SUFFIX='.so' 32124 STATIC_LIBRARY_SUFFIX='.a' 32125 SHARED_LIBRARY='lib$1.so' 32126 STATIC_LIBRARY='lib$1.a' 32127 OBJ_SUFFIX='.o' 32128 EXE_SUFFIX='' 32129 if test "x$OPENJDK_TARGET_OS" = xmacosx; then 32130 # For full static builds, we're overloading the SHARED_LIBRARY 32131 # variables in order to limit the amount of changes required. 32132 # It would be better to remove SHARED and just use LIBRARY and 32133 # LIBRARY_SUFFIX for libraries that can be built either 32134 # shared or static and use STATIC_* for libraries that are 32135 # always built statically. 32136 if test "x$STATIC_BUILD" = xtrue; then 32137 SHARED_LIBRARY='lib$1.a' 32138 SHARED_LIBRARY_SUFFIX='.a' 32139 else 32140 SHARED_LIBRARY='lib$1.dylib' 32141 SHARED_LIBRARY_SUFFIX='.dylib' 32142 fi 32143 fi 32144 fi 32145 32146 32147 32148 32149 32150 32151 32152 32153 32154 32155 if test "x$TOOLCHAIN_TYPE" = "x$DEFAULT_TOOLCHAIN"; then 32156 { $as_echo "$as_me:${as_lineno-$LINENO}: Using default toolchain $TOOLCHAIN_TYPE ($TOOLCHAIN_DESCRIPTION)" >&5 32157 $as_echo "$as_me: Using default toolchain $TOOLCHAIN_TYPE ($TOOLCHAIN_DESCRIPTION)" >&6;} 32158 else 32159 { $as_echo "$as_me:${as_lineno-$LINENO}: Using user selected toolchain $TOOLCHAIN_TYPE ($TOOLCHAIN_DESCRIPTION). Default toolchain is $DEFAULT_TOOLCHAIN." >&5 32160 $as_echo "$as_me: Using user selected toolchain $TOOLCHAIN_TYPE ($TOOLCHAIN_DESCRIPTION). Default toolchain is $DEFAULT_TOOLCHAIN." >&6;} 32161 fi 32162 32163 32164 # User supplied flags should be used when configure detects compilers 32165 32166 if test "x$CFLAGS" != "x${ADDED_CFLAGS}"; then 32167 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring CFLAGS($CFLAGS) found in environment. Use --with-extra-cflags" >&5 32168 $as_echo "$as_me: WARNING: Ignoring CFLAGS($CFLAGS) found in environment. Use --with-extra-cflags" >&2;} 32169 fi 32170 32171 if test "x$CXXFLAGS" != "x${ADDED_CXXFLAGS}"; then 32172 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring CXXFLAGS($CXXFLAGS) found in environment. Use --with-extra-cxxflags" >&5 32173 $as_echo "$as_me: WARNING: Ignoring CXXFLAGS($CXXFLAGS) found in environment. Use --with-extra-cxxflags" >&2;} 32174 fi 32175 32176 if test "x$LDFLAGS" != "x${ADDED_LDFLAGS}"; then 32177 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring LDFLAGS($LDFLAGS) found in environment. Use --with-extra-ldflags" >&5 32178 $as_echo "$as_me: WARNING: Ignoring LDFLAGS($LDFLAGS) found in environment. Use --with-extra-ldflags" >&2;} 32179 fi 32180 32181 32182 # Check whether --with-extra-cflags was given. 32183 if test "${with_extra_cflags+set}" = set; then : 32184 withval=$with_extra_cflags; 32185 fi 32186 32187 32188 32189 # Check whether --with-extra-cxxflags was given. 32190 if test "${with_extra_cxxflags+set}" = set; then : 32191 withval=$with_extra_cxxflags; 32192 fi 32193 32194 32195 32196 # Check whether --with-extra-ldflags was given. 32197 if test "${with_extra_ldflags+set}" = set; then : 32198 withval=$with_extra_ldflags; 32199 fi 32200 32201 32202 EXTRA_CFLAGS="$with_extra_cflags" 32203 EXTRA_CXXFLAGS="$with_extra_cxxflags" 32204 EXTRA_LDFLAGS="$with_extra_ldflags" 32205 32206 32207 32208 32209 32210 # The global CFLAGS and LDLAGS variables are used by configure tests and 32211 # should include the extra parameters 32212 CFLAGS="$EXTRA_CFLAGS" 32213 CXXFLAGS="$EXTRA_CXXFLAGS" 32214 LDFLAGS="$EXTRA_LDFLAGS" 32215 CPPFLAGS="" 32216 32217 # The sysroot cflags are needed for configure to be able to run the compilers 32218 32219 if test "x$SYSROOT" != "x"; then 32220 if test "x$TOOLCHAIN_TYPE" = xsolstudio; then 32221 if test "x$OPENJDK_TARGET_OS" = xsolaris; then 32222 # Solaris Studio does not have a concept of sysroot. Instead we must 32223 # make sure the default include and lib dirs are appended to each 32224 # compile and link command line. Must also add -I-xbuiltin to enable 32225 # inlining of system functions and intrinsics. 32226 SYSROOT_CFLAGS="-I-xbuiltin -I$SYSROOT/usr/include" 32227 SYSROOT_LDFLAGS="-L$SYSROOT/usr/lib$OPENJDK_TARGET_CPU_ISADIR \ 32228 -L$SYSROOT/lib$OPENJDK_TARGET_CPU_ISADIR" 32229 fi 32230 elif test "x$TOOLCHAIN_TYPE" = xgcc; then 32231 SYSROOT_CFLAGS="--sysroot=$SYSROOT" 32232 SYSROOT_LDFLAGS="--sysroot=$SYSROOT" 32233 elif test "x$TOOLCHAIN_TYPE" = xclang; then 32234 SYSROOT_CFLAGS="-isysroot $SYSROOT" 32235 SYSROOT_LDFLAGS="-isysroot $SYSROOT" 32236 fi 32237 # The global CFLAGS and LDFLAGS variables need these for configure to function 32238 CFLAGS="$CFLAGS $SYSROOT_CFLAGS" 32239 CPPFLAGS="$CPPFLAGS $SYSROOT_CFLAGS" 32240 CXXFLAGS="$CXXFLAGS $SYSROOT_CFLAGS" 32241 LDFLAGS="$LDFLAGS $SYSROOT_LDFLAGS" 32242 fi 32243 32244 if test "x$OPENJDK_TARGET_OS" = xmacosx; then 32245 # We also need -iframework<path>/System/Library/Frameworks 32246 SYSROOT_CFLAGS="$SYSROOT_CFLAGS -iframework $SYSROOT/System/Library/Frameworks" 32247 SYSROOT_LDFLAGS="$SYSROOT_LDFLAGS -iframework $SYSROOT/System/Library/Frameworks" 32248 # These always need to be set, or we can't find the frameworks embedded in JavaVM.framework 32249 # set this here so it doesn't have to be peppered throughout the forest 32250 SYSROOT_CFLAGS="$SYSROOT_CFLAGS -F $SYSROOT/System/Library/Frameworks/JavaVM.framework/Frameworks" 32251 SYSROOT_LDFLAGS="$SYSROOT_LDFLAGS -F $SYSROOT/System/Library/Frameworks/JavaVM.framework/Frameworks" 32252 fi 32253 32254 32255 32256 32257 32258 # Then detect the actual binaries needed 32259 32260 # FIXME: Is this needed? 32261 ac_ext=cpp 32262 ac_cpp='$CXXCPP $CPPFLAGS' 32263 ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5' 32264 ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' 32265 ac_compiler_gnu=$ac_cv_cxx_compiler_gnu 32266 32267 32268 # Store the CFLAGS etc passed to the configure script. 32269 ORG_CFLAGS="$CFLAGS" 32270 ORG_CXXFLAGS="$CXXFLAGS" 32271 32272 # autoconf magic only relies on PATH, so update it if tools dir is specified 32273 OLD_PATH="$PATH" 32274 32275 # On Windows, we need to detect the visual studio installation first. 32276 # This will change the PATH, but we need to keep that new PATH even 32277 # after toolchain detection is done, since the compiler (on x86) uses 32278 # it for DLL resolution in runtime. 32279 if test "x$OPENJDK_BUILD_OS" = "xwindows" \ 32280 && test "x$TOOLCHAIN_TYPE" = "xmicrosoft"; then 32281 32282 # Store path to cygwin link.exe to help excluding it when searching for 32283 # VS linker. This must be done before changing the PATH when looking for VS. 32284 # Extract the first word of "link", so it can be a program name with args. 32285 set dummy link; ac_word=$2 32286 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 32287 $as_echo_n "checking for $ac_word... " >&6; } 32288 if ${ac_cv_path_CYGWIN_LINK+:} false; then : 32289 $as_echo_n "(cached) " >&6 32290 else 32291 case $CYGWIN_LINK in 32292 [\\/]* | ?:[\\/]*) 32293 ac_cv_path_CYGWIN_LINK="$CYGWIN_LINK" # Let the user override the test with a path. 32294 ;; 32295 *) 32296 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 32297 for as_dir in $PATH 32298 do 32299 IFS=$as_save_IFS 32300 test -z "$as_dir" && as_dir=. 32301 for ac_exec_ext in '' $ac_executable_extensions; do 32302 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 32303 ac_cv_path_CYGWIN_LINK="$as_dir/$ac_word$ac_exec_ext" 32304 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 32305 break 2 32306 fi 32307 done 32308 done 32309 IFS=$as_save_IFS 32310 32311 ;; 32312 esac 32313 fi 32314 CYGWIN_LINK=$ac_cv_path_CYGWIN_LINK 32315 if test -n "$CYGWIN_LINK"; then 32316 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CYGWIN_LINK" >&5 32317 $as_echo "$CYGWIN_LINK" >&6; } 32318 else 32319 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 32320 $as_echo "no" >&6; } 32321 fi 32322 32323 32324 if test "x$CYGWIN_LINK" != x; then 32325 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if the first found link.exe is actually the Cygwin link tool" >&5 32326 $as_echo_n "checking if the first found link.exe is actually the Cygwin link tool... " >&6; } 32327 "$CYGWIN_LINK" --version > /dev/null 32328 if test $? -eq 0 ; then 32329 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 32330 $as_echo "yes" >&6; } 32331 else 32332 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 32333 $as_echo "no" >&6; } 32334 # This might be the VS linker. Don't exclude it later on. 32335 CYGWIN_LINK="" 32336 fi 32337 fi 32338 32339 # First-hand choice is to locate and run the vsvars bat file. 32340 32341 32342 # Check whether --with-toolchain-version was given. 32343 if test "${with_toolchain_version+set}" = set; then : 32344 withval=$with_toolchain_version; 32345 fi 32346 32347 32348 if test "x$with_toolchain_version" = xlist; then 32349 # List all toolchains 32350 { $as_echo "$as_me:${as_lineno-$LINENO}: The following toolchain versions are valid on this platform:" >&5 32351 $as_echo "$as_me: The following toolchain versions are valid on this platform:" >&6;} 32352 for version in $VALID_VS_VERSIONS; do 32353 eval VS_DESCRIPTION=\${VS_DESCRIPTION_$version} 32354 $PRINTF " %-10s %s\n" $version "$VS_DESCRIPTION" 32355 done 32356 32357 exit 0 32358 elif test "x$DEVKIT_VS_VERSION" != x; then 32359 VS_VERSION=$DEVKIT_VS_VERSION 32360 TOOLCHAIN_VERSION=$VS_VERSION 32361 eval VS_DESCRIPTION="\${VS_DESCRIPTION_${VS_VERSION}}" 32362 eval VS_VERSION_INTERNAL="\${VS_VERSION_INTERNAL_${VS_VERSION}}" 32363 eval MSVCR_NAME="\${VS_MSVCR_${VS_VERSION}}" 32364 eval MSVCP_NAME="\${VS_MSVCP_${VS_VERSION}}" 32365 eval PLATFORM_TOOLSET="\${VS_VS_PLATFORM_NAME_${VS_VERSION}}" 32366 VS_PATH="$TOOLCHAIN_PATH:$PATH" 32367 32368 # Convert DEVKIT_VS_INCLUDE into windows style VS_INCLUDE so that it 32369 # can still be exported as INCLUDE for compiler invocations without 32370 # SYSROOT_CFLAGS 32371 OLDIFS="$IFS" 32372 IFS=";" 32373 for i in $DEVKIT_VS_INCLUDE; do 32374 ipath=$i 32375 32376 unix_path="$ipath" 32377 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 32378 windows_path=`$CYGPATH -m "$unix_path"` 32379 ipath="$windows_path" 32380 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 32381 windows_path=`cmd //c echo $unix_path` 32382 ipath="$windows_path" 32383 fi 32384 32385 VS_INCLUDE="$VS_INCLUDE;$ipath" 32386 done 32387 # Convert DEVKIT_VS_LIB into VS_LIB so that it can still be exported 32388 # as LIB for compiler invocations without SYSROOT_LDFLAGS 32389 for i in $DEVKIT_VS_LIB; do 32390 libpath=$i 32391 32392 unix_path="$libpath" 32393 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 32394 windows_path=`$CYGPATH -m "$unix_path"` 32395 libpath="$windows_path" 32396 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 32397 windows_path=`cmd //c echo $unix_path` 32398 libpath="$windows_path" 32399 fi 32400 32401 VS_LIB="$VS_LIB;$libpath" 32402 done 32403 IFS="$OLDIFS" 32404 32405 { $as_echo "$as_me:${as_lineno-$LINENO}: Found devkit $VS_DESCRIPTION" >&5 32406 $as_echo "$as_me: Found devkit $VS_DESCRIPTION" >&6;} 32407 32408 elif test "x$with_toolchain_version" != x; then 32409 # User override; check that it is valid 32410 if test "x${VALID_VS_VERSIONS/$with_toolchain_version/}" = "x${VALID_VS_VERSIONS}"; then 32411 { $as_echo "$as_me:${as_lineno-$LINENO}: Visual Studio version $with_toolchain_version is not valid." >&5 32412 $as_echo "$as_me: Visual Studio version $with_toolchain_version is not valid." >&6;} 32413 { $as_echo "$as_me:${as_lineno-$LINENO}: Valid Visual Studio versions: $VALID_VS_VERSIONS." >&5 32414 $as_echo "$as_me: Valid Visual Studio versions: $VALID_VS_VERSIONS." >&6;} 32415 as_fn_error $? "Cannot continue." "$LINENO" 5 32416 fi 32417 VS_VERSIONS_PROBE_LIST="$with_toolchain_version" 32418 else 32419 # No flag given, use default 32420 VS_VERSIONS_PROBE_LIST="$VALID_VS_VERSIONS" 32421 fi 32422 32423 for VS_VERSION in $VS_VERSIONS_PROBE_LIST; do 32424 32425 VS_VERSION="$VS_VERSION" 32426 eval VS_COMNTOOLS_VAR="\${VS_ENVVAR_${VS_VERSION}}" 32427 eval VS_COMNTOOLS="\$${VS_COMNTOOLS_VAR}" 32428 eval VS_INSTALL_DIR="\${VS_VS_INSTALLDIR_${VS_VERSION}}" 32429 eval SDK_INSTALL_DIR="\${VS_SDK_INSTALLDIR_${VS_VERSION}}" 32430 32431 # When using --with-tools-dir, assume it points to the correct and default 32432 # version of Visual Studio or that --with-toolchain-version was also set. 32433 if test "x$with_tools_dir" != x; then 32434 32435 if test "x$VS_ENV_CMD" = x; then 32436 VS_VERSION="${VS_VERSION}" 32437 VS_BASE="$with_tools_dir/../.." 32438 METHOD="--with-tools-dir" 32439 32440 if test "x$OPENJDK_TARGET_CPU_BITS" = x32; then 32441 VCVARSFILE="vc/bin/vcvars32.bat" 32442 else 32443 VCVARSFILE="vc/bin/amd64/vcvars64.bat" 32444 fi 32445 32446 32447 windows_path="$VS_BASE" 32448 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 32449 unix_path=`$CYGPATH -u "$windows_path"` 32450 VS_BASE="$unix_path" 32451 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 32452 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 32453 VS_BASE="$unix_path" 32454 fi 32455 32456 if test -d "$VS_BASE"; then 32457 if test -f "$VS_BASE/$VCVARSFILE"; then 32458 { $as_echo "$as_me:${as_lineno-$LINENO}: Found Visual Studio installation at $VS_BASE using $METHOD" >&5 32459 $as_echo "$as_me: Found Visual Studio installation at $VS_BASE using $METHOD" >&6;} 32460 VS_ENV_CMD="$VS_BASE/$VCVARSFILE" 32461 # PLATFORM_TOOLSET is used during the compilation of the freetype sources (see 32462 # 'LIB_BUILD_FREETYPE' in libraries.m4) and must be one of 'v100', 'v110' or 'v120' for VS 2010, 2012 or VS2013 32463 eval PLATFORM_TOOLSET="\${VS_VS_PLATFORM_NAME_${VS_VERSION}}" 32464 else 32465 { $as_echo "$as_me:${as_lineno-$LINENO}: Found Visual Studio installation at $VS_BASE using $METHOD" >&5 32466 $as_echo "$as_me: Found Visual Studio installation at $VS_BASE using $METHOD" >&6;} 32467 { $as_echo "$as_me:${as_lineno-$LINENO}: Warning: $VCVARSFILE is missing, this is probably Visual Studio Express. Ignoring" >&5 32468 $as_echo "$as_me: Warning: $VCVARSFILE is missing, this is probably Visual Studio Express. Ignoring" >&6;} 32469 fi 32470 fi 32471 fi 32472 32473 32474 if test "x$VS_ENV_CMD" = x; then 32475 VS_VERSION="${VS_VERSION}" 32476 VS_BASE="$with_tools_dir/../../.." 32477 METHOD="--with-tools-dir" 32478 32479 if test "x$OPENJDK_TARGET_CPU_BITS" = x32; then 32480 VCVARSFILE="vc/bin/vcvars32.bat" 32481 else 32482 VCVARSFILE="vc/bin/amd64/vcvars64.bat" 32483 fi 32484 32485 32486 windows_path="$VS_BASE" 32487 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 32488 unix_path=`$CYGPATH -u "$windows_path"` 32489 VS_BASE="$unix_path" 32490 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 32491 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 32492 VS_BASE="$unix_path" 32493 fi 32494 32495 if test -d "$VS_BASE"; then 32496 if test -f "$VS_BASE/$VCVARSFILE"; then 32497 { $as_echo "$as_me:${as_lineno-$LINENO}: Found Visual Studio installation at $VS_BASE using $METHOD" >&5 32498 $as_echo "$as_me: Found Visual Studio installation at $VS_BASE using $METHOD" >&6;} 32499 VS_ENV_CMD="$VS_BASE/$VCVARSFILE" 32500 # PLATFORM_TOOLSET is used during the compilation of the freetype sources (see 32501 # 'LIB_BUILD_FREETYPE' in libraries.m4) and must be one of 'v100', 'v110' or 'v120' for VS 2010, 2012 or VS2013 32502 eval PLATFORM_TOOLSET="\${VS_VS_PLATFORM_NAME_${VS_VERSION}}" 32503 else 32504 { $as_echo "$as_me:${as_lineno-$LINENO}: Found Visual Studio installation at $VS_BASE using $METHOD" >&5 32505 $as_echo "$as_me: Found Visual Studio installation at $VS_BASE using $METHOD" >&6;} 32506 { $as_echo "$as_me:${as_lineno-$LINENO}: Warning: $VCVARSFILE is missing, this is probably Visual Studio Express. Ignoring" >&5 32507 $as_echo "$as_me: Warning: $VCVARSFILE is missing, this is probably Visual Studio Express. Ignoring" >&6;} 32508 fi 32509 fi 32510 fi 32511 32512 if test "x$VS_ENV_CMD" = x; then 32513 # Having specified an argument which is incorrect will produce an instant failure; 32514 # we should not go on looking 32515 { $as_echo "$as_me:${as_lineno-$LINENO}: The path given by --with-tools-dir does not contain a valid" >&5 32516 $as_echo "$as_me: The path given by --with-tools-dir does not contain a valid" >&6;} 32517 { $as_echo "$as_me:${as_lineno-$LINENO}: Visual Studio installation. Please point to the VC/bin or VC/bin/amd64" >&5 32518 $as_echo "$as_me: Visual Studio installation. Please point to the VC/bin or VC/bin/amd64" >&6;} 32519 { $as_echo "$as_me:${as_lineno-$LINENO}: directory within the Visual Studio installation" >&5 32520 $as_echo "$as_me: directory within the Visual Studio installation" >&6;} 32521 as_fn_error $? "Cannot locate a valid Visual Studio installation" "$LINENO" 5 32522 fi 32523 fi 32524 32525 VS_ENV_CMD="" 32526 VS_ENV_ARGS="" 32527 32528 if test "x$VS_COMNTOOLS" != x; then 32529 32530 if test "x$VS_ENV_CMD" = x; then 32531 VS_VERSION="${VS_VERSION}" 32532 VS_BASE="$VS_COMNTOOLS/../.." 32533 METHOD="$VS_COMNTOOLS_VAR variable" 32534 32535 if test "x$OPENJDK_TARGET_CPU_BITS" = x32; then 32536 VCVARSFILE="vc/bin/vcvars32.bat" 32537 else 32538 VCVARSFILE="vc/bin/amd64/vcvars64.bat" 32539 fi 32540 32541 32542 windows_path="$VS_BASE" 32543 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 32544 unix_path=`$CYGPATH -u "$windows_path"` 32545 VS_BASE="$unix_path" 32546 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 32547 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 32548 VS_BASE="$unix_path" 32549 fi 32550 32551 if test -d "$VS_BASE"; then 32552 if test -f "$VS_BASE/$VCVARSFILE"; then 32553 { $as_echo "$as_me:${as_lineno-$LINENO}: Found Visual Studio installation at $VS_BASE using $METHOD" >&5 32554 $as_echo "$as_me: Found Visual Studio installation at $VS_BASE using $METHOD" >&6;} 32555 VS_ENV_CMD="$VS_BASE/$VCVARSFILE" 32556 # PLATFORM_TOOLSET is used during the compilation of the freetype sources (see 32557 # 'LIB_BUILD_FREETYPE' in libraries.m4) and must be one of 'v100', 'v110' or 'v120' for VS 2010, 2012 or VS2013 32558 eval PLATFORM_TOOLSET="\${VS_VS_PLATFORM_NAME_${VS_VERSION}}" 32559 else 32560 { $as_echo "$as_me:${as_lineno-$LINENO}: Found Visual Studio installation at $VS_BASE using $METHOD" >&5 32561 $as_echo "$as_me: Found Visual Studio installation at $VS_BASE using $METHOD" >&6;} 32562 { $as_echo "$as_me:${as_lineno-$LINENO}: Warning: $VCVARSFILE is missing, this is probably Visual Studio Express. Ignoring" >&5 32563 $as_echo "$as_me: Warning: $VCVARSFILE is missing, this is probably Visual Studio Express. Ignoring" >&6;} 32564 fi 32565 fi 32566 fi 32567 32568 fi 32569 if test "x$PROGRAMFILES" != x; then 32570 32571 if test "x$VS_ENV_CMD" = x; then 32572 VS_VERSION="${VS_VERSION}" 32573 VS_BASE="$PROGRAMFILES/$VS_INSTALL_DIR" 32574 METHOD="well-known name" 32575 32576 if test "x$OPENJDK_TARGET_CPU_BITS" = x32; then 32577 VCVARSFILE="vc/bin/vcvars32.bat" 32578 else 32579 VCVARSFILE="vc/bin/amd64/vcvars64.bat" 32580 fi 32581 32582 32583 windows_path="$VS_BASE" 32584 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 32585 unix_path=`$CYGPATH -u "$windows_path"` 32586 VS_BASE="$unix_path" 32587 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 32588 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 32589 VS_BASE="$unix_path" 32590 fi 32591 32592 if test -d "$VS_BASE"; then 32593 if test -f "$VS_BASE/$VCVARSFILE"; then 32594 { $as_echo "$as_me:${as_lineno-$LINENO}: Found Visual Studio installation at $VS_BASE using $METHOD" >&5 32595 $as_echo "$as_me: Found Visual Studio installation at $VS_BASE using $METHOD" >&6;} 32596 VS_ENV_CMD="$VS_BASE/$VCVARSFILE" 32597 # PLATFORM_TOOLSET is used during the compilation of the freetype sources (see 32598 # 'LIB_BUILD_FREETYPE' in libraries.m4) and must be one of 'v100', 'v110' or 'v120' for VS 2010, 2012 or VS2013 32599 eval PLATFORM_TOOLSET="\${VS_VS_PLATFORM_NAME_${VS_VERSION}}" 32600 else 32601 { $as_echo "$as_me:${as_lineno-$LINENO}: Found Visual Studio installation at $VS_BASE using $METHOD" >&5 32602 $as_echo "$as_me: Found Visual Studio installation at $VS_BASE using $METHOD" >&6;} 32603 { $as_echo "$as_me:${as_lineno-$LINENO}: Warning: $VCVARSFILE is missing, this is probably Visual Studio Express. Ignoring" >&5 32604 $as_echo "$as_me: Warning: $VCVARSFILE is missing, this is probably Visual Studio Express. Ignoring" >&6;} 32605 fi 32606 fi 32607 fi 32608 32609 fi 32610 # Work around the insanely named ProgramFiles(x86) env variable 32611 PROGRAMFILES_X86="`env | $SED -n 's/^ProgramFiles(x86)=//p'`" 32612 if test "x$PROGRAMFILES_X86" != x; then 32613 32614 if test "x$VS_ENV_CMD" = x; then 32615 VS_VERSION="${VS_VERSION}" 32616 VS_BASE="$PROGRAMFILES_X86/$VS_INSTALL_DIR" 32617 METHOD="well-known name" 32618 32619 if test "x$OPENJDK_TARGET_CPU_BITS" = x32; then 32620 VCVARSFILE="vc/bin/vcvars32.bat" 32621 else 32622 VCVARSFILE="vc/bin/amd64/vcvars64.bat" 32623 fi 32624 32625 32626 windows_path="$VS_BASE" 32627 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 32628 unix_path=`$CYGPATH -u "$windows_path"` 32629 VS_BASE="$unix_path" 32630 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 32631 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 32632 VS_BASE="$unix_path" 32633 fi 32634 32635 if test -d "$VS_BASE"; then 32636 if test -f "$VS_BASE/$VCVARSFILE"; then 32637 { $as_echo "$as_me:${as_lineno-$LINENO}: Found Visual Studio installation at $VS_BASE using $METHOD" >&5 32638 $as_echo "$as_me: Found Visual Studio installation at $VS_BASE using $METHOD" >&6;} 32639 VS_ENV_CMD="$VS_BASE/$VCVARSFILE" 32640 # PLATFORM_TOOLSET is used during the compilation of the freetype sources (see 32641 # 'LIB_BUILD_FREETYPE' in libraries.m4) and must be one of 'v100', 'v110' or 'v120' for VS 2010, 2012 or VS2013 32642 eval PLATFORM_TOOLSET="\${VS_VS_PLATFORM_NAME_${VS_VERSION}}" 32643 else 32644 { $as_echo "$as_me:${as_lineno-$LINENO}: Found Visual Studio installation at $VS_BASE using $METHOD" >&5 32645 $as_echo "$as_me: Found Visual Studio installation at $VS_BASE using $METHOD" >&6;} 32646 { $as_echo "$as_me:${as_lineno-$LINENO}: Warning: $VCVARSFILE is missing, this is probably Visual Studio Express. Ignoring" >&5 32647 $as_echo "$as_me: Warning: $VCVARSFILE is missing, this is probably Visual Studio Express. Ignoring" >&6;} 32648 fi 32649 fi 32650 fi 32651 32652 fi 32653 32654 if test "x$VS_ENV_CMD" = x; then 32655 VS_VERSION="${VS_VERSION}" 32656 VS_BASE="C:/Program Files/$VS_INSTALL_DIR" 32657 METHOD="well-known name" 32658 32659 if test "x$OPENJDK_TARGET_CPU_BITS" = x32; then 32660 VCVARSFILE="vc/bin/vcvars32.bat" 32661 else 32662 VCVARSFILE="vc/bin/amd64/vcvars64.bat" 32663 fi 32664 32665 32666 windows_path="$VS_BASE" 32667 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 32668 unix_path=`$CYGPATH -u "$windows_path"` 32669 VS_BASE="$unix_path" 32670 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 32671 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 32672 VS_BASE="$unix_path" 32673 fi 32674 32675 if test -d "$VS_BASE"; then 32676 if test -f "$VS_BASE/$VCVARSFILE"; then 32677 { $as_echo "$as_me:${as_lineno-$LINENO}: Found Visual Studio installation at $VS_BASE using $METHOD" >&5 32678 $as_echo "$as_me: Found Visual Studio installation at $VS_BASE using $METHOD" >&6;} 32679 VS_ENV_CMD="$VS_BASE/$VCVARSFILE" 32680 # PLATFORM_TOOLSET is used during the compilation of the freetype sources (see 32681 # 'LIB_BUILD_FREETYPE' in libraries.m4) and must be one of 'v100', 'v110' or 'v120' for VS 2010, 2012 or VS2013 32682 eval PLATFORM_TOOLSET="\${VS_VS_PLATFORM_NAME_${VS_VERSION}}" 32683 else 32684 { $as_echo "$as_me:${as_lineno-$LINENO}: Found Visual Studio installation at $VS_BASE using $METHOD" >&5 32685 $as_echo "$as_me: Found Visual Studio installation at $VS_BASE using $METHOD" >&6;} 32686 { $as_echo "$as_me:${as_lineno-$LINENO}: Warning: $VCVARSFILE is missing, this is probably Visual Studio Express. Ignoring" >&5 32687 $as_echo "$as_me: Warning: $VCVARSFILE is missing, this is probably Visual Studio Express. Ignoring" >&6;} 32688 fi 32689 fi 32690 fi 32691 32692 32693 if test "x$VS_ENV_CMD" = x; then 32694 VS_VERSION="${VS_VERSION}" 32695 VS_BASE="C:/Program Files (x86)/$VS_INSTALL_DIR" 32696 METHOD="well-known name" 32697 32698 if test "x$OPENJDK_TARGET_CPU_BITS" = x32; then 32699 VCVARSFILE="vc/bin/vcvars32.bat" 32700 else 32701 VCVARSFILE="vc/bin/amd64/vcvars64.bat" 32702 fi 32703 32704 32705 windows_path="$VS_BASE" 32706 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 32707 unix_path=`$CYGPATH -u "$windows_path"` 32708 VS_BASE="$unix_path" 32709 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 32710 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 32711 VS_BASE="$unix_path" 32712 fi 32713 32714 if test -d "$VS_BASE"; then 32715 if test -f "$VS_BASE/$VCVARSFILE"; then 32716 { $as_echo "$as_me:${as_lineno-$LINENO}: Found Visual Studio installation at $VS_BASE using $METHOD" >&5 32717 $as_echo "$as_me: Found Visual Studio installation at $VS_BASE using $METHOD" >&6;} 32718 VS_ENV_CMD="$VS_BASE/$VCVARSFILE" 32719 # PLATFORM_TOOLSET is used during the compilation of the freetype sources (see 32720 # 'LIB_BUILD_FREETYPE' in libraries.m4) and must be one of 'v100', 'v110' or 'v120' for VS 2010, 2012 or VS2013 32721 eval PLATFORM_TOOLSET="\${VS_VS_PLATFORM_NAME_${VS_VERSION}}" 32722 else 32723 { $as_echo "$as_me:${as_lineno-$LINENO}: Found Visual Studio installation at $VS_BASE using $METHOD" >&5 32724 $as_echo "$as_me: Found Visual Studio installation at $VS_BASE using $METHOD" >&6;} 32725 { $as_echo "$as_me:${as_lineno-$LINENO}: Warning: $VCVARSFILE is missing, this is probably Visual Studio Express. Ignoring" >&5 32726 $as_echo "$as_me: Warning: $VCVARSFILE is missing, this is probably Visual Studio Express. Ignoring" >&6;} 32727 fi 32728 fi 32729 fi 32730 32731 32732 if test "x$SDK_INSTALL_DIR" != x; then 32733 if test "x$ProgramW6432" != x; then 32734 32735 if test "x$VS_ENV_CMD" = x; then 32736 VS_VERSION="${VS_VERSION}" 32737 WIN_SDK_BASE="$ProgramW6432/$SDK_INSTALL_DIR" 32738 METHOD="well-known name" 32739 32740 windows_path="$WIN_SDK_BASE" 32741 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 32742 unix_path=`$CYGPATH -u "$windows_path"` 32743 WIN_SDK_BASE="$unix_path" 32744 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 32745 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 32746 WIN_SDK_BASE="$unix_path" 32747 fi 32748 32749 if test -d "$WIN_SDK_BASE"; then 32750 # There have been cases of partial or broken SDK installations. A missing 32751 # lib dir is not going to work. 32752 if test ! -d "$WIN_SDK_BASE/lib"; then 32753 { $as_echo "$as_me:${as_lineno-$LINENO}: Found Windows SDK installation at $WIN_SDK_BASE using $METHOD" >&5 32754 $as_echo "$as_me: Found Windows SDK installation at $WIN_SDK_BASE using $METHOD" >&6;} 32755 { $as_echo "$as_me:${as_lineno-$LINENO}: Warning: Installation is broken, lib dir is missing. Ignoring" >&5 32756 $as_echo "$as_me: Warning: Installation is broken, lib dir is missing. Ignoring" >&6;} 32757 elif test -f "$WIN_SDK_BASE/Bin/SetEnv.Cmd"; then 32758 { $as_echo "$as_me:${as_lineno-$LINENO}: Found Windows SDK installation at $WIN_SDK_BASE using $METHOD" >&5 32759 $as_echo "$as_me: Found Windows SDK installation at $WIN_SDK_BASE using $METHOD" >&6;} 32760 VS_ENV_CMD="$WIN_SDK_BASE/Bin/SetEnv.Cmd" 32761 if test "x$OPENJDK_TARGET_CPU_BITS" = x32; then 32762 VS_ENV_ARGS="/x86" 32763 else 32764 VS_ENV_ARGS="/x64" 32765 fi 32766 # PLATFORM_TOOLSET is used during the compilation of the freetype sources (see 32767 # 'LIB_BUILD_FREETYPE' in libraries.m4) and must be 'Windows7.1SDK' for Windows7.1SDK 32768 # TODO: improve detection for other versions of SDK 32769 eval PLATFORM_TOOLSET="\${VS_SDK_PLATFORM_NAME_${VS_VERSION}}" 32770 else 32771 { $as_echo "$as_me:${as_lineno-$LINENO}: Found Windows SDK installation at $WIN_SDK_BASE using $METHOD" >&5 32772 $as_echo "$as_me: Found Windows SDK installation at $WIN_SDK_BASE using $METHOD" >&6;} 32773 { $as_echo "$as_me:${as_lineno-$LINENO}: Warning: Installation is broken, SetEnv.Cmd is missing. Ignoring" >&5 32774 $as_echo "$as_me: Warning: Installation is broken, SetEnv.Cmd is missing. Ignoring" >&6;} 32775 fi 32776 fi 32777 fi 32778 32779 fi 32780 if test "x$PROGRAMW6432" != x; then 32781 32782 if test "x$VS_ENV_CMD" = x; then 32783 VS_VERSION="${VS_VERSION}" 32784 WIN_SDK_BASE="$PROGRAMW6432/$SDK_INSTALL_DIR" 32785 METHOD="well-known name" 32786 32787 windows_path="$WIN_SDK_BASE" 32788 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 32789 unix_path=`$CYGPATH -u "$windows_path"` 32790 WIN_SDK_BASE="$unix_path" 32791 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 32792 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 32793 WIN_SDK_BASE="$unix_path" 32794 fi 32795 32796 if test -d "$WIN_SDK_BASE"; then 32797 # There have been cases of partial or broken SDK installations. A missing 32798 # lib dir is not going to work. 32799 if test ! -d "$WIN_SDK_BASE/lib"; then 32800 { $as_echo "$as_me:${as_lineno-$LINENO}: Found Windows SDK installation at $WIN_SDK_BASE using $METHOD" >&5 32801 $as_echo "$as_me: Found Windows SDK installation at $WIN_SDK_BASE using $METHOD" >&6;} 32802 { $as_echo "$as_me:${as_lineno-$LINENO}: Warning: Installation is broken, lib dir is missing. Ignoring" >&5 32803 $as_echo "$as_me: Warning: Installation is broken, lib dir is missing. Ignoring" >&6;} 32804 elif test -f "$WIN_SDK_BASE/Bin/SetEnv.Cmd"; then 32805 { $as_echo "$as_me:${as_lineno-$LINENO}: Found Windows SDK installation at $WIN_SDK_BASE using $METHOD" >&5 32806 $as_echo "$as_me: Found Windows SDK installation at $WIN_SDK_BASE using $METHOD" >&6;} 32807 VS_ENV_CMD="$WIN_SDK_BASE/Bin/SetEnv.Cmd" 32808 if test "x$OPENJDK_TARGET_CPU_BITS" = x32; then 32809 VS_ENV_ARGS="/x86" 32810 else 32811 VS_ENV_ARGS="/x64" 32812 fi 32813 # PLATFORM_TOOLSET is used during the compilation of the freetype sources (see 32814 # 'LIB_BUILD_FREETYPE' in libraries.m4) and must be 'Windows7.1SDK' for Windows7.1SDK 32815 # TODO: improve detection for other versions of SDK 32816 eval PLATFORM_TOOLSET="\${VS_SDK_PLATFORM_NAME_${VS_VERSION}}" 32817 else 32818 { $as_echo "$as_me:${as_lineno-$LINENO}: Found Windows SDK installation at $WIN_SDK_BASE using $METHOD" >&5 32819 $as_echo "$as_me: Found Windows SDK installation at $WIN_SDK_BASE using $METHOD" >&6;} 32820 { $as_echo "$as_me:${as_lineno-$LINENO}: Warning: Installation is broken, SetEnv.Cmd is missing. Ignoring" >&5 32821 $as_echo "$as_me: Warning: Installation is broken, SetEnv.Cmd is missing. Ignoring" >&6;} 32822 fi 32823 fi 32824 fi 32825 32826 fi 32827 if test "x$PROGRAMFILES" != x; then 32828 32829 if test "x$VS_ENV_CMD" = x; then 32830 VS_VERSION="${VS_VERSION}" 32831 WIN_SDK_BASE="$PROGRAMFILES/$SDK_INSTALL_DIR" 32832 METHOD="well-known name" 32833 32834 windows_path="$WIN_SDK_BASE" 32835 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 32836 unix_path=`$CYGPATH -u "$windows_path"` 32837 WIN_SDK_BASE="$unix_path" 32838 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 32839 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 32840 WIN_SDK_BASE="$unix_path" 32841 fi 32842 32843 if test -d "$WIN_SDK_BASE"; then 32844 # There have been cases of partial or broken SDK installations. A missing 32845 # lib dir is not going to work. 32846 if test ! -d "$WIN_SDK_BASE/lib"; then 32847 { $as_echo "$as_me:${as_lineno-$LINENO}: Found Windows SDK installation at $WIN_SDK_BASE using $METHOD" >&5 32848 $as_echo "$as_me: Found Windows SDK installation at $WIN_SDK_BASE using $METHOD" >&6;} 32849 { $as_echo "$as_me:${as_lineno-$LINENO}: Warning: Installation is broken, lib dir is missing. Ignoring" >&5 32850 $as_echo "$as_me: Warning: Installation is broken, lib dir is missing. Ignoring" >&6;} 32851 elif test -f "$WIN_SDK_BASE/Bin/SetEnv.Cmd"; then 32852 { $as_echo "$as_me:${as_lineno-$LINENO}: Found Windows SDK installation at $WIN_SDK_BASE using $METHOD" >&5 32853 $as_echo "$as_me: Found Windows SDK installation at $WIN_SDK_BASE using $METHOD" >&6;} 32854 VS_ENV_CMD="$WIN_SDK_BASE/Bin/SetEnv.Cmd" 32855 if test "x$OPENJDK_TARGET_CPU_BITS" = x32; then 32856 VS_ENV_ARGS="/x86" 32857 else 32858 VS_ENV_ARGS="/x64" 32859 fi 32860 # PLATFORM_TOOLSET is used during the compilation of the freetype sources (see 32861 # 'LIB_BUILD_FREETYPE' in libraries.m4) and must be 'Windows7.1SDK' for Windows7.1SDK 32862 # TODO: improve detection for other versions of SDK 32863 eval PLATFORM_TOOLSET="\${VS_SDK_PLATFORM_NAME_${VS_VERSION}}" 32864 else 32865 { $as_echo "$as_me:${as_lineno-$LINENO}: Found Windows SDK installation at $WIN_SDK_BASE using $METHOD" >&5 32866 $as_echo "$as_me: Found Windows SDK installation at $WIN_SDK_BASE using $METHOD" >&6;} 32867 { $as_echo "$as_me:${as_lineno-$LINENO}: Warning: Installation is broken, SetEnv.Cmd is missing. Ignoring" >&5 32868 $as_echo "$as_me: Warning: Installation is broken, SetEnv.Cmd is missing. Ignoring" >&6;} 32869 fi 32870 fi 32871 fi 32872 32873 fi 32874 32875 if test "x$VS_ENV_CMD" = x; then 32876 VS_VERSION="${VS_VERSION}" 32877 WIN_SDK_BASE="C:/Program Files/$SDK_INSTALL_DIR" 32878 METHOD="well-known name" 32879 32880 windows_path="$WIN_SDK_BASE" 32881 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 32882 unix_path=`$CYGPATH -u "$windows_path"` 32883 WIN_SDK_BASE="$unix_path" 32884 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 32885 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 32886 WIN_SDK_BASE="$unix_path" 32887 fi 32888 32889 if test -d "$WIN_SDK_BASE"; then 32890 # There have been cases of partial or broken SDK installations. A missing 32891 # lib dir is not going to work. 32892 if test ! -d "$WIN_SDK_BASE/lib"; then 32893 { $as_echo "$as_me:${as_lineno-$LINENO}: Found Windows SDK installation at $WIN_SDK_BASE using $METHOD" >&5 32894 $as_echo "$as_me: Found Windows SDK installation at $WIN_SDK_BASE using $METHOD" >&6;} 32895 { $as_echo "$as_me:${as_lineno-$LINENO}: Warning: Installation is broken, lib dir is missing. Ignoring" >&5 32896 $as_echo "$as_me: Warning: Installation is broken, lib dir is missing. Ignoring" >&6;} 32897 elif test -f "$WIN_SDK_BASE/Bin/SetEnv.Cmd"; then 32898 { $as_echo "$as_me:${as_lineno-$LINENO}: Found Windows SDK installation at $WIN_SDK_BASE using $METHOD" >&5 32899 $as_echo "$as_me: Found Windows SDK installation at $WIN_SDK_BASE using $METHOD" >&6;} 32900 VS_ENV_CMD="$WIN_SDK_BASE/Bin/SetEnv.Cmd" 32901 if test "x$OPENJDK_TARGET_CPU_BITS" = x32; then 32902 VS_ENV_ARGS="/x86" 32903 else 32904 VS_ENV_ARGS="/x64" 32905 fi 32906 # PLATFORM_TOOLSET is used during the compilation of the freetype sources (see 32907 # 'LIB_BUILD_FREETYPE' in libraries.m4) and must be 'Windows7.1SDK' for Windows7.1SDK 32908 # TODO: improve detection for other versions of SDK 32909 eval PLATFORM_TOOLSET="\${VS_SDK_PLATFORM_NAME_${VS_VERSION}}" 32910 else 32911 { $as_echo "$as_me:${as_lineno-$LINENO}: Found Windows SDK installation at $WIN_SDK_BASE using $METHOD" >&5 32912 $as_echo "$as_me: Found Windows SDK installation at $WIN_SDK_BASE using $METHOD" >&6;} 32913 { $as_echo "$as_me:${as_lineno-$LINENO}: Warning: Installation is broken, SetEnv.Cmd is missing. Ignoring" >&5 32914 $as_echo "$as_me: Warning: Installation is broken, SetEnv.Cmd is missing. Ignoring" >&6;} 32915 fi 32916 fi 32917 fi 32918 32919 32920 if test "x$VS_ENV_CMD" = x; then 32921 VS_VERSION="${VS_VERSION}" 32922 WIN_SDK_BASE="C:/Program Files (x86)/$SDK_INSTALL_DIR" 32923 METHOD="well-known name" 32924 32925 windows_path="$WIN_SDK_BASE" 32926 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 32927 unix_path=`$CYGPATH -u "$windows_path"` 32928 WIN_SDK_BASE="$unix_path" 32929 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 32930 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 32931 WIN_SDK_BASE="$unix_path" 32932 fi 32933 32934 if test -d "$WIN_SDK_BASE"; then 32935 # There have been cases of partial or broken SDK installations. A missing 32936 # lib dir is not going to work. 32937 if test ! -d "$WIN_SDK_BASE/lib"; then 32938 { $as_echo "$as_me:${as_lineno-$LINENO}: Found Windows SDK installation at $WIN_SDK_BASE using $METHOD" >&5 32939 $as_echo "$as_me: Found Windows SDK installation at $WIN_SDK_BASE using $METHOD" >&6;} 32940 { $as_echo "$as_me:${as_lineno-$LINENO}: Warning: Installation is broken, lib dir is missing. Ignoring" >&5 32941 $as_echo "$as_me: Warning: Installation is broken, lib dir is missing. Ignoring" >&6;} 32942 elif test -f "$WIN_SDK_BASE/Bin/SetEnv.Cmd"; then 32943 { $as_echo "$as_me:${as_lineno-$LINENO}: Found Windows SDK installation at $WIN_SDK_BASE using $METHOD" >&5 32944 $as_echo "$as_me: Found Windows SDK installation at $WIN_SDK_BASE using $METHOD" >&6;} 32945 VS_ENV_CMD="$WIN_SDK_BASE/Bin/SetEnv.Cmd" 32946 if test "x$OPENJDK_TARGET_CPU_BITS" = x32; then 32947 VS_ENV_ARGS="/x86" 32948 else 32949 VS_ENV_ARGS="/x64" 32950 fi 32951 # PLATFORM_TOOLSET is used during the compilation of the freetype sources (see 32952 # 'LIB_BUILD_FREETYPE' in libraries.m4) and must be 'Windows7.1SDK' for Windows7.1SDK 32953 # TODO: improve detection for other versions of SDK 32954 eval PLATFORM_TOOLSET="\${VS_SDK_PLATFORM_NAME_${VS_VERSION}}" 32955 else 32956 { $as_echo "$as_me:${as_lineno-$LINENO}: Found Windows SDK installation at $WIN_SDK_BASE using $METHOD" >&5 32957 $as_echo "$as_me: Found Windows SDK installation at $WIN_SDK_BASE using $METHOD" >&6;} 32958 { $as_echo "$as_me:${as_lineno-$LINENO}: Warning: Installation is broken, SetEnv.Cmd is missing. Ignoring" >&5 32959 $as_echo "$as_me: Warning: Installation is broken, SetEnv.Cmd is missing. Ignoring" >&6;} 32960 fi 32961 fi 32962 fi 32963 32964 fi 32965 32966 if test "x$VS_ENV_CMD" != x; then 32967 TOOLCHAIN_VERSION=$VS_VERSION 32968 eval VS_DESCRIPTION="\${VS_DESCRIPTION_${VS_VERSION}}" 32969 eval VS_VERSION_INTERNAL="\${VS_VERSION_INTERNAL_${VS_VERSION}}" 32970 eval MSVCR_NAME="\${VS_MSVCR_${VS_VERSION}}" 32971 eval MSVCP_NAME="\${VS_MSVCP_${VS_VERSION}}" 32972 # The rest of the variables are already evaled while probing 32973 { $as_echo "$as_me:${as_lineno-$LINENO}: Found $VS_DESCRIPTION" >&5 32974 $as_echo "$as_me: Found $VS_DESCRIPTION" >&6;} 32975 break 32976 fi 32977 done 32978 32979 32980 # If we have a devkit, skip all of the below. 32981 if test "x$DEVKIT_VS_VERSION" = x; then 32982 if test "x$VS_ENV_CMD" != x; then 32983 # We have found a Visual Studio environment on disk, let's extract variables from the vsvars bat file. 32984 32985 # Only process if variable expands to non-empty 32986 32987 if test "x$VS_ENV_CMD" != x; then 32988 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 32989 32990 # First separate the path from the arguments. This will split at the first 32991 # space. 32992 complete="$VS_ENV_CMD" 32993 path="${complete%% *}" 32994 tmp="$complete EOL" 32995 arguments="${tmp#* }" 32996 32997 # Input might be given as Windows format, start by converting to 32998 # unix format. 32999 new_path=`$CYGPATH -u "$path"` 33000 33001 # Now try to locate executable using which 33002 new_path=`$WHICH "$new_path" 2> /dev/null` 33003 # bat and cmd files are not always considered executable in cygwin causing which 33004 # to not find them 33005 if test "x$new_path" = x \ 33006 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 33007 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 33008 new_path=`$CYGPATH -u "$path"` 33009 fi 33010 if test "x$new_path" = x; then 33011 # Oops. Which didn't find the executable. 33012 # The splitting of arguments from the executable at a space might have been incorrect, 33013 # since paths with space are more likely in Windows. Give it another try with the whole 33014 # argument. 33015 path="$complete" 33016 arguments="EOL" 33017 new_path=`$CYGPATH -u "$path"` 33018 new_path=`$WHICH "$new_path" 2> /dev/null` 33019 # bat and cmd files are not always considered executable in cygwin causing which 33020 # to not find them 33021 if test "x$new_path" = x \ 33022 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 33023 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 33024 new_path=`$CYGPATH -u "$path"` 33025 fi 33026 if test "x$new_path" = x; then 33027 # It's still not found. Now this is an unrecoverable error. 33028 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of VS_ENV_CMD, which resolves as \"$complete\", is not found." >&5 33029 $as_echo "$as_me: The path of VS_ENV_CMD, which resolves as \"$complete\", is not found." >&6;} 33030 has_space=`$ECHO "$complete" | $GREP " "` 33031 if test "x$has_space" != x; then 33032 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 33033 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 33034 fi 33035 as_fn_error $? "Cannot locate the the path of VS_ENV_CMD" "$LINENO" 5 33036 fi 33037 fi 33038 33039 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 33040 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 33041 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 33042 # "foo.exe" is OK but "foo" is an error. 33043 # 33044 # This test is therefore slightly more accurate than "test -f" to check for file presence. 33045 # It is also a way to make sure we got the proper file name for the real test later on. 33046 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 33047 if test "x$test_shortpath" = x; then 33048 # Short path failed, file does not exist as specified. 33049 # Try adding .exe or .cmd 33050 if test -f "${new_path}.exe"; then 33051 input_to_shortpath="${new_path}.exe" 33052 elif test -f "${new_path}.cmd"; then 33053 input_to_shortpath="${new_path}.cmd" 33054 else 33055 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of VS_ENV_CMD, which resolves as \"$new_path\", is invalid." >&5 33056 $as_echo "$as_me: The path of VS_ENV_CMD, which resolves as \"$new_path\", is invalid." >&6;} 33057 { $as_echo "$as_me:${as_lineno-$LINENO}: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&5 33058 $as_echo "$as_me: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&6;} 33059 as_fn_error $? "Cannot locate the the path of VS_ENV_CMD" "$LINENO" 5 33060 fi 33061 else 33062 input_to_shortpath="$new_path" 33063 fi 33064 33065 # Call helper function which possibly converts this using DOS-style short mode. 33066 # If so, the updated path is stored in $new_path. 33067 new_path="$input_to_shortpath" 33068 33069 input_path="$input_to_shortpath" 33070 # Check if we need to convert this using DOS-style short mode. If the path 33071 # contains just simple characters, use it. Otherwise (spaces, weird characters), 33072 # take no chances and rewrite it. 33073 # Note: m4 eats our [], so we need to use [ and ] instead. 33074 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 33075 if test "x$has_forbidden_chars" != x; then 33076 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 33077 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 33078 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 33079 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 33080 # Going to short mode and back again did indeed matter. Since short mode is 33081 # case insensitive, let's make it lowercase to improve readability. 33082 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 33083 # Now convert it back to Unix-style (cygpath) 33084 input_path=`$CYGPATH -u "$shortmode_path"` 33085 new_path="$input_path" 33086 fi 33087 fi 33088 33089 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 33090 if test "x$test_cygdrive_prefix" = x; then 33091 # As a simple fix, exclude /usr/bin since it's not a real path. 33092 if test "x`$ECHO $input_to_shortpath | $GREP ^/usr/bin/`" = x; then 33093 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 33094 # a path prefixed by /cygdrive for fixpath to work. 33095 new_path="$CYGWIN_ROOT_PATH$input_path" 33096 fi 33097 fi 33098 33099 # remove trailing .exe if any 33100 new_path="${new_path/%.exe/}" 33101 33102 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 33103 33104 # First separate the path from the arguments. This will split at the first 33105 # space. 33106 complete="$VS_ENV_CMD" 33107 path="${complete%% *}" 33108 tmp="$complete EOL" 33109 arguments="${tmp#* }" 33110 33111 # Input might be given as Windows format, start by converting to 33112 # unix format. 33113 new_path="$path" 33114 33115 windows_path="$new_path" 33116 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 33117 unix_path=`$CYGPATH -u "$windows_path"` 33118 new_path="$unix_path" 33119 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 33120 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 33121 new_path="$unix_path" 33122 fi 33123 33124 33125 # Now try to locate executable using which 33126 new_path=`$WHICH "$new_path" 2> /dev/null` 33127 33128 if test "x$new_path" = x; then 33129 # Oops. Which didn't find the executable. 33130 # The splitting of arguments from the executable at a space might have been incorrect, 33131 # since paths with space are more likely in Windows. Give it another try with the whole 33132 # argument. 33133 path="$complete" 33134 arguments="EOL" 33135 new_path="$path" 33136 33137 windows_path="$new_path" 33138 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 33139 unix_path=`$CYGPATH -u "$windows_path"` 33140 new_path="$unix_path" 33141 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 33142 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 33143 new_path="$unix_path" 33144 fi 33145 33146 33147 new_path=`$WHICH "$new_path" 2> /dev/null` 33148 # bat and cmd files are not always considered executable in MSYS causing which 33149 # to not find them 33150 if test "x$new_path" = x \ 33151 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 33152 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 33153 new_path="$path" 33154 33155 windows_path="$new_path" 33156 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 33157 unix_path=`$CYGPATH -u "$windows_path"` 33158 new_path="$unix_path" 33159 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 33160 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 33161 new_path="$unix_path" 33162 fi 33163 33164 fi 33165 33166 if test "x$new_path" = x; then 33167 # It's still not found. Now this is an unrecoverable error. 33168 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of VS_ENV_CMD, which resolves as \"$complete\", is not found." >&5 33169 $as_echo "$as_me: The path of VS_ENV_CMD, which resolves as \"$complete\", is not found." >&6;} 33170 has_space=`$ECHO "$complete" | $GREP " "` 33171 if test "x$has_space" != x; then 33172 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 33173 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 33174 fi 33175 as_fn_error $? "Cannot locate the the path of VS_ENV_CMD" "$LINENO" 5 33176 fi 33177 fi 33178 33179 # Now new_path has a complete unix path to the binary 33180 if test "x`$ECHO $new_path | $GREP ^/bin/`" != x; then 33181 # Keep paths in /bin as-is, but remove trailing .exe if any 33182 new_path="${new_path/%.exe/}" 33183 # Do not save /bin paths to all_fixpath_prefixes! 33184 else 33185 # Not in mixed or Windows style, start by that. 33186 new_path=`cmd //c echo $new_path` 33187 33188 input_path="$new_path" 33189 # Check if we need to convert this using DOS-style short mode. If the path 33190 # contains just simple characters, use it. Otherwise (spaces, weird characters), 33191 # take no chances and rewrite it. 33192 # Note: m4 eats our [], so we need to use [ and ] instead. 33193 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 33194 if test "x$has_forbidden_chars" != x; then 33195 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 33196 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 33197 fi 33198 33199 # Output is in $new_path 33200 33201 windows_path="$new_path" 33202 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 33203 unix_path=`$CYGPATH -u "$windows_path"` 33204 new_path="$unix_path" 33205 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 33206 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 33207 new_path="$unix_path" 33208 fi 33209 33210 # remove trailing .exe if any 33211 new_path="${new_path/%.exe/}" 33212 33213 # Save the first 10 bytes of this path to the storage, so fixpath can work. 33214 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 33215 fi 33216 33217 else 33218 # We're on a unix platform. Hooray! :) 33219 # First separate the path from the arguments. This will split at the first 33220 # space. 33221 complete="$VS_ENV_CMD" 33222 path="${complete%% *}" 33223 tmp="$complete EOL" 33224 arguments="${tmp#* }" 33225 33226 # Cannot rely on the command "which" here since it doesn't always work. 33227 is_absolute_path=`$ECHO "$path" | $GREP ^/` 33228 if test -z "$is_absolute_path"; then 33229 # Path to executable is not absolute. Find it. 33230 IFS_save="$IFS" 33231 IFS=: 33232 for p in $PATH; do 33233 if test -f "$p/$path" && test -x "$p/$path"; then 33234 new_path="$p/$path" 33235 break 33236 fi 33237 done 33238 IFS="$IFS_save" 33239 else 33240 # This is an absolute path, we can use it without further modifications. 33241 new_path="$path" 33242 fi 33243 33244 if test "x$new_path" = x; then 33245 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of VS_ENV_CMD, which resolves as \"$complete\", is not found." >&5 33246 $as_echo "$as_me: The path of VS_ENV_CMD, which resolves as \"$complete\", is not found." >&6;} 33247 has_space=`$ECHO "$complete" | $GREP " "` 33248 if test "x$has_space" != x; then 33249 { $as_echo "$as_me:${as_lineno-$LINENO}: This might be caused by spaces in the path, which is not allowed." >&5 33250 $as_echo "$as_me: This might be caused by spaces in the path, which is not allowed." >&6;} 33251 fi 33252 as_fn_error $? "Cannot locate the the path of VS_ENV_CMD" "$LINENO" 5 33253 fi 33254 fi 33255 33256 # Now join together the path and the arguments once again 33257 if test "x$arguments" != xEOL; then 33258 new_complete="$new_path ${arguments% *}" 33259 else 33260 new_complete="$new_path" 33261 fi 33262 33263 if test "x$complete" != "x$new_complete"; then 33264 VS_ENV_CMD="$new_complete" 33265 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting VS_ENV_CMD to \"$new_complete\"" >&5 33266 $as_echo "$as_me: Rewriting VS_ENV_CMD to \"$new_complete\"" >&6;} 33267 fi 33268 fi 33269 33270 33271 # Lets extract the variables that are set by vcvarsall.bat/vsvars32.bat/vsvars64.bat 33272 { $as_echo "$as_me:${as_lineno-$LINENO}: Trying to extract Visual Studio environment variables" >&5 33273 $as_echo "$as_me: Trying to extract Visual Studio environment variables" >&6;} 33274 33275 # We need to create a couple of temporary files. 33276 VS_ENV_TMP_DIR="$CONFIGURESUPPORT_OUTPUTDIR/vs-env" 33277 $MKDIR -p $VS_ENV_TMP_DIR 33278 33279 # Cannot use the VS10 setup script directly (since it only updates the DOS subshell environment). 33280 # Instead create a shell script which will set the relevant variables when run. 33281 WINPATH_VS_ENV_CMD="$VS_ENV_CMD" 33282 33283 unix_path="$WINPATH_VS_ENV_CMD" 33284 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 33285 windows_path=`$CYGPATH -m "$unix_path"` 33286 WINPATH_VS_ENV_CMD="$windows_path" 33287 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 33288 windows_path=`cmd //c echo $unix_path` 33289 WINPATH_VS_ENV_CMD="$windows_path" 33290 fi 33291 33292 WINPATH_BASH="$BASH" 33293 33294 unix_path="$WINPATH_BASH" 33295 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 33296 windows_path=`$CYGPATH -m "$unix_path"` 33297 WINPATH_BASH="$windows_path" 33298 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 33299 windows_path=`cmd //c echo $unix_path` 33300 WINPATH_BASH="$windows_path" 33301 fi 33302 33303 33304 # Generate a DOS batch file which runs $VS_ENV_CMD, and then creates a shell 33305 # script (executable by bash) that will setup the important variables. 33306 EXTRACT_VC_ENV_BAT_FILE="$VS_ENV_TMP_DIR/extract-vs-env.bat" 33307 $ECHO "@echo off" > $EXTRACT_VC_ENV_BAT_FILE 33308 # This will end up something like: 33309 # call C:/progra~2/micros~2.0/vc/bin/amd64/vcvars64.bat 33310 $ECHO "call $WINPATH_VS_ENV_CMD $VS_ENV_ARGS" >> $EXTRACT_VC_ENV_BAT_FILE 33311 # These will end up something like: 33312 # C:/CygWin/bin/bash -c 'echo VS_PATH=\"$PATH\" > localdevenv.sh 33313 # The trailing space for everyone except PATH is no typo, but is needed due 33314 # to trailing \ in the Windows paths. These will be stripped later. 33315 $ECHO "$WINPATH_BASH -c 'echo VS_PATH="'\"$PATH\" > set-vs-env.sh' \ 33316 >> $EXTRACT_VC_ENV_BAT_FILE 33317 $ECHO "$WINPATH_BASH -c 'echo VS_INCLUDE="'\"$INCLUDE\;$include \" >> set-vs-env.sh' \ 33318 >> $EXTRACT_VC_ENV_BAT_FILE 33319 $ECHO "$WINPATH_BASH -c 'echo VS_LIB="'\"$LIB\;$lib \" >> set-vs-env.sh' \ 33320 >> $EXTRACT_VC_ENV_BAT_FILE 33321 $ECHO "$WINPATH_BASH -c 'echo VCINSTALLDIR="'\"$VCINSTALLDIR \" >> set-vs-env.sh' \ 33322 >> $EXTRACT_VC_ENV_BAT_FILE 33323 $ECHO "$WINPATH_BASH -c 'echo WindowsSdkDir="'\"$WindowsSdkDir \" >> set-vs-env.sh' \ 33324 >> $EXTRACT_VC_ENV_BAT_FILE 33325 $ECHO "$WINPATH_BASH -c 'echo WINDOWSSDKDIR="'\"$WINDOWSSDKDIR \" >> set-vs-env.sh' \ 33326 >> $EXTRACT_VC_ENV_BAT_FILE 33327 33328 # Now execute the newly created bat file. 33329 # The | cat is to stop SetEnv.Cmd to mess with system colors on msys. 33330 # Change directory so we don't need to mess with Windows paths in redirects. 33331 cd $VS_ENV_TMP_DIR 33332 cmd /c extract-vs-env.bat | $CAT 33333 cd $CURDIR 33334 33335 if test ! -s $VS_ENV_TMP_DIR/set-vs-env.sh; then 33336 { $as_echo "$as_me:${as_lineno-$LINENO}: Could not succesfully extract the envionment variables needed for the VS setup." >&5 33337 $as_echo "$as_me: Could not succesfully extract the envionment variables needed for the VS setup." >&6;} 33338 { $as_echo "$as_me:${as_lineno-$LINENO}: Try setting --with-tools-dir to the VC/bin directory within the VS installation" >&5 33339 $as_echo "$as_me: Try setting --with-tools-dir to the VC/bin directory within the VS installation" >&6;} 33340 { $as_echo "$as_me:${as_lineno-$LINENO}: or run \"bash.exe -l\" from a VS command prompt and then run configure from there." >&5 33341 $as_echo "$as_me: or run \"bash.exe -l\" from a VS command prompt and then run configure from there." >&6;} 33342 as_fn_error $? "Cannot continue" "$LINENO" 5 33343 fi 33344 33345 # Now set all paths and other env variables. This will allow the rest of 33346 # the configure script to find and run the compiler in the proper way. 33347 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting extracted environment variables" >&5 33348 $as_echo "$as_me: Setting extracted environment variables" >&6;} 33349 . $VS_ENV_TMP_DIR/set-vs-env.sh 33350 # Now we have VS_PATH, VS_INCLUDE, VS_LIB. For further checking, we 33351 # also define VCINSTALLDIR, WindowsSdkDir and WINDOWSSDKDIR. 33352 else 33353 # We did not find a vsvars bat file, let's hope we are run from a VS command prompt. 33354 { $as_echo "$as_me:${as_lineno-$LINENO}: Cannot locate a valid Visual Studio installation, checking current environment" >&5 33355 $as_echo "$as_me: Cannot locate a valid Visual Studio installation, checking current environment" >&6;} 33356 fi 33357 fi 33358 33359 # At this point, we should have correct variables in the environment, or we can't continue. 33360 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for Visual Studio variables" >&5 33361 $as_echo_n "checking for Visual Studio variables... " >&6; } 33362 33363 if test "x$VCINSTALLDIR" != x || test "x$WindowsSDKDir" != x \ 33364 || test "x$WINDOWSSDKDIR" != x || test "x$DEVKIT_NAME" != x; then 33365 if test "x$VS_INCLUDE" = x || test "x$VS_LIB" = x; then 33366 { $as_echo "$as_me:${as_lineno-$LINENO}: result: present but broken" >&5 33367 $as_echo "present but broken" >&6; } 33368 as_fn_error $? "Your VC command prompt seems broken, INCLUDE and/or LIB is missing." "$LINENO" 5 33369 else 33370 { $as_echo "$as_me:${as_lineno-$LINENO}: result: ok" >&5 33371 $as_echo "ok" >&6; } 33372 # Remove any trailing "\" ";" and " " from the variables. 33373 VS_INCLUDE=`$ECHO "$VS_INCLUDE" | $SED -e 's/\\\\*;* *$//'` 33374 VS_LIB=`$ECHO "$VS_LIB" | $SED 's/\\\\*;* *$//'` 33375 VCINSTALLDIR=`$ECHO "$VCINSTALLDIR" | $SED 's/\\\\* *$//'` 33376 WindowsSDKDir=`$ECHO "$WindowsSDKDir" | $SED 's/\\\\* *$//'` 33377 WINDOWSSDKDIR=`$ECHO "$WINDOWSSDKDIR" | $SED 's/\\\\* *$//'` 33378 # Remove any paths containing # (typically F#) as that messes up make. This 33379 # is needed if visual studio was installed with F# support. 33380 VS_PATH=`$ECHO "$VS_PATH" | $SED 's/[^:#]*#[^:]*://g'` 33381 33382 33383 33384 33385 33386 # Convert VS_INCLUDE into SYSROOT_CFLAGS 33387 OLDIFS="$IFS" 33388 IFS=";" 33389 for i in $VS_INCLUDE; do 33390 ipath=$i 33391 # Only process non-empty elements 33392 if test "x$ipath" != x; then 33393 IFS="$OLDIFS" 33394 # Check that directory exists before calling fixup_path 33395 testpath=$ipath 33396 33397 windows_path="$testpath" 33398 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 33399 unix_path=`$CYGPATH -u "$windows_path"` 33400 testpath="$unix_path" 33401 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 33402 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 33403 testpath="$unix_path" 33404 fi 33405 33406 if test -d "$testpath"; then 33407 33408 # Only process if variable expands to non-empty 33409 33410 if test "x$ipath" != x; then 33411 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 33412 33413 # Input might be given as Windows format, start by converting to 33414 # unix format. 33415 path="$ipath" 33416 new_path=`$CYGPATH -u "$path"` 33417 33418 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 33419 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 33420 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 33421 # "foo.exe" is OK but "foo" is an error. 33422 # 33423 # This test is therefore slightly more accurate than "test -f" to check for file precense. 33424 # It is also a way to make sure we got the proper file name for the real test later on. 33425 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 33426 if test "x$test_shortpath" = x; then 33427 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of ipath, which resolves as \"$path\", is invalid." >&5 33428 $as_echo "$as_me: The path of ipath, which resolves as \"$path\", is invalid." >&6;} 33429 as_fn_error $? "Cannot locate the the path of ipath" "$LINENO" 5 33430 fi 33431 33432 # Call helper function which possibly converts this using DOS-style short mode. 33433 # If so, the updated path is stored in $new_path. 33434 33435 input_path="$new_path" 33436 # Check if we need to convert this using DOS-style short mode. If the path 33437 # contains just simple characters, use it. Otherwise (spaces, weird characters), 33438 # take no chances and rewrite it. 33439 # Note: m4 eats our [], so we need to use [ and ] instead. 33440 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 33441 if test "x$has_forbidden_chars" != x; then 33442 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 33443 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 33444 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 33445 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 33446 # Going to short mode and back again did indeed matter. Since short mode is 33447 # case insensitive, let's make it lowercase to improve readability. 33448 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 33449 # Now convert it back to Unix-style (cygpath) 33450 input_path=`$CYGPATH -u "$shortmode_path"` 33451 new_path="$input_path" 33452 fi 33453 fi 33454 33455 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 33456 if test "x$test_cygdrive_prefix" = x; then 33457 # As a simple fix, exclude /usr/bin since it's not a real path. 33458 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 33459 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 33460 # a path prefixed by /cygdrive for fixpath to work. 33461 new_path="$CYGWIN_ROOT_PATH$input_path" 33462 fi 33463 fi 33464 33465 33466 if test "x$path" != "x$new_path"; then 33467 ipath="$new_path" 33468 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting ipath to \"$new_path\"" >&5 33469 $as_echo "$as_me: Rewriting ipath to \"$new_path\"" >&6;} 33470 fi 33471 33472 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 33473 33474 path="$ipath" 33475 has_colon=`$ECHO $path | $GREP ^.:` 33476 new_path="$path" 33477 if test "x$has_colon" = x; then 33478 # Not in mixed or Windows style, start by that. 33479 new_path=`cmd //c echo $path` 33480 fi 33481 33482 33483 input_path="$new_path" 33484 # Check if we need to convert this using DOS-style short mode. If the path 33485 # contains just simple characters, use it. Otherwise (spaces, weird characters), 33486 # take no chances and rewrite it. 33487 # Note: m4 eats our [], so we need to use [ and ] instead. 33488 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 33489 if test "x$has_forbidden_chars" != x; then 33490 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 33491 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 33492 fi 33493 33494 33495 windows_path="$new_path" 33496 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 33497 unix_path=`$CYGPATH -u "$windows_path"` 33498 new_path="$unix_path" 33499 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 33500 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 33501 new_path="$unix_path" 33502 fi 33503 33504 if test "x$path" != "x$new_path"; then 33505 ipath="$new_path" 33506 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting ipath to \"$new_path\"" >&5 33507 $as_echo "$as_me: Rewriting ipath to \"$new_path\"" >&6;} 33508 fi 33509 33510 # Save the first 10 bytes of this path to the storage, so fixpath can work. 33511 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 33512 33513 else 33514 # We're on a unix platform. Hooray! :) 33515 path="$ipath" 33516 has_space=`$ECHO "$path" | $GREP " "` 33517 if test "x$has_space" != x; then 33518 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of ipath, which resolves as \"$path\", is invalid." >&5 33519 $as_echo "$as_me: The path of ipath, which resolves as \"$path\", is invalid." >&6;} 33520 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 33521 fi 33522 33523 # Use eval to expand a potential ~ 33524 eval path="$path" 33525 if test ! -f "$path" && test ! -d "$path"; then 33526 as_fn_error $? "The path of ipath, which resolves as \"$path\", is not found." "$LINENO" 5 33527 fi 33528 33529 if test -d "$path"; then 33530 ipath="`cd "$path"; $THEPWDCMD -L`" 33531 else 33532 dir="`$DIRNAME "$path"`" 33533 base="`$BASENAME "$path"`" 33534 ipath="`cd "$dir"; $THEPWDCMD -L`/$base" 33535 fi 33536 fi 33537 fi 33538 33539 SYSROOT_CFLAGS="$SYSROOT_CFLAGS -I$ipath" 33540 fi 33541 IFS=";" 33542 fi 33543 done 33544 # Convert VS_LIB into SYSROOT_LDFLAGS 33545 for i in $VS_LIB; do 33546 libpath=$i 33547 # Only process non-empty elements 33548 if test "x$libpath" != x; then 33549 IFS="$OLDIFS" 33550 # Check that directory exists before calling fixup_path 33551 testpath=$libpath 33552 33553 windows_path="$testpath" 33554 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 33555 unix_path=`$CYGPATH -u "$windows_path"` 33556 testpath="$unix_path" 33557 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 33558 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 33559 testpath="$unix_path" 33560 fi 33561 33562 if test -d "$testpath"; then 33563 33564 # Only process if variable expands to non-empty 33565 33566 if test "x$libpath" != x; then 33567 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 33568 33569 # Input might be given as Windows format, start by converting to 33570 # unix format. 33571 path="$libpath" 33572 new_path=`$CYGPATH -u "$path"` 33573 33574 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 33575 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 33576 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 33577 # "foo.exe" is OK but "foo" is an error. 33578 # 33579 # This test is therefore slightly more accurate than "test -f" to check for file precense. 33580 # It is also a way to make sure we got the proper file name for the real test later on. 33581 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 33582 if test "x$test_shortpath" = x; then 33583 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of libpath, which resolves as \"$path\", is invalid." >&5 33584 $as_echo "$as_me: The path of libpath, which resolves as \"$path\", is invalid." >&6;} 33585 as_fn_error $? "Cannot locate the the path of libpath" "$LINENO" 5 33586 fi 33587 33588 # Call helper function which possibly converts this using DOS-style short mode. 33589 # If so, the updated path is stored in $new_path. 33590 33591 input_path="$new_path" 33592 # Check if we need to convert this using DOS-style short mode. If the path 33593 # contains just simple characters, use it. Otherwise (spaces, weird characters), 33594 # take no chances and rewrite it. 33595 # Note: m4 eats our [], so we need to use [ and ] instead. 33596 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 33597 if test "x$has_forbidden_chars" != x; then 33598 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 33599 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 33600 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 33601 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 33602 # Going to short mode and back again did indeed matter. Since short mode is 33603 # case insensitive, let's make it lowercase to improve readability. 33604 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 33605 # Now convert it back to Unix-style (cygpath) 33606 input_path=`$CYGPATH -u "$shortmode_path"` 33607 new_path="$input_path" 33608 fi 33609 fi 33610 33611 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 33612 if test "x$test_cygdrive_prefix" = x; then 33613 # As a simple fix, exclude /usr/bin since it's not a real path. 33614 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 33615 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 33616 # a path prefixed by /cygdrive for fixpath to work. 33617 new_path="$CYGWIN_ROOT_PATH$input_path" 33618 fi 33619 fi 33620 33621 33622 if test "x$path" != "x$new_path"; then 33623 libpath="$new_path" 33624 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting libpath to \"$new_path\"" >&5 33625 $as_echo "$as_me: Rewriting libpath to \"$new_path\"" >&6;} 33626 fi 33627 33628 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 33629 33630 path="$libpath" 33631 has_colon=`$ECHO $path | $GREP ^.:` 33632 new_path="$path" 33633 if test "x$has_colon" = x; then 33634 # Not in mixed or Windows style, start by that. 33635 new_path=`cmd //c echo $path` 33636 fi 33637 33638 33639 input_path="$new_path" 33640 # Check if we need to convert this using DOS-style short mode. If the path 33641 # contains just simple characters, use it. Otherwise (spaces, weird characters), 33642 # take no chances and rewrite it. 33643 # Note: m4 eats our [], so we need to use [ and ] instead. 33644 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 33645 if test "x$has_forbidden_chars" != x; then 33646 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 33647 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 33648 fi 33649 33650 33651 windows_path="$new_path" 33652 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 33653 unix_path=`$CYGPATH -u "$windows_path"` 33654 new_path="$unix_path" 33655 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 33656 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 33657 new_path="$unix_path" 33658 fi 33659 33660 if test "x$path" != "x$new_path"; then 33661 libpath="$new_path" 33662 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting libpath to \"$new_path\"" >&5 33663 $as_echo "$as_me: Rewriting libpath to \"$new_path\"" >&6;} 33664 fi 33665 33666 # Save the first 10 bytes of this path to the storage, so fixpath can work. 33667 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 33668 33669 else 33670 # We're on a unix platform. Hooray! :) 33671 path="$libpath" 33672 has_space=`$ECHO "$path" | $GREP " "` 33673 if test "x$has_space" != x; then 33674 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of libpath, which resolves as \"$path\", is invalid." >&5 33675 $as_echo "$as_me: The path of libpath, which resolves as \"$path\", is invalid." >&6;} 33676 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 33677 fi 33678 33679 # Use eval to expand a potential ~ 33680 eval path="$path" 33681 if test ! -f "$path" && test ! -d "$path"; then 33682 as_fn_error $? "The path of libpath, which resolves as \"$path\", is not found." "$LINENO" 5 33683 fi 33684 33685 if test -d "$path"; then 33686 libpath="`cd "$path"; $THEPWDCMD -L`" 33687 else 33688 dir="`$DIRNAME "$path"`" 33689 base="`$BASENAME "$path"`" 33690 libpath="`cd "$dir"; $THEPWDCMD -L`/$base" 33691 fi 33692 fi 33693 fi 33694 33695 SYSROOT_LDFLAGS="$SYSROOT_LDFLAGS -libpath:$libpath" 33696 fi 33697 IFS=";" 33698 fi 33699 done 33700 IFS="$OLDIFS" 33701 fi 33702 else 33703 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 33704 $as_echo "not found" >&6; } 33705 33706 if test "x$VS_ENV_CMD" = x; then 33707 { $as_echo "$as_me:${as_lineno-$LINENO}: Cannot locate a valid Visual Studio or Windows SDK installation on disk," >&5 33708 $as_echo "$as_me: Cannot locate a valid Visual Studio or Windows SDK installation on disk," >&6;} 33709 { $as_echo "$as_me:${as_lineno-$LINENO}: nor is this script run from a Visual Studio command prompt." >&5 33710 $as_echo "$as_me: nor is this script run from a Visual Studio command prompt." >&6;} 33711 else 33712 { $as_echo "$as_me:${as_lineno-$LINENO}: Running the extraction script failed." >&5 33713 $as_echo "$as_me: Running the extraction script failed." >&6;} 33714 fi 33715 { $as_echo "$as_me:${as_lineno-$LINENO}: Try setting --with-tools-dir to the VC/bin directory within the VS installation" >&5 33716 $as_echo "$as_me: Try setting --with-tools-dir to the VC/bin directory within the VS installation" >&6;} 33717 { $as_echo "$as_me:${as_lineno-$LINENO}: or run \"bash.exe -l\" from a VS command prompt and then run configure from there." >&5 33718 $as_echo "$as_me: or run \"bash.exe -l\" from a VS command prompt and then run configure from there." >&6;} 33719 as_fn_error $? "Cannot continue" "$LINENO" 5 33720 fi 33721 33722 # Reset path to VS_PATH. It will include everything that was on PATH at the time we 33723 # ran TOOLCHAIN_SETUP_VISUAL_STUDIO_ENV. 33724 PATH="$VS_PATH" 33725 # The microsoft toolchain also requires INCLUDE and LIB to be set. 33726 export INCLUDE="$VS_INCLUDE" 33727 export LIB="$VS_LIB" 33728 else 33729 if test "x$XCODE_VERSION_OUTPUT" != x; then 33730 # For Xcode, we set the Xcode version as TOOLCHAIN_VERSION 33731 TOOLCHAIN_VERSION=`$ECHO $XCODE_VERSION_OUTPUT | $CUT -f 2 -d ' '` 33732 TOOLCHAIN_DESCRIPTION="$TOOLCHAIN_DESCRIPTION from Xcode" 33733 else 33734 # Currently we do not define this for other toolchains. This might change as the need arise. 33735 TOOLCHAIN_VERSION= 33736 fi 33737 fi 33738 33739 33740 # Finally add TOOLCHAIN_PATH at the beginning, to allow --with-tools-dir to 33741 # override all other locations. 33742 if test "x$TOOLCHAIN_PATH" != x; then 33743 PATH=$TOOLCHAIN_PATH:$PATH 33744 fi 33745 33746 33747 # 33748 # Setup the compilers (CC and CXX) 33749 # 33750 33751 COMPILER_NAME=C 33752 SEARCH_LIST="$TOOLCHAIN_CC_BINARY" 33753 33754 if test "x$CC" != x; then 33755 # User has supplied compiler name already, always let that override. 33756 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied compiler CC=$CC" >&5 33757 $as_echo "$as_me: Will use user supplied compiler CC=$CC" >&6;} 33758 if test "x`basename $CC`" = "x$CC"; then 33759 # A command without a complete path is provided, search $PATH. 33760 33761 for ac_prog in $CC 33762 do 33763 # Extract the first word of "$ac_prog", so it can be a program name with args. 33764 set dummy $ac_prog; ac_word=$2 33765 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 33766 $as_echo_n "checking for $ac_word... " >&6; } 33767 if ${ac_cv_path_POTENTIAL_CC+:} false; then : 33768 $as_echo_n "(cached) " >&6 33769 else 33770 case $POTENTIAL_CC in 33771 [\\/]* | ?:[\\/]*) 33772 ac_cv_path_POTENTIAL_CC="$POTENTIAL_CC" # Let the user override the test with a path. 33773 ;; 33774 *) 33775 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 33776 for as_dir in $PATH 33777 do 33778 IFS=$as_save_IFS 33779 test -z "$as_dir" && as_dir=. 33780 for ac_exec_ext in '' $ac_executable_extensions; do 33781 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 33782 ac_cv_path_POTENTIAL_CC="$as_dir/$ac_word$ac_exec_ext" 33783 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 33784 break 2 33785 fi 33786 done 33787 done 33788 IFS=$as_save_IFS 33789 33790 ;; 33791 esac 33792 fi 33793 POTENTIAL_CC=$ac_cv_path_POTENTIAL_CC 33794 if test -n "$POTENTIAL_CC"; then 33795 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $POTENTIAL_CC" >&5 33796 $as_echo "$POTENTIAL_CC" >&6; } 33797 else 33798 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 33799 $as_echo "no" >&6; } 33800 fi 33801 33802 33803 test -n "$POTENTIAL_CC" && break 33804 done 33805 33806 if test "x$POTENTIAL_CC" != x; then 33807 CC=$POTENTIAL_CC 33808 else 33809 as_fn_error $? "User supplied compiler CC=$CC could not be found" "$LINENO" 5 33810 fi 33811 else 33812 # Otherwise it might already be a complete path 33813 if test ! -x "$CC"; then 33814 as_fn_error $? "User supplied compiler CC=$CC does not exist" "$LINENO" 5 33815 fi 33816 fi 33817 else 33818 # No user supplied value. Locate compiler ourselves. 33819 33820 # If we are cross compiling, assume cross compilation tools follows the 33821 # cross compilation standard where they are prefixed with the autoconf 33822 # standard name for the target. For example the binary 33823 # i686-sun-solaris2.10-gcc will cross compile for i686-sun-solaris2.10. 33824 # If we are not cross compiling, then the default compiler name will be 33825 # used. 33826 33827 CC= 33828 # If TOOLCHAIN_PATH is set, check for all compiler names in there first 33829 # before checking the rest of the PATH. 33830 # FIXME: Now that we prefix the TOOLS_DIR to the PATH in the PRE_DETECTION 33831 # step, this should not be necessary. 33832 if test -n "$TOOLCHAIN_PATH"; then 33833 PATH_save="$PATH" 33834 PATH="$TOOLCHAIN_PATH" 33835 if test -n "$ac_tool_prefix"; then 33836 # Extract the first word of "${ac_tool_prefix}$SEARCH_LIST", so it can be a program name with args. 33837 set dummy ${ac_tool_prefix}$SEARCH_LIST; ac_word=$2 33838 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 33839 $as_echo_n "checking for $ac_word... " >&6; } 33840 if ${ac_cv_path_TOOLCHAIN_PATH_CC+:} false; then : 33841 $as_echo_n "(cached) " >&6 33842 else 33843 case $TOOLCHAIN_PATH_CC in 33844 [\\/]* | ?:[\\/]*) 33845 ac_cv_path_TOOLCHAIN_PATH_CC="$TOOLCHAIN_PATH_CC" # Let the user override the test with a path. 33846 ;; 33847 *) 33848 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 33849 for as_dir in $PATH 33850 do 33851 IFS=$as_save_IFS 33852 test -z "$as_dir" && as_dir=. 33853 for ac_exec_ext in '' $ac_executable_extensions; do 33854 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 33855 ac_cv_path_TOOLCHAIN_PATH_CC="$as_dir/$ac_word$ac_exec_ext" 33856 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 33857 break 2 33858 fi 33859 done 33860 done 33861 IFS=$as_save_IFS 33862 33863 ;; 33864 esac 33865 fi 33866 TOOLCHAIN_PATH_CC=$ac_cv_path_TOOLCHAIN_PATH_CC 33867 if test -n "$TOOLCHAIN_PATH_CC"; then 33868 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $TOOLCHAIN_PATH_CC" >&5 33869 $as_echo "$TOOLCHAIN_PATH_CC" >&6; } 33870 else 33871 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 33872 $as_echo "no" >&6; } 33873 fi 33874 33875 33876 fi 33877 if test -z "$ac_cv_path_TOOLCHAIN_PATH_CC"; then 33878 ac_pt_TOOLCHAIN_PATH_CC=$TOOLCHAIN_PATH_CC 33879 # Extract the first word of "$SEARCH_LIST", so it can be a program name with args. 33880 set dummy $SEARCH_LIST; ac_word=$2 33881 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 33882 $as_echo_n "checking for $ac_word... " >&6; } 33883 if ${ac_cv_path_ac_pt_TOOLCHAIN_PATH_CC+:} false; then : 33884 $as_echo_n "(cached) " >&6 33885 else 33886 case $ac_pt_TOOLCHAIN_PATH_CC in 33887 [\\/]* | ?:[\\/]*) 33888 ac_cv_path_ac_pt_TOOLCHAIN_PATH_CC="$ac_pt_TOOLCHAIN_PATH_CC" # Let the user override the test with a path. 33889 ;; 33890 *) 33891 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 33892 for as_dir in $PATH 33893 do 33894 IFS=$as_save_IFS 33895 test -z "$as_dir" && as_dir=. 33896 for ac_exec_ext in '' $ac_executable_extensions; do 33897 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 33898 ac_cv_path_ac_pt_TOOLCHAIN_PATH_CC="$as_dir/$ac_word$ac_exec_ext" 33899 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 33900 break 2 33901 fi 33902 done 33903 done 33904 IFS=$as_save_IFS 33905 33906 ;; 33907 esac 33908 fi 33909 ac_pt_TOOLCHAIN_PATH_CC=$ac_cv_path_ac_pt_TOOLCHAIN_PATH_CC 33910 if test -n "$ac_pt_TOOLCHAIN_PATH_CC"; then 33911 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_pt_TOOLCHAIN_PATH_CC" >&5 33912 $as_echo "$ac_pt_TOOLCHAIN_PATH_CC" >&6; } 33913 else 33914 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 33915 $as_echo "no" >&6; } 33916 fi 33917 33918 if test "x$ac_pt_TOOLCHAIN_PATH_CC" = x; then 33919 TOOLCHAIN_PATH_CC="" 33920 else 33921 case $cross_compiling:$ac_tool_warned in 33922 yes:) 33923 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5 33924 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;} 33925 ac_tool_warned=yes ;; 33926 esac 33927 TOOLCHAIN_PATH_CC=$ac_pt_TOOLCHAIN_PATH_CC 33928 fi 33929 else 33930 TOOLCHAIN_PATH_CC="$ac_cv_path_TOOLCHAIN_PATH_CC" 33931 fi 33932 33933 CC=$TOOLCHAIN_PATH_CC 33934 PATH="$PATH_save" 33935 fi 33936 33937 # AC_PATH_TOOL can't be run multiple times with the same variable, 33938 # so create a new name for this run. 33939 if test "x$CC" = x; then 33940 if test -n "$ac_tool_prefix"; then 33941 # Extract the first word of "${ac_tool_prefix}$SEARCH_LIST", so it can be a program name with args. 33942 set dummy ${ac_tool_prefix}$SEARCH_LIST; ac_word=$2 33943 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 33944 $as_echo_n "checking for $ac_word... " >&6; } 33945 if ${ac_cv_path_POTENTIAL_CC+:} false; then : 33946 $as_echo_n "(cached) " >&6 33947 else 33948 case $POTENTIAL_CC in 33949 [\\/]* | ?:[\\/]*) 33950 ac_cv_path_POTENTIAL_CC="$POTENTIAL_CC" # Let the user override the test with a path. 33951 ;; 33952 *) 33953 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 33954 for as_dir in $PATH 33955 do 33956 IFS=$as_save_IFS 33957 test -z "$as_dir" && as_dir=. 33958 for ac_exec_ext in '' $ac_executable_extensions; do 33959 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 33960 ac_cv_path_POTENTIAL_CC="$as_dir/$ac_word$ac_exec_ext" 33961 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 33962 break 2 33963 fi 33964 done 33965 done 33966 IFS=$as_save_IFS 33967 33968 ;; 33969 esac 33970 fi 33971 POTENTIAL_CC=$ac_cv_path_POTENTIAL_CC 33972 if test -n "$POTENTIAL_CC"; then 33973 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $POTENTIAL_CC" >&5 33974 $as_echo "$POTENTIAL_CC" >&6; } 33975 else 33976 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 33977 $as_echo "no" >&6; } 33978 fi 33979 33980 33981 fi 33982 if test -z "$ac_cv_path_POTENTIAL_CC"; then 33983 ac_pt_POTENTIAL_CC=$POTENTIAL_CC 33984 # Extract the first word of "$SEARCH_LIST", so it can be a program name with args. 33985 set dummy $SEARCH_LIST; ac_word=$2 33986 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 33987 $as_echo_n "checking for $ac_word... " >&6; } 33988 if ${ac_cv_path_ac_pt_POTENTIAL_CC+:} false; then : 33989 $as_echo_n "(cached) " >&6 33990 else 33991 case $ac_pt_POTENTIAL_CC in 33992 [\\/]* | ?:[\\/]*) 33993 ac_cv_path_ac_pt_POTENTIAL_CC="$ac_pt_POTENTIAL_CC" # Let the user override the test with a path. 33994 ;; 33995 *) 33996 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 33997 for as_dir in $PATH 33998 do 33999 IFS=$as_save_IFS 34000 test -z "$as_dir" && as_dir=. 34001 for ac_exec_ext in '' $ac_executable_extensions; do 34002 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 34003 ac_cv_path_ac_pt_POTENTIAL_CC="$as_dir/$ac_word$ac_exec_ext" 34004 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 34005 break 2 34006 fi 34007 done 34008 done 34009 IFS=$as_save_IFS 34010 34011 ;; 34012 esac 34013 fi 34014 ac_pt_POTENTIAL_CC=$ac_cv_path_ac_pt_POTENTIAL_CC 34015 if test -n "$ac_pt_POTENTIAL_CC"; then 34016 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_pt_POTENTIAL_CC" >&5 34017 $as_echo "$ac_pt_POTENTIAL_CC" >&6; } 34018 else 34019 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 34020 $as_echo "no" >&6; } 34021 fi 34022 34023 if test "x$ac_pt_POTENTIAL_CC" = x; then 34024 POTENTIAL_CC="" 34025 else 34026 case $cross_compiling:$ac_tool_warned in 34027 yes:) 34028 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5 34029 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;} 34030 ac_tool_warned=yes ;; 34031 esac 34032 POTENTIAL_CC=$ac_pt_POTENTIAL_CC 34033 fi 34034 else 34035 POTENTIAL_CC="$ac_cv_path_POTENTIAL_CC" 34036 fi 34037 34038 CC=$POTENTIAL_CC 34039 fi 34040 34041 if test "x$CC" = x; then 34042 34043 # Print a helpful message on how to acquire the necessary build dependency. 34044 # devkit is the help tag: freetype, cups, alsa etc 34045 MISSING_DEPENDENCY=devkit 34046 34047 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 34048 cygwin_help $MISSING_DEPENDENCY 34049 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 34050 msys_help $MISSING_DEPENDENCY 34051 else 34052 PKGHANDLER_COMMAND= 34053 34054 case $PKGHANDLER in 34055 apt-get) 34056 apt_help $MISSING_DEPENDENCY ;; 34057 yum) 34058 yum_help $MISSING_DEPENDENCY ;; 34059 brew) 34060 brew_help $MISSING_DEPENDENCY ;; 34061 port) 34062 port_help $MISSING_DEPENDENCY ;; 34063 pkgutil) 34064 pkgutil_help $MISSING_DEPENDENCY ;; 34065 pkgadd) 34066 pkgadd_help $MISSING_DEPENDENCY ;; 34067 esac 34068 34069 if test "x$PKGHANDLER_COMMAND" != x; then 34070 HELP_MSG="You might be able to fix this by running '$PKGHANDLER_COMMAND'." 34071 fi 34072 fi 34073 34074 as_fn_error $? "Could not find a $COMPILER_NAME compiler. $HELP_MSG" "$LINENO" 5 34075 fi 34076 fi 34077 34078 # Now we have a compiler binary in CC. Make sure it's okay. 34079 34080 # Only process if variable expands to non-empty 34081 34082 if test "x$CC" != x; then 34083 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 34084 34085 # First separate the path from the arguments. This will split at the first 34086 # space. 34087 complete="$CC" 34088 path="${complete%% *}" 34089 tmp="$complete EOL" 34090 arguments="${tmp#* }" 34091 34092 # Input might be given as Windows format, start by converting to 34093 # unix format. 34094 new_path=`$CYGPATH -u "$path"` 34095 34096 # Now try to locate executable using which 34097 new_path=`$WHICH "$new_path" 2> /dev/null` 34098 # bat and cmd files are not always considered executable in cygwin causing which 34099 # to not find them 34100 if test "x$new_path" = x \ 34101 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 34102 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 34103 new_path=`$CYGPATH -u "$path"` 34104 fi 34105 if test "x$new_path" = x; then 34106 # Oops. Which didn't find the executable. 34107 # The splitting of arguments from the executable at a space might have been incorrect, 34108 # since paths with space are more likely in Windows. Give it another try with the whole 34109 # argument. 34110 path="$complete" 34111 arguments="EOL" 34112 new_path=`$CYGPATH -u "$path"` 34113 new_path=`$WHICH "$new_path" 2> /dev/null` 34114 # bat and cmd files are not always considered executable in cygwin causing which 34115 # to not find them 34116 if test "x$new_path" = x \ 34117 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 34118 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 34119 new_path=`$CYGPATH -u "$path"` 34120 fi 34121 if test "x$new_path" = x; then 34122 # It's still not found. Now this is an unrecoverable error. 34123 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of CC, which resolves as \"$complete\", is not found." >&5 34124 $as_echo "$as_me: The path of CC, which resolves as \"$complete\", is not found." >&6;} 34125 has_space=`$ECHO "$complete" | $GREP " "` 34126 if test "x$has_space" != x; then 34127 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 34128 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 34129 fi 34130 as_fn_error $? "Cannot locate the the path of CC" "$LINENO" 5 34131 fi 34132 fi 34133 34134 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 34135 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 34136 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 34137 # "foo.exe" is OK but "foo" is an error. 34138 # 34139 # This test is therefore slightly more accurate than "test -f" to check for file presence. 34140 # It is also a way to make sure we got the proper file name for the real test later on. 34141 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 34142 if test "x$test_shortpath" = x; then 34143 # Short path failed, file does not exist as specified. 34144 # Try adding .exe or .cmd 34145 if test -f "${new_path}.exe"; then 34146 input_to_shortpath="${new_path}.exe" 34147 elif test -f "${new_path}.cmd"; then 34148 input_to_shortpath="${new_path}.cmd" 34149 else 34150 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of CC, which resolves as \"$new_path\", is invalid." >&5 34151 $as_echo "$as_me: The path of CC, which resolves as \"$new_path\", is invalid." >&6;} 34152 { $as_echo "$as_me:${as_lineno-$LINENO}: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&5 34153 $as_echo "$as_me: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&6;} 34154 as_fn_error $? "Cannot locate the the path of CC" "$LINENO" 5 34155 fi 34156 else 34157 input_to_shortpath="$new_path" 34158 fi 34159 34160 # Call helper function which possibly converts this using DOS-style short mode. 34161 # If so, the updated path is stored in $new_path. 34162 new_path="$input_to_shortpath" 34163 34164 input_path="$input_to_shortpath" 34165 # Check if we need to convert this using DOS-style short mode. If the path 34166 # contains just simple characters, use it. Otherwise (spaces, weird characters), 34167 # take no chances and rewrite it. 34168 # Note: m4 eats our [], so we need to use [ and ] instead. 34169 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 34170 if test "x$has_forbidden_chars" != x; then 34171 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 34172 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 34173 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 34174 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 34175 # Going to short mode and back again did indeed matter. Since short mode is 34176 # case insensitive, let's make it lowercase to improve readability. 34177 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 34178 # Now convert it back to Unix-style (cygpath) 34179 input_path=`$CYGPATH -u "$shortmode_path"` 34180 new_path="$input_path" 34181 fi 34182 fi 34183 34184 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 34185 if test "x$test_cygdrive_prefix" = x; then 34186 # As a simple fix, exclude /usr/bin since it's not a real path. 34187 if test "x`$ECHO $input_to_shortpath | $GREP ^/usr/bin/`" = x; then 34188 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 34189 # a path prefixed by /cygdrive for fixpath to work. 34190 new_path="$CYGWIN_ROOT_PATH$input_path" 34191 fi 34192 fi 34193 34194 # remove trailing .exe if any 34195 new_path="${new_path/%.exe/}" 34196 34197 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 34198 34199 # First separate the path from the arguments. This will split at the first 34200 # space. 34201 complete="$CC" 34202 path="${complete%% *}" 34203 tmp="$complete EOL" 34204 arguments="${tmp#* }" 34205 34206 # Input might be given as Windows format, start by converting to 34207 # unix format. 34208 new_path="$path" 34209 34210 windows_path="$new_path" 34211 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 34212 unix_path=`$CYGPATH -u "$windows_path"` 34213 new_path="$unix_path" 34214 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 34215 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 34216 new_path="$unix_path" 34217 fi 34218 34219 34220 # Now try to locate executable using which 34221 new_path=`$WHICH "$new_path" 2> /dev/null` 34222 34223 if test "x$new_path" = x; then 34224 # Oops. Which didn't find the executable. 34225 # The splitting of arguments from the executable at a space might have been incorrect, 34226 # since paths with space are more likely in Windows. Give it another try with the whole 34227 # argument. 34228 path="$complete" 34229 arguments="EOL" 34230 new_path="$path" 34231 34232 windows_path="$new_path" 34233 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 34234 unix_path=`$CYGPATH -u "$windows_path"` 34235 new_path="$unix_path" 34236 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 34237 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 34238 new_path="$unix_path" 34239 fi 34240 34241 34242 new_path=`$WHICH "$new_path" 2> /dev/null` 34243 # bat and cmd files are not always considered executable in MSYS causing which 34244 # to not find them 34245 if test "x$new_path" = x \ 34246 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 34247 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 34248 new_path="$path" 34249 34250 windows_path="$new_path" 34251 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 34252 unix_path=`$CYGPATH -u "$windows_path"` 34253 new_path="$unix_path" 34254 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 34255 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 34256 new_path="$unix_path" 34257 fi 34258 34259 fi 34260 34261 if test "x$new_path" = x; then 34262 # It's still not found. Now this is an unrecoverable error. 34263 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of CC, which resolves as \"$complete\", is not found." >&5 34264 $as_echo "$as_me: The path of CC, which resolves as \"$complete\", is not found." >&6;} 34265 has_space=`$ECHO "$complete" | $GREP " "` 34266 if test "x$has_space" != x; then 34267 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 34268 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 34269 fi 34270 as_fn_error $? "Cannot locate the the path of CC" "$LINENO" 5 34271 fi 34272 fi 34273 34274 # Now new_path has a complete unix path to the binary 34275 if test "x`$ECHO $new_path | $GREP ^/bin/`" != x; then 34276 # Keep paths in /bin as-is, but remove trailing .exe if any 34277 new_path="${new_path/%.exe/}" 34278 # Do not save /bin paths to all_fixpath_prefixes! 34279 else 34280 # Not in mixed or Windows style, start by that. 34281 new_path=`cmd //c echo $new_path` 34282 34283 input_path="$new_path" 34284 # Check if we need to convert this using DOS-style short mode. If the path 34285 # contains just simple characters, use it. Otherwise (spaces, weird characters), 34286 # take no chances and rewrite it. 34287 # Note: m4 eats our [], so we need to use [ and ] instead. 34288 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 34289 if test "x$has_forbidden_chars" != x; then 34290 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 34291 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 34292 fi 34293 34294 # Output is in $new_path 34295 34296 windows_path="$new_path" 34297 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 34298 unix_path=`$CYGPATH -u "$windows_path"` 34299 new_path="$unix_path" 34300 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 34301 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 34302 new_path="$unix_path" 34303 fi 34304 34305 # remove trailing .exe if any 34306 new_path="${new_path/%.exe/}" 34307 34308 # Save the first 10 bytes of this path to the storage, so fixpath can work. 34309 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 34310 fi 34311 34312 else 34313 # We're on a unix platform. Hooray! :) 34314 # First separate the path from the arguments. This will split at the first 34315 # space. 34316 complete="$CC" 34317 path="${complete%% *}" 34318 tmp="$complete EOL" 34319 arguments="${tmp#* }" 34320 34321 # Cannot rely on the command "which" here since it doesn't always work. 34322 is_absolute_path=`$ECHO "$path" | $GREP ^/` 34323 if test -z "$is_absolute_path"; then 34324 # Path to executable is not absolute. Find it. 34325 IFS_save="$IFS" 34326 IFS=: 34327 for p in $PATH; do 34328 if test -f "$p/$path" && test -x "$p/$path"; then 34329 new_path="$p/$path" 34330 break 34331 fi 34332 done 34333 IFS="$IFS_save" 34334 else 34335 # This is an absolute path, we can use it without further modifications. 34336 new_path="$path" 34337 fi 34338 34339 if test "x$new_path" = x; then 34340 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of CC, which resolves as \"$complete\", is not found." >&5 34341 $as_echo "$as_me: The path of CC, which resolves as \"$complete\", is not found." >&6;} 34342 has_space=`$ECHO "$complete" | $GREP " "` 34343 if test "x$has_space" != x; then 34344 { $as_echo "$as_me:${as_lineno-$LINENO}: This might be caused by spaces in the path, which is not allowed." >&5 34345 $as_echo "$as_me: This might be caused by spaces in the path, which is not allowed." >&6;} 34346 fi 34347 as_fn_error $? "Cannot locate the the path of CC" "$LINENO" 5 34348 fi 34349 fi 34350 34351 # Now join together the path and the arguments once again 34352 if test "x$arguments" != xEOL; then 34353 new_complete="$new_path ${arguments% *}" 34354 else 34355 new_complete="$new_path" 34356 fi 34357 34358 if test "x$complete" != "x$new_complete"; then 34359 CC="$new_complete" 34360 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting CC to \"$new_complete\"" >&5 34361 $as_echo "$as_me: Rewriting CC to \"$new_complete\"" >&6;} 34362 fi 34363 fi 34364 34365 TEST_COMPILER="$CC" 34366 34367 { $as_echo "$as_me:${as_lineno-$LINENO}: checking resolved symbolic links for CC" >&5 34368 $as_echo_n "checking resolved symbolic links for CC... " >&6; } 34369 SYMLINK_ORIGINAL="$TEST_COMPILER" 34370 34371 if test "x$OPENJDK_BUILD_OS" != xwindows; then 34372 # Follow a chain of symbolic links. Use readlink 34373 # where it exists, else fall back to horribly 34374 # complicated shell code. 34375 if test "x$READLINK_TESTED" != yes; then 34376 # On MacOSX there is a readlink tool with a different 34377 # purpose than the GNU readlink tool. Check the found readlink. 34378 ISGNU=`$READLINK --version 2>&1 | $GREP GNU` 34379 if test "x$ISGNU" = x; then 34380 # A readlink that we do not know how to use. 34381 # Are there other non-GNU readlinks out there? 34382 READLINK_TESTED=yes 34383 READLINK= 34384 fi 34385 fi 34386 34387 if test "x$READLINK" != x; then 34388 SYMLINK_ORIGINAL=`$READLINK -f $SYMLINK_ORIGINAL` 34389 else 34390 # Save the current directory for restoring afterwards 34391 STARTDIR=$PWD 34392 COUNTER=0 34393 sym_link_dir=`$DIRNAME $SYMLINK_ORIGINAL` 34394 sym_link_file=`$BASENAME $SYMLINK_ORIGINAL` 34395 cd $sym_link_dir 34396 # Use -P flag to resolve symlinks in directories. 34397 cd `$THEPWDCMD -P` 34398 sym_link_dir=`$THEPWDCMD -P` 34399 # Resolve file symlinks 34400 while test $COUNTER -lt 20; do 34401 ISLINK=`$LS -l $sym_link_dir/$sym_link_file | $GREP '\->' | $SED -e 's/.*-> \(.*\)/\1/'` 34402 if test "x$ISLINK" == x; then 34403 # This is not a symbolic link! We are done! 34404 break 34405 fi 34406 # Again resolve directory symlinks since the target of the just found 34407 # link could be in a different directory 34408 cd `$DIRNAME $ISLINK` 34409 sym_link_dir=`$THEPWDCMD -P` 34410 sym_link_file=`$BASENAME $ISLINK` 34411 let COUNTER=COUNTER+1 34412 done 34413 cd $STARTDIR 34414 SYMLINK_ORIGINAL=$sym_link_dir/$sym_link_file 34415 fi 34416 fi 34417 34418 if test "x$TEST_COMPILER" = "x$SYMLINK_ORIGINAL"; then 34419 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no symlink" >&5 34420 $as_echo "no symlink" >&6; } 34421 else 34422 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $SYMLINK_ORIGINAL" >&5 34423 $as_echo "$SYMLINK_ORIGINAL" >&6; } 34424 34425 # We can't handle ccache by gcc wrappers, since we need to know if we're 34426 # using ccache. Instead ccache usage must be controlled by a configure option. 34427 COMPILER_BASENAME=`$BASENAME "$SYMLINK_ORIGINAL"` 34428 if test "x$COMPILER_BASENAME" = "xccache"; then 34429 { $as_echo "$as_me:${as_lineno-$LINENO}: Please use --enable-ccache instead of providing a wrapped compiler." >&5 34430 $as_echo "$as_me: Please use --enable-ccache instead of providing a wrapped compiler." >&6;} 34431 as_fn_error $? "$TEST_COMPILER is a symbolic link to ccache. This is not supported." "$LINENO" 5 34432 fi 34433 fi 34434 34435 34436 COMPILER=$CC 34437 COMPILER_NAME=$COMPILER_NAME 34438 34439 if test "x$TOOLCHAIN_TYPE" = xsolstudio; then 34440 # cc -V output typically looks like 34441 # cc: Sun C 5.12 Linux_i386 2011/11/16 34442 # or 34443 # cc: Studio 12.5 Sun C 5.14 SunOS_sparc 2016/05/31 34444 COMPILER_VERSION_OUTPUT=`$COMPILER -V 2>&1` 34445 # Check that this is likely to be the Solaris Studio cc. 34446 $ECHO "$COMPILER_VERSION_OUTPUT" | $GREP "^.* Sun $COMPILER_NAME" > /dev/null 34447 if test $? -ne 0; then 34448 ALT_VERSION_OUTPUT=`$COMPILER --version 2>&1` 34449 { $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 34450 $as_echo "$as_me: The $COMPILER_NAME compiler (located as $COMPILER) does not seem to be the required $TOOLCHAIN_TYPE compiler." >&6;} 34451 { $as_echo "$as_me:${as_lineno-$LINENO}: The result from running with -V was: \"$COMPILER_VERSION_OUTPUT\"" >&5 34452 $as_echo "$as_me: The result from running with -V was: \"$COMPILER_VERSION_OUTPUT\"" >&6;} 34453 { $as_echo "$as_me:${as_lineno-$LINENO}: The result from running with --version was: \"$ALT_VERSION_OUTPUT\"" >&5 34454 $as_echo "$as_me: The result from running with --version was: \"$ALT_VERSION_OUTPUT\"" >&6;} 34455 as_fn_error $? "A $TOOLCHAIN_TYPE compiler is required. Try setting --with-tools-dir." "$LINENO" 5 34456 fi 34457 # Remove usage instructions (if present), and 34458 # collapse compiler output into a single line 34459 COMPILER_VERSION_STRING=`$ECHO $COMPILER_VERSION_OUTPUT | \ 34460 $SED -e 's/ *[Uu]sage:.*//'` 34461 COMPILER_VERSION_NUMBER=`$ECHO $COMPILER_VERSION_OUTPUT | \ 34462 $SED -e "s/^.*[ ,\t]$COMPILER_NAME[ ,\t]\([1-9]\.[0-9][0-9]*\).*/\1/"` 34463 elif test "x$TOOLCHAIN_TYPE" = xxlc; then 34464 # xlc -qversion output typically looks like 34465 # IBM XL C/C++ for AIX, V11.1 (5724-X13) 34466 # Version: 11.01.0000.0015 34467 COMPILER_VERSION_OUTPUT=`$COMPILER -qversion 2>&1` 34468 # Check that this is likely to be the IBM XL C compiler. 34469 $ECHO "$COMPILER_VERSION_OUTPUT" | $GREP "IBM XL C" > /dev/null 34470 if test $? -ne 0; then 34471 ALT_VERSION_OUTPUT=`$COMPILER --version 2>&1` 34472 { $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 34473 $as_echo "$as_me: The $COMPILER_NAME compiler (located as $COMPILER) does not seem to be the required $TOOLCHAIN_TYPE compiler." >&6;} 34474 { $as_echo "$as_me:${as_lineno-$LINENO}: The result from running with -qversion was: \"$COMPILER_VERSION_OUTPUT\"" >&5 34475 $as_echo "$as_me: The result from running with -qversion was: \"$COMPILER_VERSION_OUTPUT\"" >&6;} 34476 { $as_echo "$as_me:${as_lineno-$LINENO}: The result from running with --version was: \"$ALT_VERSION_OUTPUT\"" >&5 34477 $as_echo "$as_me: The result from running with --version was: \"$ALT_VERSION_OUTPUT\"" >&6;} 34478 as_fn_error $? "A $TOOLCHAIN_TYPE compiler is required. Try setting --with-tools-dir." "$LINENO" 5 34479 fi 34480 # Collapse compiler output into a single line 34481 COMPILER_VERSION_STRING=`$ECHO $COMPILER_VERSION_OUTPUT` 34482 COMPILER_VERSION_NUMBER=`$ECHO $COMPILER_VERSION_OUTPUT | \ 34483 $SED -e 's/^.*, V\([1-9][0-9.]*\).*$/\1/'` 34484 elif test "x$TOOLCHAIN_TYPE" = xmicrosoft; then 34485 # There is no specific version flag, but all output starts with a version string. 34486 # First line typically looks something like: 34487 # Microsoft (R) 32-bit C/C++ Optimizing Compiler Version 16.00.40219.01 for 80x86 34488 COMPILER_VERSION_OUTPUT=`$COMPILER 2>&1 | $HEAD -n 1 | $TR -d '\r'` 34489 # Check that this is likely to be Microsoft CL.EXE. 34490 $ECHO "$COMPILER_VERSION_OUTPUT" | $GREP "Microsoft.*Compiler" > /dev/null 34491 if test $? -ne 0; then 34492 { $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 34493 $as_echo "$as_me: The $COMPILER_NAME compiler (located as $COMPILER) does not seem to be the required $TOOLCHAIN_TYPE compiler." >&6;} 34494 { $as_echo "$as_me:${as_lineno-$LINENO}: The result from running it was: \"$COMPILER_VERSION_OUTPUT\"" >&5 34495 $as_echo "$as_me: The result from running it was: \"$COMPILER_VERSION_OUTPUT\"" >&6;} 34496 as_fn_error $? "A $TOOLCHAIN_TYPE compiler is required. Try setting --with-tools-dir." "$LINENO" 5 34497 fi 34498 # Collapse compiler output into a single line 34499 COMPILER_VERSION_STRING=`$ECHO $COMPILER_VERSION_OUTPUT` 34500 COMPILER_VERSION_NUMBER=`$ECHO $COMPILER_VERSION_OUTPUT | \ 34501 $SED -e 's/^.*ersion.\([1-9][0-9.]*\) .*$/\1/'` 34502 elif test "x$TOOLCHAIN_TYPE" = xgcc; then 34503 # gcc --version output typically looks like 34504 # gcc (Ubuntu/Linaro 4.8.1-10ubuntu9) 4.8.1 34505 # Copyright (C) 2013 Free Software Foundation, Inc. 34506 # This is free software; see the source for copying conditions. There is NO 34507 # warranty; not even for MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. 34508 COMPILER_VERSION_OUTPUT=`$COMPILER --version 2>&1` 34509 # Check that this is likely to be GCC. 34510 $ECHO "$COMPILER_VERSION_OUTPUT" | $GREP "Free Software Foundation" > /dev/null 34511 if test $? -ne 0; then 34512 { $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 34513 $as_echo "$as_me: The $COMPILER_NAME compiler (located as $COMPILER) does not seem to be the required $TOOLCHAIN_TYPE compiler." >&6;} 34514 { $as_echo "$as_me:${as_lineno-$LINENO}: The result from running with --version was: \"$COMPILER_VERSION\"" >&5 34515 $as_echo "$as_me: The result from running with --version was: \"$COMPILER_VERSION\"" >&6;} 34516 as_fn_error $? "A $TOOLCHAIN_TYPE compiler is required. Try setting --with-tools-dir." "$LINENO" 5 34517 fi 34518 # Remove Copyright and legalese from version string, and 34519 # collapse into a single line 34520 COMPILER_VERSION_STRING=`$ECHO $COMPILER_VERSION_OUTPUT | \ 34521 $SED -e 's/ *Copyright .*//'` 34522 COMPILER_VERSION_NUMBER=`$ECHO $COMPILER_VERSION_OUTPUT | \ 34523 $SED -e 's/^.* \([1-9]\.[0-9.]*\)[^0-9.].*$/\1/'` 34524 elif test "x$TOOLCHAIN_TYPE" = xclang; then 34525 # clang --version output typically looks like 34526 # Apple LLVM version 5.0 (clang-500.2.79) (based on LLVM 3.3svn) 34527 # clang version 3.3 (tags/RELEASE_33/final) 34528 # or 34529 # Debian clang version 3.2-7ubuntu1 (tags/RELEASE_32/final) (based on LLVM 3.2) 34530 # Target: x86_64-pc-linux-gnu 34531 # Thread model: posix 34532 COMPILER_VERSION_OUTPUT=`$COMPILER --version 2>&1` 34533 # Check that this is likely to be clang 34534 $ECHO "$COMPILER_VERSION_OUTPUT" | $GREP "clang" > /dev/null 34535 if test $? -ne 0; then 34536 { $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 34537 $as_echo "$as_me: The $COMPILER_NAME compiler (located as $COMPILER) does not seem to be the required $TOOLCHAIN_TYPE compiler." >&6;} 34538 { $as_echo "$as_me:${as_lineno-$LINENO}: The result from running with --version was: \"$COMPILER_VERSION_OUTPUT\"" >&5 34539 $as_echo "$as_me: The result from running with --version was: \"$COMPILER_VERSION_OUTPUT\"" >&6;} 34540 as_fn_error $? "A $TOOLCHAIN_TYPE compiler is required. Try setting --with-tools-dir." "$LINENO" 5 34541 fi 34542 # Collapse compiler output into a single line 34543 COMPILER_VERSION_STRING=`$ECHO $COMPILER_VERSION_OUTPUT` 34544 COMPILER_VERSION_NUMBER=`$ECHO $COMPILER_VERSION_OUTPUT | \ 34545 $SED -e 's/^.* version \([1-9][0-9.]*\).*$/\1/'` 34546 else 34547 as_fn_error $? "Unknown toolchain type $TOOLCHAIN_TYPE." "$LINENO" 5 34548 fi 34549 # This sets CC_VERSION_NUMBER or CXX_VERSION_NUMBER. (This comment is a grep marker) 34550 CC_VERSION_NUMBER="$COMPILER_VERSION_NUMBER" 34551 # This sets CC_VERSION_STRING or CXX_VERSION_STRING. (This comment is a grep marker) 34552 CC_VERSION_STRING="$COMPILER_VERSION_STRING" 34553 34554 { $as_echo "$as_me:${as_lineno-$LINENO}: Using $TOOLCHAIN_TYPE $COMPILER_NAME compiler version $COMPILER_VERSION_NUMBER [$COMPILER_VERSION_STRING]" >&5 34555 $as_echo "$as_me: Using $TOOLCHAIN_TYPE $COMPILER_NAME compiler version $COMPILER_VERSION_NUMBER [$COMPILER_VERSION_STRING]" >&6;} 34556 34557 34558 # Now that we have resolved CC ourself, let autoconf have its go at it 34559 ac_ext=c 34560 ac_cpp='$CPP $CPPFLAGS' 34561 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5' 34562 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' 34563 ac_compiler_gnu=$ac_cv_c_compiler_gnu 34564 if test -n "$ac_tool_prefix"; then 34565 for ac_prog in $CC 34566 do 34567 # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args. 34568 set dummy $ac_tool_prefix$ac_prog; ac_word=$2 34569 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 34570 $as_echo_n "checking for $ac_word... " >&6; } 34571 if ${ac_cv_prog_CC+:} false; then : 34572 $as_echo_n "(cached) " >&6 34573 else 34574 if test -n "$CC"; then 34575 ac_cv_prog_CC="$CC" # Let the user override the test. 34576 else 34577 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 34578 for as_dir in $PATH 34579 do 34580 IFS=$as_save_IFS 34581 test -z "$as_dir" && as_dir=. 34582 for ac_exec_ext in '' $ac_executable_extensions; do 34583 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 34584 ac_cv_prog_CC="$ac_tool_prefix$ac_prog" 34585 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 34586 break 2 34587 fi 34588 done 34589 done 34590 IFS=$as_save_IFS 34591 34592 fi 34593 fi 34594 CC=$ac_cv_prog_CC 34595 if test -n "$CC"; then 34596 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CC" >&5 34597 $as_echo "$CC" >&6; } 34598 else 34599 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 34600 $as_echo "no" >&6; } 34601 fi 34602 34603 34604 test -n "$CC" && break 34605 done 34606 fi 34607 if test -z "$CC"; then 34608 ac_ct_CC=$CC 34609 for ac_prog in $CC 34610 do 34611 # Extract the first word of "$ac_prog", so it can be a program name with args. 34612 set dummy $ac_prog; ac_word=$2 34613 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 34614 $as_echo_n "checking for $ac_word... " >&6; } 34615 if ${ac_cv_prog_ac_ct_CC+:} false; then : 34616 $as_echo_n "(cached) " >&6 34617 else 34618 if test -n "$ac_ct_CC"; then 34619 ac_cv_prog_ac_ct_CC="$ac_ct_CC" # Let the user override the test. 34620 else 34621 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 34622 for as_dir in $PATH 34623 do 34624 IFS=$as_save_IFS 34625 test -z "$as_dir" && as_dir=. 34626 for ac_exec_ext in '' $ac_executable_extensions; do 34627 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 34628 ac_cv_prog_ac_ct_CC="$ac_prog" 34629 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 34630 break 2 34631 fi 34632 done 34633 done 34634 IFS=$as_save_IFS 34635 34636 fi 34637 fi 34638 ac_ct_CC=$ac_cv_prog_ac_ct_CC 34639 if test -n "$ac_ct_CC"; then 34640 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_CC" >&5 34641 $as_echo "$ac_ct_CC" >&6; } 34642 else 34643 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 34644 $as_echo "no" >&6; } 34645 fi 34646 34647 34648 test -n "$ac_ct_CC" && break 34649 done 34650 34651 if test "x$ac_ct_CC" = x; then 34652 CC="" 34653 else 34654 case $cross_compiling:$ac_tool_warned in 34655 yes:) 34656 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5 34657 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;} 34658 ac_tool_warned=yes ;; 34659 esac 34660 CC=$ac_ct_CC 34661 fi 34662 fi 34663 34664 34665 test -z "$CC" && { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 34666 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;} 34667 as_fn_error $? "no acceptable C compiler found in \$PATH 34668 See \`config.log' for more details" "$LINENO" 5; } 34669 34670 # Provide some information about the compiler. 34671 $as_echo "$as_me:${as_lineno-$LINENO}: checking for C compiler version" >&5 34672 set X $ac_compile 34673 ac_compiler=$2 34674 for ac_option in --version -v -V -qversion; do 34675 { { ac_try="$ac_compiler $ac_option >&5" 34676 case "(($ac_try" in 34677 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; 34678 *) ac_try_echo=$ac_try;; 34679 esac 34680 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\"" 34681 $as_echo "$ac_try_echo"; } >&5 34682 (eval "$ac_compiler $ac_option >&5") 2>conftest.err 34683 ac_status=$? 34684 if test -s conftest.err; then 34685 sed '10a\ 34686 ... rest of stderr output deleted ... 34687 10q' conftest.err >conftest.er1 34688 cat conftest.er1 >&5 34689 fi 34690 rm -f conftest.er1 conftest.err 34691 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 34692 test $ac_status = 0; } 34693 done 34694 34695 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 34696 /* end confdefs.h. */ 34697 34698 int 34699 main () 34700 { 34701 34702 ; 34703 return 0; 34704 } 34705 _ACEOF 34706 ac_clean_files_save=$ac_clean_files 34707 ac_clean_files="$ac_clean_files a.out a.out.dSYM a.exe b.out" 34708 # Try to create an executable without -o first, disregard a.out. 34709 # It will help us diagnose broken compilers, and finding out an intuition 34710 # of exeext. 34711 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether the C compiler works" >&5 34712 $as_echo_n "checking whether the C compiler works... " >&6; } 34713 ac_link_default=`$as_echo "$ac_link" | sed 's/ -o *conftest[^ ]*//'` 34714 34715 # The possible output files: 34716 ac_files="a.out conftest.exe conftest a.exe a_out.exe b.out conftest.*" 34717 34718 ac_rmfiles= 34719 for ac_file in $ac_files 34720 do 34721 case $ac_file in 34722 *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.dSYM | *.o | *.obj ) ;; 34723 * ) ac_rmfiles="$ac_rmfiles $ac_file";; 34724 esac 34725 done 34726 rm -f $ac_rmfiles 34727 34728 if { { ac_try="$ac_link_default" 34729 case "(($ac_try" in 34730 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; 34731 *) ac_try_echo=$ac_try;; 34732 esac 34733 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\"" 34734 $as_echo "$ac_try_echo"; } >&5 34735 (eval "$ac_link_default") 2>&5 34736 ac_status=$? 34737 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 34738 test $ac_status = 0; }; then : 34739 # Autoconf-2.13 could set the ac_cv_exeext variable to `no'. 34740 # So ignore a value of `no', otherwise this would lead to `EXEEXT = no' 34741 # in a Makefile. We should not override ac_cv_exeext if it was cached, 34742 # so that the user can short-circuit this test for compilers unknown to 34743 # Autoconf. 34744 for ac_file in $ac_files '' 34745 do 34746 test -f "$ac_file" || continue 34747 case $ac_file in 34748 *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.dSYM | *.o | *.obj ) 34749 ;; 34750 [ab].out ) 34751 # We found the default executable, but exeext='' is most 34752 # certainly right. 34753 break;; 34754 *.* ) 34755 if test "${ac_cv_exeext+set}" = set && test "$ac_cv_exeext" != no; 34756 then :; else 34757 ac_cv_exeext=`expr "$ac_file" : '[^.]*\(\..*\)'` 34758 fi 34759 # We set ac_cv_exeext here because the later test for it is not 34760 # safe: cross compilers may not add the suffix if given an `-o' 34761 # argument, so we may need to know it at that point already. 34762 # Even if this section looks crufty: it has the advantage of 34763 # actually working. 34764 break;; 34765 * ) 34766 break;; 34767 esac 34768 done 34769 test "$ac_cv_exeext" = no && ac_cv_exeext= 34770 34771 else 34772 ac_file='' 34773 fi 34774 if test -z "$ac_file"; then : 34775 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 34776 $as_echo "no" >&6; } 34777 $as_echo "$as_me: failed program was:" >&5 34778 sed 's/^/| /' conftest.$ac_ext >&5 34779 34780 { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 34781 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;} 34782 as_fn_error 77 "C compiler cannot create executables 34783 See \`config.log' for more details" "$LINENO" 5; } 34784 else 34785 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 34786 $as_echo "yes" >&6; } 34787 fi 34788 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for C compiler default output file name" >&5 34789 $as_echo_n "checking for C compiler default output file name... " >&6; } 34790 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_file" >&5 34791 $as_echo "$ac_file" >&6; } 34792 ac_exeext=$ac_cv_exeext 34793 34794 rm -f -r a.out a.out.dSYM a.exe conftest$ac_cv_exeext b.out 34795 ac_clean_files=$ac_clean_files_save 34796 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for suffix of executables" >&5 34797 $as_echo_n "checking for suffix of executables... " >&6; } 34798 if { { ac_try="$ac_link" 34799 case "(($ac_try" in 34800 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; 34801 *) ac_try_echo=$ac_try;; 34802 esac 34803 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\"" 34804 $as_echo "$ac_try_echo"; } >&5 34805 (eval "$ac_link") 2>&5 34806 ac_status=$? 34807 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 34808 test $ac_status = 0; }; then : 34809 # If both `conftest.exe' and `conftest' are `present' (well, observable) 34810 # catch `conftest.exe'. For instance with Cygwin, `ls conftest' will 34811 # work properly (i.e., refer to `conftest.exe'), while it won't with 34812 # `rm'. 34813 for ac_file in conftest.exe conftest conftest.*; do 34814 test -f "$ac_file" || continue 34815 case $ac_file in 34816 *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.dSYM | *.o | *.obj ) ;; 34817 *.* ) ac_cv_exeext=`expr "$ac_file" : '[^.]*\(\..*\)'` 34818 break;; 34819 * ) break;; 34820 esac 34821 done 34822 else 34823 { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 34824 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;} 34825 as_fn_error $? "cannot compute suffix of executables: cannot compile and link 34826 See \`config.log' for more details" "$LINENO" 5; } 34827 fi 34828 rm -f conftest conftest$ac_cv_exeext 34829 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_exeext" >&5 34830 $as_echo "$ac_cv_exeext" >&6; } 34831 34832 rm -f conftest.$ac_ext 34833 EXEEXT=$ac_cv_exeext 34834 ac_exeext=$EXEEXT 34835 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 34836 /* end confdefs.h. */ 34837 #include <stdio.h> 34838 int 34839 main () 34840 { 34841 FILE *f = fopen ("conftest.out", "w"); 34842 return ferror (f) || fclose (f) != 0; 34843 34844 ; 34845 return 0; 34846 } 34847 _ACEOF 34848 ac_clean_files="$ac_clean_files conftest.out" 34849 # Check that the compiler produces executables we can run. If not, either 34850 # the compiler is broken, or we cross compile. 34851 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether we are cross compiling" >&5 34852 $as_echo_n "checking whether we are cross compiling... " >&6; } 34853 if test "$cross_compiling" != yes; then 34854 { { ac_try="$ac_link" 34855 case "(($ac_try" in 34856 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; 34857 *) ac_try_echo=$ac_try;; 34858 esac 34859 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\"" 34860 $as_echo "$ac_try_echo"; } >&5 34861 (eval "$ac_link") 2>&5 34862 ac_status=$? 34863 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 34864 test $ac_status = 0; } 34865 if { ac_try='./conftest$ac_cv_exeext' 34866 { { case "(($ac_try" in 34867 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; 34868 *) ac_try_echo=$ac_try;; 34869 esac 34870 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\"" 34871 $as_echo "$ac_try_echo"; } >&5 34872 (eval "$ac_try") 2>&5 34873 ac_status=$? 34874 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 34875 test $ac_status = 0; }; }; then 34876 cross_compiling=no 34877 else 34878 if test "$cross_compiling" = maybe; then 34879 cross_compiling=yes 34880 else 34881 { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 34882 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;} 34883 as_fn_error $? "cannot run C compiled programs. 34884 If you meant to cross compile, use \`--host'. 34885 See \`config.log' for more details" "$LINENO" 5; } 34886 fi 34887 fi 34888 fi 34889 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $cross_compiling" >&5 34890 $as_echo "$cross_compiling" >&6; } 34891 34892 rm -f conftest.$ac_ext conftest$ac_cv_exeext conftest.out 34893 ac_clean_files=$ac_clean_files_save 34894 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for suffix of object files" >&5 34895 $as_echo_n "checking for suffix of object files... " >&6; } 34896 if ${ac_cv_objext+:} false; then : 34897 $as_echo_n "(cached) " >&6 34898 else 34899 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 34900 /* end confdefs.h. */ 34901 34902 int 34903 main () 34904 { 34905 34906 ; 34907 return 0; 34908 } 34909 _ACEOF 34910 rm -f conftest.o conftest.obj 34911 if { { ac_try="$ac_compile" 34912 case "(($ac_try" in 34913 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; 34914 *) ac_try_echo=$ac_try;; 34915 esac 34916 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\"" 34917 $as_echo "$ac_try_echo"; } >&5 34918 (eval "$ac_compile") 2>&5 34919 ac_status=$? 34920 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 34921 test $ac_status = 0; }; then : 34922 for ac_file in conftest.o conftest.obj conftest.*; do 34923 test -f "$ac_file" || continue; 34924 case $ac_file in 34925 *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.dSYM ) ;; 34926 *) ac_cv_objext=`expr "$ac_file" : '.*\.\(.*\)'` 34927 break;; 34928 esac 34929 done 34930 else 34931 $as_echo "$as_me: failed program was:" >&5 34932 sed 's/^/| /' conftest.$ac_ext >&5 34933 34934 { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 34935 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;} 34936 as_fn_error $? "cannot compute suffix of object files: cannot compile 34937 See \`config.log' for more details" "$LINENO" 5; } 34938 fi 34939 rm -f conftest.$ac_cv_objext conftest.$ac_ext 34940 fi 34941 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_objext" >&5 34942 $as_echo "$ac_cv_objext" >&6; } 34943 OBJEXT=$ac_cv_objext 34944 ac_objext=$OBJEXT 34945 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether we are using the GNU C compiler" >&5 34946 $as_echo_n "checking whether we are using the GNU C compiler... " >&6; } 34947 if ${ac_cv_c_compiler_gnu+:} false; then : 34948 $as_echo_n "(cached) " >&6 34949 else 34950 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 34951 /* end confdefs.h. */ 34952 34953 int 34954 main () 34955 { 34956 #ifndef __GNUC__ 34957 choke me 34958 #endif 34959 34960 ; 34961 return 0; 34962 } 34963 _ACEOF 34964 if ac_fn_c_try_compile "$LINENO"; then : 34965 ac_compiler_gnu=yes 34966 else 34967 ac_compiler_gnu=no 34968 fi 34969 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext 34970 ac_cv_c_compiler_gnu=$ac_compiler_gnu 34971 34972 fi 34973 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_c_compiler_gnu" >&5 34974 $as_echo "$ac_cv_c_compiler_gnu" >&6; } 34975 if test $ac_compiler_gnu = yes; then 34976 GCC=yes 34977 else 34978 GCC= 34979 fi 34980 ac_test_CFLAGS=${CFLAGS+set} 34981 ac_save_CFLAGS=$CFLAGS 34982 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $CC accepts -g" >&5 34983 $as_echo_n "checking whether $CC accepts -g... " >&6; } 34984 if ${ac_cv_prog_cc_g+:} false; then : 34985 $as_echo_n "(cached) " >&6 34986 else 34987 ac_save_c_werror_flag=$ac_c_werror_flag 34988 ac_c_werror_flag=yes 34989 ac_cv_prog_cc_g=no 34990 CFLAGS="-g" 34991 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 34992 /* end confdefs.h. */ 34993 34994 int 34995 main () 34996 { 34997 34998 ; 34999 return 0; 35000 } 35001 _ACEOF 35002 if ac_fn_c_try_compile "$LINENO"; then : 35003 ac_cv_prog_cc_g=yes 35004 else 35005 CFLAGS="" 35006 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 35007 /* end confdefs.h. */ 35008 35009 int 35010 main () 35011 { 35012 35013 ; 35014 return 0; 35015 } 35016 _ACEOF 35017 if ac_fn_c_try_compile "$LINENO"; then : 35018 35019 else 35020 ac_c_werror_flag=$ac_save_c_werror_flag 35021 CFLAGS="-g" 35022 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 35023 /* end confdefs.h. */ 35024 35025 int 35026 main () 35027 { 35028 35029 ; 35030 return 0; 35031 } 35032 _ACEOF 35033 if ac_fn_c_try_compile "$LINENO"; then : 35034 ac_cv_prog_cc_g=yes 35035 fi 35036 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext 35037 fi 35038 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext 35039 fi 35040 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext 35041 ac_c_werror_flag=$ac_save_c_werror_flag 35042 fi 35043 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_prog_cc_g" >&5 35044 $as_echo "$ac_cv_prog_cc_g" >&6; } 35045 if test "$ac_test_CFLAGS" = set; then 35046 CFLAGS=$ac_save_CFLAGS 35047 elif test $ac_cv_prog_cc_g = yes; then 35048 if test "$GCC" = yes; then 35049 CFLAGS="-g -O2" 35050 else 35051 CFLAGS="-g" 35052 fi 35053 else 35054 if test "$GCC" = yes; then 35055 CFLAGS="-O2" 35056 else 35057 CFLAGS= 35058 fi 35059 fi 35060 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $CC option to accept ISO C89" >&5 35061 $as_echo_n "checking for $CC option to accept ISO C89... " >&6; } 35062 if ${ac_cv_prog_cc_c89+:} false; then : 35063 $as_echo_n "(cached) " >&6 35064 else 35065 ac_cv_prog_cc_c89=no 35066 ac_save_CC=$CC 35067 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 35068 /* end confdefs.h. */ 35069 #include <stdarg.h> 35070 #include <stdio.h> 35071 struct stat; 35072 /* Most of the following tests are stolen from RCS 5.7's src/conf.sh. */ 35073 struct buf { int x; }; 35074 FILE * (*rcsopen) (struct buf *, struct stat *, int); 35075 static char *e (p, i) 35076 char **p; 35077 int i; 35078 { 35079 return p[i]; 35080 } 35081 static char *f (char * (*g) (char **, int), char **p, ...) 35082 { 35083 char *s; 35084 va_list v; 35085 va_start (v,p); 35086 s = g (p, va_arg (v,int)); 35087 va_end (v); 35088 return s; 35089 } 35090 35091 /* OSF 4.0 Compaq cc is some sort of almost-ANSI by default. It has 35092 function prototypes and stuff, but not '\xHH' hex character constants. 35093 These don't provoke an error unfortunately, instead are silently treated 35094 as 'x'. The following induces an error, until -std is added to get 35095 proper ANSI mode. Curiously '\x00'!='x' always comes out true, for an 35096 array size at least. It's necessary to write '\x00'==0 to get something 35097 that's true only with -std. */ 35098 int osf4_cc_array ['\x00' == 0 ? 1 : -1]; 35099 35100 /* IBM C 6 for AIX is almost-ANSI by default, but it replaces macro parameters 35101 inside strings and character constants. */ 35102 #define FOO(x) 'x' 35103 int xlc6_cc_array[FOO(a) == 'x' ? 1 : -1]; 35104 35105 int test (int i, double x); 35106 struct s1 {int (*f) (int a);}; 35107 struct s2 {int (*f) (double a);}; 35108 int pairnames (int, char **, FILE *(*)(struct buf *, struct stat *, int), int, int); 35109 int argc; 35110 char **argv; 35111 int 35112 main () 35113 { 35114 return f (e, argv, 0) != argv[0] || f (e, argv, 1) != argv[1]; 35115 ; 35116 return 0; 35117 } 35118 _ACEOF 35119 for ac_arg in '' -qlanglvl=extc89 -qlanglvl=ansi -std \ 35120 -Ae "-Aa -D_HPUX_SOURCE" "-Xc -D__EXTENSIONS__" 35121 do 35122 CC="$ac_save_CC $ac_arg" 35123 if ac_fn_c_try_compile "$LINENO"; then : 35124 ac_cv_prog_cc_c89=$ac_arg 35125 fi 35126 rm -f core conftest.err conftest.$ac_objext 35127 test "x$ac_cv_prog_cc_c89" != "xno" && break 35128 done 35129 rm -f conftest.$ac_ext 35130 CC=$ac_save_CC 35131 35132 fi 35133 # AC_CACHE_VAL 35134 case "x$ac_cv_prog_cc_c89" in 35135 x) 35136 { $as_echo "$as_me:${as_lineno-$LINENO}: result: none needed" >&5 35137 $as_echo "none needed" >&6; } ;; 35138 xno) 35139 { $as_echo "$as_me:${as_lineno-$LINENO}: result: unsupported" >&5 35140 $as_echo "unsupported" >&6; } ;; 35141 *) 35142 CC="$CC $ac_cv_prog_cc_c89" 35143 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_prog_cc_c89" >&5 35144 $as_echo "$ac_cv_prog_cc_c89" >&6; } ;; 35145 esac 35146 if test "x$ac_cv_prog_cc_c89" != xno; then : 35147 35148 fi 35149 35150 ac_ext=cpp 35151 ac_cpp='$CXXCPP $CPPFLAGS' 35152 ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5' 35153 ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' 35154 ac_compiler_gnu=$ac_cv_cxx_compiler_gnu 35155 35156 35157 35158 COMPILER_NAME=C++ 35159 SEARCH_LIST="$TOOLCHAIN_CXX_BINARY" 35160 35161 if test "x$CXX" != x; then 35162 # User has supplied compiler name already, always let that override. 35163 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied compiler CXX=$CXX" >&5 35164 $as_echo "$as_me: Will use user supplied compiler CXX=$CXX" >&6;} 35165 if test "x`basename $CXX`" = "x$CXX"; then 35166 # A command without a complete path is provided, search $PATH. 35167 35168 for ac_prog in $CXX 35169 do 35170 # Extract the first word of "$ac_prog", so it can be a program name with args. 35171 set dummy $ac_prog; ac_word=$2 35172 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 35173 $as_echo_n "checking for $ac_word... " >&6; } 35174 if ${ac_cv_path_POTENTIAL_CXX+:} false; then : 35175 $as_echo_n "(cached) " >&6 35176 else 35177 case $POTENTIAL_CXX in 35178 [\\/]* | ?:[\\/]*) 35179 ac_cv_path_POTENTIAL_CXX="$POTENTIAL_CXX" # Let the user override the test with a path. 35180 ;; 35181 *) 35182 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 35183 for as_dir in $PATH 35184 do 35185 IFS=$as_save_IFS 35186 test -z "$as_dir" && as_dir=. 35187 for ac_exec_ext in '' $ac_executable_extensions; do 35188 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 35189 ac_cv_path_POTENTIAL_CXX="$as_dir/$ac_word$ac_exec_ext" 35190 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 35191 break 2 35192 fi 35193 done 35194 done 35195 IFS=$as_save_IFS 35196 35197 ;; 35198 esac 35199 fi 35200 POTENTIAL_CXX=$ac_cv_path_POTENTIAL_CXX 35201 if test -n "$POTENTIAL_CXX"; then 35202 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $POTENTIAL_CXX" >&5 35203 $as_echo "$POTENTIAL_CXX" >&6; } 35204 else 35205 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 35206 $as_echo "no" >&6; } 35207 fi 35208 35209 35210 test -n "$POTENTIAL_CXX" && break 35211 done 35212 35213 if test "x$POTENTIAL_CXX" != x; then 35214 CXX=$POTENTIAL_CXX 35215 else 35216 as_fn_error $? "User supplied compiler CXX=$CXX could not be found" "$LINENO" 5 35217 fi 35218 else 35219 # Otherwise it might already be a complete path 35220 if test ! -x "$CXX"; then 35221 as_fn_error $? "User supplied compiler CXX=$CXX does not exist" "$LINENO" 5 35222 fi 35223 fi 35224 else 35225 # No user supplied value. Locate compiler ourselves. 35226 35227 # If we are cross compiling, assume cross compilation tools follows the 35228 # cross compilation standard where they are prefixed with the autoconf 35229 # standard name for the target. For example the binary 35230 # i686-sun-solaris2.10-gcc will cross compile for i686-sun-solaris2.10. 35231 # If we are not cross compiling, then the default compiler name will be 35232 # used. 35233 35234 CXX= 35235 # If TOOLCHAIN_PATH is set, check for all compiler names in there first 35236 # before checking the rest of the PATH. 35237 # FIXME: Now that we prefix the TOOLS_DIR to the PATH in the PRE_DETECTION 35238 # step, this should not be necessary. 35239 if test -n "$TOOLCHAIN_PATH"; then 35240 PATH_save="$PATH" 35241 PATH="$TOOLCHAIN_PATH" 35242 if test -n "$ac_tool_prefix"; then 35243 # Extract the first word of "${ac_tool_prefix}$SEARCH_LIST", so it can be a program name with args. 35244 set dummy ${ac_tool_prefix}$SEARCH_LIST; ac_word=$2 35245 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 35246 $as_echo_n "checking for $ac_word... " >&6; } 35247 if ${ac_cv_path_TOOLCHAIN_PATH_CXX+:} false; then : 35248 $as_echo_n "(cached) " >&6 35249 else 35250 case $TOOLCHAIN_PATH_CXX in 35251 [\\/]* | ?:[\\/]*) 35252 ac_cv_path_TOOLCHAIN_PATH_CXX="$TOOLCHAIN_PATH_CXX" # Let the user override the test with a path. 35253 ;; 35254 *) 35255 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 35256 for as_dir in $PATH 35257 do 35258 IFS=$as_save_IFS 35259 test -z "$as_dir" && as_dir=. 35260 for ac_exec_ext in '' $ac_executable_extensions; do 35261 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 35262 ac_cv_path_TOOLCHAIN_PATH_CXX="$as_dir/$ac_word$ac_exec_ext" 35263 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 35264 break 2 35265 fi 35266 done 35267 done 35268 IFS=$as_save_IFS 35269 35270 ;; 35271 esac 35272 fi 35273 TOOLCHAIN_PATH_CXX=$ac_cv_path_TOOLCHAIN_PATH_CXX 35274 if test -n "$TOOLCHAIN_PATH_CXX"; then 35275 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $TOOLCHAIN_PATH_CXX" >&5 35276 $as_echo "$TOOLCHAIN_PATH_CXX" >&6; } 35277 else 35278 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 35279 $as_echo "no" >&6; } 35280 fi 35281 35282 35283 fi 35284 if test -z "$ac_cv_path_TOOLCHAIN_PATH_CXX"; then 35285 ac_pt_TOOLCHAIN_PATH_CXX=$TOOLCHAIN_PATH_CXX 35286 # Extract the first word of "$SEARCH_LIST", so it can be a program name with args. 35287 set dummy $SEARCH_LIST; ac_word=$2 35288 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 35289 $as_echo_n "checking for $ac_word... " >&6; } 35290 if ${ac_cv_path_ac_pt_TOOLCHAIN_PATH_CXX+:} false; then : 35291 $as_echo_n "(cached) " >&6 35292 else 35293 case $ac_pt_TOOLCHAIN_PATH_CXX in 35294 [\\/]* | ?:[\\/]*) 35295 ac_cv_path_ac_pt_TOOLCHAIN_PATH_CXX="$ac_pt_TOOLCHAIN_PATH_CXX" # Let the user override the test with a path. 35296 ;; 35297 *) 35298 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 35299 for as_dir in $PATH 35300 do 35301 IFS=$as_save_IFS 35302 test -z "$as_dir" && as_dir=. 35303 for ac_exec_ext in '' $ac_executable_extensions; do 35304 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 35305 ac_cv_path_ac_pt_TOOLCHAIN_PATH_CXX="$as_dir/$ac_word$ac_exec_ext" 35306 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 35307 break 2 35308 fi 35309 done 35310 done 35311 IFS=$as_save_IFS 35312 35313 ;; 35314 esac 35315 fi 35316 ac_pt_TOOLCHAIN_PATH_CXX=$ac_cv_path_ac_pt_TOOLCHAIN_PATH_CXX 35317 if test -n "$ac_pt_TOOLCHAIN_PATH_CXX"; then 35318 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_pt_TOOLCHAIN_PATH_CXX" >&5 35319 $as_echo "$ac_pt_TOOLCHAIN_PATH_CXX" >&6; } 35320 else 35321 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 35322 $as_echo "no" >&6; } 35323 fi 35324 35325 if test "x$ac_pt_TOOLCHAIN_PATH_CXX" = x; then 35326 TOOLCHAIN_PATH_CXX="" 35327 else 35328 case $cross_compiling:$ac_tool_warned in 35329 yes:) 35330 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5 35331 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;} 35332 ac_tool_warned=yes ;; 35333 esac 35334 TOOLCHAIN_PATH_CXX=$ac_pt_TOOLCHAIN_PATH_CXX 35335 fi 35336 else 35337 TOOLCHAIN_PATH_CXX="$ac_cv_path_TOOLCHAIN_PATH_CXX" 35338 fi 35339 35340 CXX=$TOOLCHAIN_PATH_CXX 35341 PATH="$PATH_save" 35342 fi 35343 35344 # AC_PATH_TOOL can't be run multiple times with the same variable, 35345 # so create a new name for this run. 35346 if test "x$CXX" = x; then 35347 if test -n "$ac_tool_prefix"; then 35348 # Extract the first word of "${ac_tool_prefix}$SEARCH_LIST", so it can be a program name with args. 35349 set dummy ${ac_tool_prefix}$SEARCH_LIST; ac_word=$2 35350 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 35351 $as_echo_n "checking for $ac_word... " >&6; } 35352 if ${ac_cv_path_POTENTIAL_CXX+:} false; then : 35353 $as_echo_n "(cached) " >&6 35354 else 35355 case $POTENTIAL_CXX in 35356 [\\/]* | ?:[\\/]*) 35357 ac_cv_path_POTENTIAL_CXX="$POTENTIAL_CXX" # Let the user override the test with a path. 35358 ;; 35359 *) 35360 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 35361 for as_dir in $PATH 35362 do 35363 IFS=$as_save_IFS 35364 test -z "$as_dir" && as_dir=. 35365 for ac_exec_ext in '' $ac_executable_extensions; do 35366 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 35367 ac_cv_path_POTENTIAL_CXX="$as_dir/$ac_word$ac_exec_ext" 35368 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 35369 break 2 35370 fi 35371 done 35372 done 35373 IFS=$as_save_IFS 35374 35375 ;; 35376 esac 35377 fi 35378 POTENTIAL_CXX=$ac_cv_path_POTENTIAL_CXX 35379 if test -n "$POTENTIAL_CXX"; then 35380 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $POTENTIAL_CXX" >&5 35381 $as_echo "$POTENTIAL_CXX" >&6; } 35382 else 35383 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 35384 $as_echo "no" >&6; } 35385 fi 35386 35387 35388 fi 35389 if test -z "$ac_cv_path_POTENTIAL_CXX"; then 35390 ac_pt_POTENTIAL_CXX=$POTENTIAL_CXX 35391 # Extract the first word of "$SEARCH_LIST", so it can be a program name with args. 35392 set dummy $SEARCH_LIST; ac_word=$2 35393 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 35394 $as_echo_n "checking for $ac_word... " >&6; } 35395 if ${ac_cv_path_ac_pt_POTENTIAL_CXX+:} false; then : 35396 $as_echo_n "(cached) " >&6 35397 else 35398 case $ac_pt_POTENTIAL_CXX in 35399 [\\/]* | ?:[\\/]*) 35400 ac_cv_path_ac_pt_POTENTIAL_CXX="$ac_pt_POTENTIAL_CXX" # Let the user override the test with a path. 35401 ;; 35402 *) 35403 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 35404 for as_dir in $PATH 35405 do 35406 IFS=$as_save_IFS 35407 test -z "$as_dir" && as_dir=. 35408 for ac_exec_ext in '' $ac_executable_extensions; do 35409 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 35410 ac_cv_path_ac_pt_POTENTIAL_CXX="$as_dir/$ac_word$ac_exec_ext" 35411 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 35412 break 2 35413 fi 35414 done 35415 done 35416 IFS=$as_save_IFS 35417 35418 ;; 35419 esac 35420 fi 35421 ac_pt_POTENTIAL_CXX=$ac_cv_path_ac_pt_POTENTIAL_CXX 35422 if test -n "$ac_pt_POTENTIAL_CXX"; then 35423 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_pt_POTENTIAL_CXX" >&5 35424 $as_echo "$ac_pt_POTENTIAL_CXX" >&6; } 35425 else 35426 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 35427 $as_echo "no" >&6; } 35428 fi 35429 35430 if test "x$ac_pt_POTENTIAL_CXX" = x; then 35431 POTENTIAL_CXX="" 35432 else 35433 case $cross_compiling:$ac_tool_warned in 35434 yes:) 35435 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5 35436 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;} 35437 ac_tool_warned=yes ;; 35438 esac 35439 POTENTIAL_CXX=$ac_pt_POTENTIAL_CXX 35440 fi 35441 else 35442 POTENTIAL_CXX="$ac_cv_path_POTENTIAL_CXX" 35443 fi 35444 35445 CXX=$POTENTIAL_CXX 35446 fi 35447 35448 if test "x$CXX" = x; then 35449 35450 # Print a helpful message on how to acquire the necessary build dependency. 35451 # devkit is the help tag: freetype, cups, alsa etc 35452 MISSING_DEPENDENCY=devkit 35453 35454 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 35455 cygwin_help $MISSING_DEPENDENCY 35456 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 35457 msys_help $MISSING_DEPENDENCY 35458 else 35459 PKGHANDLER_COMMAND= 35460 35461 case $PKGHANDLER in 35462 apt-get) 35463 apt_help $MISSING_DEPENDENCY ;; 35464 yum) 35465 yum_help $MISSING_DEPENDENCY ;; 35466 brew) 35467 brew_help $MISSING_DEPENDENCY ;; 35468 port) 35469 port_help $MISSING_DEPENDENCY ;; 35470 pkgutil) 35471 pkgutil_help $MISSING_DEPENDENCY ;; 35472 pkgadd) 35473 pkgadd_help $MISSING_DEPENDENCY ;; 35474 esac 35475 35476 if test "x$PKGHANDLER_COMMAND" != x; then 35477 HELP_MSG="You might be able to fix this by running '$PKGHANDLER_COMMAND'." 35478 fi 35479 fi 35480 35481 as_fn_error $? "Could not find a $COMPILER_NAME compiler. $HELP_MSG" "$LINENO" 5 35482 fi 35483 fi 35484 35485 # Now we have a compiler binary in CXX. Make sure it's okay. 35486 35487 # Only process if variable expands to non-empty 35488 35489 if test "x$CXX" != x; then 35490 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 35491 35492 # First separate the path from the arguments. This will split at the first 35493 # space. 35494 complete="$CXX" 35495 path="${complete%% *}" 35496 tmp="$complete EOL" 35497 arguments="${tmp#* }" 35498 35499 # Input might be given as Windows format, start by converting to 35500 # unix format. 35501 new_path=`$CYGPATH -u "$path"` 35502 35503 # Now try to locate executable using which 35504 new_path=`$WHICH "$new_path" 2> /dev/null` 35505 # bat and cmd files are not always considered executable in cygwin causing which 35506 # to not find them 35507 if test "x$new_path" = x \ 35508 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 35509 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 35510 new_path=`$CYGPATH -u "$path"` 35511 fi 35512 if test "x$new_path" = x; then 35513 # Oops. Which didn't find the executable. 35514 # The splitting of arguments from the executable at a space might have been incorrect, 35515 # since paths with space are more likely in Windows. Give it another try with the whole 35516 # argument. 35517 path="$complete" 35518 arguments="EOL" 35519 new_path=`$CYGPATH -u "$path"` 35520 new_path=`$WHICH "$new_path" 2> /dev/null` 35521 # bat and cmd files are not always considered executable in cygwin causing which 35522 # to not find them 35523 if test "x$new_path" = x \ 35524 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 35525 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 35526 new_path=`$CYGPATH -u "$path"` 35527 fi 35528 if test "x$new_path" = x; then 35529 # It's still not found. Now this is an unrecoverable error. 35530 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of CXX, which resolves as \"$complete\", is not found." >&5 35531 $as_echo "$as_me: The path of CXX, which resolves as \"$complete\", is not found." >&6;} 35532 has_space=`$ECHO "$complete" | $GREP " "` 35533 if test "x$has_space" != x; then 35534 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 35535 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 35536 fi 35537 as_fn_error $? "Cannot locate the the path of CXX" "$LINENO" 5 35538 fi 35539 fi 35540 35541 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 35542 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 35543 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 35544 # "foo.exe" is OK but "foo" is an error. 35545 # 35546 # This test is therefore slightly more accurate than "test -f" to check for file presence. 35547 # It is also a way to make sure we got the proper file name for the real test later on. 35548 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 35549 if test "x$test_shortpath" = x; then 35550 # Short path failed, file does not exist as specified. 35551 # Try adding .exe or .cmd 35552 if test -f "${new_path}.exe"; then 35553 input_to_shortpath="${new_path}.exe" 35554 elif test -f "${new_path}.cmd"; then 35555 input_to_shortpath="${new_path}.cmd" 35556 else 35557 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of CXX, which resolves as \"$new_path\", is invalid." >&5 35558 $as_echo "$as_me: The path of CXX, which resolves as \"$new_path\", is invalid." >&6;} 35559 { $as_echo "$as_me:${as_lineno-$LINENO}: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&5 35560 $as_echo "$as_me: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&6;} 35561 as_fn_error $? "Cannot locate the the path of CXX" "$LINENO" 5 35562 fi 35563 else 35564 input_to_shortpath="$new_path" 35565 fi 35566 35567 # Call helper function which possibly converts this using DOS-style short mode. 35568 # If so, the updated path is stored in $new_path. 35569 new_path="$input_to_shortpath" 35570 35571 input_path="$input_to_shortpath" 35572 # Check if we need to convert this using DOS-style short mode. If the path 35573 # contains just simple characters, use it. Otherwise (spaces, weird characters), 35574 # take no chances and rewrite it. 35575 # Note: m4 eats our [], so we need to use [ and ] instead. 35576 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 35577 if test "x$has_forbidden_chars" != x; then 35578 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 35579 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 35580 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 35581 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 35582 # Going to short mode and back again did indeed matter. Since short mode is 35583 # case insensitive, let's make it lowercase to improve readability. 35584 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 35585 # Now convert it back to Unix-style (cygpath) 35586 input_path=`$CYGPATH -u "$shortmode_path"` 35587 new_path="$input_path" 35588 fi 35589 fi 35590 35591 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 35592 if test "x$test_cygdrive_prefix" = x; then 35593 # As a simple fix, exclude /usr/bin since it's not a real path. 35594 if test "x`$ECHO $input_to_shortpath | $GREP ^/usr/bin/`" = x; then 35595 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 35596 # a path prefixed by /cygdrive for fixpath to work. 35597 new_path="$CYGWIN_ROOT_PATH$input_path" 35598 fi 35599 fi 35600 35601 # remove trailing .exe if any 35602 new_path="${new_path/%.exe/}" 35603 35604 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 35605 35606 # First separate the path from the arguments. This will split at the first 35607 # space. 35608 complete="$CXX" 35609 path="${complete%% *}" 35610 tmp="$complete EOL" 35611 arguments="${tmp#* }" 35612 35613 # Input might be given as Windows format, start by converting to 35614 # unix format. 35615 new_path="$path" 35616 35617 windows_path="$new_path" 35618 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 35619 unix_path=`$CYGPATH -u "$windows_path"` 35620 new_path="$unix_path" 35621 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 35622 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 35623 new_path="$unix_path" 35624 fi 35625 35626 35627 # Now try to locate executable using which 35628 new_path=`$WHICH "$new_path" 2> /dev/null` 35629 35630 if test "x$new_path" = x; then 35631 # Oops. Which didn't find the executable. 35632 # The splitting of arguments from the executable at a space might have been incorrect, 35633 # since paths with space are more likely in Windows. Give it another try with the whole 35634 # argument. 35635 path="$complete" 35636 arguments="EOL" 35637 new_path="$path" 35638 35639 windows_path="$new_path" 35640 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 35641 unix_path=`$CYGPATH -u "$windows_path"` 35642 new_path="$unix_path" 35643 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 35644 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 35645 new_path="$unix_path" 35646 fi 35647 35648 35649 new_path=`$WHICH "$new_path" 2> /dev/null` 35650 # bat and cmd files are not always considered executable in MSYS causing which 35651 # to not find them 35652 if test "x$new_path" = x \ 35653 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 35654 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 35655 new_path="$path" 35656 35657 windows_path="$new_path" 35658 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 35659 unix_path=`$CYGPATH -u "$windows_path"` 35660 new_path="$unix_path" 35661 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 35662 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 35663 new_path="$unix_path" 35664 fi 35665 35666 fi 35667 35668 if test "x$new_path" = x; then 35669 # It's still not found. Now this is an unrecoverable error. 35670 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of CXX, which resolves as \"$complete\", is not found." >&5 35671 $as_echo "$as_me: The path of CXX, which resolves as \"$complete\", is not found." >&6;} 35672 has_space=`$ECHO "$complete" | $GREP " "` 35673 if test "x$has_space" != x; then 35674 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 35675 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 35676 fi 35677 as_fn_error $? "Cannot locate the the path of CXX" "$LINENO" 5 35678 fi 35679 fi 35680 35681 # Now new_path has a complete unix path to the binary 35682 if test "x`$ECHO $new_path | $GREP ^/bin/`" != x; then 35683 # Keep paths in /bin as-is, but remove trailing .exe if any 35684 new_path="${new_path/%.exe/}" 35685 # Do not save /bin paths to all_fixpath_prefixes! 35686 else 35687 # Not in mixed or Windows style, start by that. 35688 new_path=`cmd //c echo $new_path` 35689 35690 input_path="$new_path" 35691 # Check if we need to convert this using DOS-style short mode. If the path 35692 # contains just simple characters, use it. Otherwise (spaces, weird characters), 35693 # take no chances and rewrite it. 35694 # Note: m4 eats our [], so we need to use [ and ] instead. 35695 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 35696 if test "x$has_forbidden_chars" != x; then 35697 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 35698 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 35699 fi 35700 35701 # Output is in $new_path 35702 35703 windows_path="$new_path" 35704 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 35705 unix_path=`$CYGPATH -u "$windows_path"` 35706 new_path="$unix_path" 35707 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 35708 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 35709 new_path="$unix_path" 35710 fi 35711 35712 # remove trailing .exe if any 35713 new_path="${new_path/%.exe/}" 35714 35715 # Save the first 10 bytes of this path to the storage, so fixpath can work. 35716 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 35717 fi 35718 35719 else 35720 # We're on a unix platform. Hooray! :) 35721 # First separate the path from the arguments. This will split at the first 35722 # space. 35723 complete="$CXX" 35724 path="${complete%% *}" 35725 tmp="$complete EOL" 35726 arguments="${tmp#* }" 35727 35728 # Cannot rely on the command "which" here since it doesn't always work. 35729 is_absolute_path=`$ECHO "$path" | $GREP ^/` 35730 if test -z "$is_absolute_path"; then 35731 # Path to executable is not absolute. Find it. 35732 IFS_save="$IFS" 35733 IFS=: 35734 for p in $PATH; do 35735 if test -f "$p/$path" && test -x "$p/$path"; then 35736 new_path="$p/$path" 35737 break 35738 fi 35739 done 35740 IFS="$IFS_save" 35741 else 35742 # This is an absolute path, we can use it without further modifications. 35743 new_path="$path" 35744 fi 35745 35746 if test "x$new_path" = x; then 35747 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of CXX, which resolves as \"$complete\", is not found." >&5 35748 $as_echo "$as_me: The path of CXX, which resolves as \"$complete\", is not found." >&6;} 35749 has_space=`$ECHO "$complete" | $GREP " "` 35750 if test "x$has_space" != x; then 35751 { $as_echo "$as_me:${as_lineno-$LINENO}: This might be caused by spaces in the path, which is not allowed." >&5 35752 $as_echo "$as_me: This might be caused by spaces in the path, which is not allowed." >&6;} 35753 fi 35754 as_fn_error $? "Cannot locate the the path of CXX" "$LINENO" 5 35755 fi 35756 fi 35757 35758 # Now join together the path and the arguments once again 35759 if test "x$arguments" != xEOL; then 35760 new_complete="$new_path ${arguments% *}" 35761 else 35762 new_complete="$new_path" 35763 fi 35764 35765 if test "x$complete" != "x$new_complete"; then 35766 CXX="$new_complete" 35767 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting CXX to \"$new_complete\"" >&5 35768 $as_echo "$as_me: Rewriting CXX to \"$new_complete\"" >&6;} 35769 fi 35770 fi 35771 35772 TEST_COMPILER="$CXX" 35773 35774 { $as_echo "$as_me:${as_lineno-$LINENO}: checking resolved symbolic links for CXX" >&5 35775 $as_echo_n "checking resolved symbolic links for CXX... " >&6; } 35776 SYMLINK_ORIGINAL="$TEST_COMPILER" 35777 35778 if test "x$OPENJDK_BUILD_OS" != xwindows; then 35779 # Follow a chain of symbolic links. Use readlink 35780 # where it exists, else fall back to horribly 35781 # complicated shell code. 35782 if test "x$READLINK_TESTED" != yes; then 35783 # On MacOSX there is a readlink tool with a different 35784 # purpose than the GNU readlink tool. Check the found readlink. 35785 ISGNU=`$READLINK --version 2>&1 | $GREP GNU` 35786 if test "x$ISGNU" = x; then 35787 # A readlink that we do not know how to use. 35788 # Are there other non-GNU readlinks out there? 35789 READLINK_TESTED=yes 35790 READLINK= 35791 fi 35792 fi 35793 35794 if test "x$READLINK" != x; then 35795 SYMLINK_ORIGINAL=`$READLINK -f $SYMLINK_ORIGINAL` 35796 else 35797 # Save the current directory for restoring afterwards 35798 STARTDIR=$PWD 35799 COUNTER=0 35800 sym_link_dir=`$DIRNAME $SYMLINK_ORIGINAL` 35801 sym_link_file=`$BASENAME $SYMLINK_ORIGINAL` 35802 cd $sym_link_dir 35803 # Use -P flag to resolve symlinks in directories. 35804 cd `$THEPWDCMD -P` 35805 sym_link_dir=`$THEPWDCMD -P` 35806 # Resolve file symlinks 35807 while test $COUNTER -lt 20; do 35808 ISLINK=`$LS -l $sym_link_dir/$sym_link_file | $GREP '\->' | $SED -e 's/.*-> \(.*\)/\1/'` 35809 if test "x$ISLINK" == x; then 35810 # This is not a symbolic link! We are done! 35811 break 35812 fi 35813 # Again resolve directory symlinks since the target of the just found 35814 # link could be in a different directory 35815 cd `$DIRNAME $ISLINK` 35816 sym_link_dir=`$THEPWDCMD -P` 35817 sym_link_file=`$BASENAME $ISLINK` 35818 let COUNTER=COUNTER+1 35819 done 35820 cd $STARTDIR 35821 SYMLINK_ORIGINAL=$sym_link_dir/$sym_link_file 35822 fi 35823 fi 35824 35825 if test "x$TEST_COMPILER" = "x$SYMLINK_ORIGINAL"; then 35826 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no symlink" >&5 35827 $as_echo "no symlink" >&6; } 35828 else 35829 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $SYMLINK_ORIGINAL" >&5 35830 $as_echo "$SYMLINK_ORIGINAL" >&6; } 35831 35832 # We can't handle ccache by gcc wrappers, since we need to know if we're 35833 # using ccache. Instead ccache usage must be controlled by a configure option. 35834 COMPILER_BASENAME=`$BASENAME "$SYMLINK_ORIGINAL"` 35835 if test "x$COMPILER_BASENAME" = "xccache"; then 35836 { $as_echo "$as_me:${as_lineno-$LINENO}: Please use --enable-ccache instead of providing a wrapped compiler." >&5 35837 $as_echo "$as_me: Please use --enable-ccache instead of providing a wrapped compiler." >&6;} 35838 as_fn_error $? "$TEST_COMPILER is a symbolic link to ccache. This is not supported." "$LINENO" 5 35839 fi 35840 fi 35841 35842 35843 COMPILER=$CXX 35844 COMPILER_NAME=$COMPILER_NAME 35845 35846 if test "x$TOOLCHAIN_TYPE" = xsolstudio; then 35847 # cc -V output typically looks like 35848 # cc: Sun C 5.12 Linux_i386 2011/11/16 35849 # or 35850 # cc: Studio 12.5 Sun C 5.14 SunOS_sparc 2016/05/31 35851 COMPILER_VERSION_OUTPUT=`$COMPILER -V 2>&1` 35852 # Check that this is likely to be the Solaris Studio cc. 35853 $ECHO "$COMPILER_VERSION_OUTPUT" | $GREP "^.* Sun $COMPILER_NAME" > /dev/null 35854 if test $? -ne 0; then 35855 ALT_VERSION_OUTPUT=`$COMPILER --version 2>&1` 35856 { $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 35857 $as_echo "$as_me: The $COMPILER_NAME compiler (located as $COMPILER) does not seem to be the required $TOOLCHAIN_TYPE compiler." >&6;} 35858 { $as_echo "$as_me:${as_lineno-$LINENO}: The result from running with -V was: \"$COMPILER_VERSION_OUTPUT\"" >&5 35859 $as_echo "$as_me: The result from running with -V was: \"$COMPILER_VERSION_OUTPUT\"" >&6;} 35860 { $as_echo "$as_me:${as_lineno-$LINENO}: The result from running with --version was: \"$ALT_VERSION_OUTPUT\"" >&5 35861 $as_echo "$as_me: The result from running with --version was: \"$ALT_VERSION_OUTPUT\"" >&6;} 35862 as_fn_error $? "A $TOOLCHAIN_TYPE compiler is required. Try setting --with-tools-dir." "$LINENO" 5 35863 fi 35864 # Remove usage instructions (if present), and 35865 # collapse compiler output into a single line 35866 COMPILER_VERSION_STRING=`$ECHO $COMPILER_VERSION_OUTPUT | \ 35867 $SED -e 's/ *[Uu]sage:.*//'` 35868 COMPILER_VERSION_NUMBER=`$ECHO $COMPILER_VERSION_OUTPUT | \ 35869 $SED -e "s/^.*[ ,\t]$COMPILER_NAME[ ,\t]\([1-9]\.[0-9][0-9]*\).*/\1/"` 35870 elif test "x$TOOLCHAIN_TYPE" = xxlc; then 35871 # xlc -qversion output typically looks like 35872 # IBM XL C/C++ for AIX, V11.1 (5724-X13) 35873 # Version: 11.01.0000.0015 35874 COMPILER_VERSION_OUTPUT=`$COMPILER -qversion 2>&1` 35875 # Check that this is likely to be the IBM XL C compiler. 35876 $ECHO "$COMPILER_VERSION_OUTPUT" | $GREP "IBM XL C" > /dev/null 35877 if test $? -ne 0; then 35878 ALT_VERSION_OUTPUT=`$COMPILER --version 2>&1` 35879 { $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 35880 $as_echo "$as_me: The $COMPILER_NAME compiler (located as $COMPILER) does not seem to be the required $TOOLCHAIN_TYPE compiler." >&6;} 35881 { $as_echo "$as_me:${as_lineno-$LINENO}: The result from running with -qversion was: \"$COMPILER_VERSION_OUTPUT\"" >&5 35882 $as_echo "$as_me: The result from running with -qversion was: \"$COMPILER_VERSION_OUTPUT\"" >&6;} 35883 { $as_echo "$as_me:${as_lineno-$LINENO}: The result from running with --version was: \"$ALT_VERSION_OUTPUT\"" >&5 35884 $as_echo "$as_me: The result from running with --version was: \"$ALT_VERSION_OUTPUT\"" >&6;} 35885 as_fn_error $? "A $TOOLCHAIN_TYPE compiler is required. Try setting --with-tools-dir." "$LINENO" 5 35886 fi 35887 # Collapse compiler output into a single line 35888 COMPILER_VERSION_STRING=`$ECHO $COMPILER_VERSION_OUTPUT` 35889 COMPILER_VERSION_NUMBER=`$ECHO $COMPILER_VERSION_OUTPUT | \ 35890 $SED -e 's/^.*, V\([1-9][0-9.]*\).*$/\1/'` 35891 elif test "x$TOOLCHAIN_TYPE" = xmicrosoft; then 35892 # There is no specific version flag, but all output starts with a version string. 35893 # First line typically looks something like: 35894 # Microsoft (R) 32-bit C/C++ Optimizing Compiler Version 16.00.40219.01 for 80x86 35895 COMPILER_VERSION_OUTPUT=`$COMPILER 2>&1 | $HEAD -n 1 | $TR -d '\r'` 35896 # Check that this is likely to be Microsoft CL.EXE. 35897 $ECHO "$COMPILER_VERSION_OUTPUT" | $GREP "Microsoft.*Compiler" > /dev/null 35898 if test $? -ne 0; then 35899 { $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 35900 $as_echo "$as_me: The $COMPILER_NAME compiler (located as $COMPILER) does not seem to be the required $TOOLCHAIN_TYPE compiler." >&6;} 35901 { $as_echo "$as_me:${as_lineno-$LINENO}: The result from running it was: \"$COMPILER_VERSION_OUTPUT\"" >&5 35902 $as_echo "$as_me: The result from running it was: \"$COMPILER_VERSION_OUTPUT\"" >&6;} 35903 as_fn_error $? "A $TOOLCHAIN_TYPE compiler is required. Try setting --with-tools-dir." "$LINENO" 5 35904 fi 35905 # Collapse compiler output into a single line 35906 COMPILER_VERSION_STRING=`$ECHO $COMPILER_VERSION_OUTPUT` 35907 COMPILER_VERSION_NUMBER=`$ECHO $COMPILER_VERSION_OUTPUT | \ 35908 $SED -e 's/^.*ersion.\([1-9][0-9.]*\) .*$/\1/'` 35909 elif test "x$TOOLCHAIN_TYPE" = xgcc; then 35910 # gcc --version output typically looks like 35911 # gcc (Ubuntu/Linaro 4.8.1-10ubuntu9) 4.8.1 35912 # Copyright (C) 2013 Free Software Foundation, Inc. 35913 # This is free software; see the source for copying conditions. There is NO 35914 # warranty; not even for MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. 35915 COMPILER_VERSION_OUTPUT=`$COMPILER --version 2>&1` 35916 # Check that this is likely to be GCC. 35917 $ECHO "$COMPILER_VERSION_OUTPUT" | $GREP "Free Software Foundation" > /dev/null 35918 if test $? -ne 0; then 35919 { $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 35920 $as_echo "$as_me: The $COMPILER_NAME compiler (located as $COMPILER) does not seem to be the required $TOOLCHAIN_TYPE compiler." >&6;} 35921 { $as_echo "$as_me:${as_lineno-$LINENO}: The result from running with --version was: \"$COMPILER_VERSION\"" >&5 35922 $as_echo "$as_me: The result from running with --version was: \"$COMPILER_VERSION\"" >&6;} 35923 as_fn_error $? "A $TOOLCHAIN_TYPE compiler is required. Try setting --with-tools-dir." "$LINENO" 5 35924 fi 35925 # Remove Copyright and legalese from version string, and 35926 # collapse into a single line 35927 COMPILER_VERSION_STRING=`$ECHO $COMPILER_VERSION_OUTPUT | \ 35928 $SED -e 's/ *Copyright .*//'` 35929 COMPILER_VERSION_NUMBER=`$ECHO $COMPILER_VERSION_OUTPUT | \ 35930 $SED -e 's/^.* \([1-9]\.[0-9.]*\)[^0-9.].*$/\1/'` 35931 elif test "x$TOOLCHAIN_TYPE" = xclang; then 35932 # clang --version output typically looks like 35933 # Apple LLVM version 5.0 (clang-500.2.79) (based on LLVM 3.3svn) 35934 # clang version 3.3 (tags/RELEASE_33/final) 35935 # or 35936 # Debian clang version 3.2-7ubuntu1 (tags/RELEASE_32/final) (based on LLVM 3.2) 35937 # Target: x86_64-pc-linux-gnu 35938 # Thread model: posix 35939 COMPILER_VERSION_OUTPUT=`$COMPILER --version 2>&1` 35940 # Check that this is likely to be clang 35941 $ECHO "$COMPILER_VERSION_OUTPUT" | $GREP "clang" > /dev/null 35942 if test $? -ne 0; then 35943 { $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 35944 $as_echo "$as_me: The $COMPILER_NAME compiler (located as $COMPILER) does not seem to be the required $TOOLCHAIN_TYPE compiler." >&6;} 35945 { $as_echo "$as_me:${as_lineno-$LINENO}: The result from running with --version was: \"$COMPILER_VERSION_OUTPUT\"" >&5 35946 $as_echo "$as_me: The result from running with --version was: \"$COMPILER_VERSION_OUTPUT\"" >&6;} 35947 as_fn_error $? "A $TOOLCHAIN_TYPE compiler is required. Try setting --with-tools-dir." "$LINENO" 5 35948 fi 35949 # Collapse compiler output into a single line 35950 COMPILER_VERSION_STRING=`$ECHO $COMPILER_VERSION_OUTPUT` 35951 COMPILER_VERSION_NUMBER=`$ECHO $COMPILER_VERSION_OUTPUT | \ 35952 $SED -e 's/^.* version \([1-9][0-9.]*\).*$/\1/'` 35953 else 35954 as_fn_error $? "Unknown toolchain type $TOOLCHAIN_TYPE." "$LINENO" 5 35955 fi 35956 # This sets CC_VERSION_NUMBER or CXX_VERSION_NUMBER. (This comment is a grep marker) 35957 CXX_VERSION_NUMBER="$COMPILER_VERSION_NUMBER" 35958 # This sets CC_VERSION_STRING or CXX_VERSION_STRING. (This comment is a grep marker) 35959 CXX_VERSION_STRING="$COMPILER_VERSION_STRING" 35960 35961 { $as_echo "$as_me:${as_lineno-$LINENO}: Using $TOOLCHAIN_TYPE $COMPILER_NAME compiler version $COMPILER_VERSION_NUMBER [$COMPILER_VERSION_STRING]" >&5 35962 $as_echo "$as_me: Using $TOOLCHAIN_TYPE $COMPILER_NAME compiler version $COMPILER_VERSION_NUMBER [$COMPILER_VERSION_STRING]" >&6;} 35963 35964 35965 # Now that we have resolved CXX ourself, let autoconf have its go at it 35966 ac_ext=cpp 35967 ac_cpp='$CXXCPP $CPPFLAGS' 35968 ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5' 35969 ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' 35970 ac_compiler_gnu=$ac_cv_cxx_compiler_gnu 35971 if test -z "$CXX"; then 35972 if test -n "$CCC"; then 35973 CXX=$CCC 35974 else 35975 if test -n "$ac_tool_prefix"; then 35976 for ac_prog in $CXX 35977 do 35978 # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args. 35979 set dummy $ac_tool_prefix$ac_prog; ac_word=$2 35980 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 35981 $as_echo_n "checking for $ac_word... " >&6; } 35982 if ${ac_cv_prog_CXX+:} false; then : 35983 $as_echo_n "(cached) " >&6 35984 else 35985 if test -n "$CXX"; then 35986 ac_cv_prog_CXX="$CXX" # Let the user override the test. 35987 else 35988 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 35989 for as_dir in $PATH 35990 do 35991 IFS=$as_save_IFS 35992 test -z "$as_dir" && as_dir=. 35993 for ac_exec_ext in '' $ac_executable_extensions; do 35994 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 35995 ac_cv_prog_CXX="$ac_tool_prefix$ac_prog" 35996 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 35997 break 2 35998 fi 35999 done 36000 done 36001 IFS=$as_save_IFS 36002 36003 fi 36004 fi 36005 CXX=$ac_cv_prog_CXX 36006 if test -n "$CXX"; then 36007 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CXX" >&5 36008 $as_echo "$CXX" >&6; } 36009 else 36010 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 36011 $as_echo "no" >&6; } 36012 fi 36013 36014 36015 test -n "$CXX" && break 36016 done 36017 fi 36018 if test -z "$CXX"; then 36019 ac_ct_CXX=$CXX 36020 for ac_prog in $CXX 36021 do 36022 # Extract the first word of "$ac_prog", so it can be a program name with args. 36023 set dummy $ac_prog; ac_word=$2 36024 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 36025 $as_echo_n "checking for $ac_word... " >&6; } 36026 if ${ac_cv_prog_ac_ct_CXX+:} false; then : 36027 $as_echo_n "(cached) " >&6 36028 else 36029 if test -n "$ac_ct_CXX"; then 36030 ac_cv_prog_ac_ct_CXX="$ac_ct_CXX" # Let the user override the test. 36031 else 36032 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 36033 for as_dir in $PATH 36034 do 36035 IFS=$as_save_IFS 36036 test -z "$as_dir" && as_dir=. 36037 for ac_exec_ext in '' $ac_executable_extensions; do 36038 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 36039 ac_cv_prog_ac_ct_CXX="$ac_prog" 36040 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 36041 break 2 36042 fi 36043 done 36044 done 36045 IFS=$as_save_IFS 36046 36047 fi 36048 fi 36049 ac_ct_CXX=$ac_cv_prog_ac_ct_CXX 36050 if test -n "$ac_ct_CXX"; then 36051 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_CXX" >&5 36052 $as_echo "$ac_ct_CXX" >&6; } 36053 else 36054 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 36055 $as_echo "no" >&6; } 36056 fi 36057 36058 36059 test -n "$ac_ct_CXX" && break 36060 done 36061 36062 if test "x$ac_ct_CXX" = x; then 36063 CXX="g++" 36064 else 36065 case $cross_compiling:$ac_tool_warned in 36066 yes:) 36067 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5 36068 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;} 36069 ac_tool_warned=yes ;; 36070 esac 36071 CXX=$ac_ct_CXX 36072 fi 36073 fi 36074 36075 fi 36076 fi 36077 # Provide some information about the compiler. 36078 $as_echo "$as_me:${as_lineno-$LINENO}: checking for C++ compiler version" >&5 36079 set X $ac_compile 36080 ac_compiler=$2 36081 for ac_option in --version -v -V -qversion; do 36082 { { ac_try="$ac_compiler $ac_option >&5" 36083 case "(($ac_try" in 36084 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; 36085 *) ac_try_echo=$ac_try;; 36086 esac 36087 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\"" 36088 $as_echo "$ac_try_echo"; } >&5 36089 (eval "$ac_compiler $ac_option >&5") 2>conftest.err 36090 ac_status=$? 36091 if test -s conftest.err; then 36092 sed '10a\ 36093 ... rest of stderr output deleted ... 36094 10q' conftest.err >conftest.er1 36095 cat conftest.er1 >&5 36096 fi 36097 rm -f conftest.er1 conftest.err 36098 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 36099 test $ac_status = 0; } 36100 done 36101 36102 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether we are using the GNU C++ compiler" >&5 36103 $as_echo_n "checking whether we are using the GNU C++ compiler... " >&6; } 36104 if ${ac_cv_cxx_compiler_gnu+:} false; then : 36105 $as_echo_n "(cached) " >&6 36106 else 36107 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 36108 /* end confdefs.h. */ 36109 36110 int 36111 main () 36112 { 36113 #ifndef __GNUC__ 36114 choke me 36115 #endif 36116 36117 ; 36118 return 0; 36119 } 36120 _ACEOF 36121 if ac_fn_cxx_try_compile "$LINENO"; then : 36122 ac_compiler_gnu=yes 36123 else 36124 ac_compiler_gnu=no 36125 fi 36126 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext 36127 ac_cv_cxx_compiler_gnu=$ac_compiler_gnu 36128 36129 fi 36130 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_cxx_compiler_gnu" >&5 36131 $as_echo "$ac_cv_cxx_compiler_gnu" >&6; } 36132 if test $ac_compiler_gnu = yes; then 36133 GXX=yes 36134 else 36135 GXX= 36136 fi 36137 ac_test_CXXFLAGS=${CXXFLAGS+set} 36138 ac_save_CXXFLAGS=$CXXFLAGS 36139 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $CXX accepts -g" >&5 36140 $as_echo_n "checking whether $CXX accepts -g... " >&6; } 36141 if ${ac_cv_prog_cxx_g+:} false; then : 36142 $as_echo_n "(cached) " >&6 36143 else 36144 ac_save_cxx_werror_flag=$ac_cxx_werror_flag 36145 ac_cxx_werror_flag=yes 36146 ac_cv_prog_cxx_g=no 36147 CXXFLAGS="-g" 36148 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 36149 /* end confdefs.h. */ 36150 36151 int 36152 main () 36153 { 36154 36155 ; 36156 return 0; 36157 } 36158 _ACEOF 36159 if ac_fn_cxx_try_compile "$LINENO"; then : 36160 ac_cv_prog_cxx_g=yes 36161 else 36162 CXXFLAGS="" 36163 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 36164 /* end confdefs.h. */ 36165 36166 int 36167 main () 36168 { 36169 36170 ; 36171 return 0; 36172 } 36173 _ACEOF 36174 if ac_fn_cxx_try_compile "$LINENO"; then : 36175 36176 else 36177 ac_cxx_werror_flag=$ac_save_cxx_werror_flag 36178 CXXFLAGS="-g" 36179 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 36180 /* end confdefs.h. */ 36181 36182 int 36183 main () 36184 { 36185 36186 ; 36187 return 0; 36188 } 36189 _ACEOF 36190 if ac_fn_cxx_try_compile "$LINENO"; then : 36191 ac_cv_prog_cxx_g=yes 36192 fi 36193 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext 36194 fi 36195 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext 36196 fi 36197 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext 36198 ac_cxx_werror_flag=$ac_save_cxx_werror_flag 36199 fi 36200 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_prog_cxx_g" >&5 36201 $as_echo "$ac_cv_prog_cxx_g" >&6; } 36202 if test "$ac_test_CXXFLAGS" = set; then 36203 CXXFLAGS=$ac_save_CXXFLAGS 36204 elif test $ac_cv_prog_cxx_g = yes; then 36205 if test "$GXX" = yes; then 36206 CXXFLAGS="-g -O2" 36207 else 36208 CXXFLAGS="-g" 36209 fi 36210 else 36211 if test "$GXX" = yes; then 36212 CXXFLAGS="-O2" 36213 else 36214 CXXFLAGS= 36215 fi 36216 fi 36217 ac_ext=cpp 36218 ac_cpp='$CXXCPP $CPPFLAGS' 36219 ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5' 36220 ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' 36221 ac_compiler_gnu=$ac_cv_cxx_compiler_gnu 36222 36223 36224 # This is the compiler version number on the form X.Y[.Z] 36225 36226 36227 36228 36229 if test "x$CC_VERSION_NUMBER" != "x$CXX_VERSION_NUMBER"; then 36230 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: C and C++ compiler have different version numbers, $CC_VERSION_NUMBER vs $CXX_VERSION_NUMBER." >&5 36231 $as_echo "$as_me: WARNING: C and C++ compiler have different version numbers, $CC_VERSION_NUMBER vs $CXX_VERSION_NUMBER." >&2;} 36232 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: This typically indicates a broken setup, and is not supported" >&5 36233 $as_echo "$as_me: WARNING: This typically indicates a broken setup, and is not supported" >&2;} 36234 fi 36235 36236 # We only check CC_VERSION_NUMBER since we assume CXX_VERSION_NUMBER is equal. 36237 if [[ "[$]CC_VERSION_NUMBER" =~ (.*\.){4} ]] ; then 36238 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: C compiler version number has more than four parts (W.X.Y.Z): $CC_VERSION_NUMBER. Comparisons might be wrong." >&5 36239 $as_echo "$as_me: WARNING: C compiler version number has more than four parts (W.X.Y.Z): $CC_VERSION_NUMBER. Comparisons might be wrong." >&2;} 36240 fi 36241 36242 if [[ "[$]CC_VERSION_NUMBER" =~ [0-9]{6} ]] ; then 36243 { $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 36244 $as_echo "$as_me: WARNING: C compiler version number has a part larger than 99999: $CC_VERSION_NUMBER. Comparisons might be wrong." >&2;} 36245 fi 36246 36247 COMPARABLE_ACTUAL_VERSION=`$AWK -F. '{ printf("%05d%05d%05d%05d\n", $1, $2, $3, $4) }' <<< "$CC_VERSION_NUMBER"` 36248 36249 36250 if test "x$TOOLCHAIN_MINIMUM_VERSION" != x; then 36251 36252 36253 36254 36255 36256 36257 36258 36259 36260 36261 36262 36263 36264 36265 36266 36267 36268 36269 36270 36271 36272 36273 36274 36275 36276 36277 36278 36279 36280 36281 36282 36283 36284 36285 36286 36287 36288 36289 36290 36291 36292 36293 36294 36295 36296 36297 36298 36299 36300 # Execute function body 36301 36302 # Need to assign to a variable since m4 is blocked from modifying parts in []. 36303 REFERENCE_VERSION=$TOOLCHAIN_MINIMUM_VERSION 36304 36305 if [[ "$REFERENCE_VERSION" =~ (.*\.){4} ]] ; then 36306 as_fn_error $? "Internal error: Cannot compare to $TOOLCHAIN_MINIMUM_VERSION, only four parts (W.X.Y.Z) is supported" "$LINENO" 5 36307 fi 36308 36309 if [[ "$REFERENCE_VERSION" =~ [0-9]{6} ]] ; then 36310 as_fn_error $? "Internal error: Cannot compare to $TOOLCHAIN_MINIMUM_VERSION, only parts < 99999 is supported" "$LINENO" 5 36311 fi 36312 36313 # Version comparison method inspired by http://stackoverflow.com/a/24067243 36314 COMPARABLE_REFERENCE_VERSION=`$AWK -F. '{ printf("%05d%05d%05d%05d\n", $1, $2, $3, $4) }' <<< "$REFERENCE_VERSION"` 36315 36316 if test $COMPARABLE_ACTUAL_VERSION -ge $COMPARABLE_REFERENCE_VERSION ; then 36317 : 36318 36319 else 36320 : 36321 36322 { $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 36323 $as_echo "$as_me: WARNING: You are using $TOOLCHAIN_TYPE older than $TOOLCHAIN_MINIMUM_VERSION. This is not a supported configuration." >&2;} 36324 36325 36326 fi 36327 36328 36329 36330 36331 36332 36333 36334 36335 36336 36337 36338 36339 36340 36341 fi 36342 36343 # 36344 # Setup the preprocessor (CPP and CXXCPP) 36345 # 36346 ac_ext=c 36347 ac_cpp='$CPP $CPPFLAGS' 36348 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5' 36349 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' 36350 ac_compiler_gnu=$ac_cv_c_compiler_gnu 36351 { $as_echo "$as_me:${as_lineno-$LINENO}: checking how to run the C preprocessor" >&5 36352 $as_echo_n "checking how to run the C preprocessor... " >&6; } 36353 # On Suns, sometimes $CPP names a directory. 36354 if test -n "$CPP" && test -d "$CPP"; then 36355 CPP= 36356 fi 36357 if test -z "$CPP"; then 36358 if ${ac_cv_prog_CPP+:} false; then : 36359 $as_echo_n "(cached) " >&6 36360 else 36361 # Double quotes because CPP needs to be expanded 36362 for CPP in "$CC -E" "$CC -E -traditional-cpp" "/lib/cpp" 36363 do 36364 ac_preproc_ok=false 36365 for ac_c_preproc_warn_flag in '' yes 36366 do 36367 # Use a header file that comes with gcc, so configuring glibc 36368 # with a fresh cross-compiler works. 36369 # Prefer <limits.h> to <assert.h> if __STDC__ is defined, since 36370 # <limits.h> exists even on freestanding compilers. 36371 # On the NeXT, cc -E runs the code through the compiler's parser, 36372 # not just through cpp. "Syntax error" is here to catch this case. 36373 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 36374 /* end confdefs.h. */ 36375 #ifdef __STDC__ 36376 # include <limits.h> 36377 #else 36378 # include <assert.h> 36379 #endif 36380 Syntax error 36381 _ACEOF 36382 if ac_fn_c_try_cpp "$LINENO"; then : 36383 36384 else 36385 # Broken: fails on valid input. 36386 continue 36387 fi 36388 rm -f conftest.err conftest.i conftest.$ac_ext 36389 36390 # OK, works on sane cases. Now check whether nonexistent headers 36391 # can be detected and how. 36392 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 36393 /* end confdefs.h. */ 36394 #include <ac_nonexistent.h> 36395 _ACEOF 36396 if ac_fn_c_try_cpp "$LINENO"; then : 36397 # Broken: success on invalid input. 36398 continue 36399 else 36400 # Passes both tests. 36401 ac_preproc_ok=: 36402 break 36403 fi 36404 rm -f conftest.err conftest.i conftest.$ac_ext 36405 36406 done 36407 # Because of `break', _AC_PREPROC_IFELSE's cleaning code was skipped. 36408 rm -f conftest.i conftest.err conftest.$ac_ext 36409 if $ac_preproc_ok; then : 36410 break 36411 fi 36412 36413 done 36414 ac_cv_prog_CPP=$CPP 36415 36416 fi 36417 CPP=$ac_cv_prog_CPP 36418 else 36419 ac_cv_prog_CPP=$CPP 36420 fi 36421 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CPP" >&5 36422 $as_echo "$CPP" >&6; } 36423 ac_preproc_ok=false 36424 for ac_c_preproc_warn_flag in '' yes 36425 do 36426 # Use a header file that comes with gcc, so configuring glibc 36427 # with a fresh cross-compiler works. 36428 # Prefer <limits.h> to <assert.h> if __STDC__ is defined, since 36429 # <limits.h> exists even on freestanding compilers. 36430 # On the NeXT, cc -E runs the code through the compiler's parser, 36431 # not just through cpp. "Syntax error" is here to catch this case. 36432 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 36433 /* end confdefs.h. */ 36434 #ifdef __STDC__ 36435 # include <limits.h> 36436 #else 36437 # include <assert.h> 36438 #endif 36439 Syntax error 36440 _ACEOF 36441 if ac_fn_c_try_cpp "$LINENO"; then : 36442 36443 else 36444 # Broken: fails on valid input. 36445 continue 36446 fi 36447 rm -f conftest.err conftest.i conftest.$ac_ext 36448 36449 # OK, works on sane cases. Now check whether nonexistent headers 36450 # can be detected and how. 36451 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 36452 /* end confdefs.h. */ 36453 #include <ac_nonexistent.h> 36454 _ACEOF 36455 if ac_fn_c_try_cpp "$LINENO"; then : 36456 # Broken: success on invalid input. 36457 continue 36458 else 36459 # Passes both tests. 36460 ac_preproc_ok=: 36461 break 36462 fi 36463 rm -f conftest.err conftest.i conftest.$ac_ext 36464 36465 done 36466 # Because of `break', _AC_PREPROC_IFELSE's cleaning code was skipped. 36467 rm -f conftest.i conftest.err conftest.$ac_ext 36468 if $ac_preproc_ok; then : 36469 36470 else 36471 { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 36472 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;} 36473 as_fn_error $? "C preprocessor \"$CPP\" fails sanity check 36474 See \`config.log' for more details" "$LINENO" 5; } 36475 fi 36476 36477 ac_ext=cpp 36478 ac_cpp='$CXXCPP $CPPFLAGS' 36479 ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5' 36480 ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' 36481 ac_compiler_gnu=$ac_cv_cxx_compiler_gnu 36482 36483 36484 # Only process if variable expands to non-empty 36485 36486 if test "x$CPP" != x; then 36487 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 36488 36489 # First separate the path from the arguments. This will split at the first 36490 # space. 36491 complete="$CPP" 36492 path="${complete%% *}" 36493 tmp="$complete EOL" 36494 arguments="${tmp#* }" 36495 36496 # Input might be given as Windows format, start by converting to 36497 # unix format. 36498 new_path=`$CYGPATH -u "$path"` 36499 36500 # Now try to locate executable using which 36501 new_path=`$WHICH "$new_path" 2> /dev/null` 36502 # bat and cmd files are not always considered executable in cygwin causing which 36503 # to not find them 36504 if test "x$new_path" = x \ 36505 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 36506 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 36507 new_path=`$CYGPATH -u "$path"` 36508 fi 36509 if test "x$new_path" = x; then 36510 # Oops. Which didn't find the executable. 36511 # The splitting of arguments from the executable at a space might have been incorrect, 36512 # since paths with space are more likely in Windows. Give it another try with the whole 36513 # argument. 36514 path="$complete" 36515 arguments="EOL" 36516 new_path=`$CYGPATH -u "$path"` 36517 new_path=`$WHICH "$new_path" 2> /dev/null` 36518 # bat and cmd files are not always considered executable in cygwin causing which 36519 # to not find them 36520 if test "x$new_path" = x \ 36521 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 36522 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 36523 new_path=`$CYGPATH -u "$path"` 36524 fi 36525 if test "x$new_path" = x; then 36526 # It's still not found. Now this is an unrecoverable error. 36527 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of CPP, which resolves as \"$complete\", is not found." >&5 36528 $as_echo "$as_me: The path of CPP, which resolves as \"$complete\", is not found." >&6;} 36529 has_space=`$ECHO "$complete" | $GREP " "` 36530 if test "x$has_space" != x; then 36531 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 36532 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 36533 fi 36534 as_fn_error $? "Cannot locate the the path of CPP" "$LINENO" 5 36535 fi 36536 fi 36537 36538 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 36539 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 36540 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 36541 # "foo.exe" is OK but "foo" is an error. 36542 # 36543 # This test is therefore slightly more accurate than "test -f" to check for file presence. 36544 # It is also a way to make sure we got the proper file name for the real test later on. 36545 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 36546 if test "x$test_shortpath" = x; then 36547 # Short path failed, file does not exist as specified. 36548 # Try adding .exe or .cmd 36549 if test -f "${new_path}.exe"; then 36550 input_to_shortpath="${new_path}.exe" 36551 elif test -f "${new_path}.cmd"; then 36552 input_to_shortpath="${new_path}.cmd" 36553 else 36554 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of CPP, which resolves as \"$new_path\", is invalid." >&5 36555 $as_echo "$as_me: The path of CPP, which resolves as \"$new_path\", is invalid." >&6;} 36556 { $as_echo "$as_me:${as_lineno-$LINENO}: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&5 36557 $as_echo "$as_me: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&6;} 36558 as_fn_error $? "Cannot locate the the path of CPP" "$LINENO" 5 36559 fi 36560 else 36561 input_to_shortpath="$new_path" 36562 fi 36563 36564 # Call helper function which possibly converts this using DOS-style short mode. 36565 # If so, the updated path is stored in $new_path. 36566 new_path="$input_to_shortpath" 36567 36568 input_path="$input_to_shortpath" 36569 # Check if we need to convert this using DOS-style short mode. If the path 36570 # contains just simple characters, use it. Otherwise (spaces, weird characters), 36571 # take no chances and rewrite it. 36572 # Note: m4 eats our [], so we need to use [ and ] instead. 36573 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 36574 if test "x$has_forbidden_chars" != x; then 36575 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 36576 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 36577 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 36578 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 36579 # Going to short mode and back again did indeed matter. Since short mode is 36580 # case insensitive, let's make it lowercase to improve readability. 36581 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 36582 # Now convert it back to Unix-style (cygpath) 36583 input_path=`$CYGPATH -u "$shortmode_path"` 36584 new_path="$input_path" 36585 fi 36586 fi 36587 36588 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 36589 if test "x$test_cygdrive_prefix" = x; then 36590 # As a simple fix, exclude /usr/bin since it's not a real path. 36591 if test "x`$ECHO $input_to_shortpath | $GREP ^/usr/bin/`" = x; then 36592 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 36593 # a path prefixed by /cygdrive for fixpath to work. 36594 new_path="$CYGWIN_ROOT_PATH$input_path" 36595 fi 36596 fi 36597 36598 # remove trailing .exe if any 36599 new_path="${new_path/%.exe/}" 36600 36601 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 36602 36603 # First separate the path from the arguments. This will split at the first 36604 # space. 36605 complete="$CPP" 36606 path="${complete%% *}" 36607 tmp="$complete EOL" 36608 arguments="${tmp#* }" 36609 36610 # Input might be given as Windows format, start by converting to 36611 # unix format. 36612 new_path="$path" 36613 36614 windows_path="$new_path" 36615 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 36616 unix_path=`$CYGPATH -u "$windows_path"` 36617 new_path="$unix_path" 36618 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 36619 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 36620 new_path="$unix_path" 36621 fi 36622 36623 36624 # Now try to locate executable using which 36625 new_path=`$WHICH "$new_path" 2> /dev/null` 36626 36627 if test "x$new_path" = x; then 36628 # Oops. Which didn't find the executable. 36629 # The splitting of arguments from the executable at a space might have been incorrect, 36630 # since paths with space are more likely in Windows. Give it another try with the whole 36631 # argument. 36632 path="$complete" 36633 arguments="EOL" 36634 new_path="$path" 36635 36636 windows_path="$new_path" 36637 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 36638 unix_path=`$CYGPATH -u "$windows_path"` 36639 new_path="$unix_path" 36640 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 36641 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 36642 new_path="$unix_path" 36643 fi 36644 36645 36646 new_path=`$WHICH "$new_path" 2> /dev/null` 36647 # bat and cmd files are not always considered executable in MSYS causing which 36648 # to not find them 36649 if test "x$new_path" = x \ 36650 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 36651 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 36652 new_path="$path" 36653 36654 windows_path="$new_path" 36655 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 36656 unix_path=`$CYGPATH -u "$windows_path"` 36657 new_path="$unix_path" 36658 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 36659 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 36660 new_path="$unix_path" 36661 fi 36662 36663 fi 36664 36665 if test "x$new_path" = x; then 36666 # It's still not found. Now this is an unrecoverable error. 36667 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of CPP, which resolves as \"$complete\", is not found." >&5 36668 $as_echo "$as_me: The path of CPP, which resolves as \"$complete\", is not found." >&6;} 36669 has_space=`$ECHO "$complete" | $GREP " "` 36670 if test "x$has_space" != x; then 36671 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 36672 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 36673 fi 36674 as_fn_error $? "Cannot locate the the path of CPP" "$LINENO" 5 36675 fi 36676 fi 36677 36678 # Now new_path has a complete unix path to the binary 36679 if test "x`$ECHO $new_path | $GREP ^/bin/`" != x; then 36680 # Keep paths in /bin as-is, but remove trailing .exe if any 36681 new_path="${new_path/%.exe/}" 36682 # Do not save /bin paths to all_fixpath_prefixes! 36683 else 36684 # Not in mixed or Windows style, start by that. 36685 new_path=`cmd //c echo $new_path` 36686 36687 input_path="$new_path" 36688 # Check if we need to convert this using DOS-style short mode. If the path 36689 # contains just simple characters, use it. Otherwise (spaces, weird characters), 36690 # take no chances and rewrite it. 36691 # Note: m4 eats our [], so we need to use [ and ] instead. 36692 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 36693 if test "x$has_forbidden_chars" != x; then 36694 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 36695 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 36696 fi 36697 36698 # Output is in $new_path 36699 36700 windows_path="$new_path" 36701 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 36702 unix_path=`$CYGPATH -u "$windows_path"` 36703 new_path="$unix_path" 36704 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 36705 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 36706 new_path="$unix_path" 36707 fi 36708 36709 # remove trailing .exe if any 36710 new_path="${new_path/%.exe/}" 36711 36712 # Save the first 10 bytes of this path to the storage, so fixpath can work. 36713 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 36714 fi 36715 36716 else 36717 # We're on a unix platform. Hooray! :) 36718 # First separate the path from the arguments. This will split at the first 36719 # space. 36720 complete="$CPP" 36721 path="${complete%% *}" 36722 tmp="$complete EOL" 36723 arguments="${tmp#* }" 36724 36725 # Cannot rely on the command "which" here since it doesn't always work. 36726 is_absolute_path=`$ECHO "$path" | $GREP ^/` 36727 if test -z "$is_absolute_path"; then 36728 # Path to executable is not absolute. Find it. 36729 IFS_save="$IFS" 36730 IFS=: 36731 for p in $PATH; do 36732 if test -f "$p/$path" && test -x "$p/$path"; then 36733 new_path="$p/$path" 36734 break 36735 fi 36736 done 36737 IFS="$IFS_save" 36738 else 36739 # This is an absolute path, we can use it without further modifications. 36740 new_path="$path" 36741 fi 36742 36743 if test "x$new_path" = x; then 36744 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of CPP, which resolves as \"$complete\", is not found." >&5 36745 $as_echo "$as_me: The path of CPP, which resolves as \"$complete\", is not found." >&6;} 36746 has_space=`$ECHO "$complete" | $GREP " "` 36747 if test "x$has_space" != x; then 36748 { $as_echo "$as_me:${as_lineno-$LINENO}: This might be caused by spaces in the path, which is not allowed." >&5 36749 $as_echo "$as_me: This might be caused by spaces in the path, which is not allowed." >&6;} 36750 fi 36751 as_fn_error $? "Cannot locate the the path of CPP" "$LINENO" 5 36752 fi 36753 fi 36754 36755 # Now join together the path and the arguments once again 36756 if test "x$arguments" != xEOL; then 36757 new_complete="$new_path ${arguments% *}" 36758 else 36759 new_complete="$new_path" 36760 fi 36761 36762 if test "x$complete" != "x$new_complete"; then 36763 CPP="$new_complete" 36764 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting CPP to \"$new_complete\"" >&5 36765 $as_echo "$as_me: Rewriting CPP to \"$new_complete\"" >&6;} 36766 fi 36767 fi 36768 36769 ac_ext=cpp 36770 ac_cpp='$CXXCPP $CPPFLAGS' 36771 ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5' 36772 ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' 36773 ac_compiler_gnu=$ac_cv_cxx_compiler_gnu 36774 { $as_echo "$as_me:${as_lineno-$LINENO}: checking how to run the C++ preprocessor" >&5 36775 $as_echo_n "checking how to run the C++ preprocessor... " >&6; } 36776 if test -z "$CXXCPP"; then 36777 if ${ac_cv_prog_CXXCPP+:} false; then : 36778 $as_echo_n "(cached) " >&6 36779 else 36780 # Double quotes because CXXCPP needs to be expanded 36781 for CXXCPP in "$CXX -E" "/lib/cpp" 36782 do 36783 ac_preproc_ok=false 36784 for ac_cxx_preproc_warn_flag in '' yes 36785 do 36786 # Use a header file that comes with gcc, so configuring glibc 36787 # with a fresh cross-compiler works. 36788 # Prefer <limits.h> to <assert.h> if __STDC__ is defined, since 36789 # <limits.h> exists even on freestanding compilers. 36790 # On the NeXT, cc -E runs the code through the compiler's parser, 36791 # not just through cpp. "Syntax error" is here to catch this case. 36792 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 36793 /* end confdefs.h. */ 36794 #ifdef __STDC__ 36795 # include <limits.h> 36796 #else 36797 # include <assert.h> 36798 #endif 36799 Syntax error 36800 _ACEOF 36801 if ac_fn_cxx_try_cpp "$LINENO"; then : 36802 36803 else 36804 # Broken: fails on valid input. 36805 continue 36806 fi 36807 rm -f conftest.err conftest.i conftest.$ac_ext 36808 36809 # OK, works on sane cases. Now check whether nonexistent headers 36810 # can be detected and how. 36811 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 36812 /* end confdefs.h. */ 36813 #include <ac_nonexistent.h> 36814 _ACEOF 36815 if ac_fn_cxx_try_cpp "$LINENO"; then : 36816 # Broken: success on invalid input. 36817 continue 36818 else 36819 # Passes both tests. 36820 ac_preproc_ok=: 36821 break 36822 fi 36823 rm -f conftest.err conftest.i conftest.$ac_ext 36824 36825 done 36826 # Because of `break', _AC_PREPROC_IFELSE's cleaning code was skipped. 36827 rm -f conftest.i conftest.err conftest.$ac_ext 36828 if $ac_preproc_ok; then : 36829 break 36830 fi 36831 36832 done 36833 ac_cv_prog_CXXCPP=$CXXCPP 36834 36835 fi 36836 CXXCPP=$ac_cv_prog_CXXCPP 36837 else 36838 ac_cv_prog_CXXCPP=$CXXCPP 36839 fi 36840 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CXXCPP" >&5 36841 $as_echo "$CXXCPP" >&6; } 36842 ac_preproc_ok=false 36843 for ac_cxx_preproc_warn_flag in '' yes 36844 do 36845 # Use a header file that comes with gcc, so configuring glibc 36846 # with a fresh cross-compiler works. 36847 # Prefer <limits.h> to <assert.h> if __STDC__ is defined, since 36848 # <limits.h> exists even on freestanding compilers. 36849 # On the NeXT, cc -E runs the code through the compiler's parser, 36850 # not just through cpp. "Syntax error" is here to catch this case. 36851 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 36852 /* end confdefs.h. */ 36853 #ifdef __STDC__ 36854 # include <limits.h> 36855 #else 36856 # include <assert.h> 36857 #endif 36858 Syntax error 36859 _ACEOF 36860 if ac_fn_cxx_try_cpp "$LINENO"; then : 36861 36862 else 36863 # Broken: fails on valid input. 36864 continue 36865 fi 36866 rm -f conftest.err conftest.i conftest.$ac_ext 36867 36868 # OK, works on sane cases. Now check whether nonexistent headers 36869 # can be detected and how. 36870 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 36871 /* end confdefs.h. */ 36872 #include <ac_nonexistent.h> 36873 _ACEOF 36874 if ac_fn_cxx_try_cpp "$LINENO"; then : 36875 # Broken: success on invalid input. 36876 continue 36877 else 36878 # Passes both tests. 36879 ac_preproc_ok=: 36880 break 36881 fi 36882 rm -f conftest.err conftest.i conftest.$ac_ext 36883 36884 done 36885 # Because of `break', _AC_PREPROC_IFELSE's cleaning code was skipped. 36886 rm -f conftest.i conftest.err conftest.$ac_ext 36887 if $ac_preproc_ok; then : 36888 36889 else 36890 { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 36891 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;} 36892 as_fn_error $? "C++ preprocessor \"$CXXCPP\" fails sanity check 36893 See \`config.log' for more details" "$LINENO" 5; } 36894 fi 36895 36896 ac_ext=cpp 36897 ac_cpp='$CXXCPP $CPPFLAGS' 36898 ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5' 36899 ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' 36900 ac_compiler_gnu=$ac_cv_cxx_compiler_gnu 36901 36902 36903 # Only process if variable expands to non-empty 36904 36905 if test "x$CXXCPP" != x; then 36906 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 36907 36908 # First separate the path from the arguments. This will split at the first 36909 # space. 36910 complete="$CXXCPP" 36911 path="${complete%% *}" 36912 tmp="$complete EOL" 36913 arguments="${tmp#* }" 36914 36915 # Input might be given as Windows format, start by converting to 36916 # unix format. 36917 new_path=`$CYGPATH -u "$path"` 36918 36919 # Now try to locate executable using which 36920 new_path=`$WHICH "$new_path" 2> /dev/null` 36921 # bat and cmd files are not always considered executable in cygwin causing which 36922 # to not find them 36923 if test "x$new_path" = x \ 36924 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 36925 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 36926 new_path=`$CYGPATH -u "$path"` 36927 fi 36928 if test "x$new_path" = x; then 36929 # Oops. Which didn't find the executable. 36930 # The splitting of arguments from the executable at a space might have been incorrect, 36931 # since paths with space are more likely in Windows. Give it another try with the whole 36932 # argument. 36933 path="$complete" 36934 arguments="EOL" 36935 new_path=`$CYGPATH -u "$path"` 36936 new_path=`$WHICH "$new_path" 2> /dev/null` 36937 # bat and cmd files are not always considered executable in cygwin causing which 36938 # to not find them 36939 if test "x$new_path" = x \ 36940 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 36941 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 36942 new_path=`$CYGPATH -u "$path"` 36943 fi 36944 if test "x$new_path" = x; then 36945 # It's still not found. Now this is an unrecoverable error. 36946 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of CXXCPP, which resolves as \"$complete\", is not found." >&5 36947 $as_echo "$as_me: The path of CXXCPP, which resolves as \"$complete\", is not found." >&6;} 36948 has_space=`$ECHO "$complete" | $GREP " "` 36949 if test "x$has_space" != x; then 36950 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 36951 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 36952 fi 36953 as_fn_error $? "Cannot locate the the path of CXXCPP" "$LINENO" 5 36954 fi 36955 fi 36956 36957 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 36958 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 36959 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 36960 # "foo.exe" is OK but "foo" is an error. 36961 # 36962 # This test is therefore slightly more accurate than "test -f" to check for file presence. 36963 # It is also a way to make sure we got the proper file name for the real test later on. 36964 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 36965 if test "x$test_shortpath" = x; then 36966 # Short path failed, file does not exist as specified. 36967 # Try adding .exe or .cmd 36968 if test -f "${new_path}.exe"; then 36969 input_to_shortpath="${new_path}.exe" 36970 elif test -f "${new_path}.cmd"; then 36971 input_to_shortpath="${new_path}.cmd" 36972 else 36973 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of CXXCPP, which resolves as \"$new_path\", is invalid." >&5 36974 $as_echo "$as_me: The path of CXXCPP, which resolves as \"$new_path\", is invalid." >&6;} 36975 { $as_echo "$as_me:${as_lineno-$LINENO}: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&5 36976 $as_echo "$as_me: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&6;} 36977 as_fn_error $? "Cannot locate the the path of CXXCPP" "$LINENO" 5 36978 fi 36979 else 36980 input_to_shortpath="$new_path" 36981 fi 36982 36983 # Call helper function which possibly converts this using DOS-style short mode. 36984 # If so, the updated path is stored in $new_path. 36985 new_path="$input_to_shortpath" 36986 36987 input_path="$input_to_shortpath" 36988 # Check if we need to convert this using DOS-style short mode. If the path 36989 # contains just simple characters, use it. Otherwise (spaces, weird characters), 36990 # take no chances and rewrite it. 36991 # Note: m4 eats our [], so we need to use [ and ] instead. 36992 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 36993 if test "x$has_forbidden_chars" != x; then 36994 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 36995 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 36996 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 36997 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 36998 # Going to short mode and back again did indeed matter. Since short mode is 36999 # case insensitive, let's make it lowercase to improve readability. 37000 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 37001 # Now convert it back to Unix-style (cygpath) 37002 input_path=`$CYGPATH -u "$shortmode_path"` 37003 new_path="$input_path" 37004 fi 37005 fi 37006 37007 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 37008 if test "x$test_cygdrive_prefix" = x; then 37009 # As a simple fix, exclude /usr/bin since it's not a real path. 37010 if test "x`$ECHO $input_to_shortpath | $GREP ^/usr/bin/`" = x; then 37011 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 37012 # a path prefixed by /cygdrive for fixpath to work. 37013 new_path="$CYGWIN_ROOT_PATH$input_path" 37014 fi 37015 fi 37016 37017 # remove trailing .exe if any 37018 new_path="${new_path/%.exe/}" 37019 37020 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 37021 37022 # First separate the path from the arguments. This will split at the first 37023 # space. 37024 complete="$CXXCPP" 37025 path="${complete%% *}" 37026 tmp="$complete EOL" 37027 arguments="${tmp#* }" 37028 37029 # Input might be given as Windows format, start by converting to 37030 # unix format. 37031 new_path="$path" 37032 37033 windows_path="$new_path" 37034 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 37035 unix_path=`$CYGPATH -u "$windows_path"` 37036 new_path="$unix_path" 37037 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 37038 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 37039 new_path="$unix_path" 37040 fi 37041 37042 37043 # Now try to locate executable using which 37044 new_path=`$WHICH "$new_path" 2> /dev/null` 37045 37046 if test "x$new_path" = x; then 37047 # Oops. Which didn't find the executable. 37048 # The splitting of arguments from the executable at a space might have been incorrect, 37049 # since paths with space are more likely in Windows. Give it another try with the whole 37050 # argument. 37051 path="$complete" 37052 arguments="EOL" 37053 new_path="$path" 37054 37055 windows_path="$new_path" 37056 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 37057 unix_path=`$CYGPATH -u "$windows_path"` 37058 new_path="$unix_path" 37059 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 37060 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 37061 new_path="$unix_path" 37062 fi 37063 37064 37065 new_path=`$WHICH "$new_path" 2> /dev/null` 37066 # bat and cmd files are not always considered executable in MSYS causing which 37067 # to not find them 37068 if test "x$new_path" = x \ 37069 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 37070 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 37071 new_path="$path" 37072 37073 windows_path="$new_path" 37074 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 37075 unix_path=`$CYGPATH -u "$windows_path"` 37076 new_path="$unix_path" 37077 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 37078 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 37079 new_path="$unix_path" 37080 fi 37081 37082 fi 37083 37084 if test "x$new_path" = x; then 37085 # It's still not found. Now this is an unrecoverable error. 37086 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of CXXCPP, which resolves as \"$complete\", is not found." >&5 37087 $as_echo "$as_me: The path of CXXCPP, which resolves as \"$complete\", is not found." >&6;} 37088 has_space=`$ECHO "$complete" | $GREP " "` 37089 if test "x$has_space" != x; then 37090 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 37091 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 37092 fi 37093 as_fn_error $? "Cannot locate the the path of CXXCPP" "$LINENO" 5 37094 fi 37095 fi 37096 37097 # Now new_path has a complete unix path to the binary 37098 if test "x`$ECHO $new_path | $GREP ^/bin/`" != x; then 37099 # Keep paths in /bin as-is, but remove trailing .exe if any 37100 new_path="${new_path/%.exe/}" 37101 # Do not save /bin paths to all_fixpath_prefixes! 37102 else 37103 # Not in mixed or Windows style, start by that. 37104 new_path=`cmd //c echo $new_path` 37105 37106 input_path="$new_path" 37107 # Check if we need to convert this using DOS-style short mode. If the path 37108 # contains just simple characters, use it. Otherwise (spaces, weird characters), 37109 # take no chances and rewrite it. 37110 # Note: m4 eats our [], so we need to use [ and ] instead. 37111 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 37112 if test "x$has_forbidden_chars" != x; then 37113 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 37114 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 37115 fi 37116 37117 # Output is in $new_path 37118 37119 windows_path="$new_path" 37120 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 37121 unix_path=`$CYGPATH -u "$windows_path"` 37122 new_path="$unix_path" 37123 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 37124 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 37125 new_path="$unix_path" 37126 fi 37127 37128 # remove trailing .exe if any 37129 new_path="${new_path/%.exe/}" 37130 37131 # Save the first 10 bytes of this path to the storage, so fixpath can work. 37132 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 37133 fi 37134 37135 else 37136 # We're on a unix platform. Hooray! :) 37137 # First separate the path from the arguments. This will split at the first 37138 # space. 37139 complete="$CXXCPP" 37140 path="${complete%% *}" 37141 tmp="$complete EOL" 37142 arguments="${tmp#* }" 37143 37144 # Cannot rely on the command "which" here since it doesn't always work. 37145 is_absolute_path=`$ECHO "$path" | $GREP ^/` 37146 if test -z "$is_absolute_path"; then 37147 # Path to executable is not absolute. Find it. 37148 IFS_save="$IFS" 37149 IFS=: 37150 for p in $PATH; do 37151 if test -f "$p/$path" && test -x "$p/$path"; then 37152 new_path="$p/$path" 37153 break 37154 fi 37155 done 37156 IFS="$IFS_save" 37157 else 37158 # This is an absolute path, we can use it without further modifications. 37159 new_path="$path" 37160 fi 37161 37162 if test "x$new_path" = x; then 37163 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of CXXCPP, which resolves as \"$complete\", is not found." >&5 37164 $as_echo "$as_me: The path of CXXCPP, which resolves as \"$complete\", is not found." >&6;} 37165 has_space=`$ECHO "$complete" | $GREP " "` 37166 if test "x$has_space" != x; then 37167 { $as_echo "$as_me:${as_lineno-$LINENO}: This might be caused by spaces in the path, which is not allowed." >&5 37168 $as_echo "$as_me: This might be caused by spaces in the path, which is not allowed." >&6;} 37169 fi 37170 as_fn_error $? "Cannot locate the the path of CXXCPP" "$LINENO" 5 37171 fi 37172 fi 37173 37174 # Now join together the path and the arguments once again 37175 if test "x$arguments" != xEOL; then 37176 new_complete="$new_path ${arguments% *}" 37177 else 37178 new_complete="$new_path" 37179 fi 37180 37181 if test "x$complete" != "x$new_complete"; then 37182 CXXCPP="$new_complete" 37183 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting CXXCPP to \"$new_complete\"" >&5 37184 $as_echo "$as_me: Rewriting CXXCPP to \"$new_complete\"" >&6;} 37185 fi 37186 fi 37187 37188 37189 # 37190 # Setup the linker (LD) 37191 # 37192 if test "x$TOOLCHAIN_TYPE" = xmicrosoft; then 37193 # In the Microsoft toolchain we have a separate LD command "link". 37194 # Make sure we reject /usr/bin/link (as determined in CYGWIN_LINK), which is 37195 # a cygwin program for something completely different. 37196 # Extract the first word of "link", so it can be a program name with args. 37197 set dummy link; ac_word=$2 37198 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 37199 $as_echo_n "checking for $ac_word... " >&6; } 37200 if ${ac_cv_prog_LD+:} false; then : 37201 $as_echo_n "(cached) " >&6 37202 else 37203 if test -n "$LD"; then 37204 ac_cv_prog_LD="$LD" # Let the user override the test. 37205 else 37206 ac_prog_rejected=no 37207 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 37208 for as_dir in $PATH 37209 do 37210 IFS=$as_save_IFS 37211 test -z "$as_dir" && as_dir=. 37212 for ac_exec_ext in '' $ac_executable_extensions; do 37213 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 37214 if test "$as_dir/$ac_word$ac_exec_ext" = "$CYGWIN_LINK"; then 37215 ac_prog_rejected=yes 37216 continue 37217 fi 37218 ac_cv_prog_LD="link" 37219 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 37220 break 2 37221 fi 37222 done 37223 done 37224 IFS=$as_save_IFS 37225 37226 if test $ac_prog_rejected = yes; then 37227 # We found a bogon in the path, so make sure we never use it. 37228 set dummy $ac_cv_prog_LD 37229 shift 37230 if test $# != 0; then 37231 # We chose a different compiler from the bogus one. 37232 # However, it has the same basename, so the bogon will be chosen 37233 # first if we set LD to just the basename; use the full file name. 37234 shift 37235 ac_cv_prog_LD="$as_dir/$ac_word${1+' '}$@" 37236 fi 37237 fi 37238 fi 37239 fi 37240 LD=$ac_cv_prog_LD 37241 if test -n "$LD"; then 37242 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $LD" >&5 37243 $as_echo "$LD" >&6; } 37244 else 37245 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 37246 $as_echo "no" >&6; } 37247 fi 37248 37249 37250 37251 # Only process if variable expands to non-empty 37252 37253 if test "x$LD" != x; then 37254 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 37255 37256 # First separate the path from the arguments. This will split at the first 37257 # space. 37258 complete="$LD" 37259 path="${complete%% *}" 37260 tmp="$complete EOL" 37261 arguments="${tmp#* }" 37262 37263 # Input might be given as Windows format, start by converting to 37264 # unix format. 37265 new_path=`$CYGPATH -u "$path"` 37266 37267 # Now try to locate executable using which 37268 new_path=`$WHICH "$new_path" 2> /dev/null` 37269 # bat and cmd files are not always considered executable in cygwin causing which 37270 # to not find them 37271 if test "x$new_path" = x \ 37272 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 37273 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 37274 new_path=`$CYGPATH -u "$path"` 37275 fi 37276 if test "x$new_path" = x; then 37277 # Oops. Which didn't find the executable. 37278 # The splitting of arguments from the executable at a space might have been incorrect, 37279 # since paths with space are more likely in Windows. Give it another try with the whole 37280 # argument. 37281 path="$complete" 37282 arguments="EOL" 37283 new_path=`$CYGPATH -u "$path"` 37284 new_path=`$WHICH "$new_path" 2> /dev/null` 37285 # bat and cmd files are not always considered executable in cygwin causing which 37286 # to not find them 37287 if test "x$new_path" = x \ 37288 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 37289 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 37290 new_path=`$CYGPATH -u "$path"` 37291 fi 37292 if test "x$new_path" = x; then 37293 # It's still not found. Now this is an unrecoverable error. 37294 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of LD, which resolves as \"$complete\", is not found." >&5 37295 $as_echo "$as_me: The path of LD, which resolves as \"$complete\", is not found." >&6;} 37296 has_space=`$ECHO "$complete" | $GREP " "` 37297 if test "x$has_space" != x; then 37298 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 37299 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 37300 fi 37301 as_fn_error $? "Cannot locate the the path of LD" "$LINENO" 5 37302 fi 37303 fi 37304 37305 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 37306 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 37307 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 37308 # "foo.exe" is OK but "foo" is an error. 37309 # 37310 # This test is therefore slightly more accurate than "test -f" to check for file presence. 37311 # It is also a way to make sure we got the proper file name for the real test later on. 37312 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 37313 if test "x$test_shortpath" = x; then 37314 # Short path failed, file does not exist as specified. 37315 # Try adding .exe or .cmd 37316 if test -f "${new_path}.exe"; then 37317 input_to_shortpath="${new_path}.exe" 37318 elif test -f "${new_path}.cmd"; then 37319 input_to_shortpath="${new_path}.cmd" 37320 else 37321 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of LD, which resolves as \"$new_path\", is invalid." >&5 37322 $as_echo "$as_me: The path of LD, which resolves as \"$new_path\", is invalid." >&6;} 37323 { $as_echo "$as_me:${as_lineno-$LINENO}: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&5 37324 $as_echo "$as_me: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&6;} 37325 as_fn_error $? "Cannot locate the the path of LD" "$LINENO" 5 37326 fi 37327 else 37328 input_to_shortpath="$new_path" 37329 fi 37330 37331 # Call helper function which possibly converts this using DOS-style short mode. 37332 # If so, the updated path is stored in $new_path. 37333 new_path="$input_to_shortpath" 37334 37335 input_path="$input_to_shortpath" 37336 # Check if we need to convert this using DOS-style short mode. If the path 37337 # contains just simple characters, use it. Otherwise (spaces, weird characters), 37338 # take no chances and rewrite it. 37339 # Note: m4 eats our [], so we need to use [ and ] instead. 37340 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 37341 if test "x$has_forbidden_chars" != x; then 37342 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 37343 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 37344 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 37345 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 37346 # Going to short mode and back again did indeed matter. Since short mode is 37347 # case insensitive, let's make it lowercase to improve readability. 37348 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 37349 # Now convert it back to Unix-style (cygpath) 37350 input_path=`$CYGPATH -u "$shortmode_path"` 37351 new_path="$input_path" 37352 fi 37353 fi 37354 37355 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 37356 if test "x$test_cygdrive_prefix" = x; then 37357 # As a simple fix, exclude /usr/bin since it's not a real path. 37358 if test "x`$ECHO $input_to_shortpath | $GREP ^/usr/bin/`" = x; then 37359 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 37360 # a path prefixed by /cygdrive for fixpath to work. 37361 new_path="$CYGWIN_ROOT_PATH$input_path" 37362 fi 37363 fi 37364 37365 # remove trailing .exe if any 37366 new_path="${new_path/%.exe/}" 37367 37368 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 37369 37370 # First separate the path from the arguments. This will split at the first 37371 # space. 37372 complete="$LD" 37373 path="${complete%% *}" 37374 tmp="$complete EOL" 37375 arguments="${tmp#* }" 37376 37377 # Input might be given as Windows format, start by converting to 37378 # unix format. 37379 new_path="$path" 37380 37381 windows_path="$new_path" 37382 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 37383 unix_path=`$CYGPATH -u "$windows_path"` 37384 new_path="$unix_path" 37385 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 37386 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 37387 new_path="$unix_path" 37388 fi 37389 37390 37391 # Now try to locate executable using which 37392 new_path=`$WHICH "$new_path" 2> /dev/null` 37393 37394 if test "x$new_path" = x; then 37395 # Oops. Which didn't find the executable. 37396 # The splitting of arguments from the executable at a space might have been incorrect, 37397 # since paths with space are more likely in Windows. Give it another try with the whole 37398 # argument. 37399 path="$complete" 37400 arguments="EOL" 37401 new_path="$path" 37402 37403 windows_path="$new_path" 37404 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 37405 unix_path=`$CYGPATH -u "$windows_path"` 37406 new_path="$unix_path" 37407 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 37408 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 37409 new_path="$unix_path" 37410 fi 37411 37412 37413 new_path=`$WHICH "$new_path" 2> /dev/null` 37414 # bat and cmd files are not always considered executable in MSYS causing which 37415 # to not find them 37416 if test "x$new_path" = x \ 37417 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 37418 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 37419 new_path="$path" 37420 37421 windows_path="$new_path" 37422 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 37423 unix_path=`$CYGPATH -u "$windows_path"` 37424 new_path="$unix_path" 37425 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 37426 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 37427 new_path="$unix_path" 37428 fi 37429 37430 fi 37431 37432 if test "x$new_path" = x; then 37433 # It's still not found. Now this is an unrecoverable error. 37434 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of LD, which resolves as \"$complete\", is not found." >&5 37435 $as_echo "$as_me: The path of LD, which resolves as \"$complete\", is not found." >&6;} 37436 has_space=`$ECHO "$complete" | $GREP " "` 37437 if test "x$has_space" != x; then 37438 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 37439 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 37440 fi 37441 as_fn_error $? "Cannot locate the the path of LD" "$LINENO" 5 37442 fi 37443 fi 37444 37445 # Now new_path has a complete unix path to the binary 37446 if test "x`$ECHO $new_path | $GREP ^/bin/`" != x; then 37447 # Keep paths in /bin as-is, but remove trailing .exe if any 37448 new_path="${new_path/%.exe/}" 37449 # Do not save /bin paths to all_fixpath_prefixes! 37450 else 37451 # Not in mixed or Windows style, start by that. 37452 new_path=`cmd //c echo $new_path` 37453 37454 input_path="$new_path" 37455 # Check if we need to convert this using DOS-style short mode. If the path 37456 # contains just simple characters, use it. Otherwise (spaces, weird characters), 37457 # take no chances and rewrite it. 37458 # Note: m4 eats our [], so we need to use [ and ] instead. 37459 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 37460 if test "x$has_forbidden_chars" != x; then 37461 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 37462 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 37463 fi 37464 37465 # Output is in $new_path 37466 37467 windows_path="$new_path" 37468 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 37469 unix_path=`$CYGPATH -u "$windows_path"` 37470 new_path="$unix_path" 37471 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 37472 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 37473 new_path="$unix_path" 37474 fi 37475 37476 # remove trailing .exe if any 37477 new_path="${new_path/%.exe/}" 37478 37479 # Save the first 10 bytes of this path to the storage, so fixpath can work. 37480 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 37481 fi 37482 37483 else 37484 # We're on a unix platform. Hooray! :) 37485 # First separate the path from the arguments. This will split at the first 37486 # space. 37487 complete="$LD" 37488 path="${complete%% *}" 37489 tmp="$complete EOL" 37490 arguments="${tmp#* }" 37491 37492 # Cannot rely on the command "which" here since it doesn't always work. 37493 is_absolute_path=`$ECHO "$path" | $GREP ^/` 37494 if test -z "$is_absolute_path"; then 37495 # Path to executable is not absolute. Find it. 37496 IFS_save="$IFS" 37497 IFS=: 37498 for p in $PATH; do 37499 if test -f "$p/$path" && test -x "$p/$path"; then 37500 new_path="$p/$path" 37501 break 37502 fi 37503 done 37504 IFS="$IFS_save" 37505 else 37506 # This is an absolute path, we can use it without further modifications. 37507 new_path="$path" 37508 fi 37509 37510 if test "x$new_path" = x; then 37511 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of LD, which resolves as \"$complete\", is not found." >&5 37512 $as_echo "$as_me: The path of LD, which resolves as \"$complete\", is not found." >&6;} 37513 has_space=`$ECHO "$complete" | $GREP " "` 37514 if test "x$has_space" != x; then 37515 { $as_echo "$as_me:${as_lineno-$LINENO}: This might be caused by spaces in the path, which is not allowed." >&5 37516 $as_echo "$as_me: This might be caused by spaces in the path, which is not allowed." >&6;} 37517 fi 37518 as_fn_error $? "Cannot locate the the path of LD" "$LINENO" 5 37519 fi 37520 fi 37521 37522 # Now join together the path and the arguments once again 37523 if test "x$arguments" != xEOL; then 37524 new_complete="$new_path ${arguments% *}" 37525 else 37526 new_complete="$new_path" 37527 fi 37528 37529 if test "x$complete" != "x$new_complete"; then 37530 LD="$new_complete" 37531 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting LD to \"$new_complete\"" >&5 37532 $as_echo "$as_me: Rewriting LD to \"$new_complete\"" >&6;} 37533 fi 37534 fi 37535 37536 # Verify that we indeed succeeded with this trick. 37537 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if the found link.exe is actually the Visual Studio linker" >&5 37538 $as_echo_n "checking if the found link.exe is actually the Visual Studio linker... " >&6; } 37539 "$LD" --version > /dev/null 37540 if test $? -eq 0 ; then 37541 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 37542 $as_echo "no" >&6; } 37543 as_fn_error $? "This is the Cygwin link tool. Please check your PATH and rerun configure." "$LINENO" 5 37544 else 37545 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 37546 $as_echo "yes" >&6; } 37547 fi 37548 LDCXX="$LD" 37549 else 37550 # All other toolchains use the compiler to link. 37551 LD="$CC" 37552 LDCXX="$CXX" 37553 fi 37554 37555 # FIXME: it should be CXXLD, according to standard (cf CXXCPP) 37556 37557 37558 # 37559 # Setup the assembler (AS) 37560 # 37561 if test "x$OPENJDK_TARGET_OS" = xsolaris; then 37562 37563 37564 # Publish this variable in the help. 37565 37566 37567 if [ -z "${AS+x}" ]; then 37568 # The variable is not set by user, try to locate tool using the code snippet 37569 for ac_prog in as 37570 do 37571 # Extract the first word of "$ac_prog", so it can be a program name with args. 37572 set dummy $ac_prog; ac_word=$2 37573 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 37574 $as_echo_n "checking for $ac_word... " >&6; } 37575 if ${ac_cv_path_AS+:} false; then : 37576 $as_echo_n "(cached) " >&6 37577 else 37578 case $AS in 37579 [\\/]* | ?:[\\/]*) 37580 ac_cv_path_AS="$AS" # Let the user override the test with a path. 37581 ;; 37582 *) 37583 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 37584 for as_dir in $PATH 37585 do 37586 IFS=$as_save_IFS 37587 test -z "$as_dir" && as_dir=. 37588 for ac_exec_ext in '' $ac_executable_extensions; do 37589 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 37590 ac_cv_path_AS="$as_dir/$ac_word$ac_exec_ext" 37591 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 37592 break 2 37593 fi 37594 done 37595 done 37596 IFS=$as_save_IFS 37597 37598 ;; 37599 esac 37600 fi 37601 AS=$ac_cv_path_AS 37602 if test -n "$AS"; then 37603 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $AS" >&5 37604 $as_echo "$AS" >&6; } 37605 else 37606 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 37607 $as_echo "no" >&6; } 37608 fi 37609 37610 37611 test -n "$AS" && break 37612 done 37613 37614 else 37615 # The variable is set, but is it from the command line or the environment? 37616 37617 # Try to remove the string !AS! from our list. 37618 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!AS!/} 37619 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 37620 # If it failed, the variable was not from the command line. Ignore it, 37621 # but warn the user (except for BASH, which is always set by the calling BASH). 37622 if test "xAS" != xBASH; then 37623 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of AS from the environment. Use command line variables instead." >&5 37624 $as_echo "$as_me: WARNING: Ignoring value of AS from the environment. Use command line variables instead." >&2;} 37625 fi 37626 # Try to locate tool using the code snippet 37627 for ac_prog in as 37628 do 37629 # Extract the first word of "$ac_prog", so it can be a program name with args. 37630 set dummy $ac_prog; ac_word=$2 37631 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 37632 $as_echo_n "checking for $ac_word... " >&6; } 37633 if ${ac_cv_path_AS+:} false; then : 37634 $as_echo_n "(cached) " >&6 37635 else 37636 case $AS in 37637 [\\/]* | ?:[\\/]*) 37638 ac_cv_path_AS="$AS" # Let the user override the test with a path. 37639 ;; 37640 *) 37641 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 37642 for as_dir in $PATH 37643 do 37644 IFS=$as_save_IFS 37645 test -z "$as_dir" && as_dir=. 37646 for ac_exec_ext in '' $ac_executable_extensions; do 37647 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 37648 ac_cv_path_AS="$as_dir/$ac_word$ac_exec_ext" 37649 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 37650 break 2 37651 fi 37652 done 37653 done 37654 IFS=$as_save_IFS 37655 37656 ;; 37657 esac 37658 fi 37659 AS=$ac_cv_path_AS 37660 if test -n "$AS"; then 37661 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $AS" >&5 37662 $as_echo "$AS" >&6; } 37663 else 37664 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 37665 $as_echo "no" >&6; } 37666 fi 37667 37668 37669 test -n "$AS" && break 37670 done 37671 37672 else 37673 # If it succeeded, then it was overridden by the user. We will use it 37674 # for the tool. 37675 37676 # First remove it from the list of overridden variables, so we can test 37677 # for unknown variables in the end. 37678 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 37679 37680 # Check if we try to supply an empty value 37681 if test "x$AS" = x; then 37682 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool AS= (no value)" >&5 37683 $as_echo "$as_me: Setting user supplied tool AS= (no value)" >&6;} 37684 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for AS" >&5 37685 $as_echo_n "checking for AS... " >&6; } 37686 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 37687 $as_echo "disabled" >&6; } 37688 else 37689 # Check if the provided tool contains a complete path. 37690 tool_specified="$AS" 37691 tool_basename="${tool_specified##*/}" 37692 if test "x$tool_basename" = "x$tool_specified"; then 37693 # A command without a complete path is provided, search $PATH. 37694 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool AS=$tool_basename" >&5 37695 $as_echo "$as_me: Will search for user supplied tool AS=$tool_basename" >&6;} 37696 # Extract the first word of "$tool_basename", so it can be a program name with args. 37697 set dummy $tool_basename; ac_word=$2 37698 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 37699 $as_echo_n "checking for $ac_word... " >&6; } 37700 if ${ac_cv_path_AS+:} false; then : 37701 $as_echo_n "(cached) " >&6 37702 else 37703 case $AS in 37704 [\\/]* | ?:[\\/]*) 37705 ac_cv_path_AS="$AS" # Let the user override the test with a path. 37706 ;; 37707 *) 37708 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 37709 for as_dir in $PATH 37710 do 37711 IFS=$as_save_IFS 37712 test -z "$as_dir" && as_dir=. 37713 for ac_exec_ext in '' $ac_executable_extensions; do 37714 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 37715 ac_cv_path_AS="$as_dir/$ac_word$ac_exec_ext" 37716 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 37717 break 2 37718 fi 37719 done 37720 done 37721 IFS=$as_save_IFS 37722 37723 ;; 37724 esac 37725 fi 37726 AS=$ac_cv_path_AS 37727 if test -n "$AS"; then 37728 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $AS" >&5 37729 $as_echo "$AS" >&6; } 37730 else 37731 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 37732 $as_echo "no" >&6; } 37733 fi 37734 37735 37736 if test "x$AS" = x; then 37737 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 37738 fi 37739 else 37740 # Otherwise we believe it is a complete path. Use it as it is. 37741 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool AS=$tool_specified" >&5 37742 $as_echo "$as_me: Will use user supplied tool AS=$tool_specified" >&6;} 37743 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for AS" >&5 37744 $as_echo_n "checking for AS... " >&6; } 37745 if test ! -x "$tool_specified"; then 37746 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 37747 $as_echo "not found" >&6; } 37748 as_fn_error $? "User supplied tool AS=$tool_specified does not exist or is not executable" "$LINENO" 5 37749 fi 37750 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 37751 $as_echo "$tool_specified" >&6; } 37752 fi 37753 fi 37754 fi 37755 37756 fi 37757 37758 37759 37760 # Only process if variable expands to non-empty 37761 37762 if test "x$AS" != x; then 37763 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 37764 37765 # First separate the path from the arguments. This will split at the first 37766 # space. 37767 complete="$AS" 37768 path="${complete%% *}" 37769 tmp="$complete EOL" 37770 arguments="${tmp#* }" 37771 37772 # Input might be given as Windows format, start by converting to 37773 # unix format. 37774 new_path=`$CYGPATH -u "$path"` 37775 37776 # Now try to locate executable using which 37777 new_path=`$WHICH "$new_path" 2> /dev/null` 37778 # bat and cmd files are not always considered executable in cygwin causing which 37779 # to not find them 37780 if test "x$new_path" = x \ 37781 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 37782 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 37783 new_path=`$CYGPATH -u "$path"` 37784 fi 37785 if test "x$new_path" = x; then 37786 # Oops. Which didn't find the executable. 37787 # The splitting of arguments from the executable at a space might have been incorrect, 37788 # since paths with space are more likely in Windows. Give it another try with the whole 37789 # argument. 37790 path="$complete" 37791 arguments="EOL" 37792 new_path=`$CYGPATH -u "$path"` 37793 new_path=`$WHICH "$new_path" 2> /dev/null` 37794 # bat and cmd files are not always considered executable in cygwin causing which 37795 # to not find them 37796 if test "x$new_path" = x \ 37797 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 37798 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 37799 new_path=`$CYGPATH -u "$path"` 37800 fi 37801 if test "x$new_path" = x; then 37802 # It's still not found. Now this is an unrecoverable error. 37803 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of AS, which resolves as \"$complete\", is not found." >&5 37804 $as_echo "$as_me: The path of AS, which resolves as \"$complete\", is not found." >&6;} 37805 has_space=`$ECHO "$complete" | $GREP " "` 37806 if test "x$has_space" != x; then 37807 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 37808 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 37809 fi 37810 as_fn_error $? "Cannot locate the the path of AS" "$LINENO" 5 37811 fi 37812 fi 37813 37814 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 37815 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 37816 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 37817 # "foo.exe" is OK but "foo" is an error. 37818 # 37819 # This test is therefore slightly more accurate than "test -f" to check for file presence. 37820 # It is also a way to make sure we got the proper file name for the real test later on. 37821 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 37822 if test "x$test_shortpath" = x; then 37823 # Short path failed, file does not exist as specified. 37824 # Try adding .exe or .cmd 37825 if test -f "${new_path}.exe"; then 37826 input_to_shortpath="${new_path}.exe" 37827 elif test -f "${new_path}.cmd"; then 37828 input_to_shortpath="${new_path}.cmd" 37829 else 37830 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of AS, which resolves as \"$new_path\", is invalid." >&5 37831 $as_echo "$as_me: The path of AS, which resolves as \"$new_path\", is invalid." >&6;} 37832 { $as_echo "$as_me:${as_lineno-$LINENO}: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&5 37833 $as_echo "$as_me: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&6;} 37834 as_fn_error $? "Cannot locate the the path of AS" "$LINENO" 5 37835 fi 37836 else 37837 input_to_shortpath="$new_path" 37838 fi 37839 37840 # Call helper function which possibly converts this using DOS-style short mode. 37841 # If so, the updated path is stored in $new_path. 37842 new_path="$input_to_shortpath" 37843 37844 input_path="$input_to_shortpath" 37845 # Check if we need to convert this using DOS-style short mode. If the path 37846 # contains just simple characters, use it. Otherwise (spaces, weird characters), 37847 # take no chances and rewrite it. 37848 # Note: m4 eats our [], so we need to use [ and ] instead. 37849 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 37850 if test "x$has_forbidden_chars" != x; then 37851 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 37852 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 37853 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 37854 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 37855 # Going to short mode and back again did indeed matter. Since short mode is 37856 # case insensitive, let's make it lowercase to improve readability. 37857 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 37858 # Now convert it back to Unix-style (cygpath) 37859 input_path=`$CYGPATH -u "$shortmode_path"` 37860 new_path="$input_path" 37861 fi 37862 fi 37863 37864 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 37865 if test "x$test_cygdrive_prefix" = x; then 37866 # As a simple fix, exclude /usr/bin since it's not a real path. 37867 if test "x`$ECHO $input_to_shortpath | $GREP ^/usr/bin/`" = x; then 37868 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 37869 # a path prefixed by /cygdrive for fixpath to work. 37870 new_path="$CYGWIN_ROOT_PATH$input_path" 37871 fi 37872 fi 37873 37874 # remove trailing .exe if any 37875 new_path="${new_path/%.exe/}" 37876 37877 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 37878 37879 # First separate the path from the arguments. This will split at the first 37880 # space. 37881 complete="$AS" 37882 path="${complete%% *}" 37883 tmp="$complete EOL" 37884 arguments="${tmp#* }" 37885 37886 # Input might be given as Windows format, start by converting to 37887 # unix format. 37888 new_path="$path" 37889 37890 windows_path="$new_path" 37891 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 37892 unix_path=`$CYGPATH -u "$windows_path"` 37893 new_path="$unix_path" 37894 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 37895 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 37896 new_path="$unix_path" 37897 fi 37898 37899 37900 # Now try to locate executable using which 37901 new_path=`$WHICH "$new_path" 2> /dev/null` 37902 37903 if test "x$new_path" = x; then 37904 # Oops. Which didn't find the executable. 37905 # The splitting of arguments from the executable at a space might have been incorrect, 37906 # since paths with space are more likely in Windows. Give it another try with the whole 37907 # argument. 37908 path="$complete" 37909 arguments="EOL" 37910 new_path="$path" 37911 37912 windows_path="$new_path" 37913 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 37914 unix_path=`$CYGPATH -u "$windows_path"` 37915 new_path="$unix_path" 37916 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 37917 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 37918 new_path="$unix_path" 37919 fi 37920 37921 37922 new_path=`$WHICH "$new_path" 2> /dev/null` 37923 # bat and cmd files are not always considered executable in MSYS causing which 37924 # to not find them 37925 if test "x$new_path" = x \ 37926 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 37927 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 37928 new_path="$path" 37929 37930 windows_path="$new_path" 37931 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 37932 unix_path=`$CYGPATH -u "$windows_path"` 37933 new_path="$unix_path" 37934 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 37935 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 37936 new_path="$unix_path" 37937 fi 37938 37939 fi 37940 37941 if test "x$new_path" = x; then 37942 # It's still not found. Now this is an unrecoverable error. 37943 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of AS, which resolves as \"$complete\", is not found." >&5 37944 $as_echo "$as_me: The path of AS, which resolves as \"$complete\", is not found." >&6;} 37945 has_space=`$ECHO "$complete" | $GREP " "` 37946 if test "x$has_space" != x; then 37947 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 37948 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 37949 fi 37950 as_fn_error $? "Cannot locate the the path of AS" "$LINENO" 5 37951 fi 37952 fi 37953 37954 # Now new_path has a complete unix path to the binary 37955 if test "x`$ECHO $new_path | $GREP ^/bin/`" != x; then 37956 # Keep paths in /bin as-is, but remove trailing .exe if any 37957 new_path="${new_path/%.exe/}" 37958 # Do not save /bin paths to all_fixpath_prefixes! 37959 else 37960 # Not in mixed or Windows style, start by that. 37961 new_path=`cmd //c echo $new_path` 37962 37963 input_path="$new_path" 37964 # Check if we need to convert this using DOS-style short mode. If the path 37965 # contains just simple characters, use it. Otherwise (spaces, weird characters), 37966 # take no chances and rewrite it. 37967 # Note: m4 eats our [], so we need to use [ and ] instead. 37968 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 37969 if test "x$has_forbidden_chars" != x; then 37970 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 37971 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 37972 fi 37973 37974 # Output is in $new_path 37975 37976 windows_path="$new_path" 37977 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 37978 unix_path=`$CYGPATH -u "$windows_path"` 37979 new_path="$unix_path" 37980 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 37981 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 37982 new_path="$unix_path" 37983 fi 37984 37985 # remove trailing .exe if any 37986 new_path="${new_path/%.exe/}" 37987 37988 # Save the first 10 bytes of this path to the storage, so fixpath can work. 37989 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 37990 fi 37991 37992 else 37993 # We're on a unix platform. Hooray! :) 37994 # First separate the path from the arguments. This will split at the first 37995 # space. 37996 complete="$AS" 37997 path="${complete%% *}" 37998 tmp="$complete EOL" 37999 arguments="${tmp#* }" 38000 38001 # Cannot rely on the command "which" here since it doesn't always work. 38002 is_absolute_path=`$ECHO "$path" | $GREP ^/` 38003 if test -z "$is_absolute_path"; then 38004 # Path to executable is not absolute. Find it. 38005 IFS_save="$IFS" 38006 IFS=: 38007 for p in $PATH; do 38008 if test -f "$p/$path" && test -x "$p/$path"; then 38009 new_path="$p/$path" 38010 break 38011 fi 38012 done 38013 IFS="$IFS_save" 38014 else 38015 # This is an absolute path, we can use it without further modifications. 38016 new_path="$path" 38017 fi 38018 38019 if test "x$new_path" = x; then 38020 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of AS, which resolves as \"$complete\", is not found." >&5 38021 $as_echo "$as_me: The path of AS, which resolves as \"$complete\", is not found." >&6;} 38022 has_space=`$ECHO "$complete" | $GREP " "` 38023 if test "x$has_space" != x; then 38024 { $as_echo "$as_me:${as_lineno-$LINENO}: This might be caused by spaces in the path, which is not allowed." >&5 38025 $as_echo "$as_me: This might be caused by spaces in the path, which is not allowed." >&6;} 38026 fi 38027 as_fn_error $? "Cannot locate the the path of AS" "$LINENO" 5 38028 fi 38029 fi 38030 38031 # Now join together the path and the arguments once again 38032 if test "x$arguments" != xEOL; then 38033 new_complete="$new_path ${arguments% *}" 38034 else 38035 new_complete="$new_path" 38036 fi 38037 38038 if test "x$complete" != "x$new_complete"; then 38039 AS="$new_complete" 38040 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting AS to \"$new_complete\"" >&5 38041 $as_echo "$as_me: Rewriting AS to \"$new_complete\"" >&6;} 38042 fi 38043 fi 38044 38045 if test "x$AS" = x; then 38046 as_fn_error $? "Solaris assembler (as) is required. Please install via \"pkg install pkg:/developer/assembler\"." "$LINENO" 5 38047 fi 38048 else 38049 # FIXME: is this correct for microsoft? 38050 AS="$CC -c" 38051 fi 38052 38053 38054 # 38055 # Setup the archiver (AR) 38056 # 38057 if test "x$TOOLCHAIN_TYPE" = xmicrosoft; then 38058 # The corresponding ar tool is lib.exe (used to create static libraries) 38059 # Extract the first word of "lib", so it can be a program name with args. 38060 set dummy lib; ac_word=$2 38061 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 38062 $as_echo_n "checking for $ac_word... " >&6; } 38063 if ${ac_cv_prog_AR+:} false; then : 38064 $as_echo_n "(cached) " >&6 38065 else 38066 if test -n "$AR"; then 38067 ac_cv_prog_AR="$AR" # Let the user override the test. 38068 else 38069 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 38070 for as_dir in $PATH 38071 do 38072 IFS=$as_save_IFS 38073 test -z "$as_dir" && as_dir=. 38074 for ac_exec_ext in '' $ac_executable_extensions; do 38075 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 38076 ac_cv_prog_AR="lib" 38077 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 38078 break 2 38079 fi 38080 done 38081 done 38082 IFS=$as_save_IFS 38083 38084 fi 38085 fi 38086 AR=$ac_cv_prog_AR 38087 if test -n "$AR"; then 38088 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $AR" >&5 38089 $as_echo "$AR" >&6; } 38090 else 38091 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 38092 $as_echo "no" >&6; } 38093 fi 38094 38095 38096 elif test "x$TOOLCHAIN_TYPE" = xgcc; then 38097 38098 38099 # Publish this variable in the help. 38100 38101 38102 if [ -z "${AR+x}" ]; then 38103 # The variable is not set by user, try to locate tool using the code snippet 38104 if test -n "$ac_tool_prefix"; then 38105 for ac_prog in ar gcc-ar 38106 do 38107 # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args. 38108 set dummy $ac_tool_prefix$ac_prog; ac_word=$2 38109 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 38110 $as_echo_n "checking for $ac_word... " >&6; } 38111 if ${ac_cv_prog_AR+:} false; then : 38112 $as_echo_n "(cached) " >&6 38113 else 38114 if test -n "$AR"; then 38115 ac_cv_prog_AR="$AR" # Let the user override the test. 38116 else 38117 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 38118 for as_dir in $PATH 38119 do 38120 IFS=$as_save_IFS 38121 test -z "$as_dir" && as_dir=. 38122 for ac_exec_ext in '' $ac_executable_extensions; do 38123 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 38124 ac_cv_prog_AR="$ac_tool_prefix$ac_prog" 38125 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 38126 break 2 38127 fi 38128 done 38129 done 38130 IFS=$as_save_IFS 38131 38132 fi 38133 fi 38134 AR=$ac_cv_prog_AR 38135 if test -n "$AR"; then 38136 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $AR" >&5 38137 $as_echo "$AR" >&6; } 38138 else 38139 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 38140 $as_echo "no" >&6; } 38141 fi 38142 38143 38144 test -n "$AR" && break 38145 done 38146 fi 38147 if test -z "$AR"; then 38148 ac_ct_AR=$AR 38149 for ac_prog in ar gcc-ar 38150 do 38151 # Extract the first word of "$ac_prog", so it can be a program name with args. 38152 set dummy $ac_prog; ac_word=$2 38153 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 38154 $as_echo_n "checking for $ac_word... " >&6; } 38155 if ${ac_cv_prog_ac_ct_AR+:} false; then : 38156 $as_echo_n "(cached) " >&6 38157 else 38158 if test -n "$ac_ct_AR"; then 38159 ac_cv_prog_ac_ct_AR="$ac_ct_AR" # Let the user override the test. 38160 else 38161 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 38162 for as_dir in $PATH 38163 do 38164 IFS=$as_save_IFS 38165 test -z "$as_dir" && as_dir=. 38166 for ac_exec_ext in '' $ac_executable_extensions; do 38167 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 38168 ac_cv_prog_ac_ct_AR="$ac_prog" 38169 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 38170 break 2 38171 fi 38172 done 38173 done 38174 IFS=$as_save_IFS 38175 38176 fi 38177 fi 38178 ac_ct_AR=$ac_cv_prog_ac_ct_AR 38179 if test -n "$ac_ct_AR"; then 38180 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_AR" >&5 38181 $as_echo "$ac_ct_AR" >&6; } 38182 else 38183 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 38184 $as_echo "no" >&6; } 38185 fi 38186 38187 38188 test -n "$ac_ct_AR" && break 38189 done 38190 38191 if test "x$ac_ct_AR" = x; then 38192 AR="" 38193 else 38194 case $cross_compiling:$ac_tool_warned in 38195 yes:) 38196 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5 38197 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;} 38198 ac_tool_warned=yes ;; 38199 esac 38200 AR=$ac_ct_AR 38201 fi 38202 fi 38203 38204 else 38205 # The variable is set, but is it from the command line or the environment? 38206 38207 # Try to remove the string !AR! from our list. 38208 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!AR!/} 38209 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 38210 # If it failed, the variable was not from the command line. Ignore it, 38211 # but warn the user (except for BASH, which is always set by the calling BASH). 38212 if test "xAR" != xBASH; then 38213 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of AR from the environment. Use command line variables instead." >&5 38214 $as_echo "$as_me: WARNING: Ignoring value of AR from the environment. Use command line variables instead." >&2;} 38215 fi 38216 # Try to locate tool using the code snippet 38217 if test -n "$ac_tool_prefix"; then 38218 for ac_prog in ar gcc-ar 38219 do 38220 # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args. 38221 set dummy $ac_tool_prefix$ac_prog; ac_word=$2 38222 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 38223 $as_echo_n "checking for $ac_word... " >&6; } 38224 if ${ac_cv_prog_AR+:} false; then : 38225 $as_echo_n "(cached) " >&6 38226 else 38227 if test -n "$AR"; then 38228 ac_cv_prog_AR="$AR" # Let the user override the test. 38229 else 38230 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 38231 for as_dir in $PATH 38232 do 38233 IFS=$as_save_IFS 38234 test -z "$as_dir" && as_dir=. 38235 for ac_exec_ext in '' $ac_executable_extensions; do 38236 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 38237 ac_cv_prog_AR="$ac_tool_prefix$ac_prog" 38238 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 38239 break 2 38240 fi 38241 done 38242 done 38243 IFS=$as_save_IFS 38244 38245 fi 38246 fi 38247 AR=$ac_cv_prog_AR 38248 if test -n "$AR"; then 38249 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $AR" >&5 38250 $as_echo "$AR" >&6; } 38251 else 38252 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 38253 $as_echo "no" >&6; } 38254 fi 38255 38256 38257 test -n "$AR" && break 38258 done 38259 fi 38260 if test -z "$AR"; then 38261 ac_ct_AR=$AR 38262 for ac_prog in ar gcc-ar 38263 do 38264 # Extract the first word of "$ac_prog", so it can be a program name with args. 38265 set dummy $ac_prog; ac_word=$2 38266 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 38267 $as_echo_n "checking for $ac_word... " >&6; } 38268 if ${ac_cv_prog_ac_ct_AR+:} false; then : 38269 $as_echo_n "(cached) " >&6 38270 else 38271 if test -n "$ac_ct_AR"; then 38272 ac_cv_prog_ac_ct_AR="$ac_ct_AR" # Let the user override the test. 38273 else 38274 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 38275 for as_dir in $PATH 38276 do 38277 IFS=$as_save_IFS 38278 test -z "$as_dir" && as_dir=. 38279 for ac_exec_ext in '' $ac_executable_extensions; do 38280 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 38281 ac_cv_prog_ac_ct_AR="$ac_prog" 38282 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 38283 break 2 38284 fi 38285 done 38286 done 38287 IFS=$as_save_IFS 38288 38289 fi 38290 fi 38291 ac_ct_AR=$ac_cv_prog_ac_ct_AR 38292 if test -n "$ac_ct_AR"; then 38293 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_AR" >&5 38294 $as_echo "$ac_ct_AR" >&6; } 38295 else 38296 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 38297 $as_echo "no" >&6; } 38298 fi 38299 38300 38301 test -n "$ac_ct_AR" && break 38302 done 38303 38304 if test "x$ac_ct_AR" = x; then 38305 AR="" 38306 else 38307 case $cross_compiling:$ac_tool_warned in 38308 yes:) 38309 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5 38310 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;} 38311 ac_tool_warned=yes ;; 38312 esac 38313 AR=$ac_ct_AR 38314 fi 38315 fi 38316 38317 else 38318 # If it succeeded, then it was overridden by the user. We will use it 38319 # for the tool. 38320 38321 # First remove it from the list of overridden variables, so we can test 38322 # for unknown variables in the end. 38323 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 38324 38325 # Check if we try to supply an empty value 38326 if test "x$AR" = x; then 38327 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool AR= (no value)" >&5 38328 $as_echo "$as_me: Setting user supplied tool AR= (no value)" >&6;} 38329 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for AR" >&5 38330 $as_echo_n "checking for AR... " >&6; } 38331 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 38332 $as_echo "disabled" >&6; } 38333 else 38334 # Check if the provided tool contains a complete path. 38335 tool_specified="$AR" 38336 tool_basename="${tool_specified##*/}" 38337 if test "x$tool_basename" = "x$tool_specified"; then 38338 # A command without a complete path is provided, search $PATH. 38339 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool AR=$tool_basename" >&5 38340 $as_echo "$as_me: Will search for user supplied tool AR=$tool_basename" >&6;} 38341 # Extract the first word of "$tool_basename", so it can be a program name with args. 38342 set dummy $tool_basename; ac_word=$2 38343 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 38344 $as_echo_n "checking for $ac_word... " >&6; } 38345 if ${ac_cv_path_AR+:} false; then : 38346 $as_echo_n "(cached) " >&6 38347 else 38348 case $AR in 38349 [\\/]* | ?:[\\/]*) 38350 ac_cv_path_AR="$AR" # Let the user override the test with a path. 38351 ;; 38352 *) 38353 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 38354 for as_dir in $PATH 38355 do 38356 IFS=$as_save_IFS 38357 test -z "$as_dir" && as_dir=. 38358 for ac_exec_ext in '' $ac_executable_extensions; do 38359 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 38360 ac_cv_path_AR="$as_dir/$ac_word$ac_exec_ext" 38361 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 38362 break 2 38363 fi 38364 done 38365 done 38366 IFS=$as_save_IFS 38367 38368 ;; 38369 esac 38370 fi 38371 AR=$ac_cv_path_AR 38372 if test -n "$AR"; then 38373 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $AR" >&5 38374 $as_echo "$AR" >&6; } 38375 else 38376 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 38377 $as_echo "no" >&6; } 38378 fi 38379 38380 38381 if test "x$AR" = x; then 38382 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 38383 fi 38384 else 38385 # Otherwise we believe it is a complete path. Use it as it is. 38386 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool AR=$tool_specified" >&5 38387 $as_echo "$as_me: Will use user supplied tool AR=$tool_specified" >&6;} 38388 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for AR" >&5 38389 $as_echo_n "checking for AR... " >&6; } 38390 if test ! -x "$tool_specified"; then 38391 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 38392 $as_echo "not found" >&6; } 38393 as_fn_error $? "User supplied tool AR=$tool_specified does not exist or is not executable" "$LINENO" 5 38394 fi 38395 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 38396 $as_echo "$tool_specified" >&6; } 38397 fi 38398 fi 38399 fi 38400 38401 fi 38402 38403 38404 else 38405 38406 38407 # Publish this variable in the help. 38408 38409 38410 if [ -z "${AR+x}" ]; then 38411 # The variable is not set by user, try to locate tool using the code snippet 38412 if test -n "$ac_tool_prefix"; then 38413 for ac_prog in ar 38414 do 38415 # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args. 38416 set dummy $ac_tool_prefix$ac_prog; ac_word=$2 38417 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 38418 $as_echo_n "checking for $ac_word... " >&6; } 38419 if ${ac_cv_prog_AR+:} false; then : 38420 $as_echo_n "(cached) " >&6 38421 else 38422 if test -n "$AR"; then 38423 ac_cv_prog_AR="$AR" # Let the user override the test. 38424 else 38425 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 38426 for as_dir in $PATH 38427 do 38428 IFS=$as_save_IFS 38429 test -z "$as_dir" && as_dir=. 38430 for ac_exec_ext in '' $ac_executable_extensions; do 38431 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 38432 ac_cv_prog_AR="$ac_tool_prefix$ac_prog" 38433 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 38434 break 2 38435 fi 38436 done 38437 done 38438 IFS=$as_save_IFS 38439 38440 fi 38441 fi 38442 AR=$ac_cv_prog_AR 38443 if test -n "$AR"; then 38444 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $AR" >&5 38445 $as_echo "$AR" >&6; } 38446 else 38447 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 38448 $as_echo "no" >&6; } 38449 fi 38450 38451 38452 test -n "$AR" && break 38453 done 38454 fi 38455 if test -z "$AR"; then 38456 ac_ct_AR=$AR 38457 for ac_prog in ar 38458 do 38459 # Extract the first word of "$ac_prog", so it can be a program name with args. 38460 set dummy $ac_prog; ac_word=$2 38461 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 38462 $as_echo_n "checking for $ac_word... " >&6; } 38463 if ${ac_cv_prog_ac_ct_AR+:} false; then : 38464 $as_echo_n "(cached) " >&6 38465 else 38466 if test -n "$ac_ct_AR"; then 38467 ac_cv_prog_ac_ct_AR="$ac_ct_AR" # Let the user override the test. 38468 else 38469 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 38470 for as_dir in $PATH 38471 do 38472 IFS=$as_save_IFS 38473 test -z "$as_dir" && as_dir=. 38474 for ac_exec_ext in '' $ac_executable_extensions; do 38475 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 38476 ac_cv_prog_ac_ct_AR="$ac_prog" 38477 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 38478 break 2 38479 fi 38480 done 38481 done 38482 IFS=$as_save_IFS 38483 38484 fi 38485 fi 38486 ac_ct_AR=$ac_cv_prog_ac_ct_AR 38487 if test -n "$ac_ct_AR"; then 38488 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_AR" >&5 38489 $as_echo "$ac_ct_AR" >&6; } 38490 else 38491 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 38492 $as_echo "no" >&6; } 38493 fi 38494 38495 38496 test -n "$ac_ct_AR" && break 38497 done 38498 38499 if test "x$ac_ct_AR" = x; then 38500 AR="" 38501 else 38502 case $cross_compiling:$ac_tool_warned in 38503 yes:) 38504 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5 38505 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;} 38506 ac_tool_warned=yes ;; 38507 esac 38508 AR=$ac_ct_AR 38509 fi 38510 fi 38511 38512 else 38513 # The variable is set, but is it from the command line or the environment? 38514 38515 # Try to remove the string !AR! from our list. 38516 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!AR!/} 38517 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 38518 # If it failed, the variable was not from the command line. Ignore it, 38519 # but warn the user (except for BASH, which is always set by the calling BASH). 38520 if test "xAR" != xBASH; then 38521 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of AR from the environment. Use command line variables instead." >&5 38522 $as_echo "$as_me: WARNING: Ignoring value of AR from the environment. Use command line variables instead." >&2;} 38523 fi 38524 # Try to locate tool using the code snippet 38525 if test -n "$ac_tool_prefix"; then 38526 for ac_prog in ar 38527 do 38528 # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args. 38529 set dummy $ac_tool_prefix$ac_prog; ac_word=$2 38530 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 38531 $as_echo_n "checking for $ac_word... " >&6; } 38532 if ${ac_cv_prog_AR+:} false; then : 38533 $as_echo_n "(cached) " >&6 38534 else 38535 if test -n "$AR"; then 38536 ac_cv_prog_AR="$AR" # Let the user override the test. 38537 else 38538 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 38539 for as_dir in $PATH 38540 do 38541 IFS=$as_save_IFS 38542 test -z "$as_dir" && as_dir=. 38543 for ac_exec_ext in '' $ac_executable_extensions; do 38544 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 38545 ac_cv_prog_AR="$ac_tool_prefix$ac_prog" 38546 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 38547 break 2 38548 fi 38549 done 38550 done 38551 IFS=$as_save_IFS 38552 38553 fi 38554 fi 38555 AR=$ac_cv_prog_AR 38556 if test -n "$AR"; then 38557 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $AR" >&5 38558 $as_echo "$AR" >&6; } 38559 else 38560 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 38561 $as_echo "no" >&6; } 38562 fi 38563 38564 38565 test -n "$AR" && break 38566 done 38567 fi 38568 if test -z "$AR"; then 38569 ac_ct_AR=$AR 38570 for ac_prog in ar 38571 do 38572 # Extract the first word of "$ac_prog", so it can be a program name with args. 38573 set dummy $ac_prog; ac_word=$2 38574 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 38575 $as_echo_n "checking for $ac_word... " >&6; } 38576 if ${ac_cv_prog_ac_ct_AR+:} false; then : 38577 $as_echo_n "(cached) " >&6 38578 else 38579 if test -n "$ac_ct_AR"; then 38580 ac_cv_prog_ac_ct_AR="$ac_ct_AR" # Let the user override the test. 38581 else 38582 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 38583 for as_dir in $PATH 38584 do 38585 IFS=$as_save_IFS 38586 test -z "$as_dir" && as_dir=. 38587 for ac_exec_ext in '' $ac_executable_extensions; do 38588 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 38589 ac_cv_prog_ac_ct_AR="$ac_prog" 38590 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 38591 break 2 38592 fi 38593 done 38594 done 38595 IFS=$as_save_IFS 38596 38597 fi 38598 fi 38599 ac_ct_AR=$ac_cv_prog_ac_ct_AR 38600 if test -n "$ac_ct_AR"; then 38601 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_AR" >&5 38602 $as_echo "$ac_ct_AR" >&6; } 38603 else 38604 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 38605 $as_echo "no" >&6; } 38606 fi 38607 38608 38609 test -n "$ac_ct_AR" && break 38610 done 38611 38612 if test "x$ac_ct_AR" = x; then 38613 AR="" 38614 else 38615 case $cross_compiling:$ac_tool_warned in 38616 yes:) 38617 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5 38618 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;} 38619 ac_tool_warned=yes ;; 38620 esac 38621 AR=$ac_ct_AR 38622 fi 38623 fi 38624 38625 else 38626 # If it succeeded, then it was overridden by the user. We will use it 38627 # for the tool. 38628 38629 # First remove it from the list of overridden variables, so we can test 38630 # for unknown variables in the end. 38631 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 38632 38633 # Check if we try to supply an empty value 38634 if test "x$AR" = x; then 38635 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool AR= (no value)" >&5 38636 $as_echo "$as_me: Setting user supplied tool AR= (no value)" >&6;} 38637 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for AR" >&5 38638 $as_echo_n "checking for AR... " >&6; } 38639 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 38640 $as_echo "disabled" >&6; } 38641 else 38642 # Check if the provided tool contains a complete path. 38643 tool_specified="$AR" 38644 tool_basename="${tool_specified##*/}" 38645 if test "x$tool_basename" = "x$tool_specified"; then 38646 # A command without a complete path is provided, search $PATH. 38647 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool AR=$tool_basename" >&5 38648 $as_echo "$as_me: Will search for user supplied tool AR=$tool_basename" >&6;} 38649 # Extract the first word of "$tool_basename", so it can be a program name with args. 38650 set dummy $tool_basename; ac_word=$2 38651 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 38652 $as_echo_n "checking for $ac_word... " >&6; } 38653 if ${ac_cv_path_AR+:} false; then : 38654 $as_echo_n "(cached) " >&6 38655 else 38656 case $AR in 38657 [\\/]* | ?:[\\/]*) 38658 ac_cv_path_AR="$AR" # Let the user override the test with a path. 38659 ;; 38660 *) 38661 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 38662 for as_dir in $PATH 38663 do 38664 IFS=$as_save_IFS 38665 test -z "$as_dir" && as_dir=. 38666 for ac_exec_ext in '' $ac_executable_extensions; do 38667 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 38668 ac_cv_path_AR="$as_dir/$ac_word$ac_exec_ext" 38669 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 38670 break 2 38671 fi 38672 done 38673 done 38674 IFS=$as_save_IFS 38675 38676 ;; 38677 esac 38678 fi 38679 AR=$ac_cv_path_AR 38680 if test -n "$AR"; then 38681 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $AR" >&5 38682 $as_echo "$AR" >&6; } 38683 else 38684 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 38685 $as_echo "no" >&6; } 38686 fi 38687 38688 38689 if test "x$AR" = x; then 38690 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 38691 fi 38692 else 38693 # Otherwise we believe it is a complete path. Use it as it is. 38694 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool AR=$tool_specified" >&5 38695 $as_echo "$as_me: Will use user supplied tool AR=$tool_specified" >&6;} 38696 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for AR" >&5 38697 $as_echo_n "checking for AR... " >&6; } 38698 if test ! -x "$tool_specified"; then 38699 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 38700 $as_echo "not found" >&6; } 38701 as_fn_error $? "User supplied tool AR=$tool_specified does not exist or is not executable" "$LINENO" 5 38702 fi 38703 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 38704 $as_echo "$tool_specified" >&6; } 38705 fi 38706 fi 38707 fi 38708 38709 fi 38710 38711 38712 fi 38713 38714 # Only process if variable expands to non-empty 38715 38716 if test "x$AR" != x; then 38717 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 38718 38719 # First separate the path from the arguments. This will split at the first 38720 # space. 38721 complete="$AR" 38722 path="${complete%% *}" 38723 tmp="$complete EOL" 38724 arguments="${tmp#* }" 38725 38726 # Input might be given as Windows format, start by converting to 38727 # unix format. 38728 new_path=`$CYGPATH -u "$path"` 38729 38730 # Now try to locate executable using which 38731 new_path=`$WHICH "$new_path" 2> /dev/null` 38732 # bat and cmd files are not always considered executable in cygwin causing which 38733 # to not find them 38734 if test "x$new_path" = x \ 38735 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 38736 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 38737 new_path=`$CYGPATH -u "$path"` 38738 fi 38739 if test "x$new_path" = x; then 38740 # Oops. Which didn't find the executable. 38741 # The splitting of arguments from the executable at a space might have been incorrect, 38742 # since paths with space are more likely in Windows. Give it another try with the whole 38743 # argument. 38744 path="$complete" 38745 arguments="EOL" 38746 new_path=`$CYGPATH -u "$path"` 38747 new_path=`$WHICH "$new_path" 2> /dev/null` 38748 # bat and cmd files are not always considered executable in cygwin causing which 38749 # to not find them 38750 if test "x$new_path" = x \ 38751 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 38752 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 38753 new_path=`$CYGPATH -u "$path"` 38754 fi 38755 if test "x$new_path" = x; then 38756 # It's still not found. Now this is an unrecoverable error. 38757 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of AR, which resolves as \"$complete\", is not found." >&5 38758 $as_echo "$as_me: The path of AR, which resolves as \"$complete\", is not found." >&6;} 38759 has_space=`$ECHO "$complete" | $GREP " "` 38760 if test "x$has_space" != x; then 38761 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 38762 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 38763 fi 38764 as_fn_error $? "Cannot locate the the path of AR" "$LINENO" 5 38765 fi 38766 fi 38767 38768 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 38769 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 38770 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 38771 # "foo.exe" is OK but "foo" is an error. 38772 # 38773 # This test is therefore slightly more accurate than "test -f" to check for file presence. 38774 # It is also a way to make sure we got the proper file name for the real test later on. 38775 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 38776 if test "x$test_shortpath" = x; then 38777 # Short path failed, file does not exist as specified. 38778 # Try adding .exe or .cmd 38779 if test -f "${new_path}.exe"; then 38780 input_to_shortpath="${new_path}.exe" 38781 elif test -f "${new_path}.cmd"; then 38782 input_to_shortpath="${new_path}.cmd" 38783 else 38784 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of AR, which resolves as \"$new_path\", is invalid." >&5 38785 $as_echo "$as_me: The path of AR, which resolves as \"$new_path\", is invalid." >&6;} 38786 { $as_echo "$as_me:${as_lineno-$LINENO}: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&5 38787 $as_echo "$as_me: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&6;} 38788 as_fn_error $? "Cannot locate the the path of AR" "$LINENO" 5 38789 fi 38790 else 38791 input_to_shortpath="$new_path" 38792 fi 38793 38794 # Call helper function which possibly converts this using DOS-style short mode. 38795 # If so, the updated path is stored in $new_path. 38796 new_path="$input_to_shortpath" 38797 38798 input_path="$input_to_shortpath" 38799 # Check if we need to convert this using DOS-style short mode. If the path 38800 # contains just simple characters, use it. Otherwise (spaces, weird characters), 38801 # take no chances and rewrite it. 38802 # Note: m4 eats our [], so we need to use [ and ] instead. 38803 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 38804 if test "x$has_forbidden_chars" != x; then 38805 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 38806 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 38807 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 38808 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 38809 # Going to short mode and back again did indeed matter. Since short mode is 38810 # case insensitive, let's make it lowercase to improve readability. 38811 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 38812 # Now convert it back to Unix-style (cygpath) 38813 input_path=`$CYGPATH -u "$shortmode_path"` 38814 new_path="$input_path" 38815 fi 38816 fi 38817 38818 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 38819 if test "x$test_cygdrive_prefix" = x; then 38820 # As a simple fix, exclude /usr/bin since it's not a real path. 38821 if test "x`$ECHO $input_to_shortpath | $GREP ^/usr/bin/`" = x; then 38822 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 38823 # a path prefixed by /cygdrive for fixpath to work. 38824 new_path="$CYGWIN_ROOT_PATH$input_path" 38825 fi 38826 fi 38827 38828 # remove trailing .exe if any 38829 new_path="${new_path/%.exe/}" 38830 38831 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 38832 38833 # First separate the path from the arguments. This will split at the first 38834 # space. 38835 complete="$AR" 38836 path="${complete%% *}" 38837 tmp="$complete EOL" 38838 arguments="${tmp#* }" 38839 38840 # Input might be given as Windows format, start by converting to 38841 # unix format. 38842 new_path="$path" 38843 38844 windows_path="$new_path" 38845 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 38846 unix_path=`$CYGPATH -u "$windows_path"` 38847 new_path="$unix_path" 38848 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 38849 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 38850 new_path="$unix_path" 38851 fi 38852 38853 38854 # Now try to locate executable using which 38855 new_path=`$WHICH "$new_path" 2> /dev/null` 38856 38857 if test "x$new_path" = x; then 38858 # Oops. Which didn't find the executable. 38859 # The splitting of arguments from the executable at a space might have been incorrect, 38860 # since paths with space are more likely in Windows. Give it another try with the whole 38861 # argument. 38862 path="$complete" 38863 arguments="EOL" 38864 new_path="$path" 38865 38866 windows_path="$new_path" 38867 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 38868 unix_path=`$CYGPATH -u "$windows_path"` 38869 new_path="$unix_path" 38870 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 38871 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 38872 new_path="$unix_path" 38873 fi 38874 38875 38876 new_path=`$WHICH "$new_path" 2> /dev/null` 38877 # bat and cmd files are not always considered executable in MSYS causing which 38878 # to not find them 38879 if test "x$new_path" = x \ 38880 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 38881 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 38882 new_path="$path" 38883 38884 windows_path="$new_path" 38885 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 38886 unix_path=`$CYGPATH -u "$windows_path"` 38887 new_path="$unix_path" 38888 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 38889 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 38890 new_path="$unix_path" 38891 fi 38892 38893 fi 38894 38895 if test "x$new_path" = x; then 38896 # It's still not found. Now this is an unrecoverable error. 38897 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of AR, which resolves as \"$complete\", is not found." >&5 38898 $as_echo "$as_me: The path of AR, which resolves as \"$complete\", is not found." >&6;} 38899 has_space=`$ECHO "$complete" | $GREP " "` 38900 if test "x$has_space" != x; then 38901 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 38902 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 38903 fi 38904 as_fn_error $? "Cannot locate the the path of AR" "$LINENO" 5 38905 fi 38906 fi 38907 38908 # Now new_path has a complete unix path to the binary 38909 if test "x`$ECHO $new_path | $GREP ^/bin/`" != x; then 38910 # Keep paths in /bin as-is, but remove trailing .exe if any 38911 new_path="${new_path/%.exe/}" 38912 # Do not save /bin paths to all_fixpath_prefixes! 38913 else 38914 # Not in mixed or Windows style, start by that. 38915 new_path=`cmd //c echo $new_path` 38916 38917 input_path="$new_path" 38918 # Check if we need to convert this using DOS-style short mode. If the path 38919 # contains just simple characters, use it. Otherwise (spaces, weird characters), 38920 # take no chances and rewrite it. 38921 # Note: m4 eats our [], so we need to use [ and ] instead. 38922 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 38923 if test "x$has_forbidden_chars" != x; then 38924 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 38925 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 38926 fi 38927 38928 # Output is in $new_path 38929 38930 windows_path="$new_path" 38931 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 38932 unix_path=`$CYGPATH -u "$windows_path"` 38933 new_path="$unix_path" 38934 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 38935 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 38936 new_path="$unix_path" 38937 fi 38938 38939 # remove trailing .exe if any 38940 new_path="${new_path/%.exe/}" 38941 38942 # Save the first 10 bytes of this path to the storage, so fixpath can work. 38943 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 38944 fi 38945 38946 else 38947 # We're on a unix platform. Hooray! :) 38948 # First separate the path from the arguments. This will split at the first 38949 # space. 38950 complete="$AR" 38951 path="${complete%% *}" 38952 tmp="$complete EOL" 38953 arguments="${tmp#* }" 38954 38955 # Cannot rely on the command "which" here since it doesn't always work. 38956 is_absolute_path=`$ECHO "$path" | $GREP ^/` 38957 if test -z "$is_absolute_path"; then 38958 # Path to executable is not absolute. Find it. 38959 IFS_save="$IFS" 38960 IFS=: 38961 for p in $PATH; do 38962 if test -f "$p/$path" && test -x "$p/$path"; then 38963 new_path="$p/$path" 38964 break 38965 fi 38966 done 38967 IFS="$IFS_save" 38968 else 38969 # This is an absolute path, we can use it without further modifications. 38970 new_path="$path" 38971 fi 38972 38973 if test "x$new_path" = x; then 38974 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of AR, which resolves as \"$complete\", is not found." >&5 38975 $as_echo "$as_me: The path of AR, which resolves as \"$complete\", is not found." >&6;} 38976 has_space=`$ECHO "$complete" | $GREP " "` 38977 if test "x$has_space" != x; then 38978 { $as_echo "$as_me:${as_lineno-$LINENO}: This might be caused by spaces in the path, which is not allowed." >&5 38979 $as_echo "$as_me: This might be caused by spaces in the path, which is not allowed." >&6;} 38980 fi 38981 as_fn_error $? "Cannot locate the the path of AR" "$LINENO" 5 38982 fi 38983 fi 38984 38985 # Now join together the path and the arguments once again 38986 if test "x$arguments" != xEOL; then 38987 new_complete="$new_path ${arguments% *}" 38988 else 38989 new_complete="$new_path" 38990 fi 38991 38992 if test "x$complete" != "x$new_complete"; then 38993 AR="$new_complete" 38994 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting AR to \"$new_complete\"" >&5 38995 $as_echo "$as_me: Rewriting AR to \"$new_complete\"" >&6;} 38996 fi 38997 fi 38998 38999 39000 39001 if test "x$OPENJDK_TARGET_OS" = "xmacosx"; then 39002 39003 39004 # Publish this variable in the help. 39005 39006 39007 if [ -z "${LIPO+x}" ]; then 39008 # The variable is not set by user, try to locate tool using the code snippet 39009 for ac_prog in lipo 39010 do 39011 # Extract the first word of "$ac_prog", so it can be a program name with args. 39012 set dummy $ac_prog; ac_word=$2 39013 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 39014 $as_echo_n "checking for $ac_word... " >&6; } 39015 if ${ac_cv_path_LIPO+:} false; then : 39016 $as_echo_n "(cached) " >&6 39017 else 39018 case $LIPO in 39019 [\\/]* | ?:[\\/]*) 39020 ac_cv_path_LIPO="$LIPO" # Let the user override the test with a path. 39021 ;; 39022 *) 39023 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 39024 for as_dir in $PATH 39025 do 39026 IFS=$as_save_IFS 39027 test -z "$as_dir" && as_dir=. 39028 for ac_exec_ext in '' $ac_executable_extensions; do 39029 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 39030 ac_cv_path_LIPO="$as_dir/$ac_word$ac_exec_ext" 39031 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 39032 break 2 39033 fi 39034 done 39035 done 39036 IFS=$as_save_IFS 39037 39038 ;; 39039 esac 39040 fi 39041 LIPO=$ac_cv_path_LIPO 39042 if test -n "$LIPO"; then 39043 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $LIPO" >&5 39044 $as_echo "$LIPO" >&6; } 39045 else 39046 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 39047 $as_echo "no" >&6; } 39048 fi 39049 39050 39051 test -n "$LIPO" && break 39052 done 39053 39054 else 39055 # The variable is set, but is it from the command line or the environment? 39056 39057 # Try to remove the string !LIPO! from our list. 39058 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!LIPO!/} 39059 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 39060 # If it failed, the variable was not from the command line. Ignore it, 39061 # but warn the user (except for BASH, which is always set by the calling BASH). 39062 if test "xLIPO" != xBASH; then 39063 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of LIPO from the environment. Use command line variables instead." >&5 39064 $as_echo "$as_me: WARNING: Ignoring value of LIPO from the environment. Use command line variables instead." >&2;} 39065 fi 39066 # Try to locate tool using the code snippet 39067 for ac_prog in lipo 39068 do 39069 # Extract the first word of "$ac_prog", so it can be a program name with args. 39070 set dummy $ac_prog; ac_word=$2 39071 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 39072 $as_echo_n "checking for $ac_word... " >&6; } 39073 if ${ac_cv_path_LIPO+:} false; then : 39074 $as_echo_n "(cached) " >&6 39075 else 39076 case $LIPO in 39077 [\\/]* | ?:[\\/]*) 39078 ac_cv_path_LIPO="$LIPO" # Let the user override the test with a path. 39079 ;; 39080 *) 39081 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 39082 for as_dir in $PATH 39083 do 39084 IFS=$as_save_IFS 39085 test -z "$as_dir" && as_dir=. 39086 for ac_exec_ext in '' $ac_executable_extensions; do 39087 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 39088 ac_cv_path_LIPO="$as_dir/$ac_word$ac_exec_ext" 39089 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 39090 break 2 39091 fi 39092 done 39093 done 39094 IFS=$as_save_IFS 39095 39096 ;; 39097 esac 39098 fi 39099 LIPO=$ac_cv_path_LIPO 39100 if test -n "$LIPO"; then 39101 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $LIPO" >&5 39102 $as_echo "$LIPO" >&6; } 39103 else 39104 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 39105 $as_echo "no" >&6; } 39106 fi 39107 39108 39109 test -n "$LIPO" && break 39110 done 39111 39112 else 39113 # If it succeeded, then it was overridden by the user. We will use it 39114 # for the tool. 39115 39116 # First remove it from the list of overridden variables, so we can test 39117 # for unknown variables in the end. 39118 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 39119 39120 # Check if we try to supply an empty value 39121 if test "x$LIPO" = x; then 39122 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool LIPO= (no value)" >&5 39123 $as_echo "$as_me: Setting user supplied tool LIPO= (no value)" >&6;} 39124 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for LIPO" >&5 39125 $as_echo_n "checking for LIPO... " >&6; } 39126 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 39127 $as_echo "disabled" >&6; } 39128 else 39129 # Check if the provided tool contains a complete path. 39130 tool_specified="$LIPO" 39131 tool_basename="${tool_specified##*/}" 39132 if test "x$tool_basename" = "x$tool_specified"; then 39133 # A command without a complete path is provided, search $PATH. 39134 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool LIPO=$tool_basename" >&5 39135 $as_echo "$as_me: Will search for user supplied tool LIPO=$tool_basename" >&6;} 39136 # Extract the first word of "$tool_basename", so it can be a program name with args. 39137 set dummy $tool_basename; ac_word=$2 39138 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 39139 $as_echo_n "checking for $ac_word... " >&6; } 39140 if ${ac_cv_path_LIPO+:} false; then : 39141 $as_echo_n "(cached) " >&6 39142 else 39143 case $LIPO in 39144 [\\/]* | ?:[\\/]*) 39145 ac_cv_path_LIPO="$LIPO" # Let the user override the test with a path. 39146 ;; 39147 *) 39148 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 39149 for as_dir in $PATH 39150 do 39151 IFS=$as_save_IFS 39152 test -z "$as_dir" && as_dir=. 39153 for ac_exec_ext in '' $ac_executable_extensions; do 39154 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 39155 ac_cv_path_LIPO="$as_dir/$ac_word$ac_exec_ext" 39156 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 39157 break 2 39158 fi 39159 done 39160 done 39161 IFS=$as_save_IFS 39162 39163 ;; 39164 esac 39165 fi 39166 LIPO=$ac_cv_path_LIPO 39167 if test -n "$LIPO"; then 39168 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $LIPO" >&5 39169 $as_echo "$LIPO" >&6; } 39170 else 39171 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 39172 $as_echo "no" >&6; } 39173 fi 39174 39175 39176 if test "x$LIPO" = x; then 39177 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 39178 fi 39179 else 39180 # Otherwise we believe it is a complete path. Use it as it is. 39181 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool LIPO=$tool_specified" >&5 39182 $as_echo "$as_me: Will use user supplied tool LIPO=$tool_specified" >&6;} 39183 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for LIPO" >&5 39184 $as_echo_n "checking for LIPO... " >&6; } 39185 if test ! -x "$tool_specified"; then 39186 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 39187 $as_echo "not found" >&6; } 39188 as_fn_error $? "User supplied tool LIPO=$tool_specified does not exist or is not executable" "$LINENO" 5 39189 fi 39190 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 39191 $as_echo "$tool_specified" >&6; } 39192 fi 39193 fi 39194 fi 39195 39196 fi 39197 39198 39199 39200 # Only process if variable expands to non-empty 39201 39202 if test "x$LIPO" != x; then 39203 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 39204 39205 # First separate the path from the arguments. This will split at the first 39206 # space. 39207 complete="$LIPO" 39208 path="${complete%% *}" 39209 tmp="$complete EOL" 39210 arguments="${tmp#* }" 39211 39212 # Input might be given as Windows format, start by converting to 39213 # unix format. 39214 new_path=`$CYGPATH -u "$path"` 39215 39216 # Now try to locate executable using which 39217 new_path=`$WHICH "$new_path" 2> /dev/null` 39218 # bat and cmd files are not always considered executable in cygwin causing which 39219 # to not find them 39220 if test "x$new_path" = x \ 39221 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 39222 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 39223 new_path=`$CYGPATH -u "$path"` 39224 fi 39225 if test "x$new_path" = x; then 39226 # Oops. Which didn't find the executable. 39227 # The splitting of arguments from the executable at a space might have been incorrect, 39228 # since paths with space are more likely in Windows. Give it another try with the whole 39229 # argument. 39230 path="$complete" 39231 arguments="EOL" 39232 new_path=`$CYGPATH -u "$path"` 39233 new_path=`$WHICH "$new_path" 2> /dev/null` 39234 # bat and cmd files are not always considered executable in cygwin causing which 39235 # to not find them 39236 if test "x$new_path" = x \ 39237 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 39238 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 39239 new_path=`$CYGPATH -u "$path"` 39240 fi 39241 if test "x$new_path" = x; then 39242 # It's still not found. Now this is an unrecoverable error. 39243 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of LIPO, which resolves as \"$complete\", is not found." >&5 39244 $as_echo "$as_me: The path of LIPO, which resolves as \"$complete\", is not found." >&6;} 39245 has_space=`$ECHO "$complete" | $GREP " "` 39246 if test "x$has_space" != x; then 39247 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 39248 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 39249 fi 39250 as_fn_error $? "Cannot locate the the path of LIPO" "$LINENO" 5 39251 fi 39252 fi 39253 39254 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 39255 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 39256 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 39257 # "foo.exe" is OK but "foo" is an error. 39258 # 39259 # This test is therefore slightly more accurate than "test -f" to check for file presence. 39260 # It is also a way to make sure we got the proper file name for the real test later on. 39261 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 39262 if test "x$test_shortpath" = x; then 39263 # Short path failed, file does not exist as specified. 39264 # Try adding .exe or .cmd 39265 if test -f "${new_path}.exe"; then 39266 input_to_shortpath="${new_path}.exe" 39267 elif test -f "${new_path}.cmd"; then 39268 input_to_shortpath="${new_path}.cmd" 39269 else 39270 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of LIPO, which resolves as \"$new_path\", is invalid." >&5 39271 $as_echo "$as_me: The path of LIPO, which resolves as \"$new_path\", is invalid." >&6;} 39272 { $as_echo "$as_me:${as_lineno-$LINENO}: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&5 39273 $as_echo "$as_me: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&6;} 39274 as_fn_error $? "Cannot locate the the path of LIPO" "$LINENO" 5 39275 fi 39276 else 39277 input_to_shortpath="$new_path" 39278 fi 39279 39280 # Call helper function which possibly converts this using DOS-style short mode. 39281 # If so, the updated path is stored in $new_path. 39282 new_path="$input_to_shortpath" 39283 39284 input_path="$input_to_shortpath" 39285 # Check if we need to convert this using DOS-style short mode. If the path 39286 # contains just simple characters, use it. Otherwise (spaces, weird characters), 39287 # take no chances and rewrite it. 39288 # Note: m4 eats our [], so we need to use [ and ] instead. 39289 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 39290 if test "x$has_forbidden_chars" != x; then 39291 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 39292 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 39293 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 39294 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 39295 # Going to short mode and back again did indeed matter. Since short mode is 39296 # case insensitive, let's make it lowercase to improve readability. 39297 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 39298 # Now convert it back to Unix-style (cygpath) 39299 input_path=`$CYGPATH -u "$shortmode_path"` 39300 new_path="$input_path" 39301 fi 39302 fi 39303 39304 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 39305 if test "x$test_cygdrive_prefix" = x; then 39306 # As a simple fix, exclude /usr/bin since it's not a real path. 39307 if test "x`$ECHO $input_to_shortpath | $GREP ^/usr/bin/`" = x; then 39308 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 39309 # a path prefixed by /cygdrive for fixpath to work. 39310 new_path="$CYGWIN_ROOT_PATH$input_path" 39311 fi 39312 fi 39313 39314 # remove trailing .exe if any 39315 new_path="${new_path/%.exe/}" 39316 39317 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 39318 39319 # First separate the path from the arguments. This will split at the first 39320 # space. 39321 complete="$LIPO" 39322 path="${complete%% *}" 39323 tmp="$complete EOL" 39324 arguments="${tmp#* }" 39325 39326 # Input might be given as Windows format, start by converting to 39327 # unix format. 39328 new_path="$path" 39329 39330 windows_path="$new_path" 39331 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 39332 unix_path=`$CYGPATH -u "$windows_path"` 39333 new_path="$unix_path" 39334 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 39335 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 39336 new_path="$unix_path" 39337 fi 39338 39339 39340 # Now try to locate executable using which 39341 new_path=`$WHICH "$new_path" 2> /dev/null` 39342 39343 if test "x$new_path" = x; then 39344 # Oops. Which didn't find the executable. 39345 # The splitting of arguments from the executable at a space might have been incorrect, 39346 # since paths with space are more likely in Windows. Give it another try with the whole 39347 # argument. 39348 path="$complete" 39349 arguments="EOL" 39350 new_path="$path" 39351 39352 windows_path="$new_path" 39353 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 39354 unix_path=`$CYGPATH -u "$windows_path"` 39355 new_path="$unix_path" 39356 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 39357 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 39358 new_path="$unix_path" 39359 fi 39360 39361 39362 new_path=`$WHICH "$new_path" 2> /dev/null` 39363 # bat and cmd files are not always considered executable in MSYS causing which 39364 # to not find them 39365 if test "x$new_path" = x \ 39366 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 39367 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 39368 new_path="$path" 39369 39370 windows_path="$new_path" 39371 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 39372 unix_path=`$CYGPATH -u "$windows_path"` 39373 new_path="$unix_path" 39374 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 39375 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 39376 new_path="$unix_path" 39377 fi 39378 39379 fi 39380 39381 if test "x$new_path" = x; then 39382 # It's still not found. Now this is an unrecoverable error. 39383 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of LIPO, which resolves as \"$complete\", is not found." >&5 39384 $as_echo "$as_me: The path of LIPO, which resolves as \"$complete\", is not found." >&6;} 39385 has_space=`$ECHO "$complete" | $GREP " "` 39386 if test "x$has_space" != x; then 39387 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 39388 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 39389 fi 39390 as_fn_error $? "Cannot locate the the path of LIPO" "$LINENO" 5 39391 fi 39392 fi 39393 39394 # Now new_path has a complete unix path to the binary 39395 if test "x`$ECHO $new_path | $GREP ^/bin/`" != x; then 39396 # Keep paths in /bin as-is, but remove trailing .exe if any 39397 new_path="${new_path/%.exe/}" 39398 # Do not save /bin paths to all_fixpath_prefixes! 39399 else 39400 # Not in mixed or Windows style, start by that. 39401 new_path=`cmd //c echo $new_path` 39402 39403 input_path="$new_path" 39404 # Check if we need to convert this using DOS-style short mode. If the path 39405 # contains just simple characters, use it. Otherwise (spaces, weird characters), 39406 # take no chances and rewrite it. 39407 # Note: m4 eats our [], so we need to use [ and ] instead. 39408 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 39409 if test "x$has_forbidden_chars" != x; then 39410 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 39411 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 39412 fi 39413 39414 # Output is in $new_path 39415 39416 windows_path="$new_path" 39417 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 39418 unix_path=`$CYGPATH -u "$windows_path"` 39419 new_path="$unix_path" 39420 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 39421 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 39422 new_path="$unix_path" 39423 fi 39424 39425 # remove trailing .exe if any 39426 new_path="${new_path/%.exe/}" 39427 39428 # Save the first 10 bytes of this path to the storage, so fixpath can work. 39429 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 39430 fi 39431 39432 else 39433 # We're on a unix platform. Hooray! :) 39434 # First separate the path from the arguments. This will split at the first 39435 # space. 39436 complete="$LIPO" 39437 path="${complete%% *}" 39438 tmp="$complete EOL" 39439 arguments="${tmp#* }" 39440 39441 # Cannot rely on the command "which" here since it doesn't always work. 39442 is_absolute_path=`$ECHO "$path" | $GREP ^/` 39443 if test -z "$is_absolute_path"; then 39444 # Path to executable is not absolute. Find it. 39445 IFS_save="$IFS" 39446 IFS=: 39447 for p in $PATH; do 39448 if test -f "$p/$path" && test -x "$p/$path"; then 39449 new_path="$p/$path" 39450 break 39451 fi 39452 done 39453 IFS="$IFS_save" 39454 else 39455 # This is an absolute path, we can use it without further modifications. 39456 new_path="$path" 39457 fi 39458 39459 if test "x$new_path" = x; then 39460 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of LIPO, which resolves as \"$complete\", is not found." >&5 39461 $as_echo "$as_me: The path of LIPO, which resolves as \"$complete\", is not found." >&6;} 39462 has_space=`$ECHO "$complete" | $GREP " "` 39463 if test "x$has_space" != x; then 39464 { $as_echo "$as_me:${as_lineno-$LINENO}: This might be caused by spaces in the path, which is not allowed." >&5 39465 $as_echo "$as_me: This might be caused by spaces in the path, which is not allowed." >&6;} 39466 fi 39467 as_fn_error $? "Cannot locate the the path of LIPO" "$LINENO" 5 39468 fi 39469 fi 39470 39471 # Now join together the path and the arguments once again 39472 if test "x$arguments" != xEOL; then 39473 new_complete="$new_path ${arguments% *}" 39474 else 39475 new_complete="$new_path" 39476 fi 39477 39478 if test "x$complete" != "x$new_complete"; then 39479 LIPO="$new_complete" 39480 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting LIPO to \"$new_complete\"" >&5 39481 $as_echo "$as_me: Rewriting LIPO to \"$new_complete\"" >&6;} 39482 fi 39483 fi 39484 39485 39486 39487 39488 # Publish this variable in the help. 39489 39490 39491 if [ -z "${OTOOL+x}" ]; then 39492 # The variable is not set by user, try to locate tool using the code snippet 39493 for ac_prog in otool 39494 do 39495 # Extract the first word of "$ac_prog", so it can be a program name with args. 39496 set dummy $ac_prog; ac_word=$2 39497 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 39498 $as_echo_n "checking for $ac_word... " >&6; } 39499 if ${ac_cv_path_OTOOL+:} false; then : 39500 $as_echo_n "(cached) " >&6 39501 else 39502 case $OTOOL in 39503 [\\/]* | ?:[\\/]*) 39504 ac_cv_path_OTOOL="$OTOOL" # Let the user override the test with a path. 39505 ;; 39506 *) 39507 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 39508 for as_dir in $PATH 39509 do 39510 IFS=$as_save_IFS 39511 test -z "$as_dir" && as_dir=. 39512 for ac_exec_ext in '' $ac_executable_extensions; do 39513 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 39514 ac_cv_path_OTOOL="$as_dir/$ac_word$ac_exec_ext" 39515 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 39516 break 2 39517 fi 39518 done 39519 done 39520 IFS=$as_save_IFS 39521 39522 ;; 39523 esac 39524 fi 39525 OTOOL=$ac_cv_path_OTOOL 39526 if test -n "$OTOOL"; then 39527 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $OTOOL" >&5 39528 $as_echo "$OTOOL" >&6; } 39529 else 39530 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 39531 $as_echo "no" >&6; } 39532 fi 39533 39534 39535 test -n "$OTOOL" && break 39536 done 39537 39538 else 39539 # The variable is set, but is it from the command line or the environment? 39540 39541 # Try to remove the string !OTOOL! from our list. 39542 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!OTOOL!/} 39543 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 39544 # If it failed, the variable was not from the command line. Ignore it, 39545 # but warn the user (except for BASH, which is always set by the calling BASH). 39546 if test "xOTOOL" != xBASH; then 39547 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of OTOOL from the environment. Use command line variables instead." >&5 39548 $as_echo "$as_me: WARNING: Ignoring value of OTOOL from the environment. Use command line variables instead." >&2;} 39549 fi 39550 # Try to locate tool using the code snippet 39551 for ac_prog in otool 39552 do 39553 # Extract the first word of "$ac_prog", so it can be a program name with args. 39554 set dummy $ac_prog; ac_word=$2 39555 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 39556 $as_echo_n "checking for $ac_word... " >&6; } 39557 if ${ac_cv_path_OTOOL+:} false; then : 39558 $as_echo_n "(cached) " >&6 39559 else 39560 case $OTOOL in 39561 [\\/]* | ?:[\\/]*) 39562 ac_cv_path_OTOOL="$OTOOL" # Let the user override the test with a path. 39563 ;; 39564 *) 39565 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 39566 for as_dir in $PATH 39567 do 39568 IFS=$as_save_IFS 39569 test -z "$as_dir" && as_dir=. 39570 for ac_exec_ext in '' $ac_executable_extensions; do 39571 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 39572 ac_cv_path_OTOOL="$as_dir/$ac_word$ac_exec_ext" 39573 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 39574 break 2 39575 fi 39576 done 39577 done 39578 IFS=$as_save_IFS 39579 39580 ;; 39581 esac 39582 fi 39583 OTOOL=$ac_cv_path_OTOOL 39584 if test -n "$OTOOL"; then 39585 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $OTOOL" >&5 39586 $as_echo "$OTOOL" >&6; } 39587 else 39588 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 39589 $as_echo "no" >&6; } 39590 fi 39591 39592 39593 test -n "$OTOOL" && break 39594 done 39595 39596 else 39597 # If it succeeded, then it was overridden by the user. We will use it 39598 # for the tool. 39599 39600 # First remove it from the list of overridden variables, so we can test 39601 # for unknown variables in the end. 39602 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 39603 39604 # Check if we try to supply an empty value 39605 if test "x$OTOOL" = x; then 39606 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool OTOOL= (no value)" >&5 39607 $as_echo "$as_me: Setting user supplied tool OTOOL= (no value)" >&6;} 39608 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for OTOOL" >&5 39609 $as_echo_n "checking for OTOOL... " >&6; } 39610 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 39611 $as_echo "disabled" >&6; } 39612 else 39613 # Check if the provided tool contains a complete path. 39614 tool_specified="$OTOOL" 39615 tool_basename="${tool_specified##*/}" 39616 if test "x$tool_basename" = "x$tool_specified"; then 39617 # A command without a complete path is provided, search $PATH. 39618 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool OTOOL=$tool_basename" >&5 39619 $as_echo "$as_me: Will search for user supplied tool OTOOL=$tool_basename" >&6;} 39620 # Extract the first word of "$tool_basename", so it can be a program name with args. 39621 set dummy $tool_basename; ac_word=$2 39622 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 39623 $as_echo_n "checking for $ac_word... " >&6; } 39624 if ${ac_cv_path_OTOOL+:} false; then : 39625 $as_echo_n "(cached) " >&6 39626 else 39627 case $OTOOL in 39628 [\\/]* | ?:[\\/]*) 39629 ac_cv_path_OTOOL="$OTOOL" # Let the user override the test with a path. 39630 ;; 39631 *) 39632 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 39633 for as_dir in $PATH 39634 do 39635 IFS=$as_save_IFS 39636 test -z "$as_dir" && as_dir=. 39637 for ac_exec_ext in '' $ac_executable_extensions; do 39638 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 39639 ac_cv_path_OTOOL="$as_dir/$ac_word$ac_exec_ext" 39640 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 39641 break 2 39642 fi 39643 done 39644 done 39645 IFS=$as_save_IFS 39646 39647 ;; 39648 esac 39649 fi 39650 OTOOL=$ac_cv_path_OTOOL 39651 if test -n "$OTOOL"; then 39652 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $OTOOL" >&5 39653 $as_echo "$OTOOL" >&6; } 39654 else 39655 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 39656 $as_echo "no" >&6; } 39657 fi 39658 39659 39660 if test "x$OTOOL" = x; then 39661 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 39662 fi 39663 else 39664 # Otherwise we believe it is a complete path. Use it as it is. 39665 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool OTOOL=$tool_specified" >&5 39666 $as_echo "$as_me: Will use user supplied tool OTOOL=$tool_specified" >&6;} 39667 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for OTOOL" >&5 39668 $as_echo_n "checking for OTOOL... " >&6; } 39669 if test ! -x "$tool_specified"; then 39670 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 39671 $as_echo "not found" >&6; } 39672 as_fn_error $? "User supplied tool OTOOL=$tool_specified does not exist or is not executable" "$LINENO" 5 39673 fi 39674 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 39675 $as_echo "$tool_specified" >&6; } 39676 fi 39677 fi 39678 fi 39679 39680 fi 39681 39682 39683 39684 if test "x$OTOOL" = x; then 39685 as_fn_error $? "Could not find required tool for OTOOL" "$LINENO" 5 39686 fi 39687 39688 39689 39690 # Only process if variable expands to non-empty 39691 39692 if test "x$OTOOL" != x; then 39693 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 39694 39695 # First separate the path from the arguments. This will split at the first 39696 # space. 39697 complete="$OTOOL" 39698 path="${complete%% *}" 39699 tmp="$complete EOL" 39700 arguments="${tmp#* }" 39701 39702 # Input might be given as Windows format, start by converting to 39703 # unix format. 39704 new_path=`$CYGPATH -u "$path"` 39705 39706 # Now try to locate executable using which 39707 new_path=`$WHICH "$new_path" 2> /dev/null` 39708 # bat and cmd files are not always considered executable in cygwin causing which 39709 # to not find them 39710 if test "x$new_path" = x \ 39711 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 39712 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 39713 new_path=`$CYGPATH -u "$path"` 39714 fi 39715 if test "x$new_path" = x; then 39716 # Oops. Which didn't find the executable. 39717 # The splitting of arguments from the executable at a space might have been incorrect, 39718 # since paths with space are more likely in Windows. Give it another try with the whole 39719 # argument. 39720 path="$complete" 39721 arguments="EOL" 39722 new_path=`$CYGPATH -u "$path"` 39723 new_path=`$WHICH "$new_path" 2> /dev/null` 39724 # bat and cmd files are not always considered executable in cygwin causing which 39725 # to not find them 39726 if test "x$new_path" = x \ 39727 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 39728 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 39729 new_path=`$CYGPATH -u "$path"` 39730 fi 39731 if test "x$new_path" = x; then 39732 # It's still not found. Now this is an unrecoverable error. 39733 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of OTOOL, which resolves as \"$complete\", is not found." >&5 39734 $as_echo "$as_me: The path of OTOOL, which resolves as \"$complete\", is not found." >&6;} 39735 has_space=`$ECHO "$complete" | $GREP " "` 39736 if test "x$has_space" != x; then 39737 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 39738 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 39739 fi 39740 as_fn_error $? "Cannot locate the the path of OTOOL" "$LINENO" 5 39741 fi 39742 fi 39743 39744 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 39745 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 39746 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 39747 # "foo.exe" is OK but "foo" is an error. 39748 # 39749 # This test is therefore slightly more accurate than "test -f" to check for file presence. 39750 # It is also a way to make sure we got the proper file name for the real test later on. 39751 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 39752 if test "x$test_shortpath" = x; then 39753 # Short path failed, file does not exist as specified. 39754 # Try adding .exe or .cmd 39755 if test -f "${new_path}.exe"; then 39756 input_to_shortpath="${new_path}.exe" 39757 elif test -f "${new_path}.cmd"; then 39758 input_to_shortpath="${new_path}.cmd" 39759 else 39760 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of OTOOL, which resolves as \"$new_path\", is invalid." >&5 39761 $as_echo "$as_me: The path of OTOOL, which resolves as \"$new_path\", is invalid." >&6;} 39762 { $as_echo "$as_me:${as_lineno-$LINENO}: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&5 39763 $as_echo "$as_me: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&6;} 39764 as_fn_error $? "Cannot locate the the path of OTOOL" "$LINENO" 5 39765 fi 39766 else 39767 input_to_shortpath="$new_path" 39768 fi 39769 39770 # Call helper function which possibly converts this using DOS-style short mode. 39771 # If so, the updated path is stored in $new_path. 39772 new_path="$input_to_shortpath" 39773 39774 input_path="$input_to_shortpath" 39775 # Check if we need to convert this using DOS-style short mode. If the path 39776 # contains just simple characters, use it. Otherwise (spaces, weird characters), 39777 # take no chances and rewrite it. 39778 # Note: m4 eats our [], so we need to use [ and ] instead. 39779 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 39780 if test "x$has_forbidden_chars" != x; then 39781 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 39782 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 39783 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 39784 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 39785 # Going to short mode and back again did indeed matter. Since short mode is 39786 # case insensitive, let's make it lowercase to improve readability. 39787 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 39788 # Now convert it back to Unix-style (cygpath) 39789 input_path=`$CYGPATH -u "$shortmode_path"` 39790 new_path="$input_path" 39791 fi 39792 fi 39793 39794 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 39795 if test "x$test_cygdrive_prefix" = x; then 39796 # As a simple fix, exclude /usr/bin since it's not a real path. 39797 if test "x`$ECHO $input_to_shortpath | $GREP ^/usr/bin/`" = x; then 39798 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 39799 # a path prefixed by /cygdrive for fixpath to work. 39800 new_path="$CYGWIN_ROOT_PATH$input_path" 39801 fi 39802 fi 39803 39804 # remove trailing .exe if any 39805 new_path="${new_path/%.exe/}" 39806 39807 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 39808 39809 # First separate the path from the arguments. This will split at the first 39810 # space. 39811 complete="$OTOOL" 39812 path="${complete%% *}" 39813 tmp="$complete EOL" 39814 arguments="${tmp#* }" 39815 39816 # Input might be given as Windows format, start by converting to 39817 # unix format. 39818 new_path="$path" 39819 39820 windows_path="$new_path" 39821 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 39822 unix_path=`$CYGPATH -u "$windows_path"` 39823 new_path="$unix_path" 39824 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 39825 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 39826 new_path="$unix_path" 39827 fi 39828 39829 39830 # Now try to locate executable using which 39831 new_path=`$WHICH "$new_path" 2> /dev/null` 39832 39833 if test "x$new_path" = x; then 39834 # Oops. Which didn't find the executable. 39835 # The splitting of arguments from the executable at a space might have been incorrect, 39836 # since paths with space are more likely in Windows. Give it another try with the whole 39837 # argument. 39838 path="$complete" 39839 arguments="EOL" 39840 new_path="$path" 39841 39842 windows_path="$new_path" 39843 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 39844 unix_path=`$CYGPATH -u "$windows_path"` 39845 new_path="$unix_path" 39846 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 39847 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 39848 new_path="$unix_path" 39849 fi 39850 39851 39852 new_path=`$WHICH "$new_path" 2> /dev/null` 39853 # bat and cmd files are not always considered executable in MSYS causing which 39854 # to not find them 39855 if test "x$new_path" = x \ 39856 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 39857 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 39858 new_path="$path" 39859 39860 windows_path="$new_path" 39861 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 39862 unix_path=`$CYGPATH -u "$windows_path"` 39863 new_path="$unix_path" 39864 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 39865 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 39866 new_path="$unix_path" 39867 fi 39868 39869 fi 39870 39871 if test "x$new_path" = x; then 39872 # It's still not found. Now this is an unrecoverable error. 39873 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of OTOOL, which resolves as \"$complete\", is not found." >&5 39874 $as_echo "$as_me: The path of OTOOL, which resolves as \"$complete\", is not found." >&6;} 39875 has_space=`$ECHO "$complete" | $GREP " "` 39876 if test "x$has_space" != x; then 39877 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 39878 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 39879 fi 39880 as_fn_error $? "Cannot locate the the path of OTOOL" "$LINENO" 5 39881 fi 39882 fi 39883 39884 # Now new_path has a complete unix path to the binary 39885 if test "x`$ECHO $new_path | $GREP ^/bin/`" != x; then 39886 # Keep paths in /bin as-is, but remove trailing .exe if any 39887 new_path="${new_path/%.exe/}" 39888 # Do not save /bin paths to all_fixpath_prefixes! 39889 else 39890 # Not in mixed or Windows style, start by that. 39891 new_path=`cmd //c echo $new_path` 39892 39893 input_path="$new_path" 39894 # Check if we need to convert this using DOS-style short mode. If the path 39895 # contains just simple characters, use it. Otherwise (spaces, weird characters), 39896 # take no chances and rewrite it. 39897 # Note: m4 eats our [], so we need to use [ and ] instead. 39898 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 39899 if test "x$has_forbidden_chars" != x; then 39900 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 39901 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 39902 fi 39903 39904 # Output is in $new_path 39905 39906 windows_path="$new_path" 39907 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 39908 unix_path=`$CYGPATH -u "$windows_path"` 39909 new_path="$unix_path" 39910 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 39911 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 39912 new_path="$unix_path" 39913 fi 39914 39915 # remove trailing .exe if any 39916 new_path="${new_path/%.exe/}" 39917 39918 # Save the first 10 bytes of this path to the storage, so fixpath can work. 39919 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 39920 fi 39921 39922 else 39923 # We're on a unix platform. Hooray! :) 39924 # First separate the path from the arguments. This will split at the first 39925 # space. 39926 complete="$OTOOL" 39927 path="${complete%% *}" 39928 tmp="$complete EOL" 39929 arguments="${tmp#* }" 39930 39931 # Cannot rely on the command "which" here since it doesn't always work. 39932 is_absolute_path=`$ECHO "$path" | $GREP ^/` 39933 if test -z "$is_absolute_path"; then 39934 # Path to executable is not absolute. Find it. 39935 IFS_save="$IFS" 39936 IFS=: 39937 for p in $PATH; do 39938 if test -f "$p/$path" && test -x "$p/$path"; then 39939 new_path="$p/$path" 39940 break 39941 fi 39942 done 39943 IFS="$IFS_save" 39944 else 39945 # This is an absolute path, we can use it without further modifications. 39946 new_path="$path" 39947 fi 39948 39949 if test "x$new_path" = x; then 39950 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of OTOOL, which resolves as \"$complete\", is not found." >&5 39951 $as_echo "$as_me: The path of OTOOL, which resolves as \"$complete\", is not found." >&6;} 39952 has_space=`$ECHO "$complete" | $GREP " "` 39953 if test "x$has_space" != x; then 39954 { $as_echo "$as_me:${as_lineno-$LINENO}: This might be caused by spaces in the path, which is not allowed." >&5 39955 $as_echo "$as_me: This might be caused by spaces in the path, which is not allowed." >&6;} 39956 fi 39957 as_fn_error $? "Cannot locate the the path of OTOOL" "$LINENO" 5 39958 fi 39959 fi 39960 39961 # Now join together the path and the arguments once again 39962 if test "x$arguments" != xEOL; then 39963 new_complete="$new_path ${arguments% *}" 39964 else 39965 new_complete="$new_path" 39966 fi 39967 39968 if test "x$complete" != "x$new_complete"; then 39969 OTOOL="$new_complete" 39970 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting OTOOL to \"$new_complete\"" >&5 39971 $as_echo "$as_me: Rewriting OTOOL to \"$new_complete\"" >&6;} 39972 fi 39973 fi 39974 39975 39976 39977 39978 # Publish this variable in the help. 39979 39980 39981 if [ -z "${INSTALL_NAME_TOOL+x}" ]; then 39982 # The variable is not set by user, try to locate tool using the code snippet 39983 for ac_prog in install_name_tool 39984 do 39985 # Extract the first word of "$ac_prog", so it can be a program name with args. 39986 set dummy $ac_prog; ac_word=$2 39987 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 39988 $as_echo_n "checking for $ac_word... " >&6; } 39989 if ${ac_cv_path_INSTALL_NAME_TOOL+:} false; then : 39990 $as_echo_n "(cached) " >&6 39991 else 39992 case $INSTALL_NAME_TOOL in 39993 [\\/]* | ?:[\\/]*) 39994 ac_cv_path_INSTALL_NAME_TOOL="$INSTALL_NAME_TOOL" # Let the user override the test with a path. 39995 ;; 39996 *) 39997 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 39998 for as_dir in $PATH 39999 do 40000 IFS=$as_save_IFS 40001 test -z "$as_dir" && as_dir=. 40002 for ac_exec_ext in '' $ac_executable_extensions; do 40003 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 40004 ac_cv_path_INSTALL_NAME_TOOL="$as_dir/$ac_word$ac_exec_ext" 40005 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 40006 break 2 40007 fi 40008 done 40009 done 40010 IFS=$as_save_IFS 40011 40012 ;; 40013 esac 40014 fi 40015 INSTALL_NAME_TOOL=$ac_cv_path_INSTALL_NAME_TOOL 40016 if test -n "$INSTALL_NAME_TOOL"; then 40017 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $INSTALL_NAME_TOOL" >&5 40018 $as_echo "$INSTALL_NAME_TOOL" >&6; } 40019 else 40020 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 40021 $as_echo "no" >&6; } 40022 fi 40023 40024 40025 test -n "$INSTALL_NAME_TOOL" && break 40026 done 40027 40028 else 40029 # The variable is set, but is it from the command line or the environment? 40030 40031 # Try to remove the string !INSTALL_NAME_TOOL! from our list. 40032 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!INSTALL_NAME_TOOL!/} 40033 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 40034 # If it failed, the variable was not from the command line. Ignore it, 40035 # but warn the user (except for BASH, which is always set by the calling BASH). 40036 if test "xINSTALL_NAME_TOOL" != xBASH; then 40037 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of INSTALL_NAME_TOOL from the environment. Use command line variables instead." >&5 40038 $as_echo "$as_me: WARNING: Ignoring value of INSTALL_NAME_TOOL from the environment. Use command line variables instead." >&2;} 40039 fi 40040 # Try to locate tool using the code snippet 40041 for ac_prog in install_name_tool 40042 do 40043 # Extract the first word of "$ac_prog", so it can be a program name with args. 40044 set dummy $ac_prog; ac_word=$2 40045 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 40046 $as_echo_n "checking for $ac_word... " >&6; } 40047 if ${ac_cv_path_INSTALL_NAME_TOOL+:} false; then : 40048 $as_echo_n "(cached) " >&6 40049 else 40050 case $INSTALL_NAME_TOOL in 40051 [\\/]* | ?:[\\/]*) 40052 ac_cv_path_INSTALL_NAME_TOOL="$INSTALL_NAME_TOOL" # Let the user override the test with a path. 40053 ;; 40054 *) 40055 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 40056 for as_dir in $PATH 40057 do 40058 IFS=$as_save_IFS 40059 test -z "$as_dir" && as_dir=. 40060 for ac_exec_ext in '' $ac_executable_extensions; do 40061 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 40062 ac_cv_path_INSTALL_NAME_TOOL="$as_dir/$ac_word$ac_exec_ext" 40063 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 40064 break 2 40065 fi 40066 done 40067 done 40068 IFS=$as_save_IFS 40069 40070 ;; 40071 esac 40072 fi 40073 INSTALL_NAME_TOOL=$ac_cv_path_INSTALL_NAME_TOOL 40074 if test -n "$INSTALL_NAME_TOOL"; then 40075 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $INSTALL_NAME_TOOL" >&5 40076 $as_echo "$INSTALL_NAME_TOOL" >&6; } 40077 else 40078 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 40079 $as_echo "no" >&6; } 40080 fi 40081 40082 40083 test -n "$INSTALL_NAME_TOOL" && break 40084 done 40085 40086 else 40087 # If it succeeded, then it was overridden by the user. We will use it 40088 # for the tool. 40089 40090 # First remove it from the list of overridden variables, so we can test 40091 # for unknown variables in the end. 40092 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 40093 40094 # Check if we try to supply an empty value 40095 if test "x$INSTALL_NAME_TOOL" = x; then 40096 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool INSTALL_NAME_TOOL= (no value)" >&5 40097 $as_echo "$as_me: Setting user supplied tool INSTALL_NAME_TOOL= (no value)" >&6;} 40098 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for INSTALL_NAME_TOOL" >&5 40099 $as_echo_n "checking for INSTALL_NAME_TOOL... " >&6; } 40100 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 40101 $as_echo "disabled" >&6; } 40102 else 40103 # Check if the provided tool contains a complete path. 40104 tool_specified="$INSTALL_NAME_TOOL" 40105 tool_basename="${tool_specified##*/}" 40106 if test "x$tool_basename" = "x$tool_specified"; then 40107 # A command without a complete path is provided, search $PATH. 40108 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool INSTALL_NAME_TOOL=$tool_basename" >&5 40109 $as_echo "$as_me: Will search for user supplied tool INSTALL_NAME_TOOL=$tool_basename" >&6;} 40110 # Extract the first word of "$tool_basename", so it can be a program name with args. 40111 set dummy $tool_basename; ac_word=$2 40112 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 40113 $as_echo_n "checking for $ac_word... " >&6; } 40114 if ${ac_cv_path_INSTALL_NAME_TOOL+:} false; then : 40115 $as_echo_n "(cached) " >&6 40116 else 40117 case $INSTALL_NAME_TOOL in 40118 [\\/]* | ?:[\\/]*) 40119 ac_cv_path_INSTALL_NAME_TOOL="$INSTALL_NAME_TOOL" # Let the user override the test with a path. 40120 ;; 40121 *) 40122 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 40123 for as_dir in $PATH 40124 do 40125 IFS=$as_save_IFS 40126 test -z "$as_dir" && as_dir=. 40127 for ac_exec_ext in '' $ac_executable_extensions; do 40128 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 40129 ac_cv_path_INSTALL_NAME_TOOL="$as_dir/$ac_word$ac_exec_ext" 40130 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 40131 break 2 40132 fi 40133 done 40134 done 40135 IFS=$as_save_IFS 40136 40137 ;; 40138 esac 40139 fi 40140 INSTALL_NAME_TOOL=$ac_cv_path_INSTALL_NAME_TOOL 40141 if test -n "$INSTALL_NAME_TOOL"; then 40142 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $INSTALL_NAME_TOOL" >&5 40143 $as_echo "$INSTALL_NAME_TOOL" >&6; } 40144 else 40145 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 40146 $as_echo "no" >&6; } 40147 fi 40148 40149 40150 if test "x$INSTALL_NAME_TOOL" = x; then 40151 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 40152 fi 40153 else 40154 # Otherwise we believe it is a complete path. Use it as it is. 40155 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool INSTALL_NAME_TOOL=$tool_specified" >&5 40156 $as_echo "$as_me: Will use user supplied tool INSTALL_NAME_TOOL=$tool_specified" >&6;} 40157 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for INSTALL_NAME_TOOL" >&5 40158 $as_echo_n "checking for INSTALL_NAME_TOOL... " >&6; } 40159 if test ! -x "$tool_specified"; then 40160 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 40161 $as_echo "not found" >&6; } 40162 as_fn_error $? "User supplied tool INSTALL_NAME_TOOL=$tool_specified does not exist or is not executable" "$LINENO" 5 40163 fi 40164 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 40165 $as_echo "$tool_specified" >&6; } 40166 fi 40167 fi 40168 fi 40169 40170 fi 40171 40172 40173 40174 if test "x$INSTALL_NAME_TOOL" = x; then 40175 as_fn_error $? "Could not find required tool for INSTALL_NAME_TOOL" "$LINENO" 5 40176 fi 40177 40178 40179 40180 # Only process if variable expands to non-empty 40181 40182 if test "x$INSTALL_NAME_TOOL" != x; then 40183 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 40184 40185 # First separate the path from the arguments. This will split at the first 40186 # space. 40187 complete="$INSTALL_NAME_TOOL" 40188 path="${complete%% *}" 40189 tmp="$complete EOL" 40190 arguments="${tmp#* }" 40191 40192 # Input might be given as Windows format, start by converting to 40193 # unix format. 40194 new_path=`$CYGPATH -u "$path"` 40195 40196 # Now try to locate executable using which 40197 new_path=`$WHICH "$new_path" 2> /dev/null` 40198 # bat and cmd files are not always considered executable in cygwin causing which 40199 # to not find them 40200 if test "x$new_path" = x \ 40201 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 40202 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 40203 new_path=`$CYGPATH -u "$path"` 40204 fi 40205 if test "x$new_path" = x; then 40206 # Oops. Which didn't find the executable. 40207 # The splitting of arguments from the executable at a space might have been incorrect, 40208 # since paths with space are more likely in Windows. Give it another try with the whole 40209 # argument. 40210 path="$complete" 40211 arguments="EOL" 40212 new_path=`$CYGPATH -u "$path"` 40213 new_path=`$WHICH "$new_path" 2> /dev/null` 40214 # bat and cmd files are not always considered executable in cygwin causing which 40215 # to not find them 40216 if test "x$new_path" = x \ 40217 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 40218 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 40219 new_path=`$CYGPATH -u "$path"` 40220 fi 40221 if test "x$new_path" = x; then 40222 # It's still not found. Now this is an unrecoverable error. 40223 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of INSTALL_NAME_TOOL, which resolves as \"$complete\", is not found." >&5 40224 $as_echo "$as_me: The path of INSTALL_NAME_TOOL, which resolves as \"$complete\", is not found." >&6;} 40225 has_space=`$ECHO "$complete" | $GREP " "` 40226 if test "x$has_space" != x; then 40227 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 40228 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 40229 fi 40230 as_fn_error $? "Cannot locate the the path of INSTALL_NAME_TOOL" "$LINENO" 5 40231 fi 40232 fi 40233 40234 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 40235 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 40236 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 40237 # "foo.exe" is OK but "foo" is an error. 40238 # 40239 # This test is therefore slightly more accurate than "test -f" to check for file presence. 40240 # It is also a way to make sure we got the proper file name for the real test later on. 40241 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 40242 if test "x$test_shortpath" = x; then 40243 # Short path failed, file does not exist as specified. 40244 # Try adding .exe or .cmd 40245 if test -f "${new_path}.exe"; then 40246 input_to_shortpath="${new_path}.exe" 40247 elif test -f "${new_path}.cmd"; then 40248 input_to_shortpath="${new_path}.cmd" 40249 else 40250 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of INSTALL_NAME_TOOL, which resolves as \"$new_path\", is invalid." >&5 40251 $as_echo "$as_me: The path of INSTALL_NAME_TOOL, which resolves as \"$new_path\", is invalid." >&6;} 40252 { $as_echo "$as_me:${as_lineno-$LINENO}: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&5 40253 $as_echo "$as_me: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&6;} 40254 as_fn_error $? "Cannot locate the the path of INSTALL_NAME_TOOL" "$LINENO" 5 40255 fi 40256 else 40257 input_to_shortpath="$new_path" 40258 fi 40259 40260 # Call helper function which possibly converts this using DOS-style short mode. 40261 # If so, the updated path is stored in $new_path. 40262 new_path="$input_to_shortpath" 40263 40264 input_path="$input_to_shortpath" 40265 # Check if we need to convert this using DOS-style short mode. If the path 40266 # contains just simple characters, use it. Otherwise (spaces, weird characters), 40267 # take no chances and rewrite it. 40268 # Note: m4 eats our [], so we need to use [ and ] instead. 40269 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 40270 if test "x$has_forbidden_chars" != x; then 40271 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 40272 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 40273 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 40274 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 40275 # Going to short mode and back again did indeed matter. Since short mode is 40276 # case insensitive, let's make it lowercase to improve readability. 40277 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 40278 # Now convert it back to Unix-style (cygpath) 40279 input_path=`$CYGPATH -u "$shortmode_path"` 40280 new_path="$input_path" 40281 fi 40282 fi 40283 40284 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 40285 if test "x$test_cygdrive_prefix" = x; then 40286 # As a simple fix, exclude /usr/bin since it's not a real path. 40287 if test "x`$ECHO $input_to_shortpath | $GREP ^/usr/bin/`" = x; then 40288 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 40289 # a path prefixed by /cygdrive for fixpath to work. 40290 new_path="$CYGWIN_ROOT_PATH$input_path" 40291 fi 40292 fi 40293 40294 # remove trailing .exe if any 40295 new_path="${new_path/%.exe/}" 40296 40297 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 40298 40299 # First separate the path from the arguments. This will split at the first 40300 # space. 40301 complete="$INSTALL_NAME_TOOL" 40302 path="${complete%% *}" 40303 tmp="$complete EOL" 40304 arguments="${tmp#* }" 40305 40306 # Input might be given as Windows format, start by converting to 40307 # unix format. 40308 new_path="$path" 40309 40310 windows_path="$new_path" 40311 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 40312 unix_path=`$CYGPATH -u "$windows_path"` 40313 new_path="$unix_path" 40314 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 40315 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 40316 new_path="$unix_path" 40317 fi 40318 40319 40320 # Now try to locate executable using which 40321 new_path=`$WHICH "$new_path" 2> /dev/null` 40322 40323 if test "x$new_path" = x; then 40324 # Oops. Which didn't find the executable. 40325 # The splitting of arguments from the executable at a space might have been incorrect, 40326 # since paths with space are more likely in Windows. Give it another try with the whole 40327 # argument. 40328 path="$complete" 40329 arguments="EOL" 40330 new_path="$path" 40331 40332 windows_path="$new_path" 40333 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 40334 unix_path=`$CYGPATH -u "$windows_path"` 40335 new_path="$unix_path" 40336 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 40337 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 40338 new_path="$unix_path" 40339 fi 40340 40341 40342 new_path=`$WHICH "$new_path" 2> /dev/null` 40343 # bat and cmd files are not always considered executable in MSYS causing which 40344 # to not find them 40345 if test "x$new_path" = x \ 40346 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 40347 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 40348 new_path="$path" 40349 40350 windows_path="$new_path" 40351 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 40352 unix_path=`$CYGPATH -u "$windows_path"` 40353 new_path="$unix_path" 40354 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 40355 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 40356 new_path="$unix_path" 40357 fi 40358 40359 fi 40360 40361 if test "x$new_path" = x; then 40362 # It's still not found. Now this is an unrecoverable error. 40363 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of INSTALL_NAME_TOOL, which resolves as \"$complete\", is not found." >&5 40364 $as_echo "$as_me: The path of INSTALL_NAME_TOOL, which resolves as \"$complete\", is not found." >&6;} 40365 has_space=`$ECHO "$complete" | $GREP " "` 40366 if test "x$has_space" != x; then 40367 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 40368 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 40369 fi 40370 as_fn_error $? "Cannot locate the the path of INSTALL_NAME_TOOL" "$LINENO" 5 40371 fi 40372 fi 40373 40374 # Now new_path has a complete unix path to the binary 40375 if test "x`$ECHO $new_path | $GREP ^/bin/`" != x; then 40376 # Keep paths in /bin as-is, but remove trailing .exe if any 40377 new_path="${new_path/%.exe/}" 40378 # Do not save /bin paths to all_fixpath_prefixes! 40379 else 40380 # Not in mixed or Windows style, start by that. 40381 new_path=`cmd //c echo $new_path` 40382 40383 input_path="$new_path" 40384 # Check if we need to convert this using DOS-style short mode. If the path 40385 # contains just simple characters, use it. Otherwise (spaces, weird characters), 40386 # take no chances and rewrite it. 40387 # Note: m4 eats our [], so we need to use [ and ] instead. 40388 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 40389 if test "x$has_forbidden_chars" != x; then 40390 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 40391 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 40392 fi 40393 40394 # Output is in $new_path 40395 40396 windows_path="$new_path" 40397 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 40398 unix_path=`$CYGPATH -u "$windows_path"` 40399 new_path="$unix_path" 40400 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 40401 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 40402 new_path="$unix_path" 40403 fi 40404 40405 # remove trailing .exe if any 40406 new_path="${new_path/%.exe/}" 40407 40408 # Save the first 10 bytes of this path to the storage, so fixpath can work. 40409 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 40410 fi 40411 40412 else 40413 # We're on a unix platform. Hooray! :) 40414 # First separate the path from the arguments. This will split at the first 40415 # space. 40416 complete="$INSTALL_NAME_TOOL" 40417 path="${complete%% *}" 40418 tmp="$complete EOL" 40419 arguments="${tmp#* }" 40420 40421 # Cannot rely on the command "which" here since it doesn't always work. 40422 is_absolute_path=`$ECHO "$path" | $GREP ^/` 40423 if test -z "$is_absolute_path"; then 40424 # Path to executable is not absolute. Find it. 40425 IFS_save="$IFS" 40426 IFS=: 40427 for p in $PATH; do 40428 if test -f "$p/$path" && test -x "$p/$path"; then 40429 new_path="$p/$path" 40430 break 40431 fi 40432 done 40433 IFS="$IFS_save" 40434 else 40435 # This is an absolute path, we can use it without further modifications. 40436 new_path="$path" 40437 fi 40438 40439 if test "x$new_path" = x; then 40440 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of INSTALL_NAME_TOOL, which resolves as \"$complete\", is not found." >&5 40441 $as_echo "$as_me: The path of INSTALL_NAME_TOOL, which resolves as \"$complete\", is not found." >&6;} 40442 has_space=`$ECHO "$complete" | $GREP " "` 40443 if test "x$has_space" != x; then 40444 { $as_echo "$as_me:${as_lineno-$LINENO}: This might be caused by spaces in the path, which is not allowed." >&5 40445 $as_echo "$as_me: This might be caused by spaces in the path, which is not allowed." >&6;} 40446 fi 40447 as_fn_error $? "Cannot locate the the path of INSTALL_NAME_TOOL" "$LINENO" 5 40448 fi 40449 fi 40450 40451 # Now join together the path and the arguments once again 40452 if test "x$arguments" != xEOL; then 40453 new_complete="$new_path ${arguments% *}" 40454 else 40455 new_complete="$new_path" 40456 fi 40457 40458 if test "x$complete" != "x$new_complete"; then 40459 INSTALL_NAME_TOOL="$new_complete" 40460 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting INSTALL_NAME_TOOL to \"$new_complete\"" >&5 40461 $as_echo "$as_me: Rewriting INSTALL_NAME_TOOL to \"$new_complete\"" >&6;} 40462 fi 40463 fi 40464 40465 fi 40466 40467 if test "x$TOOLCHAIN_TYPE" = xmicrosoft; then 40468 # Extract the first word of "mt", so it can be a program name with args. 40469 set dummy mt; ac_word=$2 40470 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 40471 $as_echo_n "checking for $ac_word... " >&6; } 40472 if ${ac_cv_prog_MT+:} false; then : 40473 $as_echo_n "(cached) " >&6 40474 else 40475 if test -n "$MT"; then 40476 ac_cv_prog_MT="$MT" # Let the user override the test. 40477 else 40478 ac_prog_rejected=no 40479 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 40480 for as_dir in $PATH 40481 do 40482 IFS=$as_save_IFS 40483 test -z "$as_dir" && as_dir=. 40484 for ac_exec_ext in '' $ac_executable_extensions; do 40485 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 40486 if test "$as_dir/$ac_word$ac_exec_ext" = "/usr/bin/mt"; then 40487 ac_prog_rejected=yes 40488 continue 40489 fi 40490 ac_cv_prog_MT="mt" 40491 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 40492 break 2 40493 fi 40494 done 40495 done 40496 IFS=$as_save_IFS 40497 40498 if test $ac_prog_rejected = yes; then 40499 # We found a bogon in the path, so make sure we never use it. 40500 set dummy $ac_cv_prog_MT 40501 shift 40502 if test $# != 0; then 40503 # We chose a different compiler from the bogus one. 40504 # However, it has the same basename, so the bogon will be chosen 40505 # first if we set MT to just the basename; use the full file name. 40506 shift 40507 ac_cv_prog_MT="$as_dir/$ac_word${1+' '}$@" 40508 fi 40509 fi 40510 fi 40511 fi 40512 MT=$ac_cv_prog_MT 40513 if test -n "$MT"; then 40514 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MT" >&5 40515 $as_echo "$MT" >&6; } 40516 else 40517 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 40518 $as_echo "no" >&6; } 40519 fi 40520 40521 40522 40523 # Only process if variable expands to non-empty 40524 40525 if test "x$MT" != x; then 40526 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 40527 40528 # First separate the path from the arguments. This will split at the first 40529 # space. 40530 complete="$MT" 40531 path="${complete%% *}" 40532 tmp="$complete EOL" 40533 arguments="${tmp#* }" 40534 40535 # Input might be given as Windows format, start by converting to 40536 # unix format. 40537 new_path=`$CYGPATH -u "$path"` 40538 40539 # Now try to locate executable using which 40540 new_path=`$WHICH "$new_path" 2> /dev/null` 40541 # bat and cmd files are not always considered executable in cygwin causing which 40542 # to not find them 40543 if test "x$new_path" = x \ 40544 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 40545 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 40546 new_path=`$CYGPATH -u "$path"` 40547 fi 40548 if test "x$new_path" = x; then 40549 # Oops. Which didn't find the executable. 40550 # The splitting of arguments from the executable at a space might have been incorrect, 40551 # since paths with space are more likely in Windows. Give it another try with the whole 40552 # argument. 40553 path="$complete" 40554 arguments="EOL" 40555 new_path=`$CYGPATH -u "$path"` 40556 new_path=`$WHICH "$new_path" 2> /dev/null` 40557 # bat and cmd files are not always considered executable in cygwin causing which 40558 # to not find them 40559 if test "x$new_path" = x \ 40560 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 40561 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 40562 new_path=`$CYGPATH -u "$path"` 40563 fi 40564 if test "x$new_path" = x; then 40565 # It's still not found. Now this is an unrecoverable error. 40566 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of MT, which resolves as \"$complete\", is not found." >&5 40567 $as_echo "$as_me: The path of MT, which resolves as \"$complete\", is not found." >&6;} 40568 has_space=`$ECHO "$complete" | $GREP " "` 40569 if test "x$has_space" != x; then 40570 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 40571 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 40572 fi 40573 as_fn_error $? "Cannot locate the the path of MT" "$LINENO" 5 40574 fi 40575 fi 40576 40577 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 40578 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 40579 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 40580 # "foo.exe" is OK but "foo" is an error. 40581 # 40582 # This test is therefore slightly more accurate than "test -f" to check for file presence. 40583 # It is also a way to make sure we got the proper file name for the real test later on. 40584 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 40585 if test "x$test_shortpath" = x; then 40586 # Short path failed, file does not exist as specified. 40587 # Try adding .exe or .cmd 40588 if test -f "${new_path}.exe"; then 40589 input_to_shortpath="${new_path}.exe" 40590 elif test -f "${new_path}.cmd"; then 40591 input_to_shortpath="${new_path}.cmd" 40592 else 40593 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of MT, which resolves as \"$new_path\", is invalid." >&5 40594 $as_echo "$as_me: The path of MT, which resolves as \"$new_path\", is invalid." >&6;} 40595 { $as_echo "$as_me:${as_lineno-$LINENO}: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&5 40596 $as_echo "$as_me: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&6;} 40597 as_fn_error $? "Cannot locate the the path of MT" "$LINENO" 5 40598 fi 40599 else 40600 input_to_shortpath="$new_path" 40601 fi 40602 40603 # Call helper function which possibly converts this using DOS-style short mode. 40604 # If so, the updated path is stored in $new_path. 40605 new_path="$input_to_shortpath" 40606 40607 input_path="$input_to_shortpath" 40608 # Check if we need to convert this using DOS-style short mode. If the path 40609 # contains just simple characters, use it. Otherwise (spaces, weird characters), 40610 # take no chances and rewrite it. 40611 # Note: m4 eats our [], so we need to use [ and ] instead. 40612 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 40613 if test "x$has_forbidden_chars" != x; then 40614 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 40615 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 40616 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 40617 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 40618 # Going to short mode and back again did indeed matter. Since short mode is 40619 # case insensitive, let's make it lowercase to improve readability. 40620 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 40621 # Now convert it back to Unix-style (cygpath) 40622 input_path=`$CYGPATH -u "$shortmode_path"` 40623 new_path="$input_path" 40624 fi 40625 fi 40626 40627 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 40628 if test "x$test_cygdrive_prefix" = x; then 40629 # As a simple fix, exclude /usr/bin since it's not a real path. 40630 if test "x`$ECHO $input_to_shortpath | $GREP ^/usr/bin/`" = x; then 40631 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 40632 # a path prefixed by /cygdrive for fixpath to work. 40633 new_path="$CYGWIN_ROOT_PATH$input_path" 40634 fi 40635 fi 40636 40637 # remove trailing .exe if any 40638 new_path="${new_path/%.exe/}" 40639 40640 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 40641 40642 # First separate the path from the arguments. This will split at the first 40643 # space. 40644 complete="$MT" 40645 path="${complete%% *}" 40646 tmp="$complete EOL" 40647 arguments="${tmp#* }" 40648 40649 # Input might be given as Windows format, start by converting to 40650 # unix format. 40651 new_path="$path" 40652 40653 windows_path="$new_path" 40654 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 40655 unix_path=`$CYGPATH -u "$windows_path"` 40656 new_path="$unix_path" 40657 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 40658 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 40659 new_path="$unix_path" 40660 fi 40661 40662 40663 # Now try to locate executable using which 40664 new_path=`$WHICH "$new_path" 2> /dev/null` 40665 40666 if test "x$new_path" = x; then 40667 # Oops. Which didn't find the executable. 40668 # The splitting of arguments from the executable at a space might have been incorrect, 40669 # since paths with space are more likely in Windows. Give it another try with the whole 40670 # argument. 40671 path="$complete" 40672 arguments="EOL" 40673 new_path="$path" 40674 40675 windows_path="$new_path" 40676 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 40677 unix_path=`$CYGPATH -u "$windows_path"` 40678 new_path="$unix_path" 40679 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 40680 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 40681 new_path="$unix_path" 40682 fi 40683 40684 40685 new_path=`$WHICH "$new_path" 2> /dev/null` 40686 # bat and cmd files are not always considered executable in MSYS causing which 40687 # to not find them 40688 if test "x$new_path" = x \ 40689 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 40690 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 40691 new_path="$path" 40692 40693 windows_path="$new_path" 40694 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 40695 unix_path=`$CYGPATH -u "$windows_path"` 40696 new_path="$unix_path" 40697 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 40698 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 40699 new_path="$unix_path" 40700 fi 40701 40702 fi 40703 40704 if test "x$new_path" = x; then 40705 # It's still not found. Now this is an unrecoverable error. 40706 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of MT, which resolves as \"$complete\", is not found." >&5 40707 $as_echo "$as_me: The path of MT, which resolves as \"$complete\", is not found." >&6;} 40708 has_space=`$ECHO "$complete" | $GREP " "` 40709 if test "x$has_space" != x; then 40710 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 40711 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 40712 fi 40713 as_fn_error $? "Cannot locate the the path of MT" "$LINENO" 5 40714 fi 40715 fi 40716 40717 # Now new_path has a complete unix path to the binary 40718 if test "x`$ECHO $new_path | $GREP ^/bin/`" != x; then 40719 # Keep paths in /bin as-is, but remove trailing .exe if any 40720 new_path="${new_path/%.exe/}" 40721 # Do not save /bin paths to all_fixpath_prefixes! 40722 else 40723 # Not in mixed or Windows style, start by that. 40724 new_path=`cmd //c echo $new_path` 40725 40726 input_path="$new_path" 40727 # Check if we need to convert this using DOS-style short mode. If the path 40728 # contains just simple characters, use it. Otherwise (spaces, weird characters), 40729 # take no chances and rewrite it. 40730 # Note: m4 eats our [], so we need to use [ and ] instead. 40731 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 40732 if test "x$has_forbidden_chars" != x; then 40733 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 40734 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 40735 fi 40736 40737 # Output is in $new_path 40738 40739 windows_path="$new_path" 40740 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 40741 unix_path=`$CYGPATH -u "$windows_path"` 40742 new_path="$unix_path" 40743 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 40744 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 40745 new_path="$unix_path" 40746 fi 40747 40748 # remove trailing .exe if any 40749 new_path="${new_path/%.exe/}" 40750 40751 # Save the first 10 bytes of this path to the storage, so fixpath can work. 40752 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 40753 fi 40754 40755 else 40756 # We're on a unix platform. Hooray! :) 40757 # First separate the path from the arguments. This will split at the first 40758 # space. 40759 complete="$MT" 40760 path="${complete%% *}" 40761 tmp="$complete EOL" 40762 arguments="${tmp#* }" 40763 40764 # Cannot rely on the command "which" here since it doesn't always work. 40765 is_absolute_path=`$ECHO "$path" | $GREP ^/` 40766 if test -z "$is_absolute_path"; then 40767 # Path to executable is not absolute. Find it. 40768 IFS_save="$IFS" 40769 IFS=: 40770 for p in $PATH; do 40771 if test -f "$p/$path" && test -x "$p/$path"; then 40772 new_path="$p/$path" 40773 break 40774 fi 40775 done 40776 IFS="$IFS_save" 40777 else 40778 # This is an absolute path, we can use it without further modifications. 40779 new_path="$path" 40780 fi 40781 40782 if test "x$new_path" = x; then 40783 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of MT, which resolves as \"$complete\", is not found." >&5 40784 $as_echo "$as_me: The path of MT, which resolves as \"$complete\", is not found." >&6;} 40785 has_space=`$ECHO "$complete" | $GREP " "` 40786 if test "x$has_space" != x; then 40787 { $as_echo "$as_me:${as_lineno-$LINENO}: This might be caused by spaces in the path, which is not allowed." >&5 40788 $as_echo "$as_me: This might be caused by spaces in the path, which is not allowed." >&6;} 40789 fi 40790 as_fn_error $? "Cannot locate the the path of MT" "$LINENO" 5 40791 fi 40792 fi 40793 40794 # Now join together the path and the arguments once again 40795 if test "x$arguments" != xEOL; then 40796 new_complete="$new_path ${arguments% *}" 40797 else 40798 new_complete="$new_path" 40799 fi 40800 40801 if test "x$complete" != "x$new_complete"; then 40802 MT="$new_complete" 40803 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting MT to \"$new_complete\"" >&5 40804 $as_echo "$as_me: Rewriting MT to \"$new_complete\"" >&6;} 40805 fi 40806 fi 40807 40808 # Setup the resource compiler (RC) 40809 # Extract the first word of "rc", so it can be a program name with args. 40810 set dummy rc; ac_word=$2 40811 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 40812 $as_echo_n "checking for $ac_word... " >&6; } 40813 if ${ac_cv_prog_RC+:} false; then : 40814 $as_echo_n "(cached) " >&6 40815 else 40816 if test -n "$RC"; then 40817 ac_cv_prog_RC="$RC" # Let the user override the test. 40818 else 40819 ac_prog_rejected=no 40820 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 40821 for as_dir in $PATH 40822 do 40823 IFS=$as_save_IFS 40824 test -z "$as_dir" && as_dir=. 40825 for ac_exec_ext in '' $ac_executable_extensions; do 40826 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 40827 if test "$as_dir/$ac_word$ac_exec_ext" = "/usr/bin/rc"; then 40828 ac_prog_rejected=yes 40829 continue 40830 fi 40831 ac_cv_prog_RC="rc" 40832 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 40833 break 2 40834 fi 40835 done 40836 done 40837 IFS=$as_save_IFS 40838 40839 if test $ac_prog_rejected = yes; then 40840 # We found a bogon in the path, so make sure we never use it. 40841 set dummy $ac_cv_prog_RC 40842 shift 40843 if test $# != 0; then 40844 # We chose a different compiler from the bogus one. 40845 # However, it has the same basename, so the bogon will be chosen 40846 # first if we set RC to just the basename; use the full file name. 40847 shift 40848 ac_cv_prog_RC="$as_dir/$ac_word${1+' '}$@" 40849 fi 40850 fi 40851 fi 40852 fi 40853 RC=$ac_cv_prog_RC 40854 if test -n "$RC"; then 40855 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $RC" >&5 40856 $as_echo "$RC" >&6; } 40857 else 40858 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 40859 $as_echo "no" >&6; } 40860 fi 40861 40862 40863 40864 # Only process if variable expands to non-empty 40865 40866 if test "x$RC" != x; then 40867 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 40868 40869 # First separate the path from the arguments. This will split at the first 40870 # space. 40871 complete="$RC" 40872 path="${complete%% *}" 40873 tmp="$complete EOL" 40874 arguments="${tmp#* }" 40875 40876 # Input might be given as Windows format, start by converting to 40877 # unix format. 40878 new_path=`$CYGPATH -u "$path"` 40879 40880 # Now try to locate executable using which 40881 new_path=`$WHICH "$new_path" 2> /dev/null` 40882 # bat and cmd files are not always considered executable in cygwin causing which 40883 # to not find them 40884 if test "x$new_path" = x \ 40885 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 40886 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 40887 new_path=`$CYGPATH -u "$path"` 40888 fi 40889 if test "x$new_path" = x; then 40890 # Oops. Which didn't find the executable. 40891 # The splitting of arguments from the executable at a space might have been incorrect, 40892 # since paths with space are more likely in Windows. Give it another try with the whole 40893 # argument. 40894 path="$complete" 40895 arguments="EOL" 40896 new_path=`$CYGPATH -u "$path"` 40897 new_path=`$WHICH "$new_path" 2> /dev/null` 40898 # bat and cmd files are not always considered executable in cygwin causing which 40899 # to not find them 40900 if test "x$new_path" = x \ 40901 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 40902 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 40903 new_path=`$CYGPATH -u "$path"` 40904 fi 40905 if test "x$new_path" = x; then 40906 # It's still not found. Now this is an unrecoverable error. 40907 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of RC, which resolves as \"$complete\", is not found." >&5 40908 $as_echo "$as_me: The path of RC, which resolves as \"$complete\", is not found." >&6;} 40909 has_space=`$ECHO "$complete" | $GREP " "` 40910 if test "x$has_space" != x; then 40911 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 40912 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 40913 fi 40914 as_fn_error $? "Cannot locate the the path of RC" "$LINENO" 5 40915 fi 40916 fi 40917 40918 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 40919 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 40920 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 40921 # "foo.exe" is OK but "foo" is an error. 40922 # 40923 # This test is therefore slightly more accurate than "test -f" to check for file presence. 40924 # It is also a way to make sure we got the proper file name for the real test later on. 40925 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 40926 if test "x$test_shortpath" = x; then 40927 # Short path failed, file does not exist as specified. 40928 # Try adding .exe or .cmd 40929 if test -f "${new_path}.exe"; then 40930 input_to_shortpath="${new_path}.exe" 40931 elif test -f "${new_path}.cmd"; then 40932 input_to_shortpath="${new_path}.cmd" 40933 else 40934 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of RC, which resolves as \"$new_path\", is invalid." >&5 40935 $as_echo "$as_me: The path of RC, which resolves as \"$new_path\", is invalid." >&6;} 40936 { $as_echo "$as_me:${as_lineno-$LINENO}: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&5 40937 $as_echo "$as_me: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&6;} 40938 as_fn_error $? "Cannot locate the the path of RC" "$LINENO" 5 40939 fi 40940 else 40941 input_to_shortpath="$new_path" 40942 fi 40943 40944 # Call helper function which possibly converts this using DOS-style short mode. 40945 # If so, the updated path is stored in $new_path. 40946 new_path="$input_to_shortpath" 40947 40948 input_path="$input_to_shortpath" 40949 # Check if we need to convert this using DOS-style short mode. If the path 40950 # contains just simple characters, use it. Otherwise (spaces, weird characters), 40951 # take no chances and rewrite it. 40952 # Note: m4 eats our [], so we need to use [ and ] instead. 40953 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 40954 if test "x$has_forbidden_chars" != x; then 40955 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 40956 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 40957 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 40958 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 40959 # Going to short mode and back again did indeed matter. Since short mode is 40960 # case insensitive, let's make it lowercase to improve readability. 40961 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 40962 # Now convert it back to Unix-style (cygpath) 40963 input_path=`$CYGPATH -u "$shortmode_path"` 40964 new_path="$input_path" 40965 fi 40966 fi 40967 40968 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 40969 if test "x$test_cygdrive_prefix" = x; then 40970 # As a simple fix, exclude /usr/bin since it's not a real path. 40971 if test "x`$ECHO $input_to_shortpath | $GREP ^/usr/bin/`" = x; then 40972 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 40973 # a path prefixed by /cygdrive for fixpath to work. 40974 new_path="$CYGWIN_ROOT_PATH$input_path" 40975 fi 40976 fi 40977 40978 # remove trailing .exe if any 40979 new_path="${new_path/%.exe/}" 40980 40981 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 40982 40983 # First separate the path from the arguments. This will split at the first 40984 # space. 40985 complete="$RC" 40986 path="${complete%% *}" 40987 tmp="$complete EOL" 40988 arguments="${tmp#* }" 40989 40990 # Input might be given as Windows format, start by converting to 40991 # unix format. 40992 new_path="$path" 40993 40994 windows_path="$new_path" 40995 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 40996 unix_path=`$CYGPATH -u "$windows_path"` 40997 new_path="$unix_path" 40998 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 40999 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 41000 new_path="$unix_path" 41001 fi 41002 41003 41004 # Now try to locate executable using which 41005 new_path=`$WHICH "$new_path" 2> /dev/null` 41006 41007 if test "x$new_path" = x; then 41008 # Oops. Which didn't find the executable. 41009 # The splitting of arguments from the executable at a space might have been incorrect, 41010 # since paths with space are more likely in Windows. Give it another try with the whole 41011 # argument. 41012 path="$complete" 41013 arguments="EOL" 41014 new_path="$path" 41015 41016 windows_path="$new_path" 41017 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 41018 unix_path=`$CYGPATH -u "$windows_path"` 41019 new_path="$unix_path" 41020 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 41021 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 41022 new_path="$unix_path" 41023 fi 41024 41025 41026 new_path=`$WHICH "$new_path" 2> /dev/null` 41027 # bat and cmd files are not always considered executable in MSYS causing which 41028 # to not find them 41029 if test "x$new_path" = x \ 41030 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 41031 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 41032 new_path="$path" 41033 41034 windows_path="$new_path" 41035 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 41036 unix_path=`$CYGPATH -u "$windows_path"` 41037 new_path="$unix_path" 41038 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 41039 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 41040 new_path="$unix_path" 41041 fi 41042 41043 fi 41044 41045 if test "x$new_path" = x; then 41046 # It's still not found. Now this is an unrecoverable error. 41047 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of RC, which resolves as \"$complete\", is not found." >&5 41048 $as_echo "$as_me: The path of RC, which resolves as \"$complete\", is not found." >&6;} 41049 has_space=`$ECHO "$complete" | $GREP " "` 41050 if test "x$has_space" != x; then 41051 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 41052 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 41053 fi 41054 as_fn_error $? "Cannot locate the the path of RC" "$LINENO" 5 41055 fi 41056 fi 41057 41058 # Now new_path has a complete unix path to the binary 41059 if test "x`$ECHO $new_path | $GREP ^/bin/`" != x; then 41060 # Keep paths in /bin as-is, but remove trailing .exe if any 41061 new_path="${new_path/%.exe/}" 41062 # Do not save /bin paths to all_fixpath_prefixes! 41063 else 41064 # Not in mixed or Windows style, start by that. 41065 new_path=`cmd //c echo $new_path` 41066 41067 input_path="$new_path" 41068 # Check if we need to convert this using DOS-style short mode. If the path 41069 # contains just simple characters, use it. Otherwise (spaces, weird characters), 41070 # take no chances and rewrite it. 41071 # Note: m4 eats our [], so we need to use [ and ] instead. 41072 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 41073 if test "x$has_forbidden_chars" != x; then 41074 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 41075 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 41076 fi 41077 41078 # Output is in $new_path 41079 41080 windows_path="$new_path" 41081 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 41082 unix_path=`$CYGPATH -u "$windows_path"` 41083 new_path="$unix_path" 41084 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 41085 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 41086 new_path="$unix_path" 41087 fi 41088 41089 # remove trailing .exe if any 41090 new_path="${new_path/%.exe/}" 41091 41092 # Save the first 10 bytes of this path to the storage, so fixpath can work. 41093 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 41094 fi 41095 41096 else 41097 # We're on a unix platform. Hooray! :) 41098 # First separate the path from the arguments. This will split at the first 41099 # space. 41100 complete="$RC" 41101 path="${complete%% *}" 41102 tmp="$complete EOL" 41103 arguments="${tmp#* }" 41104 41105 # Cannot rely on the command "which" here since it doesn't always work. 41106 is_absolute_path=`$ECHO "$path" | $GREP ^/` 41107 if test -z "$is_absolute_path"; then 41108 # Path to executable is not absolute. Find it. 41109 IFS_save="$IFS" 41110 IFS=: 41111 for p in $PATH; do 41112 if test -f "$p/$path" && test -x "$p/$path"; then 41113 new_path="$p/$path" 41114 break 41115 fi 41116 done 41117 IFS="$IFS_save" 41118 else 41119 # This is an absolute path, we can use it without further modifications. 41120 new_path="$path" 41121 fi 41122 41123 if test "x$new_path" = x; then 41124 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of RC, which resolves as \"$complete\", is not found." >&5 41125 $as_echo "$as_me: The path of RC, which resolves as \"$complete\", is not found." >&6;} 41126 has_space=`$ECHO "$complete" | $GREP " "` 41127 if test "x$has_space" != x; then 41128 { $as_echo "$as_me:${as_lineno-$LINENO}: This might be caused by spaces in the path, which is not allowed." >&5 41129 $as_echo "$as_me: This might be caused by spaces in the path, which is not allowed." >&6;} 41130 fi 41131 as_fn_error $? "Cannot locate the the path of RC" "$LINENO" 5 41132 fi 41133 fi 41134 41135 # Now join together the path and the arguments once again 41136 if test "x$arguments" != xEOL; then 41137 new_complete="$new_path ${arguments% *}" 41138 else 41139 new_complete="$new_path" 41140 fi 41141 41142 if test "x$complete" != "x$new_complete"; then 41143 RC="$new_complete" 41144 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting RC to \"$new_complete\"" >&5 41145 $as_echo "$as_me: Rewriting RC to \"$new_complete\"" >&6;} 41146 fi 41147 fi 41148 41149 # Extract the first word of "dumpbin", so it can be a program name with args. 41150 set dummy dumpbin; ac_word=$2 41151 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 41152 $as_echo_n "checking for $ac_word... " >&6; } 41153 if ${ac_cv_prog_DUMPBIN+:} false; then : 41154 $as_echo_n "(cached) " >&6 41155 else 41156 if test -n "$DUMPBIN"; then 41157 ac_cv_prog_DUMPBIN="$DUMPBIN" # Let the user override the test. 41158 else 41159 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 41160 for as_dir in $PATH 41161 do 41162 IFS=$as_save_IFS 41163 test -z "$as_dir" && as_dir=. 41164 for ac_exec_ext in '' $ac_executable_extensions; do 41165 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 41166 ac_cv_prog_DUMPBIN="dumpbin" 41167 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 41168 break 2 41169 fi 41170 done 41171 done 41172 IFS=$as_save_IFS 41173 41174 fi 41175 fi 41176 DUMPBIN=$ac_cv_prog_DUMPBIN 41177 if test -n "$DUMPBIN"; then 41178 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $DUMPBIN" >&5 41179 $as_echo "$DUMPBIN" >&6; } 41180 else 41181 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 41182 $as_echo "no" >&6; } 41183 fi 41184 41185 41186 41187 # Only process if variable expands to non-empty 41188 41189 if test "x$DUMPBIN" != x; then 41190 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 41191 41192 # First separate the path from the arguments. This will split at the first 41193 # space. 41194 complete="$DUMPBIN" 41195 path="${complete%% *}" 41196 tmp="$complete EOL" 41197 arguments="${tmp#* }" 41198 41199 # Input might be given as Windows format, start by converting to 41200 # unix format. 41201 new_path=`$CYGPATH -u "$path"` 41202 41203 # Now try to locate executable using which 41204 new_path=`$WHICH "$new_path" 2> /dev/null` 41205 # bat and cmd files are not always considered executable in cygwin causing which 41206 # to not find them 41207 if test "x$new_path" = x \ 41208 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 41209 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 41210 new_path=`$CYGPATH -u "$path"` 41211 fi 41212 if test "x$new_path" = x; then 41213 # Oops. Which didn't find the executable. 41214 # The splitting of arguments from the executable at a space might have been incorrect, 41215 # since paths with space are more likely in Windows. Give it another try with the whole 41216 # argument. 41217 path="$complete" 41218 arguments="EOL" 41219 new_path=`$CYGPATH -u "$path"` 41220 new_path=`$WHICH "$new_path" 2> /dev/null` 41221 # bat and cmd files are not always considered executable in cygwin causing which 41222 # to not find them 41223 if test "x$new_path" = x \ 41224 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 41225 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 41226 new_path=`$CYGPATH -u "$path"` 41227 fi 41228 if test "x$new_path" = x; then 41229 # It's still not found. Now this is an unrecoverable error. 41230 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of DUMPBIN, which resolves as \"$complete\", is not found." >&5 41231 $as_echo "$as_me: The path of DUMPBIN, which resolves as \"$complete\", is not found." >&6;} 41232 has_space=`$ECHO "$complete" | $GREP " "` 41233 if test "x$has_space" != x; then 41234 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 41235 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 41236 fi 41237 as_fn_error $? "Cannot locate the the path of DUMPBIN" "$LINENO" 5 41238 fi 41239 fi 41240 41241 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 41242 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 41243 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 41244 # "foo.exe" is OK but "foo" is an error. 41245 # 41246 # This test is therefore slightly more accurate than "test -f" to check for file presence. 41247 # It is also a way to make sure we got the proper file name for the real test later on. 41248 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 41249 if test "x$test_shortpath" = x; then 41250 # Short path failed, file does not exist as specified. 41251 # Try adding .exe or .cmd 41252 if test -f "${new_path}.exe"; then 41253 input_to_shortpath="${new_path}.exe" 41254 elif test -f "${new_path}.cmd"; then 41255 input_to_shortpath="${new_path}.cmd" 41256 else 41257 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of DUMPBIN, which resolves as \"$new_path\", is invalid." >&5 41258 $as_echo "$as_me: The path of DUMPBIN, which resolves as \"$new_path\", is invalid." >&6;} 41259 { $as_echo "$as_me:${as_lineno-$LINENO}: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&5 41260 $as_echo "$as_me: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&6;} 41261 as_fn_error $? "Cannot locate the the path of DUMPBIN" "$LINENO" 5 41262 fi 41263 else 41264 input_to_shortpath="$new_path" 41265 fi 41266 41267 # Call helper function which possibly converts this using DOS-style short mode. 41268 # If so, the updated path is stored in $new_path. 41269 new_path="$input_to_shortpath" 41270 41271 input_path="$input_to_shortpath" 41272 # Check if we need to convert this using DOS-style short mode. If the path 41273 # contains just simple characters, use it. Otherwise (spaces, weird characters), 41274 # take no chances and rewrite it. 41275 # Note: m4 eats our [], so we need to use [ and ] instead. 41276 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 41277 if test "x$has_forbidden_chars" != x; then 41278 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 41279 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 41280 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 41281 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 41282 # Going to short mode and back again did indeed matter. Since short mode is 41283 # case insensitive, let's make it lowercase to improve readability. 41284 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 41285 # Now convert it back to Unix-style (cygpath) 41286 input_path=`$CYGPATH -u "$shortmode_path"` 41287 new_path="$input_path" 41288 fi 41289 fi 41290 41291 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 41292 if test "x$test_cygdrive_prefix" = x; then 41293 # As a simple fix, exclude /usr/bin since it's not a real path. 41294 if test "x`$ECHO $input_to_shortpath | $GREP ^/usr/bin/`" = x; then 41295 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 41296 # a path prefixed by /cygdrive for fixpath to work. 41297 new_path="$CYGWIN_ROOT_PATH$input_path" 41298 fi 41299 fi 41300 41301 # remove trailing .exe if any 41302 new_path="${new_path/%.exe/}" 41303 41304 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 41305 41306 # First separate the path from the arguments. This will split at the first 41307 # space. 41308 complete="$DUMPBIN" 41309 path="${complete%% *}" 41310 tmp="$complete EOL" 41311 arguments="${tmp#* }" 41312 41313 # Input might be given as Windows format, start by converting to 41314 # unix format. 41315 new_path="$path" 41316 41317 windows_path="$new_path" 41318 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 41319 unix_path=`$CYGPATH -u "$windows_path"` 41320 new_path="$unix_path" 41321 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 41322 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 41323 new_path="$unix_path" 41324 fi 41325 41326 41327 # Now try to locate executable using which 41328 new_path=`$WHICH "$new_path" 2> /dev/null` 41329 41330 if test "x$new_path" = x; then 41331 # Oops. Which didn't find the executable. 41332 # The splitting of arguments from the executable at a space might have been incorrect, 41333 # since paths with space are more likely in Windows. Give it another try with the whole 41334 # argument. 41335 path="$complete" 41336 arguments="EOL" 41337 new_path="$path" 41338 41339 windows_path="$new_path" 41340 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 41341 unix_path=`$CYGPATH -u "$windows_path"` 41342 new_path="$unix_path" 41343 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 41344 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 41345 new_path="$unix_path" 41346 fi 41347 41348 41349 new_path=`$WHICH "$new_path" 2> /dev/null` 41350 # bat and cmd files are not always considered executable in MSYS causing which 41351 # to not find them 41352 if test "x$new_path" = x \ 41353 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 41354 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 41355 new_path="$path" 41356 41357 windows_path="$new_path" 41358 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 41359 unix_path=`$CYGPATH -u "$windows_path"` 41360 new_path="$unix_path" 41361 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 41362 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 41363 new_path="$unix_path" 41364 fi 41365 41366 fi 41367 41368 if test "x$new_path" = x; then 41369 # It's still not found. Now this is an unrecoverable error. 41370 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of DUMPBIN, which resolves as \"$complete\", is not found." >&5 41371 $as_echo "$as_me: The path of DUMPBIN, which resolves as \"$complete\", is not found." >&6;} 41372 has_space=`$ECHO "$complete" | $GREP " "` 41373 if test "x$has_space" != x; then 41374 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 41375 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 41376 fi 41377 as_fn_error $? "Cannot locate the the path of DUMPBIN" "$LINENO" 5 41378 fi 41379 fi 41380 41381 # Now new_path has a complete unix path to the binary 41382 if test "x`$ECHO $new_path | $GREP ^/bin/`" != x; then 41383 # Keep paths in /bin as-is, but remove trailing .exe if any 41384 new_path="${new_path/%.exe/}" 41385 # Do not save /bin paths to all_fixpath_prefixes! 41386 else 41387 # Not in mixed or Windows style, start by that. 41388 new_path=`cmd //c echo $new_path` 41389 41390 input_path="$new_path" 41391 # Check if we need to convert this using DOS-style short mode. If the path 41392 # contains just simple characters, use it. Otherwise (spaces, weird characters), 41393 # take no chances and rewrite it. 41394 # Note: m4 eats our [], so we need to use [ and ] instead. 41395 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 41396 if test "x$has_forbidden_chars" != x; then 41397 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 41398 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 41399 fi 41400 41401 # Output is in $new_path 41402 41403 windows_path="$new_path" 41404 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 41405 unix_path=`$CYGPATH -u "$windows_path"` 41406 new_path="$unix_path" 41407 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 41408 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 41409 new_path="$unix_path" 41410 fi 41411 41412 # remove trailing .exe if any 41413 new_path="${new_path/%.exe/}" 41414 41415 # Save the first 10 bytes of this path to the storage, so fixpath can work. 41416 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 41417 fi 41418 41419 else 41420 # We're on a unix platform. Hooray! :) 41421 # First separate the path from the arguments. This will split at the first 41422 # space. 41423 complete="$DUMPBIN" 41424 path="${complete%% *}" 41425 tmp="$complete EOL" 41426 arguments="${tmp#* }" 41427 41428 # Cannot rely on the command "which" here since it doesn't always work. 41429 is_absolute_path=`$ECHO "$path" | $GREP ^/` 41430 if test -z "$is_absolute_path"; then 41431 # Path to executable is not absolute. Find it. 41432 IFS_save="$IFS" 41433 IFS=: 41434 for p in $PATH; do 41435 if test -f "$p/$path" && test -x "$p/$path"; then 41436 new_path="$p/$path" 41437 break 41438 fi 41439 done 41440 IFS="$IFS_save" 41441 else 41442 # This is an absolute path, we can use it without further modifications. 41443 new_path="$path" 41444 fi 41445 41446 if test "x$new_path" = x; then 41447 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of DUMPBIN, which resolves as \"$complete\", is not found." >&5 41448 $as_echo "$as_me: The path of DUMPBIN, which resolves as \"$complete\", is not found." >&6;} 41449 has_space=`$ECHO "$complete" | $GREP " "` 41450 if test "x$has_space" != x; then 41451 { $as_echo "$as_me:${as_lineno-$LINENO}: This might be caused by spaces in the path, which is not allowed." >&5 41452 $as_echo "$as_me: This might be caused by spaces in the path, which is not allowed." >&6;} 41453 fi 41454 as_fn_error $? "Cannot locate the the path of DUMPBIN" "$LINENO" 5 41455 fi 41456 fi 41457 41458 # Now join together the path and the arguments once again 41459 if test "x$arguments" != xEOL; then 41460 new_complete="$new_path ${arguments% *}" 41461 else 41462 new_complete="$new_path" 41463 fi 41464 41465 if test "x$complete" != "x$new_complete"; then 41466 DUMPBIN="$new_complete" 41467 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting DUMPBIN to \"$new_complete\"" >&5 41468 $as_echo "$as_me: Rewriting DUMPBIN to \"$new_complete\"" >&6;} 41469 fi 41470 fi 41471 41472 # We need to check for 'msbuild.exe' because at the place where we expect to 41473 # find 'msbuild.exe' there's also a directory called 'msbuild' and configure 41474 # won't find the 'msbuild.exe' executable in that case (and the 41475 # 'ac_executable_extensions' is unusable due to performance reasons). 41476 # Notice that we intentionally don't fix up the path to MSBUILD because we 41477 # will call it in a DOS shell during freetype detection on Windows (see 41478 # 'LIB_SETUP_FREETYPE' in "libraries.m4" 41479 # Extract the first word of "msbuild.exe", so it can be a program name with args. 41480 set dummy msbuild.exe; ac_word=$2 41481 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 41482 $as_echo_n "checking for $ac_word... " >&6; } 41483 if ${ac_cv_prog_MSBUILD+:} false; then : 41484 $as_echo_n "(cached) " >&6 41485 else 41486 if test -n "$MSBUILD"; then 41487 ac_cv_prog_MSBUILD="$MSBUILD" # Let the user override the test. 41488 else 41489 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 41490 for as_dir in $PATH 41491 do 41492 IFS=$as_save_IFS 41493 test -z "$as_dir" && as_dir=. 41494 for ac_exec_ext in '' $ac_executable_extensions; do 41495 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 41496 ac_cv_prog_MSBUILD="msbuild.exe" 41497 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 41498 break 2 41499 fi 41500 done 41501 done 41502 IFS=$as_save_IFS 41503 41504 fi 41505 fi 41506 MSBUILD=$ac_cv_prog_MSBUILD 41507 if test -n "$MSBUILD"; then 41508 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MSBUILD" >&5 41509 $as_echo "$MSBUILD" >&6; } 41510 else 41511 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 41512 $as_echo "no" >&6; } 41513 fi 41514 41515 41516 fi 41517 41518 if test "x$OPENJDK_TARGET_OS" = xsolaris; then 41519 41520 41521 # Publish this variable in the help. 41522 41523 41524 if [ -z "${STRIP+x}" ]; then 41525 # The variable is not set by user, try to locate tool using the code snippet 41526 for ac_prog in strip 41527 do 41528 # Extract the first word of "$ac_prog", so it can be a program name with args. 41529 set dummy $ac_prog; ac_word=$2 41530 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 41531 $as_echo_n "checking for $ac_word... " >&6; } 41532 if ${ac_cv_path_STRIP+:} false; then : 41533 $as_echo_n "(cached) " >&6 41534 else 41535 case $STRIP in 41536 [\\/]* | ?:[\\/]*) 41537 ac_cv_path_STRIP="$STRIP" # Let the user override the test with a path. 41538 ;; 41539 *) 41540 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 41541 for as_dir in $PATH 41542 do 41543 IFS=$as_save_IFS 41544 test -z "$as_dir" && as_dir=. 41545 for ac_exec_ext in '' $ac_executable_extensions; do 41546 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 41547 ac_cv_path_STRIP="$as_dir/$ac_word$ac_exec_ext" 41548 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 41549 break 2 41550 fi 41551 done 41552 done 41553 IFS=$as_save_IFS 41554 41555 ;; 41556 esac 41557 fi 41558 STRIP=$ac_cv_path_STRIP 41559 if test -n "$STRIP"; then 41560 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $STRIP" >&5 41561 $as_echo "$STRIP" >&6; } 41562 else 41563 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 41564 $as_echo "no" >&6; } 41565 fi 41566 41567 41568 test -n "$STRIP" && break 41569 done 41570 41571 else 41572 # The variable is set, but is it from the command line or the environment? 41573 41574 # Try to remove the string !STRIP! from our list. 41575 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!STRIP!/} 41576 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 41577 # If it failed, the variable was not from the command line. Ignore it, 41578 # but warn the user (except for BASH, which is always set by the calling BASH). 41579 if test "xSTRIP" != xBASH; then 41580 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of STRIP from the environment. Use command line variables instead." >&5 41581 $as_echo "$as_me: WARNING: Ignoring value of STRIP from the environment. Use command line variables instead." >&2;} 41582 fi 41583 # Try to locate tool using the code snippet 41584 for ac_prog in strip 41585 do 41586 # Extract the first word of "$ac_prog", so it can be a program name with args. 41587 set dummy $ac_prog; ac_word=$2 41588 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 41589 $as_echo_n "checking for $ac_word... " >&6; } 41590 if ${ac_cv_path_STRIP+:} false; then : 41591 $as_echo_n "(cached) " >&6 41592 else 41593 case $STRIP in 41594 [\\/]* | ?:[\\/]*) 41595 ac_cv_path_STRIP="$STRIP" # Let the user override the test with a path. 41596 ;; 41597 *) 41598 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 41599 for as_dir in $PATH 41600 do 41601 IFS=$as_save_IFS 41602 test -z "$as_dir" && as_dir=. 41603 for ac_exec_ext in '' $ac_executable_extensions; do 41604 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 41605 ac_cv_path_STRIP="$as_dir/$ac_word$ac_exec_ext" 41606 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 41607 break 2 41608 fi 41609 done 41610 done 41611 IFS=$as_save_IFS 41612 41613 ;; 41614 esac 41615 fi 41616 STRIP=$ac_cv_path_STRIP 41617 if test -n "$STRIP"; then 41618 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $STRIP" >&5 41619 $as_echo "$STRIP" >&6; } 41620 else 41621 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 41622 $as_echo "no" >&6; } 41623 fi 41624 41625 41626 test -n "$STRIP" && break 41627 done 41628 41629 else 41630 # If it succeeded, then it was overridden by the user. We will use it 41631 # for the tool. 41632 41633 # First remove it from the list of overridden variables, so we can test 41634 # for unknown variables in the end. 41635 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 41636 41637 # Check if we try to supply an empty value 41638 if test "x$STRIP" = x; then 41639 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool STRIP= (no value)" >&5 41640 $as_echo "$as_me: Setting user supplied tool STRIP= (no value)" >&6;} 41641 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for STRIP" >&5 41642 $as_echo_n "checking for STRIP... " >&6; } 41643 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 41644 $as_echo "disabled" >&6; } 41645 else 41646 # Check if the provided tool contains a complete path. 41647 tool_specified="$STRIP" 41648 tool_basename="${tool_specified##*/}" 41649 if test "x$tool_basename" = "x$tool_specified"; then 41650 # A command without a complete path is provided, search $PATH. 41651 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool STRIP=$tool_basename" >&5 41652 $as_echo "$as_me: Will search for user supplied tool STRIP=$tool_basename" >&6;} 41653 # Extract the first word of "$tool_basename", so it can be a program name with args. 41654 set dummy $tool_basename; ac_word=$2 41655 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 41656 $as_echo_n "checking for $ac_word... " >&6; } 41657 if ${ac_cv_path_STRIP+:} false; then : 41658 $as_echo_n "(cached) " >&6 41659 else 41660 case $STRIP in 41661 [\\/]* | ?:[\\/]*) 41662 ac_cv_path_STRIP="$STRIP" # Let the user override the test with a path. 41663 ;; 41664 *) 41665 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 41666 for as_dir in $PATH 41667 do 41668 IFS=$as_save_IFS 41669 test -z "$as_dir" && as_dir=. 41670 for ac_exec_ext in '' $ac_executable_extensions; do 41671 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 41672 ac_cv_path_STRIP="$as_dir/$ac_word$ac_exec_ext" 41673 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 41674 break 2 41675 fi 41676 done 41677 done 41678 IFS=$as_save_IFS 41679 41680 ;; 41681 esac 41682 fi 41683 STRIP=$ac_cv_path_STRIP 41684 if test -n "$STRIP"; then 41685 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $STRIP" >&5 41686 $as_echo "$STRIP" >&6; } 41687 else 41688 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 41689 $as_echo "no" >&6; } 41690 fi 41691 41692 41693 if test "x$STRIP" = x; then 41694 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 41695 fi 41696 else 41697 # Otherwise we believe it is a complete path. Use it as it is. 41698 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool STRIP=$tool_specified" >&5 41699 $as_echo "$as_me: Will use user supplied tool STRIP=$tool_specified" >&6;} 41700 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for STRIP" >&5 41701 $as_echo_n "checking for STRIP... " >&6; } 41702 if test ! -x "$tool_specified"; then 41703 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 41704 $as_echo "not found" >&6; } 41705 as_fn_error $? "User supplied tool STRIP=$tool_specified does not exist or is not executable" "$LINENO" 5 41706 fi 41707 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 41708 $as_echo "$tool_specified" >&6; } 41709 fi 41710 fi 41711 fi 41712 41713 fi 41714 41715 41716 41717 # Only process if variable expands to non-empty 41718 41719 if test "x$STRIP" != x; then 41720 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 41721 41722 # First separate the path from the arguments. This will split at the first 41723 # space. 41724 complete="$STRIP" 41725 path="${complete%% *}" 41726 tmp="$complete EOL" 41727 arguments="${tmp#* }" 41728 41729 # Input might be given as Windows format, start by converting to 41730 # unix format. 41731 new_path=`$CYGPATH -u "$path"` 41732 41733 # Now try to locate executable using which 41734 new_path=`$WHICH "$new_path" 2> /dev/null` 41735 # bat and cmd files are not always considered executable in cygwin causing which 41736 # to not find them 41737 if test "x$new_path" = x \ 41738 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 41739 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 41740 new_path=`$CYGPATH -u "$path"` 41741 fi 41742 if test "x$new_path" = x; then 41743 # Oops. Which didn't find the executable. 41744 # The splitting of arguments from the executable at a space might have been incorrect, 41745 # since paths with space are more likely in Windows. Give it another try with the whole 41746 # argument. 41747 path="$complete" 41748 arguments="EOL" 41749 new_path=`$CYGPATH -u "$path"` 41750 new_path=`$WHICH "$new_path" 2> /dev/null` 41751 # bat and cmd files are not always considered executable in cygwin causing which 41752 # to not find them 41753 if test "x$new_path" = x \ 41754 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 41755 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 41756 new_path=`$CYGPATH -u "$path"` 41757 fi 41758 if test "x$new_path" = x; then 41759 # It's still not found. Now this is an unrecoverable error. 41760 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of STRIP, which resolves as \"$complete\", is not found." >&5 41761 $as_echo "$as_me: The path of STRIP, which resolves as \"$complete\", is not found." >&6;} 41762 has_space=`$ECHO "$complete" | $GREP " "` 41763 if test "x$has_space" != x; then 41764 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 41765 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 41766 fi 41767 as_fn_error $? "Cannot locate the the path of STRIP" "$LINENO" 5 41768 fi 41769 fi 41770 41771 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 41772 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 41773 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 41774 # "foo.exe" is OK but "foo" is an error. 41775 # 41776 # This test is therefore slightly more accurate than "test -f" to check for file presence. 41777 # It is also a way to make sure we got the proper file name for the real test later on. 41778 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 41779 if test "x$test_shortpath" = x; then 41780 # Short path failed, file does not exist as specified. 41781 # Try adding .exe or .cmd 41782 if test -f "${new_path}.exe"; then 41783 input_to_shortpath="${new_path}.exe" 41784 elif test -f "${new_path}.cmd"; then 41785 input_to_shortpath="${new_path}.cmd" 41786 else 41787 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of STRIP, which resolves as \"$new_path\", is invalid." >&5 41788 $as_echo "$as_me: The path of STRIP, which resolves as \"$new_path\", is invalid." >&6;} 41789 { $as_echo "$as_me:${as_lineno-$LINENO}: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&5 41790 $as_echo "$as_me: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&6;} 41791 as_fn_error $? "Cannot locate the the path of STRIP" "$LINENO" 5 41792 fi 41793 else 41794 input_to_shortpath="$new_path" 41795 fi 41796 41797 # Call helper function which possibly converts this using DOS-style short mode. 41798 # If so, the updated path is stored in $new_path. 41799 new_path="$input_to_shortpath" 41800 41801 input_path="$input_to_shortpath" 41802 # Check if we need to convert this using DOS-style short mode. If the path 41803 # contains just simple characters, use it. Otherwise (spaces, weird characters), 41804 # take no chances and rewrite it. 41805 # Note: m4 eats our [], so we need to use [ and ] instead. 41806 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 41807 if test "x$has_forbidden_chars" != x; then 41808 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 41809 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 41810 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 41811 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 41812 # Going to short mode and back again did indeed matter. Since short mode is 41813 # case insensitive, let's make it lowercase to improve readability. 41814 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 41815 # Now convert it back to Unix-style (cygpath) 41816 input_path=`$CYGPATH -u "$shortmode_path"` 41817 new_path="$input_path" 41818 fi 41819 fi 41820 41821 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 41822 if test "x$test_cygdrive_prefix" = x; then 41823 # As a simple fix, exclude /usr/bin since it's not a real path. 41824 if test "x`$ECHO $input_to_shortpath | $GREP ^/usr/bin/`" = x; then 41825 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 41826 # a path prefixed by /cygdrive for fixpath to work. 41827 new_path="$CYGWIN_ROOT_PATH$input_path" 41828 fi 41829 fi 41830 41831 # remove trailing .exe if any 41832 new_path="${new_path/%.exe/}" 41833 41834 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 41835 41836 # First separate the path from the arguments. This will split at the first 41837 # space. 41838 complete="$STRIP" 41839 path="${complete%% *}" 41840 tmp="$complete EOL" 41841 arguments="${tmp#* }" 41842 41843 # Input might be given as Windows format, start by converting to 41844 # unix format. 41845 new_path="$path" 41846 41847 windows_path="$new_path" 41848 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 41849 unix_path=`$CYGPATH -u "$windows_path"` 41850 new_path="$unix_path" 41851 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 41852 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 41853 new_path="$unix_path" 41854 fi 41855 41856 41857 # Now try to locate executable using which 41858 new_path=`$WHICH "$new_path" 2> /dev/null` 41859 41860 if test "x$new_path" = x; then 41861 # Oops. Which didn't find the executable. 41862 # The splitting of arguments from the executable at a space might have been incorrect, 41863 # since paths with space are more likely in Windows. Give it another try with the whole 41864 # argument. 41865 path="$complete" 41866 arguments="EOL" 41867 new_path="$path" 41868 41869 windows_path="$new_path" 41870 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 41871 unix_path=`$CYGPATH -u "$windows_path"` 41872 new_path="$unix_path" 41873 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 41874 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 41875 new_path="$unix_path" 41876 fi 41877 41878 41879 new_path=`$WHICH "$new_path" 2> /dev/null` 41880 # bat and cmd files are not always considered executable in MSYS causing which 41881 # to not find them 41882 if test "x$new_path" = x \ 41883 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 41884 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 41885 new_path="$path" 41886 41887 windows_path="$new_path" 41888 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 41889 unix_path=`$CYGPATH -u "$windows_path"` 41890 new_path="$unix_path" 41891 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 41892 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 41893 new_path="$unix_path" 41894 fi 41895 41896 fi 41897 41898 if test "x$new_path" = x; then 41899 # It's still not found. Now this is an unrecoverable error. 41900 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of STRIP, which resolves as \"$complete\", is not found." >&5 41901 $as_echo "$as_me: The path of STRIP, which resolves as \"$complete\", is not found." >&6;} 41902 has_space=`$ECHO "$complete" | $GREP " "` 41903 if test "x$has_space" != x; then 41904 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 41905 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 41906 fi 41907 as_fn_error $? "Cannot locate the the path of STRIP" "$LINENO" 5 41908 fi 41909 fi 41910 41911 # Now new_path has a complete unix path to the binary 41912 if test "x`$ECHO $new_path | $GREP ^/bin/`" != x; then 41913 # Keep paths in /bin as-is, but remove trailing .exe if any 41914 new_path="${new_path/%.exe/}" 41915 # Do not save /bin paths to all_fixpath_prefixes! 41916 else 41917 # Not in mixed or Windows style, start by that. 41918 new_path=`cmd //c echo $new_path` 41919 41920 input_path="$new_path" 41921 # Check if we need to convert this using DOS-style short mode. If the path 41922 # contains just simple characters, use it. Otherwise (spaces, weird characters), 41923 # take no chances and rewrite it. 41924 # Note: m4 eats our [], so we need to use [ and ] instead. 41925 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 41926 if test "x$has_forbidden_chars" != x; then 41927 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 41928 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 41929 fi 41930 41931 # Output is in $new_path 41932 41933 windows_path="$new_path" 41934 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 41935 unix_path=`$CYGPATH -u "$windows_path"` 41936 new_path="$unix_path" 41937 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 41938 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 41939 new_path="$unix_path" 41940 fi 41941 41942 # remove trailing .exe if any 41943 new_path="${new_path/%.exe/}" 41944 41945 # Save the first 10 bytes of this path to the storage, so fixpath can work. 41946 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 41947 fi 41948 41949 else 41950 # We're on a unix platform. Hooray! :) 41951 # First separate the path from the arguments. This will split at the first 41952 # space. 41953 complete="$STRIP" 41954 path="${complete%% *}" 41955 tmp="$complete EOL" 41956 arguments="${tmp#* }" 41957 41958 # Cannot rely on the command "which" here since it doesn't always work. 41959 is_absolute_path=`$ECHO "$path" | $GREP ^/` 41960 if test -z "$is_absolute_path"; then 41961 # Path to executable is not absolute. Find it. 41962 IFS_save="$IFS" 41963 IFS=: 41964 for p in $PATH; do 41965 if test -f "$p/$path" && test -x "$p/$path"; then 41966 new_path="$p/$path" 41967 break 41968 fi 41969 done 41970 IFS="$IFS_save" 41971 else 41972 # This is an absolute path, we can use it without further modifications. 41973 new_path="$path" 41974 fi 41975 41976 if test "x$new_path" = x; then 41977 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of STRIP, which resolves as \"$complete\", is not found." >&5 41978 $as_echo "$as_me: The path of STRIP, which resolves as \"$complete\", is not found." >&6;} 41979 has_space=`$ECHO "$complete" | $GREP " "` 41980 if test "x$has_space" != x; then 41981 { $as_echo "$as_me:${as_lineno-$LINENO}: This might be caused by spaces in the path, which is not allowed." >&5 41982 $as_echo "$as_me: This might be caused by spaces in the path, which is not allowed." >&6;} 41983 fi 41984 as_fn_error $? "Cannot locate the the path of STRIP" "$LINENO" 5 41985 fi 41986 fi 41987 41988 # Now join together the path and the arguments once again 41989 if test "x$arguments" != xEOL; then 41990 new_complete="$new_path ${arguments% *}" 41991 else 41992 new_complete="$new_path" 41993 fi 41994 41995 if test "x$complete" != "x$new_complete"; then 41996 STRIP="$new_complete" 41997 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting STRIP to \"$new_complete\"" >&5 41998 $as_echo "$as_me: Rewriting STRIP to \"$new_complete\"" >&6;} 41999 fi 42000 fi 42001 42002 42003 42004 # Publish this variable in the help. 42005 42006 42007 if [ -z "${NM+x}" ]; then 42008 # The variable is not set by user, try to locate tool using the code snippet 42009 for ac_prog in nm 42010 do 42011 # Extract the first word of "$ac_prog", so it can be a program name with args. 42012 set dummy $ac_prog; ac_word=$2 42013 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 42014 $as_echo_n "checking for $ac_word... " >&6; } 42015 if ${ac_cv_path_NM+:} false; then : 42016 $as_echo_n "(cached) " >&6 42017 else 42018 case $NM in 42019 [\\/]* | ?:[\\/]*) 42020 ac_cv_path_NM="$NM" # Let the user override the test with a path. 42021 ;; 42022 *) 42023 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 42024 for as_dir in $PATH 42025 do 42026 IFS=$as_save_IFS 42027 test -z "$as_dir" && as_dir=. 42028 for ac_exec_ext in '' $ac_executable_extensions; do 42029 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 42030 ac_cv_path_NM="$as_dir/$ac_word$ac_exec_ext" 42031 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 42032 break 2 42033 fi 42034 done 42035 done 42036 IFS=$as_save_IFS 42037 42038 ;; 42039 esac 42040 fi 42041 NM=$ac_cv_path_NM 42042 if test -n "$NM"; then 42043 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $NM" >&5 42044 $as_echo "$NM" >&6; } 42045 else 42046 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 42047 $as_echo "no" >&6; } 42048 fi 42049 42050 42051 test -n "$NM" && break 42052 done 42053 42054 else 42055 # The variable is set, but is it from the command line or the environment? 42056 42057 # Try to remove the string !NM! from our list. 42058 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!NM!/} 42059 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 42060 # If it failed, the variable was not from the command line. Ignore it, 42061 # but warn the user (except for BASH, which is always set by the calling BASH). 42062 if test "xNM" != xBASH; then 42063 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of NM from the environment. Use command line variables instead." >&5 42064 $as_echo "$as_me: WARNING: Ignoring value of NM from the environment. Use command line variables instead." >&2;} 42065 fi 42066 # Try to locate tool using the code snippet 42067 for ac_prog in nm 42068 do 42069 # Extract the first word of "$ac_prog", so it can be a program name with args. 42070 set dummy $ac_prog; ac_word=$2 42071 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 42072 $as_echo_n "checking for $ac_word... " >&6; } 42073 if ${ac_cv_path_NM+:} false; then : 42074 $as_echo_n "(cached) " >&6 42075 else 42076 case $NM in 42077 [\\/]* | ?:[\\/]*) 42078 ac_cv_path_NM="$NM" # Let the user override the test with a path. 42079 ;; 42080 *) 42081 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 42082 for as_dir in $PATH 42083 do 42084 IFS=$as_save_IFS 42085 test -z "$as_dir" && as_dir=. 42086 for ac_exec_ext in '' $ac_executable_extensions; do 42087 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 42088 ac_cv_path_NM="$as_dir/$ac_word$ac_exec_ext" 42089 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 42090 break 2 42091 fi 42092 done 42093 done 42094 IFS=$as_save_IFS 42095 42096 ;; 42097 esac 42098 fi 42099 NM=$ac_cv_path_NM 42100 if test -n "$NM"; then 42101 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $NM" >&5 42102 $as_echo "$NM" >&6; } 42103 else 42104 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 42105 $as_echo "no" >&6; } 42106 fi 42107 42108 42109 test -n "$NM" && break 42110 done 42111 42112 else 42113 # If it succeeded, then it was overridden by the user. We will use it 42114 # for the tool. 42115 42116 # First remove it from the list of overridden variables, so we can test 42117 # for unknown variables in the end. 42118 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 42119 42120 # Check if we try to supply an empty value 42121 if test "x$NM" = x; then 42122 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool NM= (no value)" >&5 42123 $as_echo "$as_me: Setting user supplied tool NM= (no value)" >&6;} 42124 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for NM" >&5 42125 $as_echo_n "checking for NM... " >&6; } 42126 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 42127 $as_echo "disabled" >&6; } 42128 else 42129 # Check if the provided tool contains a complete path. 42130 tool_specified="$NM" 42131 tool_basename="${tool_specified##*/}" 42132 if test "x$tool_basename" = "x$tool_specified"; then 42133 # A command without a complete path is provided, search $PATH. 42134 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool NM=$tool_basename" >&5 42135 $as_echo "$as_me: Will search for user supplied tool NM=$tool_basename" >&6;} 42136 # Extract the first word of "$tool_basename", so it can be a program name with args. 42137 set dummy $tool_basename; ac_word=$2 42138 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 42139 $as_echo_n "checking for $ac_word... " >&6; } 42140 if ${ac_cv_path_NM+:} false; then : 42141 $as_echo_n "(cached) " >&6 42142 else 42143 case $NM in 42144 [\\/]* | ?:[\\/]*) 42145 ac_cv_path_NM="$NM" # Let the user override the test with a path. 42146 ;; 42147 *) 42148 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 42149 for as_dir in $PATH 42150 do 42151 IFS=$as_save_IFS 42152 test -z "$as_dir" && as_dir=. 42153 for ac_exec_ext in '' $ac_executable_extensions; do 42154 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 42155 ac_cv_path_NM="$as_dir/$ac_word$ac_exec_ext" 42156 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 42157 break 2 42158 fi 42159 done 42160 done 42161 IFS=$as_save_IFS 42162 42163 ;; 42164 esac 42165 fi 42166 NM=$ac_cv_path_NM 42167 if test -n "$NM"; then 42168 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $NM" >&5 42169 $as_echo "$NM" >&6; } 42170 else 42171 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 42172 $as_echo "no" >&6; } 42173 fi 42174 42175 42176 if test "x$NM" = x; then 42177 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 42178 fi 42179 else 42180 # Otherwise we believe it is a complete path. Use it as it is. 42181 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool NM=$tool_specified" >&5 42182 $as_echo "$as_me: Will use user supplied tool NM=$tool_specified" >&6;} 42183 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for NM" >&5 42184 $as_echo_n "checking for NM... " >&6; } 42185 if test ! -x "$tool_specified"; then 42186 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 42187 $as_echo "not found" >&6; } 42188 as_fn_error $? "User supplied tool NM=$tool_specified does not exist or is not executable" "$LINENO" 5 42189 fi 42190 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 42191 $as_echo "$tool_specified" >&6; } 42192 fi 42193 fi 42194 fi 42195 42196 fi 42197 42198 42199 42200 # Only process if variable expands to non-empty 42201 42202 if test "x$NM" != x; then 42203 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 42204 42205 # First separate the path from the arguments. This will split at the first 42206 # space. 42207 complete="$NM" 42208 path="${complete%% *}" 42209 tmp="$complete EOL" 42210 arguments="${tmp#* }" 42211 42212 # Input might be given as Windows format, start by converting to 42213 # unix format. 42214 new_path=`$CYGPATH -u "$path"` 42215 42216 # Now try to locate executable using which 42217 new_path=`$WHICH "$new_path" 2> /dev/null` 42218 # bat and cmd files are not always considered executable in cygwin causing which 42219 # to not find them 42220 if test "x$new_path" = x \ 42221 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 42222 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 42223 new_path=`$CYGPATH -u "$path"` 42224 fi 42225 if test "x$new_path" = x; then 42226 # Oops. Which didn't find the executable. 42227 # The splitting of arguments from the executable at a space might have been incorrect, 42228 # since paths with space are more likely in Windows. Give it another try with the whole 42229 # argument. 42230 path="$complete" 42231 arguments="EOL" 42232 new_path=`$CYGPATH -u "$path"` 42233 new_path=`$WHICH "$new_path" 2> /dev/null` 42234 # bat and cmd files are not always considered executable in cygwin causing which 42235 # to not find them 42236 if test "x$new_path" = x \ 42237 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 42238 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 42239 new_path=`$CYGPATH -u "$path"` 42240 fi 42241 if test "x$new_path" = x; then 42242 # It's still not found. Now this is an unrecoverable error. 42243 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of NM, which resolves as \"$complete\", is not found." >&5 42244 $as_echo "$as_me: The path of NM, which resolves as \"$complete\", is not found." >&6;} 42245 has_space=`$ECHO "$complete" | $GREP " "` 42246 if test "x$has_space" != x; then 42247 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 42248 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 42249 fi 42250 as_fn_error $? "Cannot locate the the path of NM" "$LINENO" 5 42251 fi 42252 fi 42253 42254 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 42255 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 42256 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 42257 # "foo.exe" is OK but "foo" is an error. 42258 # 42259 # This test is therefore slightly more accurate than "test -f" to check for file presence. 42260 # It is also a way to make sure we got the proper file name for the real test later on. 42261 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 42262 if test "x$test_shortpath" = x; then 42263 # Short path failed, file does not exist as specified. 42264 # Try adding .exe or .cmd 42265 if test -f "${new_path}.exe"; then 42266 input_to_shortpath="${new_path}.exe" 42267 elif test -f "${new_path}.cmd"; then 42268 input_to_shortpath="${new_path}.cmd" 42269 else 42270 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of NM, which resolves as \"$new_path\", is invalid." >&5 42271 $as_echo "$as_me: The path of NM, which resolves as \"$new_path\", is invalid." >&6;} 42272 { $as_echo "$as_me:${as_lineno-$LINENO}: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&5 42273 $as_echo "$as_me: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&6;} 42274 as_fn_error $? "Cannot locate the the path of NM" "$LINENO" 5 42275 fi 42276 else 42277 input_to_shortpath="$new_path" 42278 fi 42279 42280 # Call helper function which possibly converts this using DOS-style short mode. 42281 # If so, the updated path is stored in $new_path. 42282 new_path="$input_to_shortpath" 42283 42284 input_path="$input_to_shortpath" 42285 # Check if we need to convert this using DOS-style short mode. If the path 42286 # contains just simple characters, use it. Otherwise (spaces, weird characters), 42287 # take no chances and rewrite it. 42288 # Note: m4 eats our [], so we need to use [ and ] instead. 42289 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 42290 if test "x$has_forbidden_chars" != x; then 42291 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 42292 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 42293 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 42294 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 42295 # Going to short mode and back again did indeed matter. Since short mode is 42296 # case insensitive, let's make it lowercase to improve readability. 42297 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 42298 # Now convert it back to Unix-style (cygpath) 42299 input_path=`$CYGPATH -u "$shortmode_path"` 42300 new_path="$input_path" 42301 fi 42302 fi 42303 42304 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 42305 if test "x$test_cygdrive_prefix" = x; then 42306 # As a simple fix, exclude /usr/bin since it's not a real path. 42307 if test "x`$ECHO $input_to_shortpath | $GREP ^/usr/bin/`" = x; then 42308 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 42309 # a path prefixed by /cygdrive for fixpath to work. 42310 new_path="$CYGWIN_ROOT_PATH$input_path" 42311 fi 42312 fi 42313 42314 # remove trailing .exe if any 42315 new_path="${new_path/%.exe/}" 42316 42317 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 42318 42319 # First separate the path from the arguments. This will split at the first 42320 # space. 42321 complete="$NM" 42322 path="${complete%% *}" 42323 tmp="$complete EOL" 42324 arguments="${tmp#* }" 42325 42326 # Input might be given as Windows format, start by converting to 42327 # unix format. 42328 new_path="$path" 42329 42330 windows_path="$new_path" 42331 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 42332 unix_path=`$CYGPATH -u "$windows_path"` 42333 new_path="$unix_path" 42334 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 42335 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 42336 new_path="$unix_path" 42337 fi 42338 42339 42340 # Now try to locate executable using which 42341 new_path=`$WHICH "$new_path" 2> /dev/null` 42342 42343 if test "x$new_path" = x; then 42344 # Oops. Which didn't find the executable. 42345 # The splitting of arguments from the executable at a space might have been incorrect, 42346 # since paths with space are more likely in Windows. Give it another try with the whole 42347 # argument. 42348 path="$complete" 42349 arguments="EOL" 42350 new_path="$path" 42351 42352 windows_path="$new_path" 42353 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 42354 unix_path=`$CYGPATH -u "$windows_path"` 42355 new_path="$unix_path" 42356 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 42357 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 42358 new_path="$unix_path" 42359 fi 42360 42361 42362 new_path=`$WHICH "$new_path" 2> /dev/null` 42363 # bat and cmd files are not always considered executable in MSYS causing which 42364 # to not find them 42365 if test "x$new_path" = x \ 42366 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 42367 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 42368 new_path="$path" 42369 42370 windows_path="$new_path" 42371 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 42372 unix_path=`$CYGPATH -u "$windows_path"` 42373 new_path="$unix_path" 42374 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 42375 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 42376 new_path="$unix_path" 42377 fi 42378 42379 fi 42380 42381 if test "x$new_path" = x; then 42382 # It's still not found. Now this is an unrecoverable error. 42383 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of NM, which resolves as \"$complete\", is not found." >&5 42384 $as_echo "$as_me: The path of NM, which resolves as \"$complete\", is not found." >&6;} 42385 has_space=`$ECHO "$complete" | $GREP " "` 42386 if test "x$has_space" != x; then 42387 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 42388 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 42389 fi 42390 as_fn_error $? "Cannot locate the the path of NM" "$LINENO" 5 42391 fi 42392 fi 42393 42394 # Now new_path has a complete unix path to the binary 42395 if test "x`$ECHO $new_path | $GREP ^/bin/`" != x; then 42396 # Keep paths in /bin as-is, but remove trailing .exe if any 42397 new_path="${new_path/%.exe/}" 42398 # Do not save /bin paths to all_fixpath_prefixes! 42399 else 42400 # Not in mixed or Windows style, start by that. 42401 new_path=`cmd //c echo $new_path` 42402 42403 input_path="$new_path" 42404 # Check if we need to convert this using DOS-style short mode. If the path 42405 # contains just simple characters, use it. Otherwise (spaces, weird characters), 42406 # take no chances and rewrite it. 42407 # Note: m4 eats our [], so we need to use [ and ] instead. 42408 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 42409 if test "x$has_forbidden_chars" != x; then 42410 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 42411 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 42412 fi 42413 42414 # Output is in $new_path 42415 42416 windows_path="$new_path" 42417 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 42418 unix_path=`$CYGPATH -u "$windows_path"` 42419 new_path="$unix_path" 42420 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 42421 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 42422 new_path="$unix_path" 42423 fi 42424 42425 # remove trailing .exe if any 42426 new_path="${new_path/%.exe/}" 42427 42428 # Save the first 10 bytes of this path to the storage, so fixpath can work. 42429 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 42430 fi 42431 42432 else 42433 # We're on a unix platform. Hooray! :) 42434 # First separate the path from the arguments. This will split at the first 42435 # space. 42436 complete="$NM" 42437 path="${complete%% *}" 42438 tmp="$complete EOL" 42439 arguments="${tmp#* }" 42440 42441 # Cannot rely on the command "which" here since it doesn't always work. 42442 is_absolute_path=`$ECHO "$path" | $GREP ^/` 42443 if test -z "$is_absolute_path"; then 42444 # Path to executable is not absolute. Find it. 42445 IFS_save="$IFS" 42446 IFS=: 42447 for p in $PATH; do 42448 if test -f "$p/$path" && test -x "$p/$path"; then 42449 new_path="$p/$path" 42450 break 42451 fi 42452 done 42453 IFS="$IFS_save" 42454 else 42455 # This is an absolute path, we can use it without further modifications. 42456 new_path="$path" 42457 fi 42458 42459 if test "x$new_path" = x; then 42460 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of NM, which resolves as \"$complete\", is not found." >&5 42461 $as_echo "$as_me: The path of NM, which resolves as \"$complete\", is not found." >&6;} 42462 has_space=`$ECHO "$complete" | $GREP " "` 42463 if test "x$has_space" != x; then 42464 { $as_echo "$as_me:${as_lineno-$LINENO}: This might be caused by spaces in the path, which is not allowed." >&5 42465 $as_echo "$as_me: This might be caused by spaces in the path, which is not allowed." >&6;} 42466 fi 42467 as_fn_error $? "Cannot locate the the path of NM" "$LINENO" 5 42468 fi 42469 fi 42470 42471 # Now join together the path and the arguments once again 42472 if test "x$arguments" != xEOL; then 42473 new_complete="$new_path ${arguments% *}" 42474 else 42475 new_complete="$new_path" 42476 fi 42477 42478 if test "x$complete" != "x$new_complete"; then 42479 NM="$new_complete" 42480 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting NM to \"$new_complete\"" >&5 42481 $as_echo "$as_me: Rewriting NM to \"$new_complete\"" >&6;} 42482 fi 42483 fi 42484 42485 42486 42487 # Publish this variable in the help. 42488 42489 42490 if [ -z "${GNM+x}" ]; then 42491 # The variable is not set by user, try to locate tool using the code snippet 42492 for ac_prog in gnm 42493 do 42494 # Extract the first word of "$ac_prog", so it can be a program name with args. 42495 set dummy $ac_prog; ac_word=$2 42496 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 42497 $as_echo_n "checking for $ac_word... " >&6; } 42498 if ${ac_cv_path_GNM+:} false; then : 42499 $as_echo_n "(cached) " >&6 42500 else 42501 case $GNM in 42502 [\\/]* | ?:[\\/]*) 42503 ac_cv_path_GNM="$GNM" # Let the user override the test with a path. 42504 ;; 42505 *) 42506 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 42507 for as_dir in $PATH 42508 do 42509 IFS=$as_save_IFS 42510 test -z "$as_dir" && as_dir=. 42511 for ac_exec_ext in '' $ac_executable_extensions; do 42512 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 42513 ac_cv_path_GNM="$as_dir/$ac_word$ac_exec_ext" 42514 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 42515 break 2 42516 fi 42517 done 42518 done 42519 IFS=$as_save_IFS 42520 42521 ;; 42522 esac 42523 fi 42524 GNM=$ac_cv_path_GNM 42525 if test -n "$GNM"; then 42526 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $GNM" >&5 42527 $as_echo "$GNM" >&6; } 42528 else 42529 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 42530 $as_echo "no" >&6; } 42531 fi 42532 42533 42534 test -n "$GNM" && break 42535 done 42536 42537 else 42538 # The variable is set, but is it from the command line or the environment? 42539 42540 # Try to remove the string !GNM! from our list. 42541 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!GNM!/} 42542 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 42543 # If it failed, the variable was not from the command line. Ignore it, 42544 # but warn the user (except for BASH, which is always set by the calling BASH). 42545 if test "xGNM" != xBASH; then 42546 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of GNM from the environment. Use command line variables instead." >&5 42547 $as_echo "$as_me: WARNING: Ignoring value of GNM from the environment. Use command line variables instead." >&2;} 42548 fi 42549 # Try to locate tool using the code snippet 42550 for ac_prog in gnm 42551 do 42552 # Extract the first word of "$ac_prog", so it can be a program name with args. 42553 set dummy $ac_prog; ac_word=$2 42554 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 42555 $as_echo_n "checking for $ac_word... " >&6; } 42556 if ${ac_cv_path_GNM+:} false; then : 42557 $as_echo_n "(cached) " >&6 42558 else 42559 case $GNM in 42560 [\\/]* | ?:[\\/]*) 42561 ac_cv_path_GNM="$GNM" # Let the user override the test with a path. 42562 ;; 42563 *) 42564 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 42565 for as_dir in $PATH 42566 do 42567 IFS=$as_save_IFS 42568 test -z "$as_dir" && as_dir=. 42569 for ac_exec_ext in '' $ac_executable_extensions; do 42570 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 42571 ac_cv_path_GNM="$as_dir/$ac_word$ac_exec_ext" 42572 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 42573 break 2 42574 fi 42575 done 42576 done 42577 IFS=$as_save_IFS 42578 42579 ;; 42580 esac 42581 fi 42582 GNM=$ac_cv_path_GNM 42583 if test -n "$GNM"; then 42584 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $GNM" >&5 42585 $as_echo "$GNM" >&6; } 42586 else 42587 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 42588 $as_echo "no" >&6; } 42589 fi 42590 42591 42592 test -n "$GNM" && break 42593 done 42594 42595 else 42596 # If it succeeded, then it was overridden by the user. We will use it 42597 # for the tool. 42598 42599 # First remove it from the list of overridden variables, so we can test 42600 # for unknown variables in the end. 42601 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 42602 42603 # Check if we try to supply an empty value 42604 if test "x$GNM" = x; then 42605 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool GNM= (no value)" >&5 42606 $as_echo "$as_me: Setting user supplied tool GNM= (no value)" >&6;} 42607 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for GNM" >&5 42608 $as_echo_n "checking for GNM... " >&6; } 42609 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 42610 $as_echo "disabled" >&6; } 42611 else 42612 # Check if the provided tool contains a complete path. 42613 tool_specified="$GNM" 42614 tool_basename="${tool_specified##*/}" 42615 if test "x$tool_basename" = "x$tool_specified"; then 42616 # A command without a complete path is provided, search $PATH. 42617 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool GNM=$tool_basename" >&5 42618 $as_echo "$as_me: Will search for user supplied tool GNM=$tool_basename" >&6;} 42619 # Extract the first word of "$tool_basename", so it can be a program name with args. 42620 set dummy $tool_basename; ac_word=$2 42621 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 42622 $as_echo_n "checking for $ac_word... " >&6; } 42623 if ${ac_cv_path_GNM+:} false; then : 42624 $as_echo_n "(cached) " >&6 42625 else 42626 case $GNM in 42627 [\\/]* | ?:[\\/]*) 42628 ac_cv_path_GNM="$GNM" # Let the user override the test with a path. 42629 ;; 42630 *) 42631 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 42632 for as_dir in $PATH 42633 do 42634 IFS=$as_save_IFS 42635 test -z "$as_dir" && as_dir=. 42636 for ac_exec_ext in '' $ac_executable_extensions; do 42637 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 42638 ac_cv_path_GNM="$as_dir/$ac_word$ac_exec_ext" 42639 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 42640 break 2 42641 fi 42642 done 42643 done 42644 IFS=$as_save_IFS 42645 42646 ;; 42647 esac 42648 fi 42649 GNM=$ac_cv_path_GNM 42650 if test -n "$GNM"; then 42651 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $GNM" >&5 42652 $as_echo "$GNM" >&6; } 42653 else 42654 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 42655 $as_echo "no" >&6; } 42656 fi 42657 42658 42659 if test "x$GNM" = x; then 42660 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 42661 fi 42662 else 42663 # Otherwise we believe it is a complete path. Use it as it is. 42664 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool GNM=$tool_specified" >&5 42665 $as_echo "$as_me: Will use user supplied tool GNM=$tool_specified" >&6;} 42666 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for GNM" >&5 42667 $as_echo_n "checking for GNM... " >&6; } 42668 if test ! -x "$tool_specified"; then 42669 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 42670 $as_echo "not found" >&6; } 42671 as_fn_error $? "User supplied tool GNM=$tool_specified does not exist or is not executable" "$LINENO" 5 42672 fi 42673 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 42674 $as_echo "$tool_specified" >&6; } 42675 fi 42676 fi 42677 fi 42678 42679 fi 42680 42681 42682 42683 # Only process if variable expands to non-empty 42684 42685 if test "x$GNM" != x; then 42686 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 42687 42688 # First separate the path from the arguments. This will split at the first 42689 # space. 42690 complete="$GNM" 42691 path="${complete%% *}" 42692 tmp="$complete EOL" 42693 arguments="${tmp#* }" 42694 42695 # Input might be given as Windows format, start by converting to 42696 # unix format. 42697 new_path=`$CYGPATH -u "$path"` 42698 42699 # Now try to locate executable using which 42700 new_path=`$WHICH "$new_path" 2> /dev/null` 42701 # bat and cmd files are not always considered executable in cygwin causing which 42702 # to not find them 42703 if test "x$new_path" = x \ 42704 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 42705 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 42706 new_path=`$CYGPATH -u "$path"` 42707 fi 42708 if test "x$new_path" = x; then 42709 # Oops. Which didn't find the executable. 42710 # The splitting of arguments from the executable at a space might have been incorrect, 42711 # since paths with space are more likely in Windows. Give it another try with the whole 42712 # argument. 42713 path="$complete" 42714 arguments="EOL" 42715 new_path=`$CYGPATH -u "$path"` 42716 new_path=`$WHICH "$new_path" 2> /dev/null` 42717 # bat and cmd files are not always considered executable in cygwin causing which 42718 # to not find them 42719 if test "x$new_path" = x \ 42720 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 42721 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 42722 new_path=`$CYGPATH -u "$path"` 42723 fi 42724 if test "x$new_path" = x; then 42725 # It's still not found. Now this is an unrecoverable error. 42726 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of GNM, which resolves as \"$complete\", is not found." >&5 42727 $as_echo "$as_me: The path of GNM, which resolves as \"$complete\", is not found." >&6;} 42728 has_space=`$ECHO "$complete" | $GREP " "` 42729 if test "x$has_space" != x; then 42730 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 42731 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 42732 fi 42733 as_fn_error $? "Cannot locate the the path of GNM" "$LINENO" 5 42734 fi 42735 fi 42736 42737 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 42738 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 42739 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 42740 # "foo.exe" is OK but "foo" is an error. 42741 # 42742 # This test is therefore slightly more accurate than "test -f" to check for file presence. 42743 # It is also a way to make sure we got the proper file name for the real test later on. 42744 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 42745 if test "x$test_shortpath" = x; then 42746 # Short path failed, file does not exist as specified. 42747 # Try adding .exe or .cmd 42748 if test -f "${new_path}.exe"; then 42749 input_to_shortpath="${new_path}.exe" 42750 elif test -f "${new_path}.cmd"; then 42751 input_to_shortpath="${new_path}.cmd" 42752 else 42753 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of GNM, which resolves as \"$new_path\", is invalid." >&5 42754 $as_echo "$as_me: The path of GNM, which resolves as \"$new_path\", is invalid." >&6;} 42755 { $as_echo "$as_me:${as_lineno-$LINENO}: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&5 42756 $as_echo "$as_me: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&6;} 42757 as_fn_error $? "Cannot locate the the path of GNM" "$LINENO" 5 42758 fi 42759 else 42760 input_to_shortpath="$new_path" 42761 fi 42762 42763 # Call helper function which possibly converts this using DOS-style short mode. 42764 # If so, the updated path is stored in $new_path. 42765 new_path="$input_to_shortpath" 42766 42767 input_path="$input_to_shortpath" 42768 # Check if we need to convert this using DOS-style short mode. If the path 42769 # contains just simple characters, use it. Otherwise (spaces, weird characters), 42770 # take no chances and rewrite it. 42771 # Note: m4 eats our [], so we need to use [ and ] instead. 42772 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 42773 if test "x$has_forbidden_chars" != x; then 42774 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 42775 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 42776 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 42777 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 42778 # Going to short mode and back again did indeed matter. Since short mode is 42779 # case insensitive, let's make it lowercase to improve readability. 42780 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 42781 # Now convert it back to Unix-style (cygpath) 42782 input_path=`$CYGPATH -u "$shortmode_path"` 42783 new_path="$input_path" 42784 fi 42785 fi 42786 42787 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 42788 if test "x$test_cygdrive_prefix" = x; then 42789 # As a simple fix, exclude /usr/bin since it's not a real path. 42790 if test "x`$ECHO $input_to_shortpath | $GREP ^/usr/bin/`" = x; then 42791 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 42792 # a path prefixed by /cygdrive for fixpath to work. 42793 new_path="$CYGWIN_ROOT_PATH$input_path" 42794 fi 42795 fi 42796 42797 # remove trailing .exe if any 42798 new_path="${new_path/%.exe/}" 42799 42800 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 42801 42802 # First separate the path from the arguments. This will split at the first 42803 # space. 42804 complete="$GNM" 42805 path="${complete%% *}" 42806 tmp="$complete EOL" 42807 arguments="${tmp#* }" 42808 42809 # Input might be given as Windows format, start by converting to 42810 # unix format. 42811 new_path="$path" 42812 42813 windows_path="$new_path" 42814 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 42815 unix_path=`$CYGPATH -u "$windows_path"` 42816 new_path="$unix_path" 42817 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 42818 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 42819 new_path="$unix_path" 42820 fi 42821 42822 42823 # Now try to locate executable using which 42824 new_path=`$WHICH "$new_path" 2> /dev/null` 42825 42826 if test "x$new_path" = x; then 42827 # Oops. Which didn't find the executable. 42828 # The splitting of arguments from the executable at a space might have been incorrect, 42829 # since paths with space are more likely in Windows. Give it another try with the whole 42830 # argument. 42831 path="$complete" 42832 arguments="EOL" 42833 new_path="$path" 42834 42835 windows_path="$new_path" 42836 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 42837 unix_path=`$CYGPATH -u "$windows_path"` 42838 new_path="$unix_path" 42839 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 42840 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 42841 new_path="$unix_path" 42842 fi 42843 42844 42845 new_path=`$WHICH "$new_path" 2> /dev/null` 42846 # bat and cmd files are not always considered executable in MSYS causing which 42847 # to not find them 42848 if test "x$new_path" = x \ 42849 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 42850 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 42851 new_path="$path" 42852 42853 windows_path="$new_path" 42854 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 42855 unix_path=`$CYGPATH -u "$windows_path"` 42856 new_path="$unix_path" 42857 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 42858 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 42859 new_path="$unix_path" 42860 fi 42861 42862 fi 42863 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 GNM, which resolves as \"$complete\", is not found." >&5 42867 $as_echo "$as_me: The path of GNM, 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 GNM" "$LINENO" 5 42874 fi 42875 fi 42876 42877 # Now new_path has a complete unix path to the binary 42878 if test "x`$ECHO $new_path | $GREP ^/bin/`" != x; then 42879 # Keep paths in /bin as-is, but remove trailing .exe if any 42880 new_path="${new_path/%.exe/}" 42881 # Do not save /bin paths to all_fixpath_prefixes! 42882 else 42883 # Not in mixed or Windows style, start by that. 42884 new_path=`cmd //c echo $new_path` 42885 42886 input_path="$new_path" 42887 # Check if we need to convert this using DOS-style short mode. If the path 42888 # contains just simple characters, use it. Otherwise (spaces, weird characters), 42889 # take no chances and rewrite it. 42890 # Note: m4 eats our [], so we need to use [ and ] instead. 42891 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 42892 if test "x$has_forbidden_chars" != x; then 42893 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 42894 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 42895 fi 42896 42897 # Output is in $new_path 42898 42899 windows_path="$new_path" 42900 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 42901 unix_path=`$CYGPATH -u "$windows_path"` 42902 new_path="$unix_path" 42903 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 42904 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 42905 new_path="$unix_path" 42906 fi 42907 42908 # remove trailing .exe if any 42909 new_path="${new_path/%.exe/}" 42910 42911 # Save the first 10 bytes of this path to the storage, so fixpath can work. 42912 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 42913 fi 42914 42915 else 42916 # We're on a unix platform. Hooray! :) 42917 # First separate the path from the arguments. This will split at the first 42918 # space. 42919 complete="$GNM" 42920 path="${complete%% *}" 42921 tmp="$complete EOL" 42922 arguments="${tmp#* }" 42923 42924 # Cannot rely on the command "which" here since it doesn't always work. 42925 is_absolute_path=`$ECHO "$path" | $GREP ^/` 42926 if test -z "$is_absolute_path"; then 42927 # Path to executable is not absolute. Find it. 42928 IFS_save="$IFS" 42929 IFS=: 42930 for p in $PATH; do 42931 if test -f "$p/$path" && test -x "$p/$path"; then 42932 new_path="$p/$path" 42933 break 42934 fi 42935 done 42936 IFS="$IFS_save" 42937 else 42938 # This is an absolute path, we can use it without further modifications. 42939 new_path="$path" 42940 fi 42941 42942 if test "x$new_path" = x; then 42943 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of GNM, which resolves as \"$complete\", is not found." >&5 42944 $as_echo "$as_me: The path of GNM, which resolves as \"$complete\", is not found." >&6;} 42945 has_space=`$ECHO "$complete" | $GREP " "` 42946 if test "x$has_space" != x; then 42947 { $as_echo "$as_me:${as_lineno-$LINENO}: This might be caused by spaces in the path, which is not allowed." >&5 42948 $as_echo "$as_me: This might be caused by spaces in the path, which is not allowed." >&6;} 42949 fi 42950 as_fn_error $? "Cannot locate the the path of GNM" "$LINENO" 5 42951 fi 42952 fi 42953 42954 # Now join together the path and the arguments once again 42955 if test "x$arguments" != xEOL; then 42956 new_complete="$new_path ${arguments% *}" 42957 else 42958 new_complete="$new_path" 42959 fi 42960 42961 if test "x$complete" != "x$new_complete"; then 42962 GNM="$new_complete" 42963 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting GNM to \"$new_complete\"" >&5 42964 $as_echo "$as_me: Rewriting GNM to \"$new_complete\"" >&6;} 42965 fi 42966 fi 42967 42968 elif test "x$OPENJDK_TARGET_OS" != xwindows; then 42969 # FIXME: we should unify this with the solaris case above. 42970 42971 42972 # Publish this variable in the help. 42973 42974 42975 if [ -z "${STRIP+x}" ]; then 42976 # The variable is not set by user, try to locate tool using the code snippet 42977 if test -n "$ac_tool_prefix"; then 42978 for ac_prog in strip 42979 do 42980 # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args. 42981 set dummy $ac_tool_prefix$ac_prog; ac_word=$2 42982 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 42983 $as_echo_n "checking for $ac_word... " >&6; } 42984 if ${ac_cv_prog_STRIP+:} false; then : 42985 $as_echo_n "(cached) " >&6 42986 else 42987 if test -n "$STRIP"; then 42988 ac_cv_prog_STRIP="$STRIP" # Let the user override the test. 42989 else 42990 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 42991 for as_dir in $PATH 42992 do 42993 IFS=$as_save_IFS 42994 test -z "$as_dir" && as_dir=. 42995 for ac_exec_ext in '' $ac_executable_extensions; do 42996 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 42997 ac_cv_prog_STRIP="$ac_tool_prefix$ac_prog" 42998 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 42999 break 2 43000 fi 43001 done 43002 done 43003 IFS=$as_save_IFS 43004 43005 fi 43006 fi 43007 STRIP=$ac_cv_prog_STRIP 43008 if test -n "$STRIP"; then 43009 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $STRIP" >&5 43010 $as_echo "$STRIP" >&6; } 43011 else 43012 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 43013 $as_echo "no" >&6; } 43014 fi 43015 43016 43017 test -n "$STRIP" && break 43018 done 43019 fi 43020 if test -z "$STRIP"; then 43021 ac_ct_STRIP=$STRIP 43022 for ac_prog in strip 43023 do 43024 # Extract the first word of "$ac_prog", so it can be a program name with args. 43025 set dummy $ac_prog; ac_word=$2 43026 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 43027 $as_echo_n "checking for $ac_word... " >&6; } 43028 if ${ac_cv_prog_ac_ct_STRIP+:} false; then : 43029 $as_echo_n "(cached) " >&6 43030 else 43031 if test -n "$ac_ct_STRIP"; then 43032 ac_cv_prog_ac_ct_STRIP="$ac_ct_STRIP" # Let the user override the test. 43033 else 43034 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 43035 for as_dir in $PATH 43036 do 43037 IFS=$as_save_IFS 43038 test -z "$as_dir" && as_dir=. 43039 for ac_exec_ext in '' $ac_executable_extensions; do 43040 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 43041 ac_cv_prog_ac_ct_STRIP="$ac_prog" 43042 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 43043 break 2 43044 fi 43045 done 43046 done 43047 IFS=$as_save_IFS 43048 43049 fi 43050 fi 43051 ac_ct_STRIP=$ac_cv_prog_ac_ct_STRIP 43052 if test -n "$ac_ct_STRIP"; then 43053 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_STRIP" >&5 43054 $as_echo "$ac_ct_STRIP" >&6; } 43055 else 43056 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 43057 $as_echo "no" >&6; } 43058 fi 43059 43060 43061 test -n "$ac_ct_STRIP" && break 43062 done 43063 43064 if test "x$ac_ct_STRIP" = x; then 43065 STRIP="" 43066 else 43067 case $cross_compiling:$ac_tool_warned in 43068 yes:) 43069 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5 43070 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;} 43071 ac_tool_warned=yes ;; 43072 esac 43073 STRIP=$ac_ct_STRIP 43074 fi 43075 fi 43076 43077 else 43078 # The variable is set, but is it from the command line or the environment? 43079 43080 # Try to remove the string !STRIP! from our list. 43081 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!STRIP!/} 43082 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 43083 # If it failed, the variable was not from the command line. Ignore it, 43084 # but warn the user (except for BASH, which is always set by the calling BASH). 43085 if test "xSTRIP" != xBASH; then 43086 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of STRIP from the environment. Use command line variables instead." >&5 43087 $as_echo "$as_me: WARNING: Ignoring value of STRIP from the environment. Use command line variables instead." >&2;} 43088 fi 43089 # Try to locate tool using the code snippet 43090 if test -n "$ac_tool_prefix"; then 43091 for ac_prog in strip 43092 do 43093 # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args. 43094 set dummy $ac_tool_prefix$ac_prog; ac_word=$2 43095 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 43096 $as_echo_n "checking for $ac_word... " >&6; } 43097 if ${ac_cv_prog_STRIP+:} false; then : 43098 $as_echo_n "(cached) " >&6 43099 else 43100 if test -n "$STRIP"; then 43101 ac_cv_prog_STRIP="$STRIP" # Let the user override the test. 43102 else 43103 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 43104 for as_dir in $PATH 43105 do 43106 IFS=$as_save_IFS 43107 test -z "$as_dir" && as_dir=. 43108 for ac_exec_ext in '' $ac_executable_extensions; do 43109 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 43110 ac_cv_prog_STRIP="$ac_tool_prefix$ac_prog" 43111 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 43112 break 2 43113 fi 43114 done 43115 done 43116 IFS=$as_save_IFS 43117 43118 fi 43119 fi 43120 STRIP=$ac_cv_prog_STRIP 43121 if test -n "$STRIP"; then 43122 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $STRIP" >&5 43123 $as_echo "$STRIP" >&6; } 43124 else 43125 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 43126 $as_echo "no" >&6; } 43127 fi 43128 43129 43130 test -n "$STRIP" && break 43131 done 43132 fi 43133 if test -z "$STRIP"; then 43134 ac_ct_STRIP=$STRIP 43135 for ac_prog in strip 43136 do 43137 # Extract the first word of "$ac_prog", so it can be a program name with args. 43138 set dummy $ac_prog; ac_word=$2 43139 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 43140 $as_echo_n "checking for $ac_word... " >&6; } 43141 if ${ac_cv_prog_ac_ct_STRIP+:} false; then : 43142 $as_echo_n "(cached) " >&6 43143 else 43144 if test -n "$ac_ct_STRIP"; then 43145 ac_cv_prog_ac_ct_STRIP="$ac_ct_STRIP" # Let the user override the test. 43146 else 43147 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 43148 for as_dir in $PATH 43149 do 43150 IFS=$as_save_IFS 43151 test -z "$as_dir" && as_dir=. 43152 for ac_exec_ext in '' $ac_executable_extensions; do 43153 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 43154 ac_cv_prog_ac_ct_STRIP="$ac_prog" 43155 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 43156 break 2 43157 fi 43158 done 43159 done 43160 IFS=$as_save_IFS 43161 43162 fi 43163 fi 43164 ac_ct_STRIP=$ac_cv_prog_ac_ct_STRIP 43165 if test -n "$ac_ct_STRIP"; then 43166 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_STRIP" >&5 43167 $as_echo "$ac_ct_STRIP" >&6; } 43168 else 43169 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 43170 $as_echo "no" >&6; } 43171 fi 43172 43173 43174 test -n "$ac_ct_STRIP" && break 43175 done 43176 43177 if test "x$ac_ct_STRIP" = x; then 43178 STRIP="" 43179 else 43180 case $cross_compiling:$ac_tool_warned in 43181 yes:) 43182 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5 43183 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;} 43184 ac_tool_warned=yes ;; 43185 esac 43186 STRIP=$ac_ct_STRIP 43187 fi 43188 fi 43189 43190 else 43191 # If it succeeded, then it was overridden by the user. We will use it 43192 # for the tool. 43193 43194 # First remove it from the list of overridden variables, so we can test 43195 # for unknown variables in the end. 43196 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 43197 43198 # Check if we try to supply an empty value 43199 if test "x$STRIP" = x; then 43200 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool STRIP= (no value)" >&5 43201 $as_echo "$as_me: Setting user supplied tool STRIP= (no value)" >&6;} 43202 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for STRIP" >&5 43203 $as_echo_n "checking for STRIP... " >&6; } 43204 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 43205 $as_echo "disabled" >&6; } 43206 else 43207 # Check if the provided tool contains a complete path. 43208 tool_specified="$STRIP" 43209 tool_basename="${tool_specified##*/}" 43210 if test "x$tool_basename" = "x$tool_specified"; then 43211 # A command without a complete path is provided, search $PATH. 43212 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool STRIP=$tool_basename" >&5 43213 $as_echo "$as_me: Will search for user supplied tool STRIP=$tool_basename" >&6;} 43214 # Extract the first word of "$tool_basename", so it can be a program name with args. 43215 set dummy $tool_basename; ac_word=$2 43216 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 43217 $as_echo_n "checking for $ac_word... " >&6; } 43218 if ${ac_cv_path_STRIP+:} false; then : 43219 $as_echo_n "(cached) " >&6 43220 else 43221 case $STRIP in 43222 [\\/]* | ?:[\\/]*) 43223 ac_cv_path_STRIP="$STRIP" # Let the user override the test with a path. 43224 ;; 43225 *) 43226 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 43227 for as_dir in $PATH 43228 do 43229 IFS=$as_save_IFS 43230 test -z "$as_dir" && as_dir=. 43231 for ac_exec_ext in '' $ac_executable_extensions; do 43232 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 43233 ac_cv_path_STRIP="$as_dir/$ac_word$ac_exec_ext" 43234 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 43235 break 2 43236 fi 43237 done 43238 done 43239 IFS=$as_save_IFS 43240 43241 ;; 43242 esac 43243 fi 43244 STRIP=$ac_cv_path_STRIP 43245 if test -n "$STRIP"; then 43246 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $STRIP" >&5 43247 $as_echo "$STRIP" >&6; } 43248 else 43249 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 43250 $as_echo "no" >&6; } 43251 fi 43252 43253 43254 if test "x$STRIP" = x; then 43255 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 43256 fi 43257 else 43258 # Otherwise we believe it is a complete path. Use it as it is. 43259 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool STRIP=$tool_specified" >&5 43260 $as_echo "$as_me: Will use user supplied tool STRIP=$tool_specified" >&6;} 43261 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for STRIP" >&5 43262 $as_echo_n "checking for STRIP... " >&6; } 43263 if test ! -x "$tool_specified"; then 43264 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 43265 $as_echo "not found" >&6; } 43266 as_fn_error $? "User supplied tool STRIP=$tool_specified does not exist or is not executable" "$LINENO" 5 43267 fi 43268 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 43269 $as_echo "$tool_specified" >&6; } 43270 fi 43271 fi 43272 fi 43273 43274 fi 43275 43276 43277 43278 # Only process if variable expands to non-empty 43279 43280 if test "x$STRIP" != x; then 43281 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 43282 43283 # First separate the path from the arguments. This will split at the first 43284 # space. 43285 complete="$STRIP" 43286 path="${complete%% *}" 43287 tmp="$complete EOL" 43288 arguments="${tmp#* }" 43289 43290 # Input might be given as Windows format, start by converting to 43291 # unix format. 43292 new_path=`$CYGPATH -u "$path"` 43293 43294 # Now try to locate executable using which 43295 new_path=`$WHICH "$new_path" 2> /dev/null` 43296 # bat and cmd files are not always considered executable in cygwin causing which 43297 # to not find them 43298 if test "x$new_path" = x \ 43299 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 43300 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 43301 new_path=`$CYGPATH -u "$path"` 43302 fi 43303 if test "x$new_path" = x; then 43304 # Oops. Which didn't find the executable. 43305 # The splitting of arguments from the executable at a space might have been incorrect, 43306 # since paths with space are more likely in Windows. Give it another try with the whole 43307 # argument. 43308 path="$complete" 43309 arguments="EOL" 43310 new_path=`$CYGPATH -u "$path"` 43311 new_path=`$WHICH "$new_path" 2> /dev/null` 43312 # bat and cmd files are not always considered executable in cygwin causing which 43313 # to not find them 43314 if test "x$new_path" = x \ 43315 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 43316 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 43317 new_path=`$CYGPATH -u "$path"` 43318 fi 43319 if test "x$new_path" = x; then 43320 # It's still not found. Now this is an unrecoverable error. 43321 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of STRIP, which resolves as \"$complete\", is not found." >&5 43322 $as_echo "$as_me: The path of STRIP, which resolves as \"$complete\", is not found." >&6;} 43323 has_space=`$ECHO "$complete" | $GREP " "` 43324 if test "x$has_space" != x; then 43325 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 43326 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 43327 fi 43328 as_fn_error $? "Cannot locate the the path of STRIP" "$LINENO" 5 43329 fi 43330 fi 43331 43332 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 43333 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 43334 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 43335 # "foo.exe" is OK but "foo" is an error. 43336 # 43337 # This test is therefore slightly more accurate than "test -f" to check for file presence. 43338 # It is also a way to make sure we got the proper file name for the real test later on. 43339 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 43340 if test "x$test_shortpath" = x; then 43341 # Short path failed, file does not exist as specified. 43342 # Try adding .exe or .cmd 43343 if test -f "${new_path}.exe"; then 43344 input_to_shortpath="${new_path}.exe" 43345 elif test -f "${new_path}.cmd"; then 43346 input_to_shortpath="${new_path}.cmd" 43347 else 43348 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of STRIP, which resolves as \"$new_path\", is invalid." >&5 43349 $as_echo "$as_me: The path of STRIP, which resolves as \"$new_path\", is invalid." >&6;} 43350 { $as_echo "$as_me:${as_lineno-$LINENO}: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&5 43351 $as_echo "$as_me: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&6;} 43352 as_fn_error $? "Cannot locate the the path of STRIP" "$LINENO" 5 43353 fi 43354 else 43355 input_to_shortpath="$new_path" 43356 fi 43357 43358 # Call helper function which possibly converts this using DOS-style short mode. 43359 # If so, the updated path is stored in $new_path. 43360 new_path="$input_to_shortpath" 43361 43362 input_path="$input_to_shortpath" 43363 # Check if we need to convert this using DOS-style short mode. If the path 43364 # contains just simple characters, use it. Otherwise (spaces, weird characters), 43365 # take no chances and rewrite it. 43366 # Note: m4 eats our [], so we need to use [ and ] instead. 43367 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 43368 if test "x$has_forbidden_chars" != x; then 43369 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 43370 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 43371 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 43372 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 43373 # Going to short mode and back again did indeed matter. Since short mode is 43374 # case insensitive, let's make it lowercase to improve readability. 43375 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 43376 # Now convert it back to Unix-style (cygpath) 43377 input_path=`$CYGPATH -u "$shortmode_path"` 43378 new_path="$input_path" 43379 fi 43380 fi 43381 43382 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 43383 if test "x$test_cygdrive_prefix" = x; then 43384 # As a simple fix, exclude /usr/bin since it's not a real path. 43385 if test "x`$ECHO $input_to_shortpath | $GREP ^/usr/bin/`" = x; then 43386 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 43387 # a path prefixed by /cygdrive for fixpath to work. 43388 new_path="$CYGWIN_ROOT_PATH$input_path" 43389 fi 43390 fi 43391 43392 # remove trailing .exe if any 43393 new_path="${new_path/%.exe/}" 43394 43395 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 43396 43397 # First separate the path from the arguments. This will split at the first 43398 # space. 43399 complete="$STRIP" 43400 path="${complete%% *}" 43401 tmp="$complete EOL" 43402 arguments="${tmp#* }" 43403 43404 # Input might be given as Windows format, start by converting to 43405 # unix format. 43406 new_path="$path" 43407 43408 windows_path="$new_path" 43409 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 43410 unix_path=`$CYGPATH -u "$windows_path"` 43411 new_path="$unix_path" 43412 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 43413 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 43414 new_path="$unix_path" 43415 fi 43416 43417 43418 # Now try to locate executable using which 43419 new_path=`$WHICH "$new_path" 2> /dev/null` 43420 43421 if test "x$new_path" = x; then 43422 # Oops. Which didn't find the executable. 43423 # The splitting of arguments from the executable at a space might have been incorrect, 43424 # since paths with space are more likely in Windows. Give it another try with the whole 43425 # argument. 43426 path="$complete" 43427 arguments="EOL" 43428 new_path="$path" 43429 43430 windows_path="$new_path" 43431 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 43432 unix_path=`$CYGPATH -u "$windows_path"` 43433 new_path="$unix_path" 43434 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 43435 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 43436 new_path="$unix_path" 43437 fi 43438 43439 43440 new_path=`$WHICH "$new_path" 2> /dev/null` 43441 # bat and cmd files are not always considered executable in MSYS causing which 43442 # to not find them 43443 if test "x$new_path" = x \ 43444 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 43445 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 43446 new_path="$path" 43447 43448 windows_path="$new_path" 43449 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 43450 unix_path=`$CYGPATH -u "$windows_path"` 43451 new_path="$unix_path" 43452 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 43453 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 43454 new_path="$unix_path" 43455 fi 43456 43457 fi 43458 43459 if test "x$new_path" = x; then 43460 # It's still not found. Now this is an unrecoverable error. 43461 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of STRIP, which resolves as \"$complete\", is not found." >&5 43462 $as_echo "$as_me: The path of STRIP, which resolves as \"$complete\", is not found." >&6;} 43463 has_space=`$ECHO "$complete" | $GREP " "` 43464 if test "x$has_space" != x; then 43465 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 43466 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 43467 fi 43468 as_fn_error $? "Cannot locate the the path of STRIP" "$LINENO" 5 43469 fi 43470 fi 43471 43472 # Now new_path has a complete unix path to the binary 43473 if test "x`$ECHO $new_path | $GREP ^/bin/`" != x; then 43474 # Keep paths in /bin as-is, but remove trailing .exe if any 43475 new_path="${new_path/%.exe/}" 43476 # Do not save /bin paths to all_fixpath_prefixes! 43477 else 43478 # Not in mixed or Windows style, start by that. 43479 new_path=`cmd //c echo $new_path` 43480 43481 input_path="$new_path" 43482 # Check if we need to convert this using DOS-style short mode. If the path 43483 # contains just simple characters, use it. Otherwise (spaces, weird characters), 43484 # take no chances and rewrite it. 43485 # Note: m4 eats our [], so we need to use [ and ] instead. 43486 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 43487 if test "x$has_forbidden_chars" != x; then 43488 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 43489 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 43490 fi 43491 43492 # Output is in $new_path 43493 43494 windows_path="$new_path" 43495 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 43496 unix_path=`$CYGPATH -u "$windows_path"` 43497 new_path="$unix_path" 43498 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 43499 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 43500 new_path="$unix_path" 43501 fi 43502 43503 # remove trailing .exe if any 43504 new_path="${new_path/%.exe/}" 43505 43506 # Save the first 10 bytes of this path to the storage, so fixpath can work. 43507 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 43508 fi 43509 43510 else 43511 # We're on a unix platform. Hooray! :) 43512 # First separate the path from the arguments. This will split at the first 43513 # space. 43514 complete="$STRIP" 43515 path="${complete%% *}" 43516 tmp="$complete EOL" 43517 arguments="${tmp#* }" 43518 43519 # Cannot rely on the command "which" here since it doesn't always work. 43520 is_absolute_path=`$ECHO "$path" | $GREP ^/` 43521 if test -z "$is_absolute_path"; then 43522 # Path to executable is not absolute. Find it. 43523 IFS_save="$IFS" 43524 IFS=: 43525 for p in $PATH; do 43526 if test -f "$p/$path" && test -x "$p/$path"; then 43527 new_path="$p/$path" 43528 break 43529 fi 43530 done 43531 IFS="$IFS_save" 43532 else 43533 # This is an absolute path, we can use it without further modifications. 43534 new_path="$path" 43535 fi 43536 43537 if test "x$new_path" = x; then 43538 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of STRIP, which resolves as \"$complete\", is not found." >&5 43539 $as_echo "$as_me: The path of STRIP, which resolves as \"$complete\", is not found." >&6;} 43540 has_space=`$ECHO "$complete" | $GREP " "` 43541 if test "x$has_space" != x; then 43542 { $as_echo "$as_me:${as_lineno-$LINENO}: This might be caused by spaces in the path, which is not allowed." >&5 43543 $as_echo "$as_me: This might be caused by spaces in the path, which is not allowed." >&6;} 43544 fi 43545 as_fn_error $? "Cannot locate the the path of STRIP" "$LINENO" 5 43546 fi 43547 fi 43548 43549 # Now join together the path and the arguments once again 43550 if test "x$arguments" != xEOL; then 43551 new_complete="$new_path ${arguments% *}" 43552 else 43553 new_complete="$new_path" 43554 fi 43555 43556 if test "x$complete" != "x$new_complete"; then 43557 STRIP="$new_complete" 43558 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting STRIP to \"$new_complete\"" >&5 43559 $as_echo "$as_me: Rewriting STRIP to \"$new_complete\"" >&6;} 43560 fi 43561 fi 43562 43563 if test "x$TOOLCHAIN_TYPE" = xgcc; then 43564 43565 43566 # Publish this variable in the help. 43567 43568 43569 if [ -z "${NM+x}" ]; then 43570 # The variable is not set by user, try to locate tool using the code snippet 43571 if test -n "$ac_tool_prefix"; then 43572 for ac_prog in nm gcc-nm 43573 do 43574 # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args. 43575 set dummy $ac_tool_prefix$ac_prog; ac_word=$2 43576 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 43577 $as_echo_n "checking for $ac_word... " >&6; } 43578 if ${ac_cv_prog_NM+:} false; then : 43579 $as_echo_n "(cached) " >&6 43580 else 43581 if test -n "$NM"; then 43582 ac_cv_prog_NM="$NM" # Let the user override the test. 43583 else 43584 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 43585 for as_dir in $PATH 43586 do 43587 IFS=$as_save_IFS 43588 test -z "$as_dir" && as_dir=. 43589 for ac_exec_ext in '' $ac_executable_extensions; do 43590 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 43591 ac_cv_prog_NM="$ac_tool_prefix$ac_prog" 43592 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 43593 break 2 43594 fi 43595 done 43596 done 43597 IFS=$as_save_IFS 43598 43599 fi 43600 fi 43601 NM=$ac_cv_prog_NM 43602 if test -n "$NM"; then 43603 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $NM" >&5 43604 $as_echo "$NM" >&6; } 43605 else 43606 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 43607 $as_echo "no" >&6; } 43608 fi 43609 43610 43611 test -n "$NM" && break 43612 done 43613 fi 43614 if test -z "$NM"; then 43615 ac_ct_NM=$NM 43616 for ac_prog in nm gcc-nm 43617 do 43618 # Extract the first word of "$ac_prog", so it can be a program name with args. 43619 set dummy $ac_prog; ac_word=$2 43620 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 43621 $as_echo_n "checking for $ac_word... " >&6; } 43622 if ${ac_cv_prog_ac_ct_NM+:} false; then : 43623 $as_echo_n "(cached) " >&6 43624 else 43625 if test -n "$ac_ct_NM"; then 43626 ac_cv_prog_ac_ct_NM="$ac_ct_NM" # Let the user override the test. 43627 else 43628 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 43629 for as_dir in $PATH 43630 do 43631 IFS=$as_save_IFS 43632 test -z "$as_dir" && as_dir=. 43633 for ac_exec_ext in '' $ac_executable_extensions; do 43634 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 43635 ac_cv_prog_ac_ct_NM="$ac_prog" 43636 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 43637 break 2 43638 fi 43639 done 43640 done 43641 IFS=$as_save_IFS 43642 43643 fi 43644 fi 43645 ac_ct_NM=$ac_cv_prog_ac_ct_NM 43646 if test -n "$ac_ct_NM"; then 43647 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_NM" >&5 43648 $as_echo "$ac_ct_NM" >&6; } 43649 else 43650 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 43651 $as_echo "no" >&6; } 43652 fi 43653 43654 43655 test -n "$ac_ct_NM" && break 43656 done 43657 43658 if test "x$ac_ct_NM" = x; then 43659 NM="" 43660 else 43661 case $cross_compiling:$ac_tool_warned in 43662 yes:) 43663 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5 43664 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;} 43665 ac_tool_warned=yes ;; 43666 esac 43667 NM=$ac_ct_NM 43668 fi 43669 fi 43670 43671 else 43672 # The variable is set, but is it from the command line or the environment? 43673 43674 # Try to remove the string !NM! from our list. 43675 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!NM!/} 43676 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 43677 # If it failed, the variable was not from the command line. Ignore it, 43678 # but warn the user (except for BASH, which is always set by the calling BASH). 43679 if test "xNM" != xBASH; then 43680 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of NM from the environment. Use command line variables instead." >&5 43681 $as_echo "$as_me: WARNING: Ignoring value of NM from the environment. Use command line variables instead." >&2;} 43682 fi 43683 # Try to locate tool using the code snippet 43684 if test -n "$ac_tool_prefix"; then 43685 for ac_prog in nm gcc-nm 43686 do 43687 # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args. 43688 set dummy $ac_tool_prefix$ac_prog; ac_word=$2 43689 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 43690 $as_echo_n "checking for $ac_word... " >&6; } 43691 if ${ac_cv_prog_NM+:} false; then : 43692 $as_echo_n "(cached) " >&6 43693 else 43694 if test -n "$NM"; then 43695 ac_cv_prog_NM="$NM" # Let the user override the test. 43696 else 43697 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 43698 for as_dir in $PATH 43699 do 43700 IFS=$as_save_IFS 43701 test -z "$as_dir" && as_dir=. 43702 for ac_exec_ext in '' $ac_executable_extensions; do 43703 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 43704 ac_cv_prog_NM="$ac_tool_prefix$ac_prog" 43705 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 43706 break 2 43707 fi 43708 done 43709 done 43710 IFS=$as_save_IFS 43711 43712 fi 43713 fi 43714 NM=$ac_cv_prog_NM 43715 if test -n "$NM"; then 43716 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $NM" >&5 43717 $as_echo "$NM" >&6; } 43718 else 43719 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 43720 $as_echo "no" >&6; } 43721 fi 43722 43723 43724 test -n "$NM" && break 43725 done 43726 fi 43727 if test -z "$NM"; then 43728 ac_ct_NM=$NM 43729 for ac_prog in nm gcc-nm 43730 do 43731 # Extract the first word of "$ac_prog", so it can be a program name with args. 43732 set dummy $ac_prog; ac_word=$2 43733 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 43734 $as_echo_n "checking for $ac_word... " >&6; } 43735 if ${ac_cv_prog_ac_ct_NM+:} false; then : 43736 $as_echo_n "(cached) " >&6 43737 else 43738 if test -n "$ac_ct_NM"; then 43739 ac_cv_prog_ac_ct_NM="$ac_ct_NM" # Let the user override the test. 43740 else 43741 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 43742 for as_dir in $PATH 43743 do 43744 IFS=$as_save_IFS 43745 test -z "$as_dir" && as_dir=. 43746 for ac_exec_ext in '' $ac_executable_extensions; do 43747 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 43748 ac_cv_prog_ac_ct_NM="$ac_prog" 43749 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 43750 break 2 43751 fi 43752 done 43753 done 43754 IFS=$as_save_IFS 43755 43756 fi 43757 fi 43758 ac_ct_NM=$ac_cv_prog_ac_ct_NM 43759 if test -n "$ac_ct_NM"; then 43760 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_NM" >&5 43761 $as_echo "$ac_ct_NM" >&6; } 43762 else 43763 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 43764 $as_echo "no" >&6; } 43765 fi 43766 43767 43768 test -n "$ac_ct_NM" && break 43769 done 43770 43771 if test "x$ac_ct_NM" = x; then 43772 NM="" 43773 else 43774 case $cross_compiling:$ac_tool_warned in 43775 yes:) 43776 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5 43777 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;} 43778 ac_tool_warned=yes ;; 43779 esac 43780 NM=$ac_ct_NM 43781 fi 43782 fi 43783 43784 else 43785 # If it succeeded, then it was overridden by the user. We will use it 43786 # for the tool. 43787 43788 # First remove it from the list of overridden variables, so we can test 43789 # for unknown variables in the end. 43790 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 43791 43792 # Check if we try to supply an empty value 43793 if test "x$NM" = x; then 43794 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool NM= (no value)" >&5 43795 $as_echo "$as_me: Setting user supplied tool NM= (no value)" >&6;} 43796 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for NM" >&5 43797 $as_echo_n "checking for NM... " >&6; } 43798 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 43799 $as_echo "disabled" >&6; } 43800 else 43801 # Check if the provided tool contains a complete path. 43802 tool_specified="$NM" 43803 tool_basename="${tool_specified##*/}" 43804 if test "x$tool_basename" = "x$tool_specified"; then 43805 # A command without a complete path is provided, search $PATH. 43806 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool NM=$tool_basename" >&5 43807 $as_echo "$as_me: Will search for user supplied tool NM=$tool_basename" >&6;} 43808 # Extract the first word of "$tool_basename", so it can be a program name with args. 43809 set dummy $tool_basename; ac_word=$2 43810 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 43811 $as_echo_n "checking for $ac_word... " >&6; } 43812 if ${ac_cv_path_NM+:} false; then : 43813 $as_echo_n "(cached) " >&6 43814 else 43815 case $NM in 43816 [\\/]* | ?:[\\/]*) 43817 ac_cv_path_NM="$NM" # Let the user override the test with a path. 43818 ;; 43819 *) 43820 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 43821 for as_dir in $PATH 43822 do 43823 IFS=$as_save_IFS 43824 test -z "$as_dir" && as_dir=. 43825 for ac_exec_ext in '' $ac_executable_extensions; do 43826 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 43827 ac_cv_path_NM="$as_dir/$ac_word$ac_exec_ext" 43828 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 43829 break 2 43830 fi 43831 done 43832 done 43833 IFS=$as_save_IFS 43834 43835 ;; 43836 esac 43837 fi 43838 NM=$ac_cv_path_NM 43839 if test -n "$NM"; then 43840 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $NM" >&5 43841 $as_echo "$NM" >&6; } 43842 else 43843 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 43844 $as_echo "no" >&6; } 43845 fi 43846 43847 43848 if test "x$NM" = x; then 43849 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 43850 fi 43851 else 43852 # Otherwise we believe it is a complete path. Use it as it is. 43853 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool NM=$tool_specified" >&5 43854 $as_echo "$as_me: Will use user supplied tool NM=$tool_specified" >&6;} 43855 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for NM" >&5 43856 $as_echo_n "checking for NM... " >&6; } 43857 if test ! -x "$tool_specified"; then 43858 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 43859 $as_echo "not found" >&6; } 43860 as_fn_error $? "User supplied tool NM=$tool_specified does not exist or is not executable" "$LINENO" 5 43861 fi 43862 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 43863 $as_echo "$tool_specified" >&6; } 43864 fi 43865 fi 43866 fi 43867 43868 fi 43869 43870 43871 else 43872 43873 43874 # Publish this variable in the help. 43875 43876 43877 if [ -z "${NM+x}" ]; then 43878 # The variable is not set by user, try to locate tool using the code snippet 43879 if test -n "$ac_tool_prefix"; then 43880 for ac_prog in nm 43881 do 43882 # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args. 43883 set dummy $ac_tool_prefix$ac_prog; ac_word=$2 43884 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 43885 $as_echo_n "checking for $ac_word... " >&6; } 43886 if ${ac_cv_prog_NM+:} false; then : 43887 $as_echo_n "(cached) " >&6 43888 else 43889 if test -n "$NM"; then 43890 ac_cv_prog_NM="$NM" # Let the user override the test. 43891 else 43892 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 43893 for as_dir in $PATH 43894 do 43895 IFS=$as_save_IFS 43896 test -z "$as_dir" && as_dir=. 43897 for ac_exec_ext in '' $ac_executable_extensions; do 43898 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 43899 ac_cv_prog_NM="$ac_tool_prefix$ac_prog" 43900 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 43901 break 2 43902 fi 43903 done 43904 done 43905 IFS=$as_save_IFS 43906 43907 fi 43908 fi 43909 NM=$ac_cv_prog_NM 43910 if test -n "$NM"; then 43911 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $NM" >&5 43912 $as_echo "$NM" >&6; } 43913 else 43914 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 43915 $as_echo "no" >&6; } 43916 fi 43917 43918 43919 test -n "$NM" && break 43920 done 43921 fi 43922 if test -z "$NM"; then 43923 ac_ct_NM=$NM 43924 for ac_prog in nm 43925 do 43926 # Extract the first word of "$ac_prog", so it can be a program name with args. 43927 set dummy $ac_prog; ac_word=$2 43928 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 43929 $as_echo_n "checking for $ac_word... " >&6; } 43930 if ${ac_cv_prog_ac_ct_NM+:} false; then : 43931 $as_echo_n "(cached) " >&6 43932 else 43933 if test -n "$ac_ct_NM"; then 43934 ac_cv_prog_ac_ct_NM="$ac_ct_NM" # Let the user override the test. 43935 else 43936 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 43937 for as_dir in $PATH 43938 do 43939 IFS=$as_save_IFS 43940 test -z "$as_dir" && as_dir=. 43941 for ac_exec_ext in '' $ac_executable_extensions; do 43942 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 43943 ac_cv_prog_ac_ct_NM="$ac_prog" 43944 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 43945 break 2 43946 fi 43947 done 43948 done 43949 IFS=$as_save_IFS 43950 43951 fi 43952 fi 43953 ac_ct_NM=$ac_cv_prog_ac_ct_NM 43954 if test -n "$ac_ct_NM"; then 43955 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_NM" >&5 43956 $as_echo "$ac_ct_NM" >&6; } 43957 else 43958 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 43959 $as_echo "no" >&6; } 43960 fi 43961 43962 43963 test -n "$ac_ct_NM" && break 43964 done 43965 43966 if test "x$ac_ct_NM" = x; then 43967 NM="" 43968 else 43969 case $cross_compiling:$ac_tool_warned in 43970 yes:) 43971 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5 43972 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;} 43973 ac_tool_warned=yes ;; 43974 esac 43975 NM=$ac_ct_NM 43976 fi 43977 fi 43978 43979 else 43980 # The variable is set, but is it from the command line or the environment? 43981 43982 # Try to remove the string !NM! from our list. 43983 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!NM!/} 43984 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 43985 # If it failed, the variable was not from the command line. Ignore it, 43986 # but warn the user (except for BASH, which is always set by the calling BASH). 43987 if test "xNM" != xBASH; then 43988 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of NM from the environment. Use command line variables instead." >&5 43989 $as_echo "$as_me: WARNING: Ignoring value of NM from the environment. Use command line variables instead." >&2;} 43990 fi 43991 # Try to locate tool using the code snippet 43992 if test -n "$ac_tool_prefix"; then 43993 for ac_prog in nm 43994 do 43995 # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args. 43996 set dummy $ac_tool_prefix$ac_prog; ac_word=$2 43997 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 43998 $as_echo_n "checking for $ac_word... " >&6; } 43999 if ${ac_cv_prog_NM+:} false; then : 44000 $as_echo_n "(cached) " >&6 44001 else 44002 if test -n "$NM"; then 44003 ac_cv_prog_NM="$NM" # Let the user override the test. 44004 else 44005 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 44006 for as_dir in $PATH 44007 do 44008 IFS=$as_save_IFS 44009 test -z "$as_dir" && as_dir=. 44010 for ac_exec_ext in '' $ac_executable_extensions; do 44011 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 44012 ac_cv_prog_NM="$ac_tool_prefix$ac_prog" 44013 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 44014 break 2 44015 fi 44016 done 44017 done 44018 IFS=$as_save_IFS 44019 44020 fi 44021 fi 44022 NM=$ac_cv_prog_NM 44023 if test -n "$NM"; then 44024 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $NM" >&5 44025 $as_echo "$NM" >&6; } 44026 else 44027 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 44028 $as_echo "no" >&6; } 44029 fi 44030 44031 44032 test -n "$NM" && break 44033 done 44034 fi 44035 if test -z "$NM"; then 44036 ac_ct_NM=$NM 44037 for ac_prog in nm 44038 do 44039 # Extract the first word of "$ac_prog", so it can be a program name with args. 44040 set dummy $ac_prog; ac_word=$2 44041 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 44042 $as_echo_n "checking for $ac_word... " >&6; } 44043 if ${ac_cv_prog_ac_ct_NM+:} false; then : 44044 $as_echo_n "(cached) " >&6 44045 else 44046 if test -n "$ac_ct_NM"; then 44047 ac_cv_prog_ac_ct_NM="$ac_ct_NM" # Let the user override the test. 44048 else 44049 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 44050 for as_dir in $PATH 44051 do 44052 IFS=$as_save_IFS 44053 test -z "$as_dir" && as_dir=. 44054 for ac_exec_ext in '' $ac_executable_extensions; do 44055 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 44056 ac_cv_prog_ac_ct_NM="$ac_prog" 44057 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 44058 break 2 44059 fi 44060 done 44061 done 44062 IFS=$as_save_IFS 44063 44064 fi 44065 fi 44066 ac_ct_NM=$ac_cv_prog_ac_ct_NM 44067 if test -n "$ac_ct_NM"; then 44068 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_NM" >&5 44069 $as_echo "$ac_ct_NM" >&6; } 44070 else 44071 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 44072 $as_echo "no" >&6; } 44073 fi 44074 44075 44076 test -n "$ac_ct_NM" && break 44077 done 44078 44079 if test "x$ac_ct_NM" = x; then 44080 NM="" 44081 else 44082 case $cross_compiling:$ac_tool_warned in 44083 yes:) 44084 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5 44085 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;} 44086 ac_tool_warned=yes ;; 44087 esac 44088 NM=$ac_ct_NM 44089 fi 44090 fi 44091 44092 else 44093 # If it succeeded, then it was overridden by the user. We will use it 44094 # for the tool. 44095 44096 # First remove it from the list of overridden variables, so we can test 44097 # for unknown variables in the end. 44098 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 44099 44100 # Check if we try to supply an empty value 44101 if test "x$NM" = x; then 44102 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool NM= (no value)" >&5 44103 $as_echo "$as_me: Setting user supplied tool NM= (no value)" >&6;} 44104 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for NM" >&5 44105 $as_echo_n "checking for NM... " >&6; } 44106 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 44107 $as_echo "disabled" >&6; } 44108 else 44109 # Check if the provided tool contains a complete path. 44110 tool_specified="$NM" 44111 tool_basename="${tool_specified##*/}" 44112 if test "x$tool_basename" = "x$tool_specified"; then 44113 # A command without a complete path is provided, search $PATH. 44114 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool NM=$tool_basename" >&5 44115 $as_echo "$as_me: Will search for user supplied tool NM=$tool_basename" >&6;} 44116 # Extract the first word of "$tool_basename", so it can be a program name with args. 44117 set dummy $tool_basename; ac_word=$2 44118 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 44119 $as_echo_n "checking for $ac_word... " >&6; } 44120 if ${ac_cv_path_NM+:} false; then : 44121 $as_echo_n "(cached) " >&6 44122 else 44123 case $NM in 44124 [\\/]* | ?:[\\/]*) 44125 ac_cv_path_NM="$NM" # Let the user override the test with a path. 44126 ;; 44127 *) 44128 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 44129 for as_dir in $PATH 44130 do 44131 IFS=$as_save_IFS 44132 test -z "$as_dir" && as_dir=. 44133 for ac_exec_ext in '' $ac_executable_extensions; do 44134 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 44135 ac_cv_path_NM="$as_dir/$ac_word$ac_exec_ext" 44136 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 44137 break 2 44138 fi 44139 done 44140 done 44141 IFS=$as_save_IFS 44142 44143 ;; 44144 esac 44145 fi 44146 NM=$ac_cv_path_NM 44147 if test -n "$NM"; then 44148 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $NM" >&5 44149 $as_echo "$NM" >&6; } 44150 else 44151 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 44152 $as_echo "no" >&6; } 44153 fi 44154 44155 44156 if test "x$NM" = x; then 44157 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 44158 fi 44159 else 44160 # Otherwise we believe it is a complete path. Use it as it is. 44161 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool NM=$tool_specified" >&5 44162 $as_echo "$as_me: Will use user supplied tool NM=$tool_specified" >&6;} 44163 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for NM" >&5 44164 $as_echo_n "checking for NM... " >&6; } 44165 if test ! -x "$tool_specified"; then 44166 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 44167 $as_echo "not found" >&6; } 44168 as_fn_error $? "User supplied tool NM=$tool_specified does not exist or is not executable" "$LINENO" 5 44169 fi 44170 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 44171 $as_echo "$tool_specified" >&6; } 44172 fi 44173 fi 44174 fi 44175 44176 fi 44177 44178 44179 fi 44180 44181 # Only process if variable expands to non-empty 44182 44183 if test "x$NM" != x; then 44184 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 44185 44186 # First separate the path from the arguments. This will split at the first 44187 # space. 44188 complete="$NM" 44189 path="${complete%% *}" 44190 tmp="$complete EOL" 44191 arguments="${tmp#* }" 44192 44193 # Input might be given as Windows format, start by converting to 44194 # unix format. 44195 new_path=`$CYGPATH -u "$path"` 44196 44197 # Now try to locate executable using which 44198 new_path=`$WHICH "$new_path" 2> /dev/null` 44199 # bat and cmd files are not always considered executable in cygwin causing which 44200 # to not find them 44201 if test "x$new_path" = x \ 44202 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 44203 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 44204 new_path=`$CYGPATH -u "$path"` 44205 fi 44206 if test "x$new_path" = x; then 44207 # Oops. Which didn't find the executable. 44208 # The splitting of arguments from the executable at a space might have been incorrect, 44209 # since paths with space are more likely in Windows. Give it another try with the whole 44210 # argument. 44211 path="$complete" 44212 arguments="EOL" 44213 new_path=`$CYGPATH -u "$path"` 44214 new_path=`$WHICH "$new_path" 2> /dev/null` 44215 # bat and cmd files are not always considered executable in cygwin causing which 44216 # to not find them 44217 if test "x$new_path" = x \ 44218 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 44219 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 44220 new_path=`$CYGPATH -u "$path"` 44221 fi 44222 if test "x$new_path" = x; then 44223 # It's still not found. Now this is an unrecoverable error. 44224 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of NM, which resolves as \"$complete\", is not found." >&5 44225 $as_echo "$as_me: The path of NM, which resolves as \"$complete\", is not found." >&6;} 44226 has_space=`$ECHO "$complete" | $GREP " "` 44227 if test "x$has_space" != x; then 44228 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 44229 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 44230 fi 44231 as_fn_error $? "Cannot locate the the path of NM" "$LINENO" 5 44232 fi 44233 fi 44234 44235 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 44236 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 44237 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 44238 # "foo.exe" is OK but "foo" is an error. 44239 # 44240 # This test is therefore slightly more accurate than "test -f" to check for file presence. 44241 # It is also a way to make sure we got the proper file name for the real test later on. 44242 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 44243 if test "x$test_shortpath" = x; then 44244 # Short path failed, file does not exist as specified. 44245 # Try adding .exe or .cmd 44246 if test -f "${new_path}.exe"; then 44247 input_to_shortpath="${new_path}.exe" 44248 elif test -f "${new_path}.cmd"; then 44249 input_to_shortpath="${new_path}.cmd" 44250 else 44251 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of NM, which resolves as \"$new_path\", is invalid." >&5 44252 $as_echo "$as_me: The path of NM, which resolves as \"$new_path\", is invalid." >&6;} 44253 { $as_echo "$as_me:${as_lineno-$LINENO}: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&5 44254 $as_echo "$as_me: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&6;} 44255 as_fn_error $? "Cannot locate the the path of NM" "$LINENO" 5 44256 fi 44257 else 44258 input_to_shortpath="$new_path" 44259 fi 44260 44261 # Call helper function which possibly converts this using DOS-style short mode. 44262 # If so, the updated path is stored in $new_path. 44263 new_path="$input_to_shortpath" 44264 44265 input_path="$input_to_shortpath" 44266 # Check if we need to convert this using DOS-style short mode. If the path 44267 # contains just simple characters, use it. Otherwise (spaces, weird characters), 44268 # take no chances and rewrite it. 44269 # Note: m4 eats our [], so we need to use [ and ] instead. 44270 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 44271 if test "x$has_forbidden_chars" != x; then 44272 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 44273 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 44274 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 44275 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 44276 # Going to short mode and back again did indeed matter. Since short mode is 44277 # case insensitive, let's make it lowercase to improve readability. 44278 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 44279 # Now convert it back to Unix-style (cygpath) 44280 input_path=`$CYGPATH -u "$shortmode_path"` 44281 new_path="$input_path" 44282 fi 44283 fi 44284 44285 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 44286 if test "x$test_cygdrive_prefix" = x; then 44287 # As a simple fix, exclude /usr/bin since it's not a real path. 44288 if test "x`$ECHO $input_to_shortpath | $GREP ^/usr/bin/`" = x; then 44289 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 44290 # a path prefixed by /cygdrive for fixpath to work. 44291 new_path="$CYGWIN_ROOT_PATH$input_path" 44292 fi 44293 fi 44294 44295 # remove trailing .exe if any 44296 new_path="${new_path/%.exe/}" 44297 44298 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 44299 44300 # First separate the path from the arguments. This will split at the first 44301 # space. 44302 complete="$NM" 44303 path="${complete%% *}" 44304 tmp="$complete EOL" 44305 arguments="${tmp#* }" 44306 44307 # Input might be given as Windows format, start by converting to 44308 # unix format. 44309 new_path="$path" 44310 44311 windows_path="$new_path" 44312 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 44313 unix_path=`$CYGPATH -u "$windows_path"` 44314 new_path="$unix_path" 44315 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 44316 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 44317 new_path="$unix_path" 44318 fi 44319 44320 44321 # Now try to locate executable using which 44322 new_path=`$WHICH "$new_path" 2> /dev/null` 44323 44324 if test "x$new_path" = x; then 44325 # Oops. Which didn't find the executable. 44326 # The splitting of arguments from the executable at a space might have been incorrect, 44327 # since paths with space are more likely in Windows. Give it another try with the whole 44328 # argument. 44329 path="$complete" 44330 arguments="EOL" 44331 new_path="$path" 44332 44333 windows_path="$new_path" 44334 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 44335 unix_path=`$CYGPATH -u "$windows_path"` 44336 new_path="$unix_path" 44337 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 44338 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 44339 new_path="$unix_path" 44340 fi 44341 44342 44343 new_path=`$WHICH "$new_path" 2> /dev/null` 44344 # bat and cmd files are not always considered executable in MSYS causing which 44345 # to not find them 44346 if test "x$new_path" = x \ 44347 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 44348 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 44349 new_path="$path" 44350 44351 windows_path="$new_path" 44352 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 44353 unix_path=`$CYGPATH -u "$windows_path"` 44354 new_path="$unix_path" 44355 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 44356 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 44357 new_path="$unix_path" 44358 fi 44359 44360 fi 44361 44362 if test "x$new_path" = x; then 44363 # It's still not found. Now this is an unrecoverable error. 44364 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of NM, which resolves as \"$complete\", is not found." >&5 44365 $as_echo "$as_me: The path of NM, which resolves as \"$complete\", is not found." >&6;} 44366 has_space=`$ECHO "$complete" | $GREP " "` 44367 if test "x$has_space" != x; then 44368 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 44369 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 44370 fi 44371 as_fn_error $? "Cannot locate the the path of NM" "$LINENO" 5 44372 fi 44373 fi 44374 44375 # Now new_path has a complete unix path to the binary 44376 if test "x`$ECHO $new_path | $GREP ^/bin/`" != x; then 44377 # Keep paths in /bin as-is, but remove trailing .exe if any 44378 new_path="${new_path/%.exe/}" 44379 # Do not save /bin paths to all_fixpath_prefixes! 44380 else 44381 # Not in mixed or Windows style, start by that. 44382 new_path=`cmd //c echo $new_path` 44383 44384 input_path="$new_path" 44385 # Check if we need to convert this using DOS-style short mode. If the path 44386 # contains just simple characters, use it. Otherwise (spaces, weird characters), 44387 # take no chances and rewrite it. 44388 # Note: m4 eats our [], so we need to use [ and ] instead. 44389 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 44390 if test "x$has_forbidden_chars" != x; then 44391 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 44392 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 44393 fi 44394 44395 # Output is in $new_path 44396 44397 windows_path="$new_path" 44398 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 44399 unix_path=`$CYGPATH -u "$windows_path"` 44400 new_path="$unix_path" 44401 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 44402 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 44403 new_path="$unix_path" 44404 fi 44405 44406 # remove trailing .exe if any 44407 new_path="${new_path/%.exe/}" 44408 44409 # Save the first 10 bytes of this path to the storage, so fixpath can work. 44410 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 44411 fi 44412 44413 else 44414 # We're on a unix platform. Hooray! :) 44415 # First separate the path from the arguments. This will split at the first 44416 # space. 44417 complete="$NM" 44418 path="${complete%% *}" 44419 tmp="$complete EOL" 44420 arguments="${tmp#* }" 44421 44422 # Cannot rely on the command "which" here since it doesn't always work. 44423 is_absolute_path=`$ECHO "$path" | $GREP ^/` 44424 if test -z "$is_absolute_path"; then 44425 # Path to executable is not absolute. Find it. 44426 IFS_save="$IFS" 44427 IFS=: 44428 for p in $PATH; do 44429 if test -f "$p/$path" && test -x "$p/$path"; then 44430 new_path="$p/$path" 44431 break 44432 fi 44433 done 44434 IFS="$IFS_save" 44435 else 44436 # This is an absolute path, we can use it without further modifications. 44437 new_path="$path" 44438 fi 44439 44440 if test "x$new_path" = x; then 44441 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of NM, which resolves as \"$complete\", is not found." >&5 44442 $as_echo "$as_me: The path of NM, which resolves as \"$complete\", is not found." >&6;} 44443 has_space=`$ECHO "$complete" | $GREP " "` 44444 if test "x$has_space" != x; then 44445 { $as_echo "$as_me:${as_lineno-$LINENO}: This might be caused by spaces in the path, which is not allowed." >&5 44446 $as_echo "$as_me: This might be caused by spaces in the path, which is not allowed." >&6;} 44447 fi 44448 as_fn_error $? "Cannot locate the the path of NM" "$LINENO" 5 44449 fi 44450 fi 44451 44452 # Now join together the path and the arguments once again 44453 if test "x$arguments" != xEOL; then 44454 new_complete="$new_path ${arguments% *}" 44455 else 44456 new_complete="$new_path" 44457 fi 44458 44459 if test "x$complete" != "x$new_complete"; then 44460 NM="$new_complete" 44461 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting NM to \"$new_complete\"" >&5 44462 $as_echo "$as_me: Rewriting NM to \"$new_complete\"" >&6;} 44463 fi 44464 fi 44465 44466 GNM="$NM" 44467 44468 fi 44469 44470 # objcopy is used for moving debug symbols to separate files when 44471 # full debug symbols are enabled. 44472 if test "x$OPENJDK_TARGET_OS" = xsolaris || test "x$OPENJDK_TARGET_OS" = xlinux; then 44473 44474 44475 # Publish this variable in the help. 44476 44477 44478 if [ -z "${OBJCOPY+x}" ]; then 44479 # The variable is not set by user, try to locate tool using the code snippet 44480 if test -n "$ac_tool_prefix"; then 44481 for ac_prog in gobjcopy objcopy 44482 do 44483 # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args. 44484 set dummy $ac_tool_prefix$ac_prog; ac_word=$2 44485 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 44486 $as_echo_n "checking for $ac_word... " >&6; } 44487 if ${ac_cv_prog_OBJCOPY+:} false; then : 44488 $as_echo_n "(cached) " >&6 44489 else 44490 if test -n "$OBJCOPY"; then 44491 ac_cv_prog_OBJCOPY="$OBJCOPY" # Let the user override the test. 44492 else 44493 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 44494 for as_dir in $PATH 44495 do 44496 IFS=$as_save_IFS 44497 test -z "$as_dir" && as_dir=. 44498 for ac_exec_ext in '' $ac_executable_extensions; do 44499 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 44500 ac_cv_prog_OBJCOPY="$ac_tool_prefix$ac_prog" 44501 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 44502 break 2 44503 fi 44504 done 44505 done 44506 IFS=$as_save_IFS 44507 44508 fi 44509 fi 44510 OBJCOPY=$ac_cv_prog_OBJCOPY 44511 if test -n "$OBJCOPY"; then 44512 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $OBJCOPY" >&5 44513 $as_echo "$OBJCOPY" >&6; } 44514 else 44515 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 44516 $as_echo "no" >&6; } 44517 fi 44518 44519 44520 test -n "$OBJCOPY" && break 44521 done 44522 fi 44523 if test -z "$OBJCOPY"; then 44524 ac_ct_OBJCOPY=$OBJCOPY 44525 for ac_prog in gobjcopy objcopy 44526 do 44527 # Extract the first word of "$ac_prog", so it can be a program name with args. 44528 set dummy $ac_prog; ac_word=$2 44529 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 44530 $as_echo_n "checking for $ac_word... " >&6; } 44531 if ${ac_cv_prog_ac_ct_OBJCOPY+:} false; then : 44532 $as_echo_n "(cached) " >&6 44533 else 44534 if test -n "$ac_ct_OBJCOPY"; then 44535 ac_cv_prog_ac_ct_OBJCOPY="$ac_ct_OBJCOPY" # Let the user override the test. 44536 else 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_prog_ac_ct_OBJCOPY="$ac_prog" 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 fi 44553 fi 44554 ac_ct_OBJCOPY=$ac_cv_prog_ac_ct_OBJCOPY 44555 if test -n "$ac_ct_OBJCOPY"; then 44556 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_OBJCOPY" >&5 44557 $as_echo "$ac_ct_OBJCOPY" >&6; } 44558 else 44559 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 44560 $as_echo "no" >&6; } 44561 fi 44562 44563 44564 test -n "$ac_ct_OBJCOPY" && break 44565 done 44566 44567 if test "x$ac_ct_OBJCOPY" = x; then 44568 OBJCOPY="" 44569 else 44570 case $cross_compiling:$ac_tool_warned in 44571 yes:) 44572 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5 44573 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;} 44574 ac_tool_warned=yes ;; 44575 esac 44576 OBJCOPY=$ac_ct_OBJCOPY 44577 fi 44578 fi 44579 44580 else 44581 # The variable is set, but is it from the command line or the environment? 44582 44583 # Try to remove the string !OBJCOPY! from our list. 44584 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!OBJCOPY!/} 44585 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 44586 # If it failed, the variable was not from the command line. Ignore it, 44587 # but warn the user (except for BASH, which is always set by the calling BASH). 44588 if test "xOBJCOPY" != xBASH; then 44589 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of OBJCOPY from the environment. Use command line variables instead." >&5 44590 $as_echo "$as_me: WARNING: Ignoring value of OBJCOPY from the environment. Use command line variables instead." >&2;} 44591 fi 44592 # Try to locate tool using the code snippet 44593 if test -n "$ac_tool_prefix"; then 44594 for ac_prog in gobjcopy objcopy 44595 do 44596 # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args. 44597 set dummy $ac_tool_prefix$ac_prog; ac_word=$2 44598 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 44599 $as_echo_n "checking for $ac_word... " >&6; } 44600 if ${ac_cv_prog_OBJCOPY+:} false; then : 44601 $as_echo_n "(cached) " >&6 44602 else 44603 if test -n "$OBJCOPY"; then 44604 ac_cv_prog_OBJCOPY="$OBJCOPY" # Let the user override the test. 44605 else 44606 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 44607 for as_dir in $PATH 44608 do 44609 IFS=$as_save_IFS 44610 test -z "$as_dir" && as_dir=. 44611 for ac_exec_ext in '' $ac_executable_extensions; do 44612 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 44613 ac_cv_prog_OBJCOPY="$ac_tool_prefix$ac_prog" 44614 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 44615 break 2 44616 fi 44617 done 44618 done 44619 IFS=$as_save_IFS 44620 44621 fi 44622 fi 44623 OBJCOPY=$ac_cv_prog_OBJCOPY 44624 if test -n "$OBJCOPY"; then 44625 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $OBJCOPY" >&5 44626 $as_echo "$OBJCOPY" >&6; } 44627 else 44628 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 44629 $as_echo "no" >&6; } 44630 fi 44631 44632 44633 test -n "$OBJCOPY" && break 44634 done 44635 fi 44636 if test -z "$OBJCOPY"; then 44637 ac_ct_OBJCOPY=$OBJCOPY 44638 for ac_prog in gobjcopy objcopy 44639 do 44640 # Extract the first word of "$ac_prog", so it can be a program name with args. 44641 set dummy $ac_prog; ac_word=$2 44642 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 44643 $as_echo_n "checking for $ac_word... " >&6; } 44644 if ${ac_cv_prog_ac_ct_OBJCOPY+:} false; then : 44645 $as_echo_n "(cached) " >&6 44646 else 44647 if test -n "$ac_ct_OBJCOPY"; then 44648 ac_cv_prog_ac_ct_OBJCOPY="$ac_ct_OBJCOPY" # Let the user override the test. 44649 else 44650 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 44651 for as_dir in $PATH 44652 do 44653 IFS=$as_save_IFS 44654 test -z "$as_dir" && as_dir=. 44655 for ac_exec_ext in '' $ac_executable_extensions; do 44656 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 44657 ac_cv_prog_ac_ct_OBJCOPY="$ac_prog" 44658 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 44659 break 2 44660 fi 44661 done 44662 done 44663 IFS=$as_save_IFS 44664 44665 fi 44666 fi 44667 ac_ct_OBJCOPY=$ac_cv_prog_ac_ct_OBJCOPY 44668 if test -n "$ac_ct_OBJCOPY"; then 44669 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_OBJCOPY" >&5 44670 $as_echo "$ac_ct_OBJCOPY" >&6; } 44671 else 44672 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 44673 $as_echo "no" >&6; } 44674 fi 44675 44676 44677 test -n "$ac_ct_OBJCOPY" && break 44678 done 44679 44680 if test "x$ac_ct_OBJCOPY" = x; then 44681 OBJCOPY="" 44682 else 44683 case $cross_compiling:$ac_tool_warned in 44684 yes:) 44685 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5 44686 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;} 44687 ac_tool_warned=yes ;; 44688 esac 44689 OBJCOPY=$ac_ct_OBJCOPY 44690 fi 44691 fi 44692 44693 else 44694 # If it succeeded, then it was overridden by the user. We will use it 44695 # for the tool. 44696 44697 # First remove it from the list of overridden variables, so we can test 44698 # for unknown variables in the end. 44699 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 44700 44701 # Check if we try to supply an empty value 44702 if test "x$OBJCOPY" = x; then 44703 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool OBJCOPY= (no value)" >&5 44704 $as_echo "$as_me: Setting user supplied tool OBJCOPY= (no value)" >&6;} 44705 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for OBJCOPY" >&5 44706 $as_echo_n "checking for OBJCOPY... " >&6; } 44707 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 44708 $as_echo "disabled" >&6; } 44709 else 44710 # Check if the provided tool contains a complete path. 44711 tool_specified="$OBJCOPY" 44712 tool_basename="${tool_specified##*/}" 44713 if test "x$tool_basename" = "x$tool_specified"; then 44714 # A command without a complete path is provided, search $PATH. 44715 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool OBJCOPY=$tool_basename" >&5 44716 $as_echo "$as_me: Will search for user supplied tool OBJCOPY=$tool_basename" >&6;} 44717 # Extract the first word of "$tool_basename", so it can be a program name with args. 44718 set dummy $tool_basename; ac_word=$2 44719 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 44720 $as_echo_n "checking for $ac_word... " >&6; } 44721 if ${ac_cv_path_OBJCOPY+:} false; then : 44722 $as_echo_n "(cached) " >&6 44723 else 44724 case $OBJCOPY in 44725 [\\/]* | ?:[\\/]*) 44726 ac_cv_path_OBJCOPY="$OBJCOPY" # Let the user override the test with a path. 44727 ;; 44728 *) 44729 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 44730 for as_dir in $PATH 44731 do 44732 IFS=$as_save_IFS 44733 test -z "$as_dir" && as_dir=. 44734 for ac_exec_ext in '' $ac_executable_extensions; do 44735 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 44736 ac_cv_path_OBJCOPY="$as_dir/$ac_word$ac_exec_ext" 44737 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 44738 break 2 44739 fi 44740 done 44741 done 44742 IFS=$as_save_IFS 44743 44744 ;; 44745 esac 44746 fi 44747 OBJCOPY=$ac_cv_path_OBJCOPY 44748 if test -n "$OBJCOPY"; then 44749 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $OBJCOPY" >&5 44750 $as_echo "$OBJCOPY" >&6; } 44751 else 44752 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 44753 $as_echo "no" >&6; } 44754 fi 44755 44756 44757 if test "x$OBJCOPY" = x; then 44758 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 44759 fi 44760 else 44761 # Otherwise we believe it is a complete path. Use it as it is. 44762 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool OBJCOPY=$tool_specified" >&5 44763 $as_echo "$as_me: Will use user supplied tool OBJCOPY=$tool_specified" >&6;} 44764 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for OBJCOPY" >&5 44765 $as_echo_n "checking for OBJCOPY... " >&6; } 44766 if test ! -x "$tool_specified"; then 44767 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 44768 $as_echo "not found" >&6; } 44769 as_fn_error $? "User supplied tool OBJCOPY=$tool_specified does not exist or is not executable" "$LINENO" 5 44770 fi 44771 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 44772 $as_echo "$tool_specified" >&6; } 44773 fi 44774 fi 44775 fi 44776 44777 fi 44778 44779 44780 # Only call fixup if objcopy was found. 44781 if test -n "$OBJCOPY"; then 44782 44783 # Only process if variable expands to non-empty 44784 44785 if test "x$OBJCOPY" != x; then 44786 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 44787 44788 # First separate the path from the arguments. This will split at the first 44789 # space. 44790 complete="$OBJCOPY" 44791 path="${complete%% *}" 44792 tmp="$complete EOL" 44793 arguments="${tmp#* }" 44794 44795 # Input might be given as Windows format, start by converting to 44796 # unix format. 44797 new_path=`$CYGPATH -u "$path"` 44798 44799 # Now try to locate executable using which 44800 new_path=`$WHICH "$new_path" 2> /dev/null` 44801 # bat and cmd files are not always considered executable in cygwin causing which 44802 # to not find them 44803 if test "x$new_path" = x \ 44804 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 44805 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 44806 new_path=`$CYGPATH -u "$path"` 44807 fi 44808 if test "x$new_path" = x; then 44809 # Oops. Which didn't find the executable. 44810 # The splitting of arguments from the executable at a space might have been incorrect, 44811 # since paths with space are more likely in Windows. Give it another try with the whole 44812 # argument. 44813 path="$complete" 44814 arguments="EOL" 44815 new_path=`$CYGPATH -u "$path"` 44816 new_path=`$WHICH "$new_path" 2> /dev/null` 44817 # bat and cmd files are not always considered executable in cygwin causing which 44818 # to not find them 44819 if test "x$new_path" = x \ 44820 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 44821 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 44822 new_path=`$CYGPATH -u "$path"` 44823 fi 44824 if test "x$new_path" = x; then 44825 # It's still not found. Now this is an unrecoverable error. 44826 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of OBJCOPY, which resolves as \"$complete\", is not found." >&5 44827 $as_echo "$as_me: The path of OBJCOPY, which resolves as \"$complete\", is not found." >&6;} 44828 has_space=`$ECHO "$complete" | $GREP " "` 44829 if test "x$has_space" != x; then 44830 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 44831 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 44832 fi 44833 as_fn_error $? "Cannot locate the the path of OBJCOPY" "$LINENO" 5 44834 fi 44835 fi 44836 44837 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 44838 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 44839 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 44840 # "foo.exe" is OK but "foo" is an error. 44841 # 44842 # This test is therefore slightly more accurate than "test -f" to check for file presence. 44843 # It is also a way to make sure we got the proper file name for the real test later on. 44844 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 44845 if test "x$test_shortpath" = x; then 44846 # Short path failed, file does not exist as specified. 44847 # Try adding .exe or .cmd 44848 if test -f "${new_path}.exe"; then 44849 input_to_shortpath="${new_path}.exe" 44850 elif test -f "${new_path}.cmd"; then 44851 input_to_shortpath="${new_path}.cmd" 44852 else 44853 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of OBJCOPY, which resolves as \"$new_path\", is invalid." >&5 44854 $as_echo "$as_me: The path of OBJCOPY, which resolves as \"$new_path\", is invalid." >&6;} 44855 { $as_echo "$as_me:${as_lineno-$LINENO}: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&5 44856 $as_echo "$as_me: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&6;} 44857 as_fn_error $? "Cannot locate the the path of OBJCOPY" "$LINENO" 5 44858 fi 44859 else 44860 input_to_shortpath="$new_path" 44861 fi 44862 44863 # Call helper function which possibly converts this using DOS-style short mode. 44864 # If so, the updated path is stored in $new_path. 44865 new_path="$input_to_shortpath" 44866 44867 input_path="$input_to_shortpath" 44868 # Check if we need to convert this using DOS-style short mode. If the path 44869 # contains just simple characters, use it. Otherwise (spaces, weird characters), 44870 # take no chances and rewrite it. 44871 # Note: m4 eats our [], so we need to use [ and ] instead. 44872 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 44873 if test "x$has_forbidden_chars" != x; then 44874 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 44875 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 44876 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 44877 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 44878 # Going to short mode and back again did indeed matter. Since short mode is 44879 # case insensitive, let's make it lowercase to improve readability. 44880 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 44881 # Now convert it back to Unix-style (cygpath) 44882 input_path=`$CYGPATH -u "$shortmode_path"` 44883 new_path="$input_path" 44884 fi 44885 fi 44886 44887 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 44888 if test "x$test_cygdrive_prefix" = x; then 44889 # As a simple fix, exclude /usr/bin since it's not a real path. 44890 if test "x`$ECHO $input_to_shortpath | $GREP ^/usr/bin/`" = x; then 44891 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 44892 # a path prefixed by /cygdrive for fixpath to work. 44893 new_path="$CYGWIN_ROOT_PATH$input_path" 44894 fi 44895 fi 44896 44897 # remove trailing .exe if any 44898 new_path="${new_path/%.exe/}" 44899 44900 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 44901 44902 # First separate the path from the arguments. This will split at the first 44903 # space. 44904 complete="$OBJCOPY" 44905 path="${complete%% *}" 44906 tmp="$complete EOL" 44907 arguments="${tmp#* }" 44908 44909 # Input might be given as Windows format, start by converting to 44910 # unix format. 44911 new_path="$path" 44912 44913 windows_path="$new_path" 44914 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 44915 unix_path=`$CYGPATH -u "$windows_path"` 44916 new_path="$unix_path" 44917 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 44918 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 44919 new_path="$unix_path" 44920 fi 44921 44922 44923 # Now try to locate executable using which 44924 new_path=`$WHICH "$new_path" 2> /dev/null` 44925 44926 if test "x$new_path" = x; then 44927 # Oops. Which didn't find the executable. 44928 # The splitting of arguments from the executable at a space might have been incorrect, 44929 # since paths with space are more likely in Windows. Give it another try with the whole 44930 # argument. 44931 path="$complete" 44932 arguments="EOL" 44933 new_path="$path" 44934 44935 windows_path="$new_path" 44936 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 44937 unix_path=`$CYGPATH -u "$windows_path"` 44938 new_path="$unix_path" 44939 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 44940 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 44941 new_path="$unix_path" 44942 fi 44943 44944 44945 new_path=`$WHICH "$new_path" 2> /dev/null` 44946 # bat and cmd files are not always considered executable in MSYS causing which 44947 # to not find them 44948 if test "x$new_path" = x \ 44949 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 44950 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 44951 new_path="$path" 44952 44953 windows_path="$new_path" 44954 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 44955 unix_path=`$CYGPATH -u "$windows_path"` 44956 new_path="$unix_path" 44957 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 44958 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 44959 new_path="$unix_path" 44960 fi 44961 44962 fi 44963 44964 if test "x$new_path" = x; then 44965 # It's still not found. Now this is an unrecoverable error. 44966 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of OBJCOPY, which resolves as \"$complete\", is not found." >&5 44967 $as_echo "$as_me: The path of OBJCOPY, which resolves as \"$complete\", is not found." >&6;} 44968 has_space=`$ECHO "$complete" | $GREP " "` 44969 if test "x$has_space" != x; then 44970 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 44971 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 44972 fi 44973 as_fn_error $? "Cannot locate the the path of OBJCOPY" "$LINENO" 5 44974 fi 44975 fi 44976 44977 # Now new_path has a complete unix path to the binary 44978 if test "x`$ECHO $new_path | $GREP ^/bin/`" != x; then 44979 # Keep paths in /bin as-is, but remove trailing .exe if any 44980 new_path="${new_path/%.exe/}" 44981 # Do not save /bin paths to all_fixpath_prefixes! 44982 else 44983 # Not in mixed or Windows style, start by that. 44984 new_path=`cmd //c echo $new_path` 44985 44986 input_path="$new_path" 44987 # Check if we need to convert this using DOS-style short mode. If the path 44988 # contains just simple characters, use it. Otherwise (spaces, weird characters), 44989 # take no chances and rewrite it. 44990 # Note: m4 eats our [], so we need to use [ and ] instead. 44991 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 44992 if test "x$has_forbidden_chars" != x; then 44993 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 44994 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 44995 fi 44996 44997 # Output is in $new_path 44998 44999 windows_path="$new_path" 45000 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 45001 unix_path=`$CYGPATH -u "$windows_path"` 45002 new_path="$unix_path" 45003 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 45004 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 45005 new_path="$unix_path" 45006 fi 45007 45008 # remove trailing .exe if any 45009 new_path="${new_path/%.exe/}" 45010 45011 # Save the first 10 bytes of this path to the storage, so fixpath can work. 45012 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 45013 fi 45014 45015 else 45016 # We're on a unix platform. Hooray! :) 45017 # First separate the path from the arguments. This will split at the first 45018 # space. 45019 complete="$OBJCOPY" 45020 path="${complete%% *}" 45021 tmp="$complete EOL" 45022 arguments="${tmp#* }" 45023 45024 # Cannot rely on the command "which" here since it doesn't always work. 45025 is_absolute_path=`$ECHO "$path" | $GREP ^/` 45026 if test -z "$is_absolute_path"; then 45027 # Path to executable is not absolute. Find it. 45028 IFS_save="$IFS" 45029 IFS=: 45030 for p in $PATH; do 45031 if test -f "$p/$path" && test -x "$p/$path"; then 45032 new_path="$p/$path" 45033 break 45034 fi 45035 done 45036 IFS="$IFS_save" 45037 else 45038 # This is an absolute path, we can use it without further modifications. 45039 new_path="$path" 45040 fi 45041 45042 if test "x$new_path" = x; then 45043 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of OBJCOPY, which resolves as \"$complete\", is not found." >&5 45044 $as_echo "$as_me: The path of OBJCOPY, which resolves as \"$complete\", is not found." >&6;} 45045 has_space=`$ECHO "$complete" | $GREP " "` 45046 if test "x$has_space" != x; then 45047 { $as_echo "$as_me:${as_lineno-$LINENO}: This might be caused by spaces in the path, which is not allowed." >&5 45048 $as_echo "$as_me: This might be caused by spaces in the path, which is not allowed." >&6;} 45049 fi 45050 as_fn_error $? "Cannot locate the the path of OBJCOPY" "$LINENO" 5 45051 fi 45052 fi 45053 45054 # Now join together the path and the arguments once again 45055 if test "x$arguments" != xEOL; then 45056 new_complete="$new_path ${arguments% *}" 45057 else 45058 new_complete="$new_path" 45059 fi 45060 45061 if test "x$complete" != "x$new_complete"; then 45062 OBJCOPY="$new_complete" 45063 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting OBJCOPY to \"$new_complete\"" >&5 45064 $as_echo "$as_me: Rewriting OBJCOPY to \"$new_complete\"" >&6;} 45065 fi 45066 fi 45067 45068 if test "x$OPENJDK_BUILD_OS" = xsolaris; then 45069 # objcopy prior to 2.21.1 on solaris is broken and is not usable. 45070 # Rewrite objcopy version output to VALID_VERSION or BAD_VERSION. 45071 # - version number is last blank separate word on first line 45072 # - version number formats that have been seen: 45073 # - <major>.<minor> 45074 # - <major>.<minor>.<micro> 45075 OBJCOPY_VERSION=`$OBJCOPY --version | $HEAD -n 1` 45076 # The outer [ ] is to prevent m4 from eating the [] in the sed expression. 45077 OBJCOPY_VERSION_CHECK=`$ECHO $OBJCOPY_VERSION | $SED -n \ 45078 -e 's/.* //' \ 45079 -e '/^[01]\./b bad' \ 45080 -e '/^2\./{' \ 45081 -e ' s/^2\.//' \ 45082 -e ' /^[0-9]$/b bad' \ 45083 -e ' /^[0-9]\./b bad' \ 45084 -e ' /^1[0-9]$/b bad' \ 45085 -e ' /^1[0-9]\./b bad' \ 45086 -e ' /^20\./b bad' \ 45087 -e ' /^21\.0$/b bad' \ 45088 -e ' /^21\.0\./b bad' \ 45089 -e '}' \ 45090 -e ':good' \ 45091 -e 's/.*/VALID_VERSION/p' \ 45092 -e 'q' \ 45093 -e ':bad' \ 45094 -e 's/.*/BAD_VERSION/p' \ 45095 -e 'q'` 45096 if test "x$OBJCOPY_VERSION_CHECK" = xBAD_VERSION; then 45097 OBJCOPY= 45098 { $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 45099 $as_echo "$as_me: WARNING: Ignoring found objcopy since it is broken (prior to 2.21.1). No debug symbols will be generated." >&2;} 45100 { $as_echo "$as_me:${as_lineno-$LINENO}: objcopy reports version $OBJCOPY_VERSION" >&5 45101 $as_echo "$as_me: objcopy reports version $OBJCOPY_VERSION" >&6;} 45102 { $as_echo "$as_me:${as_lineno-$LINENO}: Note: patch 149063-01 or newer contains the correct Solaris 10 SPARC version" >&5 45103 $as_echo "$as_me: Note: patch 149063-01 or newer contains the correct Solaris 10 SPARC version" >&6;} 45104 { $as_echo "$as_me:${as_lineno-$LINENO}: Note: patch 149064-01 or newer contains the correct Solaris 10 X86 version" >&5 45105 $as_echo "$as_me: Note: patch 149064-01 or newer contains the correct Solaris 10 X86 version" >&6;} 45106 { $as_echo "$as_me:${as_lineno-$LINENO}: Note: Solaris 11 Update 1 contains the correct version" >&5 45107 $as_echo "$as_me: Note: Solaris 11 Update 1 contains the correct version" >&6;} 45108 fi 45109 fi 45110 fi 45111 fi 45112 45113 45114 45115 # Publish this variable in the help. 45116 45117 45118 if [ -z "${OBJDUMP+x}" ]; then 45119 # The variable is not set by user, try to locate tool using the code snippet 45120 if test -n "$ac_tool_prefix"; then 45121 for ac_prog in gobjdump objdump 45122 do 45123 # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args. 45124 set dummy $ac_tool_prefix$ac_prog; ac_word=$2 45125 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 45126 $as_echo_n "checking for $ac_word... " >&6; } 45127 if ${ac_cv_prog_OBJDUMP+:} false; then : 45128 $as_echo_n "(cached) " >&6 45129 else 45130 if test -n "$OBJDUMP"; then 45131 ac_cv_prog_OBJDUMP="$OBJDUMP" # Let the user override the test. 45132 else 45133 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 45134 for as_dir in $PATH 45135 do 45136 IFS=$as_save_IFS 45137 test -z "$as_dir" && as_dir=. 45138 for ac_exec_ext in '' $ac_executable_extensions; do 45139 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 45140 ac_cv_prog_OBJDUMP="$ac_tool_prefix$ac_prog" 45141 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 45142 break 2 45143 fi 45144 done 45145 done 45146 IFS=$as_save_IFS 45147 45148 fi 45149 fi 45150 OBJDUMP=$ac_cv_prog_OBJDUMP 45151 if test -n "$OBJDUMP"; then 45152 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $OBJDUMP" >&5 45153 $as_echo "$OBJDUMP" >&6; } 45154 else 45155 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 45156 $as_echo "no" >&6; } 45157 fi 45158 45159 45160 test -n "$OBJDUMP" && break 45161 done 45162 fi 45163 if test -z "$OBJDUMP"; then 45164 ac_ct_OBJDUMP=$OBJDUMP 45165 for ac_prog in gobjdump objdump 45166 do 45167 # Extract the first word of "$ac_prog", so it can be a program name with args. 45168 set dummy $ac_prog; ac_word=$2 45169 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 45170 $as_echo_n "checking for $ac_word... " >&6; } 45171 if ${ac_cv_prog_ac_ct_OBJDUMP+:} false; then : 45172 $as_echo_n "(cached) " >&6 45173 else 45174 if test -n "$ac_ct_OBJDUMP"; then 45175 ac_cv_prog_ac_ct_OBJDUMP="$ac_ct_OBJDUMP" # Let the user override the test. 45176 else 45177 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 45178 for as_dir in $PATH 45179 do 45180 IFS=$as_save_IFS 45181 test -z "$as_dir" && as_dir=. 45182 for ac_exec_ext in '' $ac_executable_extensions; do 45183 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 45184 ac_cv_prog_ac_ct_OBJDUMP="$ac_prog" 45185 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 45186 break 2 45187 fi 45188 done 45189 done 45190 IFS=$as_save_IFS 45191 45192 fi 45193 fi 45194 ac_ct_OBJDUMP=$ac_cv_prog_ac_ct_OBJDUMP 45195 if test -n "$ac_ct_OBJDUMP"; then 45196 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_OBJDUMP" >&5 45197 $as_echo "$ac_ct_OBJDUMP" >&6; } 45198 else 45199 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 45200 $as_echo "no" >&6; } 45201 fi 45202 45203 45204 test -n "$ac_ct_OBJDUMP" && break 45205 done 45206 45207 if test "x$ac_ct_OBJDUMP" = x; then 45208 OBJDUMP="" 45209 else 45210 case $cross_compiling:$ac_tool_warned in 45211 yes:) 45212 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5 45213 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;} 45214 ac_tool_warned=yes ;; 45215 esac 45216 OBJDUMP=$ac_ct_OBJDUMP 45217 fi 45218 fi 45219 45220 else 45221 # The variable is set, but is it from the command line or the environment? 45222 45223 # Try to remove the string !OBJDUMP! from our list. 45224 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!OBJDUMP!/} 45225 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 45226 # If it failed, the variable was not from the command line. Ignore it, 45227 # but warn the user (except for BASH, which is always set by the calling BASH). 45228 if test "xOBJDUMP" != xBASH; then 45229 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of OBJDUMP from the environment. Use command line variables instead." >&5 45230 $as_echo "$as_me: WARNING: Ignoring value of OBJDUMP from the environment. Use command line variables instead." >&2;} 45231 fi 45232 # Try to locate tool using the code snippet 45233 if test -n "$ac_tool_prefix"; then 45234 for ac_prog in gobjdump objdump 45235 do 45236 # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args. 45237 set dummy $ac_tool_prefix$ac_prog; ac_word=$2 45238 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 45239 $as_echo_n "checking for $ac_word... " >&6; } 45240 if ${ac_cv_prog_OBJDUMP+:} false; then : 45241 $as_echo_n "(cached) " >&6 45242 else 45243 if test -n "$OBJDUMP"; then 45244 ac_cv_prog_OBJDUMP="$OBJDUMP" # Let the user override the test. 45245 else 45246 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 45247 for as_dir in $PATH 45248 do 45249 IFS=$as_save_IFS 45250 test -z "$as_dir" && as_dir=. 45251 for ac_exec_ext in '' $ac_executable_extensions; do 45252 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 45253 ac_cv_prog_OBJDUMP="$ac_tool_prefix$ac_prog" 45254 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 45255 break 2 45256 fi 45257 done 45258 done 45259 IFS=$as_save_IFS 45260 45261 fi 45262 fi 45263 OBJDUMP=$ac_cv_prog_OBJDUMP 45264 if test -n "$OBJDUMP"; then 45265 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $OBJDUMP" >&5 45266 $as_echo "$OBJDUMP" >&6; } 45267 else 45268 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 45269 $as_echo "no" >&6; } 45270 fi 45271 45272 45273 test -n "$OBJDUMP" && break 45274 done 45275 fi 45276 if test -z "$OBJDUMP"; then 45277 ac_ct_OBJDUMP=$OBJDUMP 45278 for ac_prog in gobjdump objdump 45279 do 45280 # Extract the first word of "$ac_prog", so it can be a program name with args. 45281 set dummy $ac_prog; ac_word=$2 45282 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 45283 $as_echo_n "checking for $ac_word... " >&6; } 45284 if ${ac_cv_prog_ac_ct_OBJDUMP+:} false; then : 45285 $as_echo_n "(cached) " >&6 45286 else 45287 if test -n "$ac_ct_OBJDUMP"; then 45288 ac_cv_prog_ac_ct_OBJDUMP="$ac_ct_OBJDUMP" # Let the user override the test. 45289 else 45290 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 45291 for as_dir in $PATH 45292 do 45293 IFS=$as_save_IFS 45294 test -z "$as_dir" && as_dir=. 45295 for ac_exec_ext in '' $ac_executable_extensions; do 45296 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 45297 ac_cv_prog_ac_ct_OBJDUMP="$ac_prog" 45298 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 45299 break 2 45300 fi 45301 done 45302 done 45303 IFS=$as_save_IFS 45304 45305 fi 45306 fi 45307 ac_ct_OBJDUMP=$ac_cv_prog_ac_ct_OBJDUMP 45308 if test -n "$ac_ct_OBJDUMP"; then 45309 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_OBJDUMP" >&5 45310 $as_echo "$ac_ct_OBJDUMP" >&6; } 45311 else 45312 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 45313 $as_echo "no" >&6; } 45314 fi 45315 45316 45317 test -n "$ac_ct_OBJDUMP" && break 45318 done 45319 45320 if test "x$ac_ct_OBJDUMP" = x; then 45321 OBJDUMP="" 45322 else 45323 case $cross_compiling:$ac_tool_warned in 45324 yes:) 45325 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5 45326 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;} 45327 ac_tool_warned=yes ;; 45328 esac 45329 OBJDUMP=$ac_ct_OBJDUMP 45330 fi 45331 fi 45332 45333 else 45334 # If it succeeded, then it was overridden by the user. We will use it 45335 # for the tool. 45336 45337 # First remove it from the list of overridden variables, so we can test 45338 # for unknown variables in the end. 45339 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 45340 45341 # Check if we try to supply an empty value 45342 if test "x$OBJDUMP" = x; then 45343 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool OBJDUMP= (no value)" >&5 45344 $as_echo "$as_me: Setting user supplied tool OBJDUMP= (no value)" >&6;} 45345 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for OBJDUMP" >&5 45346 $as_echo_n "checking for OBJDUMP... " >&6; } 45347 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 45348 $as_echo "disabled" >&6; } 45349 else 45350 # Check if the provided tool contains a complete path. 45351 tool_specified="$OBJDUMP" 45352 tool_basename="${tool_specified##*/}" 45353 if test "x$tool_basename" = "x$tool_specified"; then 45354 # A command without a complete path is provided, search $PATH. 45355 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool OBJDUMP=$tool_basename" >&5 45356 $as_echo "$as_me: Will search for user supplied tool OBJDUMP=$tool_basename" >&6;} 45357 # Extract the first word of "$tool_basename", so it can be a program name with args. 45358 set dummy $tool_basename; ac_word=$2 45359 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 45360 $as_echo_n "checking for $ac_word... " >&6; } 45361 if ${ac_cv_path_OBJDUMP+:} false; then : 45362 $as_echo_n "(cached) " >&6 45363 else 45364 case $OBJDUMP in 45365 [\\/]* | ?:[\\/]*) 45366 ac_cv_path_OBJDUMP="$OBJDUMP" # Let the user override the test with a path. 45367 ;; 45368 *) 45369 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 45370 for as_dir in $PATH 45371 do 45372 IFS=$as_save_IFS 45373 test -z "$as_dir" && as_dir=. 45374 for ac_exec_ext in '' $ac_executable_extensions; do 45375 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 45376 ac_cv_path_OBJDUMP="$as_dir/$ac_word$ac_exec_ext" 45377 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 45378 break 2 45379 fi 45380 done 45381 done 45382 IFS=$as_save_IFS 45383 45384 ;; 45385 esac 45386 fi 45387 OBJDUMP=$ac_cv_path_OBJDUMP 45388 if test -n "$OBJDUMP"; then 45389 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $OBJDUMP" >&5 45390 $as_echo "$OBJDUMP" >&6; } 45391 else 45392 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 45393 $as_echo "no" >&6; } 45394 fi 45395 45396 45397 if test "x$OBJDUMP" = x; then 45398 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 45399 fi 45400 else 45401 # Otherwise we believe it is a complete path. Use it as it is. 45402 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool OBJDUMP=$tool_specified" >&5 45403 $as_echo "$as_me: Will use user supplied tool OBJDUMP=$tool_specified" >&6;} 45404 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for OBJDUMP" >&5 45405 $as_echo_n "checking for OBJDUMP... " >&6; } 45406 if test ! -x "$tool_specified"; then 45407 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 45408 $as_echo "not found" >&6; } 45409 as_fn_error $? "User supplied tool OBJDUMP=$tool_specified does not exist or is not executable" "$LINENO" 5 45410 fi 45411 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 45412 $as_echo "$tool_specified" >&6; } 45413 fi 45414 fi 45415 fi 45416 45417 fi 45418 45419 45420 if test "x$OBJDUMP" != x; then 45421 # Only used for compare.sh; we can live without it. BASIC_FIXUP_EXECUTABLE 45422 # bails if argument is missing. 45423 45424 # Only process if variable expands to non-empty 45425 45426 if test "x$OBJDUMP" != x; then 45427 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 45428 45429 # First separate the path from the arguments. This will split at the first 45430 # space. 45431 complete="$OBJDUMP" 45432 path="${complete%% *}" 45433 tmp="$complete EOL" 45434 arguments="${tmp#* }" 45435 45436 # Input might be given as Windows format, start by converting to 45437 # unix format. 45438 new_path=`$CYGPATH -u "$path"` 45439 45440 # Now try to locate executable using which 45441 new_path=`$WHICH "$new_path" 2> /dev/null` 45442 # bat and cmd files are not always considered executable in cygwin causing which 45443 # to not find them 45444 if test "x$new_path" = x \ 45445 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 45446 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 45447 new_path=`$CYGPATH -u "$path"` 45448 fi 45449 if test "x$new_path" = x; then 45450 # Oops. Which didn't find the executable. 45451 # The splitting of arguments from the executable at a space might have been incorrect, 45452 # since paths with space are more likely in Windows. Give it another try with the whole 45453 # argument. 45454 path="$complete" 45455 arguments="EOL" 45456 new_path=`$CYGPATH -u "$path"` 45457 new_path=`$WHICH "$new_path" 2> /dev/null` 45458 # bat and cmd files are not always considered executable in cygwin causing which 45459 # to not find them 45460 if test "x$new_path" = x \ 45461 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 45462 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 45463 new_path=`$CYGPATH -u "$path"` 45464 fi 45465 if test "x$new_path" = x; then 45466 # It's still not found. Now this is an unrecoverable error. 45467 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of OBJDUMP, which resolves as \"$complete\", is not found." >&5 45468 $as_echo "$as_me: The path of OBJDUMP, which resolves as \"$complete\", is not found." >&6;} 45469 has_space=`$ECHO "$complete" | $GREP " "` 45470 if test "x$has_space" != x; then 45471 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 45472 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 45473 fi 45474 as_fn_error $? "Cannot locate the the path of OBJDUMP" "$LINENO" 5 45475 fi 45476 fi 45477 45478 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 45479 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 45480 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 45481 # "foo.exe" is OK but "foo" is an error. 45482 # 45483 # This test is therefore slightly more accurate than "test -f" to check for file presence. 45484 # It is also a way to make sure we got the proper file name for the real test later on. 45485 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 45486 if test "x$test_shortpath" = x; then 45487 # Short path failed, file does not exist as specified. 45488 # Try adding .exe or .cmd 45489 if test -f "${new_path}.exe"; then 45490 input_to_shortpath="${new_path}.exe" 45491 elif test -f "${new_path}.cmd"; then 45492 input_to_shortpath="${new_path}.cmd" 45493 else 45494 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of OBJDUMP, which resolves as \"$new_path\", is invalid." >&5 45495 $as_echo "$as_me: The path of OBJDUMP, which resolves as \"$new_path\", is invalid." >&6;} 45496 { $as_echo "$as_me:${as_lineno-$LINENO}: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&5 45497 $as_echo "$as_me: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&6;} 45498 as_fn_error $? "Cannot locate the the path of OBJDUMP" "$LINENO" 5 45499 fi 45500 else 45501 input_to_shortpath="$new_path" 45502 fi 45503 45504 # Call helper function which possibly converts this using DOS-style short mode. 45505 # If so, the updated path is stored in $new_path. 45506 new_path="$input_to_shortpath" 45507 45508 input_path="$input_to_shortpath" 45509 # Check if we need to convert this using DOS-style short mode. If the path 45510 # contains just simple characters, use it. Otherwise (spaces, weird characters), 45511 # take no chances and rewrite it. 45512 # Note: m4 eats our [], so we need to use [ and ] instead. 45513 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 45514 if test "x$has_forbidden_chars" != x; then 45515 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 45516 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 45517 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 45518 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 45519 # Going to short mode and back again did indeed matter. Since short mode is 45520 # case insensitive, let's make it lowercase to improve readability. 45521 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 45522 # Now convert it back to Unix-style (cygpath) 45523 input_path=`$CYGPATH -u "$shortmode_path"` 45524 new_path="$input_path" 45525 fi 45526 fi 45527 45528 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 45529 if test "x$test_cygdrive_prefix" = x; then 45530 # As a simple fix, exclude /usr/bin since it's not a real path. 45531 if test "x`$ECHO $input_to_shortpath | $GREP ^/usr/bin/`" = x; then 45532 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 45533 # a path prefixed by /cygdrive for fixpath to work. 45534 new_path="$CYGWIN_ROOT_PATH$input_path" 45535 fi 45536 fi 45537 45538 # remove trailing .exe if any 45539 new_path="${new_path/%.exe/}" 45540 45541 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 45542 45543 # First separate the path from the arguments. This will split at the first 45544 # space. 45545 complete="$OBJDUMP" 45546 path="${complete%% *}" 45547 tmp="$complete EOL" 45548 arguments="${tmp#* }" 45549 45550 # Input might be given as Windows format, start by converting to 45551 # unix format. 45552 new_path="$path" 45553 45554 windows_path="$new_path" 45555 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 45556 unix_path=`$CYGPATH -u "$windows_path"` 45557 new_path="$unix_path" 45558 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 45559 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 45560 new_path="$unix_path" 45561 fi 45562 45563 45564 # Now try to locate executable using which 45565 new_path=`$WHICH "$new_path" 2> /dev/null` 45566 45567 if test "x$new_path" = x; then 45568 # Oops. Which didn't find the executable. 45569 # The splitting of arguments from the executable at a space might have been incorrect, 45570 # since paths with space are more likely in Windows. Give it another try with the whole 45571 # argument. 45572 path="$complete" 45573 arguments="EOL" 45574 new_path="$path" 45575 45576 windows_path="$new_path" 45577 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 45578 unix_path=`$CYGPATH -u "$windows_path"` 45579 new_path="$unix_path" 45580 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 45581 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 45582 new_path="$unix_path" 45583 fi 45584 45585 45586 new_path=`$WHICH "$new_path" 2> /dev/null` 45587 # bat and cmd files are not always considered executable in MSYS causing which 45588 # to not find them 45589 if test "x$new_path" = x \ 45590 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 45591 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 45592 new_path="$path" 45593 45594 windows_path="$new_path" 45595 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 45596 unix_path=`$CYGPATH -u "$windows_path"` 45597 new_path="$unix_path" 45598 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 45599 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 45600 new_path="$unix_path" 45601 fi 45602 45603 fi 45604 45605 if test "x$new_path" = x; then 45606 # It's still not found. Now this is an unrecoverable error. 45607 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of OBJDUMP, which resolves as \"$complete\", is not found." >&5 45608 $as_echo "$as_me: The path of OBJDUMP, which resolves as \"$complete\", is not found." >&6;} 45609 has_space=`$ECHO "$complete" | $GREP " "` 45610 if test "x$has_space" != x; then 45611 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 45612 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 45613 fi 45614 as_fn_error $? "Cannot locate the the path of OBJDUMP" "$LINENO" 5 45615 fi 45616 fi 45617 45618 # Now new_path has a complete unix path to the binary 45619 if test "x`$ECHO $new_path | $GREP ^/bin/`" != x; then 45620 # Keep paths in /bin as-is, but remove trailing .exe if any 45621 new_path="${new_path/%.exe/}" 45622 # Do not save /bin paths to all_fixpath_prefixes! 45623 else 45624 # Not in mixed or Windows style, start by that. 45625 new_path=`cmd //c echo $new_path` 45626 45627 input_path="$new_path" 45628 # Check if we need to convert this using DOS-style short mode. If the path 45629 # contains just simple characters, use it. Otherwise (spaces, weird characters), 45630 # take no chances and rewrite it. 45631 # Note: m4 eats our [], so we need to use [ and ] instead. 45632 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 45633 if test "x$has_forbidden_chars" != x; then 45634 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 45635 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 45636 fi 45637 45638 # Output is in $new_path 45639 45640 windows_path="$new_path" 45641 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 45642 unix_path=`$CYGPATH -u "$windows_path"` 45643 new_path="$unix_path" 45644 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 45645 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 45646 new_path="$unix_path" 45647 fi 45648 45649 # remove trailing .exe if any 45650 new_path="${new_path/%.exe/}" 45651 45652 # Save the first 10 bytes of this path to the storage, so fixpath can work. 45653 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 45654 fi 45655 45656 else 45657 # We're on a unix platform. Hooray! :) 45658 # First separate the path from the arguments. This will split at the first 45659 # space. 45660 complete="$OBJDUMP" 45661 path="${complete%% *}" 45662 tmp="$complete EOL" 45663 arguments="${tmp#* }" 45664 45665 # Cannot rely on the command "which" here since it doesn't always work. 45666 is_absolute_path=`$ECHO "$path" | $GREP ^/` 45667 if test -z "$is_absolute_path"; then 45668 # Path to executable is not absolute. Find it. 45669 IFS_save="$IFS" 45670 IFS=: 45671 for p in $PATH; do 45672 if test -f "$p/$path" && test -x "$p/$path"; then 45673 new_path="$p/$path" 45674 break 45675 fi 45676 done 45677 IFS="$IFS_save" 45678 else 45679 # This is an absolute path, we can use it without further modifications. 45680 new_path="$path" 45681 fi 45682 45683 if test "x$new_path" = x; then 45684 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of OBJDUMP, which resolves as \"$complete\", is not found." >&5 45685 $as_echo "$as_me: The path of OBJDUMP, which resolves as \"$complete\", is not found." >&6;} 45686 has_space=`$ECHO "$complete" | $GREP " "` 45687 if test "x$has_space" != x; then 45688 { $as_echo "$as_me:${as_lineno-$LINENO}: This might be caused by spaces in the path, which is not allowed." >&5 45689 $as_echo "$as_me: This might be caused by spaces in the path, which is not allowed." >&6;} 45690 fi 45691 as_fn_error $? "Cannot locate the the path of OBJDUMP" "$LINENO" 5 45692 fi 45693 fi 45694 45695 # Now join together the path and the arguments once again 45696 if test "x$arguments" != xEOL; then 45697 new_complete="$new_path ${arguments% *}" 45698 else 45699 new_complete="$new_path" 45700 fi 45701 45702 if test "x$complete" != "x$new_complete"; then 45703 OBJDUMP="$new_complete" 45704 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting OBJDUMP to \"$new_complete\"" >&5 45705 $as_echo "$as_me: Rewriting OBJDUMP to \"$new_complete\"" >&6;} 45706 fi 45707 fi 45708 45709 fi 45710 45711 45712 # Restore old path, except for the microsoft toolchain, which requires VS_PATH 45713 # to remain in place. Otherwise the compiler will not work in some siutations 45714 # in later configure checks. 45715 if test "x$TOOLCHAIN_TYPE" != "xmicrosoft"; then 45716 PATH="$OLD_PATH" 45717 fi 45718 45719 # Restore the flags to the user specified values. 45720 # This is necessary since AC_PROG_CC defaults CFLAGS to "-g -O2" 45721 CFLAGS="$ORG_CFLAGS" 45722 CXXFLAGS="$ORG_CXXFLAGS" 45723 45724 45725 # Finally do some processing after the detection phase 45726 45727 if test "x$COMPILE_TYPE" = "xcross"; then 45728 # Now we need to find a C/C++ compiler that can build executables for the 45729 # build platform. We can't use the AC_PROG_CC macro, since it can only be 45730 # used once. Also, we need to do this without adding a tools dir to the 45731 # path, otherwise we might pick up cross-compilers which don't use standard 45732 # naming. 45733 45734 OLDPATH="$PATH" 45735 45736 45737 # Check whether --with-build-devkit was given. 45738 if test "${with_build_devkit+set}" = set; then : 45739 withval=$with_build_devkit; 45740 fi 45741 45742 if test "x$with_build_devkit" = "xyes"; then 45743 as_fn_error $? "--with-build-devkit must have a value" "$LINENO" 5 45744 elif test -n "$with_build_devkit"; then 45745 if test ! -d "$with_build_devkit"; then 45746 as_fn_error $? "--with-build-devkit points to non existing dir: $with_build_devkit" "$LINENO" 5 45747 else 45748 45749 # Only process if variable expands to non-empty 45750 45751 if test "x$with_build_devkit" != x; then 45752 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 45753 45754 # Input might be given as Windows format, start by converting to 45755 # unix format. 45756 path="$with_build_devkit" 45757 new_path=`$CYGPATH -u "$path"` 45758 45759 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 45760 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 45761 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 45762 # "foo.exe" is OK but "foo" is an error. 45763 # 45764 # This test is therefore slightly more accurate than "test -f" to check for file precense. 45765 # It is also a way to make sure we got the proper file name for the real test later on. 45766 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 45767 if test "x$test_shortpath" = x; then 45768 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of with_build_devkit, which resolves as \"$path\", is invalid." >&5 45769 $as_echo "$as_me: The path of with_build_devkit, which resolves as \"$path\", is invalid." >&6;} 45770 as_fn_error $? "Cannot locate the the path of with_build_devkit" "$LINENO" 5 45771 fi 45772 45773 # Call helper function which possibly converts this using DOS-style short mode. 45774 # If so, the updated path is stored in $new_path. 45775 45776 input_path="$new_path" 45777 # Check if we need to convert this using DOS-style short mode. If the path 45778 # contains just simple characters, use it. Otherwise (spaces, weird characters), 45779 # take no chances and rewrite it. 45780 # Note: m4 eats our [], so we need to use [ and ] instead. 45781 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 45782 if test "x$has_forbidden_chars" != x; then 45783 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 45784 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 45785 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 45786 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 45787 # Going to short mode and back again did indeed matter. Since short mode is 45788 # case insensitive, let's make it lowercase to improve readability. 45789 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 45790 # Now convert it back to Unix-style (cygpath) 45791 input_path=`$CYGPATH -u "$shortmode_path"` 45792 new_path="$input_path" 45793 fi 45794 fi 45795 45796 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 45797 if test "x$test_cygdrive_prefix" = x; then 45798 # As a simple fix, exclude /usr/bin since it's not a real path. 45799 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 45800 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 45801 # a path prefixed by /cygdrive for fixpath to work. 45802 new_path="$CYGWIN_ROOT_PATH$input_path" 45803 fi 45804 fi 45805 45806 45807 if test "x$path" != "x$new_path"; then 45808 with_build_devkit="$new_path" 45809 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting with_build_devkit to \"$new_path\"" >&5 45810 $as_echo "$as_me: Rewriting with_build_devkit to \"$new_path\"" >&6;} 45811 fi 45812 45813 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 45814 45815 path="$with_build_devkit" 45816 has_colon=`$ECHO $path | $GREP ^.:` 45817 new_path="$path" 45818 if test "x$has_colon" = x; then 45819 # Not in mixed or Windows style, start by that. 45820 new_path=`cmd //c echo $path` 45821 fi 45822 45823 45824 input_path="$new_path" 45825 # Check if we need to convert this using DOS-style short mode. If the path 45826 # contains just simple characters, use it. Otherwise (spaces, weird characters), 45827 # take no chances and rewrite it. 45828 # Note: m4 eats our [], so we need to use [ and ] instead. 45829 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 45830 if test "x$has_forbidden_chars" != x; then 45831 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 45832 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 45833 fi 45834 45835 45836 windows_path="$new_path" 45837 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 45838 unix_path=`$CYGPATH -u "$windows_path"` 45839 new_path="$unix_path" 45840 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 45841 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 45842 new_path="$unix_path" 45843 fi 45844 45845 if test "x$path" != "x$new_path"; then 45846 with_build_devkit="$new_path" 45847 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting with_build_devkit to \"$new_path\"" >&5 45848 $as_echo "$as_me: Rewriting with_build_devkit to \"$new_path\"" >&6;} 45849 fi 45850 45851 # Save the first 10 bytes of this path to the storage, so fixpath can work. 45852 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 45853 45854 else 45855 # We're on a unix platform. Hooray! :) 45856 path="$with_build_devkit" 45857 has_space=`$ECHO "$path" | $GREP " "` 45858 if test "x$has_space" != x; then 45859 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of with_build_devkit, which resolves as \"$path\", is invalid." >&5 45860 $as_echo "$as_me: The path of with_build_devkit, which resolves as \"$path\", is invalid." >&6;} 45861 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 45862 fi 45863 45864 # Use eval to expand a potential ~ 45865 eval path="$path" 45866 if test ! -f "$path" && test ! -d "$path"; then 45867 as_fn_error $? "The path of with_build_devkit, which resolves as \"$path\", is not found." "$LINENO" 5 45868 fi 45869 45870 if test -d "$path"; then 45871 with_build_devkit="`cd "$path"; $THEPWDCMD -L`" 45872 else 45873 dir="`$DIRNAME "$path"`" 45874 base="`$BASENAME "$path"`" 45875 with_build_devkit="`cd "$dir"; $THEPWDCMD -L`/$base" 45876 fi 45877 fi 45878 fi 45879 45880 BUILD_DEVKIT_ROOT="$with_build_devkit" 45881 # Check for a meta data info file in the root of the devkit 45882 if test -f "$BUILD_DEVKIT_ROOT/devkit.info"; then 45883 # Process devkit.info so that existing devkit variables are not 45884 # modified by this 45885 $SED -e "s/^DEVKIT_/BUILD_DEVKIT_/g" \ 45886 -e "s/\$DEVKIT_ROOT/\$BUILD_DEVKIT_ROOT/g" \ 45887 -e "s/\$host/\$build/g" \ 45888 $BUILD_DEVKIT_ROOT/devkit.info \ 45889 > $CONFIGURESUPPORT_OUTPUTDIR/build-devkit.info 45890 . $CONFIGURESUPPORT_OUTPUTDIR/build-devkit.info 45891 # This potentially sets the following: 45892 # A descriptive name of the devkit 45893 45894 if test "x$BUILD_DEVKIT_NAME" = x; then 45895 eval BUILD_DEVKIT_NAME="\${BUILD_DEVKIT_NAME_${OPENJDK_TARGET_CPU}}" 45896 fi 45897 45898 # Corresponds to --with-extra-path 45899 45900 if test "x$BUILD_DEVKIT_EXTRA_PATH" = x; then 45901 eval BUILD_DEVKIT_EXTRA_PATH="\${BUILD_DEVKIT_EXTRA_PATH_${OPENJDK_TARGET_CPU}}" 45902 fi 45903 45904 # Corresponds to --with-toolchain-path 45905 45906 if test "x$BUILD_DEVKIT_TOOLCHAIN_PATH" = x; then 45907 eval BUILD_DEVKIT_TOOLCHAIN_PATH="\${BUILD_DEVKIT_TOOLCHAIN_PATH_${OPENJDK_TARGET_CPU}}" 45908 fi 45909 45910 # Corresponds to --with-sysroot 45911 45912 if test "x$BUILD_DEVKIT_SYSROOT" = x; then 45913 eval BUILD_DEVKIT_SYSROOT="\${BUILD_DEVKIT_SYSROOT_${OPENJDK_TARGET_CPU}}" 45914 fi 45915 45916 # Skip the Window specific parts 45917 fi 45918 45919 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for build platform devkit" >&5 45920 $as_echo_n "checking for build platform devkit... " >&6; } 45921 if test "x$BUILD_DEVKIT_NAME" != x; then 45922 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BUILD_DEVKIT_NAME in $BUILD_DEVKIT_ROOT" >&5 45923 $as_echo "$BUILD_DEVKIT_NAME in $BUILD_DEVKIT_ROOT" >&6; } 45924 else 45925 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BUILD_DEVKIT_ROOT" >&5 45926 $as_echo "$BUILD_DEVKIT_ROOT" >&6; } 45927 fi 45928 45929 BUILD_SYSROOT="$BUILD_DEVKIT_SYSROOT" 45930 45931 if test "x$BUILD_SYSROOT" != "x"; then 45932 if test "x$TOOLCHAIN_TYPE" = xsolstudio; then 45933 if test "x$OPENJDK_TARGET_OS" = xsolaris; then 45934 # Solaris Studio does not have a concept of sysroot. Instead we must 45935 # make sure the default include and lib dirs are appended to each 45936 # compile and link command line. Must also add -I-xbuiltin to enable 45937 # inlining of system functions and intrinsics. 45938 BUILD_SYSROOT_CFLAGS="-I-xbuiltin -I$BUILD_SYSROOT/usr/include" 45939 BUILD_SYSROOT_LDFLAGS="-L$BUILD_SYSROOT/usr/lib$OPENJDK_TARGET_CPU_ISADIR \ 45940 -L$BUILD_SYSROOT/lib$OPENJDK_TARGET_CPU_ISADIR" 45941 fi 45942 elif test "x$TOOLCHAIN_TYPE" = xgcc; then 45943 BUILD_SYSROOT_CFLAGS="--sysroot=$BUILD_SYSROOT" 45944 BUILD_SYSROOT_LDFLAGS="--sysroot=$BUILD_SYSROOT" 45945 elif test "x$TOOLCHAIN_TYPE" = xclang; then 45946 BUILD_SYSROOT_CFLAGS="-isysroot $BUILD_SYSROOT" 45947 BUILD_SYSROOT_LDFLAGS="-isysroot $BUILD_SYSROOT" 45948 fi 45949 # The global CFLAGS and LDFLAGS variables need these for configure to function 45950 BUILD_CFLAGS="$BUILD_CFLAGS $BUILD_SYSROOT_CFLAGS" 45951 BUILD_CPPFLAGS="$BUILD_CPPFLAGS $BUILD_SYSROOT_CFLAGS" 45952 BUILD_CXXFLAGS="$BUILD_CXXFLAGS $BUILD_SYSROOT_CFLAGS" 45953 BUILD_LDFLAGS="$BUILD_LDFLAGS $BUILD_SYSROOT_LDFLAGS" 45954 fi 45955 45956 if test "x$OPENJDK_TARGET_OS" = xmacosx; then 45957 # We also need -iframework<path>/System/Library/Frameworks 45958 BUILD_SYSROOT_CFLAGS="$BUILD_SYSROOT_CFLAGS -iframework $BUILD_SYSROOT/System/Library/Frameworks" 45959 BUILD_SYSROOT_LDFLAGS="$BUILD_SYSROOT_LDFLAGS -iframework $BUILD_SYSROOT/System/Library/Frameworks" 45960 # These always need to be set, or we can't find the frameworks embedded in JavaVM.framework 45961 # set this here so it doesn't have to be peppered throughout the forest 45962 BUILD_SYSROOT_CFLAGS="$BUILD_SYSROOT_CFLAGS -F $BUILD_SYSROOT/System/Library/Frameworks/JavaVM.framework/Frameworks" 45963 BUILD_SYSROOT_LDFLAGS="$BUILD_SYSROOT_LDFLAGS -F $BUILD_SYSROOT/System/Library/Frameworks/JavaVM.framework/Frameworks" 45964 fi 45965 45966 45967 45968 45969 45970 # Fallback default of just /bin if DEVKIT_PATH is not defined 45971 if test "x$BUILD_DEVKIT_TOOLCHAIN_PATH" = x; then 45972 BUILD_DEVKIT_TOOLCHAIN_PATH="$BUILD_DEVKIT_ROOT/bin" 45973 fi 45974 PATH="$BUILD_DEVKIT_TOOLCHAIN_PATH:$BUILD_DEVKIT_EXTRA_PATH" 45975 fi 45976 fi 45977 45978 # FIXME: we should list the discovered compilers as an exclude pattern! 45979 # If we do that, we can do this detection before POST_DETECTION, and still 45980 # find the build compilers in the tools dir, if needed. 45981 45982 45983 45984 # Publish this variable in the help. 45985 45986 45987 if [ -z "${BUILD_CC+x}" ]; then 45988 # The variable is not set by user, try to locate tool using the code snippet 45989 for ac_prog in cl cc gcc 45990 do 45991 # Extract the first word of "$ac_prog", so it can be a program name with args. 45992 set dummy $ac_prog; ac_word=$2 45993 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 45994 $as_echo_n "checking for $ac_word... " >&6; } 45995 if ${ac_cv_path_BUILD_CC+:} false; then : 45996 $as_echo_n "(cached) " >&6 45997 else 45998 case $BUILD_CC in 45999 [\\/]* | ?:[\\/]*) 46000 ac_cv_path_BUILD_CC="$BUILD_CC" # Let the user override the test with a path. 46001 ;; 46002 *) 46003 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 46004 for as_dir in $PATH 46005 do 46006 IFS=$as_save_IFS 46007 test -z "$as_dir" && as_dir=. 46008 for ac_exec_ext in '' $ac_executable_extensions; do 46009 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 46010 ac_cv_path_BUILD_CC="$as_dir/$ac_word$ac_exec_ext" 46011 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 46012 break 2 46013 fi 46014 done 46015 done 46016 IFS=$as_save_IFS 46017 46018 ;; 46019 esac 46020 fi 46021 BUILD_CC=$ac_cv_path_BUILD_CC 46022 if test -n "$BUILD_CC"; then 46023 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BUILD_CC" >&5 46024 $as_echo "$BUILD_CC" >&6; } 46025 else 46026 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 46027 $as_echo "no" >&6; } 46028 fi 46029 46030 46031 test -n "$BUILD_CC" && break 46032 done 46033 46034 else 46035 # The variable is set, but is it from the command line or the environment? 46036 46037 # Try to remove the string !BUILD_CC! from our list. 46038 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!BUILD_CC!/} 46039 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 46040 # If it failed, the variable was not from the command line. Ignore it, 46041 # but warn the user (except for BASH, which is always set by the calling BASH). 46042 if test "xBUILD_CC" != xBASH; then 46043 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of BUILD_CC from the environment. Use command line variables instead." >&5 46044 $as_echo "$as_me: WARNING: Ignoring value of BUILD_CC from the environment. Use command line variables instead." >&2;} 46045 fi 46046 # Try to locate tool using the code snippet 46047 for ac_prog in cl cc gcc 46048 do 46049 # Extract the first word of "$ac_prog", so it can be a program name with args. 46050 set dummy $ac_prog; ac_word=$2 46051 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 46052 $as_echo_n "checking for $ac_word... " >&6; } 46053 if ${ac_cv_path_BUILD_CC+:} false; then : 46054 $as_echo_n "(cached) " >&6 46055 else 46056 case $BUILD_CC in 46057 [\\/]* | ?:[\\/]*) 46058 ac_cv_path_BUILD_CC="$BUILD_CC" # Let the user override the test with a path. 46059 ;; 46060 *) 46061 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 46062 for as_dir in $PATH 46063 do 46064 IFS=$as_save_IFS 46065 test -z "$as_dir" && as_dir=. 46066 for ac_exec_ext in '' $ac_executable_extensions; do 46067 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 46068 ac_cv_path_BUILD_CC="$as_dir/$ac_word$ac_exec_ext" 46069 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 46070 break 2 46071 fi 46072 done 46073 done 46074 IFS=$as_save_IFS 46075 46076 ;; 46077 esac 46078 fi 46079 BUILD_CC=$ac_cv_path_BUILD_CC 46080 if test -n "$BUILD_CC"; then 46081 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BUILD_CC" >&5 46082 $as_echo "$BUILD_CC" >&6; } 46083 else 46084 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 46085 $as_echo "no" >&6; } 46086 fi 46087 46088 46089 test -n "$BUILD_CC" && break 46090 done 46091 46092 else 46093 # If it succeeded, then it was overridden by the user. We will use it 46094 # for the tool. 46095 46096 # First remove it from the list of overridden variables, so we can test 46097 # for unknown variables in the end. 46098 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 46099 46100 # Check if we try to supply an empty value 46101 if test "x$BUILD_CC" = x; then 46102 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool BUILD_CC= (no value)" >&5 46103 $as_echo "$as_me: Setting user supplied tool BUILD_CC= (no value)" >&6;} 46104 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for BUILD_CC" >&5 46105 $as_echo_n "checking for BUILD_CC... " >&6; } 46106 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 46107 $as_echo "disabled" >&6; } 46108 else 46109 # Check if the provided tool contains a complete path. 46110 tool_specified="$BUILD_CC" 46111 tool_basename="${tool_specified##*/}" 46112 if test "x$tool_basename" = "x$tool_specified"; then 46113 # A command without a complete path is provided, search $PATH. 46114 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool BUILD_CC=$tool_basename" >&5 46115 $as_echo "$as_me: Will search for user supplied tool BUILD_CC=$tool_basename" >&6;} 46116 # Extract the first word of "$tool_basename", so it can be a program name with args. 46117 set dummy $tool_basename; ac_word=$2 46118 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 46119 $as_echo_n "checking for $ac_word... " >&6; } 46120 if ${ac_cv_path_BUILD_CC+:} false; then : 46121 $as_echo_n "(cached) " >&6 46122 else 46123 case $BUILD_CC in 46124 [\\/]* | ?:[\\/]*) 46125 ac_cv_path_BUILD_CC="$BUILD_CC" # Let the user override the test with a path. 46126 ;; 46127 *) 46128 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 46129 for as_dir in $PATH 46130 do 46131 IFS=$as_save_IFS 46132 test -z "$as_dir" && as_dir=. 46133 for ac_exec_ext in '' $ac_executable_extensions; do 46134 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 46135 ac_cv_path_BUILD_CC="$as_dir/$ac_word$ac_exec_ext" 46136 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 46137 break 2 46138 fi 46139 done 46140 done 46141 IFS=$as_save_IFS 46142 46143 ;; 46144 esac 46145 fi 46146 BUILD_CC=$ac_cv_path_BUILD_CC 46147 if test -n "$BUILD_CC"; then 46148 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BUILD_CC" >&5 46149 $as_echo "$BUILD_CC" >&6; } 46150 else 46151 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 46152 $as_echo "no" >&6; } 46153 fi 46154 46155 46156 if test "x$BUILD_CC" = x; then 46157 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 46158 fi 46159 else 46160 # Otherwise we believe it is a complete path. Use it as it is. 46161 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool BUILD_CC=$tool_specified" >&5 46162 $as_echo "$as_me: Will use user supplied tool BUILD_CC=$tool_specified" >&6;} 46163 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for BUILD_CC" >&5 46164 $as_echo_n "checking for BUILD_CC... " >&6; } 46165 if test ! -x "$tool_specified"; then 46166 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 46167 $as_echo "not found" >&6; } 46168 as_fn_error $? "User supplied tool BUILD_CC=$tool_specified does not exist or is not executable" "$LINENO" 5 46169 fi 46170 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 46171 $as_echo "$tool_specified" >&6; } 46172 fi 46173 fi 46174 fi 46175 46176 fi 46177 46178 46179 46180 if test "x$BUILD_CC" = x; then 46181 as_fn_error $? "Could not find required tool for BUILD_CC" "$LINENO" 5 46182 fi 46183 46184 46185 46186 # Only process if variable expands to non-empty 46187 46188 if test "x$BUILD_CC" != x; then 46189 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 46190 46191 # First separate the path from the arguments. This will split at the first 46192 # space. 46193 complete="$BUILD_CC" 46194 path="${complete%% *}" 46195 tmp="$complete EOL" 46196 arguments="${tmp#* }" 46197 46198 # Input might be given as Windows format, start by converting to 46199 # unix format. 46200 new_path=`$CYGPATH -u "$path"` 46201 46202 # Now try to locate executable using which 46203 new_path=`$WHICH "$new_path" 2> /dev/null` 46204 # bat and cmd files are not always considered executable in cygwin causing which 46205 # to not find them 46206 if test "x$new_path" = x \ 46207 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 46208 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 46209 new_path=`$CYGPATH -u "$path"` 46210 fi 46211 if test "x$new_path" = x; then 46212 # Oops. Which didn't find the executable. 46213 # The splitting of arguments from the executable at a space might have been incorrect, 46214 # since paths with space are more likely in Windows. Give it another try with the whole 46215 # argument. 46216 path="$complete" 46217 arguments="EOL" 46218 new_path=`$CYGPATH -u "$path"` 46219 new_path=`$WHICH "$new_path" 2> /dev/null` 46220 # bat and cmd files are not always considered executable in cygwin causing which 46221 # to not find them 46222 if test "x$new_path" = x \ 46223 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 46224 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 46225 new_path=`$CYGPATH -u "$path"` 46226 fi 46227 if test "x$new_path" = x; then 46228 # It's still not found. Now this is an unrecoverable error. 46229 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BUILD_CC, which resolves as \"$complete\", is not found." >&5 46230 $as_echo "$as_me: The path of BUILD_CC, which resolves as \"$complete\", is not found." >&6;} 46231 has_space=`$ECHO "$complete" | $GREP " "` 46232 if test "x$has_space" != x; then 46233 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 46234 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 46235 fi 46236 as_fn_error $? "Cannot locate the the path of BUILD_CC" "$LINENO" 5 46237 fi 46238 fi 46239 46240 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 46241 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 46242 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 46243 # "foo.exe" is OK but "foo" is an error. 46244 # 46245 # This test is therefore slightly more accurate than "test -f" to check for file presence. 46246 # It is also a way to make sure we got the proper file name for the real test later on. 46247 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 46248 if test "x$test_shortpath" = x; then 46249 # Short path failed, file does not exist as specified. 46250 # Try adding .exe or .cmd 46251 if test -f "${new_path}.exe"; then 46252 input_to_shortpath="${new_path}.exe" 46253 elif test -f "${new_path}.cmd"; then 46254 input_to_shortpath="${new_path}.cmd" 46255 else 46256 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BUILD_CC, which resolves as \"$new_path\", is invalid." >&5 46257 $as_echo "$as_me: The path of BUILD_CC, which resolves as \"$new_path\", is invalid." >&6;} 46258 { $as_echo "$as_me:${as_lineno-$LINENO}: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&5 46259 $as_echo "$as_me: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&6;} 46260 as_fn_error $? "Cannot locate the the path of BUILD_CC" "$LINENO" 5 46261 fi 46262 else 46263 input_to_shortpath="$new_path" 46264 fi 46265 46266 # Call helper function which possibly converts this using DOS-style short mode. 46267 # If so, the updated path is stored in $new_path. 46268 new_path="$input_to_shortpath" 46269 46270 input_path="$input_to_shortpath" 46271 # Check if we need to convert this using DOS-style short mode. If the path 46272 # contains just simple characters, use it. Otherwise (spaces, weird characters), 46273 # take no chances and rewrite it. 46274 # Note: m4 eats our [], so we need to use [ and ] instead. 46275 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 46276 if test "x$has_forbidden_chars" != x; then 46277 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 46278 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 46279 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 46280 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 46281 # Going to short mode and back again did indeed matter. Since short mode is 46282 # case insensitive, let's make it lowercase to improve readability. 46283 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 46284 # Now convert it back to Unix-style (cygpath) 46285 input_path=`$CYGPATH -u "$shortmode_path"` 46286 new_path="$input_path" 46287 fi 46288 fi 46289 46290 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 46291 if test "x$test_cygdrive_prefix" = x; then 46292 # As a simple fix, exclude /usr/bin since it's not a real path. 46293 if test "x`$ECHO $input_to_shortpath | $GREP ^/usr/bin/`" = x; then 46294 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 46295 # a path prefixed by /cygdrive for fixpath to work. 46296 new_path="$CYGWIN_ROOT_PATH$input_path" 46297 fi 46298 fi 46299 46300 # remove trailing .exe if any 46301 new_path="${new_path/%.exe/}" 46302 46303 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 46304 46305 # First separate the path from the arguments. This will split at the first 46306 # space. 46307 complete="$BUILD_CC" 46308 path="${complete%% *}" 46309 tmp="$complete EOL" 46310 arguments="${tmp#* }" 46311 46312 # Input might be given as Windows format, start by converting to 46313 # unix format. 46314 new_path="$path" 46315 46316 windows_path="$new_path" 46317 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 46318 unix_path=`$CYGPATH -u "$windows_path"` 46319 new_path="$unix_path" 46320 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 46321 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 46322 new_path="$unix_path" 46323 fi 46324 46325 46326 # Now try to locate executable using which 46327 new_path=`$WHICH "$new_path" 2> /dev/null` 46328 46329 if test "x$new_path" = x; then 46330 # Oops. Which didn't find the executable. 46331 # The splitting of arguments from the executable at a space might have been incorrect, 46332 # since paths with space are more likely in Windows. Give it another try with the whole 46333 # argument. 46334 path="$complete" 46335 arguments="EOL" 46336 new_path="$path" 46337 46338 windows_path="$new_path" 46339 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 46340 unix_path=`$CYGPATH -u "$windows_path"` 46341 new_path="$unix_path" 46342 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 46343 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 46344 new_path="$unix_path" 46345 fi 46346 46347 46348 new_path=`$WHICH "$new_path" 2> /dev/null` 46349 # bat and cmd files are not always considered executable in MSYS causing which 46350 # to not find them 46351 if test "x$new_path" = x \ 46352 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 46353 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 46354 new_path="$path" 46355 46356 windows_path="$new_path" 46357 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 46358 unix_path=`$CYGPATH -u "$windows_path"` 46359 new_path="$unix_path" 46360 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 46361 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 46362 new_path="$unix_path" 46363 fi 46364 46365 fi 46366 46367 if test "x$new_path" = x; then 46368 # It's still not found. Now this is an unrecoverable error. 46369 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BUILD_CC, which resolves as \"$complete\", is not found." >&5 46370 $as_echo "$as_me: The path of BUILD_CC, which resolves as \"$complete\", is not found." >&6;} 46371 has_space=`$ECHO "$complete" | $GREP " "` 46372 if test "x$has_space" != x; then 46373 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 46374 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 46375 fi 46376 as_fn_error $? "Cannot locate the the path of BUILD_CC" "$LINENO" 5 46377 fi 46378 fi 46379 46380 # Now new_path has a complete unix path to the binary 46381 if test "x`$ECHO $new_path | $GREP ^/bin/`" != x; then 46382 # Keep paths in /bin as-is, but remove trailing .exe if any 46383 new_path="${new_path/%.exe/}" 46384 # Do not save /bin paths to all_fixpath_prefixes! 46385 else 46386 # Not in mixed or Windows style, start by that. 46387 new_path=`cmd //c echo $new_path` 46388 46389 input_path="$new_path" 46390 # Check if we need to convert this using DOS-style short mode. If the path 46391 # contains just simple characters, use it. Otherwise (spaces, weird characters), 46392 # take no chances and rewrite it. 46393 # Note: m4 eats our [], so we need to use [ and ] instead. 46394 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 46395 if test "x$has_forbidden_chars" != x; then 46396 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 46397 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 46398 fi 46399 46400 # Output is in $new_path 46401 46402 windows_path="$new_path" 46403 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 46404 unix_path=`$CYGPATH -u "$windows_path"` 46405 new_path="$unix_path" 46406 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 46407 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 46408 new_path="$unix_path" 46409 fi 46410 46411 # remove trailing .exe if any 46412 new_path="${new_path/%.exe/}" 46413 46414 # Save the first 10 bytes of this path to the storage, so fixpath can work. 46415 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 46416 fi 46417 46418 else 46419 # We're on a unix platform. Hooray! :) 46420 # First separate the path from the arguments. This will split at the first 46421 # space. 46422 complete="$BUILD_CC" 46423 path="${complete%% *}" 46424 tmp="$complete EOL" 46425 arguments="${tmp#* }" 46426 46427 # Cannot rely on the command "which" here since it doesn't always work. 46428 is_absolute_path=`$ECHO "$path" | $GREP ^/` 46429 if test -z "$is_absolute_path"; then 46430 # Path to executable is not absolute. Find it. 46431 IFS_save="$IFS" 46432 IFS=: 46433 for p in $PATH; do 46434 if test -f "$p/$path" && test -x "$p/$path"; then 46435 new_path="$p/$path" 46436 break 46437 fi 46438 done 46439 IFS="$IFS_save" 46440 else 46441 # This is an absolute path, we can use it without further modifications. 46442 new_path="$path" 46443 fi 46444 46445 if test "x$new_path" = x; then 46446 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BUILD_CC, which resolves as \"$complete\", is not found." >&5 46447 $as_echo "$as_me: The path of BUILD_CC, which resolves as \"$complete\", is not found." >&6;} 46448 has_space=`$ECHO "$complete" | $GREP " "` 46449 if test "x$has_space" != x; then 46450 { $as_echo "$as_me:${as_lineno-$LINENO}: This might be caused by spaces in the path, which is not allowed." >&5 46451 $as_echo "$as_me: This might be caused by spaces in the path, which is not allowed." >&6;} 46452 fi 46453 as_fn_error $? "Cannot locate the the path of BUILD_CC" "$LINENO" 5 46454 fi 46455 fi 46456 46457 # Now join together the path and the arguments once again 46458 if test "x$arguments" != xEOL; then 46459 new_complete="$new_path ${arguments% *}" 46460 else 46461 new_complete="$new_path" 46462 fi 46463 46464 if test "x$complete" != "x$new_complete"; then 46465 BUILD_CC="$new_complete" 46466 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BUILD_CC to \"$new_complete\"" >&5 46467 $as_echo "$as_me: Rewriting BUILD_CC to \"$new_complete\"" >&6;} 46468 fi 46469 fi 46470 46471 46472 46473 46474 # Publish this variable in the help. 46475 46476 46477 if [ -z "${BUILD_CXX+x}" ]; then 46478 # The variable is not set by user, try to locate tool using the code snippet 46479 for ac_prog in cl CC g++ 46480 do 46481 # Extract the first word of "$ac_prog", so it can be a program name with args. 46482 set dummy $ac_prog; ac_word=$2 46483 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 46484 $as_echo_n "checking for $ac_word... " >&6; } 46485 if ${ac_cv_path_BUILD_CXX+:} false; then : 46486 $as_echo_n "(cached) " >&6 46487 else 46488 case $BUILD_CXX in 46489 [\\/]* | ?:[\\/]*) 46490 ac_cv_path_BUILD_CXX="$BUILD_CXX" # Let the user override the test with a path. 46491 ;; 46492 *) 46493 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 46494 for as_dir in $PATH 46495 do 46496 IFS=$as_save_IFS 46497 test -z "$as_dir" && as_dir=. 46498 for ac_exec_ext in '' $ac_executable_extensions; do 46499 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 46500 ac_cv_path_BUILD_CXX="$as_dir/$ac_word$ac_exec_ext" 46501 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 46502 break 2 46503 fi 46504 done 46505 done 46506 IFS=$as_save_IFS 46507 46508 ;; 46509 esac 46510 fi 46511 BUILD_CXX=$ac_cv_path_BUILD_CXX 46512 if test -n "$BUILD_CXX"; then 46513 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BUILD_CXX" >&5 46514 $as_echo "$BUILD_CXX" >&6; } 46515 else 46516 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 46517 $as_echo "no" >&6; } 46518 fi 46519 46520 46521 test -n "$BUILD_CXX" && break 46522 done 46523 46524 else 46525 # The variable is set, but is it from the command line or the environment? 46526 46527 # Try to remove the string !BUILD_CXX! from our list. 46528 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!BUILD_CXX!/} 46529 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 46530 # If it failed, the variable was not from the command line. Ignore it, 46531 # but warn the user (except for BASH, which is always set by the calling BASH). 46532 if test "xBUILD_CXX" != xBASH; then 46533 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of BUILD_CXX from the environment. Use command line variables instead." >&5 46534 $as_echo "$as_me: WARNING: Ignoring value of BUILD_CXX from the environment. Use command line variables instead." >&2;} 46535 fi 46536 # Try to locate tool using the code snippet 46537 for ac_prog in cl CC g++ 46538 do 46539 # Extract the first word of "$ac_prog", so it can be a program name with args. 46540 set dummy $ac_prog; ac_word=$2 46541 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 46542 $as_echo_n "checking for $ac_word... " >&6; } 46543 if ${ac_cv_path_BUILD_CXX+:} false; then : 46544 $as_echo_n "(cached) " >&6 46545 else 46546 case $BUILD_CXX in 46547 [\\/]* | ?:[\\/]*) 46548 ac_cv_path_BUILD_CXX="$BUILD_CXX" # Let the user override the test with a path. 46549 ;; 46550 *) 46551 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 46552 for as_dir in $PATH 46553 do 46554 IFS=$as_save_IFS 46555 test -z "$as_dir" && as_dir=. 46556 for ac_exec_ext in '' $ac_executable_extensions; do 46557 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 46558 ac_cv_path_BUILD_CXX="$as_dir/$ac_word$ac_exec_ext" 46559 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 46560 break 2 46561 fi 46562 done 46563 done 46564 IFS=$as_save_IFS 46565 46566 ;; 46567 esac 46568 fi 46569 BUILD_CXX=$ac_cv_path_BUILD_CXX 46570 if test -n "$BUILD_CXX"; then 46571 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BUILD_CXX" >&5 46572 $as_echo "$BUILD_CXX" >&6; } 46573 else 46574 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 46575 $as_echo "no" >&6; } 46576 fi 46577 46578 46579 test -n "$BUILD_CXX" && break 46580 done 46581 46582 else 46583 # If it succeeded, then it was overridden by the user. We will use it 46584 # for the tool. 46585 46586 # First remove it from the list of overridden variables, so we can test 46587 # for unknown variables in the end. 46588 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 46589 46590 # Check if we try to supply an empty value 46591 if test "x$BUILD_CXX" = x; then 46592 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool BUILD_CXX= (no value)" >&5 46593 $as_echo "$as_me: Setting user supplied tool BUILD_CXX= (no value)" >&6;} 46594 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for BUILD_CXX" >&5 46595 $as_echo_n "checking for BUILD_CXX... " >&6; } 46596 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 46597 $as_echo "disabled" >&6; } 46598 else 46599 # Check if the provided tool contains a complete path. 46600 tool_specified="$BUILD_CXX" 46601 tool_basename="${tool_specified##*/}" 46602 if test "x$tool_basename" = "x$tool_specified"; then 46603 # A command without a complete path is provided, search $PATH. 46604 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool BUILD_CXX=$tool_basename" >&5 46605 $as_echo "$as_me: Will search for user supplied tool BUILD_CXX=$tool_basename" >&6;} 46606 # Extract the first word of "$tool_basename", so it can be a program name with args. 46607 set dummy $tool_basename; ac_word=$2 46608 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 46609 $as_echo_n "checking for $ac_word... " >&6; } 46610 if ${ac_cv_path_BUILD_CXX+:} false; then : 46611 $as_echo_n "(cached) " >&6 46612 else 46613 case $BUILD_CXX in 46614 [\\/]* | ?:[\\/]*) 46615 ac_cv_path_BUILD_CXX="$BUILD_CXX" # Let the user override the test with a path. 46616 ;; 46617 *) 46618 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 46619 for as_dir in $PATH 46620 do 46621 IFS=$as_save_IFS 46622 test -z "$as_dir" && as_dir=. 46623 for ac_exec_ext in '' $ac_executable_extensions; do 46624 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 46625 ac_cv_path_BUILD_CXX="$as_dir/$ac_word$ac_exec_ext" 46626 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 46627 break 2 46628 fi 46629 done 46630 done 46631 IFS=$as_save_IFS 46632 46633 ;; 46634 esac 46635 fi 46636 BUILD_CXX=$ac_cv_path_BUILD_CXX 46637 if test -n "$BUILD_CXX"; then 46638 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BUILD_CXX" >&5 46639 $as_echo "$BUILD_CXX" >&6; } 46640 else 46641 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 46642 $as_echo "no" >&6; } 46643 fi 46644 46645 46646 if test "x$BUILD_CXX" = x; then 46647 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 46648 fi 46649 else 46650 # Otherwise we believe it is a complete path. Use it as it is. 46651 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool BUILD_CXX=$tool_specified" >&5 46652 $as_echo "$as_me: Will use user supplied tool BUILD_CXX=$tool_specified" >&6;} 46653 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for BUILD_CXX" >&5 46654 $as_echo_n "checking for BUILD_CXX... " >&6; } 46655 if test ! -x "$tool_specified"; then 46656 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 46657 $as_echo "not found" >&6; } 46658 as_fn_error $? "User supplied tool BUILD_CXX=$tool_specified does not exist or is not executable" "$LINENO" 5 46659 fi 46660 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 46661 $as_echo "$tool_specified" >&6; } 46662 fi 46663 fi 46664 fi 46665 46666 fi 46667 46668 46669 46670 if test "x$BUILD_CXX" = x; then 46671 as_fn_error $? "Could not find required tool for BUILD_CXX" "$LINENO" 5 46672 fi 46673 46674 46675 46676 # Only process if variable expands to non-empty 46677 46678 if test "x$BUILD_CXX" != x; then 46679 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 46680 46681 # First separate the path from the arguments. This will split at the first 46682 # space. 46683 complete="$BUILD_CXX" 46684 path="${complete%% *}" 46685 tmp="$complete EOL" 46686 arguments="${tmp#* }" 46687 46688 # Input might be given as Windows format, start by converting to 46689 # unix format. 46690 new_path=`$CYGPATH -u "$path"` 46691 46692 # Now try to locate executable using which 46693 new_path=`$WHICH "$new_path" 2> /dev/null` 46694 # bat and cmd files are not always considered executable in cygwin causing which 46695 # to not find them 46696 if test "x$new_path" = x \ 46697 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 46698 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 46699 new_path=`$CYGPATH -u "$path"` 46700 fi 46701 if test "x$new_path" = x; then 46702 # Oops. Which didn't find the executable. 46703 # The splitting of arguments from the executable at a space might have been incorrect, 46704 # since paths with space are more likely in Windows. Give it another try with the whole 46705 # argument. 46706 path="$complete" 46707 arguments="EOL" 46708 new_path=`$CYGPATH -u "$path"` 46709 new_path=`$WHICH "$new_path" 2> /dev/null` 46710 # bat and cmd files are not always considered executable in cygwin causing which 46711 # to not find them 46712 if test "x$new_path" = x \ 46713 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 46714 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 46715 new_path=`$CYGPATH -u "$path"` 46716 fi 46717 if test "x$new_path" = x; then 46718 # It's still not found. Now this is an unrecoverable error. 46719 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BUILD_CXX, which resolves as \"$complete\", is not found." >&5 46720 $as_echo "$as_me: The path of BUILD_CXX, which resolves as \"$complete\", is not found." >&6;} 46721 has_space=`$ECHO "$complete" | $GREP " "` 46722 if test "x$has_space" != x; then 46723 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 46724 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 46725 fi 46726 as_fn_error $? "Cannot locate the the path of BUILD_CXX" "$LINENO" 5 46727 fi 46728 fi 46729 46730 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 46731 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 46732 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 46733 # "foo.exe" is OK but "foo" is an error. 46734 # 46735 # This test is therefore slightly more accurate than "test -f" to check for file presence. 46736 # It is also a way to make sure we got the proper file name for the real test later on. 46737 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 46738 if test "x$test_shortpath" = x; then 46739 # Short path failed, file does not exist as specified. 46740 # Try adding .exe or .cmd 46741 if test -f "${new_path}.exe"; then 46742 input_to_shortpath="${new_path}.exe" 46743 elif test -f "${new_path}.cmd"; then 46744 input_to_shortpath="${new_path}.cmd" 46745 else 46746 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BUILD_CXX, which resolves as \"$new_path\", is invalid." >&5 46747 $as_echo "$as_me: The path of BUILD_CXX, which resolves as \"$new_path\", is invalid." >&6;} 46748 { $as_echo "$as_me:${as_lineno-$LINENO}: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&5 46749 $as_echo "$as_me: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&6;} 46750 as_fn_error $? "Cannot locate the the path of BUILD_CXX" "$LINENO" 5 46751 fi 46752 else 46753 input_to_shortpath="$new_path" 46754 fi 46755 46756 # Call helper function which possibly converts this using DOS-style short mode. 46757 # If so, the updated path is stored in $new_path. 46758 new_path="$input_to_shortpath" 46759 46760 input_path="$input_to_shortpath" 46761 # Check if we need to convert this using DOS-style short mode. If the path 46762 # contains just simple characters, use it. Otherwise (spaces, weird characters), 46763 # take no chances and rewrite it. 46764 # Note: m4 eats our [], so we need to use [ and ] instead. 46765 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 46766 if test "x$has_forbidden_chars" != x; then 46767 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 46768 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 46769 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 46770 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 46771 # Going to short mode and back again did indeed matter. Since short mode is 46772 # case insensitive, let's make it lowercase to improve readability. 46773 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 46774 # Now convert it back to Unix-style (cygpath) 46775 input_path=`$CYGPATH -u "$shortmode_path"` 46776 new_path="$input_path" 46777 fi 46778 fi 46779 46780 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 46781 if test "x$test_cygdrive_prefix" = x; then 46782 # As a simple fix, exclude /usr/bin since it's not a real path. 46783 if test "x`$ECHO $input_to_shortpath | $GREP ^/usr/bin/`" = x; then 46784 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 46785 # a path prefixed by /cygdrive for fixpath to work. 46786 new_path="$CYGWIN_ROOT_PATH$input_path" 46787 fi 46788 fi 46789 46790 # remove trailing .exe if any 46791 new_path="${new_path/%.exe/}" 46792 46793 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 46794 46795 # First separate the path from the arguments. This will split at the first 46796 # space. 46797 complete="$BUILD_CXX" 46798 path="${complete%% *}" 46799 tmp="$complete EOL" 46800 arguments="${tmp#* }" 46801 46802 # Input might be given as Windows format, start by converting to 46803 # unix format. 46804 new_path="$path" 46805 46806 windows_path="$new_path" 46807 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 46808 unix_path=`$CYGPATH -u "$windows_path"` 46809 new_path="$unix_path" 46810 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 46811 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 46812 new_path="$unix_path" 46813 fi 46814 46815 46816 # Now try to locate executable using which 46817 new_path=`$WHICH "$new_path" 2> /dev/null` 46818 46819 if test "x$new_path" = x; then 46820 # Oops. Which didn't find the executable. 46821 # The splitting of arguments from the executable at a space might have been incorrect, 46822 # since paths with space are more likely in Windows. Give it another try with the whole 46823 # argument. 46824 path="$complete" 46825 arguments="EOL" 46826 new_path="$path" 46827 46828 windows_path="$new_path" 46829 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 46830 unix_path=`$CYGPATH -u "$windows_path"` 46831 new_path="$unix_path" 46832 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 46833 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 46834 new_path="$unix_path" 46835 fi 46836 46837 46838 new_path=`$WHICH "$new_path" 2> /dev/null` 46839 # bat and cmd files are not always considered executable in MSYS causing which 46840 # to not find them 46841 if test "x$new_path" = x \ 46842 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 46843 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 46844 new_path="$path" 46845 46846 windows_path="$new_path" 46847 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 46848 unix_path=`$CYGPATH -u "$windows_path"` 46849 new_path="$unix_path" 46850 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 46851 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 46852 new_path="$unix_path" 46853 fi 46854 46855 fi 46856 46857 if test "x$new_path" = x; then 46858 # It's still not found. Now this is an unrecoverable error. 46859 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BUILD_CXX, which resolves as \"$complete\", is not found." >&5 46860 $as_echo "$as_me: The path of BUILD_CXX, which resolves as \"$complete\", is not found." >&6;} 46861 has_space=`$ECHO "$complete" | $GREP " "` 46862 if test "x$has_space" != x; then 46863 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 46864 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 46865 fi 46866 as_fn_error $? "Cannot locate the the path of BUILD_CXX" "$LINENO" 5 46867 fi 46868 fi 46869 46870 # Now new_path has a complete unix path to the binary 46871 if test "x`$ECHO $new_path | $GREP ^/bin/`" != x; then 46872 # Keep paths in /bin as-is, but remove trailing .exe if any 46873 new_path="${new_path/%.exe/}" 46874 # Do not save /bin paths to all_fixpath_prefixes! 46875 else 46876 # Not in mixed or Windows style, start by that. 46877 new_path=`cmd //c echo $new_path` 46878 46879 input_path="$new_path" 46880 # Check if we need to convert this using DOS-style short mode. If the path 46881 # contains just simple characters, use it. Otherwise (spaces, weird characters), 46882 # take no chances and rewrite it. 46883 # Note: m4 eats our [], so we need to use [ and ] instead. 46884 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 46885 if test "x$has_forbidden_chars" != x; then 46886 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 46887 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 46888 fi 46889 46890 # Output is in $new_path 46891 46892 windows_path="$new_path" 46893 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 46894 unix_path=`$CYGPATH -u "$windows_path"` 46895 new_path="$unix_path" 46896 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 46897 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 46898 new_path="$unix_path" 46899 fi 46900 46901 # remove trailing .exe if any 46902 new_path="${new_path/%.exe/}" 46903 46904 # Save the first 10 bytes of this path to the storage, so fixpath can work. 46905 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 46906 fi 46907 46908 else 46909 # We're on a unix platform. Hooray! :) 46910 # First separate the path from the arguments. This will split at the first 46911 # space. 46912 complete="$BUILD_CXX" 46913 path="${complete%% *}" 46914 tmp="$complete EOL" 46915 arguments="${tmp#* }" 46916 46917 # Cannot rely on the command "which" here since it doesn't always work. 46918 is_absolute_path=`$ECHO "$path" | $GREP ^/` 46919 if test -z "$is_absolute_path"; then 46920 # Path to executable is not absolute. Find it. 46921 IFS_save="$IFS" 46922 IFS=: 46923 for p in $PATH; do 46924 if test -f "$p/$path" && test -x "$p/$path"; then 46925 new_path="$p/$path" 46926 break 46927 fi 46928 done 46929 IFS="$IFS_save" 46930 else 46931 # This is an absolute path, we can use it without further modifications. 46932 new_path="$path" 46933 fi 46934 46935 if test "x$new_path" = x; then 46936 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BUILD_CXX, which resolves as \"$complete\", is not found." >&5 46937 $as_echo "$as_me: The path of BUILD_CXX, which resolves as \"$complete\", is not found." >&6;} 46938 has_space=`$ECHO "$complete" | $GREP " "` 46939 if test "x$has_space" != x; then 46940 { $as_echo "$as_me:${as_lineno-$LINENO}: This might be caused by spaces in the path, which is not allowed." >&5 46941 $as_echo "$as_me: This might be caused by spaces in the path, which is not allowed." >&6;} 46942 fi 46943 as_fn_error $? "Cannot locate the the path of BUILD_CXX" "$LINENO" 5 46944 fi 46945 fi 46946 46947 # Now join together the path and the arguments once again 46948 if test "x$arguments" != xEOL; then 46949 new_complete="$new_path ${arguments% *}" 46950 else 46951 new_complete="$new_path" 46952 fi 46953 46954 if test "x$complete" != "x$new_complete"; then 46955 BUILD_CXX="$new_complete" 46956 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BUILD_CXX to \"$new_complete\"" >&5 46957 $as_echo "$as_me: Rewriting BUILD_CXX to \"$new_complete\"" >&6;} 46958 fi 46959 fi 46960 46961 46962 46963 # Publish this variable in the help. 46964 46965 46966 if [ -z "${BUILD_NM+x}" ]; then 46967 # The variable is not set by user, try to locate tool using the code snippet 46968 for ac_prog in nm gcc-nm 46969 do 46970 # Extract the first word of "$ac_prog", so it can be a program name with args. 46971 set dummy $ac_prog; ac_word=$2 46972 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 46973 $as_echo_n "checking for $ac_word... " >&6; } 46974 if ${ac_cv_path_BUILD_NM+:} false; then : 46975 $as_echo_n "(cached) " >&6 46976 else 46977 case $BUILD_NM in 46978 [\\/]* | ?:[\\/]*) 46979 ac_cv_path_BUILD_NM="$BUILD_NM" # Let the user override the test with a path. 46980 ;; 46981 *) 46982 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 46983 for as_dir in $PATH 46984 do 46985 IFS=$as_save_IFS 46986 test -z "$as_dir" && as_dir=. 46987 for ac_exec_ext in '' $ac_executable_extensions; do 46988 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 46989 ac_cv_path_BUILD_NM="$as_dir/$ac_word$ac_exec_ext" 46990 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 46991 break 2 46992 fi 46993 done 46994 done 46995 IFS=$as_save_IFS 46996 46997 ;; 46998 esac 46999 fi 47000 BUILD_NM=$ac_cv_path_BUILD_NM 47001 if test -n "$BUILD_NM"; then 47002 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BUILD_NM" >&5 47003 $as_echo "$BUILD_NM" >&6; } 47004 else 47005 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 47006 $as_echo "no" >&6; } 47007 fi 47008 47009 47010 test -n "$BUILD_NM" && break 47011 done 47012 47013 else 47014 # The variable is set, but is it from the command line or the environment? 47015 47016 # Try to remove the string !BUILD_NM! from our list. 47017 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!BUILD_NM!/} 47018 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 47019 # If it failed, the variable was not from the command line. Ignore it, 47020 # but warn the user (except for BASH, which is always set by the calling BASH). 47021 if test "xBUILD_NM" != xBASH; then 47022 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of BUILD_NM from the environment. Use command line variables instead." >&5 47023 $as_echo "$as_me: WARNING: Ignoring value of BUILD_NM from the environment. Use command line variables instead." >&2;} 47024 fi 47025 # Try to locate tool using the code snippet 47026 for ac_prog in nm gcc-nm 47027 do 47028 # Extract the first word of "$ac_prog", so it can be a program name with args. 47029 set dummy $ac_prog; ac_word=$2 47030 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 47031 $as_echo_n "checking for $ac_word... " >&6; } 47032 if ${ac_cv_path_BUILD_NM+:} false; then : 47033 $as_echo_n "(cached) " >&6 47034 else 47035 case $BUILD_NM in 47036 [\\/]* | ?:[\\/]*) 47037 ac_cv_path_BUILD_NM="$BUILD_NM" # Let the user override the test with a path. 47038 ;; 47039 *) 47040 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 47041 for as_dir in $PATH 47042 do 47043 IFS=$as_save_IFS 47044 test -z "$as_dir" && as_dir=. 47045 for ac_exec_ext in '' $ac_executable_extensions; do 47046 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 47047 ac_cv_path_BUILD_NM="$as_dir/$ac_word$ac_exec_ext" 47048 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 47049 break 2 47050 fi 47051 done 47052 done 47053 IFS=$as_save_IFS 47054 47055 ;; 47056 esac 47057 fi 47058 BUILD_NM=$ac_cv_path_BUILD_NM 47059 if test -n "$BUILD_NM"; then 47060 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BUILD_NM" >&5 47061 $as_echo "$BUILD_NM" >&6; } 47062 else 47063 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 47064 $as_echo "no" >&6; } 47065 fi 47066 47067 47068 test -n "$BUILD_NM" && break 47069 done 47070 47071 else 47072 # If it succeeded, then it was overridden by the user. We will use it 47073 # for the tool. 47074 47075 # First remove it from the list of overridden variables, so we can test 47076 # for unknown variables in the end. 47077 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 47078 47079 # Check if we try to supply an empty value 47080 if test "x$BUILD_NM" = x; then 47081 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool BUILD_NM= (no value)" >&5 47082 $as_echo "$as_me: Setting user supplied tool BUILD_NM= (no value)" >&6;} 47083 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for BUILD_NM" >&5 47084 $as_echo_n "checking for BUILD_NM... " >&6; } 47085 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 47086 $as_echo "disabled" >&6; } 47087 else 47088 # Check if the provided tool contains a complete path. 47089 tool_specified="$BUILD_NM" 47090 tool_basename="${tool_specified##*/}" 47091 if test "x$tool_basename" = "x$tool_specified"; then 47092 # A command without a complete path is provided, search $PATH. 47093 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool BUILD_NM=$tool_basename" >&5 47094 $as_echo "$as_me: Will search for user supplied tool BUILD_NM=$tool_basename" >&6;} 47095 # Extract the first word of "$tool_basename", so it can be a program name with args. 47096 set dummy $tool_basename; ac_word=$2 47097 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 47098 $as_echo_n "checking for $ac_word... " >&6; } 47099 if ${ac_cv_path_BUILD_NM+:} false; then : 47100 $as_echo_n "(cached) " >&6 47101 else 47102 case $BUILD_NM in 47103 [\\/]* | ?:[\\/]*) 47104 ac_cv_path_BUILD_NM="$BUILD_NM" # Let the user override the test with a path. 47105 ;; 47106 *) 47107 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 47108 for as_dir in $PATH 47109 do 47110 IFS=$as_save_IFS 47111 test -z "$as_dir" && as_dir=. 47112 for ac_exec_ext in '' $ac_executable_extensions; do 47113 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 47114 ac_cv_path_BUILD_NM="$as_dir/$ac_word$ac_exec_ext" 47115 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 47116 break 2 47117 fi 47118 done 47119 done 47120 IFS=$as_save_IFS 47121 47122 ;; 47123 esac 47124 fi 47125 BUILD_NM=$ac_cv_path_BUILD_NM 47126 if test -n "$BUILD_NM"; then 47127 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BUILD_NM" >&5 47128 $as_echo "$BUILD_NM" >&6; } 47129 else 47130 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 47131 $as_echo "no" >&6; } 47132 fi 47133 47134 47135 if test "x$BUILD_NM" = x; then 47136 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 47137 fi 47138 else 47139 # Otherwise we believe it is a complete path. Use it as it is. 47140 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool BUILD_NM=$tool_specified" >&5 47141 $as_echo "$as_me: Will use user supplied tool BUILD_NM=$tool_specified" >&6;} 47142 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for BUILD_NM" >&5 47143 $as_echo_n "checking for BUILD_NM... " >&6; } 47144 if test ! -x "$tool_specified"; then 47145 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 47146 $as_echo "not found" >&6; } 47147 as_fn_error $? "User supplied tool BUILD_NM=$tool_specified does not exist or is not executable" "$LINENO" 5 47148 fi 47149 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 47150 $as_echo "$tool_specified" >&6; } 47151 fi 47152 fi 47153 fi 47154 47155 fi 47156 47157 47158 47159 # Only process if variable expands to non-empty 47160 47161 if test "x$BUILD_NM" != x; then 47162 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 47163 47164 # First separate the path from the arguments. This will split at the first 47165 # space. 47166 complete="$BUILD_NM" 47167 path="${complete%% *}" 47168 tmp="$complete EOL" 47169 arguments="${tmp#* }" 47170 47171 # Input might be given as Windows format, start by converting to 47172 # unix format. 47173 new_path=`$CYGPATH -u "$path"` 47174 47175 # Now try to locate executable using which 47176 new_path=`$WHICH "$new_path" 2> /dev/null` 47177 # bat and cmd files are not always considered executable in cygwin causing which 47178 # to not find them 47179 if test "x$new_path" = x \ 47180 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 47181 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 47182 new_path=`$CYGPATH -u "$path"` 47183 fi 47184 if test "x$new_path" = x; then 47185 # Oops. Which didn't find the executable. 47186 # The splitting of arguments from the executable at a space might have been incorrect, 47187 # since paths with space are more likely in Windows. Give it another try with the whole 47188 # argument. 47189 path="$complete" 47190 arguments="EOL" 47191 new_path=`$CYGPATH -u "$path"` 47192 new_path=`$WHICH "$new_path" 2> /dev/null` 47193 # bat and cmd files are not always considered executable in cygwin causing which 47194 # to not find them 47195 if test "x$new_path" = x \ 47196 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 47197 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 47198 new_path=`$CYGPATH -u "$path"` 47199 fi 47200 if test "x$new_path" = x; then 47201 # It's still not found. Now this is an unrecoverable error. 47202 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BUILD_NM, which resolves as \"$complete\", is not found." >&5 47203 $as_echo "$as_me: The path of BUILD_NM, which resolves as \"$complete\", is not found." >&6;} 47204 has_space=`$ECHO "$complete" | $GREP " "` 47205 if test "x$has_space" != x; then 47206 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 47207 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 47208 fi 47209 as_fn_error $? "Cannot locate the the path of BUILD_NM" "$LINENO" 5 47210 fi 47211 fi 47212 47213 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 47214 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 47215 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 47216 # "foo.exe" is OK but "foo" is an error. 47217 # 47218 # This test is therefore slightly more accurate than "test -f" to check for file presence. 47219 # It is also a way to make sure we got the proper file name for the real test later on. 47220 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 47221 if test "x$test_shortpath" = x; then 47222 # Short path failed, file does not exist as specified. 47223 # Try adding .exe or .cmd 47224 if test -f "${new_path}.exe"; then 47225 input_to_shortpath="${new_path}.exe" 47226 elif test -f "${new_path}.cmd"; then 47227 input_to_shortpath="${new_path}.cmd" 47228 else 47229 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BUILD_NM, which resolves as \"$new_path\", is invalid." >&5 47230 $as_echo "$as_me: The path of BUILD_NM, which resolves as \"$new_path\", is invalid." >&6;} 47231 { $as_echo "$as_me:${as_lineno-$LINENO}: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&5 47232 $as_echo "$as_me: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&6;} 47233 as_fn_error $? "Cannot locate the the path of BUILD_NM" "$LINENO" 5 47234 fi 47235 else 47236 input_to_shortpath="$new_path" 47237 fi 47238 47239 # Call helper function which possibly converts this using DOS-style short mode. 47240 # If so, the updated path is stored in $new_path. 47241 new_path="$input_to_shortpath" 47242 47243 input_path="$input_to_shortpath" 47244 # Check if we need to convert this using DOS-style short mode. If the path 47245 # contains just simple characters, use it. Otherwise (spaces, weird characters), 47246 # take no chances and rewrite it. 47247 # Note: m4 eats our [], so we need to use [ and ] instead. 47248 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 47249 if test "x$has_forbidden_chars" != x; then 47250 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 47251 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 47252 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 47253 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 47254 # Going to short mode and back again did indeed matter. Since short mode is 47255 # case insensitive, let's make it lowercase to improve readability. 47256 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 47257 # Now convert it back to Unix-style (cygpath) 47258 input_path=`$CYGPATH -u "$shortmode_path"` 47259 new_path="$input_path" 47260 fi 47261 fi 47262 47263 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 47264 if test "x$test_cygdrive_prefix" = x; then 47265 # As a simple fix, exclude /usr/bin since it's not a real path. 47266 if test "x`$ECHO $input_to_shortpath | $GREP ^/usr/bin/`" = x; then 47267 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 47268 # a path prefixed by /cygdrive for fixpath to work. 47269 new_path="$CYGWIN_ROOT_PATH$input_path" 47270 fi 47271 fi 47272 47273 # remove trailing .exe if any 47274 new_path="${new_path/%.exe/}" 47275 47276 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 47277 47278 # First separate the path from the arguments. This will split at the first 47279 # space. 47280 complete="$BUILD_NM" 47281 path="${complete%% *}" 47282 tmp="$complete EOL" 47283 arguments="${tmp#* }" 47284 47285 # Input might be given as Windows format, start by converting to 47286 # unix format. 47287 new_path="$path" 47288 47289 windows_path="$new_path" 47290 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 47291 unix_path=`$CYGPATH -u "$windows_path"` 47292 new_path="$unix_path" 47293 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 47294 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 47295 new_path="$unix_path" 47296 fi 47297 47298 47299 # Now try to locate executable using which 47300 new_path=`$WHICH "$new_path" 2> /dev/null` 47301 47302 if test "x$new_path" = x; then 47303 # Oops. Which didn't find the executable. 47304 # The splitting of arguments from the executable at a space might have been incorrect, 47305 # since paths with space are more likely in Windows. Give it another try with the whole 47306 # argument. 47307 path="$complete" 47308 arguments="EOL" 47309 new_path="$path" 47310 47311 windows_path="$new_path" 47312 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 47313 unix_path=`$CYGPATH -u "$windows_path"` 47314 new_path="$unix_path" 47315 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 47316 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 47317 new_path="$unix_path" 47318 fi 47319 47320 47321 new_path=`$WHICH "$new_path" 2> /dev/null` 47322 # bat and cmd files are not always considered executable in MSYS causing which 47323 # to not find them 47324 if test "x$new_path" = x \ 47325 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 47326 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 47327 new_path="$path" 47328 47329 windows_path="$new_path" 47330 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 47331 unix_path=`$CYGPATH -u "$windows_path"` 47332 new_path="$unix_path" 47333 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 47334 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 47335 new_path="$unix_path" 47336 fi 47337 47338 fi 47339 47340 if test "x$new_path" = x; then 47341 # It's still not found. Now this is an unrecoverable error. 47342 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BUILD_NM, which resolves as \"$complete\", is not found." >&5 47343 $as_echo "$as_me: The path of BUILD_NM, which resolves as \"$complete\", is not found." >&6;} 47344 has_space=`$ECHO "$complete" | $GREP " "` 47345 if test "x$has_space" != x; then 47346 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 47347 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 47348 fi 47349 as_fn_error $? "Cannot locate the the path of BUILD_NM" "$LINENO" 5 47350 fi 47351 fi 47352 47353 # Now new_path has a complete unix path to the binary 47354 if test "x`$ECHO $new_path | $GREP ^/bin/`" != x; then 47355 # Keep paths in /bin as-is, but remove trailing .exe if any 47356 new_path="${new_path/%.exe/}" 47357 # Do not save /bin paths to all_fixpath_prefixes! 47358 else 47359 # Not in mixed or Windows style, start by that. 47360 new_path=`cmd //c echo $new_path` 47361 47362 input_path="$new_path" 47363 # Check if we need to convert this using DOS-style short mode. If the path 47364 # contains just simple characters, use it. Otherwise (spaces, weird characters), 47365 # take no chances and rewrite it. 47366 # Note: m4 eats our [], so we need to use [ and ] instead. 47367 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 47368 if test "x$has_forbidden_chars" != x; then 47369 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 47370 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 47371 fi 47372 47373 # Output is in $new_path 47374 47375 windows_path="$new_path" 47376 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 47377 unix_path=`$CYGPATH -u "$windows_path"` 47378 new_path="$unix_path" 47379 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 47380 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 47381 new_path="$unix_path" 47382 fi 47383 47384 # remove trailing .exe if any 47385 new_path="${new_path/%.exe/}" 47386 47387 # Save the first 10 bytes of this path to the storage, so fixpath can work. 47388 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 47389 fi 47390 47391 else 47392 # We're on a unix platform. Hooray! :) 47393 # First separate the path from the arguments. This will split at the first 47394 # space. 47395 complete="$BUILD_NM" 47396 path="${complete%% *}" 47397 tmp="$complete EOL" 47398 arguments="${tmp#* }" 47399 47400 # Cannot rely on the command "which" here since it doesn't always work. 47401 is_absolute_path=`$ECHO "$path" | $GREP ^/` 47402 if test -z "$is_absolute_path"; then 47403 # Path to executable is not absolute. Find it. 47404 IFS_save="$IFS" 47405 IFS=: 47406 for p in $PATH; do 47407 if test -f "$p/$path" && test -x "$p/$path"; then 47408 new_path="$p/$path" 47409 break 47410 fi 47411 done 47412 IFS="$IFS_save" 47413 else 47414 # This is an absolute path, we can use it without further modifications. 47415 new_path="$path" 47416 fi 47417 47418 if test "x$new_path" = x; then 47419 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BUILD_NM, which resolves as \"$complete\", is not found." >&5 47420 $as_echo "$as_me: The path of BUILD_NM, which resolves as \"$complete\", is not found." >&6;} 47421 has_space=`$ECHO "$complete" | $GREP " "` 47422 if test "x$has_space" != x; then 47423 { $as_echo "$as_me:${as_lineno-$LINENO}: This might be caused by spaces in the path, which is not allowed." >&5 47424 $as_echo "$as_me: This might be caused by spaces in the path, which is not allowed." >&6;} 47425 fi 47426 as_fn_error $? "Cannot locate the the path of BUILD_NM" "$LINENO" 5 47427 fi 47428 fi 47429 47430 # Now join together the path and the arguments once again 47431 if test "x$arguments" != xEOL; then 47432 new_complete="$new_path ${arguments% *}" 47433 else 47434 new_complete="$new_path" 47435 fi 47436 47437 if test "x$complete" != "x$new_complete"; then 47438 BUILD_NM="$new_complete" 47439 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BUILD_NM to \"$new_complete\"" >&5 47440 $as_echo "$as_me: Rewriting BUILD_NM to \"$new_complete\"" >&6;} 47441 fi 47442 fi 47443 47444 47445 47446 # Publish this variable in the help. 47447 47448 47449 if [ -z "${BUILD_AR+x}" ]; then 47450 # The variable is not set by user, try to locate tool using the code snippet 47451 for ac_prog in ar gcc-ar 47452 do 47453 # Extract the first word of "$ac_prog", so it can be a program name with args. 47454 set dummy $ac_prog; ac_word=$2 47455 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 47456 $as_echo_n "checking for $ac_word... " >&6; } 47457 if ${ac_cv_path_BUILD_AR+:} false; then : 47458 $as_echo_n "(cached) " >&6 47459 else 47460 case $BUILD_AR in 47461 [\\/]* | ?:[\\/]*) 47462 ac_cv_path_BUILD_AR="$BUILD_AR" # Let the user override the test with a path. 47463 ;; 47464 *) 47465 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 47466 for as_dir in $PATH 47467 do 47468 IFS=$as_save_IFS 47469 test -z "$as_dir" && as_dir=. 47470 for ac_exec_ext in '' $ac_executable_extensions; do 47471 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 47472 ac_cv_path_BUILD_AR="$as_dir/$ac_word$ac_exec_ext" 47473 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 47474 break 2 47475 fi 47476 done 47477 done 47478 IFS=$as_save_IFS 47479 47480 ;; 47481 esac 47482 fi 47483 BUILD_AR=$ac_cv_path_BUILD_AR 47484 if test -n "$BUILD_AR"; then 47485 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BUILD_AR" >&5 47486 $as_echo "$BUILD_AR" >&6; } 47487 else 47488 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 47489 $as_echo "no" >&6; } 47490 fi 47491 47492 47493 test -n "$BUILD_AR" && break 47494 done 47495 47496 else 47497 # The variable is set, but is it from the command line or the environment? 47498 47499 # Try to remove the string !BUILD_AR! from our list. 47500 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!BUILD_AR!/} 47501 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 47502 # If it failed, the variable was not from the command line. Ignore it, 47503 # but warn the user (except for BASH, which is always set by the calling BASH). 47504 if test "xBUILD_AR" != xBASH; then 47505 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of BUILD_AR from the environment. Use command line variables instead." >&5 47506 $as_echo "$as_me: WARNING: Ignoring value of BUILD_AR from the environment. Use command line variables instead." >&2;} 47507 fi 47508 # Try to locate tool using the code snippet 47509 for ac_prog in ar gcc-ar 47510 do 47511 # Extract the first word of "$ac_prog", so it can be a program name with args. 47512 set dummy $ac_prog; ac_word=$2 47513 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 47514 $as_echo_n "checking for $ac_word... " >&6; } 47515 if ${ac_cv_path_BUILD_AR+:} false; then : 47516 $as_echo_n "(cached) " >&6 47517 else 47518 case $BUILD_AR in 47519 [\\/]* | ?:[\\/]*) 47520 ac_cv_path_BUILD_AR="$BUILD_AR" # Let the user override the test with a path. 47521 ;; 47522 *) 47523 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 47524 for as_dir in $PATH 47525 do 47526 IFS=$as_save_IFS 47527 test -z "$as_dir" && as_dir=. 47528 for ac_exec_ext in '' $ac_executable_extensions; do 47529 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 47530 ac_cv_path_BUILD_AR="$as_dir/$ac_word$ac_exec_ext" 47531 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 47532 break 2 47533 fi 47534 done 47535 done 47536 IFS=$as_save_IFS 47537 47538 ;; 47539 esac 47540 fi 47541 BUILD_AR=$ac_cv_path_BUILD_AR 47542 if test -n "$BUILD_AR"; then 47543 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BUILD_AR" >&5 47544 $as_echo "$BUILD_AR" >&6; } 47545 else 47546 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 47547 $as_echo "no" >&6; } 47548 fi 47549 47550 47551 test -n "$BUILD_AR" && break 47552 done 47553 47554 else 47555 # If it succeeded, then it was overridden by the user. We will use it 47556 # for the tool. 47557 47558 # First remove it from the list of overridden variables, so we can test 47559 # for unknown variables in the end. 47560 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 47561 47562 # Check if we try to supply an empty value 47563 if test "x$BUILD_AR" = x; then 47564 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool BUILD_AR= (no value)" >&5 47565 $as_echo "$as_me: Setting user supplied tool BUILD_AR= (no value)" >&6;} 47566 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for BUILD_AR" >&5 47567 $as_echo_n "checking for BUILD_AR... " >&6; } 47568 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 47569 $as_echo "disabled" >&6; } 47570 else 47571 # Check if the provided tool contains a complete path. 47572 tool_specified="$BUILD_AR" 47573 tool_basename="${tool_specified##*/}" 47574 if test "x$tool_basename" = "x$tool_specified"; then 47575 # A command without a complete path is provided, search $PATH. 47576 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool BUILD_AR=$tool_basename" >&5 47577 $as_echo "$as_me: Will search for user supplied tool BUILD_AR=$tool_basename" >&6;} 47578 # Extract the first word of "$tool_basename", so it can be a program name with args. 47579 set dummy $tool_basename; ac_word=$2 47580 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 47581 $as_echo_n "checking for $ac_word... " >&6; } 47582 if ${ac_cv_path_BUILD_AR+:} false; then : 47583 $as_echo_n "(cached) " >&6 47584 else 47585 case $BUILD_AR in 47586 [\\/]* | ?:[\\/]*) 47587 ac_cv_path_BUILD_AR="$BUILD_AR" # Let the user override the test with a path. 47588 ;; 47589 *) 47590 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 47591 for as_dir in $PATH 47592 do 47593 IFS=$as_save_IFS 47594 test -z "$as_dir" && as_dir=. 47595 for ac_exec_ext in '' $ac_executable_extensions; do 47596 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 47597 ac_cv_path_BUILD_AR="$as_dir/$ac_word$ac_exec_ext" 47598 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 47599 break 2 47600 fi 47601 done 47602 done 47603 IFS=$as_save_IFS 47604 47605 ;; 47606 esac 47607 fi 47608 BUILD_AR=$ac_cv_path_BUILD_AR 47609 if test -n "$BUILD_AR"; then 47610 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BUILD_AR" >&5 47611 $as_echo "$BUILD_AR" >&6; } 47612 else 47613 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 47614 $as_echo "no" >&6; } 47615 fi 47616 47617 47618 if test "x$BUILD_AR" = x; then 47619 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 47620 fi 47621 else 47622 # Otherwise we believe it is a complete path. Use it as it is. 47623 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool BUILD_AR=$tool_specified" >&5 47624 $as_echo "$as_me: Will use user supplied tool BUILD_AR=$tool_specified" >&6;} 47625 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for BUILD_AR" >&5 47626 $as_echo_n "checking for BUILD_AR... " >&6; } 47627 if test ! -x "$tool_specified"; then 47628 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 47629 $as_echo "not found" >&6; } 47630 as_fn_error $? "User supplied tool BUILD_AR=$tool_specified does not exist or is not executable" "$LINENO" 5 47631 fi 47632 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 47633 $as_echo "$tool_specified" >&6; } 47634 fi 47635 fi 47636 fi 47637 47638 fi 47639 47640 47641 47642 # Only process if variable expands to non-empty 47643 47644 if test "x$BUILD_AR" != x; then 47645 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 47646 47647 # First separate the path from the arguments. This will split at the first 47648 # space. 47649 complete="$BUILD_AR" 47650 path="${complete%% *}" 47651 tmp="$complete EOL" 47652 arguments="${tmp#* }" 47653 47654 # Input might be given as Windows format, start by converting to 47655 # unix format. 47656 new_path=`$CYGPATH -u "$path"` 47657 47658 # Now try to locate executable using which 47659 new_path=`$WHICH "$new_path" 2> /dev/null` 47660 # bat and cmd files are not always considered executable in cygwin causing which 47661 # to not find them 47662 if test "x$new_path" = x \ 47663 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 47664 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 47665 new_path=`$CYGPATH -u "$path"` 47666 fi 47667 if test "x$new_path" = x; then 47668 # Oops. Which didn't find the executable. 47669 # The splitting of arguments from the executable at a space might have been incorrect, 47670 # since paths with space are more likely in Windows. Give it another try with the whole 47671 # argument. 47672 path="$complete" 47673 arguments="EOL" 47674 new_path=`$CYGPATH -u "$path"` 47675 new_path=`$WHICH "$new_path" 2> /dev/null` 47676 # bat and cmd files are not always considered executable in cygwin causing which 47677 # to not find them 47678 if test "x$new_path" = x \ 47679 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 47680 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 47681 new_path=`$CYGPATH -u "$path"` 47682 fi 47683 if test "x$new_path" = x; then 47684 # It's still not found. Now this is an unrecoverable error. 47685 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BUILD_AR, which resolves as \"$complete\", is not found." >&5 47686 $as_echo "$as_me: The path of BUILD_AR, which resolves as \"$complete\", is not found." >&6;} 47687 has_space=`$ECHO "$complete" | $GREP " "` 47688 if test "x$has_space" != x; then 47689 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 47690 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 47691 fi 47692 as_fn_error $? "Cannot locate the the path of BUILD_AR" "$LINENO" 5 47693 fi 47694 fi 47695 47696 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 47697 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 47698 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 47699 # "foo.exe" is OK but "foo" is an error. 47700 # 47701 # This test is therefore slightly more accurate than "test -f" to check for file presence. 47702 # It is also a way to make sure we got the proper file name for the real test later on. 47703 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 47704 if test "x$test_shortpath" = x; then 47705 # Short path failed, file does not exist as specified. 47706 # Try adding .exe or .cmd 47707 if test -f "${new_path}.exe"; then 47708 input_to_shortpath="${new_path}.exe" 47709 elif test -f "${new_path}.cmd"; then 47710 input_to_shortpath="${new_path}.cmd" 47711 else 47712 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BUILD_AR, which resolves as \"$new_path\", is invalid." >&5 47713 $as_echo "$as_me: The path of BUILD_AR, which resolves as \"$new_path\", is invalid." >&6;} 47714 { $as_echo "$as_me:${as_lineno-$LINENO}: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&5 47715 $as_echo "$as_me: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&6;} 47716 as_fn_error $? "Cannot locate the the path of BUILD_AR" "$LINENO" 5 47717 fi 47718 else 47719 input_to_shortpath="$new_path" 47720 fi 47721 47722 # Call helper function which possibly converts this using DOS-style short mode. 47723 # If so, the updated path is stored in $new_path. 47724 new_path="$input_to_shortpath" 47725 47726 input_path="$input_to_shortpath" 47727 # Check if we need to convert this using DOS-style short mode. If the path 47728 # contains just simple characters, use it. Otherwise (spaces, weird characters), 47729 # take no chances and rewrite it. 47730 # Note: m4 eats our [], so we need to use [ and ] instead. 47731 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 47732 if test "x$has_forbidden_chars" != x; then 47733 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 47734 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 47735 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 47736 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 47737 # Going to short mode and back again did indeed matter. Since short mode is 47738 # case insensitive, let's make it lowercase to improve readability. 47739 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 47740 # Now convert it back to Unix-style (cygpath) 47741 input_path=`$CYGPATH -u "$shortmode_path"` 47742 new_path="$input_path" 47743 fi 47744 fi 47745 47746 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 47747 if test "x$test_cygdrive_prefix" = x; then 47748 # As a simple fix, exclude /usr/bin since it's not a real path. 47749 if test "x`$ECHO $input_to_shortpath | $GREP ^/usr/bin/`" = x; then 47750 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 47751 # a path prefixed by /cygdrive for fixpath to work. 47752 new_path="$CYGWIN_ROOT_PATH$input_path" 47753 fi 47754 fi 47755 47756 # remove trailing .exe if any 47757 new_path="${new_path/%.exe/}" 47758 47759 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 47760 47761 # First separate the path from the arguments. This will split at the first 47762 # space. 47763 complete="$BUILD_AR" 47764 path="${complete%% *}" 47765 tmp="$complete EOL" 47766 arguments="${tmp#* }" 47767 47768 # Input might be given as Windows format, start by converting to 47769 # unix format. 47770 new_path="$path" 47771 47772 windows_path="$new_path" 47773 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 47774 unix_path=`$CYGPATH -u "$windows_path"` 47775 new_path="$unix_path" 47776 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 47777 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 47778 new_path="$unix_path" 47779 fi 47780 47781 47782 # Now try to locate executable using which 47783 new_path=`$WHICH "$new_path" 2> /dev/null` 47784 47785 if test "x$new_path" = x; then 47786 # Oops. Which didn't find the executable. 47787 # The splitting of arguments from the executable at a space might have been incorrect, 47788 # since paths with space are more likely in Windows. Give it another try with the whole 47789 # argument. 47790 path="$complete" 47791 arguments="EOL" 47792 new_path="$path" 47793 47794 windows_path="$new_path" 47795 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 47796 unix_path=`$CYGPATH -u "$windows_path"` 47797 new_path="$unix_path" 47798 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 47799 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 47800 new_path="$unix_path" 47801 fi 47802 47803 47804 new_path=`$WHICH "$new_path" 2> /dev/null` 47805 # bat and cmd files are not always considered executable in MSYS causing which 47806 # to not find them 47807 if test "x$new_path" = x \ 47808 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 47809 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 47810 new_path="$path" 47811 47812 windows_path="$new_path" 47813 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 47814 unix_path=`$CYGPATH -u "$windows_path"` 47815 new_path="$unix_path" 47816 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 47817 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 47818 new_path="$unix_path" 47819 fi 47820 47821 fi 47822 47823 if test "x$new_path" = x; then 47824 # It's still not found. Now this is an unrecoverable error. 47825 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BUILD_AR, which resolves as \"$complete\", is not found." >&5 47826 $as_echo "$as_me: The path of BUILD_AR, which resolves as \"$complete\", is not found." >&6;} 47827 has_space=`$ECHO "$complete" | $GREP " "` 47828 if test "x$has_space" != x; then 47829 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 47830 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 47831 fi 47832 as_fn_error $? "Cannot locate the the path of BUILD_AR" "$LINENO" 5 47833 fi 47834 fi 47835 47836 # Now new_path has a complete unix path to the binary 47837 if test "x`$ECHO $new_path | $GREP ^/bin/`" != x; then 47838 # Keep paths in /bin as-is, but remove trailing .exe if any 47839 new_path="${new_path/%.exe/}" 47840 # Do not save /bin paths to all_fixpath_prefixes! 47841 else 47842 # Not in mixed or Windows style, start by that. 47843 new_path=`cmd //c echo $new_path` 47844 47845 input_path="$new_path" 47846 # Check if we need to convert this using DOS-style short mode. If the path 47847 # contains just simple characters, use it. Otherwise (spaces, weird characters), 47848 # take no chances and rewrite it. 47849 # Note: m4 eats our [], so we need to use [ and ] instead. 47850 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 47851 if test "x$has_forbidden_chars" != x; then 47852 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 47853 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 47854 fi 47855 47856 # Output is in $new_path 47857 47858 windows_path="$new_path" 47859 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 47860 unix_path=`$CYGPATH -u "$windows_path"` 47861 new_path="$unix_path" 47862 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 47863 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 47864 new_path="$unix_path" 47865 fi 47866 47867 # remove trailing .exe if any 47868 new_path="${new_path/%.exe/}" 47869 47870 # Save the first 10 bytes of this path to the storage, so fixpath can work. 47871 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 47872 fi 47873 47874 else 47875 # We're on a unix platform. Hooray! :) 47876 # First separate the path from the arguments. This will split at the first 47877 # space. 47878 complete="$BUILD_AR" 47879 path="${complete%% *}" 47880 tmp="$complete EOL" 47881 arguments="${tmp#* }" 47882 47883 # Cannot rely on the command "which" here since it doesn't always work. 47884 is_absolute_path=`$ECHO "$path" | $GREP ^/` 47885 if test -z "$is_absolute_path"; then 47886 # Path to executable is not absolute. Find it. 47887 IFS_save="$IFS" 47888 IFS=: 47889 for p in $PATH; do 47890 if test -f "$p/$path" && test -x "$p/$path"; then 47891 new_path="$p/$path" 47892 break 47893 fi 47894 done 47895 IFS="$IFS_save" 47896 else 47897 # This is an absolute path, we can use it without further modifications. 47898 new_path="$path" 47899 fi 47900 47901 if test "x$new_path" = x; then 47902 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BUILD_AR, which resolves as \"$complete\", is not found." >&5 47903 $as_echo "$as_me: The path of BUILD_AR, which resolves as \"$complete\", is not found." >&6;} 47904 has_space=`$ECHO "$complete" | $GREP " "` 47905 if test "x$has_space" != x; then 47906 { $as_echo "$as_me:${as_lineno-$LINENO}: This might be caused by spaces in the path, which is not allowed." >&5 47907 $as_echo "$as_me: This might be caused by spaces in the path, which is not allowed." >&6;} 47908 fi 47909 as_fn_error $? "Cannot locate the the path of BUILD_AR" "$LINENO" 5 47910 fi 47911 fi 47912 47913 # Now join together the path and the arguments once again 47914 if test "x$arguments" != xEOL; then 47915 new_complete="$new_path ${arguments% *}" 47916 else 47917 new_complete="$new_path" 47918 fi 47919 47920 if test "x$complete" != "x$new_complete"; then 47921 BUILD_AR="$new_complete" 47922 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BUILD_AR to \"$new_complete\"" >&5 47923 $as_echo "$as_me: Rewriting BUILD_AR to \"$new_complete\"" >&6;} 47924 fi 47925 fi 47926 47927 47928 47929 # Publish this variable in the help. 47930 47931 47932 if [ -z "${BUILD_OBJCOPY+x}" ]; then 47933 # The variable is not set by user, try to locate tool using the code snippet 47934 for ac_prog in objcopy 47935 do 47936 # Extract the first word of "$ac_prog", so it can be a program name with args. 47937 set dummy $ac_prog; ac_word=$2 47938 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 47939 $as_echo_n "checking for $ac_word... " >&6; } 47940 if ${ac_cv_path_BUILD_OBJCOPY+:} false; then : 47941 $as_echo_n "(cached) " >&6 47942 else 47943 case $BUILD_OBJCOPY in 47944 [\\/]* | ?:[\\/]*) 47945 ac_cv_path_BUILD_OBJCOPY="$BUILD_OBJCOPY" # Let the user override the test with a path. 47946 ;; 47947 *) 47948 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 47949 for as_dir in $PATH 47950 do 47951 IFS=$as_save_IFS 47952 test -z "$as_dir" && as_dir=. 47953 for ac_exec_ext in '' $ac_executable_extensions; do 47954 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 47955 ac_cv_path_BUILD_OBJCOPY="$as_dir/$ac_word$ac_exec_ext" 47956 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 47957 break 2 47958 fi 47959 done 47960 done 47961 IFS=$as_save_IFS 47962 47963 ;; 47964 esac 47965 fi 47966 BUILD_OBJCOPY=$ac_cv_path_BUILD_OBJCOPY 47967 if test -n "$BUILD_OBJCOPY"; then 47968 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BUILD_OBJCOPY" >&5 47969 $as_echo "$BUILD_OBJCOPY" >&6; } 47970 else 47971 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 47972 $as_echo "no" >&6; } 47973 fi 47974 47975 47976 test -n "$BUILD_OBJCOPY" && break 47977 done 47978 47979 else 47980 # The variable is set, but is it from the command line or the environment? 47981 47982 # Try to remove the string !BUILD_OBJCOPY! from our list. 47983 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!BUILD_OBJCOPY!/} 47984 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 47985 # If it failed, the variable was not from the command line. Ignore it, 47986 # but warn the user (except for BASH, which is always set by the calling BASH). 47987 if test "xBUILD_OBJCOPY" != xBASH; then 47988 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of BUILD_OBJCOPY from the environment. Use command line variables instead." >&5 47989 $as_echo "$as_me: WARNING: Ignoring value of BUILD_OBJCOPY from the environment. Use command line variables instead." >&2;} 47990 fi 47991 # Try to locate tool using the code snippet 47992 for ac_prog in objcopy 47993 do 47994 # Extract the first word of "$ac_prog", so it can be a program name with args. 47995 set dummy $ac_prog; ac_word=$2 47996 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 47997 $as_echo_n "checking for $ac_word... " >&6; } 47998 if ${ac_cv_path_BUILD_OBJCOPY+:} false; then : 47999 $as_echo_n "(cached) " >&6 48000 else 48001 case $BUILD_OBJCOPY in 48002 [\\/]* | ?:[\\/]*) 48003 ac_cv_path_BUILD_OBJCOPY="$BUILD_OBJCOPY" # Let the user override the test with a path. 48004 ;; 48005 *) 48006 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 48007 for as_dir in $PATH 48008 do 48009 IFS=$as_save_IFS 48010 test -z "$as_dir" && as_dir=. 48011 for ac_exec_ext in '' $ac_executable_extensions; do 48012 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 48013 ac_cv_path_BUILD_OBJCOPY="$as_dir/$ac_word$ac_exec_ext" 48014 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 48015 break 2 48016 fi 48017 done 48018 done 48019 IFS=$as_save_IFS 48020 48021 ;; 48022 esac 48023 fi 48024 BUILD_OBJCOPY=$ac_cv_path_BUILD_OBJCOPY 48025 if test -n "$BUILD_OBJCOPY"; then 48026 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BUILD_OBJCOPY" >&5 48027 $as_echo "$BUILD_OBJCOPY" >&6; } 48028 else 48029 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 48030 $as_echo "no" >&6; } 48031 fi 48032 48033 48034 test -n "$BUILD_OBJCOPY" && break 48035 done 48036 48037 else 48038 # If it succeeded, then it was overridden by the user. We will use it 48039 # for the tool. 48040 48041 # First remove it from the list of overridden variables, so we can test 48042 # for unknown variables in the end. 48043 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 48044 48045 # Check if we try to supply an empty value 48046 if test "x$BUILD_OBJCOPY" = x; then 48047 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool BUILD_OBJCOPY= (no value)" >&5 48048 $as_echo "$as_me: Setting user supplied tool BUILD_OBJCOPY= (no value)" >&6;} 48049 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for BUILD_OBJCOPY" >&5 48050 $as_echo_n "checking for BUILD_OBJCOPY... " >&6; } 48051 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 48052 $as_echo "disabled" >&6; } 48053 else 48054 # Check if the provided tool contains a complete path. 48055 tool_specified="$BUILD_OBJCOPY" 48056 tool_basename="${tool_specified##*/}" 48057 if test "x$tool_basename" = "x$tool_specified"; then 48058 # A command without a complete path is provided, search $PATH. 48059 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool BUILD_OBJCOPY=$tool_basename" >&5 48060 $as_echo "$as_me: Will search for user supplied tool BUILD_OBJCOPY=$tool_basename" >&6;} 48061 # Extract the first word of "$tool_basename", so it can be a program name with args. 48062 set dummy $tool_basename; ac_word=$2 48063 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 48064 $as_echo_n "checking for $ac_word... " >&6; } 48065 if ${ac_cv_path_BUILD_OBJCOPY+:} false; then : 48066 $as_echo_n "(cached) " >&6 48067 else 48068 case $BUILD_OBJCOPY in 48069 [\\/]* | ?:[\\/]*) 48070 ac_cv_path_BUILD_OBJCOPY="$BUILD_OBJCOPY" # Let the user override the test with a path. 48071 ;; 48072 *) 48073 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 48074 for as_dir in $PATH 48075 do 48076 IFS=$as_save_IFS 48077 test -z "$as_dir" && as_dir=. 48078 for ac_exec_ext in '' $ac_executable_extensions; do 48079 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 48080 ac_cv_path_BUILD_OBJCOPY="$as_dir/$ac_word$ac_exec_ext" 48081 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 48082 break 2 48083 fi 48084 done 48085 done 48086 IFS=$as_save_IFS 48087 48088 ;; 48089 esac 48090 fi 48091 BUILD_OBJCOPY=$ac_cv_path_BUILD_OBJCOPY 48092 if test -n "$BUILD_OBJCOPY"; then 48093 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BUILD_OBJCOPY" >&5 48094 $as_echo "$BUILD_OBJCOPY" >&6; } 48095 else 48096 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 48097 $as_echo "no" >&6; } 48098 fi 48099 48100 48101 if test "x$BUILD_OBJCOPY" = x; then 48102 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 48103 fi 48104 else 48105 # Otherwise we believe it is a complete path. Use it as it is. 48106 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool BUILD_OBJCOPY=$tool_specified" >&5 48107 $as_echo "$as_me: Will use user supplied tool BUILD_OBJCOPY=$tool_specified" >&6;} 48108 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for BUILD_OBJCOPY" >&5 48109 $as_echo_n "checking for BUILD_OBJCOPY... " >&6; } 48110 if test ! -x "$tool_specified"; then 48111 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 48112 $as_echo "not found" >&6; } 48113 as_fn_error $? "User supplied tool BUILD_OBJCOPY=$tool_specified does not exist or is not executable" "$LINENO" 5 48114 fi 48115 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 48116 $as_echo "$tool_specified" >&6; } 48117 fi 48118 fi 48119 fi 48120 48121 fi 48122 48123 48124 48125 # Only process if variable expands to non-empty 48126 48127 if test "x$BUILD_OBJCOPY" != x; then 48128 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 48129 48130 # First separate the path from the arguments. This will split at the first 48131 # space. 48132 complete="$BUILD_OBJCOPY" 48133 path="${complete%% *}" 48134 tmp="$complete EOL" 48135 arguments="${tmp#* }" 48136 48137 # Input might be given as Windows format, start by converting to 48138 # unix format. 48139 new_path=`$CYGPATH -u "$path"` 48140 48141 # Now try to locate executable using which 48142 new_path=`$WHICH "$new_path" 2> /dev/null` 48143 # bat and cmd files are not always considered executable in cygwin causing which 48144 # to not find them 48145 if test "x$new_path" = x \ 48146 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 48147 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 48148 new_path=`$CYGPATH -u "$path"` 48149 fi 48150 if test "x$new_path" = x; then 48151 # Oops. Which didn't find the executable. 48152 # The splitting of arguments from the executable at a space might have been incorrect, 48153 # since paths with space are more likely in Windows. Give it another try with the whole 48154 # argument. 48155 path="$complete" 48156 arguments="EOL" 48157 new_path=`$CYGPATH -u "$path"` 48158 new_path=`$WHICH "$new_path" 2> /dev/null` 48159 # bat and cmd files are not always considered executable in cygwin causing which 48160 # to not find them 48161 if test "x$new_path" = x \ 48162 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 48163 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 48164 new_path=`$CYGPATH -u "$path"` 48165 fi 48166 if test "x$new_path" = x; then 48167 # It's still not found. Now this is an unrecoverable error. 48168 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BUILD_OBJCOPY, which resolves as \"$complete\", is not found." >&5 48169 $as_echo "$as_me: The path of BUILD_OBJCOPY, which resolves as \"$complete\", is not found." >&6;} 48170 has_space=`$ECHO "$complete" | $GREP " "` 48171 if test "x$has_space" != x; then 48172 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 48173 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 48174 fi 48175 as_fn_error $? "Cannot locate the the path of BUILD_OBJCOPY" "$LINENO" 5 48176 fi 48177 fi 48178 48179 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 48180 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 48181 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 48182 # "foo.exe" is OK but "foo" is an error. 48183 # 48184 # This test is therefore slightly more accurate than "test -f" to check for file presence. 48185 # It is also a way to make sure we got the proper file name for the real test later on. 48186 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 48187 if test "x$test_shortpath" = x; then 48188 # Short path failed, file does not exist as specified. 48189 # Try adding .exe or .cmd 48190 if test -f "${new_path}.exe"; then 48191 input_to_shortpath="${new_path}.exe" 48192 elif test -f "${new_path}.cmd"; then 48193 input_to_shortpath="${new_path}.cmd" 48194 else 48195 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BUILD_OBJCOPY, which resolves as \"$new_path\", is invalid." >&5 48196 $as_echo "$as_me: The path of BUILD_OBJCOPY, which resolves as \"$new_path\", is invalid." >&6;} 48197 { $as_echo "$as_me:${as_lineno-$LINENO}: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&5 48198 $as_echo "$as_me: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&6;} 48199 as_fn_error $? "Cannot locate the the path of BUILD_OBJCOPY" "$LINENO" 5 48200 fi 48201 else 48202 input_to_shortpath="$new_path" 48203 fi 48204 48205 # Call helper function which possibly converts this using DOS-style short mode. 48206 # If so, the updated path is stored in $new_path. 48207 new_path="$input_to_shortpath" 48208 48209 input_path="$input_to_shortpath" 48210 # Check if we need to convert this using DOS-style short mode. If the path 48211 # contains just simple characters, use it. Otherwise (spaces, weird characters), 48212 # take no chances and rewrite it. 48213 # Note: m4 eats our [], so we need to use [ and ] instead. 48214 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 48215 if test "x$has_forbidden_chars" != x; then 48216 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 48217 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 48218 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 48219 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 48220 # Going to short mode and back again did indeed matter. Since short mode is 48221 # case insensitive, let's make it lowercase to improve readability. 48222 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 48223 # Now convert it back to Unix-style (cygpath) 48224 input_path=`$CYGPATH -u "$shortmode_path"` 48225 new_path="$input_path" 48226 fi 48227 fi 48228 48229 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 48230 if test "x$test_cygdrive_prefix" = x; then 48231 # As a simple fix, exclude /usr/bin since it's not a real path. 48232 if test "x`$ECHO $input_to_shortpath | $GREP ^/usr/bin/`" = x; then 48233 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 48234 # a path prefixed by /cygdrive for fixpath to work. 48235 new_path="$CYGWIN_ROOT_PATH$input_path" 48236 fi 48237 fi 48238 48239 # remove trailing .exe if any 48240 new_path="${new_path/%.exe/}" 48241 48242 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 48243 48244 # First separate the path from the arguments. This will split at the first 48245 # space. 48246 complete="$BUILD_OBJCOPY" 48247 path="${complete%% *}" 48248 tmp="$complete EOL" 48249 arguments="${tmp#* }" 48250 48251 # Input might be given as Windows format, start by converting to 48252 # unix format. 48253 new_path="$path" 48254 48255 windows_path="$new_path" 48256 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 48257 unix_path=`$CYGPATH -u "$windows_path"` 48258 new_path="$unix_path" 48259 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 48260 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 48261 new_path="$unix_path" 48262 fi 48263 48264 48265 # Now try to locate executable using which 48266 new_path=`$WHICH "$new_path" 2> /dev/null` 48267 48268 if test "x$new_path" = x; then 48269 # Oops. Which didn't find the executable. 48270 # The splitting of arguments from the executable at a space might have been incorrect, 48271 # since paths with space are more likely in Windows. Give it another try with the whole 48272 # argument. 48273 path="$complete" 48274 arguments="EOL" 48275 new_path="$path" 48276 48277 windows_path="$new_path" 48278 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 48279 unix_path=`$CYGPATH -u "$windows_path"` 48280 new_path="$unix_path" 48281 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 48282 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 48283 new_path="$unix_path" 48284 fi 48285 48286 48287 new_path=`$WHICH "$new_path" 2> /dev/null` 48288 # bat and cmd files are not always considered executable in MSYS causing which 48289 # to not find them 48290 if test "x$new_path" = x \ 48291 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 48292 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 48293 new_path="$path" 48294 48295 windows_path="$new_path" 48296 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 48297 unix_path=`$CYGPATH -u "$windows_path"` 48298 new_path="$unix_path" 48299 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 48300 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 48301 new_path="$unix_path" 48302 fi 48303 48304 fi 48305 48306 if test "x$new_path" = x; then 48307 # It's still not found. Now this is an unrecoverable error. 48308 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BUILD_OBJCOPY, which resolves as \"$complete\", is not found." >&5 48309 $as_echo "$as_me: The path of BUILD_OBJCOPY, which resolves as \"$complete\", is not found." >&6;} 48310 has_space=`$ECHO "$complete" | $GREP " "` 48311 if test "x$has_space" != x; then 48312 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 48313 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 48314 fi 48315 as_fn_error $? "Cannot locate the the path of BUILD_OBJCOPY" "$LINENO" 5 48316 fi 48317 fi 48318 48319 # Now new_path has a complete unix path to the binary 48320 if test "x`$ECHO $new_path | $GREP ^/bin/`" != x; then 48321 # Keep paths in /bin as-is, but remove trailing .exe if any 48322 new_path="${new_path/%.exe/}" 48323 # Do not save /bin paths to all_fixpath_prefixes! 48324 else 48325 # Not in mixed or Windows style, start by that. 48326 new_path=`cmd //c echo $new_path` 48327 48328 input_path="$new_path" 48329 # Check if we need to convert this using DOS-style short mode. If the path 48330 # contains just simple characters, use it. Otherwise (spaces, weird characters), 48331 # take no chances and rewrite it. 48332 # Note: m4 eats our [], so we need to use [ and ] instead. 48333 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 48334 if test "x$has_forbidden_chars" != x; then 48335 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 48336 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 48337 fi 48338 48339 # Output is in $new_path 48340 48341 windows_path="$new_path" 48342 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 48343 unix_path=`$CYGPATH -u "$windows_path"` 48344 new_path="$unix_path" 48345 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 48346 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 48347 new_path="$unix_path" 48348 fi 48349 48350 # remove trailing .exe if any 48351 new_path="${new_path/%.exe/}" 48352 48353 # Save the first 10 bytes of this path to the storage, so fixpath can work. 48354 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 48355 fi 48356 48357 else 48358 # We're on a unix platform. Hooray! :) 48359 # First separate the path from the arguments. This will split at the first 48360 # space. 48361 complete="$BUILD_OBJCOPY" 48362 path="${complete%% *}" 48363 tmp="$complete EOL" 48364 arguments="${tmp#* }" 48365 48366 # Cannot rely on the command "which" here since it doesn't always work. 48367 is_absolute_path=`$ECHO "$path" | $GREP ^/` 48368 if test -z "$is_absolute_path"; then 48369 # Path to executable is not absolute. Find it. 48370 IFS_save="$IFS" 48371 IFS=: 48372 for p in $PATH; do 48373 if test -f "$p/$path" && test -x "$p/$path"; then 48374 new_path="$p/$path" 48375 break 48376 fi 48377 done 48378 IFS="$IFS_save" 48379 else 48380 # This is an absolute path, we can use it without further modifications. 48381 new_path="$path" 48382 fi 48383 48384 if test "x$new_path" = x; then 48385 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BUILD_OBJCOPY, which resolves as \"$complete\", is not found." >&5 48386 $as_echo "$as_me: The path of BUILD_OBJCOPY, which resolves as \"$complete\", is not found." >&6;} 48387 has_space=`$ECHO "$complete" | $GREP " "` 48388 if test "x$has_space" != x; then 48389 { $as_echo "$as_me:${as_lineno-$LINENO}: This might be caused by spaces in the path, which is not allowed." >&5 48390 $as_echo "$as_me: This might be caused by spaces in the path, which is not allowed." >&6;} 48391 fi 48392 as_fn_error $? "Cannot locate the the path of BUILD_OBJCOPY" "$LINENO" 5 48393 fi 48394 fi 48395 48396 # Now join together the path and the arguments once again 48397 if test "x$arguments" != xEOL; then 48398 new_complete="$new_path ${arguments% *}" 48399 else 48400 new_complete="$new_path" 48401 fi 48402 48403 if test "x$complete" != "x$new_complete"; then 48404 BUILD_OBJCOPY="$new_complete" 48405 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BUILD_OBJCOPY to \"$new_complete\"" >&5 48406 $as_echo "$as_me: Rewriting BUILD_OBJCOPY to \"$new_complete\"" >&6;} 48407 fi 48408 fi 48409 48410 48411 48412 # Publish this variable in the help. 48413 48414 48415 if [ -z "${BUILD_STRIP+x}" ]; then 48416 # The variable is not set by user, try to locate tool using the code snippet 48417 for ac_prog in strip 48418 do 48419 # Extract the first word of "$ac_prog", so it can be a program name with args. 48420 set dummy $ac_prog; ac_word=$2 48421 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 48422 $as_echo_n "checking for $ac_word... " >&6; } 48423 if ${ac_cv_path_BUILD_STRIP+:} false; then : 48424 $as_echo_n "(cached) " >&6 48425 else 48426 case $BUILD_STRIP in 48427 [\\/]* | ?:[\\/]*) 48428 ac_cv_path_BUILD_STRIP="$BUILD_STRIP" # Let the user override the test with a path. 48429 ;; 48430 *) 48431 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 48432 for as_dir in $PATH 48433 do 48434 IFS=$as_save_IFS 48435 test -z "$as_dir" && as_dir=. 48436 for ac_exec_ext in '' $ac_executable_extensions; do 48437 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 48438 ac_cv_path_BUILD_STRIP="$as_dir/$ac_word$ac_exec_ext" 48439 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 48440 break 2 48441 fi 48442 done 48443 done 48444 IFS=$as_save_IFS 48445 48446 ;; 48447 esac 48448 fi 48449 BUILD_STRIP=$ac_cv_path_BUILD_STRIP 48450 if test -n "$BUILD_STRIP"; then 48451 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BUILD_STRIP" >&5 48452 $as_echo "$BUILD_STRIP" >&6; } 48453 else 48454 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 48455 $as_echo "no" >&6; } 48456 fi 48457 48458 48459 test -n "$BUILD_STRIP" && break 48460 done 48461 48462 else 48463 # The variable is set, but is it from the command line or the environment? 48464 48465 # Try to remove the string !BUILD_STRIP! from our list. 48466 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!BUILD_STRIP!/} 48467 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 48468 # If it failed, the variable was not from the command line. Ignore it, 48469 # but warn the user (except for BASH, which is always set by the calling BASH). 48470 if test "xBUILD_STRIP" != xBASH; then 48471 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of BUILD_STRIP from the environment. Use command line variables instead." >&5 48472 $as_echo "$as_me: WARNING: Ignoring value of BUILD_STRIP from the environment. Use command line variables instead." >&2;} 48473 fi 48474 # Try to locate tool using the code snippet 48475 for ac_prog in strip 48476 do 48477 # Extract the first word of "$ac_prog", so it can be a program name with args. 48478 set dummy $ac_prog; ac_word=$2 48479 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 48480 $as_echo_n "checking for $ac_word... " >&6; } 48481 if ${ac_cv_path_BUILD_STRIP+:} false; then : 48482 $as_echo_n "(cached) " >&6 48483 else 48484 case $BUILD_STRIP in 48485 [\\/]* | ?:[\\/]*) 48486 ac_cv_path_BUILD_STRIP="$BUILD_STRIP" # Let the user override the test with a path. 48487 ;; 48488 *) 48489 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 48490 for as_dir in $PATH 48491 do 48492 IFS=$as_save_IFS 48493 test -z "$as_dir" && as_dir=. 48494 for ac_exec_ext in '' $ac_executable_extensions; do 48495 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 48496 ac_cv_path_BUILD_STRIP="$as_dir/$ac_word$ac_exec_ext" 48497 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 48498 break 2 48499 fi 48500 done 48501 done 48502 IFS=$as_save_IFS 48503 48504 ;; 48505 esac 48506 fi 48507 BUILD_STRIP=$ac_cv_path_BUILD_STRIP 48508 if test -n "$BUILD_STRIP"; then 48509 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BUILD_STRIP" >&5 48510 $as_echo "$BUILD_STRIP" >&6; } 48511 else 48512 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 48513 $as_echo "no" >&6; } 48514 fi 48515 48516 48517 test -n "$BUILD_STRIP" && break 48518 done 48519 48520 else 48521 # If it succeeded, then it was overridden by the user. We will use it 48522 # for the tool. 48523 48524 # First remove it from the list of overridden variables, so we can test 48525 # for unknown variables in the end. 48526 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 48527 48528 # Check if we try to supply an empty value 48529 if test "x$BUILD_STRIP" = x; then 48530 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool BUILD_STRIP= (no value)" >&5 48531 $as_echo "$as_me: Setting user supplied tool BUILD_STRIP= (no value)" >&6;} 48532 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for BUILD_STRIP" >&5 48533 $as_echo_n "checking for BUILD_STRIP... " >&6; } 48534 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 48535 $as_echo "disabled" >&6; } 48536 else 48537 # Check if the provided tool contains a complete path. 48538 tool_specified="$BUILD_STRIP" 48539 tool_basename="${tool_specified##*/}" 48540 if test "x$tool_basename" = "x$tool_specified"; then 48541 # A command without a complete path is provided, search $PATH. 48542 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool BUILD_STRIP=$tool_basename" >&5 48543 $as_echo "$as_me: Will search for user supplied tool BUILD_STRIP=$tool_basename" >&6;} 48544 # Extract the first word of "$tool_basename", so it can be a program name with args. 48545 set dummy $tool_basename; ac_word=$2 48546 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 48547 $as_echo_n "checking for $ac_word... " >&6; } 48548 if ${ac_cv_path_BUILD_STRIP+:} false; then : 48549 $as_echo_n "(cached) " >&6 48550 else 48551 case $BUILD_STRIP in 48552 [\\/]* | ?:[\\/]*) 48553 ac_cv_path_BUILD_STRIP="$BUILD_STRIP" # Let the user override the test with a path. 48554 ;; 48555 *) 48556 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 48557 for as_dir in $PATH 48558 do 48559 IFS=$as_save_IFS 48560 test -z "$as_dir" && as_dir=. 48561 for ac_exec_ext in '' $ac_executable_extensions; do 48562 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 48563 ac_cv_path_BUILD_STRIP="$as_dir/$ac_word$ac_exec_ext" 48564 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 48565 break 2 48566 fi 48567 done 48568 done 48569 IFS=$as_save_IFS 48570 48571 ;; 48572 esac 48573 fi 48574 BUILD_STRIP=$ac_cv_path_BUILD_STRIP 48575 if test -n "$BUILD_STRIP"; then 48576 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BUILD_STRIP" >&5 48577 $as_echo "$BUILD_STRIP" >&6; } 48578 else 48579 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 48580 $as_echo "no" >&6; } 48581 fi 48582 48583 48584 if test "x$BUILD_STRIP" = x; then 48585 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 48586 fi 48587 else 48588 # Otherwise we believe it is a complete path. Use it as it is. 48589 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool BUILD_STRIP=$tool_specified" >&5 48590 $as_echo "$as_me: Will use user supplied tool BUILD_STRIP=$tool_specified" >&6;} 48591 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for BUILD_STRIP" >&5 48592 $as_echo_n "checking for BUILD_STRIP... " >&6; } 48593 if test ! -x "$tool_specified"; then 48594 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 48595 $as_echo "not found" >&6; } 48596 as_fn_error $? "User supplied tool BUILD_STRIP=$tool_specified does not exist or is not executable" "$LINENO" 5 48597 fi 48598 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 48599 $as_echo "$tool_specified" >&6; } 48600 fi 48601 fi 48602 fi 48603 48604 fi 48605 48606 48607 48608 # Only process if variable expands to non-empty 48609 48610 if test "x$BUILD_STRIP" != x; then 48611 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 48612 48613 # First separate the path from the arguments. This will split at the first 48614 # space. 48615 complete="$BUILD_STRIP" 48616 path="${complete%% *}" 48617 tmp="$complete EOL" 48618 arguments="${tmp#* }" 48619 48620 # Input might be given as Windows format, start by converting to 48621 # unix format. 48622 new_path=`$CYGPATH -u "$path"` 48623 48624 # Now try to locate executable using which 48625 new_path=`$WHICH "$new_path" 2> /dev/null` 48626 # bat and cmd files are not always considered executable in cygwin causing which 48627 # to not find them 48628 if test "x$new_path" = x \ 48629 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 48630 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 48631 new_path=`$CYGPATH -u "$path"` 48632 fi 48633 if test "x$new_path" = x; then 48634 # Oops. Which didn't find the executable. 48635 # The splitting of arguments from the executable at a space might have been incorrect, 48636 # since paths with space are more likely in Windows. Give it another try with the whole 48637 # argument. 48638 path="$complete" 48639 arguments="EOL" 48640 new_path=`$CYGPATH -u "$path"` 48641 new_path=`$WHICH "$new_path" 2> /dev/null` 48642 # bat and cmd files are not always considered executable in cygwin causing which 48643 # to not find them 48644 if test "x$new_path" = x \ 48645 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 48646 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 48647 new_path=`$CYGPATH -u "$path"` 48648 fi 48649 if test "x$new_path" = x; then 48650 # It's still not found. Now this is an unrecoverable error. 48651 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BUILD_STRIP, which resolves as \"$complete\", is not found." >&5 48652 $as_echo "$as_me: The path of BUILD_STRIP, which resolves as \"$complete\", is not found." >&6;} 48653 has_space=`$ECHO "$complete" | $GREP " "` 48654 if test "x$has_space" != x; then 48655 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 48656 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 48657 fi 48658 as_fn_error $? "Cannot locate the the path of BUILD_STRIP" "$LINENO" 5 48659 fi 48660 fi 48661 48662 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 48663 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 48664 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 48665 # "foo.exe" is OK but "foo" is an error. 48666 # 48667 # This test is therefore slightly more accurate than "test -f" to check for file presence. 48668 # It is also a way to make sure we got the proper file name for the real test later on. 48669 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 48670 if test "x$test_shortpath" = x; then 48671 # Short path failed, file does not exist as specified. 48672 # Try adding .exe or .cmd 48673 if test -f "${new_path}.exe"; then 48674 input_to_shortpath="${new_path}.exe" 48675 elif test -f "${new_path}.cmd"; then 48676 input_to_shortpath="${new_path}.cmd" 48677 else 48678 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BUILD_STRIP, which resolves as \"$new_path\", is invalid." >&5 48679 $as_echo "$as_me: The path of BUILD_STRIP, which resolves as \"$new_path\", is invalid." >&6;} 48680 { $as_echo "$as_me:${as_lineno-$LINENO}: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&5 48681 $as_echo "$as_me: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&6;} 48682 as_fn_error $? "Cannot locate the the path of BUILD_STRIP" "$LINENO" 5 48683 fi 48684 else 48685 input_to_shortpath="$new_path" 48686 fi 48687 48688 # Call helper function which possibly converts this using DOS-style short mode. 48689 # If so, the updated path is stored in $new_path. 48690 new_path="$input_to_shortpath" 48691 48692 input_path="$input_to_shortpath" 48693 # Check if we need to convert this using DOS-style short mode. If the path 48694 # contains just simple characters, use it. Otherwise (spaces, weird characters), 48695 # take no chances and rewrite it. 48696 # Note: m4 eats our [], so we need to use [ and ] instead. 48697 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 48698 if test "x$has_forbidden_chars" != x; then 48699 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 48700 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 48701 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 48702 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 48703 # Going to short mode and back again did indeed matter. Since short mode is 48704 # case insensitive, let's make it lowercase to improve readability. 48705 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 48706 # Now convert it back to Unix-style (cygpath) 48707 input_path=`$CYGPATH -u "$shortmode_path"` 48708 new_path="$input_path" 48709 fi 48710 fi 48711 48712 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 48713 if test "x$test_cygdrive_prefix" = x; then 48714 # As a simple fix, exclude /usr/bin since it's not a real path. 48715 if test "x`$ECHO $input_to_shortpath | $GREP ^/usr/bin/`" = x; then 48716 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 48717 # a path prefixed by /cygdrive for fixpath to work. 48718 new_path="$CYGWIN_ROOT_PATH$input_path" 48719 fi 48720 fi 48721 48722 # remove trailing .exe if any 48723 new_path="${new_path/%.exe/}" 48724 48725 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 48726 48727 # First separate the path from the arguments. This will split at the first 48728 # space. 48729 complete="$BUILD_STRIP" 48730 path="${complete%% *}" 48731 tmp="$complete EOL" 48732 arguments="${tmp#* }" 48733 48734 # Input might be given as Windows format, start by converting to 48735 # unix format. 48736 new_path="$path" 48737 48738 windows_path="$new_path" 48739 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 48740 unix_path=`$CYGPATH -u "$windows_path"` 48741 new_path="$unix_path" 48742 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 48743 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 48744 new_path="$unix_path" 48745 fi 48746 48747 48748 # Now try to locate executable using which 48749 new_path=`$WHICH "$new_path" 2> /dev/null` 48750 48751 if test "x$new_path" = x; then 48752 # Oops. Which didn't find the executable. 48753 # The splitting of arguments from the executable at a space might have been incorrect, 48754 # since paths with space are more likely in Windows. Give it another try with the whole 48755 # argument. 48756 path="$complete" 48757 arguments="EOL" 48758 new_path="$path" 48759 48760 windows_path="$new_path" 48761 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 48762 unix_path=`$CYGPATH -u "$windows_path"` 48763 new_path="$unix_path" 48764 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 48765 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 48766 new_path="$unix_path" 48767 fi 48768 48769 48770 new_path=`$WHICH "$new_path" 2> /dev/null` 48771 # bat and cmd files are not always considered executable in MSYS causing which 48772 # to not find them 48773 if test "x$new_path" = x \ 48774 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 48775 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 48776 new_path="$path" 48777 48778 windows_path="$new_path" 48779 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 48780 unix_path=`$CYGPATH -u "$windows_path"` 48781 new_path="$unix_path" 48782 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 48783 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 48784 new_path="$unix_path" 48785 fi 48786 48787 fi 48788 48789 if test "x$new_path" = x; then 48790 # It's still not found. Now this is an unrecoverable error. 48791 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BUILD_STRIP, which resolves as \"$complete\", is not found." >&5 48792 $as_echo "$as_me: The path of BUILD_STRIP, which resolves as \"$complete\", is not found." >&6;} 48793 has_space=`$ECHO "$complete" | $GREP " "` 48794 if test "x$has_space" != x; then 48795 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 48796 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 48797 fi 48798 as_fn_error $? "Cannot locate the the path of BUILD_STRIP" "$LINENO" 5 48799 fi 48800 fi 48801 48802 # Now new_path has a complete unix path to the binary 48803 if test "x`$ECHO $new_path | $GREP ^/bin/`" != x; then 48804 # Keep paths in /bin as-is, but remove trailing .exe if any 48805 new_path="${new_path/%.exe/}" 48806 # Do not save /bin paths to all_fixpath_prefixes! 48807 else 48808 # Not in mixed or Windows style, start by that. 48809 new_path=`cmd //c echo $new_path` 48810 48811 input_path="$new_path" 48812 # Check if we need to convert this using DOS-style short mode. If the path 48813 # contains just simple characters, use it. Otherwise (spaces, weird characters), 48814 # take no chances and rewrite it. 48815 # Note: m4 eats our [], so we need to use [ and ] instead. 48816 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 48817 if test "x$has_forbidden_chars" != x; then 48818 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 48819 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 48820 fi 48821 48822 # Output is in $new_path 48823 48824 windows_path="$new_path" 48825 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 48826 unix_path=`$CYGPATH -u "$windows_path"` 48827 new_path="$unix_path" 48828 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 48829 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 48830 new_path="$unix_path" 48831 fi 48832 48833 # remove trailing .exe if any 48834 new_path="${new_path/%.exe/}" 48835 48836 # Save the first 10 bytes of this path to the storage, so fixpath can work. 48837 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 48838 fi 48839 48840 else 48841 # We're on a unix platform. Hooray! :) 48842 # First separate the path from the arguments. This will split at the first 48843 # space. 48844 complete="$BUILD_STRIP" 48845 path="${complete%% *}" 48846 tmp="$complete EOL" 48847 arguments="${tmp#* }" 48848 48849 # Cannot rely on the command "which" here since it doesn't always work. 48850 is_absolute_path=`$ECHO "$path" | $GREP ^/` 48851 if test -z "$is_absolute_path"; then 48852 # Path to executable is not absolute. Find it. 48853 IFS_save="$IFS" 48854 IFS=: 48855 for p in $PATH; do 48856 if test -f "$p/$path" && test -x "$p/$path"; then 48857 new_path="$p/$path" 48858 break 48859 fi 48860 done 48861 IFS="$IFS_save" 48862 else 48863 # This is an absolute path, we can use it without further modifications. 48864 new_path="$path" 48865 fi 48866 48867 if test "x$new_path" = x; then 48868 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BUILD_STRIP, which resolves as \"$complete\", is not found." >&5 48869 $as_echo "$as_me: The path of BUILD_STRIP, which resolves as \"$complete\", is not found." >&6;} 48870 has_space=`$ECHO "$complete" | $GREP " "` 48871 if test "x$has_space" != x; then 48872 { $as_echo "$as_me:${as_lineno-$LINENO}: This might be caused by spaces in the path, which is not allowed." >&5 48873 $as_echo "$as_me: This might be caused by spaces in the path, which is not allowed." >&6;} 48874 fi 48875 as_fn_error $? "Cannot locate the the path of BUILD_STRIP" "$LINENO" 5 48876 fi 48877 fi 48878 48879 # Now join together the path and the arguments once again 48880 if test "x$arguments" != xEOL; then 48881 new_complete="$new_path ${arguments% *}" 48882 else 48883 new_complete="$new_path" 48884 fi 48885 48886 if test "x$complete" != "x$new_complete"; then 48887 BUILD_STRIP="$new_complete" 48888 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BUILD_STRIP to \"$new_complete\"" >&5 48889 $as_echo "$as_me: Rewriting BUILD_STRIP to \"$new_complete\"" >&6;} 48890 fi 48891 fi 48892 48893 # Assume the C compiler is the assembler 48894 BUILD_AS="$BUILD_CC -c" 48895 # Just like for the target compiler, use the compiler as linker 48896 BUILD_LD="$BUILD_CC" 48897 BUILD_LDCXX="$BUILD_CXX" 48898 48899 PATH="$OLDPATH" 48900 48901 48902 COMPILER=$BUILD_CC 48903 COMPILER_NAME=BuildC 48904 48905 if test "x$TOOLCHAIN_TYPE" = xsolstudio; then 48906 # cc -V output typically looks like 48907 # cc: Sun C 5.12 Linux_i386 2011/11/16 48908 # or 48909 # cc: Studio 12.5 Sun C 5.14 SunOS_sparc 2016/05/31 48910 COMPILER_VERSION_OUTPUT=`$COMPILER -V 2>&1` 48911 # Check that this is likely to be the Solaris Studio cc. 48912 $ECHO "$COMPILER_VERSION_OUTPUT" | $GREP "^.* Sun $COMPILER_NAME" > /dev/null 48913 if test $? -ne 0; then 48914 ALT_VERSION_OUTPUT=`$COMPILER --version 2>&1` 48915 { $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 48916 $as_echo "$as_me: The $COMPILER_NAME compiler (located as $COMPILER) does not seem to be the required $TOOLCHAIN_TYPE compiler." >&6;} 48917 { $as_echo "$as_me:${as_lineno-$LINENO}: The result from running with -V was: \"$COMPILER_VERSION_OUTPUT\"" >&5 48918 $as_echo "$as_me: The result from running with -V was: \"$COMPILER_VERSION_OUTPUT\"" >&6;} 48919 { $as_echo "$as_me:${as_lineno-$LINENO}: The result from running with --version was: \"$ALT_VERSION_OUTPUT\"" >&5 48920 $as_echo "$as_me: The result from running with --version was: \"$ALT_VERSION_OUTPUT\"" >&6;} 48921 as_fn_error $? "A $TOOLCHAIN_TYPE compiler is required. Try setting --with-tools-dir." "$LINENO" 5 48922 fi 48923 # Remove usage instructions (if present), and 48924 # collapse compiler output into a single line 48925 COMPILER_VERSION_STRING=`$ECHO $COMPILER_VERSION_OUTPUT | \ 48926 $SED -e 's/ *[Uu]sage:.*//'` 48927 COMPILER_VERSION_NUMBER=`$ECHO $COMPILER_VERSION_OUTPUT | \ 48928 $SED -e "s/^.*[ ,\t]$COMPILER_NAME[ ,\t]\([1-9]\.[0-9][0-9]*\).*/\1/"` 48929 elif test "x$TOOLCHAIN_TYPE" = xxlc; then 48930 # xlc -qversion output typically looks like 48931 # IBM XL C/C++ for AIX, V11.1 (5724-X13) 48932 # Version: 11.01.0000.0015 48933 COMPILER_VERSION_OUTPUT=`$COMPILER -qversion 2>&1` 48934 # Check that this is likely to be the IBM XL C compiler. 48935 $ECHO "$COMPILER_VERSION_OUTPUT" | $GREP "IBM XL C" > /dev/null 48936 if test $? -ne 0; then 48937 ALT_VERSION_OUTPUT=`$COMPILER --version 2>&1` 48938 { $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 48939 $as_echo "$as_me: The $COMPILER_NAME compiler (located as $COMPILER) does not seem to be the required $TOOLCHAIN_TYPE compiler." >&6;} 48940 { $as_echo "$as_me:${as_lineno-$LINENO}: The result from running with -qversion was: \"$COMPILER_VERSION_OUTPUT\"" >&5 48941 $as_echo "$as_me: The result from running with -qversion was: \"$COMPILER_VERSION_OUTPUT\"" >&6;} 48942 { $as_echo "$as_me:${as_lineno-$LINENO}: The result from running with --version was: \"$ALT_VERSION_OUTPUT\"" >&5 48943 $as_echo "$as_me: The result from running with --version was: \"$ALT_VERSION_OUTPUT\"" >&6;} 48944 as_fn_error $? "A $TOOLCHAIN_TYPE compiler is required. Try setting --with-tools-dir." "$LINENO" 5 48945 fi 48946 # Collapse compiler output into a single line 48947 COMPILER_VERSION_STRING=`$ECHO $COMPILER_VERSION_OUTPUT` 48948 COMPILER_VERSION_NUMBER=`$ECHO $COMPILER_VERSION_OUTPUT | \ 48949 $SED -e 's/^.*, V\([1-9][0-9.]*\).*$/\1/'` 48950 elif test "x$TOOLCHAIN_TYPE" = xmicrosoft; then 48951 # There is no specific version flag, but all output starts with a version string. 48952 # First line typically looks something like: 48953 # Microsoft (R) 32-bit C/C++ Optimizing Compiler Version 16.00.40219.01 for 80x86 48954 COMPILER_VERSION_OUTPUT=`$COMPILER 2>&1 | $HEAD -n 1 | $TR -d '\r'` 48955 # Check that this is likely to be Microsoft CL.EXE. 48956 $ECHO "$COMPILER_VERSION_OUTPUT" | $GREP "Microsoft.*Compiler" > /dev/null 48957 if test $? -ne 0; then 48958 { $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 48959 $as_echo "$as_me: The $COMPILER_NAME compiler (located as $COMPILER) does not seem to be the required $TOOLCHAIN_TYPE compiler." >&6;} 48960 { $as_echo "$as_me:${as_lineno-$LINENO}: The result from running it was: \"$COMPILER_VERSION_OUTPUT\"" >&5 48961 $as_echo "$as_me: The result from running it was: \"$COMPILER_VERSION_OUTPUT\"" >&6;} 48962 as_fn_error $? "A $TOOLCHAIN_TYPE compiler is required. Try setting --with-tools-dir." "$LINENO" 5 48963 fi 48964 # Collapse compiler output into a single line 48965 COMPILER_VERSION_STRING=`$ECHO $COMPILER_VERSION_OUTPUT` 48966 COMPILER_VERSION_NUMBER=`$ECHO $COMPILER_VERSION_OUTPUT | \ 48967 $SED -e 's/^.*ersion.\([1-9][0-9.]*\) .*$/\1/'` 48968 elif test "x$TOOLCHAIN_TYPE" = xgcc; then 48969 # gcc --version output typically looks like 48970 # gcc (Ubuntu/Linaro 4.8.1-10ubuntu9) 4.8.1 48971 # Copyright (C) 2013 Free Software Foundation, Inc. 48972 # This is free software; see the source for copying conditions. There is NO 48973 # warranty; not even for MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. 48974 COMPILER_VERSION_OUTPUT=`$COMPILER --version 2>&1` 48975 # Check that this is likely to be GCC. 48976 $ECHO "$COMPILER_VERSION_OUTPUT" | $GREP "Free Software Foundation" > /dev/null 48977 if test $? -ne 0; then 48978 { $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 48979 $as_echo "$as_me: The $COMPILER_NAME compiler (located as $COMPILER) does not seem to be the required $TOOLCHAIN_TYPE compiler." >&6;} 48980 { $as_echo "$as_me:${as_lineno-$LINENO}: The result from running with --version was: \"$COMPILER_VERSION\"" >&5 48981 $as_echo "$as_me: The result from running with --version was: \"$COMPILER_VERSION\"" >&6;} 48982 as_fn_error $? "A $TOOLCHAIN_TYPE compiler is required. Try setting --with-tools-dir." "$LINENO" 5 48983 fi 48984 # Remove Copyright and legalese from version string, and 48985 # collapse into a single line 48986 COMPILER_VERSION_STRING=`$ECHO $COMPILER_VERSION_OUTPUT | \ 48987 $SED -e 's/ *Copyright .*//'` 48988 COMPILER_VERSION_NUMBER=`$ECHO $COMPILER_VERSION_OUTPUT | \ 48989 $SED -e 's/^.* \([1-9]\.[0-9.]*\)[^0-9.].*$/\1/'` 48990 elif test "x$TOOLCHAIN_TYPE" = xclang; then 48991 # clang --version output typically looks like 48992 # Apple LLVM version 5.0 (clang-500.2.79) (based on LLVM 3.3svn) 48993 # clang version 3.3 (tags/RELEASE_33/final) 48994 # or 48995 # Debian clang version 3.2-7ubuntu1 (tags/RELEASE_32/final) (based on LLVM 3.2) 48996 # Target: x86_64-pc-linux-gnu 48997 # Thread model: posix 48998 COMPILER_VERSION_OUTPUT=`$COMPILER --version 2>&1` 48999 # Check that this is likely to be clang 49000 $ECHO "$COMPILER_VERSION_OUTPUT" | $GREP "clang" > /dev/null 49001 if test $? -ne 0; then 49002 { $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 49003 $as_echo "$as_me: The $COMPILER_NAME compiler (located as $COMPILER) does not seem to be the required $TOOLCHAIN_TYPE compiler." >&6;} 49004 { $as_echo "$as_me:${as_lineno-$LINENO}: The result from running with --version was: \"$COMPILER_VERSION_OUTPUT\"" >&5 49005 $as_echo "$as_me: The result from running with --version was: \"$COMPILER_VERSION_OUTPUT\"" >&6;} 49006 as_fn_error $? "A $TOOLCHAIN_TYPE compiler is required. Try setting --with-tools-dir." "$LINENO" 5 49007 fi 49008 # Collapse compiler output into a single line 49009 COMPILER_VERSION_STRING=`$ECHO $COMPILER_VERSION_OUTPUT` 49010 COMPILER_VERSION_NUMBER=`$ECHO $COMPILER_VERSION_OUTPUT | \ 49011 $SED -e 's/^.* version \([1-9][0-9.]*\).*$/\1/'` 49012 else 49013 as_fn_error $? "Unknown toolchain type $TOOLCHAIN_TYPE." "$LINENO" 5 49014 fi 49015 # This sets CC_VERSION_NUMBER or CXX_VERSION_NUMBER. (This comment is a grep marker) 49016 BUILD_CC_VERSION_NUMBER="$COMPILER_VERSION_NUMBER" 49017 # This sets CC_VERSION_STRING or CXX_VERSION_STRING. (This comment is a grep marker) 49018 BUILD_CC_VERSION_STRING="$COMPILER_VERSION_STRING" 49019 49020 { $as_echo "$as_me:${as_lineno-$LINENO}: Using $TOOLCHAIN_TYPE $COMPILER_NAME compiler version $COMPILER_VERSION_NUMBER [$COMPILER_VERSION_STRING]" >&5 49021 $as_echo "$as_me: Using $TOOLCHAIN_TYPE $COMPILER_NAME compiler version $COMPILER_VERSION_NUMBER [$COMPILER_VERSION_STRING]" >&6;} 49022 49023 49024 COMPILER=$BUILD_CXX 49025 COMPILER_NAME=BuildC++ 49026 49027 if test "x$TOOLCHAIN_TYPE" = xsolstudio; then 49028 # cc -V output typically looks like 49029 # cc: Sun C 5.12 Linux_i386 2011/11/16 49030 # or 49031 # cc: Studio 12.5 Sun C 5.14 SunOS_sparc 2016/05/31 49032 COMPILER_VERSION_OUTPUT=`$COMPILER -V 2>&1` 49033 # Check that this is likely to be the Solaris Studio cc. 49034 $ECHO "$COMPILER_VERSION_OUTPUT" | $GREP "^.* Sun $COMPILER_NAME" > /dev/null 49035 if test $? -ne 0; then 49036 ALT_VERSION_OUTPUT=`$COMPILER --version 2>&1` 49037 { $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 49038 $as_echo "$as_me: The $COMPILER_NAME compiler (located as $COMPILER) does not seem to be the required $TOOLCHAIN_TYPE compiler." >&6;} 49039 { $as_echo "$as_me:${as_lineno-$LINENO}: The result from running with -V was: \"$COMPILER_VERSION_OUTPUT\"" >&5 49040 $as_echo "$as_me: The result from running with -V was: \"$COMPILER_VERSION_OUTPUT\"" >&6;} 49041 { $as_echo "$as_me:${as_lineno-$LINENO}: The result from running with --version was: \"$ALT_VERSION_OUTPUT\"" >&5 49042 $as_echo "$as_me: The result from running with --version was: \"$ALT_VERSION_OUTPUT\"" >&6;} 49043 as_fn_error $? "A $TOOLCHAIN_TYPE compiler is required. Try setting --with-tools-dir." "$LINENO" 5 49044 fi 49045 # Remove usage instructions (if present), and 49046 # collapse compiler output into a single line 49047 COMPILER_VERSION_STRING=`$ECHO $COMPILER_VERSION_OUTPUT | \ 49048 $SED -e 's/ *[Uu]sage:.*//'` 49049 COMPILER_VERSION_NUMBER=`$ECHO $COMPILER_VERSION_OUTPUT | \ 49050 $SED -e "s/^.*[ ,\t]$COMPILER_NAME[ ,\t]\([1-9]\.[0-9][0-9]*\).*/\1/"` 49051 elif test "x$TOOLCHAIN_TYPE" = xxlc; then 49052 # xlc -qversion output typically looks like 49053 # IBM XL C/C++ for AIX, V11.1 (5724-X13) 49054 # Version: 11.01.0000.0015 49055 COMPILER_VERSION_OUTPUT=`$COMPILER -qversion 2>&1` 49056 # Check that this is likely to be the IBM XL C compiler. 49057 $ECHO "$COMPILER_VERSION_OUTPUT" | $GREP "IBM XL C" > /dev/null 49058 if test $? -ne 0; then 49059 ALT_VERSION_OUTPUT=`$COMPILER --version 2>&1` 49060 { $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 49061 $as_echo "$as_me: The $COMPILER_NAME compiler (located as $COMPILER) does not seem to be the required $TOOLCHAIN_TYPE compiler." >&6;} 49062 { $as_echo "$as_me:${as_lineno-$LINENO}: The result from running with -qversion was: \"$COMPILER_VERSION_OUTPUT\"" >&5 49063 $as_echo "$as_me: The result from running with -qversion was: \"$COMPILER_VERSION_OUTPUT\"" >&6;} 49064 { $as_echo "$as_me:${as_lineno-$LINENO}: The result from running with --version was: \"$ALT_VERSION_OUTPUT\"" >&5 49065 $as_echo "$as_me: The result from running with --version was: \"$ALT_VERSION_OUTPUT\"" >&6;} 49066 as_fn_error $? "A $TOOLCHAIN_TYPE compiler is required. Try setting --with-tools-dir." "$LINENO" 5 49067 fi 49068 # Collapse compiler output into a single line 49069 COMPILER_VERSION_STRING=`$ECHO $COMPILER_VERSION_OUTPUT` 49070 COMPILER_VERSION_NUMBER=`$ECHO $COMPILER_VERSION_OUTPUT | \ 49071 $SED -e 's/^.*, V\([1-9][0-9.]*\).*$/\1/'` 49072 elif test "x$TOOLCHAIN_TYPE" = xmicrosoft; then 49073 # There is no specific version flag, but all output starts with a version string. 49074 # First line typically looks something like: 49075 # Microsoft (R) 32-bit C/C++ Optimizing Compiler Version 16.00.40219.01 for 80x86 49076 COMPILER_VERSION_OUTPUT=`$COMPILER 2>&1 | $HEAD -n 1 | $TR -d '\r'` 49077 # Check that this is likely to be Microsoft CL.EXE. 49078 $ECHO "$COMPILER_VERSION_OUTPUT" | $GREP "Microsoft.*Compiler" > /dev/null 49079 if test $? -ne 0; then 49080 { $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 49081 $as_echo "$as_me: The $COMPILER_NAME compiler (located as $COMPILER) does not seem to be the required $TOOLCHAIN_TYPE compiler." >&6;} 49082 { $as_echo "$as_me:${as_lineno-$LINENO}: The result from running it was: \"$COMPILER_VERSION_OUTPUT\"" >&5 49083 $as_echo "$as_me: The result from running it was: \"$COMPILER_VERSION_OUTPUT\"" >&6;} 49084 as_fn_error $? "A $TOOLCHAIN_TYPE compiler is required. Try setting --with-tools-dir." "$LINENO" 5 49085 fi 49086 # Collapse compiler output into a single line 49087 COMPILER_VERSION_STRING=`$ECHO $COMPILER_VERSION_OUTPUT` 49088 COMPILER_VERSION_NUMBER=`$ECHO $COMPILER_VERSION_OUTPUT | \ 49089 $SED -e 's/^.*ersion.\([1-9][0-9.]*\) .*$/\1/'` 49090 elif test "x$TOOLCHAIN_TYPE" = xgcc; then 49091 # gcc --version output typically looks like 49092 # gcc (Ubuntu/Linaro 4.8.1-10ubuntu9) 4.8.1 49093 # Copyright (C) 2013 Free Software Foundation, Inc. 49094 # This is free software; see the source for copying conditions. There is NO 49095 # warranty; not even for MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. 49096 COMPILER_VERSION_OUTPUT=`$COMPILER --version 2>&1` 49097 # Check that this is likely to be GCC. 49098 $ECHO "$COMPILER_VERSION_OUTPUT" | $GREP "Free Software Foundation" > /dev/null 49099 if test $? -ne 0; then 49100 { $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 49101 $as_echo "$as_me: The $COMPILER_NAME compiler (located as $COMPILER) does not seem to be the required $TOOLCHAIN_TYPE compiler." >&6;} 49102 { $as_echo "$as_me:${as_lineno-$LINENO}: The result from running with --version was: \"$COMPILER_VERSION\"" >&5 49103 $as_echo "$as_me: The result from running with --version was: \"$COMPILER_VERSION\"" >&6;} 49104 as_fn_error $? "A $TOOLCHAIN_TYPE compiler is required. Try setting --with-tools-dir." "$LINENO" 5 49105 fi 49106 # Remove Copyright and legalese from version string, and 49107 # collapse into a single line 49108 COMPILER_VERSION_STRING=`$ECHO $COMPILER_VERSION_OUTPUT | \ 49109 $SED -e 's/ *Copyright .*//'` 49110 COMPILER_VERSION_NUMBER=`$ECHO $COMPILER_VERSION_OUTPUT | \ 49111 $SED -e 's/^.* \([1-9]\.[0-9.]*\)[^0-9.].*$/\1/'` 49112 elif test "x$TOOLCHAIN_TYPE" = xclang; then 49113 # clang --version output typically looks like 49114 # Apple LLVM version 5.0 (clang-500.2.79) (based on LLVM 3.3svn) 49115 # clang version 3.3 (tags/RELEASE_33/final) 49116 # or 49117 # Debian clang version 3.2-7ubuntu1 (tags/RELEASE_32/final) (based on LLVM 3.2) 49118 # Target: x86_64-pc-linux-gnu 49119 # Thread model: posix 49120 COMPILER_VERSION_OUTPUT=`$COMPILER --version 2>&1` 49121 # Check that this is likely to be clang 49122 $ECHO "$COMPILER_VERSION_OUTPUT" | $GREP "clang" > /dev/null 49123 if test $? -ne 0; then 49124 { $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 49125 $as_echo "$as_me: The $COMPILER_NAME compiler (located as $COMPILER) does not seem to be the required $TOOLCHAIN_TYPE compiler." >&6;} 49126 { $as_echo "$as_me:${as_lineno-$LINENO}: The result from running with --version was: \"$COMPILER_VERSION_OUTPUT\"" >&5 49127 $as_echo "$as_me: The result from running with --version was: \"$COMPILER_VERSION_OUTPUT\"" >&6;} 49128 as_fn_error $? "A $TOOLCHAIN_TYPE compiler is required. Try setting --with-tools-dir." "$LINENO" 5 49129 fi 49130 # Collapse compiler output into a single line 49131 COMPILER_VERSION_STRING=`$ECHO $COMPILER_VERSION_OUTPUT` 49132 COMPILER_VERSION_NUMBER=`$ECHO $COMPILER_VERSION_OUTPUT | \ 49133 $SED -e 's/^.* version \([1-9][0-9.]*\).*$/\1/'` 49134 else 49135 as_fn_error $? "Unknown toolchain type $TOOLCHAIN_TYPE." "$LINENO" 5 49136 fi 49137 # This sets CC_VERSION_NUMBER or CXX_VERSION_NUMBER. (This comment is a grep marker) 49138 BUILD_CXX_VERSION_NUMBER="$COMPILER_VERSION_NUMBER" 49139 # This sets CC_VERSION_STRING or CXX_VERSION_STRING. (This comment is a grep marker) 49140 BUILD_CXX_VERSION_STRING="$COMPILER_VERSION_STRING" 49141 49142 { $as_echo "$as_me:${as_lineno-$LINENO}: Using $TOOLCHAIN_TYPE $COMPILER_NAME compiler version $COMPILER_VERSION_NUMBER [$COMPILER_VERSION_STRING]" >&5 49143 $as_echo "$as_me: Using $TOOLCHAIN_TYPE $COMPILER_NAME compiler version $COMPILER_VERSION_NUMBER [$COMPILER_VERSION_STRING]" >&6;} 49144 49145 49146 if test "x$BUILD_CC_VERSION_NUMBER" != "x$BUILD_CXX_VERSION_NUMBER"; then 49147 { $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 49148 $as_echo "$as_me: WARNING: C and C++ compiler have different version numbers, $BUILD_CC_VERSION_NUMBER vs $BUILD_CXX_VERSION_NUMBER." >&2;} 49149 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: This typically indicates a broken setup, and is not supported" >&5 49150 $as_echo "$as_me: WARNING: This typically indicates a broken setup, and is not supported" >&2;} 49151 fi 49152 49153 # We only check CC_VERSION_NUMBER since we assume CXX_VERSION_NUMBER is equal. 49154 if [[ "[$]BUILD_CC_VERSION_NUMBER" =~ (.*\.){4} ]] ; then 49155 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: C compiler version number has more than four parts (W.X.Y.Z): $BUILD_CC_VERSION_NUMBER. Comparisons might be wrong." >&5 49156 $as_echo "$as_me: WARNING: C compiler version number has more than four parts (W.X.Y.Z): $BUILD_CC_VERSION_NUMBER. Comparisons might be wrong." >&2;} 49157 fi 49158 49159 if [[ "[$]BUILD_CC_VERSION_NUMBER" =~ [0-9]{6} ]] ; then 49160 { $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 49161 $as_echo "$as_me: WARNING: C compiler version number has a part larger than 99999: $BUILD_CC_VERSION_NUMBER. Comparisons might be wrong." >&2;} 49162 fi 49163 49164 OPENJDK_BUILD_COMPARABLE_ACTUAL_VERSION=`$AWK -F. '{ printf("%05d%05d%05d%05d\n", $1, $2, $3, $4) }' <<< "$BUILD_CC_VERSION_NUMBER"` 49165 49166 else 49167 # If we are not cross compiling, use the normal target compilers for 49168 # building the build platform executables. 49169 BUILD_CC="$CC" 49170 BUILD_CXX="$CXX" 49171 BUILD_LD="$LD" 49172 BUILD_LDCXX="$LDCXX" 49173 BUILD_NM="$NM" 49174 BUILD_AS="$AS" 49175 BUILD_OBJCOPY="$OBJCOPY" 49176 BUILD_STRIP="$STRIP" 49177 BUILD_SYSROOT_CFLAGS="$SYSROOT_CFLAGS" 49178 BUILD_SYSROOT_LDFLAGS="$SYSROOT_LDFLAGS" 49179 BUILD_AR="$AR" 49180 49181 49182 if test "x$CC_VERSION_NUMBER" != "x$CXX_VERSION_NUMBER"; then 49183 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: C and C++ compiler have different version numbers, $CC_VERSION_NUMBER vs $CXX_VERSION_NUMBER." >&5 49184 $as_echo "$as_me: WARNING: C and C++ compiler have different version numbers, $CC_VERSION_NUMBER vs $CXX_VERSION_NUMBER." >&2;} 49185 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: This typically indicates a broken setup, and is not supported" >&5 49186 $as_echo "$as_me: WARNING: This typically indicates a broken setup, and is not supported" >&2;} 49187 fi 49188 49189 # We only check CC_VERSION_NUMBER since we assume CXX_VERSION_NUMBER is equal. 49190 if [[ "[$]CC_VERSION_NUMBER" =~ (.*\.){4} ]] ; then 49191 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: C compiler version number has more than four parts (W.X.Y.Z): $CC_VERSION_NUMBER. Comparisons might be wrong." >&5 49192 $as_echo "$as_me: WARNING: C compiler version number has more than four parts (W.X.Y.Z): $CC_VERSION_NUMBER. Comparisons might be wrong." >&2;} 49193 fi 49194 49195 if [[ "[$]CC_VERSION_NUMBER" =~ [0-9]{6} ]] ; then 49196 { $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 49197 $as_echo "$as_me: WARNING: C compiler version number has a part larger than 99999: $CC_VERSION_NUMBER. Comparisons might be wrong." >&2;} 49198 fi 49199 49200 OPENJDK_BUILD_COMPARABLE_ACTUAL_VERSION=`$AWK -F. '{ printf("%05d%05d%05d%05d\n", $1, $2, $3, $4) }' <<< "$CC_VERSION_NUMBER"` 49201 49202 fi 49203 49204 49205 49206 49207 49208 49209 49210 49211 49212 49213 49214 49215 49216 49217 # The package path is used only on macosx? 49218 # FIXME: clean this up, and/or move it elsewhere. 49219 PACKAGE_PATH=/opt/local 49220 49221 49222 # Check for extra potential brokenness. 49223 if test "x$TOOLCHAIN_TYPE" = xmicrosoft; then 49224 # On Windows, double-check that we got the right compiler. 49225 CC_VERSION_OUTPUT=`$CC 2>&1 | $HEAD -n 1 | $TR -d '\r'` 49226 COMPILER_CPU_TEST=`$ECHO $CC_VERSION_OUTPUT | $SED -n "s/^.* \(.*\)$/\1/p"` 49227 if test "x$OPENJDK_TARGET_CPU" = "xx86"; then 49228 if test "x$COMPILER_CPU_TEST" != "x80x86" -a "x$COMPILER_CPU_TEST" != "xx86"; then 49229 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 49230 fi 49231 elif test "x$OPENJDK_TARGET_CPU" = "xx86_64"; then 49232 if test "x$COMPILER_CPU_TEST" != "xx64"; then 49233 as_fn_error $? "Target CPU mismatch. We are building for $OPENJDK_TARGET_CPU but CL is for \"$COMPILER_CPU_TEST\"; expected \"x64\"." "$LINENO" 5 49234 fi 49235 fi 49236 fi 49237 49238 if test "x$TOOLCHAIN_TYPE" = xgcc; then 49239 # If this is a --hash-style=gnu system, use --hash-style=both, why? 49240 HAS_GNU_HASH=`$CC -dumpspecs 2>/dev/null | $GREP 'hash-style=gnu'` 49241 # This is later checked when setting flags. 49242 49243 # "-Og" suppported for GCC 4.8 and later 49244 CFLAG_OPTIMIZE_DEBUG_FLAG="-Og" 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 49281 49282 49283 49284 49285 49286 49287 49288 49289 49290 49291 49292 # Execute function body 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 49330 49331 49332 49333 49334 49335 49336 49337 49338 49339 49340 49341 # Execute function body 49342 49343 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if the C compiler supports \"$CFLAG_OPTIMIZE_DEBUG_FLAG\"" >&5 49344 $as_echo_n "checking if the C compiler supports \"$CFLAG_OPTIMIZE_DEBUG_FLAG\"... " >&6; } 49345 supports=yes 49346 49347 saved_cflags="$CFLAGS" 49348 CFLAGS="$CFLAGS $CFLAG_OPTIMIZE_DEBUG_FLAG" 49349 ac_ext=c 49350 ac_cpp='$CPP $CPPFLAGS' 49351 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5' 49352 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' 49353 ac_compiler_gnu=$ac_cv_c_compiler_gnu 49354 49355 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 49356 /* end confdefs.h. */ 49357 int i; 49358 _ACEOF 49359 if ac_fn_c_try_compile "$LINENO"; then : 49360 49361 else 49362 supports=no 49363 fi 49364 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext 49365 ac_ext=cpp 49366 ac_cpp='$CXXCPP $CPPFLAGS' 49367 ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5' 49368 ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' 49369 ac_compiler_gnu=$ac_cv_cxx_compiler_gnu 49370 49371 CFLAGS="$saved_cflags" 49372 49373 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $supports" >&5 49374 $as_echo "$supports" >&6; } 49375 if test "x$supports" = "xyes" ; then 49376 : 49377 C_COMP_SUPPORTS="yes" 49378 else 49379 : 49380 C_COMP_SUPPORTS="no" 49381 fi 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 49430 49431 49432 49433 49434 49435 49436 49437 49438 49439 49440 49441 # Execute function body 49442 49443 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if the C++ compiler supports \"$CFLAG_OPTIMIZE_DEBUG_FLAG\"" >&5 49444 $as_echo_n "checking if the C++ compiler supports \"$CFLAG_OPTIMIZE_DEBUG_FLAG\"... " >&6; } 49445 supports=yes 49446 49447 saved_cxxflags="$CXXFLAGS" 49448 CXXFLAGS="$CXXFLAG $CFLAG_OPTIMIZE_DEBUG_FLAG" 49449 ac_ext=cpp 49450 ac_cpp='$CXXCPP $CPPFLAGS' 49451 ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5' 49452 ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' 49453 ac_compiler_gnu=$ac_cv_cxx_compiler_gnu 49454 49455 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 49456 /* end confdefs.h. */ 49457 int i; 49458 _ACEOF 49459 if ac_fn_cxx_try_compile "$LINENO"; then : 49460 49461 else 49462 supports=no 49463 fi 49464 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext 49465 ac_ext=cpp 49466 ac_cpp='$CXXCPP $CPPFLAGS' 49467 ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5' 49468 ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' 49469 ac_compiler_gnu=$ac_cv_cxx_compiler_gnu 49470 49471 CXXFLAGS="$saved_cxxflags" 49472 49473 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $supports" >&5 49474 $as_echo "$supports" >&6; } 49475 if test "x$supports" = "xyes" ; then 49476 : 49477 CXX_COMP_SUPPORTS="yes" 49478 else 49479 : 49480 CXX_COMP_SUPPORTS="no" 49481 fi 49482 49483 49484 49485 49486 49487 49488 49489 49490 49491 49492 49493 49494 49495 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if both compilers support \"$CFLAG_OPTIMIZE_DEBUG_FLAG\"" >&5 49496 $as_echo_n "checking if both compilers support \"$CFLAG_OPTIMIZE_DEBUG_FLAG\"... " >&6; } 49497 supports=no 49498 if test "x$C_COMP_SUPPORTS" = "xyes" -a "x$CXX_COMP_SUPPORTS" = "xyes"; then supports=yes; fi 49499 49500 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $supports" >&5 49501 $as_echo "$supports" >&6; } 49502 if test "x$supports" = "xyes" ; then 49503 : 49504 HAS_CFLAG_OPTIMIZE_DEBUG=true 49505 else 49506 : 49507 HAS_CFLAG_OPTIMIZE_DEBUG=false 49508 fi 49509 49510 49511 49512 49513 49514 49515 49516 # "-z relro" supported in GNU binutils 2.17 and later 49517 LINKER_RELRO_FLAG="-Wl,-z,relro" 49518 49519 49520 49521 49522 49523 49524 49525 49526 49527 49528 49529 49530 49531 49532 49533 49534 49535 49536 49537 49538 49539 49540 49541 49542 49543 49544 49545 49546 49547 49548 49549 49550 49551 49552 49553 49554 49555 49556 49557 49558 49559 49560 49561 49562 49563 49564 49565 # Execute function body 49566 49567 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if linker supports \"$LINKER_RELRO_FLAG\"" >&5 49568 $as_echo_n "checking if linker supports \"$LINKER_RELRO_FLAG\"... " >&6; } 49569 supports=yes 49570 49571 saved_ldflags="$LDFLAGS" 49572 LDFLAGS="$LDFLAGS $LINKER_RELRO_FLAG" 49573 ac_ext=c 49574 ac_cpp='$CPP $CPPFLAGS' 49575 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5' 49576 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' 49577 ac_compiler_gnu=$ac_cv_c_compiler_gnu 49578 49579 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 49580 /* end confdefs.h. */ 49581 49582 int 49583 main () 49584 { 49585 49586 ; 49587 return 0; 49588 } 49589 _ACEOF 49590 if ac_fn_c_try_link "$LINENO"; then : 49591 49592 else 49593 supports=no 49594 fi 49595 rm -f core conftest.err conftest.$ac_objext \ 49596 conftest$ac_exeext conftest.$ac_ext 49597 ac_ext=cpp 49598 ac_cpp='$CXXCPP $CPPFLAGS' 49599 ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5' 49600 ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' 49601 ac_compiler_gnu=$ac_cv_cxx_compiler_gnu 49602 49603 LDFLAGS="$saved_ldflags" 49604 49605 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $supports" >&5 49606 $as_echo "$supports" >&6; } 49607 if test "x$supports" = "xyes" ; then 49608 : 49609 HAS_LINKER_RELRO=true 49610 else 49611 : 49612 HAS_LINKER_RELRO=false 49613 fi 49614 49615 49616 49617 49618 49619 49620 49621 49622 49623 49624 49625 49626 49627 # "-z now" supported in GNU binutils 2.11 and later 49628 LINKER_NOW_FLAG="-Wl,-z,now" 49629 49630 49631 49632 49633 49634 49635 49636 49637 49638 49639 49640 49641 49642 49643 49644 49645 49646 49647 49648 49649 49650 49651 49652 49653 49654 49655 49656 49657 49658 49659 49660 49661 49662 49663 49664 49665 49666 49667 49668 49669 49670 49671 49672 49673 49674 49675 49676 # Execute function body 49677 49678 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if linker supports \"$LINKER_NOW_FLAG\"" >&5 49679 $as_echo_n "checking if linker supports \"$LINKER_NOW_FLAG\"... " >&6; } 49680 supports=yes 49681 49682 saved_ldflags="$LDFLAGS" 49683 LDFLAGS="$LDFLAGS $LINKER_NOW_FLAG" 49684 ac_ext=c 49685 ac_cpp='$CPP $CPPFLAGS' 49686 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5' 49687 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' 49688 ac_compiler_gnu=$ac_cv_c_compiler_gnu 49689 49690 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 49691 /* end confdefs.h. */ 49692 49693 int 49694 main () 49695 { 49696 49697 ; 49698 return 0; 49699 } 49700 _ACEOF 49701 if ac_fn_c_try_link "$LINENO"; then : 49702 49703 else 49704 supports=no 49705 fi 49706 rm -f core conftest.err conftest.$ac_objext \ 49707 conftest$ac_exeext conftest.$ac_ext 49708 ac_ext=cpp 49709 ac_cpp='$CXXCPP $CPPFLAGS' 49710 ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5' 49711 ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' 49712 ac_compiler_gnu=$ac_cv_cxx_compiler_gnu 49713 49714 LDFLAGS="$saved_ldflags" 49715 49716 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $supports" >&5 49717 $as_echo "$supports" >&6; } 49718 if test "x$supports" = "xyes" ; then 49719 : 49720 HAS_LINKER_NOW=true 49721 else 49722 : 49723 HAS_LINKER_NOW=false 49724 fi 49725 49726 49727 49728 49729 49730 49731 49732 49733 49734 49735 49736 49737 fi 49738 49739 # Check for broken SuSE 'ld' for which 'Only anonymous version tag is allowed 49740 # in executable.' 49741 USING_BROKEN_SUSE_LD=no 49742 if test "x$OPENJDK_TARGET_OS" = xlinux && test "x$TOOLCHAIN_TYPE" = xgcc; then 49743 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for broken SuSE 'ld' which only understands anonymous version tags in executables" >&5 49744 $as_echo_n "checking for broken SuSE 'ld' which only understands anonymous version tags in executables... " >&6; } 49745 $ECHO "SUNWprivate_1.1 { local: *; };" > version-script.map 49746 $ECHO "int main() { }" > main.c 49747 if $CXX -Wl,-version-script=version-script.map main.c 2>&5 >&5; then 49748 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 49749 $as_echo "no" >&6; } 49750 USING_BROKEN_SUSE_LD=no 49751 else 49752 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 49753 $as_echo "yes" >&6; } 49754 USING_BROKEN_SUSE_LD=yes 49755 fi 49756 $RM version-script.map main.c a.out 49757 fi 49758 49759 49760 # Setup hotspot lecagy names for toolchains 49761 HOTSPOT_TOOLCHAIN_TYPE=$TOOLCHAIN_TYPE 49762 if test "x$TOOLCHAIN_TYPE" = xclang; then 49763 HOTSPOT_TOOLCHAIN_TYPE=gcc 49764 elif test "x$TOOLCHAIN_TYPE" = xsolstudio; then 49765 HOTSPOT_TOOLCHAIN_TYPE=sparcWorks 49766 elif test "x$TOOLCHAIN_TYPE" = xmicrosoft; then 49767 HOTSPOT_TOOLCHAIN_TYPE=visCPP 49768 fi 49769 49770 49771 49772 # Setup the JTReg Regression Test Harness. 49773 49774 49775 # Check whether --with-jtreg was given. 49776 if test "${with_jtreg+set}" = set; then : 49777 withval=$with_jtreg; 49778 fi 49779 49780 49781 if test "x$with_jtreg" = xno; then 49782 # jtreg disabled 49783 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for jtreg test harness" >&5 49784 $as_echo_n "checking for jtreg test harness... " >&6; } 49785 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no, disabled" >&5 49786 $as_echo "no, disabled" >&6; } 49787 elif test "x$with_jtreg" != xyes && test "x$with_jtreg" != x; then 49788 # An explicit path is specified, use it. 49789 JT_HOME="$with_jtreg" 49790 49791 # Only process if variable expands to non-empty 49792 49793 if test "x$JT_HOME" != x; then 49794 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 49795 49796 # Input might be given as Windows format, start by converting to 49797 # unix format. 49798 path="$JT_HOME" 49799 new_path=`$CYGPATH -u "$path"` 49800 49801 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 49802 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 49803 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 49804 # "foo.exe" is OK but "foo" is an error. 49805 # 49806 # This test is therefore slightly more accurate than "test -f" to check for file precense. 49807 # It is also a way to make sure we got the proper file name for the real test later on. 49808 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 49809 if test "x$test_shortpath" = x; then 49810 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of JT_HOME, which resolves as \"$path\", is invalid." >&5 49811 $as_echo "$as_me: The path of JT_HOME, which resolves as \"$path\", is invalid." >&6;} 49812 as_fn_error $? "Cannot locate the the path of JT_HOME" "$LINENO" 5 49813 fi 49814 49815 # Call helper function which possibly converts this using DOS-style short mode. 49816 # If so, the updated path is stored in $new_path. 49817 49818 input_path="$new_path" 49819 # Check if we need to convert this using DOS-style short mode. If the path 49820 # contains just simple characters, use it. Otherwise (spaces, weird characters), 49821 # take no chances and rewrite it. 49822 # Note: m4 eats our [], so we need to use [ and ] instead. 49823 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 49824 if test "x$has_forbidden_chars" != x; then 49825 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 49826 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 49827 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 49828 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 49829 # Going to short mode and back again did indeed matter. Since short mode is 49830 # case insensitive, let's make it lowercase to improve readability. 49831 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 49832 # Now convert it back to Unix-style (cygpath) 49833 input_path=`$CYGPATH -u "$shortmode_path"` 49834 new_path="$input_path" 49835 fi 49836 fi 49837 49838 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 49839 if test "x$test_cygdrive_prefix" = x; then 49840 # As a simple fix, exclude /usr/bin since it's not a real path. 49841 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 49842 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 49843 # a path prefixed by /cygdrive for fixpath to work. 49844 new_path="$CYGWIN_ROOT_PATH$input_path" 49845 fi 49846 fi 49847 49848 49849 if test "x$path" != "x$new_path"; then 49850 JT_HOME="$new_path" 49851 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting JT_HOME to \"$new_path\"" >&5 49852 $as_echo "$as_me: Rewriting JT_HOME to \"$new_path\"" >&6;} 49853 fi 49854 49855 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 49856 49857 path="$JT_HOME" 49858 has_colon=`$ECHO $path | $GREP ^.:` 49859 new_path="$path" 49860 if test "x$has_colon" = x; then 49861 # Not in mixed or Windows style, start by that. 49862 new_path=`cmd //c echo $path` 49863 fi 49864 49865 49866 input_path="$new_path" 49867 # Check if we need to convert this using DOS-style short mode. If the path 49868 # contains just simple characters, use it. Otherwise (spaces, weird characters), 49869 # take no chances and rewrite it. 49870 # Note: m4 eats our [], so we need to use [ and ] instead. 49871 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 49872 if test "x$has_forbidden_chars" != x; then 49873 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 49874 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 49875 fi 49876 49877 49878 windows_path="$new_path" 49879 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 49880 unix_path=`$CYGPATH -u "$windows_path"` 49881 new_path="$unix_path" 49882 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 49883 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 49884 new_path="$unix_path" 49885 fi 49886 49887 if test "x$path" != "x$new_path"; then 49888 JT_HOME="$new_path" 49889 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting JT_HOME to \"$new_path\"" >&5 49890 $as_echo "$as_me: Rewriting JT_HOME to \"$new_path\"" >&6;} 49891 fi 49892 49893 # Save the first 10 bytes of this path to the storage, so fixpath can work. 49894 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 49895 49896 else 49897 # We're on a unix platform. Hooray! :) 49898 path="$JT_HOME" 49899 has_space=`$ECHO "$path" | $GREP " "` 49900 if test "x$has_space" != x; then 49901 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of JT_HOME, which resolves as \"$path\", is invalid." >&5 49902 $as_echo "$as_me: The path of JT_HOME, which resolves as \"$path\", is invalid." >&6;} 49903 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 49904 fi 49905 49906 # Use eval to expand a potential ~ 49907 eval path="$path" 49908 if test ! -f "$path" && test ! -d "$path"; then 49909 as_fn_error $? "The path of JT_HOME, which resolves as \"$path\", is not found." "$LINENO" 5 49910 fi 49911 49912 if test -d "$path"; then 49913 JT_HOME="`cd "$path"; $THEPWDCMD -L`" 49914 else 49915 dir="`$DIRNAME "$path"`" 49916 base="`$BASENAME "$path"`" 49917 JT_HOME="`cd "$dir"; $THEPWDCMD -L`/$base" 49918 fi 49919 fi 49920 fi 49921 49922 if test ! -d "$JT_HOME"; then 49923 as_fn_error $? "jtreg home directory from --with-jtreg=$with_jtreg does not exist" "$LINENO" 5 49924 fi 49925 49926 if test ! -e "$JT_HOME/lib/jtreg.jar"; then 49927 as_fn_error $? "jtreg home directory from --with-jtreg=$with_jtreg is not a valid jtreg home" "$LINENO" 5 49928 fi 49929 49930 JTREGEXE="$JT_HOME/bin/jtreg" 49931 if test ! -x "$JTREGEXE"; then 49932 as_fn_error $? "jtreg home directory from --with-jtreg=$with_jtreg does not contain valid jtreg executable" "$LINENO" 5 49933 fi 49934 49935 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for jtreg test harness" >&5 49936 $as_echo_n "checking for jtreg test harness... " >&6; } 49937 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $JT_HOME" >&5 49938 $as_echo "$JT_HOME" >&6; } 49939 else 49940 # Try to locate jtreg 49941 if test "x$JT_HOME" != x; then 49942 # JT_HOME set in environment, use it 49943 if test ! -d "$JT_HOME"; then 49944 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring JT_HOME pointing to invalid directory: $JT_HOME" >&5 49945 $as_echo "$as_me: WARNING: Ignoring JT_HOME pointing to invalid directory: $JT_HOME" >&2;} 49946 JT_HOME= 49947 else 49948 if test ! -e "$JT_HOME/lib/jtreg.jar"; then 49949 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring JT_HOME which is not a valid jtreg home: $JT_HOME" >&5 49950 $as_echo "$as_me: WARNING: Ignoring JT_HOME which is not a valid jtreg home: $JT_HOME" >&2;} 49951 JT_HOME= 49952 elif test ! -x "$JT_HOME/bin/jtreg"; then 49953 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring JT_HOME which does not contain valid jtreg executable: $JT_HOME" >&5 49954 $as_echo "$as_me: WARNING: Ignoring JT_HOME which does not contain valid jtreg executable: $JT_HOME" >&2;} 49955 JT_HOME= 49956 else 49957 JTREGEXE="$JT_HOME/bin/jtreg" 49958 { $as_echo "$as_me:${as_lineno-$LINENO}: Located jtreg using JT_HOME from environment" >&5 49959 $as_echo "$as_me: Located jtreg using JT_HOME from environment" >&6;} 49960 fi 49961 fi 49962 fi 49963 49964 if test "x$JT_HOME" = x; then 49965 # JT_HOME is not set in environment, or was deemed invalid. 49966 # Try to find jtreg on path 49967 49968 49969 # Publish this variable in the help. 49970 49971 49972 if [ -z "${JTREGEXE+x}" ]; then 49973 # The variable is not set by user, try to locate tool using the code snippet 49974 for ac_prog in jtreg 49975 do 49976 # Extract the first word of "$ac_prog", so it can be a program name with args. 49977 set dummy $ac_prog; ac_word=$2 49978 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 49979 $as_echo_n "checking for $ac_word... " >&6; } 49980 if ${ac_cv_path_JTREGEXE+:} false; then : 49981 $as_echo_n "(cached) " >&6 49982 else 49983 case $JTREGEXE in 49984 [\\/]* | ?:[\\/]*) 49985 ac_cv_path_JTREGEXE="$JTREGEXE" # Let the user override the test with a path. 49986 ;; 49987 *) 49988 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 49989 for as_dir in $PATH 49990 do 49991 IFS=$as_save_IFS 49992 test -z "$as_dir" && as_dir=. 49993 for ac_exec_ext in '' $ac_executable_extensions; do 49994 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 49995 ac_cv_path_JTREGEXE="$as_dir/$ac_word$ac_exec_ext" 49996 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 49997 break 2 49998 fi 49999 done 50000 done 50001 IFS=$as_save_IFS 50002 50003 ;; 50004 esac 50005 fi 50006 JTREGEXE=$ac_cv_path_JTREGEXE 50007 if test -n "$JTREGEXE"; then 50008 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $JTREGEXE" >&5 50009 $as_echo "$JTREGEXE" >&6; } 50010 else 50011 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 50012 $as_echo "no" >&6; } 50013 fi 50014 50015 50016 test -n "$JTREGEXE" && break 50017 done 50018 50019 else 50020 # The variable is set, but is it from the command line or the environment? 50021 50022 # Try to remove the string !JTREGEXE! from our list. 50023 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!JTREGEXE!/} 50024 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 50025 # If it failed, the variable was not from the command line. Ignore it, 50026 # but warn the user (except for BASH, which is always set by the calling BASH). 50027 if test "xJTREGEXE" != xBASH; then 50028 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of JTREGEXE from the environment. Use command line variables instead." >&5 50029 $as_echo "$as_me: WARNING: Ignoring value of JTREGEXE from the environment. Use command line variables instead." >&2;} 50030 fi 50031 # Try to locate tool using the code snippet 50032 for ac_prog in jtreg 50033 do 50034 # Extract the first word of "$ac_prog", so it can be a program name with args. 50035 set dummy $ac_prog; ac_word=$2 50036 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 50037 $as_echo_n "checking for $ac_word... " >&6; } 50038 if ${ac_cv_path_JTREGEXE+:} false; then : 50039 $as_echo_n "(cached) " >&6 50040 else 50041 case $JTREGEXE in 50042 [\\/]* | ?:[\\/]*) 50043 ac_cv_path_JTREGEXE="$JTREGEXE" # Let the user override the test with a path. 50044 ;; 50045 *) 50046 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 50047 for as_dir in $PATH 50048 do 50049 IFS=$as_save_IFS 50050 test -z "$as_dir" && as_dir=. 50051 for ac_exec_ext in '' $ac_executable_extensions; do 50052 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 50053 ac_cv_path_JTREGEXE="$as_dir/$ac_word$ac_exec_ext" 50054 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 50055 break 2 50056 fi 50057 done 50058 done 50059 IFS=$as_save_IFS 50060 50061 ;; 50062 esac 50063 fi 50064 JTREGEXE=$ac_cv_path_JTREGEXE 50065 if test -n "$JTREGEXE"; then 50066 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $JTREGEXE" >&5 50067 $as_echo "$JTREGEXE" >&6; } 50068 else 50069 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 50070 $as_echo "no" >&6; } 50071 fi 50072 50073 50074 test -n "$JTREGEXE" && break 50075 done 50076 50077 else 50078 # If it succeeded, then it was overridden by the user. We will use it 50079 # for the tool. 50080 50081 # First remove it from the list of overridden variables, so we can test 50082 # for unknown variables in the end. 50083 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 50084 50085 # Check if we try to supply an empty value 50086 if test "x$JTREGEXE" = x; then 50087 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool JTREGEXE= (no value)" >&5 50088 $as_echo "$as_me: Setting user supplied tool JTREGEXE= (no value)" >&6;} 50089 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for JTREGEXE" >&5 50090 $as_echo_n "checking for JTREGEXE... " >&6; } 50091 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 50092 $as_echo "disabled" >&6; } 50093 else 50094 # Check if the provided tool contains a complete path. 50095 tool_specified="$JTREGEXE" 50096 tool_basename="${tool_specified##*/}" 50097 if test "x$tool_basename" = "x$tool_specified"; then 50098 # A command without a complete path is provided, search $PATH. 50099 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool JTREGEXE=$tool_basename" >&5 50100 $as_echo "$as_me: Will search for user supplied tool JTREGEXE=$tool_basename" >&6;} 50101 # Extract the first word of "$tool_basename", so it can be a program name with args. 50102 set dummy $tool_basename; ac_word=$2 50103 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 50104 $as_echo_n "checking for $ac_word... " >&6; } 50105 if ${ac_cv_path_JTREGEXE+:} false; then : 50106 $as_echo_n "(cached) " >&6 50107 else 50108 case $JTREGEXE in 50109 [\\/]* | ?:[\\/]*) 50110 ac_cv_path_JTREGEXE="$JTREGEXE" # Let the user override the test with a path. 50111 ;; 50112 *) 50113 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 50114 for as_dir in $PATH 50115 do 50116 IFS=$as_save_IFS 50117 test -z "$as_dir" && as_dir=. 50118 for ac_exec_ext in '' $ac_executable_extensions; do 50119 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 50120 ac_cv_path_JTREGEXE="$as_dir/$ac_word$ac_exec_ext" 50121 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 50122 break 2 50123 fi 50124 done 50125 done 50126 IFS=$as_save_IFS 50127 50128 ;; 50129 esac 50130 fi 50131 JTREGEXE=$ac_cv_path_JTREGEXE 50132 if test -n "$JTREGEXE"; then 50133 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $JTREGEXE" >&5 50134 $as_echo "$JTREGEXE" >&6; } 50135 else 50136 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 50137 $as_echo "no" >&6; } 50138 fi 50139 50140 50141 if test "x$JTREGEXE" = x; then 50142 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 50143 fi 50144 else 50145 # Otherwise we believe it is a complete path. Use it as it is. 50146 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool JTREGEXE=$tool_specified" >&5 50147 $as_echo "$as_me: Will use user supplied tool JTREGEXE=$tool_specified" >&6;} 50148 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for JTREGEXE" >&5 50149 $as_echo_n "checking for JTREGEXE... " >&6; } 50150 if test ! -x "$tool_specified"; then 50151 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 50152 $as_echo "not found" >&6; } 50153 as_fn_error $? "User supplied tool JTREGEXE=$tool_specified does not exist or is not executable" "$LINENO" 5 50154 fi 50155 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 50156 $as_echo "$tool_specified" >&6; } 50157 fi 50158 fi 50159 fi 50160 50161 fi 50162 50163 50164 if test "x$JTREGEXE" != x; then 50165 # That's good, now try to derive JT_HOME 50166 JT_HOME=`(cd $($DIRNAME $JTREGEXE)/.. && pwd)` 50167 if test ! -e "$JT_HOME/lib/jtreg.jar"; then 50168 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring jtreg from path since a valid jtreg home cannot be found" >&5 50169 $as_echo "$as_me: WARNING: Ignoring jtreg from path since a valid jtreg home cannot be found" >&2;} 50170 JT_HOME= 50171 JTREGEXE= 50172 else 50173 { $as_echo "$as_me:${as_lineno-$LINENO}: Located jtreg using jtreg executable in path" >&5 50174 $as_echo "$as_me: Located jtreg using jtreg executable in path" >&6;} 50175 fi 50176 fi 50177 fi 50178 50179 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for jtreg test harness" >&5 50180 $as_echo_n "checking for jtreg test harness... " >&6; } 50181 if test "x$JT_HOME" != x; then 50182 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $JT_HOME" >&5 50183 $as_echo "$JT_HOME" >&6; } 50184 else 50185 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no, not found" >&5 50186 $as_echo "no, not found" >&6; } 50187 50188 if test "x$with_jtreg" = xyes; then 50189 as_fn_error $? "--with-jtreg was specified, but no jtreg found." "$LINENO" 5 50190 fi 50191 fi 50192 fi 50193 50194 50195 # Only process if variable expands to non-empty 50196 50197 if test "x$JTREGEXE" != x; then 50198 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 50199 50200 # First separate the path from the arguments. This will split at the first 50201 # space. 50202 complete="$JTREGEXE" 50203 path="${complete%% *}" 50204 tmp="$complete EOL" 50205 arguments="${tmp#* }" 50206 50207 # Input might be given as Windows format, start by converting to 50208 # unix format. 50209 new_path=`$CYGPATH -u "$path"` 50210 50211 # Now try to locate executable using which 50212 new_path=`$WHICH "$new_path" 2> /dev/null` 50213 # bat and cmd files are not always considered executable in cygwin causing which 50214 # to not find them 50215 if test "x$new_path" = x \ 50216 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 50217 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 50218 new_path=`$CYGPATH -u "$path"` 50219 fi 50220 if test "x$new_path" = x; then 50221 # Oops. Which didn't find the executable. 50222 # The splitting of arguments from the executable at a space might have been incorrect, 50223 # since paths with space are more likely in Windows. Give it another try with the whole 50224 # argument. 50225 path="$complete" 50226 arguments="EOL" 50227 new_path=`$CYGPATH -u "$path"` 50228 new_path=`$WHICH "$new_path" 2> /dev/null` 50229 # bat and cmd files are not always considered executable in cygwin causing which 50230 # to not find them 50231 if test "x$new_path" = x \ 50232 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 50233 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 50234 new_path=`$CYGPATH -u "$path"` 50235 fi 50236 if test "x$new_path" = x; then 50237 # It's still not found. Now this is an unrecoverable error. 50238 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of JTREGEXE, which resolves as \"$complete\", is not found." >&5 50239 $as_echo "$as_me: The path of JTREGEXE, which resolves as \"$complete\", is not found." >&6;} 50240 has_space=`$ECHO "$complete" | $GREP " "` 50241 if test "x$has_space" != x; then 50242 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 50243 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 50244 fi 50245 as_fn_error $? "Cannot locate the the path of JTREGEXE" "$LINENO" 5 50246 fi 50247 fi 50248 50249 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 50250 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 50251 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 50252 # "foo.exe" is OK but "foo" is an error. 50253 # 50254 # This test is therefore slightly more accurate than "test -f" to check for file presence. 50255 # It is also a way to make sure we got the proper file name for the real test later on. 50256 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 50257 if test "x$test_shortpath" = x; then 50258 # Short path failed, file does not exist as specified. 50259 # Try adding .exe or .cmd 50260 if test -f "${new_path}.exe"; then 50261 input_to_shortpath="${new_path}.exe" 50262 elif test -f "${new_path}.cmd"; then 50263 input_to_shortpath="${new_path}.cmd" 50264 else 50265 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of JTREGEXE, which resolves as \"$new_path\", is invalid." >&5 50266 $as_echo "$as_me: The path of JTREGEXE, which resolves as \"$new_path\", is invalid." >&6;} 50267 { $as_echo "$as_me:${as_lineno-$LINENO}: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&5 50268 $as_echo "$as_me: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&6;} 50269 as_fn_error $? "Cannot locate the the path of JTREGEXE" "$LINENO" 5 50270 fi 50271 else 50272 input_to_shortpath="$new_path" 50273 fi 50274 50275 # Call helper function which possibly converts this using DOS-style short mode. 50276 # If so, the updated path is stored in $new_path. 50277 new_path="$input_to_shortpath" 50278 50279 input_path="$input_to_shortpath" 50280 # Check if we need to convert this using DOS-style short mode. If the path 50281 # contains just simple characters, use it. Otherwise (spaces, weird characters), 50282 # take no chances and rewrite it. 50283 # Note: m4 eats our [], so we need to use [ and ] instead. 50284 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 50285 if test "x$has_forbidden_chars" != x; then 50286 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 50287 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 50288 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 50289 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 50290 # Going to short mode and back again did indeed matter. Since short mode is 50291 # case insensitive, let's make it lowercase to improve readability. 50292 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 50293 # Now convert it back to Unix-style (cygpath) 50294 input_path=`$CYGPATH -u "$shortmode_path"` 50295 new_path="$input_path" 50296 fi 50297 fi 50298 50299 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 50300 if test "x$test_cygdrive_prefix" = x; then 50301 # As a simple fix, exclude /usr/bin since it's not a real path. 50302 if test "x`$ECHO $input_to_shortpath | $GREP ^/usr/bin/`" = x; then 50303 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 50304 # a path prefixed by /cygdrive for fixpath to work. 50305 new_path="$CYGWIN_ROOT_PATH$input_path" 50306 fi 50307 fi 50308 50309 # remove trailing .exe if any 50310 new_path="${new_path/%.exe/}" 50311 50312 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 50313 50314 # First separate the path from the arguments. This will split at the first 50315 # space. 50316 complete="$JTREGEXE" 50317 path="${complete%% *}" 50318 tmp="$complete EOL" 50319 arguments="${tmp#* }" 50320 50321 # Input might be given as Windows format, start by converting to 50322 # unix format. 50323 new_path="$path" 50324 50325 windows_path="$new_path" 50326 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 50327 unix_path=`$CYGPATH -u "$windows_path"` 50328 new_path="$unix_path" 50329 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 50330 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 50331 new_path="$unix_path" 50332 fi 50333 50334 50335 # Now try to locate executable using which 50336 new_path=`$WHICH "$new_path" 2> /dev/null` 50337 50338 if test "x$new_path" = x; then 50339 # Oops. Which didn't find the executable. 50340 # The splitting of arguments from the executable at a space might have been incorrect, 50341 # since paths with space are more likely in Windows. Give it another try with the whole 50342 # argument. 50343 path="$complete" 50344 arguments="EOL" 50345 new_path="$path" 50346 50347 windows_path="$new_path" 50348 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 50349 unix_path=`$CYGPATH -u "$windows_path"` 50350 new_path="$unix_path" 50351 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 50352 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 50353 new_path="$unix_path" 50354 fi 50355 50356 50357 new_path=`$WHICH "$new_path" 2> /dev/null` 50358 # bat and cmd files are not always considered executable in MSYS causing which 50359 # to not find them 50360 if test "x$new_path" = x \ 50361 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 50362 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 50363 new_path="$path" 50364 50365 windows_path="$new_path" 50366 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 50367 unix_path=`$CYGPATH -u "$windows_path"` 50368 new_path="$unix_path" 50369 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 50370 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 50371 new_path="$unix_path" 50372 fi 50373 50374 fi 50375 50376 if test "x$new_path" = x; then 50377 # It's still not found. Now this is an unrecoverable error. 50378 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of JTREGEXE, which resolves as \"$complete\", is not found." >&5 50379 $as_echo "$as_me: The path of JTREGEXE, which resolves as \"$complete\", is not found." >&6;} 50380 has_space=`$ECHO "$complete" | $GREP " "` 50381 if test "x$has_space" != x; then 50382 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 50383 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 50384 fi 50385 as_fn_error $? "Cannot locate the the path of JTREGEXE" "$LINENO" 5 50386 fi 50387 fi 50388 50389 # Now new_path has a complete unix path to the binary 50390 if test "x`$ECHO $new_path | $GREP ^/bin/`" != x; then 50391 # Keep paths in /bin as-is, but remove trailing .exe if any 50392 new_path="${new_path/%.exe/}" 50393 # Do not save /bin paths to all_fixpath_prefixes! 50394 else 50395 # Not in mixed or Windows style, start by that. 50396 new_path=`cmd //c echo $new_path` 50397 50398 input_path="$new_path" 50399 # Check if we need to convert this using DOS-style short mode. If the path 50400 # contains just simple characters, use it. Otherwise (spaces, weird characters), 50401 # take no chances and rewrite it. 50402 # Note: m4 eats our [], so we need to use [ and ] instead. 50403 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 50404 if test "x$has_forbidden_chars" != x; then 50405 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 50406 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 50407 fi 50408 50409 # Output is in $new_path 50410 50411 windows_path="$new_path" 50412 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 50413 unix_path=`$CYGPATH -u "$windows_path"` 50414 new_path="$unix_path" 50415 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 50416 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 50417 new_path="$unix_path" 50418 fi 50419 50420 # remove trailing .exe if any 50421 new_path="${new_path/%.exe/}" 50422 50423 # Save the first 10 bytes of this path to the storage, so fixpath can work. 50424 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 50425 fi 50426 50427 else 50428 # We're on a unix platform. Hooray! :) 50429 # First separate the path from the arguments. This will split at the first 50430 # space. 50431 complete="$JTREGEXE" 50432 path="${complete%% *}" 50433 tmp="$complete EOL" 50434 arguments="${tmp#* }" 50435 50436 # Cannot rely on the command "which" here since it doesn't always work. 50437 is_absolute_path=`$ECHO "$path" | $GREP ^/` 50438 if test -z "$is_absolute_path"; then 50439 # Path to executable is not absolute. Find it. 50440 IFS_save="$IFS" 50441 IFS=: 50442 for p in $PATH; do 50443 if test -f "$p/$path" && test -x "$p/$path"; then 50444 new_path="$p/$path" 50445 break 50446 fi 50447 done 50448 IFS="$IFS_save" 50449 else 50450 # This is an absolute path, we can use it without further modifications. 50451 new_path="$path" 50452 fi 50453 50454 if test "x$new_path" = x; then 50455 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of JTREGEXE, which resolves as \"$complete\", is not found." >&5 50456 $as_echo "$as_me: The path of JTREGEXE, which resolves as \"$complete\", is not found." >&6;} 50457 has_space=`$ECHO "$complete" | $GREP " "` 50458 if test "x$has_space" != x; then 50459 { $as_echo "$as_me:${as_lineno-$LINENO}: This might be caused by spaces in the path, which is not allowed." >&5 50460 $as_echo "$as_me: This might be caused by spaces in the path, which is not allowed." >&6;} 50461 fi 50462 as_fn_error $? "Cannot locate the the path of JTREGEXE" "$LINENO" 5 50463 fi 50464 fi 50465 50466 # Now join together the path and the arguments once again 50467 if test "x$arguments" != xEOL; then 50468 new_complete="$new_path ${arguments% *}" 50469 else 50470 new_complete="$new_path" 50471 fi 50472 50473 if test "x$complete" != "x$new_complete"; then 50474 JTREGEXE="$new_complete" 50475 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting JTREGEXE to \"$new_complete\"" >&5 50476 $as_echo "$as_me: Rewriting JTREGEXE to \"$new_complete\"" >&6;} 50477 fi 50478 fi 50479 50480 50481 # Only process if variable expands to non-empty 50482 50483 if test "x$JT_HOME" != x; then 50484 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 50485 50486 # Input might be given as Windows format, start by converting to 50487 # unix format. 50488 path="$JT_HOME" 50489 new_path=`$CYGPATH -u "$path"` 50490 50491 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 50492 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 50493 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 50494 # "foo.exe" is OK but "foo" is an error. 50495 # 50496 # This test is therefore slightly more accurate than "test -f" to check for file precense. 50497 # It is also a way to make sure we got the proper file name for the real test later on. 50498 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 50499 if test "x$test_shortpath" = x; then 50500 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of JT_HOME, which resolves as \"$path\", is invalid." >&5 50501 $as_echo "$as_me: The path of JT_HOME, which resolves as \"$path\", is invalid." >&6;} 50502 as_fn_error $? "Cannot locate the the path of JT_HOME" "$LINENO" 5 50503 fi 50504 50505 # Call helper function which possibly converts this using DOS-style short mode. 50506 # If so, the updated path is stored in $new_path. 50507 50508 input_path="$new_path" 50509 # Check if we need to convert this using DOS-style short mode. If the path 50510 # contains just simple characters, use it. Otherwise (spaces, weird characters), 50511 # take no chances and rewrite it. 50512 # Note: m4 eats our [], so we need to use [ and ] instead. 50513 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 50514 if test "x$has_forbidden_chars" != x; then 50515 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 50516 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 50517 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 50518 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 50519 # Going to short mode and back again did indeed matter. Since short mode is 50520 # case insensitive, let's make it lowercase to improve readability. 50521 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 50522 # Now convert it back to Unix-style (cygpath) 50523 input_path=`$CYGPATH -u "$shortmode_path"` 50524 new_path="$input_path" 50525 fi 50526 fi 50527 50528 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 50529 if test "x$test_cygdrive_prefix" = x; then 50530 # As a simple fix, exclude /usr/bin since it's not a real path. 50531 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 50532 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 50533 # a path prefixed by /cygdrive for fixpath to work. 50534 new_path="$CYGWIN_ROOT_PATH$input_path" 50535 fi 50536 fi 50537 50538 50539 if test "x$path" != "x$new_path"; then 50540 JT_HOME="$new_path" 50541 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting JT_HOME to \"$new_path\"" >&5 50542 $as_echo "$as_me: Rewriting JT_HOME to \"$new_path\"" >&6;} 50543 fi 50544 50545 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 50546 50547 path="$JT_HOME" 50548 has_colon=`$ECHO $path | $GREP ^.:` 50549 new_path="$path" 50550 if test "x$has_colon" = x; then 50551 # Not in mixed or Windows style, start by that. 50552 new_path=`cmd //c echo $path` 50553 fi 50554 50555 50556 input_path="$new_path" 50557 # Check if we need to convert this using DOS-style short mode. If the path 50558 # contains just simple characters, use it. Otherwise (spaces, weird characters), 50559 # take no chances and rewrite it. 50560 # Note: m4 eats our [], so we need to use [ and ] instead. 50561 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 50562 if test "x$has_forbidden_chars" != x; then 50563 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 50564 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 50565 fi 50566 50567 50568 windows_path="$new_path" 50569 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 50570 unix_path=`$CYGPATH -u "$windows_path"` 50571 new_path="$unix_path" 50572 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 50573 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 50574 new_path="$unix_path" 50575 fi 50576 50577 if test "x$path" != "x$new_path"; then 50578 JT_HOME="$new_path" 50579 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting JT_HOME to \"$new_path\"" >&5 50580 $as_echo "$as_me: Rewriting JT_HOME to \"$new_path\"" >&6;} 50581 fi 50582 50583 # Save the first 10 bytes of this path to the storage, so fixpath can work. 50584 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 50585 50586 else 50587 # We're on a unix platform. Hooray! :) 50588 path="$JT_HOME" 50589 has_space=`$ECHO "$path" | $GREP " "` 50590 if test "x$has_space" != x; then 50591 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of JT_HOME, which resolves as \"$path\", is invalid." >&5 50592 $as_echo "$as_me: The path of JT_HOME, which resolves as \"$path\", is invalid." >&6;} 50593 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 50594 fi 50595 50596 # Use eval to expand a potential ~ 50597 eval path="$path" 50598 if test ! -f "$path" && test ! -d "$path"; then 50599 as_fn_error $? "The path of JT_HOME, which resolves as \"$path\", is not found." "$LINENO" 5 50600 fi 50601 50602 if test -d "$path"; then 50603 JT_HOME="`cd "$path"; $THEPWDCMD -L`" 50604 else 50605 dir="`$DIRNAME "$path"`" 50606 base="`$BASENAME "$path"`" 50607 JT_HOME="`cd "$dir"; $THEPWDCMD -L`/$base" 50608 fi 50609 fi 50610 fi 50611 50612 50613 50614 50615 50616 # Setup Jib dependency tool 50617 50618 50619 # Check whether --with-jib was given. 50620 if test "${with_jib+set}" = set; then : 50621 withval=$with_jib; 50622 fi 50623 50624 50625 if test "x$with_jib" = xno || test "x$with_jib" = x; then 50626 # jib disabled 50627 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for jib" >&5 50628 $as_echo_n "checking for jib... " >&6; } 50629 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 50630 $as_echo "no" >&6; } 50631 elif test "x$with_jib" = xyes; then 50632 as_fn_error $? "Must supply a value to --with-jib" "$LINENO" 5 50633 else 50634 JIB_HOME="${with_jib}" 50635 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for jib" >&5 50636 $as_echo_n "checking for jib... " >&6; } 50637 { $as_echo "$as_me:${as_lineno-$LINENO}: result: ${JIB_HOME}" >&5 50638 $as_echo "${JIB_HOME}" >&6; } 50639 if test ! -d "${JIB_HOME}"; then 50640 as_fn_error $? "--with-jib must be a directory" "$LINENO" 5 50641 fi 50642 JIB_JAR=$(ls ${JIB_HOME}/lib/jib-*.jar) 50643 if test ! -f "${JIB_JAR}"; then 50644 as_fn_error $? "Could not find jib jar file in ${JIB_HOME}" "$LINENO" 5 50645 fi 50646 fi 50647 50648 50649 50650 50651 50652 # COMPILER_TARGET_BITS_FLAG : option for selecting 32- or 64-bit output 50653 # COMPILER_COMMAND_FILE_FLAG : option for passing a command file to the compiler 50654 # COMPILER_BINDCMD_FILE_FLAG : option for specifying a file which saves the binder 50655 # commands produced by the link step (currently AIX only) 50656 if test "x$TOOLCHAIN_TYPE" = xxlc; then 50657 COMPILER_TARGET_BITS_FLAG="-q" 50658 COMPILER_COMMAND_FILE_FLAG="-f" 50659 COMPILER_BINDCMD_FILE_FLAG="-bloadmap:" 50660 else 50661 COMPILER_TARGET_BITS_FLAG="-m" 50662 COMPILER_COMMAND_FILE_FLAG="@" 50663 COMPILER_BINDCMD_FILE_FLAG="" 50664 50665 # The solstudio linker does not support @-files. 50666 if test "x$TOOLCHAIN_TYPE" = xsolstudio; then 50667 COMPILER_COMMAND_FILE_FLAG= 50668 fi 50669 50670 # Check if @file is supported by gcc 50671 if test "x$TOOLCHAIN_TYPE" = xgcc; then 50672 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if @file is supported by gcc" >&5 50673 $as_echo_n "checking if @file is supported by gcc... " >&6; } 50674 # Extra emtpy "" to prevent ECHO from interpreting '--version' as argument 50675 $ECHO "" "--version" > command.file 50676 if $CXX @command.file 2>&5 >&5; then 50677 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 50678 $as_echo "yes" >&6; } 50679 COMPILER_COMMAND_FILE_FLAG="@" 50680 else 50681 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 50682 $as_echo "no" >&6; } 50683 COMPILER_COMMAND_FILE_FLAG= 50684 fi 50685 $RM command.file 50686 fi 50687 fi 50688 50689 50690 50691 50692 # FIXME: figure out if we should select AR flags depending on OS or toolchain. 50693 if test "x$OPENJDK_TARGET_OS" = xmacosx; then 50694 ARFLAGS="-r" 50695 elif test "x$OPENJDK_TARGET_OS" = xaix; then 50696 ARFLAGS="-X64" 50697 elif test "x$OPENJDK_TARGET_OS" = xwindows; then 50698 # lib.exe is used as AR to create static libraries. 50699 ARFLAGS="-nologo -NODEFAULTLIB:MSVCRT" 50700 else 50701 ARFLAGS="" 50702 fi 50703 50704 50705 ## Setup strip. 50706 # FIXME: should this really be per platform, or should it be per toolchain type? 50707 # strip is not provided by clang or solstudio; so guessing platform makes most sense. 50708 # FIXME: we should really only export STRIPFLAGS from here, not POST_STRIP_CMD. 50709 if test "x$OPENJDK_TARGET_OS" = xlinux; then 50710 STRIPFLAGS="-g" 50711 elif test "x$OPENJDK_TARGET_OS" = xsolaris; then 50712 STRIPFLAGS="-x" 50713 elif test "x$OPENJDK_TARGET_OS" = xmacosx; then 50714 STRIPFLAGS="-S" 50715 elif test "x$OPENJDK_TARGET_OS" = xaix; then 50716 STRIPFLAGS="-X32_64" 50717 fi 50718 50719 50720 50721 if test "x$TOOLCHAIN_TYPE" = xmicrosoft; then 50722 CC_OUT_OPTION=-Fo 50723 EXE_OUT_OPTION=-out: 50724 LD_OUT_OPTION=-out: 50725 AR_OUT_OPTION=-out: 50726 else 50727 # The option used to specify the target .o,.a or .so file. 50728 # When compiling, how to specify the to be created object file. 50729 CC_OUT_OPTION='-o$(SPACE)' 50730 # When linking, how to specify the to be created executable. 50731 EXE_OUT_OPTION='-o$(SPACE)' 50732 # When linking, how to specify the to be created dynamically linkable library. 50733 LD_OUT_OPTION='-o$(SPACE)' 50734 # When archiving, how to specify the to be create static archive for object files. 50735 AR_OUT_OPTION='rcs$(SPACE)' 50736 fi 50737 50738 50739 50740 50741 50742 # On Windows, we need to set RC flags. 50743 if test "x$TOOLCHAIN_TYPE" = xmicrosoft; then 50744 RC_FLAGS="-nologo -l0x409" 50745 JVM_RCFLAGS="-nologo" 50746 if test "x$DEBUG_LEVEL" = xrelease; then 50747 RC_FLAGS="$RC_FLAGS -DNDEBUG" 50748 JVM_RCFLAGS="$JVM_RCFLAGS -DNDEBUG" 50749 fi 50750 50751 # The version variables used to create RC_FLAGS may be overridden 50752 # in a custom configure script, or possibly the command line. 50753 # Let those variables be expanded at make time in spec.gmk. 50754 # The \$ are escaped to the shell, and the $(...) variables 50755 # are evaluated by make. 50756 RC_FLAGS="$RC_FLAGS \ 50757 -D\"JDK_VERSION_STRING=\$(VERSION_STRING)\" \ 50758 -D\"JDK_COMPANY=\$(COMPANY_NAME)\" \ 50759 -D\"JDK_COMPONENT=\$(PRODUCT_NAME) \$(JDK_RC_PLATFORM_NAME) binary\" \ 50760 -D\"JDK_VER=\$(VERSION_NUMBER)\" \ 50761 -D\"JDK_COPYRIGHT=Copyright \xA9 $COPYRIGHT_YEAR\" \ 50762 -D\"JDK_NAME=\$(PRODUCT_NAME) \$(JDK_RC_PLATFORM_NAME) \$(VERSION_FEATURE)\" \ 50763 -D\"JDK_FVER=\$(subst .,\$(COMMA),\$(VERSION_NUMBER_FOUR_POSITIONS))\"" 50764 50765 JVM_RCFLAGS="$JVM_RCFLAGS \ 50766 -D\"HS_BUILD_ID=\$(VERSION_STRING)\" \ 50767 -D\"HS_COMPANY=\$(COMPANY_NAME)\" \ 50768 -D\"JDK_DOTVER=\$(VERSION_NUMBER_FOUR_POSITIONS)\" \ 50769 -D\"HS_COPYRIGHT=Copyright $COPYRIGHT_YEAR\" \ 50770 -D\"HS_NAME=\$(PRODUCT_NAME) \$(VERSION_SHORT)\" \ 50771 -D\"JDK_VER=\$(subst .,\$(COMMA),\$(VERSION_NUMBER_FOUR_POSITIONS))\" \ 50772 -D\"HS_FNAME=jvm.dll\" \ 50773 -D\"HS_INTERNAL_NAME=jvm\"" 50774 fi 50775 50776 50777 50778 if test "x$TOOLCHAIN_TYPE" = xmicrosoft; then 50779 # silence copyright notice and other headers. 50780 COMMON_CCXXFLAGS="$COMMON_CCXXFLAGS -nologo" 50781 fi 50782 50783 50784 # Now we can test some aspects on the target using configure macros. 50785 50786 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ANSI C header files" >&5 50787 $as_echo_n "checking for ANSI C header files... " >&6; } 50788 if ${ac_cv_header_stdc+:} false; then : 50789 $as_echo_n "(cached) " >&6 50790 else 50791 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 50792 /* end confdefs.h. */ 50793 #include <stdlib.h> 50794 #include <stdarg.h> 50795 #include <string.h> 50796 #include <float.h> 50797 50798 int 50799 main () 50800 { 50801 50802 ; 50803 return 0; 50804 } 50805 _ACEOF 50806 if ac_fn_cxx_try_compile "$LINENO"; then : 50807 ac_cv_header_stdc=yes 50808 else 50809 ac_cv_header_stdc=no 50810 fi 50811 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext 50812 50813 if test $ac_cv_header_stdc = yes; then 50814 # SunOS 4.x string.h does not declare mem*, contrary to ANSI. 50815 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 50816 /* end confdefs.h. */ 50817 #include <string.h> 50818 50819 _ACEOF 50820 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | 50821 $EGREP "memchr" >/dev/null 2>&1; then : 50822 50823 else 50824 ac_cv_header_stdc=no 50825 fi 50826 rm -f conftest* 50827 50828 fi 50829 50830 if test $ac_cv_header_stdc = yes; then 50831 # ISC 2.0.2 stdlib.h does not declare free, contrary to ANSI. 50832 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 50833 /* end confdefs.h. */ 50834 #include <stdlib.h> 50835 50836 _ACEOF 50837 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | 50838 $EGREP "free" >/dev/null 2>&1; then : 50839 50840 else 50841 ac_cv_header_stdc=no 50842 fi 50843 rm -f conftest* 50844 50845 fi 50846 50847 if test $ac_cv_header_stdc = yes; then 50848 # /bin/cc in Irix-4.0.5 gets non-ANSI ctype macros unless using -ansi. 50849 if test "$cross_compiling" = yes; then : 50850 : 50851 else 50852 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 50853 /* end confdefs.h. */ 50854 #include <ctype.h> 50855 #include <stdlib.h> 50856 #if ((' ' & 0x0FF) == 0x020) 50857 # define ISLOWER(c) ('a' <= (c) && (c) <= 'z') 50858 # define TOUPPER(c) (ISLOWER(c) ? 'A' + ((c) - 'a') : (c)) 50859 #else 50860 # define ISLOWER(c) \ 50861 (('a' <= (c) && (c) <= 'i') \ 50862 || ('j' <= (c) && (c) <= 'r') \ 50863 || ('s' <= (c) && (c) <= 'z')) 50864 # define TOUPPER(c) (ISLOWER(c) ? ((c) | 0x40) : (c)) 50865 #endif 50866 50867 #define XOR(e, f) (((e) && !(f)) || (!(e) && (f))) 50868 int 50869 main () 50870 { 50871 int i; 50872 for (i = 0; i < 256; i++) 50873 if (XOR (islower (i), ISLOWER (i)) 50874 || toupper (i) != TOUPPER (i)) 50875 return 2; 50876 return 0; 50877 } 50878 _ACEOF 50879 if ac_fn_cxx_try_run "$LINENO"; then : 50880 50881 else 50882 ac_cv_header_stdc=no 50883 fi 50884 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \ 50885 conftest.$ac_objext conftest.beam conftest.$ac_ext 50886 fi 50887 50888 fi 50889 fi 50890 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_header_stdc" >&5 50891 $as_echo "$ac_cv_header_stdc" >&6; } 50892 if test $ac_cv_header_stdc = yes; then 50893 50894 $as_echo "#define STDC_HEADERS 1" >>confdefs.h 50895 50896 fi 50897 50898 # On IRIX 5.3, sys/types and inttypes.h are conflicting. 50899 for ac_header in sys/types.h sys/stat.h stdlib.h string.h memory.h strings.h \ 50900 inttypes.h stdint.h unistd.h 50901 do : 50902 as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh` 50903 ac_fn_cxx_check_header_compile "$LINENO" "$ac_header" "$as_ac_Header" "$ac_includes_default 50904 " 50905 if eval test \"x\$"$as_ac_Header"\" = x"yes"; then : 50906 cat >>confdefs.h <<_ACEOF 50907 #define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1 50908 _ACEOF 50909 50910 fi 50911 50912 done 50913 50914 50915 50916 ############################################################################### 50917 # 50918 # Now we check if libjvm.so will use 32 or 64 bit pointers for the C/C++ code. 50919 # (The JVM can use 32 or 64 bit Java pointers but that decision 50920 # is made at runtime.) 50921 # 50922 50923 if test "x$OPENJDK_TARGET_OS" = xsolaris || test "x$OPENJDK_TARGET_OS" = xaix; then 50924 # Always specify -m flag on Solaris 50925 # And -q on AIX because otherwise the compiler produces 32-bit objects by default 50926 50927 # When we add flags to the "official" CFLAGS etc, we need to 50928 # keep track of these additions in ADDED_CFLAGS etc. These 50929 # will later be checked to make sure only controlled additions 50930 # have been made to CFLAGS etc. 50931 ADDED_CFLAGS=" ${COMPILER_TARGET_BITS_FLAG}${OPENJDK_TARGET_CPU_BITS}" 50932 ADDED_CXXFLAGS=" ${COMPILER_TARGET_BITS_FLAG}${OPENJDK_TARGET_CPU_BITS}" 50933 ADDED_LDFLAGS=" ${COMPILER_TARGET_BITS_FLAG}${OPENJDK_TARGET_CPU_BITS}" 50934 50935 CFLAGS="${CFLAGS}${ADDED_CFLAGS}" 50936 CXXFLAGS="${CXXFLAGS}${ADDED_CXXFLAGS}" 50937 LDFLAGS="${LDFLAGS}${ADDED_LDFLAGS}" 50938 50939 CFLAGS_JDK="${CFLAGS_JDK}${ADDED_CFLAGS}" 50940 CXXFLAGS_JDK="${CXXFLAGS_JDK}${ADDED_CXXFLAGS}" 50941 LDFLAGS_JDK="${LDFLAGS_JDK}${ADDED_LDFLAGS}" 50942 50943 JVM_CFLAGS="$JVM_CFLAGS $ADDED_CFLAGS" 50944 JVM_LDFLAGS="$JVM_LDFLAGS $ADDED_LDFLAGS" 50945 JVM_ASFLAGS="$JVM_ASFLAGS $ADDED_CFLAGS" 50946 50947 elif test "x$COMPILE_TYPE" = xreduced; then 50948 if test "x$OPENJDK_TARGET_OS_TYPE" = xunix; then 50949 # Specify -m if running reduced on unix platforms 50950 50951 # When we add flags to the "official" CFLAGS etc, we need to 50952 # keep track of these additions in ADDED_CFLAGS etc. These 50953 # will later be checked to make sure only controlled additions 50954 # have been made to CFLAGS etc. 50955 ADDED_CFLAGS=" ${COMPILER_TARGET_BITS_FLAG}${OPENJDK_TARGET_CPU_BITS}" 50956 ADDED_CXXFLAGS=" ${COMPILER_TARGET_BITS_FLAG}${OPENJDK_TARGET_CPU_BITS}" 50957 ADDED_LDFLAGS=" ${COMPILER_TARGET_BITS_FLAG}${OPENJDK_TARGET_CPU_BITS}" 50958 50959 CFLAGS="${CFLAGS}${ADDED_CFLAGS}" 50960 CXXFLAGS="${CXXFLAGS}${ADDED_CXXFLAGS}" 50961 LDFLAGS="${LDFLAGS}${ADDED_LDFLAGS}" 50962 50963 CFLAGS_JDK="${CFLAGS_JDK}${ADDED_CFLAGS}" 50964 CXXFLAGS_JDK="${CXXFLAGS_JDK}${ADDED_CXXFLAGS}" 50965 LDFLAGS_JDK="${LDFLAGS_JDK}${ADDED_LDFLAGS}" 50966 50967 JVM_CFLAGS="$JVM_CFLAGS $ADDED_CFLAGS" 50968 JVM_LDFLAGS="$JVM_LDFLAGS $ADDED_LDFLAGS" 50969 JVM_ASFLAGS="$JVM_ASFLAGS $ADDED_CFLAGS" 50970 50971 fi 50972 fi 50973 if test "x$OPENJDK_TARGET_OS" = xmacosx; then 50974 JVM_CFLAGS="$JVM_CFLAGS ${COMPILER_TARGET_BITS_FLAG}${OPENJDK_TARGET_CPU_BITS}" 50975 JVM_LDFLAGS="$JVM_LDFLAGS ${COMPILER_TARGET_BITS_FLAG}${OPENJDK_TARGET_CPU_BITS}" 50976 JVM_ASFLAGS="$JVM_ASFLAGS ${COMPILER_TARGET_BITS_FLAG}${OPENJDK_TARGET_CPU_BITS}" 50977 fi 50978 50979 # Make compilation sanity check 50980 for ac_header in stdio.h 50981 do : 50982 ac_fn_cxx_check_header_mongrel "$LINENO" "stdio.h" "ac_cv_header_stdio_h" "$ac_includes_default" 50983 if test "x$ac_cv_header_stdio_h" = xyes; then : 50984 cat >>confdefs.h <<_ACEOF 50985 #define HAVE_STDIO_H 1 50986 _ACEOF 50987 50988 else 50989 50990 { $as_echo "$as_me:${as_lineno-$LINENO}: Failed to compile stdio.h. This likely implies missing compile dependencies." >&5 50991 $as_echo "$as_me: Failed to compile stdio.h. This likely implies missing compile dependencies." >&6;} 50992 if test "x$COMPILE_TYPE" = xreduced; then 50993 50994 # Print a helpful message on how to acquire the necessary build dependency. 50995 # reduced is the help tag: freetype, cups, alsa etc 50996 MISSING_DEPENDENCY=reduced 50997 50998 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 50999 cygwin_help $MISSING_DEPENDENCY 51000 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 51001 msys_help $MISSING_DEPENDENCY 51002 else 51003 PKGHANDLER_COMMAND= 51004 51005 case $PKGHANDLER in 51006 apt-get) 51007 apt_help $MISSING_DEPENDENCY ;; 51008 yum) 51009 yum_help $MISSING_DEPENDENCY ;; 51010 brew) 51011 brew_help $MISSING_DEPENDENCY ;; 51012 port) 51013 port_help $MISSING_DEPENDENCY ;; 51014 pkgutil) 51015 pkgutil_help $MISSING_DEPENDENCY ;; 51016 pkgadd) 51017 pkgadd_help $MISSING_DEPENDENCY ;; 51018 esac 51019 51020 if test "x$PKGHANDLER_COMMAND" != x; then 51021 HELP_MSG="You might be able to fix this by running '$PKGHANDLER_COMMAND'." 51022 fi 51023 fi 51024 51025 { $as_echo "$as_me:${as_lineno-$LINENO}: You are doing a reduced build. Check that you have 32-bit libraries installed. $HELP_MSG" >&5 51026 $as_echo "$as_me: You are doing a reduced build. Check that you have 32-bit libraries installed. $HELP_MSG" >&6;} 51027 elif test "x$COMPILE_TYPE" = xcross; then 51028 { $as_echo "$as_me:${as_lineno-$LINENO}: You are doing a cross-compilation. Check that you have all target platform libraries installed." >&5 51029 $as_echo "$as_me: You are doing a cross-compilation. Check that you have all target platform libraries installed." >&6;} 51030 fi 51031 as_fn_error $? "Cannot continue." "$LINENO" 5 51032 51033 fi 51034 51035 done 51036 51037 51038 # The cast to long int works around a bug in the HP C Compiler 51039 # version HP92453-01 B.11.11.23709.GP, which incorrectly rejects 51040 # declarations like `int a3[[(sizeof (unsigned char)) >= 0]];'. 51041 # This bug is HP SR number 8606223364. 51042 { $as_echo "$as_me:${as_lineno-$LINENO}: checking size of int *" >&5 51043 $as_echo_n "checking size of int *... " >&6; } 51044 if ${ac_cv_sizeof_int_p+:} false; then : 51045 $as_echo_n "(cached) " >&6 51046 else 51047 if ac_fn_cxx_compute_int "$LINENO" "(long int) (sizeof (int *))" "ac_cv_sizeof_int_p" "$ac_includes_default"; then : 51048 51049 else 51050 if test "$ac_cv_type_int_p" = yes; then 51051 { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 51052 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;} 51053 as_fn_error 77 "cannot compute sizeof (int *) 51054 See \`config.log' for more details" "$LINENO" 5; } 51055 else 51056 ac_cv_sizeof_int_p=0 51057 fi 51058 fi 51059 51060 fi 51061 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sizeof_int_p" >&5 51062 $as_echo "$ac_cv_sizeof_int_p" >&6; } 51063 51064 51065 51066 cat >>confdefs.h <<_ACEOF 51067 #define SIZEOF_INT_P $ac_cv_sizeof_int_p 51068 _ACEOF 51069 51070 51071 51072 # AC_CHECK_SIZEOF defines 'ac_cv_sizeof_int_p' to hold the number of bytes used by an 'int*' 51073 if test "x$ac_cv_sizeof_int_p" = x; then 51074 # The test failed, lets stick to the assumed value. 51075 { $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 51076 $as_echo "$as_me: WARNING: The number of bits in the target could not be determined, using $OPENJDK_TARGET_CPU_BITS." >&2;} 51077 else 51078 TESTED_TARGET_CPU_BITS=`expr 8 \* $ac_cv_sizeof_int_p` 51079 51080 if test "x$TESTED_TARGET_CPU_BITS" != "x$OPENJDK_TARGET_CPU_BITS"; then 51081 # This situation may happen on 64-bit platforms where the compiler by default only generates 32-bit objects 51082 # Let's try to implicitely set the compilers target architecture and retry the test 51083 { $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 51084 $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;} 51085 { $as_echo "$as_me:${as_lineno-$LINENO}: Retrying with platforms compiler target bits flag to ${COMPILER_TARGET_BITS_FLAG}${OPENJDK_TARGET_CPU_BITS}" >&5 51086 $as_echo "$as_me: Retrying with platforms compiler target bits flag to ${COMPILER_TARGET_BITS_FLAG}${OPENJDK_TARGET_CPU_BITS}" >&6;} 51087 51088 # When we add flags to the "official" CFLAGS etc, we need to 51089 # keep track of these additions in ADDED_CFLAGS etc. These 51090 # will later be checked to make sure only controlled additions 51091 # have been made to CFLAGS etc. 51092 ADDED_CFLAGS=" ${COMPILER_TARGET_BITS_FLAG}${OPENJDK_TARGET_CPU_BITS}" 51093 ADDED_CXXFLAGS=" ${COMPILER_TARGET_BITS_FLAG}${OPENJDK_TARGET_CPU_BITS}" 51094 ADDED_LDFLAGS=" ${COMPILER_TARGET_BITS_FLAG}${OPENJDK_TARGET_CPU_BITS}" 51095 51096 CFLAGS="${CFLAGS}${ADDED_CFLAGS}" 51097 CXXFLAGS="${CXXFLAGS}${ADDED_CXXFLAGS}" 51098 LDFLAGS="${LDFLAGS}${ADDED_LDFLAGS}" 51099 51100 CFLAGS_JDK="${CFLAGS_JDK}${ADDED_CFLAGS}" 51101 CXXFLAGS_JDK="${CXXFLAGS_JDK}${ADDED_CXXFLAGS}" 51102 LDFLAGS_JDK="${LDFLAGS_JDK}${ADDED_LDFLAGS}" 51103 51104 JVM_CFLAGS="$JVM_CFLAGS $ADDED_CFLAGS" 51105 JVM_LDFLAGS="$JVM_LDFLAGS $ADDED_LDFLAGS" 51106 JVM_ASFLAGS="$JVM_ASFLAGS $ADDED_CFLAGS" 51107 51108 51109 # We have to unset 'ac_cv_sizeof_int_p' first, otherwise AC_CHECK_SIZEOF will use the previously cached value! 51110 unset ac_cv_sizeof_int_p 51111 # And we have to undef the definition of SIZEOF_INT_P in confdefs.h by the previous invocation of AC_CHECK_SIZEOF 51112 cat >>confdefs.h <<_ACEOF 51113 #undef SIZEOF_INT_P 51114 _ACEOF 51115 51116 # The cast to long int works around a bug in the HP C Compiler 51117 # version HP92453-01 B.11.11.23709.GP, which incorrectly rejects 51118 # declarations like `int a3[[(sizeof (unsigned char)) >= 0]];'. 51119 # This bug is HP SR number 8606223364. 51120 { $as_echo "$as_me:${as_lineno-$LINENO}: checking size of int *" >&5 51121 $as_echo_n "checking size of int *... " >&6; } 51122 if ${ac_cv_sizeof_int_p+:} false; then : 51123 $as_echo_n "(cached) " >&6 51124 else 51125 if ac_fn_cxx_compute_int "$LINENO" "(long int) (sizeof (int *))" "ac_cv_sizeof_int_p" "$ac_includes_default"; then : 51126 51127 else 51128 if test "$ac_cv_type_int_p" = yes; then 51129 { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 51130 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;} 51131 as_fn_error 77 "cannot compute sizeof (int *) 51132 See \`config.log' for more details" "$LINENO" 5; } 51133 else 51134 ac_cv_sizeof_int_p=0 51135 fi 51136 fi 51137 51138 fi 51139 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sizeof_int_p" >&5 51140 $as_echo "$ac_cv_sizeof_int_p" >&6; } 51141 51142 51143 51144 cat >>confdefs.h <<_ACEOF 51145 #define SIZEOF_INT_P $ac_cv_sizeof_int_p 51146 _ACEOF 51147 51148 51149 51150 TESTED_TARGET_CPU_BITS=`expr 8 \* $ac_cv_sizeof_int_p` 51151 51152 if test "x$TESTED_TARGET_CPU_BITS" != "x$OPENJDK_TARGET_CPU_BITS"; then 51153 { $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 51154 $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;} 51155 if test "x$COMPILE_TYPE" = xreduced; then 51156 51157 # Print a helpful message on how to acquire the necessary build dependency. 51158 # reduced is the help tag: freetype, cups, alsa etc 51159 MISSING_DEPENDENCY=reduced 51160 51161 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 51162 cygwin_help $MISSING_DEPENDENCY 51163 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 51164 msys_help $MISSING_DEPENDENCY 51165 else 51166 PKGHANDLER_COMMAND= 51167 51168 case $PKGHANDLER in 51169 apt-get) 51170 apt_help $MISSING_DEPENDENCY ;; 51171 yum) 51172 yum_help $MISSING_DEPENDENCY ;; 51173 brew) 51174 brew_help $MISSING_DEPENDENCY ;; 51175 port) 51176 port_help $MISSING_DEPENDENCY ;; 51177 pkgutil) 51178 pkgutil_help $MISSING_DEPENDENCY ;; 51179 pkgadd) 51180 pkgadd_help $MISSING_DEPENDENCY ;; 51181 esac 51182 51183 if test "x$PKGHANDLER_COMMAND" != x; then 51184 HELP_MSG="You might be able to fix this by running '$PKGHANDLER_COMMAND'." 51185 fi 51186 fi 51187 51188 { $as_echo "$as_me:${as_lineno-$LINENO}: You are doing a reduced build. Check that you have 32-bit libraries installed. $HELP_MSG" >&5 51189 $as_echo "$as_me: You are doing a reduced build. Check that you have 32-bit libraries installed. $HELP_MSG" >&6;} 51190 elif test "x$COMPILE_TYPE" = xcross; then 51191 { $as_echo "$as_me:${as_lineno-$LINENO}: You are doing a cross-compilation. Check that you have all target platform libraries installed." >&5 51192 $as_echo "$as_me: You are doing a cross-compilation. Check that you have all target platform libraries installed." >&6;} 51193 fi 51194 as_fn_error $? "Cannot continue." "$LINENO" 5 51195 fi 51196 fi 51197 fi 51198 51199 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for target address size" >&5 51200 $as_echo_n "checking for target address size... " >&6; } 51201 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $OPENJDK_TARGET_CPU_BITS bits" >&5 51202 $as_echo "$OPENJDK_TARGET_CPU_BITS bits" >&6; } 51203 51204 51205 ############################################################################### 51206 # 51207 # Is the target little of big endian? 51208 # 51209 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether byte ordering is bigendian" >&5 51210 $as_echo_n "checking whether byte ordering is bigendian... " >&6; } 51211 if ${ac_cv_c_bigendian+:} false; then : 51212 $as_echo_n "(cached) " >&6 51213 else 51214 ac_cv_c_bigendian=unknown 51215 # See if we're dealing with a universal compiler. 51216 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 51217 /* end confdefs.h. */ 51218 #ifndef __APPLE_CC__ 51219 not a universal capable compiler 51220 #endif 51221 typedef int dummy; 51222 51223 _ACEOF 51224 if ac_fn_cxx_try_compile "$LINENO"; then : 51225 51226 # Check for potential -arch flags. It is not universal unless 51227 # there are at least two -arch flags with different values. 51228 ac_arch= 51229 ac_prev= 51230 for ac_word in $CC $CFLAGS $CPPFLAGS $LDFLAGS; do 51231 if test -n "$ac_prev"; then 51232 case $ac_word in 51233 i?86 | x86_64 | ppc | ppc64) 51234 if test -z "$ac_arch" || test "$ac_arch" = "$ac_word"; then 51235 ac_arch=$ac_word 51236 else 51237 ac_cv_c_bigendian=universal 51238 break 51239 fi 51240 ;; 51241 esac 51242 ac_prev= 51243 elif test "x$ac_word" = "x-arch"; then 51244 ac_prev=arch 51245 fi 51246 done 51247 fi 51248 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext 51249 if test $ac_cv_c_bigendian = unknown; then 51250 # See if sys/param.h defines the BYTE_ORDER macro. 51251 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 51252 /* end confdefs.h. */ 51253 #include <sys/types.h> 51254 #include <sys/param.h> 51255 51256 int 51257 main () 51258 { 51259 #if ! (defined BYTE_ORDER && defined BIG_ENDIAN \ 51260 && defined LITTLE_ENDIAN && BYTE_ORDER && BIG_ENDIAN \ 51261 && LITTLE_ENDIAN) 51262 bogus endian macros 51263 #endif 51264 51265 ; 51266 return 0; 51267 } 51268 _ACEOF 51269 if ac_fn_cxx_try_compile "$LINENO"; then : 51270 # It does; now see whether it defined to BIG_ENDIAN or not. 51271 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 51272 /* end confdefs.h. */ 51273 #include <sys/types.h> 51274 #include <sys/param.h> 51275 51276 int 51277 main () 51278 { 51279 #if BYTE_ORDER != BIG_ENDIAN 51280 not big endian 51281 #endif 51282 51283 ; 51284 return 0; 51285 } 51286 _ACEOF 51287 if ac_fn_cxx_try_compile "$LINENO"; then : 51288 ac_cv_c_bigendian=yes 51289 else 51290 ac_cv_c_bigendian=no 51291 fi 51292 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext 51293 fi 51294 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext 51295 fi 51296 if test $ac_cv_c_bigendian = unknown; then 51297 # See if <limits.h> defines _LITTLE_ENDIAN or _BIG_ENDIAN (e.g., Solaris). 51298 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 51299 /* end confdefs.h. */ 51300 #include <limits.h> 51301 51302 int 51303 main () 51304 { 51305 #if ! (defined _LITTLE_ENDIAN || defined _BIG_ENDIAN) 51306 bogus endian macros 51307 #endif 51308 51309 ; 51310 return 0; 51311 } 51312 _ACEOF 51313 if ac_fn_cxx_try_compile "$LINENO"; then : 51314 # It does; now see whether it defined to _BIG_ENDIAN or not. 51315 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 51316 /* end confdefs.h. */ 51317 #include <limits.h> 51318 51319 int 51320 main () 51321 { 51322 #ifndef _BIG_ENDIAN 51323 not big endian 51324 #endif 51325 51326 ; 51327 return 0; 51328 } 51329 _ACEOF 51330 if ac_fn_cxx_try_compile "$LINENO"; then : 51331 ac_cv_c_bigendian=yes 51332 else 51333 ac_cv_c_bigendian=no 51334 fi 51335 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext 51336 fi 51337 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext 51338 fi 51339 if test $ac_cv_c_bigendian = unknown; then 51340 # Compile a test program. 51341 if test "$cross_compiling" = yes; then : 51342 # Try to guess by grepping values from an object file. 51343 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 51344 /* end confdefs.h. */ 51345 short int ascii_mm[] = 51346 { 0x4249, 0x4765, 0x6E44, 0x6961, 0x6E53, 0x7953, 0 }; 51347 short int ascii_ii[] = 51348 { 0x694C, 0x5454, 0x656C, 0x6E45, 0x6944, 0x6E61, 0 }; 51349 int use_ascii (int i) { 51350 return ascii_mm[i] + ascii_ii[i]; 51351 } 51352 short int ebcdic_ii[] = 51353 { 0x89D3, 0xE3E3, 0x8593, 0x95C5, 0x89C4, 0x9581, 0 }; 51354 short int ebcdic_mm[] = 51355 { 0xC2C9, 0xC785, 0x95C4, 0x8981, 0x95E2, 0xA8E2, 0 }; 51356 int use_ebcdic (int i) { 51357 return ebcdic_mm[i] + ebcdic_ii[i]; 51358 } 51359 extern int foo; 51360 51361 int 51362 main () 51363 { 51364 return use_ascii (foo) == use_ebcdic (foo); 51365 ; 51366 return 0; 51367 } 51368 _ACEOF 51369 if ac_fn_cxx_try_compile "$LINENO"; then : 51370 if grep BIGenDianSyS conftest.$ac_objext >/dev/null; then 51371 ac_cv_c_bigendian=yes 51372 fi 51373 if grep LiTTleEnDian conftest.$ac_objext >/dev/null ; then 51374 if test "$ac_cv_c_bigendian" = unknown; then 51375 ac_cv_c_bigendian=no 51376 else 51377 # finding both strings is unlikely to happen, but who knows? 51378 ac_cv_c_bigendian=unknown 51379 fi 51380 fi 51381 fi 51382 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext 51383 else 51384 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 51385 /* end confdefs.h. */ 51386 $ac_includes_default 51387 int 51388 main () 51389 { 51390 51391 /* Are we little or big endian? From Harbison&Steele. */ 51392 union 51393 { 51394 long int l; 51395 char c[sizeof (long int)]; 51396 } u; 51397 u.l = 1; 51398 return u.c[sizeof (long int) - 1] == 1; 51399 51400 ; 51401 return 0; 51402 } 51403 _ACEOF 51404 if ac_fn_cxx_try_run "$LINENO"; then : 51405 ac_cv_c_bigendian=no 51406 else 51407 ac_cv_c_bigendian=yes 51408 fi 51409 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \ 51410 conftest.$ac_objext conftest.beam conftest.$ac_ext 51411 fi 51412 51413 fi 51414 fi 51415 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_c_bigendian" >&5 51416 $as_echo "$ac_cv_c_bigendian" >&6; } 51417 case $ac_cv_c_bigendian in #( 51418 yes) 51419 ENDIAN="big";; #( 51420 no) 51421 ENDIAN="little" ;; #( 51422 universal) 51423 ENDIAN="universal_endianness" 51424 ;; #( 51425 *) 51426 ENDIAN="unknown" ;; 51427 esac 51428 51429 51430 if test "x$ENDIAN" = xuniversal_endianness; then 51431 as_fn_error $? "Building with both big and little endianness is not supported" "$LINENO" 5 51432 fi 51433 if test "x$ENDIAN" != "x$OPENJDK_TARGET_CPU_ENDIAN"; then 51434 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 51435 fi 51436 51437 51438 # Configure flags for the tools 51439 51440 ############################################################################### 51441 # 51442 # How to compile shared libraries. 51443 # 51444 51445 if test "x$TOOLCHAIN_TYPE" = xgcc; then 51446 PICFLAG="-fPIC" 51447 C_FLAG_REORDER='' 51448 CXX_FLAG_REORDER='' 51449 51450 if test "x$OPENJDK_TARGET_OS" = xmacosx; then 51451 # Linking is different on MacOSX 51452 if test "x$STATIC_BUILD" = xtrue; then 51453 SHARED_LIBRARY_FLAGS ='-undefined dynamic_lookup' 51454 else 51455 SHARED_LIBRARY_FLAGS="-dynamiclib -compatibility_version 1.0.0 -current_version 1.0.0 $PICFLAG" 51456 JVM_CFLAGS="$JVM_CFLAGS $PICFLAG" 51457 fi 51458 SET_EXECUTABLE_ORIGIN='-Wl,-rpath,@loader_path$(or $1,/.)' 51459 SET_SHARED_LIBRARY_ORIGIN="$SET_EXECUTABLE_ORIGIN" 51460 SET_SHARED_LIBRARY_NAME='-Wl,-install_name,@rpath/$1' 51461 SET_SHARED_LIBRARY_MAPFILE='-Wl,-exported_symbols_list,$1' 51462 else 51463 # Default works for linux, might work on other platforms as well. 51464 SHARED_LIBRARY_FLAGS='-shared' 51465 SET_EXECUTABLE_ORIGIN='-Wl,-rpath,\$$ORIGIN$1' 51466 SET_SHARED_LIBRARY_ORIGIN="-Wl,-z,origin $SET_EXECUTABLE_ORIGIN" 51467 SET_SHARED_LIBRARY_NAME='-Wl,-soname=$1' 51468 SET_SHARED_LIBRARY_MAPFILE='-Wl,-version-script=$1' 51469 fi 51470 elif test "x$TOOLCHAIN_TYPE" = xclang; then 51471 C_FLAG_REORDER='' 51472 CXX_FLAG_REORDER='' 51473 51474 if test "x$OPENJDK_TARGET_OS" = xmacosx; then 51475 # Linking is different on MacOSX 51476 PICFLAG='' 51477 SHARED_LIBRARY_FLAGS="-dynamiclib -compatibility_version 1.0.0 -current_version 1.0.0 $PICFLAG" 51478 SET_EXECUTABLE_ORIGIN='-Wl,-rpath,@loader_path$(or $1,/.)' 51479 SET_SHARED_LIBRARY_ORIGIN="$SET_EXECUTABLE_ORIGIN" 51480 SET_SHARED_LIBRARY_NAME='-Wl,-install_name,@rpath/$1' 51481 SET_SHARED_LIBRARY_MAPFILE='-Wl,-exported_symbols_list,$1' 51482 51483 if test "x$STATIC_BUILD" = xfalse; then 51484 JVM_CFLAGS="$JVM_CFLAGS -fPIC" 51485 fi 51486 else 51487 # Default works for linux, might work on other platforms as well. 51488 PICFLAG='-fPIC' 51489 SHARED_LIBRARY_FLAGS='-shared' 51490 SET_EXECUTABLE_ORIGIN='-Wl,-rpath,\$$ORIGIN$1' 51491 SET_SHARED_LIBRARY_NAME='-Wl,-soname=$1' 51492 SET_SHARED_LIBRARY_MAPFILE='-Wl,-version-script=$1' 51493 51494 # arm specific settings 51495 if test "x$OPENJDK_TARGET_CPU" = "xarm"; then 51496 # '-Wl,-z,origin' isn't used on arm. 51497 SET_SHARED_LIBRARY_ORIGIN='-Wl,-rpath,\$$$$ORIGIN$1' 51498 else 51499 SET_SHARED_LIBRARY_ORIGIN="-Wl,-z,origin $SET_EXECUTABLE_ORIGIN" 51500 fi 51501 51502 fi 51503 elif test "x$TOOLCHAIN_TYPE" = xsolstudio; then 51504 if test "x$OPENJDK_TARGET_CPU" = xsparcv9; then 51505 PICFLAG="-xcode=pic32" 51506 else 51507 PICFLAG="-KPIC" 51508 fi 51509 C_FLAG_REORDER='-xF' 51510 CXX_FLAG_REORDER='-xF' 51511 SHARED_LIBRARY_FLAGS="-G" 51512 SET_EXECUTABLE_ORIGIN='-R\$$ORIGIN$1' 51513 SET_SHARED_LIBRARY_ORIGIN="$SET_EXECUTABLE_ORIGIN" 51514 SET_SHARED_LIBRARY_NAME='-h $1' 51515 SET_SHARED_LIBRARY_MAPFILE='-M$1' 51516 elif test "x$TOOLCHAIN_TYPE" = xxlc; then 51517 # '-qpic' defaults to 'qpic=small'. This means that the compiler generates only 51518 # one instruction for accessing the TOC. If the TOC grows larger than 64K, the linker 51519 # will have to patch this single instruction with a call to some out-of-order code which 51520 # does the load from the TOC. This is of course slow. But in that case we also would have 51521 # to use '-bbigtoc' for linking anyway so we could also change the PICFLAG to 'qpic=large'. 51522 # With 'qpic=large' the compiler will by default generate a two-instruction sequence which 51523 # can be patched directly by the linker and does not require a jump to out-of-order code. 51524 # Another alternative instead of using 'qpic=large -bbigtoc' may be to use '-qminimaltoc' 51525 # instead. This creates a distinct TOC for every compilation unit (and thus requires two 51526 # loads for accessing a global variable). But there are rumors that this may be seen as a 51527 # 'performance feature' because of improved code locality of the symbols used in a 51528 # compilation unit. 51529 PICFLAG="-qpic" 51530 JVM_CFLAGS="$JVM_CFLAGS $PICFLAG" 51531 C_FLAG_REORDER='' 51532 CXX_FLAG_REORDER='' 51533 SHARED_LIBRARY_FLAGS="-qmkshrobj -bM:SRE -bnoentry" 51534 SET_EXECUTABLE_ORIGIN="" 51535 SET_SHARED_LIBRARY_ORIGIN='' 51536 SET_SHARED_LIBRARY_NAME='' 51537 SET_SHARED_LIBRARY_MAPFILE='' 51538 elif test "x$TOOLCHAIN_TYPE" = xmicrosoft; then 51539 PICFLAG="" 51540 C_FLAG_REORDER='' 51541 CXX_FLAG_REORDER='' 51542 SHARED_LIBRARY_FLAGS="-dll" 51543 SET_EXECUTABLE_ORIGIN='' 51544 SET_SHARED_LIBRARY_ORIGIN='' 51545 SET_SHARED_LIBRARY_NAME='' 51546 SET_SHARED_LIBRARY_MAPFILE='-def:$1' 51547 fi 51548 51549 51550 51551 51552 51553 51554 51555 51556 51557 # The (cross) compiler is now configured, we can now test capabilities 51558 # of the target platform. 51559 51560 51561 51562 ############################################################################### 51563 # 51564 # Setup the opt flags for different compilers 51565 # and different operating systems. 51566 # 51567 51568 # FIXME: this was indirectly the old default, but just inherited. 51569 # if test "x$TOOLCHAIN_TYPE" = xmicrosoft; then 51570 # C_FLAG_DEPS="-MMD -MF" 51571 # fi 51572 51573 # Generate make dependency files 51574 if test "x$TOOLCHAIN_TYPE" = xgcc; then 51575 C_FLAG_DEPS="-MMD -MF" 51576 elif test "x$TOOLCHAIN_TYPE" = xclang; then 51577 C_FLAG_DEPS="-MMD -MF" 51578 elif test "x$TOOLCHAIN_TYPE" = xsolstudio; then 51579 C_FLAG_DEPS="-xMMD -xMF" 51580 elif test "x$TOOLCHAIN_TYPE" = xxlc; then 51581 C_FLAG_DEPS="-qmakedep=gcc -MF" 51582 fi 51583 CXX_FLAG_DEPS="$C_FLAG_DEPS" 51584 51585 51586 51587 # Debug symbols 51588 if test "x$TOOLCHAIN_TYPE" = xgcc; then 51589 if test "x$OPENJDK_TARGET_CPU_BITS" = "x64" && test "x$DEBUG_LEVEL" = "xfastdebug"; then 51590 # reduce from default "-g2" option to save space 51591 CFLAGS_DEBUG_SYMBOLS="-g1" 51592 CXXFLAGS_DEBUG_SYMBOLS="-g1" 51593 else 51594 CFLAGS_DEBUG_SYMBOLS="-g" 51595 CXXFLAGS_DEBUG_SYMBOLS="-g" 51596 fi 51597 elif test "x$TOOLCHAIN_TYPE" = xclang; then 51598 CFLAGS_DEBUG_SYMBOLS="-g" 51599 CXXFLAGS_DEBUG_SYMBOLS="-g" 51600 elif test "x$TOOLCHAIN_TYPE" = xsolstudio; then 51601 CFLAGS_DEBUG_SYMBOLS="-g -xs" 51602 # -g0 enables debug symbols without disabling inlining. 51603 CXXFLAGS_DEBUG_SYMBOLS="-g0 -xs" 51604 elif test "x$TOOLCHAIN_TYPE" = xxlc; then 51605 CFLAGS_DEBUG_SYMBOLS="-g" 51606 CXXFLAGS_DEBUG_SYMBOLS="-g" 51607 elif test "x$TOOLCHAIN_TYPE" = xmicrosoft; then 51608 CFLAGS_DEBUG_SYMBOLS="-Zi" 51609 CXXFLAGS_DEBUG_SYMBOLS="-Zi" 51610 fi 51611 51612 51613 51614 # Debug symbols for JVM_CFLAGS 51615 if test "x$TOOLCHAIN_TYPE" = xsolstudio; then 51616 JVM_CFLAGS_SYMBOLS="$JVM_CFLAGS_SYMBOLS -xs" 51617 if test "x$DEBUG_LEVEL" = xslowdebug; then 51618 JVM_CFLAGS_SYMBOLS="$JVM_CFLAGS_SYMBOLS -g" 51619 else 51620 # -g0 does not disable inlining, which -g does. 51621 JVM_CFLAGS_SYMBOLS="$JVM_CFLAGS_SYMBOLS -g0" 51622 fi 51623 elif test "x$TOOLCHAIN_TYPE" = xmicrosoft; then 51624 JVM_CFLAGS_SYMBOLS="$JVM_CFLAGS_SYMBOLS -Z7 -d2Zi+" 51625 else 51626 JVM_CFLAGS_SYMBOLS="$JVM_CFLAGS_SYMBOLS -g" 51627 fi 51628 51629 51630 # bounds, memory and behavior checking options 51631 if test "x$TOOLCHAIN_TYPE" = xgcc; then 51632 case $DEBUG_LEVEL in 51633 release ) 51634 # no adjustment 51635 ;; 51636 fastdebug ) 51637 # no adjustment 51638 ;; 51639 slowdebug ) 51640 # FIXME: By adding this to C(XX)FLAGS_DEBUG_OPTIONS/JVM_CFLAGS_SYMBOLS it 51641 # get's added conditionally on whether we produce debug symbols or not. 51642 # This is most likely not really correct. 51643 51644 # Add runtime stack smashing and undefined behavior checks. 51645 # Not all versions of gcc support -fstack-protector 51646 STACK_PROTECTOR_CFLAG="-fstack-protector-all" 51647 51648 51649 51650 51651 51652 51653 51654 51655 51656 51657 51658 51659 51660 51661 51662 51663 51664 51665 51666 51667 51668 51669 51670 51671 51672 51673 51674 51675 51676 51677 51678 51679 51680 51681 51682 51683 51684 51685 51686 51687 51688 51689 # Execute function body 51690 51691 51692 51693 51694 51695 51696 51697 51698 51699 51700 51701 51702 51703 51704 51705 51706 51707 51708 51709 51710 51711 51712 51713 51714 51715 51716 51717 51718 51719 51720 51721 51722 51723 51724 51725 51726 51727 51728 51729 51730 51731 51732 51733 51734 51735 51736 51737 51738 # Execute function body 51739 51740 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if the C compiler supports \"$STACK_PROTECTOR_CFLAG -Werror\"" >&5 51741 $as_echo_n "checking if the C compiler supports \"$STACK_PROTECTOR_CFLAG -Werror\"... " >&6; } 51742 supports=yes 51743 51744 saved_cflags="$CFLAGS" 51745 CFLAGS="$CFLAGS $STACK_PROTECTOR_CFLAG -Werror" 51746 ac_ext=c 51747 ac_cpp='$CPP $CPPFLAGS' 51748 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5' 51749 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' 51750 ac_compiler_gnu=$ac_cv_c_compiler_gnu 51751 51752 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 51753 /* end confdefs.h. */ 51754 int i; 51755 _ACEOF 51756 if ac_fn_c_try_compile "$LINENO"; then : 51757 51758 else 51759 supports=no 51760 fi 51761 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext 51762 ac_ext=cpp 51763 ac_cpp='$CXXCPP $CPPFLAGS' 51764 ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5' 51765 ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' 51766 ac_compiler_gnu=$ac_cv_cxx_compiler_gnu 51767 51768 CFLAGS="$saved_cflags" 51769 51770 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $supports" >&5 51771 $as_echo "$supports" >&6; } 51772 if test "x$supports" = "xyes" ; then 51773 : 51774 C_COMP_SUPPORTS="yes" 51775 else 51776 : 51777 C_COMP_SUPPORTS="no" 51778 fi 51779 51780 51781 51782 51783 51784 51785 51786 51787 51788 51789 51790 51791 51792 51793 51794 51795 51796 51797 51798 51799 51800 51801 51802 51803 51804 51805 51806 51807 51808 51809 51810 51811 51812 51813 51814 51815 51816 51817 51818 51819 51820 51821 51822 51823 51824 51825 51826 51827 51828 51829 51830 51831 51832 51833 51834 51835 51836 51837 51838 # Execute function body 51839 51840 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if the C++ compiler supports \"$STACK_PROTECTOR_CFLAG -Werror\"" >&5 51841 $as_echo_n "checking if the C++ compiler supports \"$STACK_PROTECTOR_CFLAG -Werror\"... " >&6; } 51842 supports=yes 51843 51844 saved_cxxflags="$CXXFLAGS" 51845 CXXFLAGS="$CXXFLAG $STACK_PROTECTOR_CFLAG -Werror" 51846 ac_ext=cpp 51847 ac_cpp='$CXXCPP $CPPFLAGS' 51848 ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5' 51849 ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' 51850 ac_compiler_gnu=$ac_cv_cxx_compiler_gnu 51851 51852 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 51853 /* end confdefs.h. */ 51854 int i; 51855 _ACEOF 51856 if ac_fn_cxx_try_compile "$LINENO"; then : 51857 51858 else 51859 supports=no 51860 fi 51861 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext 51862 ac_ext=cpp 51863 ac_cpp='$CXXCPP $CPPFLAGS' 51864 ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5' 51865 ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' 51866 ac_compiler_gnu=$ac_cv_cxx_compiler_gnu 51867 51868 CXXFLAGS="$saved_cxxflags" 51869 51870 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $supports" >&5 51871 $as_echo "$supports" >&6; } 51872 if test "x$supports" = "xyes" ; then 51873 : 51874 CXX_COMP_SUPPORTS="yes" 51875 else 51876 : 51877 CXX_COMP_SUPPORTS="no" 51878 fi 51879 51880 51881 51882 51883 51884 51885 51886 51887 51888 51889 51890 51891 51892 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if both compilers support \"$STACK_PROTECTOR_CFLAG -Werror\"" >&5 51893 $as_echo_n "checking if both compilers support \"$STACK_PROTECTOR_CFLAG -Werror\"... " >&6; } 51894 supports=no 51895 if test "x$C_COMP_SUPPORTS" = "xyes" -a "x$CXX_COMP_SUPPORTS" = "xyes"; then supports=yes; fi 51896 51897 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $supports" >&5 51898 $as_echo "$supports" >&6; } 51899 if test "x$supports" = "xyes" ; then 51900 : 51901 51902 else 51903 : 51904 STACK_PROTECTOR_CFLAG="" 51905 fi 51906 51907 51908 51909 51910 51911 51912 51913 CFLAGS_DEBUG_OPTIONS="$STACK_PROTECTOR_CFLAG --param ssp-buffer-size=1" 51914 CXXFLAGS_DEBUG_OPTIONS="$STACK_PROTECTOR_CFLAG --param ssp-buffer-size=1" 51915 if test "x$STACK_PROTECTOR_CFLAG" != x; then 51916 JVM_CFLAGS_SYMBOLS="$JVM_CFLAGS_SYMBOLS $STACK_PROTECTOR_CFLAG --param ssp-buffer-size=1" 51917 fi 51918 ;; 51919 esac 51920 fi 51921 51922 if test "x$TOOLCHAIN_TYPE" = xmicrosoft; then 51923 if test "x$DEBUG_LEVEL" != xrelease; then 51924 if test "x$OPENJDK_TARGET_CPU" = xx86_64; then 51925 JVM_CFLAGS="$JVM_CFLAGS -homeparams" 51926 fi 51927 fi 51928 fi 51929 51930 # Optimization levels 51931 if test "x$TOOLCHAIN_TYPE" = xsolstudio; then 51932 CC_HIGHEST="$CC_HIGHEST -fns -fsimple -fsingle -xbuiltin=%all -xdepend -xrestrict -xlibmil" 51933 51934 if test "x$OPENJDK_TARGET_CPU_ARCH" = "xx86"; then 51935 # FIXME: seems we always set -xregs=no%frameptr; put it elsewhere more global? 51936 C_O_FLAG_HIGHEST_JVM="-xO4" 51937 C_O_FLAG_HIGHEST="-xO4 -Wu,-O4~yz $CC_HIGHEST -xalias_level=basic -xregs=no%frameptr" 51938 C_O_FLAG_HI="-xO4 -Wu,-O4~yz -xregs=no%frameptr" 51939 C_O_FLAG_NORM="-xO2 -Wu,-O2~yz -xregs=no%frameptr" 51940 C_O_FLAG_DEBUG="-xregs=no%frameptr" 51941 C_O_FLAG_DEBUG_JVM="" 51942 C_O_FLAG_NONE="-xregs=no%frameptr" 51943 CXX_O_FLAG_HIGHEST_JVM="-xO4" 51944 CXX_O_FLAG_HIGHEST="-xO4 -Qoption ube -O4~yz $CC_HIGHEST -xregs=no%frameptr" 51945 CXX_O_FLAG_HI="-xO4 -Qoption ube -O4~yz -xregs=no%frameptr" 51946 CXX_O_FLAG_NORM="-xO2 -Qoption ube -O2~yz -xregs=no%frameptr" 51947 CXX_O_FLAG_DEBUG="-xregs=no%frameptr" 51948 CXX_O_FLAG_DEBUG_JVM="" 51949 CXX_O_FLAG_NONE="-xregs=no%frameptr" 51950 if test "x$OPENJDK_TARGET_CPU_BITS" = "x32"; then 51951 C_O_FLAG_HIGHEST="$C_O_FLAG_HIGHEST -xchip=pentium" 51952 CXX_O_FLAG_HIGHEST="$CXX_O_FLAG_HIGHEST -xchip=pentium" 51953 fi 51954 elif test "x$OPENJDK_TARGET_CPU_ARCH" = "xsparc"; then 51955 C_O_FLAG_HIGHEST_JVM="-xO4" 51956 C_O_FLAG_HIGHEST="-xO4 -Wc,-Qrm-s -Wc,-Qiselect-T0 $CC_HIGHEST -xalias_level=basic -xprefetch=auto,explicit -xchip=ultra" 51957 C_O_FLAG_HI="-xO4 -Wc,-Qrm-s -Wc,-Qiselect-T0" 51958 C_O_FLAG_NORM="-xO2 -Wc,-Qrm-s -Wc,-Qiselect-T0" 51959 C_O_FLAG_DEBUG="" 51960 C_O_FLAG_DEBUG_JVM="" 51961 C_O_FLAG_NONE="" 51962 CXX_O_FLAG_HIGHEST_JVM="-xO4" 51963 CXX_O_FLAG_HIGHEST="-xO4 -Qoption cg -Qrm-s -Qoption cg -Qiselect-T0 $CC_HIGHEST -xprefetch=auto,explicit -xchip=ultra" 51964 CXX_O_FLAG_HI="-xO4 -Qoption cg -Qrm-s -Qoption cg -Qiselect-T0" 51965 CXX_O_FLAG_NORM="-xO2 -Qoption cg -Qrm-s -Qoption cg -Qiselect-T0" 51966 CXX_O_FLAG_DEBUG="" 51967 CXX_O_FLAG_DEBUG_JVM="" 51968 CXX_O_FLAG_NONE="" 51969 fi 51970 else 51971 # The remaining toolchains share opt flags between CC and CXX; 51972 # setup for C and duplicate afterwards. 51973 if test "x$TOOLCHAIN_TYPE" = xgcc; then 51974 if test "x$OPENJDK_TARGET_OS" = xmacosx; then 51975 # On MacOSX we optimize for size, something 51976 # we should do for all platforms? 51977 C_O_FLAG_HIGHEST_JVM="-Os" 51978 C_O_FLAG_HIGHEST="-Os" 51979 C_O_FLAG_HI="-Os" 51980 C_O_FLAG_NORM="-Os" 51981 C_O_FLAG_SIZE="-Os" 51982 else 51983 C_O_FLAG_HIGHEST_JVM="-O3" 51984 C_O_FLAG_HIGHEST="-O3" 51985 C_O_FLAG_HI="-O3" 51986 C_O_FLAG_NORM="-O2" 51987 C_O_FLAG_SIZE="-Os" 51988 fi 51989 C_O_FLAG_DEBUG="-O0" 51990 if test "x$OPENJDK_TARGET_OS" = xmacosx; then 51991 C_O_FLAG_DEBUG_JVM="" 51992 elif test "x$OPENJDK_TARGET_OS" = xlinux; then 51993 C_O_FLAG_DEBUG_JVM="-O0" 51994 fi 51995 C_O_FLAG_NONE="-O0" 51996 elif test "x$TOOLCHAIN_TYPE" = xclang; then 51997 if test "x$OPENJDK_TARGET_OS" = xmacosx; then 51998 # On MacOSX we optimize for size, something 51999 # we should do for all platforms? 52000 C_O_FLAG_HIGHEST_JVM="-Os" 52001 C_O_FLAG_HIGHEST="-Os" 52002 C_O_FLAG_HI="-Os" 52003 C_O_FLAG_NORM="-Os" 52004 C_O_FLAG_SIZE="-Os" 52005 else 52006 C_O_FLAG_HIGHEST_JVM="-O3" 52007 C_O_FLAG_HIGHEST="-O3" 52008 C_O_FLAG_HI="-O3" 52009 C_O_FLAG_NORM="-O2" 52010 C_O_FLAG_SIZE="-Os" 52011 fi 52012 C_O_FLAG_DEBUG="-O0" 52013 if test "x$OPENJDK_TARGET_OS" = xmacosx; then 52014 C_O_FLAG_DEBUG_JVM="" 52015 elif test "x$OPENJDK_TARGET_OS" = xlinux; then 52016 C_O_FLAG_DEBUG_JVM="-O0" 52017 fi 52018 C_O_FLAG_NONE="-O0" 52019 elif test "x$TOOLCHAIN_TYPE" = xxlc; then 52020 C_O_FLAG_HIGHEST_JVM="-O3 -qhot=level=1 -qinline -qinlglue" 52021 C_O_FLAG_HIGHEST="-O3 -qhot=level=1 -qinline -qinlglue" 52022 C_O_FLAG_HI="-O3 -qinline -qinlglue" 52023 C_O_FLAG_NORM="-O2" 52024 C_O_FLAG_DEBUG="-qnoopt" 52025 # FIXME: Value below not verified. 52026 C_O_FLAG_DEBUG_JVM="" 52027 C_O_FLAG_NONE="-qnoopt" 52028 elif test "x$TOOLCHAIN_TYPE" = xmicrosoft; then 52029 C_O_FLAG_HIGHEST_JVM="-O2 -Oy-" 52030 C_O_FLAG_HIGHEST="-O2" 52031 C_O_FLAG_HI="-O1" 52032 C_O_FLAG_NORM="-O1" 52033 C_O_FLAG_DEBUG="-Od" 52034 C_O_FLAG_DEBUG_JVM="" 52035 C_O_FLAG_NONE="-Od" 52036 C_O_FLAG_SIZE="-Os" 52037 fi 52038 CXX_O_FLAG_HIGHEST_JVM="$C_O_FLAG_HIGHEST_JVM" 52039 CXX_O_FLAG_HIGHEST="$C_O_FLAG_HIGHEST" 52040 CXX_O_FLAG_HI="$C_O_FLAG_HI" 52041 CXX_O_FLAG_NORM="$C_O_FLAG_NORM" 52042 CXX_O_FLAG_DEBUG="$C_O_FLAG_DEBUG" 52043 CXX_O_FLAG_DEBUG_JVM="$C_O_FLAG_DEBUG_JVM" 52044 CXX_O_FLAG_NONE="$C_O_FLAG_NONE" 52045 CXX_O_FLAG_SIZE="$C_O_FLAG_SIZE" 52046 fi 52047 52048 # Adjust optimization flags according to debug level. 52049 case $DEBUG_LEVEL in 52050 release ) 52051 # no adjustment 52052 ;; 52053 fastdebug ) 52054 # Not quite so much optimization 52055 C_O_FLAG_HI="$C_O_FLAG_NORM" 52056 CXX_O_FLAG_HI="$CXX_O_FLAG_NORM" 52057 ;; 52058 slowdebug ) 52059 # Disable optimization 52060 C_O_FLAG_HIGHEST_JVM="$C_O_FLAG_DEBUG_JVM" 52061 C_O_FLAG_HIGHEST="$C_O_FLAG_DEBUG" 52062 C_O_FLAG_HI="$C_O_FLAG_DEBUG" 52063 C_O_FLAG_NORM="$C_O_FLAG_DEBUG" 52064 C_O_FLAG_SIZE="$C_O_FLAG_DEBUG" 52065 CXX_O_FLAG_HIGHEST_JVM="$CXX_O_FLAG_DEBUG_JVM" 52066 CXX_O_FLAG_HIGHEST="$CXX_O_FLAG_DEBUG" 52067 CXX_O_FLAG_HI="$CXX_O_FLAG_DEBUG" 52068 CXX_O_FLAG_NORM="$CXX_O_FLAG_DEBUG" 52069 CXX_O_FLAG_SIZE="$CXX_O_FLAG_DEBUG" 52070 ;; 52071 esac 52072 52073 52074 52075 52076 52077 52078 52079 52080 52081 52082 52083 52084 52085 52086 52087 52088 52089 52090 52091 52092 # Check whether --with-abi-profile was given. 52093 if test "${with_abi_profile+set}" = set; then : 52094 withval=$with_abi_profile; 52095 fi 52096 52097 52098 if test "x$with_abi_profile" != x; then 52099 if test "x$OPENJDK_TARGET_CPU" != xarm && \ 52100 test "x$OPENJDK_TARGET_CPU" != xaarch64; then 52101 as_fn_error $? "--with-abi-profile only available on arm/aarch64" "$LINENO" 5 52102 fi 52103 52104 OPENJDK_TARGET_ABI_PROFILE=$with_abi_profile 52105 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ABI profle" >&5 52106 $as_echo_n "checking for ABI profle... " >&6; } 52107 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $OPENJDK_TARGET_ABI_PROFILE" >&5 52108 $as_echo "$OPENJDK_TARGET_ABI_PROFILE" >&6; } 52109 52110 if test "x$OPENJDK_TARGET_ABI_PROFILE" = xarm-vfp-sflt; then 52111 ARM_FLOAT_TYPE=vfp-sflt 52112 ARM_ARCH_TYPE_FLAGS='-march=armv7-a -mthumb' 52113 elif test "x$OPENJDK_TARGET_ABI_PROFILE" = xarm-vfp-hflt; then 52114 ARM_FLOAT_TYPE=vfp-hflt 52115 ARM_ARCH_TYPE_FLAGS='-march=armv7-a -mthumb' 52116 elif test "x$OPENJDK_TARGET_ABI_PROFILE" = xarm-sflt; then 52117 ARM_FLOAT_TYPE=sflt 52118 ARM_ARCH_TYPE_FLAGS='-march=armv5t -marm' 52119 elif test "x$OPENJDK_TARGET_ABI_PROFILE" = xarmv5-vfp-sflt; then 52120 ARM_FLOAT_TYPE=vfp-sflt 52121 ARM_ARCH_TYPE_FLAGS='-march=armv5t -marm' 52122 elif test "x$OPENJDK_TARGET_ABI_PROFILE" = xarmv6-vfp-hflt; then 52123 ARM_FLOAT_TYPE=vfp-hflt 52124 ARM_ARCH_TYPE_FLAGS='-march=armv6 -marm' 52125 elif test "x$OPENJDK_TARGET_ABI_PROFILE" = xarm64; then 52126 # No special flags, just need to trigger setting JDK_ARCH_ABI_PROP_NAME 52127 ARM_FLOAT_TYPE= 52128 ARM_ARCH_TYPE_FLAGS= 52129 elif test "x$OPENJDK_TARGET_ABI_PROFILE" = xaarch64; then 52130 # No special flags, just need to trigger setting JDK_ARCH_ABI_PROP_NAME 52131 ARM_FLOAT_TYPE= 52132 ARM_ARCH_TYPE_FLAGS= 52133 else 52134 as_fn_error $? "Invalid ABI profile: \"$OPENJDK_TARGET_ABI_PROFILE\"" "$LINENO" 5 52135 fi 52136 52137 if test "x$ARM_FLOAT_TYPE" = xvfp-sflt; then 52138 ARM_FLOAT_TYPE_FLAGS='-mfloat-abi=softfp -mfpu=vfp -DFLOAT_ARCH=-vfp-sflt' 52139 elif test "x$ARM_FLOAT_TYPE" = xvfp-hflt; then 52140 ARM_FLOAT_TYPE_FLAGS='-mfloat-abi=hard -mfpu=vfp -DFLOAT_ARCH=-vfp-hflt' 52141 elif test "x$ARM_FLOAT_TYPE" = xsflt; then 52142 ARM_FLOAT_TYPE_FLAGS='-msoft-float -mfpu=vfp' 52143 fi 52144 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ARM_FLOAT_TYPE floating point flags" >&5 52145 $as_echo_n "checking for $ARM_FLOAT_TYPE floating point flags... " >&6; } 52146 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ARM_FLOAT_TYPE_FLAGS" >&5 52147 $as_echo "$ARM_FLOAT_TYPE_FLAGS" >&6; } 52148 52149 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for arch type flags" >&5 52150 $as_echo_n "checking for arch type flags... " >&6; } 52151 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ARM_ARCH_TYPE_FLAGS" >&5 52152 $as_echo "$ARM_ARCH_TYPE_FLAGS" >&6; } 52153 52154 # Now set JDK_ARCH_ABI_PROP_NAME. This is equivalent to the last part of the 52155 # autoconf target triplet. 52156 JDK_ARCH_ABI_PROP_NAME=`$ECHO $OPENJDK_TARGET_AUTOCONF_NAME | $SED -e 's/.*-\([^-]*\)$/\1/'` 52157 # Sanity check that it is a known ABI. 52158 if test "x$JDK_ARCH_ABI_PROP_NAME" != xgnu && \ 52159 test "x$JDK_ARCH_ABI_PROP_NAME" != xgnueabi && \ 52160 test "x$JDK_ARCH_ABI_PROP_NAME" != xgnueabihf; then 52161 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Unknown autoconf target triplet ABI: \"$JDK_ARCH_ABI_PROP_NAME\"" >&5 52162 $as_echo "$as_me: WARNING: Unknown autoconf target triplet ABI: \"$JDK_ARCH_ABI_PROP_NAME\"" >&2;} 52163 fi 52164 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ABI property name" >&5 52165 $as_echo_n "checking for ABI property name... " >&6; } 52166 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $JDK_ARCH_ABI_PROP_NAME" >&5 52167 $as_echo "$JDK_ARCH_ABI_PROP_NAME" >&6; } 52168 52169 52170 # Pass these on to the open part of configure as if they were set using 52171 # --with-extra-c[xx]flags. 52172 EXTRA_CFLAGS="$EXTRA_CFLAGS $ARM_ARCH_TYPE_FLAGS $ARM_FLOAT_TYPE_FLAGS" 52173 EXTRA_CXXFLAGS="$EXTRA_CXXFLAGS $ARM_ARCH_TYPE_FLAGS $ARM_FLOAT_TYPE_FLAGS" 52174 # Get rid of annoying "note: the mangling of 'va_list' has changed in GCC 4.4" 52175 # FIXME: This should not really be set using extra_cflags. 52176 if test "x$OPENJDK_TARGET_CPU" = xarm; then 52177 EXTRA_CFLAGS="$EXTRA_CFLAGS -Wno-psabi" 52178 EXTRA_CXXFLAGS="$EXTRA_CXXFLAGS -Wno-psabi" 52179 fi 52180 # Also add JDK_ARCH_ABI_PROP_NAME define, but only to CFLAGS. 52181 EXTRA_CFLAGS="$EXTRA_CFLAGS -DJDK_ARCH_ABI_PROP_NAME='\"\$(JDK_ARCH_ABI_PROP_NAME)\"'" 52182 # And pass the architecture flags to the linker as well 52183 EXTRA_LDFLAGS="$EXTRA_LDFLAGS $ARM_ARCH_TYPE_FLAGS $ARM_FLOAT_TYPE_FLAGS" 52184 fi 52185 52186 # When building with an abi profile, the name of that profile is appended on the 52187 # bundle platform, which is used in bundle names. 52188 if test "x$OPENJDK_TARGET_ABI_PROFILE" != x; then 52189 OPENJDK_TARGET_BUNDLE_PLATFORM="$OPENJDK_TARGET_OS_BUNDLE-$OPENJDK_TARGET_ABI_PROFILE" 52190 fi 52191 52192 52193 # Optional POSIX functionality needed by the JVM 52194 # 52195 # Check if clock_gettime is available and in which library. This indicates 52196 # availability of CLOCK_MONOTONIC for hotspot. But we don't need to link, so 52197 # don't let it update LIBS. 52198 save_LIBS="$LIBS" 52199 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for library containing clock_gettime" >&5 52200 $as_echo_n "checking for library containing clock_gettime... " >&6; } 52201 if ${ac_cv_search_clock_gettime+:} false; then : 52202 $as_echo_n "(cached) " >&6 52203 else 52204 ac_func_search_save_LIBS=$LIBS 52205 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 52206 /* end confdefs.h. */ 52207 52208 /* Override any GCC internal prototype to avoid an error. 52209 Use char because int might match the return type of a GCC 52210 builtin and then its argument prototype would still apply. */ 52211 #ifdef __cplusplus 52212 extern "C" 52213 #endif 52214 char clock_gettime (); 52215 int 52216 main () 52217 { 52218 return clock_gettime (); 52219 ; 52220 return 0; 52221 } 52222 _ACEOF 52223 for ac_lib in '' rt; do 52224 if test -z "$ac_lib"; then 52225 ac_res="none required" 52226 else 52227 ac_res=-l$ac_lib 52228 LIBS="-l$ac_lib $ac_func_search_save_LIBS" 52229 fi 52230 if ac_fn_cxx_try_link "$LINENO"; then : 52231 ac_cv_search_clock_gettime=$ac_res 52232 fi 52233 rm -f core conftest.err conftest.$ac_objext \ 52234 conftest$ac_exeext 52235 if ${ac_cv_search_clock_gettime+:} false; then : 52236 break 52237 fi 52238 done 52239 if ${ac_cv_search_clock_gettime+:} false; then : 52240 52241 else 52242 ac_cv_search_clock_gettime=no 52243 fi 52244 rm conftest.$ac_ext 52245 LIBS=$ac_func_search_save_LIBS 52246 fi 52247 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_search_clock_gettime" >&5 52248 $as_echo "$ac_cv_search_clock_gettime" >&6; } 52249 ac_res=$ac_cv_search_clock_gettime 52250 if test "$ac_res" != no; then : 52251 test "$ac_res" = "none required" || LIBS="$ac_res $LIBS" 52252 HAS_CLOCK_GETTIME=true 52253 fi 52254 52255 if test "x$LIBS" = "x-lrt "; then 52256 CLOCK_GETTIME_IN_LIBRT=true 52257 fi 52258 LIBS="$save_LIBS" 52259 52260 52261 # Special extras... 52262 if test "x$TOOLCHAIN_TYPE" = xsolstudio; then 52263 if test "x$OPENJDK_TARGET_CPU_ARCH" = "xsparc"; then 52264 CFLAGS_JDKLIB_EXTRA="${CFLAGS_JDKLIB_EXTRA} -xregs=no%appl" 52265 CXXFLAGS_JDKLIB_EXTRA="${CXXFLAGS_JDKLIB_EXTRA} -xregs=no%appl" 52266 fi 52267 CFLAGS_JDKLIB_EXTRA="${CFLAGS_JDKLIB_EXTRA} -errtags=yes -errfmt" 52268 CXXFLAGS_JDKLIB_EXTRA="${CXXFLAGS_JDKLIB_EXTRA} -errtags=yes -errfmt" 52269 elif test "x$TOOLCHAIN_TYPE" = xxlc; then 52270 CFLAGS_JDK="${CFLAGS_JDK} -qchars=signed -qfullpath -qsaveopt" 52271 CXXFLAGS_JDK="${CXXFLAGS_JDK} -qchars=signed -qfullpath -qsaveopt" 52272 elif test "x$TOOLCHAIN_TYPE" = xgcc; then 52273 CXXSTD_CXXFLAG="-std=gnu++98" 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 52312 52313 52314 52315 52316 # Execute function body 52317 52318 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if the C++ compiler supports \"$CXXSTD_CXXFLAG -Werror\"" >&5 52319 $as_echo_n "checking if the C++ compiler supports \"$CXXSTD_CXXFLAG -Werror\"... " >&6; } 52320 supports=yes 52321 52322 saved_cxxflags="$CXXFLAGS" 52323 CXXFLAGS="$CXXFLAG $CXXSTD_CXXFLAG -Werror" 52324 ac_ext=cpp 52325 ac_cpp='$CXXCPP $CPPFLAGS' 52326 ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5' 52327 ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' 52328 ac_compiler_gnu=$ac_cv_cxx_compiler_gnu 52329 52330 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 52331 /* end confdefs.h. */ 52332 int i; 52333 _ACEOF 52334 if ac_fn_cxx_try_compile "$LINENO"; then : 52335 52336 else 52337 supports=no 52338 fi 52339 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext 52340 ac_ext=cpp 52341 ac_cpp='$CXXCPP $CPPFLAGS' 52342 ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5' 52343 ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' 52344 ac_compiler_gnu=$ac_cv_cxx_compiler_gnu 52345 52346 CXXFLAGS="$saved_cxxflags" 52347 52348 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $supports" >&5 52349 $as_echo "$supports" >&6; } 52350 if test "x$supports" = "xyes" ; then 52351 : 52352 52353 else 52354 : 52355 CXXSTD_CXXFLAG="" 52356 fi 52357 52358 52359 52360 52361 52362 52363 52364 52365 52366 52367 52368 52369 CXXFLAGS_JDK="${CXXFLAGS_JDK} ${CXXSTD_CXXFLAG}" 52370 JVM_CFLAGS="${JVM_CFLAGS} ${CXXSTD_CXXFLAG}" 52371 52372 fi 52373 if test "x$OPENJDK_TARGET_OS" = xsolaris; then 52374 CFLAGS_JDK="${CFLAGS_JDK} -D__solaris__" 52375 CXXFLAGS_JDK="${CXXFLAGS_JDK} -D__solaris__" 52376 fi 52377 52378 CFLAGS_JDK="${CFLAGS_JDK} ${EXTRA_CFLAGS}" 52379 CXXFLAGS_JDK="${CXXFLAGS_JDK} ${EXTRA_CXXFLAGS}" 52380 LDFLAGS_JDK="${LDFLAGS_JDK} ${EXTRA_LDFLAGS}" 52381 52382 ############################################################################### 52383 # 52384 # Now setup the CFLAGS and LDFLAGS for the JDK build. 52385 # Later we will also have CFLAGS and LDFLAGS for the hotspot subrepo build. 52386 # 52387 52388 # Setup compiler/platform specific flags into 52389 # CFLAGS_JDK - C Compiler flags 52390 # CXXFLAGS_JDK - C++ Compiler flags 52391 # COMMON_CCXXFLAGS_JDK - common to C and C++ 52392 if test "x$TOOLCHAIN_TYPE" = xgcc; then 52393 JVM_CFLAGS="$JVM_CFLAGS -D_GNU_SOURCE" 52394 JVM_CFLAGS="$JVM_CFLAGS -D_REENTRANT" 52395 JVM_CFLAGS="$JVM_CFLAGS -fcheck-new" 52396 if test "x$OPENJDK_TARGET_CPU" = xx86; then 52397 # Force compatibility with i586 on 32 bit intel platforms. 52398 COMMON_CCXXFLAGS="${COMMON_CCXXFLAGS} -march=i586" 52399 JVM_CFLAGS="$JVM_CFLAGS -march=i586" 52400 fi 52401 COMMON_CCXXFLAGS_JDK="$COMMON_CCXXFLAGS $COMMON_CCXXFLAGS_JDK -Wall -Wextra -Wno-unused -Wno-unused-parameter -Wformat=2 \ 52402 -pipe -D_GNU_SOURCE -D_REENTRANT -D_LARGEFILE64_SOURCE" 52403 case $OPENJDK_TARGET_CPU_ARCH in 52404 arm ) 52405 # on arm we don't prevent gcc to omit frame pointer but do prevent strict aliasing 52406 CFLAGS_JDK="${CFLAGS_JDK} -fno-strict-aliasing" 52407 COMMON_CCXXFLAGS_JDK="${COMMON_CCXXFLAGS_JDK} -fsigned-char" 52408 ;; 52409 ppc ) 52410 # on ppc we don't prevent gcc to omit frame pointer but do prevent strict aliasing 52411 CFLAGS_JDK="${CFLAGS_JDK} -fno-strict-aliasing" 52412 ;; 52413 s390 ) 52414 COMMON_CCXXFLAGS_JDK="$COMMON_CCXXFLAGS_JDK -fno-omit-frame-pointer -mbackchain -march=z10" 52415 CFLAGS_JDK="${CFLAGS_JDK} -fno-strict-aliasing" 52416 ;; 52417 * ) 52418 COMMON_CCXXFLAGS_JDK="$COMMON_CCXXFLAGS_JDK -fno-omit-frame-pointer" 52419 CFLAGS_JDK="${CFLAGS_JDK} -fno-strict-aliasing" 52420 ;; 52421 esac 52422 52423 52424 52425 52426 52427 52428 52429 52430 52431 52432 52433 52434 52435 52436 52437 52438 52439 52440 52441 52442 52443 52444 52445 52446 52447 52448 52449 52450 52451 52452 52453 52454 52455 52456 52457 52458 52459 52460 52461 52462 52463 52464 52465 52466 52467 52468 52469 52470 52471 52472 52473 52474 52475 52476 # Execute function body 52477 52478 # Need to assign to a variable since m4 is blocked from modifying parts in []. 52479 REFERENCE_VERSION=6 52480 52481 if [[ "$REFERENCE_VERSION" =~ (.*\.){4} ]] ; then 52482 as_fn_error $? "Internal error: Cannot compare to 6, only four parts (W.X.Y.Z) is supported" "$LINENO" 5 52483 fi 52484 52485 if [[ "$REFERENCE_VERSION" =~ [0-9]{6} ]] ; then 52486 as_fn_error $? "Internal error: Cannot compare to 6, only parts < 99999 is supported" "$LINENO" 5 52487 fi 52488 52489 # Version comparison method inspired by http://stackoverflow.com/a/24067243 52490 COMPARABLE_REFERENCE_VERSION=`$AWK -F. '{ printf("%05d%05d%05d%05d\n", $1, $2, $3, $4) }' <<< "$REFERENCE_VERSION"` 52491 52492 if test $COMPARABLE_ACTUAL_VERSION -ge $COMPARABLE_REFERENCE_VERSION ; then 52493 : 52494 52495 # These flags are required for GCC 6 builds as undefined behaviour in OpenJDK code 52496 # runs afoul of the more aggressive versions of these optimisations. 52497 # Notably, value range propagation now assumes that the this pointer of C++ 52498 # member functions is non-null. 52499 NO_DELETE_NULL_POINTER_CHECKS_CFLAG="-fno-delete-null-pointer-checks" 52500 NO_LIFETIME_DSE_CFLAG="-fno-lifetime-dse" 52501 { $as_echo "$as_me:${as_lineno-$LINENO}: GCC >= 6 detected; adding ${NO_DELETE_NULL_POINTER_CHECKS_CFLAG} and ${NO_LIFETIME_DSE_CFLAG}" >&5 52502 $as_echo "$as_me: GCC >= 6 detected; adding ${NO_DELETE_NULL_POINTER_CHECKS_CFLAG} and ${NO_LIFETIME_DSE_CFLAG}" >&6;} 52503 CFLAGS_JDK="$CFLAGS_JDK ${NO_DELETE_NULL_POINTER_CHECKS_CFLAG} ${NO_LIFETIME_DSE_CFLAG}" 52504 JVM_CFLAGS="$JVM_CFLAGS ${NO_DELETE_NULL_POINTER_CHECKS_CFLAG} ${NO_LIFETIME_DSE_CFLAG}" 52505 52506 else 52507 : 52508 52509 fi 52510 52511 52512 52513 52514 52515 52516 52517 52518 52519 52520 52521 52522 52523 52524 elif test "x$TOOLCHAIN_TYPE" = xclang; then 52525 JVM_CFLAGS="$JVM_CFLAGS -D_GNU_SOURCE" 52526 52527 # Restrict the debug information created by Clang to avoid 52528 # too big object files and speed the build up a little bit 52529 # (see http://llvm.org/bugs/show_bug.cgi?id=7554) 52530 JVM_CFLAGS="$JVM_CFLAGS -flimit-debug-info" 52531 if test "x$OPENJDK_TARGET_OS" = xlinux; then 52532 if test "x$OPENJDK_TARGET_CPU" = xx86; then 52533 # Force compatibility with i586 on 32 bit intel platforms. 52534 COMMON_CCXXFLAGS="${COMMON_CCXXFLAGS} -march=i586" 52535 JVM_CFLAGS="$JVM_CFLAGS -march=i586" 52536 fi 52537 JVM_CFLAGS="$JVM_CFLAGS -Wno-sometimes-uninitialized" 52538 COMMON_CCXXFLAGS_JDK="$COMMON_CCXXFLAGS $COMMON_CCXXFLAGS_JDK -Wall -Wextra -Wno-unused -Wno-unused-parameter -Wformat=2 \ 52539 -pipe -D_GNU_SOURCE -D_REENTRANT -D_LARGEFILE64_SOURCE" 52540 case $OPENJDK_TARGET_CPU_ARCH in 52541 ppc ) 52542 # on ppc we don't prevent gcc to omit frame pointer but do prevent strict aliasing 52543 CFLAGS_JDK="${CFLAGS_JDK} -fno-strict-aliasing" 52544 ;; 52545 * ) 52546 COMMON_CCXXFLAGS_JDK="$COMMON_CCXXFLAGS_JDK -fno-omit-frame-pointer" 52547 CFLAGS_JDK="${CFLAGS_JDK} -fno-strict-aliasing" 52548 ;; 52549 esac 52550 fi 52551 elif test "x$TOOLCHAIN_TYPE" = xsolstudio; then 52552 JVM_CFLAGS="$JVM_CFLAGS -DSPARC_WORKS" 52553 COMMON_CCXXFLAGS_JDK="$COMMON_CCXXFLAGS $COMMON_CCXXFLAGS_JDK -DTRACING -DMACRO_MEMSYS_OPS -DBREAKPTS" 52554 if test "x$OPENJDK_TARGET_CPU_ARCH" = xx86; then 52555 COMMON_CCXXFLAGS_JDK="$COMMON_CCXXFLAGS_JDK -DcpuIntel -Di586 -D$OPENJDK_TARGET_CPU_LEGACY_LIB" 52556 fi 52557 52558 CFLAGS_JDK="$CFLAGS_JDK -xc99=%none -xCC -errshort=tags -Xa -v -mt -W0,-noglobal" 52559 CXXFLAGS_JDK="$CXXFLAGS_JDK -errtags=yes +w -mt -features=no%except -DCC_NOEX -norunpath -xnolib" 52560 elif test "x$TOOLCHAIN_TYPE" = xxlc; then 52561 JVM_CFLAGS="$JVM_CFLAGS -D_REENTRANT" 52562 CFLAGS_JDK="$CFLAGS_JDK -D_GNU_SOURCE -D_REENTRANT -D_LARGEFILE64_SOURCE -DSTDC" 52563 CXXFLAGS_JDK="$CXXFLAGS_JDK -D_GNU_SOURCE -D_REENTRANT -D_LARGEFILE64_SOURCE -DSTDC" 52564 elif test "x$TOOLCHAIN_TYPE" = xmicrosoft; then 52565 COMMON_CCXXFLAGS_JDK="$COMMON_CCXXFLAGS $COMMON_CCXXFLAGS_JDK \ 52566 -MD -Zc:wchar_t- -W3 -wd4800 \ 52567 -DWIN32_LEAN_AND_MEAN \ 52568 -D_CRT_SECURE_NO_DEPRECATE -D_CRT_NONSTDC_NO_DEPRECATE \ 52569 -D_WINSOCK_DEPRECATED_NO_WARNINGS \ 52570 -DWIN32 -DIAL" 52571 if test "x$OPENJDK_TARGET_CPU" = xx86_64; then 52572 COMMON_CCXXFLAGS_JDK="$COMMON_CCXXFLAGS_JDK -D_AMD64_ -Damd64" 52573 else 52574 COMMON_CCXXFLAGS_JDK="$COMMON_CCXXFLAGS_JDK -D_X86_ -Dx86" 52575 fi 52576 # If building with Visual Studio 2010, we can still use _STATIC_CPPLIB to 52577 # avoid bundling msvcpNNN.dll. Doesn't work with newer versions of visual 52578 # studio. 52579 if test "x$TOOLCHAIN_VERSION" = "x2010"; then 52580 STATIC_CPPLIB_FLAGS="-D_STATIC_CPPLIB -D_DISABLE_DEPRECATE_STATIC_CPPLIB" 52581 COMMON_CCXXFLAGS_JDK="$COMMON_CCXXFLAGS_JDK $STATIC_CPPLIB_FLAGS" 52582 JVM_CFLAGS="$JVM_CFLAGS $STATIC_CPPLIB_FLAGS" 52583 fi 52584 fi 52585 52586 ############################################################################### 52587 52588 # Adjust flags according to debug level. 52589 case $DEBUG_LEVEL in 52590 fastdebug | slowdebug ) 52591 CFLAGS_JDK="$CFLAGS_JDK $CFLAGS_DEBUG_SYMBOLS $CFLAGS_DEBUG_OPTIONS" 52592 CXXFLAGS_JDK="$CXXFLAGS_JDK $CXXFLAGS_DEBUG_SYMBOLS $CXXFLAGS_DEBUG_OPTIONS" 52593 ;; 52594 release ) 52595 ;; 52596 * ) 52597 as_fn_error $? "Unrecognized \$DEBUG_LEVEL: $DEBUG_LEVEL" "$LINENO" 5 52598 ;; 52599 esac 52600 52601 # Set some common defines. These works for all compilers, but assume 52602 # -D is universally accepted. 52603 52604 # Setup endianness 52605 if test "x$OPENJDK_TARGET_CPU_ENDIAN" = xlittle; then 52606 # The macro _LITTLE_ENDIAN needs to be defined the same to avoid the 52607 # Sun C compiler warning message: warning: macro redefined: _LITTLE_ENDIAN 52608 # (The Solaris X86 system defines this in file /usr/include/sys/isa_defs.h). 52609 # Note: -Dmacro is the same as #define macro 1 52610 # -Dmacro= is the same as #define macro 52611 if test "x$OPENJDK_TARGET_OS" = xsolaris; then 52612 COMMON_CCXXFLAGS_JDK="$COMMON_CCXXFLAGS_JDK -D_LITTLE_ENDIAN=" 52613 else 52614 COMMON_CCXXFLAGS_JDK="$COMMON_CCXXFLAGS_JDK -D_LITTLE_ENDIAN" 52615 fi 52616 else 52617 # Same goes for _BIG_ENDIAN. Do we really need to set *ENDIAN on Solaris if they 52618 # are defined in the system? 52619 if test "x$OPENJDK_TARGET_OS" = xsolaris; then 52620 COMMON_CCXXFLAGS_JDK="$COMMON_CCXXFLAGS_JDK -D_BIG_ENDIAN=" 52621 else 52622 COMMON_CCXXFLAGS_JDK="$COMMON_CCXXFLAGS_JDK -D_BIG_ENDIAN" 52623 fi 52624 fi 52625 52626 # Always enable optional macros for VM. 52627 JVM_CFLAGS="$JVM_CFLAGS -D__STDC_FORMAT_MACROS" 52628 JVM_CFLAGS="$JVM_CFLAGS -D__STDC_LIMIT_MACROS" 52629 JVM_CFLAGS="$JVM_CFLAGS -D__STDC_CONSTANT_MACROS" 52630 52631 # Setup target OS define. Use OS target name but in upper case. 52632 OPENJDK_TARGET_OS_UPPERCASE=`$ECHO $OPENJDK_TARGET_OS | $TR 'abcdefghijklmnopqrstuvwxyz' 'ABCDEFGHIJKLMNOPQRSTUVWXYZ'` 52633 COMMON_CCXXFLAGS_JDK="$COMMON_CCXXFLAGS_JDK -D$OPENJDK_TARGET_OS_UPPERCASE" 52634 52635 # Setup target CPU 52636 COMMON_CCXXFLAGS_JDK="$COMMON_CCXXFLAGS_JDK \ 52637 $OPENJDK_TARGET_ADD_LP64 \ 52638 -DARCH='\"$OPENJDK_TARGET_CPU_LEGACY\"' -D$OPENJDK_TARGET_CPU_LEGACY" 52639 52640 # Setup debug/release defines 52641 if test "x$DEBUG_LEVEL" = xrelease; then 52642 COMMON_CCXXFLAGS_JDK="$COMMON_CCXXFLAGS_JDK -DNDEBUG" 52643 if test "x$OPENJDK_TARGET_OS" = xsolaris; then 52644 COMMON_CCXXFLAGS_JDK="$COMMON_CCXXFLAGS_JDK -DTRIMMED" 52645 fi 52646 else 52647 COMMON_CCXXFLAGS_JDK="$COMMON_CCXXFLAGS_JDK -DDEBUG" 52648 fi 52649 52650 # Optional POSIX functionality needed by the VM 52651 52652 if test "x$HAS_CLOCK_GETTIME" = "xtrue"; then 52653 JVM_CFLAGS="$JVM_CFLAGS -DSUPPORTS_CLOCK_MONOTONIC" 52654 if test "x$CLOCK_GETTIME_IN_LIBRT" = "xtrue"; then 52655 JVM_CFLAGS="$JVM_CFLAGS -DNEEDS_LIBRT" 52656 fi 52657 fi 52658 52659 52660 # Set some additional per-OS defines. 52661 if test "x$OPENJDK_TARGET_OS" = xlinux; then 52662 JVM_CFLAGS="$JVM_CFLAGS -DLINUX" 52663 JVM_CFLAGS="$JVM_CFLAGS -pipe $PICFLAG -fno-rtti -fno-exceptions \ 52664 -fvisibility=hidden -fno-strict-aliasing -fno-omit-frame-pointer" 52665 elif test "x$OPENJDK_TARGET_OS" = xsolaris; then 52666 JVM_CFLAGS="$JVM_CFLAGS -DSOLARIS" 52667 JVM_CFLAGS="$JVM_CFLAGS -template=no%extdef -features=no%split_init \ 52668 -D_Crun_inline_placement -library=stlport4 $PICFLAG -mt -features=no%except" 52669 elif test "x$OPENJDK_TARGET_OS" = xmacosx; then 52670 COMMON_CCXXFLAGS_JDK="$COMMON_CCXXFLAGS_JDK -D_ALLBSD_SOURCE -D_DARWIN_UNLIMITED_SELECT" 52671 JVM_CFLAGS="$JVM_CFLAGS -D_ALLBSD_SOURCE" 52672 JVM_CFLAGS="$JVM_CFLAGS -D_DARWIN_C_SOURCE -D_XOPEN_SOURCE" 52673 JVM_CFLAGS="$JVM_CFLAGS -fno-rtti -fno-exceptions -fvisibility=hidden \ 52674 -mno-omit-leaf-frame-pointer -mstack-alignment=16 -pipe -fno-strict-aliasing \ 52675 -fno-omit-frame-pointer" 52676 elif test "x$OPENJDK_TARGET_OS" = xaix; then 52677 JVM_CFLAGS="$JVM_CFLAGS -DAIX" 52678 JVM_CFLAGS="$JVM_CFLAGS -qtune=balanced \ 52679 -qalias=noansi -qstrict -qtls=default -qlanglvl=c99vla \ 52680 -qlanglvl=noredefmac -qnortti -qnoeh -qignerrno" 52681 # We need '-qminimaltoc' or '-qpic=large -bbigtoc' if the TOC overflows. 52682 # Hotspot now overflows its 64K TOC (currently only for slowdebug), 52683 # so for slowdebug we build with '-qpic=large -bbigtoc'. 52684 if test "x$DEBUG_LEVEL" = xslowdebug; then 52685 JVM_CFLAGS="$JVM_CFLAGS -qpic=large" 52686 fi 52687 elif test "x$OPENJDK_TARGET_OS" = xbsd; then 52688 COMMON_CCXXFLAGS_JDK="$COMMON_CCXXFLAGS_JDK -D_ALLBSD_SOURCE" 52689 elif test "x$OPENJDK_TARGET_OS" = xwindows; then 52690 JVM_CFLAGS="$JVM_CFLAGS -D_WINDOWS -DWIN32 -D_JNI_IMPLEMENTATION_" 52691 JVM_CFLAGS="$JVM_CFLAGS -nologo -W3 -MD -MP" 52692 fi 52693 52694 # Set some additional per-CPU defines. 52695 if test "x$OPENJDK_TARGET_OS-$OPENJDK_TARGET_CPU" = xwindows-x86; then 52696 JVM_CFLAGS="$JVM_CFLAGS -arch:IA32" 52697 elif test "x$OPENJDK_TARGET_OS-$OPENJDK_TARGET_CPU" = xsolaris-sparcv9; then 52698 JVM_CFLAGS="$JVM_CFLAGS -xarch=sparc" 52699 elif test "x$OPENJDK_TARGET_CPU" = xppc64; then 52700 if test "x$OPENJDK_TARGET_OS" = xlinux; then 52701 JVM_CFLAGS="$JVM_CFLAGS -minsert-sched-nops=regroup_exact -mno-multiple -mno-string" 52702 # fixes `relocation truncated to fit' error for gcc 4.1. 52703 JVM_CFLAGS="$JVM_CFLAGS -mminimal-toc" 52704 # Use ppc64 instructions, but schedule for power5 52705 JVM_CFLAGS="$JVM_CFLAGS -mcpu=powerpc64 -mtune=power5" 52706 elif test "x$OPENJDK_TARGET_OS" = xaix; then 52707 JVM_CFLAGS="$JVM_CFLAGS -qarch=ppc64" 52708 fi 52709 elif test "x$OPENJDK_TARGET_CPU" = xppc64le; then 52710 if test "x$OPENJDK_TARGET_OS" = xlinux; then 52711 JVM_CFLAGS="$JVM_CFLAGS -minsert-sched-nops=regroup_exact -mno-multiple -mno-string" 52712 # Little endian machine uses ELFv2 ABI. 52713 JVM_CFLAGS="$JVM_CFLAGS -DABI_ELFv2" 52714 # Use Power8, this is the first CPU to support PPC64 LE with ELFv2 ABI. 52715 JVM_CFLAGS="$JVM_CFLAGS -mcpu=power8 -mtune=power8" 52716 fi 52717 elif test "x$OPENJDK_TARGET_CPU" = xs390x; then 52718 if test "x$OPENJDK_TARGET_OS" = xlinux; then 52719 JVM_CFLAGS="$JVM_CFLAGS -mbackchain -march=z10" 52720 fi 52721 fi 52722 52723 if test "x$OPENJDK_TARGET_CPU_ENDIAN" = xlittle; then 52724 JVM_CFLAGS="$JVM_CFLAGS -DVM_LITTLE_ENDIAN" 52725 fi 52726 52727 if test "x$OPENJDK_TARGET_CPU_BITS" = x64; then 52728 if test "x$OPENJDK_TARGET_OS" != xsolaris && test "x$OPENJDK_TARGET_OS" != xaix; then 52729 # Solaris does not have _LP64=1 in the old build. 52730 # xlc on AIX defines _LP64=1 by default and issues a warning if we redefine it. 52731 JVM_CFLAGS="$JVM_CFLAGS -D_LP64=1" 52732 fi 52733 fi 52734 52735 # Set JVM_CFLAGS warning handling 52736 if test "x$OPENJDK_TARGET_OS" = xlinux; then 52737 JVM_CFLAGS="$JVM_CFLAGS -Wpointer-arith -Wsign-compare -Wunused-function \ 52738 -Wunused-value -Woverloaded-virtual" 52739 52740 if test "x$TOOLCHAIN_TYPE" = xgcc; then 52741 52742 52743 52744 52745 52746 52747 52748 52749 52750 52751 52752 52753 52754 52755 52756 52757 52758 52759 52760 52761 52762 52763 52764 52765 52766 52767 52768 52769 52770 52771 52772 52773 52774 52775 52776 52777 52778 52779 52780 52781 52782 52783 52784 52785 52786 52787 52788 52789 52790 52791 52792 52793 52794 52795 # Execute function body 52796 52797 # Need to assign to a variable since m4 is blocked from modifying parts in []. 52798 REFERENCE_VERSION=4.8 52799 52800 if [[ "$REFERENCE_VERSION" =~ (.*\.){4} ]] ; then 52801 as_fn_error $? "Internal error: Cannot compare to 4.8, only four parts (W.X.Y.Z) is supported" "$LINENO" 5 52802 fi 52803 52804 if [[ "$REFERENCE_VERSION" =~ [0-9]{6} ]] ; then 52805 as_fn_error $? "Internal error: Cannot compare to 4.8, only parts < 99999 is supported" "$LINENO" 5 52806 fi 52807 52808 # Version comparison method inspired by http://stackoverflow.com/a/24067243 52809 COMPARABLE_REFERENCE_VERSION=`$AWK -F. '{ printf("%05d%05d%05d%05d\n", $1, $2, $3, $4) }' <<< "$REFERENCE_VERSION"` 52810 52811 if test $COMPARABLE_ACTUAL_VERSION -ge $COMPARABLE_REFERENCE_VERSION ; then 52812 : 52813 52814 # These flags either do not work or give spurious warnings prior to gcc 4.8. 52815 JVM_CFLAGS="$JVM_CFLAGS -Wno-format-zero-length -Wtype-limits -Wuninitialized" 52816 52817 52818 else 52819 : 52820 52821 fi 52822 52823 52824 52825 52826 52827 52828 52829 52830 52831 52832 52833 52834 52835 52836 fi 52837 if ! [[ " $JVM_VARIANTS " =~ " zero " ]] ; then 52838 # Non-zero builds have stricter warnings 52839 JVM_CFLAGS="$JVM_CFLAGS -Wreturn-type -Wundef -Wformat=2" 52840 else 52841 if test "x$TOOLCHAIN_TYPE" = xclang; then 52842 # Some versions of llvm do not like -Wundef 52843 JVM_CFLAGS="$JVM_CFLAGS -Wno-undef" 52844 fi 52845 fi 52846 elif test "x$OPENJDK_TARGET_OS" = xmacosx; then 52847 JVM_CFLAGS="$JVM_CFLAGS -Wno-deprecated -Wpointer-arith \ 52848 -Wsign-compare -Wundef -Wunused-function -Wformat=2" 52849 fi 52850 52851 # Additional macosx handling 52852 if test "x$OPENJDK_TARGET_OS" = xmacosx; then 52853 # MACOSX_VERSION_MIN is the c++ and ld is -mmacosx-version-min argument. The expected 52854 # format is X.Y.Z. It's hard-coded to the minimum OSX version on which the 52855 # JDK can be built and makes the linked binaries compatible even if built on 52856 # a newer version of the OS. 52857 MACOSX_VERSION_MIN=10.7.0 52858 52859 52860 # Setting --with-macosx-version-max=<version> makes it an error to build or 52861 # link to macosx APIs that are newer than the given OS version. The expected 52862 # format for <version> is either nn.n.n or nn.nn.nn. See /usr/include/AvailabilityMacros.h. 52863 52864 # Check whether --with-macosx-version-max was given. 52865 if test "${with_macosx_version_max+set}" = set; then : 52866 withval=$with_macosx_version_max; 52867 if echo "$with_macosx_version_max" | $GREP -q "^[0-9][0-9]\.[0-9]\.[0-9]\$"; then 52868 MACOSX_VERSION_MAX=$with_macosx_version_max 52869 elif echo "$with_macosx_version_max" | $GREP -q "^[0-9][0-9]\.[0-9][0-9]\.[0-9][0-9]\$"; then 52870 MACOSX_VERSION_MAX=$with_macosx_version_max 52871 elif test "x$with_macosx_version_max" = "xno"; then 52872 # Use build system default 52873 MACOSX_VERSION_MAX= 52874 else 52875 as_fn_error $? "osx version format must be nn.n.n or nn.nn.nn" "$LINENO" 5 52876 fi 52877 52878 else 52879 MACOSX_VERSION_MAX= 52880 52881 fi 52882 52883 52884 52885 # Let the flags variables get resolved in make for easier override on make 52886 # command line. AvailabilityMacros.h versions have no dots, ex: 1070. 52887 COMMON_CCXXFLAGS_JDK="$COMMON_CCXXFLAGS_JDK \ 52888 -DMAC_OS_X_VERSION_MIN_REQUIRED=\$(subst .,,\$(MACOSX_VERSION_MIN)) \ 52889 -mmacosx-version-min=\$(MACOSX_VERSION_MIN)" 52890 LDFLAGS_JDK="$LDFLAGS_JDK -mmacosx-version-min=\$(MACOSX_VERSION_MIN)" 52891 JVM_CFLAGS="$JVM_CFLAGS \ 52892 -DMAC_OS_X_VERSION_MIN_REQUIRED=\$(subst .,,\$(MACOSX_VERSION_MIN)) \ 52893 -mmacosx-version-min=\$(MACOSX_VERSION_MIN)" 52894 52895 if test -n "$MACOSX_VERSION_MAX"; then 52896 COMMON_CCXXFLAGS_JDK="$COMMON_CCXXFLAGS_JDK \ 52897 -DMAC_OS_X_VERSION_MAX_ALLOWED=\$(subst .,,\$(MACOSX_VERSION_MAX))" 52898 JVM_CFLAGS="$JVM_CFLAGS \ 52899 -DMAC_OS_X_VERSION_MAX_ALLOWED=\$(subst .,,\$(MACOSX_VERSION_MAX))" 52900 fi 52901 fi 52902 52903 # Setup some hard coded includes 52904 COMMON_CCXXFLAGS_JDK="$COMMON_CCXXFLAGS_JDK \ 52905 -I\$(SUPPORT_OUTPUTDIR)/modules_include/java.base \ 52906 -I\$(SUPPORT_OUTPUTDIR)/modules_include/java.base/\$(OPENJDK_TARGET_OS_INCLUDE_SUBDIR) \ 52907 -I${TOPDIR}/src/java.base/share/native/libjava \ 52908 -I${TOPDIR}/src/java.base/$OPENJDK_TARGET_OS_TYPE/native/libjava \ 52909 -I${TOPDIR}/src/hotspot/share/include \ 52910 -I${TOPDIR}/src/hotspot/os/${HOTSPOT_TARGET_OS_TYPE}/include" 52911 52912 # The shared libraries are compiled using the picflag. 52913 CFLAGS_JDKLIB="$COMMON_CCXXFLAGS_JDK \ 52914 $CFLAGS_JDK $EXTRA_CFLAGS_JDK $PICFLAG $CFLAGS_JDKLIB_EXTRA" 52915 CXXFLAGS_JDKLIB="$COMMON_CCXXFLAGS_JDK \ 52916 $CXXFLAGS_JDK $EXTRA_CXXFLAGS_JDK $PICFLAG $CXXFLAGS_JDKLIB_EXTRA" 52917 52918 # Executable flags 52919 CFLAGS_JDKEXE="$COMMON_CCXXFLAGS_JDK $CFLAGS_JDK $EXTRA_CFLAGS_JDK" 52920 CXXFLAGS_JDKEXE="$COMMON_CCXXFLAGS_JDK $CXXFLAGS_JDK $EXTRA_CXXFLAGS_JDK" 52921 52922 52923 52924 52925 52926 52927 # Setup LDFLAGS et al. 52928 # 52929 52930 if test "x$TOOLCHAIN_TYPE" = xmicrosoft; then 52931 LDFLAGS_MICROSOFT="-nologo -opt:ref" 52932 LDFLAGS_JDK="$LDFLAGS_JDK $LDFLAGS_MICROSOFT -incremental:no" 52933 JVM_LDFLAGS="$JVM_LDFLAGS $LDFLAGS_MICROSOFT -opt:icf,8 -subsystem:windows -base:0x8000000" 52934 if test "x$OPENJDK_TARGET_CPU_BITS" = "x32"; then 52935 LDFLAGS_SAFESH="-safeseh" 52936 LDFLAGS_JDK="$LDFLAGS_JDK $LDFLAGS_SAFESH" 52937 JVM_LDFLAGS="$JVM_LDFLAGS $LDFLAGS_SAFESH" 52938 # NOTE: Old build added -machine. Probably not needed. 52939 JVM_LDFLAGS="$JVM_LDFLAGS -machine:I386" 52940 else 52941 JVM_LDFLAGS="$JVM_LDFLAGS -machine:AMD64" 52942 fi 52943 elif test "x$TOOLCHAIN_TYPE" = xclang; then 52944 JVM_LDFLAGS="$JVM_LDFLAGS -mno-omit-leaf-frame-pointer -mstack-alignment=16 -stdlib=libstdc++ -fPIC" 52945 if test "x$OPENJDK_TARGET_OS" = xmacosx; then 52946 # FIXME: We should really generalize SET_SHARED_LIBRARY_ORIGIN instead. 52947 JVM_LDFLAGS="$JVM_LDFLAGS -Wl,-rpath,@loader_path/. -Wl,-rpath,@loader_path/.." 52948 fi 52949 elif test "x$TOOLCHAIN_TYPE" = xgcc; then 52950 # If this is a --hash-style=gnu system, use --hash-style=both, why? 52951 # We have previously set HAS_GNU_HASH if this is the case 52952 if test -n "$HAS_GNU_HASH"; then 52953 LDFLAGS_HASH_STYLE="-Wl,--hash-style=both" 52954 LDFLAGS_JDK="${LDFLAGS_JDK} $LDFLAGS_HASH_STYLE" 52955 JVM_LDFLAGS="$JVM_LDFLAGS $LDFLAGS_HASH_STYLE" 52956 fi 52957 if test "x$OPENJDK_TARGET_OS" = xmacosx; then 52958 JVM_LDFLAGS="$JVM_LDFLAGS -Wl,-rpath,@loader_path/. -Wl,-rpath,@loader_path/.." 52959 fi 52960 if test "x$OPENJDK_TARGET_OS" = xlinux; then 52961 # And since we now know that the linker is gnu, then add -z defs, to forbid 52962 # undefined symbols in object files. 52963 LDFLAGS_NO_UNDEF_SYM="-Wl,-z,defs" 52964 LDFLAGS_JDK="${LDFLAGS_JDK} $LDFLAGS_NO_UNDEF_SYM" 52965 JVM_LDFLAGS="$JVM_LDFLAGS $LDFLAGS_NO_UNDEF_SYM" 52966 LDFLAGS_NO_EXEC_STACK="-Wl,-z,noexecstack" 52967 JVM_LDFLAGS="$JVM_LDFLAGS $LDFLAGS_NO_EXEC_STACK" 52968 if test "x$OPENJDK_TARGET_CPU" = xx86; then 52969 JVM_LDFLAGS="$JVM_LDFLAGS -march=i586" 52970 fi 52971 case $DEBUG_LEVEL in 52972 release ) 52973 # tell linker to optimize libraries. 52974 # Should this be supplied to the OSS linker as well? 52975 LDFLAGS_DEBUGLEVEL_release="-Wl,-O1" 52976 LDFLAGS_JDK="${LDFLAGS_JDK} $LDFLAGS_DEBUGLEVEL_release" 52977 JVM_LDFLAGS="$JVM_LDFLAGS $LDFLAGS_DEBUGLEVEL_release" 52978 if test "x$HAS_LINKER_RELRO" = "xtrue"; then 52979 JVM_LDFLAGS="$JVM_LDFLAGS $LINKER_RELRO_FLAG" 52980 fi 52981 ;; 52982 slowdebug ) 52983 # Hotspot always let the linker optimize 52984 JVM_LDFLAGS="$JVM_LDFLAGS -Wl,-O1" 52985 if test "x$HAS_LINKER_NOW" = "xtrue"; then 52986 # do relocations at load 52987 LDFLAGS_JDK="$LDFLAGS_JDK $LINKER_NOW_FLAG" 52988 LDFLAGS_CXX_JDK="$LDFLAGS_CXX_JDK $LINKER_NOW_FLAG" 52989 JVM_LDFLAGS="$JVM_LDFLAGS $LINKER_NOW_FLAG" 52990 fi 52991 if test "x$HAS_LINKER_RELRO" = "xtrue"; then 52992 # mark relocations read only 52993 LDFLAGS_JDK="$LDFLAGS_JDK $LINKER_RELRO_FLAG" 52994 LDFLAGS_CXX_JDK="$LDFLAGS_CXX_JDK $LINKER_RELRO_FLAG" 52995 JVM_LDFLAGS="$JVM_LDFLAGS $LINKER_RELRO_FLAG" 52996 fi 52997 ;; 52998 fastdebug ) 52999 # Hotspot always let the linker optimize 53000 JVM_LDFLAGS="$JVM_LDFLAGS -Wl,-O1" 53001 if test "x$HAS_LINKER_RELRO" = "xtrue"; then 53002 # mark relocations read only 53003 LDFLAGS_JDK="$LDFLAGS_JDK $LINKER_RELRO_FLAG" 53004 LDFLAGS_CXX_JDK="$LDFLAGS_CXX_JDK $LINKER_RELRO_FLAG" 53005 JVM_LDFLAGS="$JVM_LDFLAGS $LINKER_RELRO_FLAG" 53006 fi 53007 ;; 53008 * ) 53009 as_fn_error $? "Unrecognized \$DEBUG_LEVEL: $DEBUG_LEVEL" "$LINENO" 5 53010 ;; 53011 esac 53012 fi 53013 elif test "x$TOOLCHAIN_TYPE" = xsolstudio; then 53014 LDFLAGS_SOLSTUDIO="-Wl,-z,defs" 53015 LDFLAGS_JDK="$LDFLAGS_JDK $LDFLAGS_SOLSTUDIO -ztext" 53016 LDFLAGS_CXX_SOLSTUDIO="-norunpath" 53017 LDFLAGS_CXX_JDK="$LDFLAGS_CXX_JDK $LDFLAGS_CXX_SOLSTUDIO -xnolib" 53018 JVM_LDFLAGS="$JVM_LDFLAGS $LDFLAGS_SOLSTUDIO -library=%none -mt $LDFLAGS_CXX_SOLSTUDIO -z noversion" 53019 if test "x$OPENJDK_TARGET_CPU_ARCH" = "xsparc"; then 53020 JVM_LDFLAGS="$JVM_LDFLAGS -xarch=sparc" 53021 fi 53022 elif test "x$TOOLCHAIN_TYPE" = xxlc; then 53023 LDFLAGS_XLC="-b64 -brtl -bnolibpath -bexpall -bernotok -btextpsize:64K -bdatapsize:64K -bstackpsize:64K" 53024 LDFLAGS_JDK="${LDFLAGS_JDK} $LDFLAGS_XLC" 53025 JVM_LDFLAGS="$JVM_LDFLAGS $LDFLAGS_XLC" 53026 # We need '-qminimaltoc' or '-qpic=large -bbigtoc' if the TOC overflows. 53027 # Hotspot now overflows its 64K TOC (currently only for slowdebug), 53028 # so for slowdebug we build with '-qpic=large -bbigtoc'. 53029 if test "x$DEBUG_LEVEL" = xslowdebug; then 53030 JVM_LDFLAGS="$JVM_LDFLAGS -bbigtoc" 53031 fi 53032 fi 53033 53034 # Customize LDFLAGS for executables 53035 53036 LDFLAGS_JDKEXE="${LDFLAGS_JDK}" 53037 53038 if test "x$TOOLCHAIN_TYPE" = xmicrosoft; then 53039 if test "x$OPENJDK_TARGET_CPU_BITS" = "x64"; then 53040 LDFLAGS_STACK_SIZE=1048576 53041 else 53042 LDFLAGS_STACK_SIZE=327680 53043 fi 53044 LDFLAGS_JDKEXE="${LDFLAGS_JDKEXE} /STACK:$LDFLAGS_STACK_SIZE" 53045 elif test "x$OPENJDK_TARGET_OS" = xlinux; then 53046 LDFLAGS_JDKEXE="$LDFLAGS_JDKEXE -Wl,--allow-shlib-undefined" 53047 fi 53048 53049 LDFLAGS_JDKEXE="${LDFLAGS_JDKEXE} ${EXTRA_LDFLAGS_JDK}" 53050 53051 # Customize LDFLAGS for libs 53052 LDFLAGS_JDKLIB="${LDFLAGS_JDK}" 53053 53054 LDFLAGS_JDKLIB="${LDFLAGS_JDKLIB} ${SHARED_LIBRARY_FLAGS}" 53055 LDFLAGS_JDKLIB="${LDFLAGS_JDKLIB} ${LDFLAGS_NO_EXEC_STACK}" 53056 if test "x$TOOLCHAIN_TYPE" = xmicrosoft; then 53057 JAVA_BASE_LDFLAGS="${JAVA_BASE_LDFLAGS} \ 53058 -libpath:${OUTPUTDIR}/support/modules_libs/java.base" 53059 JDKLIB_LIBS="" 53060 else 53061 JAVA_BASE_LDFLAGS="${JAVA_BASE_LDFLAGS} \ 53062 -L\$(SUPPORT_OUTPUTDIR)/modules_libs/java.base" 53063 53064 if test "xTARGET" = "xTARGET"; then 53065 # On some platforms (mac) the linker warns about non existing -L dirs. 53066 # For any of the variants server, client or minimal, the dir matches the 53067 # variant name. The "main" variant should be used for linking. For the 53068 # rest, the dir is just server. 53069 if [[ " $JVM_VARIANTS " =~ " server " ]] || [[ " $JVM_VARIANTS " =~ " client " ]] \ 53070 || [[ " $JVM_VARIANTS " =~ " minimal " ]] ; then 53071 JAVA_BASE_LDFLAGS="${JAVA_BASE_LDFLAGS} \ 53072 -L\$(SUPPORT_OUTPUTDIR)/modules_libs/java.base/$JVM_VARIANT_MAIN" 53073 else 53074 JAVA_BASE_LDFLAGS="${JAVA_BASE_LDFLAGS} \ 53075 -L\$(SUPPORT_OUTPUTDIR)/modules_libs/java.base/server" 53076 fi 53077 elif test "xTARGET" = "xBUILD"; then 53078 # When building a buildjdk, it's always only the server variant 53079 JAVA_BASE_LDFLAGS="${JAVA_BASE_LDFLAGS} \ 53080 -L\$(SUPPORT_OUTPUTDIR)/modules_libs/java.base/server" 53081 fi 53082 53083 JDKLIB_LIBS="-ljava -ljvm" 53084 if test "x$TOOLCHAIN_TYPE" = xsolstudio; then 53085 JDKLIB_LIBS="$JDKLIB_LIBS -lc" 53086 fi 53087 53088 fi 53089 53090 LDFLAGS_JDKLIB="${LDFLAGS_JDKLIB} ${JAVA_BASE_LDFLAGS}" 53091 53092 # Set JVM_LIBS (per os) 53093 if test "x$OPENJDK_TARGET_OS" = xlinux; then 53094 JVM_LIBS="$JVM_LIBS -lm -ldl -lpthread" 53095 elif test "x$OPENJDK_TARGET_OS" = xsolaris; then 53096 # FIXME: This hard-coded path is not really proper. 53097 if test "x$OPENJDK_TARGET_CPU" = xx86_64; then 53098 SOLARIS_LIBM_LIBS="/usr/lib/amd64/libm.so.1" 53099 elif test "x$OPENJDK_TARGET_CPU" = xsparcv9; then 53100 SOLARIS_LIBM_LIBS="/usr/lib/sparcv9/libm.so.1" 53101 fi 53102 JVM_LIBS="$JVM_LIBS -lsocket -lsched -ldl $SOLARIS_LIBM_LIBS -lCrun \ 53103 -lthread -ldoor -lc -ldemangle -lnsl -lrt" 53104 elif test "x$OPENJDK_TARGET_OS" = xmacosx; then 53105 JVM_LIBS="$JVM_LIBS -lm" 53106 elif test "x$OPENJDK_TARGET_OS" = xaix; then 53107 JVM_LIBS="$JVM_LIBS -Wl,-lC_r -lm -ldl -lpthread" 53108 elif test "x$OPENJDK_TARGET_OS" = xbsd; then 53109 JVM_LIBS="$JVM_LIBS -lm" 53110 elif test "x$OPENJDK_TARGET_OS" = xwindows; then 53111 JVM_LIBS="$JVM_LIBS kernel32.lib user32.lib gdi32.lib winspool.lib \ 53112 comdlg32.lib advapi32.lib shell32.lib ole32.lib oleaut32.lib uuid.lib \ 53113 wsock32.lib winmm.lib version.lib psapi.lib" 53114 fi 53115 53116 # Set JVM_ASFLAGS 53117 if test "x$OPENJDK_TARGET_OS" = xlinux; then 53118 if test "x$OPENJDK_TARGET_CPU" = xx86; then 53119 JVM_ASFLAGS="$JVM_ASFLAGS -march=i586" 53120 fi 53121 elif test "x$OPENJDK_TARGET_OS" = xmacosx; then 53122 JVM_ASFLAGS="$JVM_ASFLAGS -x assembler-with-cpp -mno-omit-leaf-frame-pointer -mstack-alignment=16" 53123 fi 53124 53125 LDFLAGS_JDKLIB="${LDFLAGS_JDKLIB} ${EXTRA_LDFLAGS_JDK}" 53126 53127 53128 53129 53130 53131 53132 53133 53134 53135 53136 53137 53138 53139 53140 53141 53142 # Special extras... 53143 if test "x$TOOLCHAIN_TYPE" = xsolstudio; then 53144 if test "x$OPENJDK_BUILD_CPU_ARCH" = "xsparc"; then 53145 OPENJDK_BUILD_CFLAGS_JDKLIB_EXTRA="${OPENJDK_BUILD_CFLAGS_JDKLIB_EXTRA} -xregs=no%appl" 53146 OPENJDK_BUILD_CXXFLAGS_JDKLIB_EXTRA="${OPENJDK_BUILD_CXXFLAGS_JDKLIB_EXTRA} -xregs=no%appl" 53147 fi 53148 OPENJDK_BUILD_CFLAGS_JDKLIB_EXTRA="${OPENJDK_BUILD_CFLAGS_JDKLIB_EXTRA} -errtags=yes -errfmt" 53149 OPENJDK_BUILD_CXXFLAGS_JDKLIB_EXTRA="${OPENJDK_BUILD_CXXFLAGS_JDKLIB_EXTRA} -errtags=yes -errfmt" 53150 elif test "x$TOOLCHAIN_TYPE" = xxlc; then 53151 OPENJDK_BUILD_CFLAGS_JDK="${OPENJDK_BUILD_CFLAGS_JDK} -qchars=signed -qfullpath -qsaveopt" 53152 OPENJDK_BUILD_CXXFLAGS_JDK="${OPENJDK_BUILD_CXXFLAGS_JDK} -qchars=signed -qfullpath -qsaveopt" 53153 elif test "x$TOOLCHAIN_TYPE" = xgcc; then 53154 OPENJDK_BUILD_CXXSTD_CXXFLAG="-std=gnu++98" 53155 53156 53157 53158 53159 53160 53161 53162 53163 53164 53165 53166 53167 53168 53169 53170 53171 53172 53173 53174 53175 53176 53177 53178 53179 53180 53181 53182 53183 53184 53185 53186 53187 53188 53189 53190 53191 53192 53193 53194 53195 53196 53197 # Execute function body 53198 53199 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if the C++ compiler supports \"$OPENJDK_BUILD_CXXSTD_CXXFLAG -Werror\"" >&5 53200 $as_echo_n "checking if the C++ compiler supports \"$OPENJDK_BUILD_CXXSTD_CXXFLAG -Werror\"... " >&6; } 53201 supports=yes 53202 53203 saved_cxxflags="$CXXFLAGS" 53204 CXXFLAGS="$CXXFLAG $OPENJDK_BUILD_CXXSTD_CXXFLAG -Werror" 53205 ac_ext=cpp 53206 ac_cpp='$CXXCPP $CPPFLAGS' 53207 ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5' 53208 ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' 53209 ac_compiler_gnu=$ac_cv_cxx_compiler_gnu 53210 53211 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 53212 /* end confdefs.h. */ 53213 int i; 53214 _ACEOF 53215 if ac_fn_cxx_try_compile "$LINENO"; then : 53216 53217 else 53218 supports=no 53219 fi 53220 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext 53221 ac_ext=cpp 53222 ac_cpp='$CXXCPP $CPPFLAGS' 53223 ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5' 53224 ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' 53225 ac_compiler_gnu=$ac_cv_cxx_compiler_gnu 53226 53227 CXXFLAGS="$saved_cxxflags" 53228 53229 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $supports" >&5 53230 $as_echo "$supports" >&6; } 53231 if test "x$supports" = "xyes" ; then 53232 : 53233 53234 else 53235 : 53236 OPENJDK_BUILD_CXXSTD_CXXFLAG="" 53237 fi 53238 53239 53240 53241 53242 53243 53244 53245 53246 53247 53248 53249 53250 OPENJDK_BUILD_CXXFLAGS_JDK="${OPENJDK_BUILD_CXXFLAGS_JDK} ${OPENJDK_BUILD_CXXSTD_CXXFLAG}" 53251 OPENJDK_BUILD_JVM_CFLAGS="${OPENJDK_BUILD_JVM_CFLAGS} ${OPENJDK_BUILD_CXXSTD_CXXFLAG}" 53252 53253 fi 53254 if test "x$OPENJDK_TARGET_OS" = xsolaris; then 53255 OPENJDK_BUILD_CFLAGS_JDK="${OPENJDK_BUILD_CFLAGS_JDK} -D__solaris__" 53256 OPENJDK_BUILD_CXXFLAGS_JDK="${OPENJDK_BUILD_CXXFLAGS_JDK} -D__solaris__" 53257 fi 53258 53259 OPENJDK_BUILD_CFLAGS_JDK="${OPENJDK_BUILD_CFLAGS_JDK} ${OPENJDK_BUILD_EXTRA_CFLAGS}" 53260 OPENJDK_BUILD_CXXFLAGS_JDK="${OPENJDK_BUILD_CXXFLAGS_JDK} ${OPENJDK_BUILD_EXTRA_CXXFLAGS}" 53261 OPENJDK_BUILD_LDFLAGS_JDK="${OPENJDK_BUILD_LDFLAGS_JDK} ${OPENJDK_BUILD_EXTRA_LDFLAGS}" 53262 53263 ############################################################################### 53264 # 53265 # Now setup the CFLAGS and LDFLAGS for the JDK build. 53266 # Later we will also have CFLAGS and LDFLAGS for the hotspot subrepo build. 53267 # 53268 53269 # Setup compiler/platform specific flags into 53270 # OPENJDK_BUILD_CFLAGS_JDK - C Compiler flags 53271 # OPENJDK_BUILD_CXXFLAGS_JDK - C++ Compiler flags 53272 # OPENJDK_BUILD_COMMON_CCXXFLAGS_JDK - common to C and C++ 53273 if test "x$TOOLCHAIN_TYPE" = xgcc; then 53274 OPENJDK_BUILD_JVM_CFLAGS="$OPENJDK_BUILD_JVM_CFLAGS -D_GNU_SOURCE" 53275 OPENJDK_BUILD_JVM_CFLAGS="$OPENJDK_BUILD_JVM_CFLAGS -D_REENTRANT" 53276 OPENJDK_BUILD_JVM_CFLAGS="$OPENJDK_BUILD_JVM_CFLAGS -fcheck-new" 53277 if test "x$OPENJDK_BUILD_CPU" = xx86; then 53278 # Force compatibility with i586 on 32 bit intel platforms. 53279 OPENJDK_BUILD_COMMON_CCXXFLAGS="${OPENJDK_BUILD_COMMON_CCXXFLAGS} -march=i586" 53280 OPENJDK_BUILD_JVM_CFLAGS="$OPENJDK_BUILD_JVM_CFLAGS -march=i586" 53281 fi 53282 OPENJDK_BUILD_COMMON_CCXXFLAGS_JDK="$OPENJDK_BUILD_COMMON_CCXXFLAGS $OPENJDK_BUILD_COMMON_CCXXFLAGS_JDK -Wall -Wextra -Wno-unused -Wno-unused-parameter -Wformat=2 \ 53283 -pipe -D_GNU_SOURCE -D_REENTRANT -D_LARGEFILE64_SOURCE" 53284 case $OPENJDK_BUILD_CPU_ARCH in 53285 arm ) 53286 # on arm we don't prevent gcc to omit frame pointer but do prevent strict aliasing 53287 OPENJDK_BUILD_CFLAGS_JDK="${OPENJDK_BUILD_CFLAGS_JDK} -fno-strict-aliasing" 53288 OPENJDK_BUILD_COMMON_CCXXFLAGS_JDK="${OPENJDK_BUILD_COMMON_CCXXFLAGS_JDK} -fsigned-char" 53289 ;; 53290 ppc ) 53291 # on ppc we don't prevent gcc to omit frame pointer but do prevent strict aliasing 53292 OPENJDK_BUILD_CFLAGS_JDK="${OPENJDK_BUILD_CFLAGS_JDK} -fno-strict-aliasing" 53293 ;; 53294 s390 ) 53295 OPENJDK_BUILD_COMMON_CCXXFLAGS_JDK="$OPENJDK_BUILD_COMMON_CCXXFLAGS_JDK -fno-omit-frame-pointer -mbackchain -march=z10" 53296 OPENJDK_BUILD_CFLAGS_JDK="${OPENJDK_BUILD_CFLAGS_JDK} -fno-strict-aliasing" 53297 ;; 53298 * ) 53299 OPENJDK_BUILD_COMMON_CCXXFLAGS_JDK="$OPENJDK_BUILD_COMMON_CCXXFLAGS_JDK -fno-omit-frame-pointer" 53300 OPENJDK_BUILD_CFLAGS_JDK="${OPENJDK_BUILD_CFLAGS_JDK} -fno-strict-aliasing" 53301 ;; 53302 esac 53303 53304 53305 53306 53307 53308 53309 53310 53311 53312 53313 53314 53315 53316 53317 53318 53319 53320 53321 53322 53323 53324 53325 53326 53327 53328 53329 53330 53331 53332 53333 53334 53335 53336 53337 53338 53339 53340 53341 53342 53343 53344 53345 53346 53347 53348 53349 53350 53351 53352 53353 53354 53355 53356 53357 # Execute function body 53358 53359 # Need to assign to a variable since m4 is blocked from modifying parts in []. 53360 REFERENCE_VERSION=6 53361 53362 if [[ "$REFERENCE_VERSION" =~ (.*\.){4} ]] ; then 53363 as_fn_error $? "Internal error: Cannot compare to 6, only four parts (W.X.Y.Z) is supported" "$LINENO" 5 53364 fi 53365 53366 if [[ "$REFERENCE_VERSION" =~ [0-9]{6} ]] ; then 53367 as_fn_error $? "Internal error: Cannot compare to 6, only parts < 99999 is supported" "$LINENO" 5 53368 fi 53369 53370 # Version comparison method inspired by http://stackoverflow.com/a/24067243 53371 COMPARABLE_REFERENCE_VERSION=`$AWK -F. '{ printf("%05d%05d%05d%05d\n", $1, $2, $3, $4) }' <<< "$REFERENCE_VERSION"` 53372 53373 if test $OPENJDK_BUILD_COMPARABLE_ACTUAL_VERSION -ge $COMPARABLE_REFERENCE_VERSION ; then 53374 : 53375 53376 # These flags are required for GCC 6 builds as undefined behaviour in OpenJDK code 53377 # runs afoul of the more aggressive versions of these optimisations. 53378 # Notably, value range propagation now assumes that the this pointer of C++ 53379 # member functions is non-null. 53380 NO_DELETE_NULL_POINTER_CHECKS_CFLAG="-fno-delete-null-pointer-checks" 53381 NO_LIFETIME_DSE_CFLAG="-fno-lifetime-dse" 53382 { $as_echo "$as_me:${as_lineno-$LINENO}: GCC >= 6 detected; adding ${NO_DELETE_NULL_POINTER_CHECKS_CFLAG} and ${NO_LIFETIME_DSE_CFLAG}" >&5 53383 $as_echo "$as_me: GCC >= 6 detected; adding ${NO_DELETE_NULL_POINTER_CHECKS_CFLAG} and ${NO_LIFETIME_DSE_CFLAG}" >&6;} 53384 OPENJDK_BUILD_CFLAGS_JDK="$OPENJDK_BUILD_CFLAGS_JDK ${NO_DELETE_NULL_POINTER_CHECKS_CFLAG} ${NO_LIFETIME_DSE_CFLAG}" 53385 OPENJDK_BUILD_JVM_CFLAGS="$OPENJDK_BUILD_JVM_CFLAGS ${NO_DELETE_NULL_POINTER_CHECKS_CFLAG} ${NO_LIFETIME_DSE_CFLAG}" 53386 53387 else 53388 : 53389 53390 fi 53391 53392 53393 53394 53395 53396 53397 53398 53399 53400 53401 53402 53403 53404 53405 elif test "x$TOOLCHAIN_TYPE" = xclang; then 53406 OPENJDK_BUILD_JVM_CFLAGS="$OPENJDK_BUILD_JVM_CFLAGS -D_GNU_SOURCE" 53407 53408 # Restrict the debug information created by Clang to avoid 53409 # too big object files and speed the build up a little bit 53410 # (see http://llvm.org/bugs/show_bug.cgi?id=7554) 53411 OPENJDK_BUILD_JVM_CFLAGS="$OPENJDK_BUILD_JVM_CFLAGS -flimit-debug-info" 53412 if test "x$OPENJDK_BUILD_OS" = xlinux; then 53413 if test "x$OPENJDK_BUILD_CPU" = xx86; then 53414 # Force compatibility with i586 on 32 bit intel platforms. 53415 OPENJDK_BUILD_COMMON_CCXXFLAGS="${OPENJDK_BUILD_COMMON_CCXXFLAGS} -march=i586" 53416 OPENJDK_BUILD_JVM_CFLAGS="$OPENJDK_BUILD_JVM_CFLAGS -march=i586" 53417 fi 53418 OPENJDK_BUILD_JVM_CFLAGS="$OPENJDK_BUILD_JVM_CFLAGS -Wno-sometimes-uninitialized" 53419 OPENJDK_BUILD_COMMON_CCXXFLAGS_JDK="$OPENJDK_BUILD_COMMON_CCXXFLAGS $OPENJDK_BUILD_COMMON_CCXXFLAGS_JDK -Wall -Wextra -Wno-unused -Wno-unused-parameter -Wformat=2 \ 53420 -pipe -D_GNU_SOURCE -D_REENTRANT -D_LARGEFILE64_SOURCE" 53421 case $OPENJDK_BUILD_CPU_ARCH in 53422 ppc ) 53423 # on ppc we don't prevent gcc to omit frame pointer but do prevent strict aliasing 53424 OPENJDK_BUILD_CFLAGS_JDK="${OPENJDK_BUILD_CFLAGS_JDK} -fno-strict-aliasing" 53425 ;; 53426 * ) 53427 OPENJDK_BUILD_COMMON_CCXXFLAGS_JDK="$OPENJDK_BUILD_COMMON_CCXXFLAGS_JDK -fno-omit-frame-pointer" 53428 OPENJDK_BUILD_CFLAGS_JDK="${OPENJDK_BUILD_CFLAGS_JDK} -fno-strict-aliasing" 53429 ;; 53430 esac 53431 fi 53432 elif test "x$TOOLCHAIN_TYPE" = xsolstudio; then 53433 OPENJDK_BUILD_JVM_CFLAGS="$OPENJDK_BUILD_JVM_CFLAGS -DSPARC_WORKS" 53434 OPENJDK_BUILD_COMMON_CCXXFLAGS_JDK="$OPENJDK_BUILD_COMMON_CCXXFLAGS $OPENJDK_BUILD_COMMON_CCXXFLAGS_JDK -DTRACING -DMACRO_MEMSYS_OPS -DBREAKPTS" 53435 if test "x$OPENJDK_BUILD_CPU_ARCH" = xx86; then 53436 OPENJDK_BUILD_COMMON_CCXXFLAGS_JDK="$OPENJDK_BUILD_COMMON_CCXXFLAGS_JDK -DcpuIntel -Di586 -D$OPENJDK_BUILD_CPU_LEGACY_LIB" 53437 fi 53438 53439 OPENJDK_BUILD_CFLAGS_JDK="$OPENJDK_BUILD_CFLAGS_JDK -xc99=%none -xCC -errshort=tags -Xa -v -mt -W0,-noglobal" 53440 OPENJDK_BUILD_CXXFLAGS_JDK="$OPENJDK_BUILD_CXXFLAGS_JDK -errtags=yes +w -mt -features=no%except -DCC_NOEX -norunpath -xnolib" 53441 elif test "x$TOOLCHAIN_TYPE" = xxlc; then 53442 OPENJDK_BUILD_JVM_CFLAGS="$OPENJDK_BUILD_JVM_CFLAGS -D_REENTRANT" 53443 OPENJDK_BUILD_CFLAGS_JDK="$OPENJDK_BUILD_CFLAGS_JDK -D_GNU_SOURCE -D_REENTRANT -D_LARGEFILE64_SOURCE -DSTDC" 53444 OPENJDK_BUILD_CXXFLAGS_JDK="$OPENJDK_BUILD_CXXFLAGS_JDK -D_GNU_SOURCE -D_REENTRANT -D_LARGEFILE64_SOURCE -DSTDC" 53445 elif test "x$TOOLCHAIN_TYPE" = xmicrosoft; then 53446 OPENJDK_BUILD_COMMON_CCXXFLAGS_JDK="$OPENJDK_BUILD_COMMON_CCXXFLAGS $OPENJDK_BUILD_COMMON_CCXXFLAGS_JDK \ 53447 -MD -Zc:wchar_t- -W3 -wd4800 \ 53448 -DWIN32_LEAN_AND_MEAN \ 53449 -D_CRT_SECURE_NO_DEPRECATE -D_CRT_NONSTDC_NO_DEPRECATE \ 53450 -D_WINSOCK_DEPRECATED_NO_WARNINGS \ 53451 -DWIN32 -DIAL" 53452 if test "x$OPENJDK_BUILD_CPU" = xx86_64; then 53453 OPENJDK_BUILD_COMMON_CCXXFLAGS_JDK="$OPENJDK_BUILD_COMMON_CCXXFLAGS_JDK -D_AMD64_ -Damd64" 53454 else 53455 OPENJDK_BUILD_COMMON_CCXXFLAGS_JDK="$OPENJDK_BUILD_COMMON_CCXXFLAGS_JDK -D_X86_ -Dx86" 53456 fi 53457 # If building with Visual Studio 2010, we can still use _STATIC_CPPLIB to 53458 # avoid bundling msvcpNNN.dll. Doesn't work with newer versions of visual 53459 # studio. 53460 if test "x$TOOLCHAIN_VERSION" = "x2010"; then 53461 STATIC_CPPLIB_FLAGS="-D_STATIC_CPPLIB -D_DISABLE_DEPRECATE_STATIC_CPPLIB" 53462 OPENJDK_BUILD_COMMON_CCXXFLAGS_JDK="$OPENJDK_BUILD_COMMON_CCXXFLAGS_JDK $STATIC_CPPLIB_FLAGS" 53463 OPENJDK_BUILD_JVM_CFLAGS="$OPENJDK_BUILD_JVM_CFLAGS $STATIC_CPPLIB_FLAGS" 53464 fi 53465 fi 53466 53467 ############################################################################### 53468 53469 # Adjust flags according to debug level. 53470 case $DEBUG_LEVEL in 53471 fastdebug | slowdebug ) 53472 OPENJDK_BUILD_CFLAGS_JDK="$OPENJDK_BUILD_CFLAGS_JDK $CFLAGS_DEBUG_SYMBOLS $CFLAGS_DEBUG_OPTIONS" 53473 OPENJDK_BUILD_CXXFLAGS_JDK="$OPENJDK_BUILD_CXXFLAGS_JDK $CXXFLAGS_DEBUG_SYMBOLS $CXXFLAGS_DEBUG_OPTIONS" 53474 ;; 53475 release ) 53476 ;; 53477 * ) 53478 as_fn_error $? "Unrecognized \$DEBUG_LEVEL: $DEBUG_LEVEL" "$LINENO" 5 53479 ;; 53480 esac 53481 53482 # Set some common defines. These works for all compilers, but assume 53483 # -D is universally accepted. 53484 53485 # Setup endianness 53486 if test "x$OPENJDK_BUILD_CPU_ENDIAN" = xlittle; then 53487 # The macro _LITTLE_ENDIAN needs to be defined the same to avoid the 53488 # Sun C compiler warning message: warning: macro redefined: _LITTLE_ENDIAN 53489 # (The Solaris X86 system defines this in file /usr/include/sys/isa_defs.h). 53490 # Note: -Dmacro is the same as #define macro 1 53491 # -Dmacro= is the same as #define macro 53492 if test "x$OPENJDK_BUILD_OS" = xsolaris; then 53493 OPENJDK_BUILD_COMMON_CCXXFLAGS_JDK="$OPENJDK_BUILD_COMMON_CCXXFLAGS_JDK -D_LITTLE_ENDIAN=" 53494 else 53495 OPENJDK_BUILD_COMMON_CCXXFLAGS_JDK="$OPENJDK_BUILD_COMMON_CCXXFLAGS_JDK -D_LITTLE_ENDIAN" 53496 fi 53497 else 53498 # Same goes for _BIG_ENDIAN. Do we really need to set *ENDIAN on Solaris if they 53499 # are defined in the system? 53500 if test "x$OPENJDK_BUILD_OS" = xsolaris; then 53501 OPENJDK_BUILD_COMMON_CCXXFLAGS_JDK="$OPENJDK_BUILD_COMMON_CCXXFLAGS_JDK -D_BIG_ENDIAN=" 53502 else 53503 OPENJDK_BUILD_COMMON_CCXXFLAGS_JDK="$OPENJDK_BUILD_COMMON_CCXXFLAGS_JDK -D_BIG_ENDIAN" 53504 fi 53505 fi 53506 53507 # Always enable optional macros for VM. 53508 OPENJDK_BUILD_JVM_CFLAGS="$OPENJDK_BUILD_JVM_CFLAGS -D__STDC_FORMAT_MACROS" 53509 OPENJDK_BUILD_JVM_CFLAGS="$OPENJDK_BUILD_JVM_CFLAGS -D__STDC_LIMIT_MACROS" 53510 OPENJDK_BUILD_JVM_CFLAGS="$OPENJDK_BUILD_JVM_CFLAGS -D__STDC_CONSTANT_MACROS" 53511 53512 # Setup target OS define. Use OS target name but in upper case. 53513 OPENJDK_BUILD_OS_UPPERCASE=`$ECHO $OPENJDK_BUILD_OS | $TR 'abcdefghijklmnopqrstuvwxyz' 'ABCDEFGHIJKLMNOPQRSTUVWXYZ'` 53514 OPENJDK_BUILD_COMMON_CCXXFLAGS_JDK="$OPENJDK_BUILD_COMMON_CCXXFLAGS_JDK -D$OPENJDK_BUILD_OS_UPPERCASE" 53515 53516 # Setup target CPU 53517 OPENJDK_BUILD_COMMON_CCXXFLAGS_JDK="$OPENJDK_BUILD_COMMON_CCXXFLAGS_JDK \ 53518 $OPENJDK_BUILD_ADD_LP64 \ 53519 -DARCH='\"$OPENJDK_BUILD_CPU_LEGACY\"' -D$OPENJDK_BUILD_CPU_LEGACY" 53520 53521 # Setup debug/release defines 53522 if test "x$DEBUG_LEVEL" = xrelease; then 53523 OPENJDK_BUILD_COMMON_CCXXFLAGS_JDK="$OPENJDK_BUILD_COMMON_CCXXFLAGS_JDK -DNDEBUG" 53524 if test "x$OPENJDK_BUILD_OS" = xsolaris; then 53525 OPENJDK_BUILD_COMMON_CCXXFLAGS_JDK="$OPENJDK_BUILD_COMMON_CCXXFLAGS_JDK -DTRIMMED" 53526 fi 53527 else 53528 OPENJDK_BUILD_COMMON_CCXXFLAGS_JDK="$OPENJDK_BUILD_COMMON_CCXXFLAGS_JDK -DDEBUG" 53529 fi 53530 53531 # Optional POSIX functionality needed by the VM 53532 53533 if test "x$HAS_CLOCK_GETTIME" = "xtrue"; then 53534 OPENJDK_BUILD_JVM_CFLAGS="$OPENJDK_BUILD_JVM_CFLAGS -DSUPPORTS_CLOCK_MONOTONIC" 53535 if test "x$CLOCK_GETTIME_IN_LIBRT" = "xtrue"; then 53536 OPENJDK_BUILD_JVM_CFLAGS="$OPENJDK_BUILD_JVM_CFLAGS -DNEEDS_LIBRT" 53537 fi 53538 fi 53539 53540 53541 # Set some additional per-OS defines. 53542 if test "x$OPENJDK_BUILD_OS" = xlinux; then 53543 OPENJDK_BUILD_JVM_CFLAGS="$OPENJDK_BUILD_JVM_CFLAGS -DLINUX" 53544 OPENJDK_BUILD_JVM_CFLAGS="$OPENJDK_BUILD_JVM_CFLAGS -pipe $PICFLAG -fno-rtti -fno-exceptions \ 53545 -fvisibility=hidden -fno-strict-aliasing -fno-omit-frame-pointer" 53546 elif test "x$OPENJDK_BUILD_OS" = xsolaris; then 53547 OPENJDK_BUILD_JVM_CFLAGS="$OPENJDK_BUILD_JVM_CFLAGS -DSOLARIS" 53548 OPENJDK_BUILD_JVM_CFLAGS="$OPENJDK_BUILD_JVM_CFLAGS -template=no%extdef -features=no%split_init \ 53549 -D_Crun_inline_placement -library=stlport4 $PICFLAG -mt -features=no%except" 53550 elif test "x$OPENJDK_BUILD_OS" = xmacosx; then 53551 OPENJDK_BUILD_COMMON_CCXXFLAGS_JDK="$OPENJDK_BUILD_COMMON_CCXXFLAGS_JDK -D_ALLBSD_SOURCE -D_DARWIN_UNLIMITED_SELECT" 53552 OPENJDK_BUILD_JVM_CFLAGS="$OPENJDK_BUILD_JVM_CFLAGS -D_ALLBSD_SOURCE" 53553 OPENJDK_BUILD_JVM_CFLAGS="$OPENJDK_BUILD_JVM_CFLAGS -D_DARWIN_C_SOURCE -D_XOPEN_SOURCE" 53554 OPENJDK_BUILD_JVM_CFLAGS="$OPENJDK_BUILD_JVM_CFLAGS -fno-rtti -fno-exceptions -fvisibility=hidden \ 53555 -mno-omit-leaf-frame-pointer -mstack-alignment=16 -pipe -fno-strict-aliasing \ 53556 -fno-omit-frame-pointer" 53557 elif test "x$OPENJDK_BUILD_OS" = xaix; then 53558 OPENJDK_BUILD_JVM_CFLAGS="$OPENJDK_BUILD_JVM_CFLAGS -DAIX" 53559 OPENJDK_BUILD_JVM_CFLAGS="$OPENJDK_BUILD_JVM_CFLAGS -qtune=balanced \ 53560 -qalias=noansi -qstrict -qtls=default -qlanglvl=c99vla \ 53561 -qlanglvl=noredefmac -qnortti -qnoeh -qignerrno" 53562 # We need '-qminimaltoc' or '-qpic=large -bbigtoc' if the TOC overflows. 53563 # Hotspot now overflows its 64K TOC (currently only for slowdebug), 53564 # so for slowdebug we build with '-qpic=large -bbigtoc'. 53565 if test "x$DEBUG_LEVEL" = xslowdebug; then 53566 OPENJDK_BUILD_JVM_CFLAGS="$OPENJDK_BUILD_JVM_CFLAGS -qpic=large" 53567 fi 53568 elif test "x$OPENJDK_BUILD_OS" = xbsd; then 53569 OPENJDK_BUILD_COMMON_CCXXFLAGS_JDK="$OPENJDK_BUILD_COMMON_CCXXFLAGS_JDK -D_ALLBSD_SOURCE" 53570 elif test "x$OPENJDK_BUILD_OS" = xwindows; then 53571 OPENJDK_BUILD_JVM_CFLAGS="$OPENJDK_BUILD_JVM_CFLAGS -D_WINDOWS -DWIN32 -D_JNI_IMPLEMENTATION_" 53572 OPENJDK_BUILD_JVM_CFLAGS="$OPENJDK_BUILD_JVM_CFLAGS -nologo -W3 -MD -MP" 53573 fi 53574 53575 # Set some additional per-CPU defines. 53576 if test "x$OPENJDK_BUILD_OS-$OPENJDK_BUILD_CPU" = xwindows-x86; then 53577 OPENJDK_BUILD_JVM_CFLAGS="$OPENJDK_BUILD_JVM_CFLAGS -arch:IA32" 53578 elif test "x$OPENJDK_BUILD_OS-$OPENJDK_BUILD_CPU" = xsolaris-sparcv9; then 53579 OPENJDK_BUILD_JVM_CFLAGS="$OPENJDK_BUILD_JVM_CFLAGS -xarch=sparc" 53580 elif test "x$OPENJDK_BUILD_CPU" = xppc64; then 53581 if test "x$OPENJDK_BUILD_OS" = xlinux; then 53582 OPENJDK_BUILD_JVM_CFLAGS="$OPENJDK_BUILD_JVM_CFLAGS -minsert-sched-nops=regroup_exact -mno-multiple -mno-string" 53583 # fixes `relocation truncated to fit' error for gcc 4.1. 53584 OPENJDK_BUILD_JVM_CFLAGS="$OPENJDK_BUILD_JVM_CFLAGS -mminimal-toc" 53585 # Use ppc64 instructions, but schedule for power5 53586 OPENJDK_BUILD_JVM_CFLAGS="$OPENJDK_BUILD_JVM_CFLAGS -mcpu=powerpc64 -mtune=power5" 53587 elif test "x$OPENJDK_BUILD_OS" = xaix; then 53588 OPENJDK_BUILD_JVM_CFLAGS="$OPENJDK_BUILD_JVM_CFLAGS -qarch=ppc64" 53589 fi 53590 elif test "x$OPENJDK_BUILD_CPU" = xppc64le; then 53591 if test "x$OPENJDK_BUILD_OS" = xlinux; then 53592 OPENJDK_BUILD_JVM_CFLAGS="$OPENJDK_BUILD_JVM_CFLAGS -minsert-sched-nops=regroup_exact -mno-multiple -mno-string" 53593 # Little endian machine uses ELFv2 ABI. 53594 OPENJDK_BUILD_JVM_CFLAGS="$OPENJDK_BUILD_JVM_CFLAGS -DABI_ELFv2" 53595 # Use Power8, this is the first CPU to support PPC64 LE with ELFv2 ABI. 53596 OPENJDK_BUILD_JVM_CFLAGS="$OPENJDK_BUILD_JVM_CFLAGS -mcpu=power8 -mtune=power8" 53597 fi 53598 elif test "x$OPENJDK_BUILD_CPU" = xs390x; then 53599 if test "x$OPENJDK_BUILD_OS" = xlinux; then 53600 OPENJDK_BUILD_JVM_CFLAGS="$OPENJDK_BUILD_JVM_CFLAGS -mbackchain -march=z10" 53601 fi 53602 fi 53603 53604 if test "x$OPENJDK_BUILD_CPU_ENDIAN" = xlittle; then 53605 OPENJDK_BUILD_JVM_CFLAGS="$OPENJDK_BUILD_JVM_CFLAGS -DVM_LITTLE_ENDIAN" 53606 fi 53607 53608 if test "x$OPENJDK_BUILD_CPU_BITS" = x64; then 53609 if test "x$OPENJDK_BUILD_OS" != xsolaris && test "x$OPENJDK_BUILD_OS" != xaix; then 53610 # Solaris does not have _LP64=1 in the old build. 53611 # xlc on AIX defines _LP64=1 by default and issues a warning if we redefine it. 53612 OPENJDK_BUILD_JVM_CFLAGS="$OPENJDK_BUILD_JVM_CFLAGS -D_LP64=1" 53613 fi 53614 fi 53615 53616 # Set OPENJDK_BUILD_JVM_CFLAGS warning handling 53617 if test "x$OPENJDK_BUILD_OS" = xlinux; then 53618 OPENJDK_BUILD_JVM_CFLAGS="$OPENJDK_BUILD_JVM_CFLAGS -Wpointer-arith -Wsign-compare -Wunused-function \ 53619 -Wunused-value -Woverloaded-virtual" 53620 53621 if test "x$TOOLCHAIN_TYPE" = xgcc; then 53622 53623 53624 53625 53626 53627 53628 53629 53630 53631 53632 53633 53634 53635 53636 53637 53638 53639 53640 53641 53642 53643 53644 53645 53646 53647 53648 53649 53650 53651 53652 53653 53654 53655 53656 53657 53658 53659 53660 53661 53662 53663 53664 53665 53666 53667 53668 53669 53670 53671 53672 53673 53674 53675 53676 # Execute function body 53677 53678 # Need to assign to a variable since m4 is blocked from modifying parts in []. 53679 REFERENCE_VERSION=4.8 53680 53681 if [[ "$REFERENCE_VERSION" =~ (.*\.){4} ]] ; then 53682 as_fn_error $? "Internal error: Cannot compare to 4.8, only four parts (W.X.Y.Z) is supported" "$LINENO" 5 53683 fi 53684 53685 if [[ "$REFERENCE_VERSION" =~ [0-9]{6} ]] ; then 53686 as_fn_error $? "Internal error: Cannot compare to 4.8, only parts < 99999 is supported" "$LINENO" 5 53687 fi 53688 53689 # Version comparison method inspired by http://stackoverflow.com/a/24067243 53690 COMPARABLE_REFERENCE_VERSION=`$AWK -F. '{ printf("%05d%05d%05d%05d\n", $1, $2, $3, $4) }' <<< "$REFERENCE_VERSION"` 53691 53692 if test $OPENJDK_BUILD_COMPARABLE_ACTUAL_VERSION -ge $COMPARABLE_REFERENCE_VERSION ; then 53693 : 53694 53695 # These flags either do not work or give spurious warnings prior to gcc 4.8. 53696 OPENJDK_BUILD_JVM_CFLAGS="$OPENJDK_BUILD_JVM_CFLAGS -Wno-format-zero-length -Wtype-limits -Wuninitialized" 53697 53698 53699 else 53700 : 53701 53702 fi 53703 53704 53705 53706 53707 53708 53709 53710 53711 53712 53713 53714 53715 53716 53717 fi 53718 if ! [[ " $JVM_VARIANTS " =~ " zero " ]] ; then 53719 # Non-zero builds have stricter warnings 53720 OPENJDK_BUILD_JVM_CFLAGS="$OPENJDK_BUILD_JVM_CFLAGS -Wreturn-type -Wundef -Wformat=2" 53721 else 53722 if test "x$TOOLCHAIN_TYPE" = xclang; then 53723 # Some versions of llvm do not like -Wundef 53724 OPENJDK_BUILD_JVM_CFLAGS="$OPENJDK_BUILD_JVM_CFLAGS -Wno-undef" 53725 fi 53726 fi 53727 elif test "x$OPENJDK_BUILD_OS" = xmacosx; then 53728 OPENJDK_BUILD_JVM_CFLAGS="$OPENJDK_BUILD_JVM_CFLAGS -Wno-deprecated -Wpointer-arith \ 53729 -Wsign-compare -Wundef -Wunused-function -Wformat=2" 53730 fi 53731 53732 # Additional macosx handling 53733 if test "x$OPENJDK_BUILD_OS" = xmacosx; then 53734 # MACOSX_VERSION_MIN is the c++ and ld is -mmacosx-version-min argument. The expected 53735 # format is X.Y.Z. It's hard-coded to the minimum OSX version on which the 53736 # JDK can be built and makes the linked binaries compatible even if built on 53737 # a newer version of the OS. 53738 MACOSX_VERSION_MIN=10.7.0 53739 53740 53741 # Setting --with-macosx-version-max=<version> makes it an error to build or 53742 # link to macosx APIs that are newer than the given OS version. The expected 53743 # format for <version> is either nn.n.n or nn.nn.nn. See /usr/include/AvailabilityMacros.h. 53744 53745 # Check whether --with-macosx-version-max was given. 53746 if test "${with_macosx_version_max+set}" = set; then : 53747 withval=$with_macosx_version_max; 53748 if echo "$with_macosx_version_max" | $GREP -q "^[0-9][0-9]\.[0-9]\.[0-9]\$"; then 53749 MACOSX_VERSION_MAX=$with_macosx_version_max 53750 elif echo "$with_macosx_version_max" | $GREP -q "^[0-9][0-9]\.[0-9][0-9]\.[0-9][0-9]\$"; then 53751 MACOSX_VERSION_MAX=$with_macosx_version_max 53752 elif test "x$with_macosx_version_max" = "xno"; then 53753 # Use build system default 53754 MACOSX_VERSION_MAX= 53755 else 53756 as_fn_error $? "osx version format must be nn.n.n or nn.nn.nn" "$LINENO" 5 53757 fi 53758 53759 else 53760 MACOSX_VERSION_MAX= 53761 53762 fi 53763 53764 53765 53766 # Let the flags variables get resolved in make for easier override on make 53767 # command line. AvailabilityMacros.h versions have no dots, ex: 1070. 53768 OPENJDK_BUILD_COMMON_CCXXFLAGS_JDK="$OPENJDK_BUILD_COMMON_CCXXFLAGS_JDK \ 53769 -DMAC_OS_X_VERSION_MIN_REQUIRED=\$(subst .,,\$(MACOSX_VERSION_MIN)) \ 53770 -mmacosx-version-min=\$(MACOSX_VERSION_MIN)" 53771 OPENJDK_BUILD_LDFLAGS_JDK="$OPENJDK_BUILD_LDFLAGS_JDK -mmacosx-version-min=\$(MACOSX_VERSION_MIN)" 53772 OPENJDK_BUILD_JVM_CFLAGS="$OPENJDK_BUILD_JVM_CFLAGS \ 53773 -DMAC_OS_X_VERSION_MIN_REQUIRED=\$(subst .,,\$(MACOSX_VERSION_MIN)) \ 53774 -mmacosx-version-min=\$(MACOSX_VERSION_MIN)" 53775 53776 if test -n "$MACOSX_VERSION_MAX"; then 53777 OPENJDK_BUILD_COMMON_CCXXFLAGS_JDK="$OPENJDK_BUILD_COMMON_CCXXFLAGS_JDK \ 53778 -DMAC_OS_X_VERSION_MAX_ALLOWED=\$(subst .,,\$(MACOSX_VERSION_MAX))" 53779 OPENJDK_BUILD_JVM_CFLAGS="$OPENJDK_BUILD_JVM_CFLAGS \ 53780 -DMAC_OS_X_VERSION_MAX_ALLOWED=\$(subst .,,\$(MACOSX_VERSION_MAX))" 53781 fi 53782 fi 53783 53784 # Setup some hard coded includes 53785 OPENJDK_BUILD_COMMON_CCXXFLAGS_JDK="$OPENJDK_BUILD_COMMON_CCXXFLAGS_JDK \ 53786 -I\$(SUPPORT_OUTPUTDIR)/modules_include/java.base \ 53787 -I\$(SUPPORT_OUTPUTDIR)/modules_include/java.base/\$(OPENJDK_TARGET_OS_INCLUDE_SUBDIR) \ 53788 -I${TOPDIR}/src/java.base/share/native/libjava \ 53789 -I${TOPDIR}/src/java.base/$OPENJDK_BUILD_OS_TYPE/native/libjava \ 53790 -I${TOPDIR}/src/hotspot/share/include \ 53791 -I${TOPDIR}/src/hotspot/os/${HOTSPOT_BUILD_OS_TYPE}/include" 53792 53793 # The shared libraries are compiled using the picflag. 53794 OPENJDK_BUILD_CFLAGS_JDKLIB="$OPENJDK_BUILD_COMMON_CCXXFLAGS_JDK \ 53795 $OPENJDK_BUILD_CFLAGS_JDK $OPENJDK_BUILD_EXTRA_CFLAGS_JDK $PICFLAG $OPENJDK_BUILD_CFLAGS_JDKLIB_EXTRA" 53796 OPENJDK_BUILD_CXXFLAGS_JDKLIB="$OPENJDK_BUILD_COMMON_CCXXFLAGS_JDK \ 53797 $OPENJDK_BUILD_CXXFLAGS_JDK $OPENJDK_BUILD_EXTRA_CXXFLAGS_JDK $PICFLAG $OPENJDK_BUILD_CXXFLAGS_JDKLIB_EXTRA" 53798 53799 # Executable flags 53800 OPENJDK_BUILD_CFLAGS_JDKEXE="$OPENJDK_BUILD_COMMON_CCXXFLAGS_JDK $OPENJDK_BUILD_CFLAGS_JDK $OPENJDK_BUILD_EXTRA_CFLAGS_JDK" 53801 OPENJDK_BUILD_CXXFLAGS_JDKEXE="$OPENJDK_BUILD_COMMON_CCXXFLAGS_JDK $OPENJDK_BUILD_CXXFLAGS_JDK $OPENJDK_BUILD_EXTRA_CXXFLAGS_JDK" 53802 53803 53804 53805 53806 53807 53808 # Setup LDFLAGS et al. 53809 # 53810 53811 if test "x$TOOLCHAIN_TYPE" = xmicrosoft; then 53812 LDFLAGS_MICROSOFT="-nologo -opt:ref" 53813 OPENJDK_BUILD_LDFLAGS_JDK="$OPENJDK_BUILD_LDFLAGS_JDK $LDFLAGS_MICROSOFT -incremental:no" 53814 OPENJDK_BUILD_JVM_LDFLAGS="$OPENJDK_BUILD_JVM_LDFLAGS $LDFLAGS_MICROSOFT -opt:icf,8 -subsystem:windows -base:0x8000000" 53815 if test "x$OPENJDK_BUILD_CPU_BITS" = "x32"; then 53816 LDFLAGS_SAFESH="-safeseh" 53817 OPENJDK_BUILD_LDFLAGS_JDK="$OPENJDK_BUILD_LDFLAGS_JDK $LDFLAGS_SAFESH" 53818 OPENJDK_BUILD_JVM_LDFLAGS="$OPENJDK_BUILD_JVM_LDFLAGS $LDFLAGS_SAFESH" 53819 # NOTE: Old build added -machine. Probably not needed. 53820 OPENJDK_BUILD_JVM_LDFLAGS="$OPENJDK_BUILD_JVM_LDFLAGS -machine:I386" 53821 else 53822 OPENJDK_BUILD_JVM_LDFLAGS="$OPENJDK_BUILD_JVM_LDFLAGS -machine:AMD64" 53823 fi 53824 elif test "x$TOOLCHAIN_TYPE" = xclang; then 53825 OPENJDK_BUILD_JVM_LDFLAGS="$OPENJDK_BUILD_JVM_LDFLAGS -mno-omit-leaf-frame-pointer -mstack-alignment=16 -stdlib=libstdc++ -fPIC" 53826 if test "x$OPENJDK_BUILD_OS" = xmacosx; then 53827 # FIXME: We should really generalize SET_SHARED_LIBRARY_ORIGIN instead. 53828 OPENJDK_BUILD_JVM_LDFLAGS="$OPENJDK_BUILD_JVM_LDFLAGS -Wl,-rpath,@loader_path/. -Wl,-rpath,@loader_path/.." 53829 fi 53830 elif test "x$TOOLCHAIN_TYPE" = xgcc; then 53831 # If this is a --hash-style=gnu system, use --hash-style=both, why? 53832 # We have previously set HAS_GNU_HASH if this is the case 53833 if test -n "$HAS_GNU_HASH"; then 53834 OPENJDK_BUILD_LDFLAGS_HASH_STYLE="-Wl,--hash-style=both" 53835 OPENJDK_BUILD_LDFLAGS_JDK="${OPENJDK_BUILD_LDFLAGS_JDK} $OPENJDK_BUILD_LDFLAGS_HASH_STYLE" 53836 OPENJDK_BUILD_JVM_LDFLAGS="$OPENJDK_BUILD_JVM_LDFLAGS $OPENJDK_BUILD_LDFLAGS_HASH_STYLE" 53837 fi 53838 if test "x$OPENJDK_BUILD_OS" = xmacosx; then 53839 OPENJDK_BUILD_JVM_LDFLAGS="$OPENJDK_BUILD_JVM_LDFLAGS -Wl,-rpath,@loader_path/. -Wl,-rpath,@loader_path/.." 53840 fi 53841 if test "x$OPENJDK_BUILD_OS" = xlinux; then 53842 # And since we now know that the linker is gnu, then add -z defs, to forbid 53843 # undefined symbols in object files. 53844 LDFLAGS_NO_UNDEF_SYM="-Wl,-z,defs" 53845 OPENJDK_BUILD_LDFLAGS_JDK="${OPENJDK_BUILD_LDFLAGS_JDK} $LDFLAGS_NO_UNDEF_SYM" 53846 OPENJDK_BUILD_JVM_LDFLAGS="$OPENJDK_BUILD_JVM_LDFLAGS $LDFLAGS_NO_UNDEF_SYM" 53847 LDFLAGS_NO_EXEC_STACK="-Wl,-z,noexecstack" 53848 OPENJDK_BUILD_JVM_LDFLAGS="$OPENJDK_BUILD_JVM_LDFLAGS $LDFLAGS_NO_EXEC_STACK" 53849 if test "x$OPENJDK_BUILD_CPU" = xx86; then 53850 OPENJDK_BUILD_JVM_LDFLAGS="$OPENJDK_BUILD_JVM_LDFLAGS -march=i586" 53851 fi 53852 case $DEBUG_LEVEL in 53853 release ) 53854 # tell linker to optimize libraries. 53855 # Should this be supplied to the OSS linker as well? 53856 LDFLAGS_DEBUGLEVEL_release="-Wl,-O1" 53857 OPENJDK_BUILD_LDFLAGS_JDK="${OPENJDK_BUILD_LDFLAGS_JDK} $LDFLAGS_DEBUGLEVEL_release" 53858 OPENJDK_BUILD_JVM_LDFLAGS="$OPENJDK_BUILD_JVM_LDFLAGS $LDFLAGS_DEBUGLEVEL_release" 53859 if test "x$HAS_LINKER_RELRO" = "xtrue"; then 53860 OPENJDK_BUILD_JVM_LDFLAGS="$OPENJDK_BUILD_JVM_LDFLAGS $LINKER_RELRO_FLAG" 53861 fi 53862 ;; 53863 slowdebug ) 53864 # Hotspot always let the linker optimize 53865 OPENJDK_BUILD_JVM_LDFLAGS="$OPENJDK_BUILD_JVM_LDFLAGS -Wl,-O1" 53866 if test "x$HAS_LINKER_NOW" = "xtrue"; then 53867 # do relocations at load 53868 OPENJDK_BUILD_LDFLAGS_JDK="$OPENJDK_BUILD_LDFLAGS_JDK $LINKER_NOW_FLAG" 53869 OPENJDK_BUILD_LDFLAGS_CXX_JDK="$OPENJDK_BUILD_LDFLAGS_CXX_JDK $LINKER_NOW_FLAG" 53870 OPENJDK_BUILD_JVM_LDFLAGS="$OPENJDK_BUILD_JVM_LDFLAGS $LINKER_NOW_FLAG" 53871 fi 53872 if test "x$HAS_LINKER_RELRO" = "xtrue"; then 53873 # mark relocations read only 53874 OPENJDK_BUILD_LDFLAGS_JDK="$OPENJDK_BUILD_LDFLAGS_JDK $LINKER_RELRO_FLAG" 53875 OPENJDK_BUILD_LDFLAGS_CXX_JDK="$OPENJDK_BUILD_LDFLAGS_CXX_JDK $LINKER_RELRO_FLAG" 53876 OPENJDK_BUILD_JVM_LDFLAGS="$OPENJDK_BUILD_JVM_LDFLAGS $LINKER_RELRO_FLAG" 53877 fi 53878 ;; 53879 fastdebug ) 53880 # Hotspot always let the linker optimize 53881 OPENJDK_BUILD_JVM_LDFLAGS="$OPENJDK_BUILD_JVM_LDFLAGS -Wl,-O1" 53882 if test "x$HAS_LINKER_RELRO" = "xtrue"; then 53883 # mark relocations read only 53884 OPENJDK_BUILD_LDFLAGS_JDK="$OPENJDK_BUILD_LDFLAGS_JDK $LINKER_RELRO_FLAG" 53885 OPENJDK_BUILD_LDFLAGS_CXX_JDK="$OPENJDK_BUILD_LDFLAGS_CXX_JDK $LINKER_RELRO_FLAG" 53886 OPENJDK_BUILD_JVM_LDFLAGS="$OPENJDK_BUILD_JVM_LDFLAGS $LINKER_RELRO_FLAG" 53887 fi 53888 ;; 53889 * ) 53890 as_fn_error $? "Unrecognized \$DEBUG_LEVEL: $DEBUG_LEVEL" "$LINENO" 5 53891 ;; 53892 esac 53893 fi 53894 elif test "x$TOOLCHAIN_TYPE" = xsolstudio; then 53895 LDFLAGS_SOLSTUDIO="-Wl,-z,defs" 53896 OPENJDK_BUILD_LDFLAGS_JDK="$OPENJDK_BUILD_LDFLAGS_JDK $LDFLAGS_SOLSTUDIO -ztext" 53897 LDFLAGS_CXX_SOLSTUDIO="-norunpath" 53898 OPENJDK_BUILD_LDFLAGS_CXX_JDK="$OPENJDK_BUILD_LDFLAGS_CXX_JDK $LDFLAGS_CXX_SOLSTUDIO -xnolib" 53899 OPENJDK_BUILD_JVM_LDFLAGS="$OPENJDK_BUILD_JVM_LDFLAGS $LDFLAGS_SOLSTUDIO -library=%none -mt $LDFLAGS_CXX_SOLSTUDIO -z noversion" 53900 if test "x$OPENJDK_BUILD_CPU_ARCH" = "xsparc"; then 53901 OPENJDK_BUILD_JVM_LDFLAGS="$OPENJDK_BUILD_JVM_LDFLAGS -xarch=sparc" 53902 fi 53903 elif test "x$TOOLCHAIN_TYPE" = xxlc; then 53904 LDFLAGS_XLC="-b64 -brtl -bnolibpath -bexpall -bernotok -btextpsize:64K -bdatapsize:64K -bstackpsize:64K" 53905 OPENJDK_BUILD_LDFLAGS_JDK="${OPENJDK_BUILD_LDFLAGS_JDK} $LDFLAGS_XLC" 53906 OPENJDK_BUILD_JVM_LDFLAGS="$OPENJDK_BUILD_JVM_LDFLAGS $LDFLAGS_XLC" 53907 # We need '-qminimaltoc' or '-qpic=large -bbigtoc' if the TOC overflows. 53908 # Hotspot now overflows its 64K TOC (currently only for slowdebug), 53909 # so for slowdebug we build with '-qpic=large -bbigtoc'. 53910 if test "x$DEBUG_LEVEL" = xslowdebug; then 53911 OPENJDK_BUILD_JVM_LDFLAGS="$OPENJDK_BUILD_JVM_LDFLAGS -bbigtoc" 53912 fi 53913 fi 53914 53915 # Customize LDFLAGS for executables 53916 53917 OPENJDK_BUILD_LDFLAGS_JDKEXE="${OPENJDK_BUILD_LDFLAGS_JDK}" 53918 53919 if test "x$TOOLCHAIN_TYPE" = xmicrosoft; then 53920 if test "x$OPENJDK_BUILD_CPU_BITS" = "x64"; then 53921 LDFLAGS_STACK_SIZE=1048576 53922 else 53923 LDFLAGS_STACK_SIZE=327680 53924 fi 53925 OPENJDK_BUILD_LDFLAGS_JDKEXE="${OPENJDK_BUILD_LDFLAGS_JDKEXE} /STACK:$LDFLAGS_STACK_SIZE" 53926 elif test "x$OPENJDK_BUILD_OS" = xlinux; then 53927 OPENJDK_BUILD_LDFLAGS_JDKEXE="$OPENJDK_BUILD_LDFLAGS_JDKEXE -Wl,--allow-shlib-undefined" 53928 fi 53929 53930 OPENJDK_BUILD_LDFLAGS_JDKEXE="${OPENJDK_BUILD_LDFLAGS_JDKEXE} ${OPENJDK_BUILD_EXTRA_LDFLAGS_JDK}" 53931 53932 # Customize LDFLAGS for libs 53933 OPENJDK_BUILD_LDFLAGS_JDKLIB="${OPENJDK_BUILD_LDFLAGS_JDK}" 53934 53935 OPENJDK_BUILD_LDFLAGS_JDKLIB="${OPENJDK_BUILD_LDFLAGS_JDKLIB} ${SHARED_LIBRARY_FLAGS}" 53936 OPENJDK_BUILD_LDFLAGS_JDKLIB="${OPENJDK_BUILD_LDFLAGS_JDKLIB} ${LDFLAGS_NO_EXEC_STACK}" 53937 if test "x$TOOLCHAIN_TYPE" = xmicrosoft; then 53938 OPENJDK_BUILD_JAVA_BASE_LDFLAGS="${OPENJDK_BUILD_JAVA_BASE_LDFLAGS} \ 53939 -libpath:${OUTPUTDIR}/support/modules_libs/java.base" 53940 OPENJDK_BUILD_JDKLIB_LIBS="" 53941 else 53942 OPENJDK_BUILD_JAVA_BASE_LDFLAGS="${OPENJDK_BUILD_JAVA_BASE_LDFLAGS} \ 53943 -L\$(SUPPORT_OUTPUTDIR)/modules_libs/java.base" 53944 53945 if test "xBUILD" = "xTARGET"; then 53946 # On some platforms (mac) the linker warns about non existing -L dirs. 53947 # For any of the variants server, client or minimal, the dir matches the 53948 # variant name. The "main" variant should be used for linking. For the 53949 # rest, the dir is just server. 53950 if [[ " $JVM_VARIANTS " =~ " server " ]] || [[ " $JVM_VARIANTS " =~ " client " ]] \ 53951 || [[ " $JVM_VARIANTS " =~ " minimal " ]] ; then 53952 OPENJDK_BUILD_JAVA_BASE_LDFLAGS="${OPENJDK_BUILD_JAVA_BASE_LDFLAGS} \ 53953 -L\$(SUPPORT_OUTPUTDIR)/modules_libs/java.base/$JVM_VARIANT_MAIN" 53954 else 53955 OPENJDK_BUILD_JAVA_BASE_LDFLAGS="${OPENJDK_BUILD_JAVA_BASE_LDFLAGS} \ 53956 -L\$(SUPPORT_OUTPUTDIR)/modules_libs/java.base/server" 53957 fi 53958 elif test "xBUILD" = "xBUILD"; then 53959 # When building a buildjdk, it's always only the server variant 53960 OPENJDK_BUILD_JAVA_BASE_LDFLAGS="${OPENJDK_BUILD_JAVA_BASE_LDFLAGS} \ 53961 -L\$(SUPPORT_OUTPUTDIR)/modules_libs/java.base/server" 53962 fi 53963 53964 OPENJDK_BUILD_JDKLIB_LIBS="-ljava -ljvm" 53965 if test "x$TOOLCHAIN_TYPE" = xsolstudio; then 53966 OPENJDK_BUILD_JDKLIB_LIBS="$OPENJDK_BUILD_JDKLIB_LIBS -lc" 53967 fi 53968 53969 fi 53970 53971 OPENJDK_BUILD_LDFLAGS_JDKLIB="${OPENJDK_BUILD_LDFLAGS_JDKLIB} ${OPENJDK_BUILD_JAVA_BASE_LDFLAGS}" 53972 53973 # Set OPENJDK_BUILD_JVM_LIBS (per os) 53974 if test "x$OPENJDK_BUILD_OS" = xlinux; then 53975 OPENJDK_BUILD_JVM_LIBS="$OPENJDK_BUILD_JVM_LIBS -lm -ldl -lpthread" 53976 elif test "x$OPENJDK_BUILD_OS" = xsolaris; then 53977 # FIXME: This hard-coded path is not really proper. 53978 if test "x$OPENJDK_BUILD_CPU" = xx86_64; then 53979 OPENJDK_BUILD_SOLARIS_LIBM_LIBS="/usr/lib/amd64/libm.so.1" 53980 elif test "x$OPENJDK_BUILD_CPU" = xsparcv9; then 53981 OPENJDK_BUILD_SOLARIS_LIBM_LIBS="/usr/lib/sparcv9/libm.so.1" 53982 fi 53983 OPENJDK_BUILD_JVM_LIBS="$OPENJDK_BUILD_JVM_LIBS -lsocket -lsched -ldl $SOLARIS_LIBM_LIBS -lCrun \ 53984 -lthread -ldoor -lc -ldemangle -lnsl -lrt" 53985 elif test "x$OPENJDK_BUILD_OS" = xmacosx; then 53986 OPENJDK_BUILD_JVM_LIBS="$OPENJDK_BUILD_JVM_LIBS -lm" 53987 elif test "x$OPENJDK_BUILD_OS" = xaix; then 53988 OPENJDK_BUILD_JVM_LIBS="$OPENJDK_BUILD_JVM_LIBS -Wl,-lC_r -lm -ldl -lpthread" 53989 elif test "x$OPENJDK_BUILD_OS" = xbsd; then 53990 OPENJDK_BUILD_JVM_LIBS="$OPENJDK_BUILD_JVM_LIBS -lm" 53991 elif test "x$OPENJDK_BUILD_OS" = xwindows; then 53992 OPENJDK_BUILD_JVM_LIBS="$OPENJDK_BUILD_JVM_LIBS kernel32.lib user32.lib gdi32.lib winspool.lib \ 53993 comdlg32.lib advapi32.lib shell32.lib ole32.lib oleaut32.lib uuid.lib \ 53994 wsock32.lib winmm.lib version.lib psapi.lib" 53995 fi 53996 53997 # Set OPENJDK_BUILD_JVM_ASFLAGS 53998 if test "x$OPENJDK_BUILD_OS" = xlinux; then 53999 if test "x$OPENJDK_BUILD_CPU" = xx86; then 54000 OPENJDK_BUILD_JVM_ASFLAGS="$OPENJDK_BUILD_JVM_ASFLAGS -march=i586" 54001 fi 54002 elif test "x$OPENJDK_BUILD_OS" = xmacosx; then 54003 OPENJDK_BUILD_JVM_ASFLAGS="$OPENJDK_BUILD_JVM_ASFLAGS -x assembler-with-cpp -mno-omit-leaf-frame-pointer -mstack-alignment=16" 54004 fi 54005 54006 OPENJDK_BUILD_LDFLAGS_JDKLIB="${OPENJDK_BUILD_LDFLAGS_JDKLIB} ${OPENJDK_BUILD_EXTRA_LDFLAGS_JDK}" 54007 54008 54009 54010 54011 54012 54013 54014 54015 54016 54017 54018 54019 54020 54021 54022 54023 # Tests are only ever compiled for TARGET 54024 # Flags for compiling test libraries 54025 CFLAGS_TESTLIB="$COMMON_CCXXFLAGS_JDK $CFLAGS_JDK $PICFLAG $CFLAGS_JDKLIB_EXTRA" 54026 CXXFLAGS_TESTLIB="$COMMON_CCXXFLAGS_JDK $CXXFLAGS_JDK $PICFLAG $CXXFLAGS_JDKLIB_EXTRA" 54027 54028 # Flags for compiling test executables 54029 CFLAGS_TESTEXE="$COMMON_CCXXFLAGS_JDK $CFLAGS_JDK" 54030 CXXFLAGS_TESTEXE="$COMMON_CCXXFLAGS_JDK $CXXFLAGS_JDK" 54031 54032 54033 54034 54035 54036 54037 LDFLAGS_TESTLIB="$LDFLAGS_JDKLIB" 54038 LDFLAGS_TESTEXE="$LDFLAGS_JDKEXE $JAVA_BASE_LDFLAGS" 54039 54040 54041 54042 54043 54044 54045 # Check that the compiler supports -mX (or -qX on AIX) flags 54046 # Set COMPILER_SUPPORTS_TARGET_BITS_FLAG to 'true' if it does 54047 54048 54049 54050 54051 54052 54053 54054 54055 54056 54057 54058 54059 54060 54061 54062 54063 54064 54065 54066 54067 54068 54069 54070 54071 54072 54073 54074 54075 54076 54077 54078 54079 54080 54081 54082 54083 54084 54085 54086 54087 54088 54089 54090 54091 54092 54093 54094 # Execute function body 54095 54096 54097 54098 54099 54100 54101 54102 54103 54104 54105 54106 54107 54108 54109 54110 54111 54112 54113 54114 54115 54116 54117 54118 54119 54120 54121 54122 54123 54124 54125 54126 54127 54128 54129 54130 54131 54132 54133 54134 54135 54136 54137 54138 54139 54140 54141 54142 54143 # Execute function body 54144 54145 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if the C compiler supports \"${COMPILER_TARGET_BITS_FLAG}${OPENJDK_TARGET_CPU_BITS}\"" >&5 54146 $as_echo_n "checking if the C compiler supports \"${COMPILER_TARGET_BITS_FLAG}${OPENJDK_TARGET_CPU_BITS}\"... " >&6; } 54147 supports=yes 54148 54149 saved_cflags="$CFLAGS" 54150 CFLAGS="$CFLAGS ${COMPILER_TARGET_BITS_FLAG}${OPENJDK_TARGET_CPU_BITS}" 54151 ac_ext=c 54152 ac_cpp='$CPP $CPPFLAGS' 54153 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5' 54154 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' 54155 ac_compiler_gnu=$ac_cv_c_compiler_gnu 54156 54157 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 54158 /* end confdefs.h. */ 54159 int i; 54160 _ACEOF 54161 if ac_fn_c_try_compile "$LINENO"; then : 54162 54163 else 54164 supports=no 54165 fi 54166 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext 54167 ac_ext=cpp 54168 ac_cpp='$CXXCPP $CPPFLAGS' 54169 ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5' 54170 ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' 54171 ac_compiler_gnu=$ac_cv_cxx_compiler_gnu 54172 54173 CFLAGS="$saved_cflags" 54174 54175 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $supports" >&5 54176 $as_echo "$supports" >&6; } 54177 if test "x$supports" = "xyes" ; then 54178 : 54179 C_COMP_SUPPORTS="yes" 54180 else 54181 : 54182 C_COMP_SUPPORTS="no" 54183 fi 54184 54185 54186 54187 54188 54189 54190 54191 54192 54193 54194 54195 54196 54197 54198 54199 54200 54201 54202 54203 54204 54205 54206 54207 54208 54209 54210 54211 54212 54213 54214 54215 54216 54217 54218 54219 54220 54221 54222 54223 54224 54225 54226 54227 54228 54229 54230 54231 54232 54233 54234 54235 54236 54237 54238 54239 54240 54241 54242 54243 # Execute function body 54244 54245 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if the C++ compiler supports \"${COMPILER_TARGET_BITS_FLAG}${OPENJDK_TARGET_CPU_BITS}\"" >&5 54246 $as_echo_n "checking if the C++ compiler supports \"${COMPILER_TARGET_BITS_FLAG}${OPENJDK_TARGET_CPU_BITS}\"... " >&6; } 54247 supports=yes 54248 54249 saved_cxxflags="$CXXFLAGS" 54250 CXXFLAGS="$CXXFLAG ${COMPILER_TARGET_BITS_FLAG}${OPENJDK_TARGET_CPU_BITS}" 54251 ac_ext=cpp 54252 ac_cpp='$CXXCPP $CPPFLAGS' 54253 ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5' 54254 ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' 54255 ac_compiler_gnu=$ac_cv_cxx_compiler_gnu 54256 54257 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 54258 /* end confdefs.h. */ 54259 int i; 54260 _ACEOF 54261 if ac_fn_cxx_try_compile "$LINENO"; then : 54262 54263 else 54264 supports=no 54265 fi 54266 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext 54267 ac_ext=cpp 54268 ac_cpp='$CXXCPP $CPPFLAGS' 54269 ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5' 54270 ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' 54271 ac_compiler_gnu=$ac_cv_cxx_compiler_gnu 54272 54273 CXXFLAGS="$saved_cxxflags" 54274 54275 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $supports" >&5 54276 $as_echo "$supports" >&6; } 54277 if test "x$supports" = "xyes" ; then 54278 : 54279 CXX_COMP_SUPPORTS="yes" 54280 else 54281 : 54282 CXX_COMP_SUPPORTS="no" 54283 fi 54284 54285 54286 54287 54288 54289 54290 54291 54292 54293 54294 54295 54296 54297 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if both compilers support \"${COMPILER_TARGET_BITS_FLAG}${OPENJDK_TARGET_CPU_BITS}\"" >&5 54298 $as_echo_n "checking if both compilers support \"${COMPILER_TARGET_BITS_FLAG}${OPENJDK_TARGET_CPU_BITS}\"... " >&6; } 54299 supports=no 54300 if test "x$C_COMP_SUPPORTS" = "xyes" -a "x$CXX_COMP_SUPPORTS" = "xyes"; then supports=yes; fi 54301 54302 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $supports" >&5 54303 $as_echo "$supports" >&6; } 54304 if test "x$supports" = "xyes" ; then 54305 : 54306 COMPILER_SUPPORTS_TARGET_BITS_FLAG=true 54307 else 54308 : 54309 COMPILER_SUPPORTS_TARGET_BITS_FLAG=false 54310 fi 54311 54312 54313 54314 54315 54316 54317 54318 54319 # Check whether --enable-warnings-as-errors was given. 54320 if test "${enable_warnings_as_errors+set}" = set; then : 54321 enableval=$enable_warnings_as_errors; 54322 fi 54323 54324 54325 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if native warnings are errors" >&5 54326 $as_echo_n "checking if native warnings are errors... " >&6; } 54327 if test "x$enable_warnings_as_errors" = "xyes"; then 54328 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes (explicitly set)" >&5 54329 $as_echo "yes (explicitly set)" >&6; } 54330 WARNINGS_AS_ERRORS=true 54331 elif test "x$enable_warnings_as_errors" = "xno"; then 54332 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 54333 $as_echo "no" >&6; } 54334 WARNINGS_AS_ERRORS=false 54335 elif test "x$enable_warnings_as_errors" = "x"; then 54336 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes (default)" >&5 54337 $as_echo "yes (default)" >&6; } 54338 WARNINGS_AS_ERRORS=true 54339 else 54340 as_fn_error $? "--enable-warnings-as-errors accepts no argument" "$LINENO" 5 54341 fi 54342 54343 54344 54345 case "${TOOLCHAIN_TYPE}" in 54346 microsoft) 54347 DISABLE_WARNING_PREFIX="-wd" 54348 CFLAGS_WARNINGS_ARE_ERRORS="-WX" 54349 ;; 54350 solstudio) 54351 DISABLE_WARNING_PREFIX="-erroff=" 54352 CFLAGS_WARNINGS_ARE_ERRORS="-errtags -errwarn=%all" 54353 ;; 54354 gcc) 54355 # Prior to gcc 4.4, a -Wno-X where X is unknown for that version of gcc will cause an error 54356 54357 54358 54359 54360 54361 54362 54363 54364 54365 54366 54367 54368 54369 54370 54371 54372 54373 54374 54375 54376 54377 54378 54379 54380 54381 54382 54383 54384 54385 54386 54387 54388 54389 54390 54391 54392 54393 54394 54395 54396 54397 54398 54399 54400 54401 54402 54403 # Execute function body 54404 54405 54406 54407 54408 54409 54410 54411 54412 54413 54414 54415 54416 54417 54418 54419 54420 54421 54422 54423 54424 54425 54426 54427 54428 54429 54430 54431 54432 54433 54434 54435 54436 54437 54438 54439 54440 54441 54442 54443 54444 54445 54446 54447 54448 54449 54450 54451 54452 # Execute function body 54453 54454 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if the C compiler supports \"-Wno-this-is-a-warning-that-do-not-exist\"" >&5 54455 $as_echo_n "checking if the C compiler supports \"-Wno-this-is-a-warning-that-do-not-exist\"... " >&6; } 54456 supports=yes 54457 54458 saved_cflags="$CFLAGS" 54459 CFLAGS="$CFLAGS -Wno-this-is-a-warning-that-do-not-exist" 54460 ac_ext=c 54461 ac_cpp='$CPP $CPPFLAGS' 54462 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5' 54463 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' 54464 ac_compiler_gnu=$ac_cv_c_compiler_gnu 54465 54466 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 54467 /* end confdefs.h. */ 54468 int i; 54469 _ACEOF 54470 if ac_fn_c_try_compile "$LINENO"; then : 54471 54472 else 54473 supports=no 54474 fi 54475 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext 54476 ac_ext=cpp 54477 ac_cpp='$CXXCPP $CPPFLAGS' 54478 ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5' 54479 ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' 54480 ac_compiler_gnu=$ac_cv_cxx_compiler_gnu 54481 54482 CFLAGS="$saved_cflags" 54483 54484 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $supports" >&5 54485 $as_echo "$supports" >&6; } 54486 if test "x$supports" = "xyes" ; then 54487 : 54488 C_COMP_SUPPORTS="yes" 54489 else 54490 : 54491 C_COMP_SUPPORTS="no" 54492 fi 54493 54494 54495 54496 54497 54498 54499 54500 54501 54502 54503 54504 54505 54506 54507 54508 54509 54510 54511 54512 54513 54514 54515 54516 54517 54518 54519 54520 54521 54522 54523 54524 54525 54526 54527 54528 54529 54530 54531 54532 54533 54534 54535 54536 54537 54538 54539 54540 54541 54542 54543 54544 54545 54546 54547 54548 54549 54550 54551 54552 # Execute function body 54553 54554 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if the C++ compiler supports \"-Wno-this-is-a-warning-that-do-not-exist\"" >&5 54555 $as_echo_n "checking if the C++ compiler supports \"-Wno-this-is-a-warning-that-do-not-exist\"... " >&6; } 54556 supports=yes 54557 54558 saved_cxxflags="$CXXFLAGS" 54559 CXXFLAGS="$CXXFLAG -Wno-this-is-a-warning-that-do-not-exist" 54560 ac_ext=cpp 54561 ac_cpp='$CXXCPP $CPPFLAGS' 54562 ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5' 54563 ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' 54564 ac_compiler_gnu=$ac_cv_cxx_compiler_gnu 54565 54566 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 54567 /* end confdefs.h. */ 54568 int i; 54569 _ACEOF 54570 if ac_fn_cxx_try_compile "$LINENO"; then : 54571 54572 else 54573 supports=no 54574 fi 54575 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext 54576 ac_ext=cpp 54577 ac_cpp='$CXXCPP $CPPFLAGS' 54578 ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5' 54579 ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' 54580 ac_compiler_gnu=$ac_cv_cxx_compiler_gnu 54581 54582 CXXFLAGS="$saved_cxxflags" 54583 54584 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $supports" >&5 54585 $as_echo "$supports" >&6; } 54586 if test "x$supports" = "xyes" ; then 54587 : 54588 CXX_COMP_SUPPORTS="yes" 54589 else 54590 : 54591 CXX_COMP_SUPPORTS="no" 54592 fi 54593 54594 54595 54596 54597 54598 54599 54600 54601 54602 54603 54604 54605 54606 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if both compilers support \"-Wno-this-is-a-warning-that-do-not-exist\"" >&5 54607 $as_echo_n "checking if both compilers support \"-Wno-this-is-a-warning-that-do-not-exist\"... " >&6; } 54608 supports=no 54609 if test "x$C_COMP_SUPPORTS" = "xyes" -a "x$CXX_COMP_SUPPORTS" = "xyes"; then supports=yes; fi 54610 54611 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $supports" >&5 54612 $as_echo "$supports" >&6; } 54613 if test "x$supports" = "xyes" ; then 54614 : 54615 GCC_CAN_DISABLE_WARNINGS=true 54616 else 54617 : 54618 GCC_CAN_DISABLE_WARNINGS=false 54619 54620 fi 54621 54622 54623 54624 54625 54626 54627 if test "x$GCC_CAN_DISABLE_WARNINGS" = "xtrue"; then 54628 DISABLE_WARNING_PREFIX="-Wno-" 54629 else 54630 DISABLE_WARNING_PREFIX= 54631 fi 54632 CFLAGS_WARNINGS_ARE_ERRORS="-Werror" 54633 # Repeate the check for the BUILD_CC and BUILD_CXX. Need to also reset 54634 # CFLAGS since any target specific flags will likely not work with the 54635 # build compiler 54636 CC_OLD="$CC" 54637 CXX_OLD="$CXX" 54638 CC="$BUILD_CC" 54639 CXX="$BUILD_CXX" 54640 CFLAGS_OLD="$CFLAGS" 54641 CFLAGS="" 54642 54643 54644 54645 54646 54647 54648 54649 54650 54651 54652 54653 54654 54655 54656 54657 54658 54659 54660 54661 54662 54663 54664 54665 54666 54667 54668 54669 54670 54671 54672 54673 54674 54675 54676 54677 54678 54679 54680 54681 54682 54683 54684 54685 54686 54687 54688 54689 # Execute function body 54690 54691 54692 54693 54694 54695 54696 54697 54698 54699 54700 54701 54702 54703 54704 54705 54706 54707 54708 54709 54710 54711 54712 54713 54714 54715 54716 54717 54718 54719 54720 54721 54722 54723 54724 54725 54726 54727 54728 54729 54730 54731 54732 54733 54734 54735 54736 54737 54738 # Execute function body 54739 54740 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if the C compiler supports \"-Wno-this-is-a-warning-that-do-not-exist\"" >&5 54741 $as_echo_n "checking if the C compiler supports \"-Wno-this-is-a-warning-that-do-not-exist\"... " >&6; } 54742 supports=yes 54743 54744 saved_cflags="$CFLAGS" 54745 CFLAGS="$CFLAGS -Wno-this-is-a-warning-that-do-not-exist" 54746 ac_ext=c 54747 ac_cpp='$CPP $CPPFLAGS' 54748 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5' 54749 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' 54750 ac_compiler_gnu=$ac_cv_c_compiler_gnu 54751 54752 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 54753 /* end confdefs.h. */ 54754 int i; 54755 _ACEOF 54756 if ac_fn_c_try_compile "$LINENO"; then : 54757 54758 else 54759 supports=no 54760 fi 54761 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext 54762 ac_ext=cpp 54763 ac_cpp='$CXXCPP $CPPFLAGS' 54764 ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5' 54765 ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' 54766 ac_compiler_gnu=$ac_cv_cxx_compiler_gnu 54767 54768 CFLAGS="$saved_cflags" 54769 54770 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $supports" >&5 54771 $as_echo "$supports" >&6; } 54772 if test "x$supports" = "xyes" ; then 54773 : 54774 C_COMP_SUPPORTS="yes" 54775 else 54776 : 54777 C_COMP_SUPPORTS="no" 54778 fi 54779 54780 54781 54782 54783 54784 54785 54786 54787 54788 54789 54790 54791 54792 54793 54794 54795 54796 54797 54798 54799 54800 54801 54802 54803 54804 54805 54806 54807 54808 54809 54810 54811 54812 54813 54814 54815 54816 54817 54818 54819 54820 54821 54822 54823 54824 54825 54826 54827 54828 54829 54830 54831 54832 54833 54834 54835 54836 54837 54838 # Execute function body 54839 54840 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if the C++ compiler supports \"-Wno-this-is-a-warning-that-do-not-exist\"" >&5 54841 $as_echo_n "checking if the C++ compiler supports \"-Wno-this-is-a-warning-that-do-not-exist\"... " >&6; } 54842 supports=yes 54843 54844 saved_cxxflags="$CXXFLAGS" 54845 CXXFLAGS="$CXXFLAG -Wno-this-is-a-warning-that-do-not-exist" 54846 ac_ext=cpp 54847 ac_cpp='$CXXCPP $CPPFLAGS' 54848 ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5' 54849 ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' 54850 ac_compiler_gnu=$ac_cv_cxx_compiler_gnu 54851 54852 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 54853 /* end confdefs.h. */ 54854 int i; 54855 _ACEOF 54856 if ac_fn_cxx_try_compile "$LINENO"; then : 54857 54858 else 54859 supports=no 54860 fi 54861 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext 54862 ac_ext=cpp 54863 ac_cpp='$CXXCPP $CPPFLAGS' 54864 ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5' 54865 ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' 54866 ac_compiler_gnu=$ac_cv_cxx_compiler_gnu 54867 54868 CXXFLAGS="$saved_cxxflags" 54869 54870 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $supports" >&5 54871 $as_echo "$supports" >&6; } 54872 if test "x$supports" = "xyes" ; then 54873 : 54874 CXX_COMP_SUPPORTS="yes" 54875 else 54876 : 54877 CXX_COMP_SUPPORTS="no" 54878 fi 54879 54880 54881 54882 54883 54884 54885 54886 54887 54888 54889 54890 54891 54892 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if both compilers support \"-Wno-this-is-a-warning-that-do-not-exist\"" >&5 54893 $as_echo_n "checking if both compilers support \"-Wno-this-is-a-warning-that-do-not-exist\"... " >&6; } 54894 supports=no 54895 if test "x$C_COMP_SUPPORTS" = "xyes" -a "x$CXX_COMP_SUPPORTS" = "xyes"; then supports=yes; fi 54896 54897 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $supports" >&5 54898 $as_echo "$supports" >&6; } 54899 if test "x$supports" = "xyes" ; then 54900 : 54901 BUILD_CC_CAN_DISABLE_WARNINGS=true 54902 else 54903 : 54904 BUILD_CC_CAN_DISABLE_WARNINGS=false 54905 54906 fi 54907 54908 54909 54910 54911 54912 54913 if test "x$BUILD_CC_CAN_DISABLE_WARNINGS" = "xtrue"; then 54914 BUILD_CC_DISABLE_WARNING_PREFIX="-Wno-" 54915 else 54916 BUILD_CC_DISABLE_WARNING_PREFIX= 54917 fi 54918 CC="$CC_OLD" 54919 CXX="$CXX_OLD" 54920 CFLAGS="$CFLAGS_OLD" 54921 ;; 54922 clang) 54923 DISABLE_WARNING_PREFIX="-Wno-" 54924 CFLAGS_WARNINGS_ARE_ERRORS="-Werror" 54925 ;; 54926 xlc) 54927 DISABLE_WARNING_PREFIX="-qsuppress=" 54928 CFLAGS_WARNINGS_ARE_ERRORS="-qhalt=w" 54929 ;; 54930 esac 54931 54932 54933 54934 54935 54936 # Setup debug symbols (need objcopy from the toolchain for that) 54937 54938 # 54939 # NATIVE_DEBUG_SYMBOLS 54940 # This must be done after the toolchain is setup, since we're looking at objcopy. 54941 # 54942 { $as_echo "$as_me:${as_lineno-$LINENO}: checking what type of native debug symbols to use" >&5 54943 $as_echo_n "checking what type of native debug symbols to use... " >&6; } 54944 54945 # Check whether --with-native-debug-symbols was given. 54946 if test "${with_native_debug_symbols+set}" = set; then : 54947 withval=$with_native_debug_symbols; 54948 if test "x$OPENJDK_TARGET_OS" = xaix; then 54949 if test "x$withval" = xexternal || test "x$withval" = xzipped; then 54950 as_fn_error $? "AIX only supports the parameters 'none' and 'internal' for --with-native-debug-symbols" "$LINENO" 5 54951 fi 54952 fi 54953 54954 else 54955 54956 if test "x$OPENJDK_TARGET_OS" = xaix; then 54957 # AIX doesn't support 'external' so use 'internal' as default 54958 with_native_debug_symbols="internal" 54959 else 54960 if test "x$STATIC_BUILD" = xtrue; then 54961 with_native_debug_symbols="none" 54962 else 54963 with_native_debug_symbols="external" 54964 fi 54965 fi 54966 54967 fi 54968 54969 NATIVE_DEBUG_SYMBOLS=$with_native_debug_symbols 54970 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $NATIVE_DEBUG_SYMBOLS" >&5 54971 $as_echo "$NATIVE_DEBUG_SYMBOLS" >&6; } 54972 54973 if test "x$NATIVE_DEBUG_SYMBOLS" = xzipped; then 54974 54975 if test "x$OPENJDK_TARGET_OS" = xsolaris || test "x$OPENJDK_TARGET_OS" = xlinux; then 54976 if test "x$OBJCOPY" = x; then 54977 # enabling of enable-debug-symbols and can't find objcopy 54978 # this is an error 54979 as_fn_error $? "Unable to find objcopy, cannot enable native debug symbols" "$LINENO" 5 54980 fi 54981 fi 54982 54983 COMPILE_WITH_DEBUG_SYMBOLS=true 54984 COPY_DEBUG_SYMBOLS=true 54985 ZIP_EXTERNAL_DEBUG_SYMBOLS=true 54986 elif test "x$NATIVE_DEBUG_SYMBOLS" = xnone; then 54987 COMPILE_WITH_DEBUG_SYMBOLS=false 54988 COPY_DEBUG_SYMBOLS=false 54989 ZIP_EXTERNAL_DEBUG_SYMBOLS=false 54990 elif test "x$NATIVE_DEBUG_SYMBOLS" = xinternal; then 54991 COMPILE_WITH_DEBUG_SYMBOLS=true 54992 COPY_DEBUG_SYMBOLS=false 54993 ZIP_EXTERNAL_DEBUG_SYMBOLS=false 54994 elif test "x$NATIVE_DEBUG_SYMBOLS" = xexternal; then 54995 54996 if test "x$OPENJDK_TARGET_OS" = xsolaris || test "x$OPENJDK_TARGET_OS" = xlinux; then 54997 if test "x$OBJCOPY" = x; then 54998 # enabling of enable-debug-symbols and can't find objcopy 54999 # this is an error 55000 as_fn_error $? "Unable to find objcopy, cannot enable native debug symbols" "$LINENO" 5 55001 fi 55002 fi 55003 55004 COMPILE_WITH_DEBUG_SYMBOLS=true 55005 COPY_DEBUG_SYMBOLS=true 55006 ZIP_EXTERNAL_DEBUG_SYMBOLS=false 55007 else 55008 as_fn_error $? "Allowed native debug symbols are: none, internal, external, zipped" "$LINENO" 5 55009 fi 55010 55011 # --enable-debug-symbols is deprecated. 55012 # Please use --with-native-debug-symbols=[internal,external,zipped] . 55013 55014 # Check whether --enable-debug-symbols was given. 55015 if test "${enable_debug_symbols+set}" = set; then : 55016 enableval=$enable_debug_symbols; 55017 fi 55018 55019 if test "x$enable_debug_symbols" != x; then 55020 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Option --enable-debug-symbols is deprecated and will be ignored." >&5 55021 $as_echo "$as_me: WARNING: Option --enable-debug-symbols is deprecated and will be ignored." >&2;} 55022 55023 if test "xPlease use --with-native-debug-symbols=[internal,external,zipped] ." != x; then 55024 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Please use --with-native-debug-symbols=[internal,external,zipped] ." >&5 55025 $as_echo "$as_me: WARNING: Please use --with-native-debug-symbols=[internal,external,zipped] ." >&2;} 55026 fi 55027 55028 fi 55029 55030 55031 # --enable-zip-debug-info is deprecated. 55032 # Please use --with-native-debug-symbols=zipped . 55033 55034 # Check whether --enable-zip-debug-info was given. 55035 if test "${enable_zip_debug_info+set}" = set; then : 55036 enableval=$enable_zip_debug_info; 55037 fi 55038 55039 if test "x$enable_zip_debug_info" != x; then 55040 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Option --enable-zip-debug-info is deprecated and will be ignored." >&5 55041 $as_echo "$as_me: WARNING: Option --enable-zip-debug-info is deprecated and will be ignored." >&2;} 55042 55043 if test "xPlease use --with-native-debug-symbols=zipped ." != x; then 55044 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Please use --with-native-debug-symbols=zipped ." >&5 55045 $as_echo "$as_me: WARNING: Please use --with-native-debug-symbols=zipped ." >&2;} 55046 fi 55047 55048 fi 55049 55050 55051 55052 55053 55054 55055 55056 # Check whether --enable-native-coverage was given. 55057 if test "${enable_native_coverage+set}" = set; then : 55058 enableval=$enable_native_coverage; 55059 fi 55060 55061 GCOV_ENABLED="false" 55062 if test "x$enable_native_coverage" = "xyes"; then 55063 if test "x$TOOLCHAIN_TYPE" = "xgcc"; then 55064 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if native coverage is enabled" >&5 55065 $as_echo_n "checking if native coverage is enabled... " >&6; } 55066 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 55067 $as_echo "yes" >&6; } 55068 GCOV_CFLAGS="-fprofile-arcs -ftest-coverage -fno-inline" 55069 GCOV_LDFLAGS="-fprofile-arcs" 55070 JVM_CFLAGS="$JVM_CFLAGS $GCOV_CFLAGS" 55071 JVM_LDFLAGS="$JVM_LDFLAGS $GCOV_LDFLAGS" 55072 CFLAGS_JDKLIB="$CFLAGS_JDKLIB $GCOV_CFLAGS" 55073 CFLAGS_JDKEXE="$CFLAGS_JDKEXE $GCOV_CFLAGS" 55074 CXXFLAGS_JDKLIB="$CXXFLAGS_JDKLIB $GCOV_CFLAGS" 55075 CXXFLAGS_JDKEXE="$CXXFLAGS_JDKEXE $GCOV_CFLAGS" 55076 LDFLAGS_JDKLIB="$LDFLAGS_JDKLIB $GCOV_LDFLAGS" 55077 LDFLAGS_JDKEXE="$LDFLAGS_JDKEXE $GCOV_LDFLAGS" 55078 GCOV_ENABLED="true" 55079 else 55080 as_fn_error $? "--enable-native-coverage only works with toolchain type gcc" "$LINENO" 5 55081 fi 55082 elif test "x$enable_native_coverage" = "xno"; then 55083 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if native coverage is enabled" >&5 55084 $as_echo_n "checking if native coverage is enabled... " >&6; } 55085 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 55086 $as_echo "no" >&6; } 55087 elif test "x$enable_native_coverage" != "x"; then 55088 as_fn_error $? "--enable-native-coverage can only be assigned \"yes\" or \"no\"" "$LINENO" 5 55089 fi 55090 55091 55092 55093 55094 # AddressSanitizer 55095 55096 # Check whether --enable-asan was given. 55097 if test "${enable_asan+set}" = set; then : 55098 enableval=$enable_asan; 55099 fi 55100 55101 ASAN_ENABLED="no" 55102 if test "x$enable_asan" = "xyes"; then 55103 case $TOOLCHAIN_TYPE in 55104 gcc | clang) 55105 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if asan is enabled" >&5 55106 $as_echo_n "checking if asan is enabled... " >&6; } 55107 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 55108 $as_echo "yes" >&6; } 55109 ASAN_CFLAGS="-fsanitize=address -fno-omit-frame-pointer" 55110 ASAN_LDFLAGS="-fsanitize=address" 55111 JVM_CFLAGS="$JVM_CFLAGS $ASAN_CFLAGS" 55112 JVM_LDFLAGS="$JVM_LDFLAGS $ASAN_LDFLAGS" 55113 CFLAGS_JDKLIB="$CFLAGS_JDKLIB $ASAN_CFLAGS" 55114 CFLAGS_JDKEXE="$CFLAGS_JDKEXE $ASAN_CFLAGS" 55115 CXXFLAGS_JDKLIB="$CXXFLAGS_JDKLIB $ASAN_CFLAGS" 55116 CXXFLAGS_JDKEXE="$CXXFLAGS_JDKEXE $ASAN_CFLAGS" 55117 LDFLAGS_JDKLIB="$LDFLAGS_JDKLIB $ASAN_LDFLAGS" 55118 LDFLAGS_JDKEXE="$LDFLAGS_JDKEXE $ASAN_LDFLAGS" 55119 ASAN_ENABLED="yes" 55120 ;; 55121 *) 55122 as_fn_error $? "--enable-asan only works with toolchain type gcc or clang" "$LINENO" 5 55123 ;; 55124 esac 55125 elif test "x$enable_asan" = "xno"; then 55126 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if asan is enabled" >&5 55127 $as_echo_n "checking if asan is enabled... " >&6; } 55128 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 55129 $as_echo "no" >&6; } 55130 elif test "x$enable_asan" != "x"; then 55131 as_fn_error $? "--enable-asan can only be assigned \"yes\" or \"no\"" "$LINENO" 5 55132 fi 55133 55134 55135 55136 55137 # Need toolchain to setup dtrace 55138 55139 # Test for dtrace dependencies 55140 # Check whether --enable-dtrace was given. 55141 if test "${enable_dtrace+set}" = set; then : 55142 enableval=$enable_dtrace; 55143 fi 55144 55145 55146 DTRACE_DEP_MISSING=false 55147 55148 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for dtrace tool" >&5 55149 $as_echo_n "checking for dtrace tool... " >&6; } 55150 if test "x$DTRACE" != "x" && test -x "$DTRACE"; then 55151 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $DTRACE" >&5 55152 $as_echo "$DTRACE" >&6; } 55153 else 55154 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found, cannot build dtrace" >&5 55155 $as_echo "not found, cannot build dtrace" >&6; } 55156 DTRACE_DEP_MISSING=true 55157 fi 55158 55159 for ac_header in sys/sdt.h 55160 do : 55161 ac_fn_cxx_check_header_mongrel "$LINENO" "sys/sdt.h" "ac_cv_header_sys_sdt_h" "$ac_includes_default" 55162 if test "x$ac_cv_header_sys_sdt_h" = xyes; then : 55163 cat >>confdefs.h <<_ACEOF 55164 #define HAVE_SYS_SDT_H 1 55165 _ACEOF 55166 DTRACE_HEADERS_OK=yes 55167 else 55168 DTRACE_HEADERS_OK=no 55169 fi 55170 55171 done 55172 55173 if test "x$DTRACE_HEADERS_OK" != "xyes"; then 55174 DTRACE_DEP_MISSING=true 55175 fi 55176 55177 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if dtrace should be built" >&5 55178 $as_echo_n "checking if dtrace should be built... " >&6; } 55179 if test "x$enable_dtrace" = "xyes"; then 55180 if test "x$DTRACE_DEP_MISSING" = "xtrue"; then 55181 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no, missing dependencies" >&5 55182 $as_echo "no, missing dependencies" >&6; } 55183 55184 # Print a helpful message on how to acquire the necessary build dependency. 55185 # dtrace is the help tag: freetype, cups, alsa etc 55186 MISSING_DEPENDENCY=dtrace 55187 55188 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 55189 cygwin_help $MISSING_DEPENDENCY 55190 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 55191 msys_help $MISSING_DEPENDENCY 55192 else 55193 PKGHANDLER_COMMAND= 55194 55195 case $PKGHANDLER in 55196 apt-get) 55197 apt_help $MISSING_DEPENDENCY ;; 55198 yum) 55199 yum_help $MISSING_DEPENDENCY ;; 55200 brew) 55201 brew_help $MISSING_DEPENDENCY ;; 55202 port) 55203 port_help $MISSING_DEPENDENCY ;; 55204 pkgutil) 55205 pkgutil_help $MISSING_DEPENDENCY ;; 55206 pkgadd) 55207 pkgadd_help $MISSING_DEPENDENCY ;; 55208 esac 55209 55210 if test "x$PKGHANDLER_COMMAND" != x; then 55211 HELP_MSG="You might be able to fix this by running '$PKGHANDLER_COMMAND'." 55212 fi 55213 fi 55214 55215 as_fn_error $? "Cannot enable dtrace with missing dependencies. See above. $HELP_MSG" "$LINENO" 5 55216 else 55217 INCLUDE_DTRACE=true 55218 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes, forced" >&5 55219 $as_echo "yes, forced" >&6; } 55220 fi 55221 elif test "x$enable_dtrace" = "xno"; then 55222 INCLUDE_DTRACE=false 55223 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no, forced" >&5 55224 $as_echo "no, forced" >&6; } 55225 elif test "x$enable_dtrace" = "xauto" || test "x$enable_dtrace" = "x"; then 55226 if test "x$DTRACE_DEP_MISSING" = "xtrue"; then 55227 INCLUDE_DTRACE=false 55228 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no, missing dependencies" >&5 55229 $as_echo "no, missing dependencies" >&6; } 55230 else 55231 INCLUDE_DTRACE=true 55232 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes, dependencies present" >&5 55233 $as_echo "yes, dependencies present" >&6; } 55234 fi 55235 else 55236 as_fn_error $? "Invalid value for --enable-dtrace: $enable_dtrace" "$LINENO" 5 55237 fi 55238 55239 55240 # Check whether --enable-aot was given. 55241 if test "${enable_aot+set}" = set; then : 55242 enableval=$enable_aot; 55243 fi 55244 55245 55246 if test "x$enable_aot" = "x" || test "x$enable_aot" = "xauto"; then 55247 ENABLE_AOT="true" 55248 elif test "x$enable_aot" = "xyes"; then 55249 ENABLE_AOT="true" 55250 elif test "x$enable_aot" = "xno"; then 55251 ENABLE_AOT="false" 55252 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if aot should be enabled" >&5 55253 $as_echo_n "checking if aot should be enabled... " >&6; } 55254 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no, forced" >&5 55255 $as_echo "no, forced" >&6; } 55256 else 55257 as_fn_error $? "Invalid value for --enable-aot: $enable_aot" "$LINENO" 5 55258 fi 55259 55260 if test "x$ENABLE_AOT" = "xtrue"; then 55261 # Only enable AOT on X64 platforms. 55262 if test "x$OPENJDK_TARGET_CPU" = "xx86_64"; then 55263 if test -e "${TOPDIR}/src/jdk.aot"; then 55264 if test -e "${TOPDIR}/src/jdk.internal.vm.compiler"; then 55265 ENABLE_AOT="true" 55266 else 55267 ENABLE_AOT="false" 55268 if test "x$enable_aot" = "xyes"; then 55269 as_fn_error $? "Cannot build AOT without src/jdk.internal.vm.compiler sources. Remove --enable-aot." "$LINENO" 5 55270 fi 55271 fi 55272 else 55273 ENABLE_AOT="false" 55274 if test "x$enable_aot" = "xyes"; then 55275 as_fn_error $? "Cannot build AOT without src/jdk.aot sources. Remove --enable-aot." "$LINENO" 5 55276 fi 55277 fi 55278 else 55279 ENABLE_AOT="false" 55280 if test "x$enable_aot" = "xyes"; then 55281 as_fn_error $? "AOT is currently only supported on x86_64. Remove --enable-aot." "$LINENO" 5 55282 fi 55283 fi 55284 fi 55285 55286 55287 55288 55289 # Check whether --enable-cds was given. 55290 if test "${enable_cds+set}" = set; then : 55291 enableval=$enable_cds; 55292 fi 55293 55294 55295 if test "x$enable_cds" = "x" || test "x$enable_cds" = "xyes"; then 55296 ENABLE_CDS="true" 55297 elif test "x$enable_cds" = "xno"; then 55298 ENABLE_CDS="false" 55299 else 55300 as_fn_error $? "Invalid value for --enable-cds: $enable_cds" "$LINENO" 5 55301 fi 55302 55303 55304 55305 55306 # Check whether --enable-hotspot-gtest was given. 55307 if test "${enable_hotspot_gtest+set}" = set; then : 55308 enableval=$enable_hotspot_gtest; 55309 fi 55310 55311 55312 if test -e "${TOPDIR}/test/hotspot/gtest"; then 55313 GTEST_DIR_EXISTS="true" 55314 else 55315 GTEST_DIR_EXISTS="false" 55316 fi 55317 55318 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if Hotspot gtest unit tests should be built" >&5 55319 $as_echo_n "checking if Hotspot gtest unit tests should be built... " >&6; } 55320 if test "x$enable_hotspot_gtest" = "xyes"; then 55321 if test "x$GTEST_DIR_EXISTS" = "xtrue"; then 55322 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes, forced" >&5 55323 $as_echo "yes, forced" >&6; } 55324 BUILD_GTEST="true" 55325 else 55326 as_fn_error $? "Cannot build gtest without the test source" "$LINENO" 5 55327 fi 55328 elif test "x$enable_hotspot_gtest" = "xno"; then 55329 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no, forced" >&5 55330 $as_echo "no, forced" >&6; } 55331 BUILD_GTEST="false" 55332 elif test "x$enable_hotspot_gtest" = "x"; then 55333 if test "x$GTEST_DIR_EXISTS" = "xtrue"; then 55334 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 55335 $as_echo "yes" >&6; } 55336 BUILD_GTEST="true" 55337 else 55338 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 55339 $as_echo "no" >&6; } 55340 BUILD_GTEST="false" 55341 fi 55342 else 55343 as_fn_error $? "--enable-gtest must be either yes or no" "$LINENO" 5 55344 fi 55345 55346 55347 55348 55349 ############################################################################### 55350 # 55351 # Check dependencies for external and internal libraries. 55352 # 55353 ############################################################################### 55354 55355 # After we have toolchain, we can compile fixpath. It's needed by the lib checks. 55356 55357 # When using cygwin or msys, we need a wrapper binary that renames 55358 # /cygdrive/c/ arguments into c:/ arguments and peeks into 55359 # @files and rewrites these too! This wrapper binary is 55360 # called fixpath. 55361 FIXPATH= 55362 if test "x$OPENJDK_BUILD_OS" = xwindows; then 55363 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if fixpath can be created" >&5 55364 $as_echo_n "checking if fixpath can be created... " >&6; } 55365 FIXPATH_SRC="$TOPDIR/make/src/native/fixpath.c" 55366 FIXPATH_BIN="$CONFIGURESUPPORT_OUTPUTDIR/bin/fixpath.exe" 55367 FIXPATH_DIR="$CONFIGURESUPPORT_OUTPUTDIR/fixpath" 55368 if test "x$OPENJDK_BUILD_OS_ENV" = xwindows.cygwin; then 55369 # Important to keep the .exe suffix on Cygwin for Hotspot makefiles 55370 FIXPATH="$FIXPATH_BIN -c" 55371 elif test "x$OPENJDK_BUILD_OS_ENV" = xwindows.msys; then 55372 # Take all collected prefixes and turn them into a -m/c/foo@/c/bar@... command line 55373 # @ was chosen as separator to minimize risk of other tools messing around with it 55374 all_unique_prefixes=`echo "${all_fixpath_prefixes[@]}" \ 55375 | tr ' ' '\n' | $GREP '^/./' | $SORT | $UNIQ` 55376 fixpath_argument_list=`echo $all_unique_prefixes | tr ' ' '@'` 55377 FIXPATH="$FIXPATH_BIN -m$fixpath_argument_list" 55378 fi 55379 FIXPATH_SRC_W="$FIXPATH_SRC" 55380 FIXPATH_BIN_W="$FIXPATH_BIN" 55381 55382 unix_path="$FIXPATH_SRC_W" 55383 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 55384 windows_path=`$CYGPATH -m "$unix_path"` 55385 FIXPATH_SRC_W="$windows_path" 55386 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 55387 windows_path=`cmd //c echo $unix_path` 55388 FIXPATH_SRC_W="$windows_path" 55389 fi 55390 55391 55392 unix_path="$FIXPATH_BIN_W" 55393 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 55394 windows_path=`$CYGPATH -m "$unix_path"` 55395 FIXPATH_BIN_W="$windows_path" 55396 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 55397 windows_path=`cmd //c echo $unix_path` 55398 FIXPATH_BIN_W="$windows_path" 55399 fi 55400 55401 $RM -rf $FIXPATH_BIN $FIXPATH_DIR 55402 $MKDIR -p $FIXPATH_DIR $CONFIGURESUPPORT_OUTPUTDIR/bin 55403 cd $FIXPATH_DIR 55404 $CC $FIXPATH_SRC_W -Fe$FIXPATH_BIN_W > $FIXPATH_DIR/fixpath1.log 2>&1 55405 cd $CURDIR 55406 55407 if test ! -x $FIXPATH_BIN; then 55408 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 55409 $as_echo "no" >&6; } 55410 cat $FIXPATH_DIR/fixpath1.log 55411 as_fn_error $? "Could not create $FIXPATH_BIN" "$LINENO" 5 55412 fi 55413 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 55414 $as_echo "yes" >&6; } 55415 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if fixpath.exe works" >&5 55416 $as_echo_n "checking if fixpath.exe works... " >&6; } 55417 cd $FIXPATH_DIR 55418 $FIXPATH $CC $FIXPATH_SRC -Fe$FIXPATH_DIR/fixpath2.exe \ 55419 > $FIXPATH_DIR/fixpath2.log 2>&1 55420 cd $CURDIR 55421 if test ! -x $FIXPATH_DIR/fixpath2.exe; then 55422 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 55423 $as_echo "no" >&6; } 55424 cat $FIXPATH_DIR/fixpath2.log 55425 as_fn_error $? "fixpath did not work!" "$LINENO" 5 55426 fi 55427 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 55428 $as_echo "yes" >&6; } 55429 55430 FIXPATH_DETACH_FLAG="--detach" 55431 fi 55432 55433 55434 55435 55436 55437 55438 # Check if X11 is needed 55439 if test "x$OPENJDK_TARGET_OS" = xwindows || test "x$OPENJDK_TARGET_OS" = xmacosx; then 55440 # No X11 support on windows or macosx 55441 NEEDS_LIB_X11=false 55442 else 55443 # All other instances need X11, even if building headless only, libawt still 55444 # needs X11 headers. 55445 NEEDS_LIB_X11=true 55446 fi 55447 55448 # Check if fontconfig is needed 55449 if test "x$OPENJDK_TARGET_OS" = xwindows || test "x$OPENJDK_TARGET_OS" = xmacosx; then 55450 # No fontconfig support on windows or macosx 55451 NEEDS_LIB_FONTCONFIG=false 55452 else 55453 # All other instances need fontconfig, even if building headless only, 55454 # libawt still needs fontconfig headers. 55455 NEEDS_LIB_FONTCONFIG=true 55456 fi 55457 55458 # Check if cups is needed 55459 if test "x$OPENJDK_TARGET_OS" = xwindows; then 55460 # Windows have a separate print system 55461 NEEDS_LIB_CUPS=false 55462 else 55463 NEEDS_LIB_CUPS=true 55464 fi 55465 55466 # A custom hook may have set this already 55467 if test "x$NEEDS_LIB_FREETYPE" = "x"; then 55468 NEEDS_LIB_FREETYPE=true 55469 fi 55470 55471 # Check if alsa is needed 55472 if test "x$OPENJDK_TARGET_OS" = xlinux; then 55473 NEEDS_LIB_ALSA=true 55474 else 55475 NEEDS_LIB_ALSA=false 55476 fi 55477 55478 # Check if ffi is needed 55479 if [[ " $JVM_VARIANTS " =~ " zero " ]] ; then 55480 NEEDS_LIB_FFI=true 55481 else 55482 NEEDS_LIB_FFI=false 55483 fi 55484 55485 55486 # statically link libstdc++ before C++ ABI is stablized on Linux unless 55487 # dynamic build is configured on command line. 55488 55489 # Check whether --with-stdc++lib was given. 55490 if test "${with_stdc__lib+set}" = set; then : 55491 withval=$with_stdc__lib; 55492 if test "x$with_stdc__lib" != xdynamic && test "x$with_stdc__lib" != xstatic \ 55493 && test "x$with_stdc__lib" != xdefault; then 55494 as_fn_error $? "Bad parameter value --with-stdc++lib=$with_stdc__lib!" "$LINENO" 5 55495 fi 55496 55497 else 55498 with_stdc__lib=default 55499 55500 fi 55501 55502 55503 if test "x$OPENJDK_TARGET_OS" = xlinux; then 55504 # Test if stdc++ can be linked statically. 55505 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if static link of stdc++ is possible" >&5 55506 $as_echo_n "checking if static link of stdc++ is possible... " >&6; } 55507 STATIC_STDCXX_FLAGS="-static-libstdc++ -static-libgcc" 55508 ac_ext=cpp 55509 ac_cpp='$CXXCPP $CPPFLAGS' 55510 ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5' 55511 ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' 55512 ac_compiler_gnu=$ac_cv_cxx_compiler_gnu 55513 55514 OLD_LIBS="$LIBS" 55515 LIBS="$STATIC_STDCXX_FLAGS" 55516 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 55517 /* end confdefs.h. */ 55518 55519 int 55520 main () 55521 { 55522 return 0; 55523 ; 55524 return 0; 55525 } 55526 _ACEOF 55527 if ac_fn_cxx_try_link "$LINENO"; then : 55528 has_static_libstdcxx=yes 55529 else 55530 has_static_libstdcxx=no 55531 fi 55532 rm -f core conftest.err conftest.$ac_objext \ 55533 conftest$ac_exeext conftest.$ac_ext 55534 LIBS="$OLD_LIBS" 55535 ac_ext=cpp 55536 ac_cpp='$CXXCPP $CPPFLAGS' 55537 ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5' 55538 ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' 55539 ac_compiler_gnu=$ac_cv_cxx_compiler_gnu 55540 55541 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $has_static_libstdcxx" >&5 55542 $as_echo "$has_static_libstdcxx" >&6; } 55543 55544 if test "x$with_stdc__lib" = xstatic && test "x$has_static_libstdcxx" = xno; then 55545 as_fn_error $? "Static linking of libstdc++ was not possible!" "$LINENO" 5 55546 fi 55547 55548 # If dynamic was requested, it's available since it would fail above otherwise. 55549 # If dynamic wasn't requested, go with static unless it isn't available. 55550 { $as_echo "$as_me:${as_lineno-$LINENO}: checking how to link with libstdc++" >&5 55551 $as_echo_n "checking how to link with libstdc++... " >&6; } 55552 if test "x$with_stdc__lib" = xdynamic || test "x$has_static_libstdcxx" = xno ; then 55553 { $as_echo "$as_me:${as_lineno-$LINENO}: result: dynamic" >&5 55554 $as_echo "dynamic" >&6; } 55555 else 55556 LIBCXX="$LIBCXX $STATIC_STDCXX_FLAGS" 55557 JVM_LDFLAGS="$JVM_LDFLAGS $STATIC_STDCXX_FLAGS" 55558 # Ideally, we should test stdc++ for the BUILD toolchain separately. For now 55559 # just use the same setting as for the TARGET toolchain. 55560 OPENJDK_BUILD_JVM_LDFLAGS="$OPENJDK_BUILD_JVM_LDFLAGS $STATIC_STDCXX_FLAGS" 55561 { $as_echo "$as_me:${as_lineno-$LINENO}: result: static" >&5 55562 $as_echo "static" >&6; } 55563 fi 55564 fi 55565 55566 # libCrun is the c++ runtime-library with SunStudio (roughly the equivalent of gcc's libstdc++.so) 55567 if test "x$TOOLCHAIN_TYPE" = xsolstudio && test "x$LIBCXX" = x; then 55568 LIBCXX="${SYSROOT}/usr/lib${OPENJDK_TARGET_CPU_ISADIR}/libCrun.so.1" 55569 fi 55570 55571 55572 55573 # Setup Windows runtime dlls 55574 if test "x$OPENJDK_TARGET_OS" = "xwindows"; then 55575 55576 55577 # Check whether --with-msvcr-dll was given. 55578 if test "${with_msvcr_dll+set}" = set; then : 55579 withval=$with_msvcr_dll; 55580 fi 55581 55582 55583 if test "x$with_msvcr_dll" != x; then 55584 # If given explicitly by user, do not probe. If not present, fail directly. 55585 55586 DLL_NAME="$MSVCR_NAME" 55587 POSSIBLE_MSVC_DLL="$with_msvcr_dll" 55588 METHOD="--with-msvcr-dll" 55589 if test -n "$POSSIBLE_MSVC_DLL" -a -e "$POSSIBLE_MSVC_DLL"; then 55590 { $as_echo "$as_me:${as_lineno-$LINENO}: Found $DLL_NAME at $POSSIBLE_MSVC_DLL using $METHOD" >&5 55591 $as_echo "$as_me: Found $DLL_NAME at $POSSIBLE_MSVC_DLL using $METHOD" >&6;} 55592 55593 # Need to check if the found msvcr is correct architecture 55594 { $as_echo "$as_me:${as_lineno-$LINENO}: checking found $DLL_NAME architecture" >&5 55595 $as_echo_n "checking found $DLL_NAME architecture... " >&6; } 55596 MSVC_DLL_FILETYPE=`$FILE -b "$POSSIBLE_MSVC_DLL"` 55597 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 55598 # The MSYS 'file' command returns "PE32 executable for MS Windows (DLL) (GUI) Intel 80386 32-bit" 55599 # on x32 and "PE32+ executable for MS Windows (DLL) (GUI) Mono/.Net assembly" on x64 systems. 55600 if test "x$OPENJDK_TARGET_CPU_BITS" = x32; then 55601 CORRECT_MSVCR_ARCH="PE32 executable" 55602 else 55603 CORRECT_MSVCR_ARCH="PE32+ executable" 55604 fi 55605 else 55606 if test "x$OPENJDK_TARGET_CPU_BITS" = x32; then 55607 CORRECT_MSVCR_ARCH=386 55608 else 55609 CORRECT_MSVCR_ARCH=x86-64 55610 fi 55611 fi 55612 if $ECHO "$MSVC_DLL_FILETYPE" | $GREP "$CORRECT_MSVCR_ARCH" 2>&1 > /dev/null; then 55613 { $as_echo "$as_me:${as_lineno-$LINENO}: result: ok" >&5 55614 $as_echo "ok" >&6; } 55615 MSVC_DLL="$POSSIBLE_MSVC_DLL" 55616 55617 # Only process if variable expands to non-empty 55618 55619 if test "x$MSVC_DLL" != x; then 55620 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 55621 55622 # Input might be given as Windows format, start by converting to 55623 # unix format. 55624 path="$MSVC_DLL" 55625 new_path=`$CYGPATH -u "$path"` 55626 55627 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 55628 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 55629 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 55630 # "foo.exe" is OK but "foo" is an error. 55631 # 55632 # This test is therefore slightly more accurate than "test -f" to check for file precense. 55633 # It is also a way to make sure we got the proper file name for the real test later on. 55634 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 55635 if test "x$test_shortpath" = x; then 55636 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of MSVC_DLL, which resolves as \"$path\", is invalid." >&5 55637 $as_echo "$as_me: The path of MSVC_DLL, which resolves as \"$path\", is invalid." >&6;} 55638 as_fn_error $? "Cannot locate the the path of MSVC_DLL" "$LINENO" 5 55639 fi 55640 55641 # Call helper function which possibly converts this using DOS-style short mode. 55642 # If so, the updated path is stored in $new_path. 55643 55644 input_path="$new_path" 55645 # Check if we need to convert this using DOS-style short mode. If the path 55646 # contains just simple characters, use it. Otherwise (spaces, weird characters), 55647 # take no chances and rewrite it. 55648 # Note: m4 eats our [], so we need to use [ and ] instead. 55649 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 55650 if test "x$has_forbidden_chars" != x; then 55651 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 55652 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 55653 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 55654 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 55655 # Going to short mode and back again did indeed matter. Since short mode is 55656 # case insensitive, let's make it lowercase to improve readability. 55657 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 55658 # Now convert it back to Unix-style (cygpath) 55659 input_path=`$CYGPATH -u "$shortmode_path"` 55660 new_path="$input_path" 55661 fi 55662 fi 55663 55664 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 55665 if test "x$test_cygdrive_prefix" = x; then 55666 # As a simple fix, exclude /usr/bin since it's not a real path. 55667 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 55668 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 55669 # a path prefixed by /cygdrive for fixpath to work. 55670 new_path="$CYGWIN_ROOT_PATH$input_path" 55671 fi 55672 fi 55673 55674 55675 if test "x$path" != "x$new_path"; then 55676 MSVC_DLL="$new_path" 55677 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting MSVC_DLL to \"$new_path\"" >&5 55678 $as_echo "$as_me: Rewriting MSVC_DLL to \"$new_path\"" >&6;} 55679 fi 55680 55681 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 55682 55683 path="$MSVC_DLL" 55684 has_colon=`$ECHO $path | $GREP ^.:` 55685 new_path="$path" 55686 if test "x$has_colon" = x; then 55687 # Not in mixed or Windows style, start by that. 55688 new_path=`cmd //c echo $path` 55689 fi 55690 55691 55692 input_path="$new_path" 55693 # Check if we need to convert this using DOS-style short mode. If the path 55694 # contains just simple characters, use it. Otherwise (spaces, weird characters), 55695 # take no chances and rewrite it. 55696 # Note: m4 eats our [], so we need to use [ and ] instead. 55697 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 55698 if test "x$has_forbidden_chars" != x; then 55699 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 55700 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 55701 fi 55702 55703 55704 windows_path="$new_path" 55705 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 55706 unix_path=`$CYGPATH -u "$windows_path"` 55707 new_path="$unix_path" 55708 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 55709 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 55710 new_path="$unix_path" 55711 fi 55712 55713 if test "x$path" != "x$new_path"; then 55714 MSVC_DLL="$new_path" 55715 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting MSVC_DLL to \"$new_path\"" >&5 55716 $as_echo "$as_me: Rewriting MSVC_DLL to \"$new_path\"" >&6;} 55717 fi 55718 55719 # Save the first 10 bytes of this path to the storage, so fixpath can work. 55720 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 55721 55722 else 55723 # We're on a unix platform. Hooray! :) 55724 path="$MSVC_DLL" 55725 has_space=`$ECHO "$path" | $GREP " "` 55726 if test "x$has_space" != x; then 55727 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of MSVC_DLL, which resolves as \"$path\", is invalid." >&5 55728 $as_echo "$as_me: The path of MSVC_DLL, which resolves as \"$path\", is invalid." >&6;} 55729 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 55730 fi 55731 55732 # Use eval to expand a potential ~ 55733 eval path="$path" 55734 if test ! -f "$path" && test ! -d "$path"; then 55735 as_fn_error $? "The path of MSVC_DLL, which resolves as \"$path\", is not found." "$LINENO" 5 55736 fi 55737 55738 if test -d "$path"; then 55739 MSVC_DLL="`cd "$path"; $THEPWDCMD -L`" 55740 else 55741 dir="`$DIRNAME "$path"`" 55742 base="`$BASENAME "$path"`" 55743 MSVC_DLL="`cd "$dir"; $THEPWDCMD -L`/$base" 55744 fi 55745 fi 55746 fi 55747 55748 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $DLL_NAME" >&5 55749 $as_echo_n "checking for $DLL_NAME... " >&6; } 55750 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MSVC_DLL" >&5 55751 $as_echo "$MSVC_DLL" >&6; } 55752 else 55753 { $as_echo "$as_me:${as_lineno-$LINENO}: result: incorrect, ignoring" >&5 55754 $as_echo "incorrect, ignoring" >&6; } 55755 { $as_echo "$as_me:${as_lineno-$LINENO}: The file type of the located $DLL_NAME is $MSVC_DLL_FILETYPE" >&5 55756 $as_echo "$as_me: The file type of the located $DLL_NAME is $MSVC_DLL_FILETYPE" >&6;} 55757 fi 55758 fi 55759 55760 if test "x$MSVC_DLL" = x; then 55761 as_fn_error $? "Could not find a proper $MSVCR_NAME as specified by --with-msvcr-dll" "$LINENO" 5 55762 fi 55763 MSVCR_DLL="$MSVC_DLL" 55764 elif test "x$DEVKIT_MSVCR_DLL" != x; then 55765 55766 DLL_NAME="$MSVCR_NAME" 55767 POSSIBLE_MSVC_DLL="$DEVKIT_MSVCR_DLL" 55768 METHOD="devkit" 55769 if test -n "$POSSIBLE_MSVC_DLL" -a -e "$POSSIBLE_MSVC_DLL"; then 55770 { $as_echo "$as_me:${as_lineno-$LINENO}: Found $DLL_NAME at $POSSIBLE_MSVC_DLL using $METHOD" >&5 55771 $as_echo "$as_me: Found $DLL_NAME at $POSSIBLE_MSVC_DLL using $METHOD" >&6;} 55772 55773 # Need to check if the found msvcr is correct architecture 55774 { $as_echo "$as_me:${as_lineno-$LINENO}: checking found $DLL_NAME architecture" >&5 55775 $as_echo_n "checking found $DLL_NAME architecture... " >&6; } 55776 MSVC_DLL_FILETYPE=`$FILE -b "$POSSIBLE_MSVC_DLL"` 55777 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 55778 # The MSYS 'file' command returns "PE32 executable for MS Windows (DLL) (GUI) Intel 80386 32-bit" 55779 # on x32 and "PE32+ executable for MS Windows (DLL) (GUI) Mono/.Net assembly" on x64 systems. 55780 if test "x$OPENJDK_TARGET_CPU_BITS" = x32; then 55781 CORRECT_MSVCR_ARCH="PE32 executable" 55782 else 55783 CORRECT_MSVCR_ARCH="PE32+ executable" 55784 fi 55785 else 55786 if test "x$OPENJDK_TARGET_CPU_BITS" = x32; then 55787 CORRECT_MSVCR_ARCH=386 55788 else 55789 CORRECT_MSVCR_ARCH=x86-64 55790 fi 55791 fi 55792 if $ECHO "$MSVC_DLL_FILETYPE" | $GREP "$CORRECT_MSVCR_ARCH" 2>&1 > /dev/null; then 55793 { $as_echo "$as_me:${as_lineno-$LINENO}: result: ok" >&5 55794 $as_echo "ok" >&6; } 55795 MSVC_DLL="$POSSIBLE_MSVC_DLL" 55796 55797 # Only process if variable expands to non-empty 55798 55799 if test "x$MSVC_DLL" != x; then 55800 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 55801 55802 # Input might be given as Windows format, start by converting to 55803 # unix format. 55804 path="$MSVC_DLL" 55805 new_path=`$CYGPATH -u "$path"` 55806 55807 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 55808 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 55809 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 55810 # "foo.exe" is OK but "foo" is an error. 55811 # 55812 # This test is therefore slightly more accurate than "test -f" to check for file precense. 55813 # It is also a way to make sure we got the proper file name for the real test later on. 55814 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 55815 if test "x$test_shortpath" = x; then 55816 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of MSVC_DLL, which resolves as \"$path\", is invalid." >&5 55817 $as_echo "$as_me: The path of MSVC_DLL, which resolves as \"$path\", is invalid." >&6;} 55818 as_fn_error $? "Cannot locate the the path of MSVC_DLL" "$LINENO" 5 55819 fi 55820 55821 # Call helper function which possibly converts this using DOS-style short mode. 55822 # If so, the updated path is stored in $new_path. 55823 55824 input_path="$new_path" 55825 # Check if we need to convert this using DOS-style short mode. If the path 55826 # contains just simple characters, use it. Otherwise (spaces, weird characters), 55827 # take no chances and rewrite it. 55828 # Note: m4 eats our [], so we need to use [ and ] instead. 55829 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 55830 if test "x$has_forbidden_chars" != x; then 55831 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 55832 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 55833 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 55834 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 55835 # Going to short mode and back again did indeed matter. Since short mode is 55836 # case insensitive, let's make it lowercase to improve readability. 55837 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 55838 # Now convert it back to Unix-style (cygpath) 55839 input_path=`$CYGPATH -u "$shortmode_path"` 55840 new_path="$input_path" 55841 fi 55842 fi 55843 55844 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 55845 if test "x$test_cygdrive_prefix" = x; then 55846 # As a simple fix, exclude /usr/bin since it's not a real path. 55847 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 55848 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 55849 # a path prefixed by /cygdrive for fixpath to work. 55850 new_path="$CYGWIN_ROOT_PATH$input_path" 55851 fi 55852 fi 55853 55854 55855 if test "x$path" != "x$new_path"; then 55856 MSVC_DLL="$new_path" 55857 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting MSVC_DLL to \"$new_path\"" >&5 55858 $as_echo "$as_me: Rewriting MSVC_DLL to \"$new_path\"" >&6;} 55859 fi 55860 55861 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 55862 55863 path="$MSVC_DLL" 55864 has_colon=`$ECHO $path | $GREP ^.:` 55865 new_path="$path" 55866 if test "x$has_colon" = x; then 55867 # Not in mixed or Windows style, start by that. 55868 new_path=`cmd //c echo $path` 55869 fi 55870 55871 55872 input_path="$new_path" 55873 # Check if we need to convert this using DOS-style short mode. If the path 55874 # contains just simple characters, use it. Otherwise (spaces, weird characters), 55875 # take no chances and rewrite it. 55876 # Note: m4 eats our [], so we need to use [ and ] instead. 55877 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 55878 if test "x$has_forbidden_chars" != x; then 55879 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 55880 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 55881 fi 55882 55883 55884 windows_path="$new_path" 55885 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 55886 unix_path=`$CYGPATH -u "$windows_path"` 55887 new_path="$unix_path" 55888 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 55889 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 55890 new_path="$unix_path" 55891 fi 55892 55893 if test "x$path" != "x$new_path"; then 55894 MSVC_DLL="$new_path" 55895 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting MSVC_DLL to \"$new_path\"" >&5 55896 $as_echo "$as_me: Rewriting MSVC_DLL to \"$new_path\"" >&6;} 55897 fi 55898 55899 # Save the first 10 bytes of this path to the storage, so fixpath can work. 55900 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 55901 55902 else 55903 # We're on a unix platform. Hooray! :) 55904 path="$MSVC_DLL" 55905 has_space=`$ECHO "$path" | $GREP " "` 55906 if test "x$has_space" != x; then 55907 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of MSVC_DLL, which resolves as \"$path\", is invalid." >&5 55908 $as_echo "$as_me: The path of MSVC_DLL, which resolves as \"$path\", is invalid." >&6;} 55909 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 55910 fi 55911 55912 # Use eval to expand a potential ~ 55913 eval path="$path" 55914 if test ! -f "$path" && test ! -d "$path"; then 55915 as_fn_error $? "The path of MSVC_DLL, which resolves as \"$path\", is not found." "$LINENO" 5 55916 fi 55917 55918 if test -d "$path"; then 55919 MSVC_DLL="`cd "$path"; $THEPWDCMD -L`" 55920 else 55921 dir="`$DIRNAME "$path"`" 55922 base="`$BASENAME "$path"`" 55923 MSVC_DLL="`cd "$dir"; $THEPWDCMD -L`/$base" 55924 fi 55925 fi 55926 fi 55927 55928 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $DLL_NAME" >&5 55929 $as_echo_n "checking for $DLL_NAME... " >&6; } 55930 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MSVC_DLL" >&5 55931 $as_echo "$MSVC_DLL" >&6; } 55932 else 55933 { $as_echo "$as_me:${as_lineno-$LINENO}: result: incorrect, ignoring" >&5 55934 $as_echo "incorrect, ignoring" >&6; } 55935 { $as_echo "$as_me:${as_lineno-$LINENO}: The file type of the located $DLL_NAME is $MSVC_DLL_FILETYPE" >&5 55936 $as_echo "$as_me: The file type of the located $DLL_NAME is $MSVC_DLL_FILETYPE" >&6;} 55937 fi 55938 fi 55939 55940 if test "x$MSVC_DLL" = x; then 55941 as_fn_error $? "Could not find a proper $MSVCR_NAME as specified by devkit" "$LINENO" 5 55942 fi 55943 MSVCR_DLL="$MSVC_DLL" 55944 else 55945 55946 DLL_NAME="${MSVCR_NAME}" 55947 MSVC_DLL= 55948 55949 if test "x$MSVC_DLL" = x; then 55950 # Probe: Using well-known location from Visual Studio 10.0 55951 if test "x$VCINSTALLDIR" != x; then 55952 CYGWIN_VC_INSTALL_DIR="$VCINSTALLDIR" 55953 55954 windows_path="$CYGWIN_VC_INSTALL_DIR" 55955 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 55956 unix_path=`$CYGPATH -u "$windows_path"` 55957 CYGWIN_VC_INSTALL_DIR="$unix_path" 55958 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 55959 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 55960 CYGWIN_VC_INSTALL_DIR="$unix_path" 55961 fi 55962 55963 if test "x$OPENJDK_TARGET_CPU_BITS" = x64; then 55964 POSSIBLE_MSVC_DLL="$CYGWIN_VC_INSTALL_DIR/redist/x64/Microsoft.VC${VS_VERSION_INTERNAL}.CRT/$DLL_NAME" 55965 else 55966 POSSIBLE_MSVC_DLL="$CYGWIN_VC_INSTALL_DIR/redist/x86/Microsoft.VC${VS_VERSION_INTERNAL}.CRT/$DLL_NAME" 55967 fi 55968 $ECHO "POSSIBLE_MSVC_DLL $POSSIBLEMSVC_DLL" 55969 55970 DLL_NAME="$DLL_NAME" 55971 POSSIBLE_MSVC_DLL="$POSSIBLE_MSVC_DLL" 55972 METHOD="well-known location in VCINSTALLDIR" 55973 if test -n "$POSSIBLE_MSVC_DLL" -a -e "$POSSIBLE_MSVC_DLL"; then 55974 { $as_echo "$as_me:${as_lineno-$LINENO}: Found $DLL_NAME at $POSSIBLE_MSVC_DLL using $METHOD" >&5 55975 $as_echo "$as_me: Found $DLL_NAME at $POSSIBLE_MSVC_DLL using $METHOD" >&6;} 55976 55977 # Need to check if the found msvcr is correct architecture 55978 { $as_echo "$as_me:${as_lineno-$LINENO}: checking found $DLL_NAME architecture" >&5 55979 $as_echo_n "checking found $DLL_NAME architecture... " >&6; } 55980 MSVC_DLL_FILETYPE=`$FILE -b "$POSSIBLE_MSVC_DLL"` 55981 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 55982 # The MSYS 'file' command returns "PE32 executable for MS Windows (DLL) (GUI) Intel 80386 32-bit" 55983 # on x32 and "PE32+ executable for MS Windows (DLL) (GUI) Mono/.Net assembly" on x64 systems. 55984 if test "x$OPENJDK_TARGET_CPU_BITS" = x32; then 55985 CORRECT_MSVCR_ARCH="PE32 executable" 55986 else 55987 CORRECT_MSVCR_ARCH="PE32+ executable" 55988 fi 55989 else 55990 if test "x$OPENJDK_TARGET_CPU_BITS" = x32; then 55991 CORRECT_MSVCR_ARCH=386 55992 else 55993 CORRECT_MSVCR_ARCH=x86-64 55994 fi 55995 fi 55996 if $ECHO "$MSVC_DLL_FILETYPE" | $GREP "$CORRECT_MSVCR_ARCH" 2>&1 > /dev/null; then 55997 { $as_echo "$as_me:${as_lineno-$LINENO}: result: ok" >&5 55998 $as_echo "ok" >&6; } 55999 MSVC_DLL="$POSSIBLE_MSVC_DLL" 56000 56001 # Only process if variable expands to non-empty 56002 56003 if test "x$MSVC_DLL" != x; then 56004 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 56005 56006 # Input might be given as Windows format, start by converting to 56007 # unix format. 56008 path="$MSVC_DLL" 56009 new_path=`$CYGPATH -u "$path"` 56010 56011 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 56012 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 56013 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 56014 # "foo.exe" is OK but "foo" is an error. 56015 # 56016 # This test is therefore slightly more accurate than "test -f" to check for file precense. 56017 # It is also a way to make sure we got the proper file name for the real test later on. 56018 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 56019 if test "x$test_shortpath" = x; then 56020 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of MSVC_DLL, which resolves as \"$path\", is invalid." >&5 56021 $as_echo "$as_me: The path of MSVC_DLL, which resolves as \"$path\", is invalid." >&6;} 56022 as_fn_error $? "Cannot locate the the path of MSVC_DLL" "$LINENO" 5 56023 fi 56024 56025 # Call helper function which possibly converts this using DOS-style short mode. 56026 # If so, the updated path is stored in $new_path. 56027 56028 input_path="$new_path" 56029 # Check if we need to convert this using DOS-style short mode. If the path 56030 # contains just simple characters, use it. Otherwise (spaces, weird characters), 56031 # take no chances and rewrite it. 56032 # Note: m4 eats our [], so we need to use [ and ] instead. 56033 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 56034 if test "x$has_forbidden_chars" != x; then 56035 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 56036 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 56037 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 56038 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 56039 # Going to short mode and back again did indeed matter. Since short mode is 56040 # case insensitive, let's make it lowercase to improve readability. 56041 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 56042 # Now convert it back to Unix-style (cygpath) 56043 input_path=`$CYGPATH -u "$shortmode_path"` 56044 new_path="$input_path" 56045 fi 56046 fi 56047 56048 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 56049 if test "x$test_cygdrive_prefix" = x; then 56050 # As a simple fix, exclude /usr/bin since it's not a real path. 56051 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 56052 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 56053 # a path prefixed by /cygdrive for fixpath to work. 56054 new_path="$CYGWIN_ROOT_PATH$input_path" 56055 fi 56056 fi 56057 56058 56059 if test "x$path" != "x$new_path"; then 56060 MSVC_DLL="$new_path" 56061 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting MSVC_DLL to \"$new_path\"" >&5 56062 $as_echo "$as_me: Rewriting MSVC_DLL to \"$new_path\"" >&6;} 56063 fi 56064 56065 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 56066 56067 path="$MSVC_DLL" 56068 has_colon=`$ECHO $path | $GREP ^.:` 56069 new_path="$path" 56070 if test "x$has_colon" = x; then 56071 # Not in mixed or Windows style, start by that. 56072 new_path=`cmd //c echo $path` 56073 fi 56074 56075 56076 input_path="$new_path" 56077 # Check if we need to convert this using DOS-style short mode. If the path 56078 # contains just simple characters, use it. Otherwise (spaces, weird characters), 56079 # take no chances and rewrite it. 56080 # Note: m4 eats our [], so we need to use [ and ] instead. 56081 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 56082 if test "x$has_forbidden_chars" != x; then 56083 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 56084 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 56085 fi 56086 56087 56088 windows_path="$new_path" 56089 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 56090 unix_path=`$CYGPATH -u "$windows_path"` 56091 new_path="$unix_path" 56092 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 56093 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 56094 new_path="$unix_path" 56095 fi 56096 56097 if test "x$path" != "x$new_path"; then 56098 MSVC_DLL="$new_path" 56099 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting MSVC_DLL to \"$new_path\"" >&5 56100 $as_echo "$as_me: Rewriting MSVC_DLL to \"$new_path\"" >&6;} 56101 fi 56102 56103 # Save the first 10 bytes of this path to the storage, so fixpath can work. 56104 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 56105 56106 else 56107 # We're on a unix platform. Hooray! :) 56108 path="$MSVC_DLL" 56109 has_space=`$ECHO "$path" | $GREP " "` 56110 if test "x$has_space" != x; then 56111 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of MSVC_DLL, which resolves as \"$path\", is invalid." >&5 56112 $as_echo "$as_me: The path of MSVC_DLL, which resolves as \"$path\", is invalid." >&6;} 56113 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 56114 fi 56115 56116 # Use eval to expand a potential ~ 56117 eval path="$path" 56118 if test ! -f "$path" && test ! -d "$path"; then 56119 as_fn_error $? "The path of MSVC_DLL, which resolves as \"$path\", is not found." "$LINENO" 5 56120 fi 56121 56122 if test -d "$path"; then 56123 MSVC_DLL="`cd "$path"; $THEPWDCMD -L`" 56124 else 56125 dir="`$DIRNAME "$path"`" 56126 base="`$BASENAME "$path"`" 56127 MSVC_DLL="`cd "$dir"; $THEPWDCMD -L`/$base" 56128 fi 56129 fi 56130 fi 56131 56132 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $DLL_NAME" >&5 56133 $as_echo_n "checking for $DLL_NAME... " >&6; } 56134 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MSVC_DLL" >&5 56135 $as_echo "$MSVC_DLL" >&6; } 56136 else 56137 { $as_echo "$as_me:${as_lineno-$LINENO}: result: incorrect, ignoring" >&5 56138 $as_echo "incorrect, ignoring" >&6; } 56139 { $as_echo "$as_me:${as_lineno-$LINENO}: The file type of the located $DLL_NAME is $MSVC_DLL_FILETYPE" >&5 56140 $as_echo "$as_me: The file type of the located $DLL_NAME is $MSVC_DLL_FILETYPE" >&6;} 56141 fi 56142 fi 56143 56144 fi 56145 fi 56146 56147 if test "x$MSVC_DLL" = x; then 56148 # Probe: Check in the Boot JDK directory. 56149 POSSIBLE_MSVC_DLL="$BOOT_JDK/bin/$DLL_NAME" 56150 56151 DLL_NAME="$DLL_NAME" 56152 POSSIBLE_MSVC_DLL="$POSSIBLE_MSVC_DLL" 56153 METHOD="well-known location in Boot JDK" 56154 if test -n "$POSSIBLE_MSVC_DLL" -a -e "$POSSIBLE_MSVC_DLL"; then 56155 { $as_echo "$as_me:${as_lineno-$LINENO}: Found $DLL_NAME at $POSSIBLE_MSVC_DLL using $METHOD" >&5 56156 $as_echo "$as_me: Found $DLL_NAME at $POSSIBLE_MSVC_DLL using $METHOD" >&6;} 56157 56158 # Need to check if the found msvcr is correct architecture 56159 { $as_echo "$as_me:${as_lineno-$LINENO}: checking found $DLL_NAME architecture" >&5 56160 $as_echo_n "checking found $DLL_NAME architecture... " >&6; } 56161 MSVC_DLL_FILETYPE=`$FILE -b "$POSSIBLE_MSVC_DLL"` 56162 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 56163 # The MSYS 'file' command returns "PE32 executable for MS Windows (DLL) (GUI) Intel 80386 32-bit" 56164 # on x32 and "PE32+ executable for MS Windows (DLL) (GUI) Mono/.Net assembly" on x64 systems. 56165 if test "x$OPENJDK_TARGET_CPU_BITS" = x32; then 56166 CORRECT_MSVCR_ARCH="PE32 executable" 56167 else 56168 CORRECT_MSVCR_ARCH="PE32+ executable" 56169 fi 56170 else 56171 if test "x$OPENJDK_TARGET_CPU_BITS" = x32; then 56172 CORRECT_MSVCR_ARCH=386 56173 else 56174 CORRECT_MSVCR_ARCH=x86-64 56175 fi 56176 fi 56177 if $ECHO "$MSVC_DLL_FILETYPE" | $GREP "$CORRECT_MSVCR_ARCH" 2>&1 > /dev/null; then 56178 { $as_echo "$as_me:${as_lineno-$LINENO}: result: ok" >&5 56179 $as_echo "ok" >&6; } 56180 MSVC_DLL="$POSSIBLE_MSVC_DLL" 56181 56182 # Only process if variable expands to non-empty 56183 56184 if test "x$MSVC_DLL" != x; then 56185 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 56186 56187 # Input might be given as Windows format, start by converting to 56188 # unix format. 56189 path="$MSVC_DLL" 56190 new_path=`$CYGPATH -u "$path"` 56191 56192 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 56193 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 56194 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 56195 # "foo.exe" is OK but "foo" is an error. 56196 # 56197 # This test is therefore slightly more accurate than "test -f" to check for file precense. 56198 # It is also a way to make sure we got the proper file name for the real test later on. 56199 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 56200 if test "x$test_shortpath" = x; then 56201 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of MSVC_DLL, which resolves as \"$path\", is invalid." >&5 56202 $as_echo "$as_me: The path of MSVC_DLL, which resolves as \"$path\", is invalid." >&6;} 56203 as_fn_error $? "Cannot locate the the path of MSVC_DLL" "$LINENO" 5 56204 fi 56205 56206 # Call helper function which possibly converts this using DOS-style short mode. 56207 # If so, the updated path is stored in $new_path. 56208 56209 input_path="$new_path" 56210 # Check if we need to convert this using DOS-style short mode. If the path 56211 # contains just simple characters, use it. Otherwise (spaces, weird characters), 56212 # take no chances and rewrite it. 56213 # Note: m4 eats our [], so we need to use [ and ] instead. 56214 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 56215 if test "x$has_forbidden_chars" != x; then 56216 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 56217 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 56218 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 56219 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 56220 # Going to short mode and back again did indeed matter. Since short mode is 56221 # case insensitive, let's make it lowercase to improve readability. 56222 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 56223 # Now convert it back to Unix-style (cygpath) 56224 input_path=`$CYGPATH -u "$shortmode_path"` 56225 new_path="$input_path" 56226 fi 56227 fi 56228 56229 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 56230 if test "x$test_cygdrive_prefix" = x; then 56231 # As a simple fix, exclude /usr/bin since it's not a real path. 56232 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 56233 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 56234 # a path prefixed by /cygdrive for fixpath to work. 56235 new_path="$CYGWIN_ROOT_PATH$input_path" 56236 fi 56237 fi 56238 56239 56240 if test "x$path" != "x$new_path"; then 56241 MSVC_DLL="$new_path" 56242 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting MSVC_DLL to \"$new_path\"" >&5 56243 $as_echo "$as_me: Rewriting MSVC_DLL to \"$new_path\"" >&6;} 56244 fi 56245 56246 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 56247 56248 path="$MSVC_DLL" 56249 has_colon=`$ECHO $path | $GREP ^.:` 56250 new_path="$path" 56251 if test "x$has_colon" = x; then 56252 # Not in mixed or Windows style, start by that. 56253 new_path=`cmd //c echo $path` 56254 fi 56255 56256 56257 input_path="$new_path" 56258 # Check if we need to convert this using DOS-style short mode. If the path 56259 # contains just simple characters, use it. Otherwise (spaces, weird characters), 56260 # take no chances and rewrite it. 56261 # Note: m4 eats our [], so we need to use [ and ] instead. 56262 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 56263 if test "x$has_forbidden_chars" != x; then 56264 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 56265 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 56266 fi 56267 56268 56269 windows_path="$new_path" 56270 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 56271 unix_path=`$CYGPATH -u "$windows_path"` 56272 new_path="$unix_path" 56273 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 56274 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 56275 new_path="$unix_path" 56276 fi 56277 56278 if test "x$path" != "x$new_path"; then 56279 MSVC_DLL="$new_path" 56280 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting MSVC_DLL to \"$new_path\"" >&5 56281 $as_echo "$as_me: Rewriting MSVC_DLL to \"$new_path\"" >&6;} 56282 fi 56283 56284 # Save the first 10 bytes of this path to the storage, so fixpath can work. 56285 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 56286 56287 else 56288 # We're on a unix platform. Hooray! :) 56289 path="$MSVC_DLL" 56290 has_space=`$ECHO "$path" | $GREP " "` 56291 if test "x$has_space" != x; then 56292 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of MSVC_DLL, which resolves as \"$path\", is invalid." >&5 56293 $as_echo "$as_me: The path of MSVC_DLL, which resolves as \"$path\", is invalid." >&6;} 56294 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 56295 fi 56296 56297 # Use eval to expand a potential ~ 56298 eval path="$path" 56299 if test ! -f "$path" && test ! -d "$path"; then 56300 as_fn_error $? "The path of MSVC_DLL, which resolves as \"$path\", is not found." "$LINENO" 5 56301 fi 56302 56303 if test -d "$path"; then 56304 MSVC_DLL="`cd "$path"; $THEPWDCMD -L`" 56305 else 56306 dir="`$DIRNAME "$path"`" 56307 base="`$BASENAME "$path"`" 56308 MSVC_DLL="`cd "$dir"; $THEPWDCMD -L`/$base" 56309 fi 56310 fi 56311 fi 56312 56313 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $DLL_NAME" >&5 56314 $as_echo_n "checking for $DLL_NAME... " >&6; } 56315 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MSVC_DLL" >&5 56316 $as_echo "$MSVC_DLL" >&6; } 56317 else 56318 { $as_echo "$as_me:${as_lineno-$LINENO}: result: incorrect, ignoring" >&5 56319 $as_echo "incorrect, ignoring" >&6; } 56320 { $as_echo "$as_me:${as_lineno-$LINENO}: The file type of the located $DLL_NAME is $MSVC_DLL_FILETYPE" >&5 56321 $as_echo "$as_me: The file type of the located $DLL_NAME is $MSVC_DLL_FILETYPE" >&6;} 56322 fi 56323 fi 56324 56325 fi 56326 56327 if test "x$MSVC_DLL" = x; then 56328 # Probe: Look in the Windows system32 directory 56329 CYGWIN_SYSTEMROOT="$SYSTEMROOT" 56330 56331 windows_path="$CYGWIN_SYSTEMROOT" 56332 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 56333 unix_path=`$CYGPATH -u "$windows_path"` 56334 CYGWIN_SYSTEMROOT="$unix_path" 56335 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 56336 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 56337 CYGWIN_SYSTEMROOT="$unix_path" 56338 fi 56339 56340 POSSIBLE_MSVC_DLL="$CYGWIN_SYSTEMROOT/system32/$DLL_NAME" 56341 56342 DLL_NAME="$DLL_NAME" 56343 POSSIBLE_MSVC_DLL="$POSSIBLE_MSVC_DLL" 56344 METHOD="well-known location in SYSTEMROOT" 56345 if test -n "$POSSIBLE_MSVC_DLL" -a -e "$POSSIBLE_MSVC_DLL"; then 56346 { $as_echo "$as_me:${as_lineno-$LINENO}: Found $DLL_NAME at $POSSIBLE_MSVC_DLL using $METHOD" >&5 56347 $as_echo "$as_me: Found $DLL_NAME at $POSSIBLE_MSVC_DLL using $METHOD" >&6;} 56348 56349 # Need to check if the found msvcr is correct architecture 56350 { $as_echo "$as_me:${as_lineno-$LINENO}: checking found $DLL_NAME architecture" >&5 56351 $as_echo_n "checking found $DLL_NAME architecture... " >&6; } 56352 MSVC_DLL_FILETYPE=`$FILE -b "$POSSIBLE_MSVC_DLL"` 56353 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 56354 # The MSYS 'file' command returns "PE32 executable for MS Windows (DLL) (GUI) Intel 80386 32-bit" 56355 # on x32 and "PE32+ executable for MS Windows (DLL) (GUI) Mono/.Net assembly" on x64 systems. 56356 if test "x$OPENJDK_TARGET_CPU_BITS" = x32; then 56357 CORRECT_MSVCR_ARCH="PE32 executable" 56358 else 56359 CORRECT_MSVCR_ARCH="PE32+ executable" 56360 fi 56361 else 56362 if test "x$OPENJDK_TARGET_CPU_BITS" = x32; then 56363 CORRECT_MSVCR_ARCH=386 56364 else 56365 CORRECT_MSVCR_ARCH=x86-64 56366 fi 56367 fi 56368 if $ECHO "$MSVC_DLL_FILETYPE" | $GREP "$CORRECT_MSVCR_ARCH" 2>&1 > /dev/null; then 56369 { $as_echo "$as_me:${as_lineno-$LINENO}: result: ok" >&5 56370 $as_echo "ok" >&6; } 56371 MSVC_DLL="$POSSIBLE_MSVC_DLL" 56372 56373 # Only process if variable expands to non-empty 56374 56375 if test "x$MSVC_DLL" != x; then 56376 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 56377 56378 # Input might be given as Windows format, start by converting to 56379 # unix format. 56380 path="$MSVC_DLL" 56381 new_path=`$CYGPATH -u "$path"` 56382 56383 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 56384 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 56385 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 56386 # "foo.exe" is OK but "foo" is an error. 56387 # 56388 # This test is therefore slightly more accurate than "test -f" to check for file precense. 56389 # It is also a way to make sure we got the proper file name for the real test later on. 56390 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 56391 if test "x$test_shortpath" = x; then 56392 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of MSVC_DLL, which resolves as \"$path\", is invalid." >&5 56393 $as_echo "$as_me: The path of MSVC_DLL, which resolves as \"$path\", is invalid." >&6;} 56394 as_fn_error $? "Cannot locate the the path of MSVC_DLL" "$LINENO" 5 56395 fi 56396 56397 # Call helper function which possibly converts this using DOS-style short mode. 56398 # If so, the updated path is stored in $new_path. 56399 56400 input_path="$new_path" 56401 # Check if we need to convert this using DOS-style short mode. If the path 56402 # contains just simple characters, use it. Otherwise (spaces, weird characters), 56403 # take no chances and rewrite it. 56404 # Note: m4 eats our [], so we need to use [ and ] instead. 56405 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 56406 if test "x$has_forbidden_chars" != x; then 56407 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 56408 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 56409 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 56410 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 56411 # Going to short mode and back again did indeed matter. Since short mode is 56412 # case insensitive, let's make it lowercase to improve readability. 56413 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 56414 # Now convert it back to Unix-style (cygpath) 56415 input_path=`$CYGPATH -u "$shortmode_path"` 56416 new_path="$input_path" 56417 fi 56418 fi 56419 56420 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 56421 if test "x$test_cygdrive_prefix" = x; then 56422 # As a simple fix, exclude /usr/bin since it's not a real path. 56423 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 56424 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 56425 # a path prefixed by /cygdrive for fixpath to work. 56426 new_path="$CYGWIN_ROOT_PATH$input_path" 56427 fi 56428 fi 56429 56430 56431 if test "x$path" != "x$new_path"; then 56432 MSVC_DLL="$new_path" 56433 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting MSVC_DLL to \"$new_path\"" >&5 56434 $as_echo "$as_me: Rewriting MSVC_DLL to \"$new_path\"" >&6;} 56435 fi 56436 56437 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 56438 56439 path="$MSVC_DLL" 56440 has_colon=`$ECHO $path | $GREP ^.:` 56441 new_path="$path" 56442 if test "x$has_colon" = x; then 56443 # Not in mixed or Windows style, start by that. 56444 new_path=`cmd //c echo $path` 56445 fi 56446 56447 56448 input_path="$new_path" 56449 # Check if we need to convert this using DOS-style short mode. If the path 56450 # contains just simple characters, use it. Otherwise (spaces, weird characters), 56451 # take no chances and rewrite it. 56452 # Note: m4 eats our [], so we need to use [ and ] instead. 56453 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 56454 if test "x$has_forbidden_chars" != x; then 56455 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 56456 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 56457 fi 56458 56459 56460 windows_path="$new_path" 56461 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 56462 unix_path=`$CYGPATH -u "$windows_path"` 56463 new_path="$unix_path" 56464 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 56465 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 56466 new_path="$unix_path" 56467 fi 56468 56469 if test "x$path" != "x$new_path"; then 56470 MSVC_DLL="$new_path" 56471 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting MSVC_DLL to \"$new_path\"" >&5 56472 $as_echo "$as_me: Rewriting MSVC_DLL to \"$new_path\"" >&6;} 56473 fi 56474 56475 # Save the first 10 bytes of this path to the storage, so fixpath can work. 56476 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 56477 56478 else 56479 # We're on a unix platform. Hooray! :) 56480 path="$MSVC_DLL" 56481 has_space=`$ECHO "$path" | $GREP " "` 56482 if test "x$has_space" != x; then 56483 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of MSVC_DLL, which resolves as \"$path\", is invalid." >&5 56484 $as_echo "$as_me: The path of MSVC_DLL, which resolves as \"$path\", is invalid." >&6;} 56485 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 56486 fi 56487 56488 # Use eval to expand a potential ~ 56489 eval path="$path" 56490 if test ! -f "$path" && test ! -d "$path"; then 56491 as_fn_error $? "The path of MSVC_DLL, which resolves as \"$path\", is not found." "$LINENO" 5 56492 fi 56493 56494 if test -d "$path"; then 56495 MSVC_DLL="`cd "$path"; $THEPWDCMD -L`" 56496 else 56497 dir="`$DIRNAME "$path"`" 56498 base="`$BASENAME "$path"`" 56499 MSVC_DLL="`cd "$dir"; $THEPWDCMD -L`/$base" 56500 fi 56501 fi 56502 fi 56503 56504 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $DLL_NAME" >&5 56505 $as_echo_n "checking for $DLL_NAME... " >&6; } 56506 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MSVC_DLL" >&5 56507 $as_echo "$MSVC_DLL" >&6; } 56508 else 56509 { $as_echo "$as_me:${as_lineno-$LINENO}: result: incorrect, ignoring" >&5 56510 $as_echo "incorrect, ignoring" >&6; } 56511 { $as_echo "$as_me:${as_lineno-$LINENO}: The file type of the located $DLL_NAME is $MSVC_DLL_FILETYPE" >&5 56512 $as_echo "$as_me: The file type of the located $DLL_NAME is $MSVC_DLL_FILETYPE" >&6;} 56513 fi 56514 fi 56515 56516 fi 56517 56518 if test "x$MSVC_DLL" = x; then 56519 # Probe: If Visual Studio Express is installed, there is usually one with the debugger 56520 if test "x$VS100COMNTOOLS" != x; then 56521 CYGWIN_VS_TOOLS_DIR="$VS100COMNTOOLS/.." 56522 56523 windows_path="$CYGWIN_VS_TOOLS_DIR" 56524 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 56525 unix_path=`$CYGPATH -u "$windows_path"` 56526 CYGWIN_VS_TOOLS_DIR="$unix_path" 56527 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 56528 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 56529 CYGWIN_VS_TOOLS_DIR="$unix_path" 56530 fi 56531 56532 if test "x$OPENJDK_TARGET_CPU_BITS" = x64; then 56533 POSSIBLE_MSVC_DLL=`$FIND "$CYGWIN_VS_TOOLS_DIR" -name $DLL_NAME \ 56534 | $GREP -i /x64/ | $HEAD --lines 1` 56535 else 56536 POSSIBLE_MSVC_DLL=`$FIND "$CYGWIN_VS_TOOLS_DIR" -name $DLL_NAME \ 56537 | $GREP -i /x86/ | $HEAD --lines 1` 56538 fi 56539 56540 DLL_NAME="$DLL_NAME" 56541 POSSIBLE_MSVC_DLL="$POSSIBLE_MSVC_DLL" 56542 METHOD="search of VS100COMNTOOLS" 56543 if test -n "$POSSIBLE_MSVC_DLL" -a -e "$POSSIBLE_MSVC_DLL"; then 56544 { $as_echo "$as_me:${as_lineno-$LINENO}: Found $DLL_NAME at $POSSIBLE_MSVC_DLL using $METHOD" >&5 56545 $as_echo "$as_me: Found $DLL_NAME at $POSSIBLE_MSVC_DLL using $METHOD" >&6;} 56546 56547 # Need to check if the found msvcr is correct architecture 56548 { $as_echo "$as_me:${as_lineno-$LINENO}: checking found $DLL_NAME architecture" >&5 56549 $as_echo_n "checking found $DLL_NAME architecture... " >&6; } 56550 MSVC_DLL_FILETYPE=`$FILE -b "$POSSIBLE_MSVC_DLL"` 56551 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 56552 # The MSYS 'file' command returns "PE32 executable for MS Windows (DLL) (GUI) Intel 80386 32-bit" 56553 # on x32 and "PE32+ executable for MS Windows (DLL) (GUI) Mono/.Net assembly" on x64 systems. 56554 if test "x$OPENJDK_TARGET_CPU_BITS" = x32; then 56555 CORRECT_MSVCR_ARCH="PE32 executable" 56556 else 56557 CORRECT_MSVCR_ARCH="PE32+ executable" 56558 fi 56559 else 56560 if test "x$OPENJDK_TARGET_CPU_BITS" = x32; then 56561 CORRECT_MSVCR_ARCH=386 56562 else 56563 CORRECT_MSVCR_ARCH=x86-64 56564 fi 56565 fi 56566 if $ECHO "$MSVC_DLL_FILETYPE" | $GREP "$CORRECT_MSVCR_ARCH" 2>&1 > /dev/null; then 56567 { $as_echo "$as_me:${as_lineno-$LINENO}: result: ok" >&5 56568 $as_echo "ok" >&6; } 56569 MSVC_DLL="$POSSIBLE_MSVC_DLL" 56570 56571 # Only process if variable expands to non-empty 56572 56573 if test "x$MSVC_DLL" != x; then 56574 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 56575 56576 # Input might be given as Windows format, start by converting to 56577 # unix format. 56578 path="$MSVC_DLL" 56579 new_path=`$CYGPATH -u "$path"` 56580 56581 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 56582 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 56583 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 56584 # "foo.exe" is OK but "foo" is an error. 56585 # 56586 # This test is therefore slightly more accurate than "test -f" to check for file precense. 56587 # It is also a way to make sure we got the proper file name for the real test later on. 56588 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 56589 if test "x$test_shortpath" = x; then 56590 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of MSVC_DLL, which resolves as \"$path\", is invalid." >&5 56591 $as_echo "$as_me: The path of MSVC_DLL, which resolves as \"$path\", is invalid." >&6;} 56592 as_fn_error $? "Cannot locate the the path of MSVC_DLL" "$LINENO" 5 56593 fi 56594 56595 # Call helper function which possibly converts this using DOS-style short mode. 56596 # If so, the updated path is stored in $new_path. 56597 56598 input_path="$new_path" 56599 # Check if we need to convert this using DOS-style short mode. If the path 56600 # contains just simple characters, use it. Otherwise (spaces, weird characters), 56601 # take no chances and rewrite it. 56602 # Note: m4 eats our [], so we need to use [ and ] instead. 56603 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 56604 if test "x$has_forbidden_chars" != x; then 56605 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 56606 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 56607 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 56608 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 56609 # Going to short mode and back again did indeed matter. Since short mode is 56610 # case insensitive, let's make it lowercase to improve readability. 56611 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 56612 # Now convert it back to Unix-style (cygpath) 56613 input_path=`$CYGPATH -u "$shortmode_path"` 56614 new_path="$input_path" 56615 fi 56616 fi 56617 56618 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 56619 if test "x$test_cygdrive_prefix" = x; then 56620 # As a simple fix, exclude /usr/bin since it's not a real path. 56621 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 56622 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 56623 # a path prefixed by /cygdrive for fixpath to work. 56624 new_path="$CYGWIN_ROOT_PATH$input_path" 56625 fi 56626 fi 56627 56628 56629 if test "x$path" != "x$new_path"; then 56630 MSVC_DLL="$new_path" 56631 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting MSVC_DLL to \"$new_path\"" >&5 56632 $as_echo "$as_me: Rewriting MSVC_DLL to \"$new_path\"" >&6;} 56633 fi 56634 56635 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 56636 56637 path="$MSVC_DLL" 56638 has_colon=`$ECHO $path | $GREP ^.:` 56639 new_path="$path" 56640 if test "x$has_colon" = x; then 56641 # Not in mixed or Windows style, start by that. 56642 new_path=`cmd //c echo $path` 56643 fi 56644 56645 56646 input_path="$new_path" 56647 # Check if we need to convert this using DOS-style short mode. If the path 56648 # contains just simple characters, use it. Otherwise (spaces, weird characters), 56649 # take no chances and rewrite it. 56650 # Note: m4 eats our [], so we need to use [ and ] instead. 56651 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 56652 if test "x$has_forbidden_chars" != x; then 56653 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 56654 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 56655 fi 56656 56657 56658 windows_path="$new_path" 56659 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 56660 unix_path=`$CYGPATH -u "$windows_path"` 56661 new_path="$unix_path" 56662 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 56663 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 56664 new_path="$unix_path" 56665 fi 56666 56667 if test "x$path" != "x$new_path"; then 56668 MSVC_DLL="$new_path" 56669 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting MSVC_DLL to \"$new_path\"" >&5 56670 $as_echo "$as_me: Rewriting MSVC_DLL to \"$new_path\"" >&6;} 56671 fi 56672 56673 # Save the first 10 bytes of this path to the storage, so fixpath can work. 56674 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 56675 56676 else 56677 # We're on a unix platform. Hooray! :) 56678 path="$MSVC_DLL" 56679 has_space=`$ECHO "$path" | $GREP " "` 56680 if test "x$has_space" != x; then 56681 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of MSVC_DLL, which resolves as \"$path\", is invalid." >&5 56682 $as_echo "$as_me: The path of MSVC_DLL, which resolves as \"$path\", is invalid." >&6;} 56683 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 56684 fi 56685 56686 # Use eval to expand a potential ~ 56687 eval path="$path" 56688 if test ! -f "$path" && test ! -d "$path"; then 56689 as_fn_error $? "The path of MSVC_DLL, which resolves as \"$path\", is not found." "$LINENO" 5 56690 fi 56691 56692 if test -d "$path"; then 56693 MSVC_DLL="`cd "$path"; $THEPWDCMD -L`" 56694 else 56695 dir="`$DIRNAME "$path"`" 56696 base="`$BASENAME "$path"`" 56697 MSVC_DLL="`cd "$dir"; $THEPWDCMD -L`/$base" 56698 fi 56699 fi 56700 fi 56701 56702 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $DLL_NAME" >&5 56703 $as_echo_n "checking for $DLL_NAME... " >&6; } 56704 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MSVC_DLL" >&5 56705 $as_echo "$MSVC_DLL" >&6; } 56706 else 56707 { $as_echo "$as_me:${as_lineno-$LINENO}: result: incorrect, ignoring" >&5 56708 $as_echo "incorrect, ignoring" >&6; } 56709 { $as_echo "$as_me:${as_lineno-$LINENO}: The file type of the located $DLL_NAME is $MSVC_DLL_FILETYPE" >&5 56710 $as_echo "$as_me: The file type of the located $DLL_NAME is $MSVC_DLL_FILETYPE" >&6;} 56711 fi 56712 fi 56713 56714 fi 56715 fi 56716 56717 if test "x$MSVC_DLL" = x; then 56718 # Probe: Search wildly in the VCINSTALLDIR. We've probably lost by now. 56719 # (This was the original behaviour; kept since it might turn something up) 56720 if test "x$CYGWIN_VC_INSTALL_DIR" != x; then 56721 if test "x$OPENJDK_TARGET_CPU_BITS" = x64; then 56722 POSSIBLE_MSVC_DLL=`$FIND "$CYGWIN_VC_INSTALL_DIR" -name $DLL_NAME \ 56723 | $GREP x64 | $HEAD --lines 1` 56724 else 56725 POSSIBLE_MSVC_DLL=`$FIND "$CYGWIN_VC_INSTALL_DIR" -name $DLL_NAME \ 56726 | $GREP x86 | $GREP -v ia64 | $GREP -v x64 | $HEAD --lines 1` 56727 if test "x$POSSIBLE_MSVC_DLL" = x; then 56728 # We're grasping at straws now... 56729 POSSIBLE_MSVC_DLL=`$FIND "$CYGWIN_VC_INSTALL_DIR" -name $DLL_NAME \ 56730 | $HEAD --lines 1` 56731 fi 56732 fi 56733 56734 56735 DLL_NAME="$DLL_NAME" 56736 POSSIBLE_MSVC_DLL="$POSSIBLE_MSVC_DLL" 56737 METHOD="search of VCINSTALLDIR" 56738 if test -n "$POSSIBLE_MSVC_DLL" -a -e "$POSSIBLE_MSVC_DLL"; then 56739 { $as_echo "$as_me:${as_lineno-$LINENO}: Found $DLL_NAME at $POSSIBLE_MSVC_DLL using $METHOD" >&5 56740 $as_echo "$as_me: Found $DLL_NAME at $POSSIBLE_MSVC_DLL using $METHOD" >&6;} 56741 56742 # Need to check if the found msvcr is correct architecture 56743 { $as_echo "$as_me:${as_lineno-$LINENO}: checking found $DLL_NAME architecture" >&5 56744 $as_echo_n "checking found $DLL_NAME architecture... " >&6; } 56745 MSVC_DLL_FILETYPE=`$FILE -b "$POSSIBLE_MSVC_DLL"` 56746 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 56747 # The MSYS 'file' command returns "PE32 executable for MS Windows (DLL) (GUI) Intel 80386 32-bit" 56748 # on x32 and "PE32+ executable for MS Windows (DLL) (GUI) Mono/.Net assembly" on x64 systems. 56749 if test "x$OPENJDK_TARGET_CPU_BITS" = x32; then 56750 CORRECT_MSVCR_ARCH="PE32 executable" 56751 else 56752 CORRECT_MSVCR_ARCH="PE32+ executable" 56753 fi 56754 else 56755 if test "x$OPENJDK_TARGET_CPU_BITS" = x32; then 56756 CORRECT_MSVCR_ARCH=386 56757 else 56758 CORRECT_MSVCR_ARCH=x86-64 56759 fi 56760 fi 56761 if $ECHO "$MSVC_DLL_FILETYPE" | $GREP "$CORRECT_MSVCR_ARCH" 2>&1 > /dev/null; then 56762 { $as_echo "$as_me:${as_lineno-$LINENO}: result: ok" >&5 56763 $as_echo "ok" >&6; } 56764 MSVC_DLL="$POSSIBLE_MSVC_DLL" 56765 56766 # Only process if variable expands to non-empty 56767 56768 if test "x$MSVC_DLL" != x; then 56769 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 56770 56771 # Input might be given as Windows format, start by converting to 56772 # unix format. 56773 path="$MSVC_DLL" 56774 new_path=`$CYGPATH -u "$path"` 56775 56776 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 56777 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 56778 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 56779 # "foo.exe" is OK but "foo" is an error. 56780 # 56781 # This test is therefore slightly more accurate than "test -f" to check for file precense. 56782 # It is also a way to make sure we got the proper file name for the real test later on. 56783 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 56784 if test "x$test_shortpath" = x; then 56785 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of MSVC_DLL, which resolves as \"$path\", is invalid." >&5 56786 $as_echo "$as_me: The path of MSVC_DLL, which resolves as \"$path\", is invalid." >&6;} 56787 as_fn_error $? "Cannot locate the the path of MSVC_DLL" "$LINENO" 5 56788 fi 56789 56790 # Call helper function which possibly converts this using DOS-style short mode. 56791 # If so, the updated path is stored in $new_path. 56792 56793 input_path="$new_path" 56794 # Check if we need to convert this using DOS-style short mode. If the path 56795 # contains just simple characters, use it. Otherwise (spaces, weird characters), 56796 # take no chances and rewrite it. 56797 # Note: m4 eats our [], so we need to use [ and ] instead. 56798 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 56799 if test "x$has_forbidden_chars" != x; then 56800 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 56801 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 56802 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 56803 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 56804 # Going to short mode and back again did indeed matter. Since short mode is 56805 # case insensitive, let's make it lowercase to improve readability. 56806 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 56807 # Now convert it back to Unix-style (cygpath) 56808 input_path=`$CYGPATH -u "$shortmode_path"` 56809 new_path="$input_path" 56810 fi 56811 fi 56812 56813 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 56814 if test "x$test_cygdrive_prefix" = x; then 56815 # As a simple fix, exclude /usr/bin since it's not a real path. 56816 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 56817 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 56818 # a path prefixed by /cygdrive for fixpath to work. 56819 new_path="$CYGWIN_ROOT_PATH$input_path" 56820 fi 56821 fi 56822 56823 56824 if test "x$path" != "x$new_path"; then 56825 MSVC_DLL="$new_path" 56826 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting MSVC_DLL to \"$new_path\"" >&5 56827 $as_echo "$as_me: Rewriting MSVC_DLL to \"$new_path\"" >&6;} 56828 fi 56829 56830 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 56831 56832 path="$MSVC_DLL" 56833 has_colon=`$ECHO $path | $GREP ^.:` 56834 new_path="$path" 56835 if test "x$has_colon" = x; then 56836 # Not in mixed or Windows style, start by that. 56837 new_path=`cmd //c echo $path` 56838 fi 56839 56840 56841 input_path="$new_path" 56842 # Check if we need to convert this using DOS-style short mode. If the path 56843 # contains just simple characters, use it. Otherwise (spaces, weird characters), 56844 # take no chances and rewrite it. 56845 # Note: m4 eats our [], so we need to use [ and ] instead. 56846 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 56847 if test "x$has_forbidden_chars" != x; then 56848 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 56849 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 56850 fi 56851 56852 56853 windows_path="$new_path" 56854 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 56855 unix_path=`$CYGPATH -u "$windows_path"` 56856 new_path="$unix_path" 56857 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 56858 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 56859 new_path="$unix_path" 56860 fi 56861 56862 if test "x$path" != "x$new_path"; then 56863 MSVC_DLL="$new_path" 56864 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting MSVC_DLL to \"$new_path\"" >&5 56865 $as_echo "$as_me: Rewriting MSVC_DLL to \"$new_path\"" >&6;} 56866 fi 56867 56868 # Save the first 10 bytes of this path to the storage, so fixpath can work. 56869 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 56870 56871 else 56872 # We're on a unix platform. Hooray! :) 56873 path="$MSVC_DLL" 56874 has_space=`$ECHO "$path" | $GREP " "` 56875 if test "x$has_space" != x; then 56876 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of MSVC_DLL, which resolves as \"$path\", is invalid." >&5 56877 $as_echo "$as_me: The path of MSVC_DLL, which resolves as \"$path\", is invalid." >&6;} 56878 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 56879 fi 56880 56881 # Use eval to expand a potential ~ 56882 eval path="$path" 56883 if test ! -f "$path" && test ! -d "$path"; then 56884 as_fn_error $? "The path of MSVC_DLL, which resolves as \"$path\", is not found." "$LINENO" 5 56885 fi 56886 56887 if test -d "$path"; then 56888 MSVC_DLL="`cd "$path"; $THEPWDCMD -L`" 56889 else 56890 dir="`$DIRNAME "$path"`" 56891 base="`$BASENAME "$path"`" 56892 MSVC_DLL="`cd "$dir"; $THEPWDCMD -L`/$base" 56893 fi 56894 fi 56895 fi 56896 56897 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $DLL_NAME" >&5 56898 $as_echo_n "checking for $DLL_NAME... " >&6; } 56899 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MSVC_DLL" >&5 56900 $as_echo "$MSVC_DLL" >&6; } 56901 else 56902 { $as_echo "$as_me:${as_lineno-$LINENO}: result: incorrect, ignoring" >&5 56903 $as_echo "incorrect, ignoring" >&6; } 56904 { $as_echo "$as_me:${as_lineno-$LINENO}: The file type of the located $DLL_NAME is $MSVC_DLL_FILETYPE" >&5 56905 $as_echo "$as_me: The file type of the located $DLL_NAME is $MSVC_DLL_FILETYPE" >&6;} 56906 fi 56907 fi 56908 56909 fi 56910 fi 56911 56912 if test "x$MSVC_DLL" = x; then 56913 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $DLL_NAME" >&5 56914 $as_echo_n "checking for $DLL_NAME... " >&6; } 56915 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 56916 $as_echo "no" >&6; } 56917 as_fn_error $? "Could not find $DLL_NAME. Please specify using --with-msvcr-dll." "$LINENO" 5 56918 fi 56919 56920 MSVCR_DLL="$MSVC_DLL" 56921 fi 56922 56923 56924 56925 # Check whether --with-msvcp-dll was given. 56926 if test "${with_msvcp_dll+set}" = set; then : 56927 withval=$with_msvcp_dll; 56928 fi 56929 56930 56931 if test "x$MSVCP_NAME" != "x"; then 56932 if test "x$with_msvcp_dll" != x; then 56933 # If given explicitly by user, do not probe. If not present, fail directly. 56934 56935 DLL_NAME="$MSVCP_NAME" 56936 POSSIBLE_MSVC_DLL="$with_msvcp_dll" 56937 METHOD="--with-msvcp-dll" 56938 if test -n "$POSSIBLE_MSVC_DLL" -a -e "$POSSIBLE_MSVC_DLL"; then 56939 { $as_echo "$as_me:${as_lineno-$LINENO}: Found $DLL_NAME at $POSSIBLE_MSVC_DLL using $METHOD" >&5 56940 $as_echo "$as_me: Found $DLL_NAME at $POSSIBLE_MSVC_DLL using $METHOD" >&6;} 56941 56942 # Need to check if the found msvcr is correct architecture 56943 { $as_echo "$as_me:${as_lineno-$LINENO}: checking found $DLL_NAME architecture" >&5 56944 $as_echo_n "checking found $DLL_NAME architecture... " >&6; } 56945 MSVC_DLL_FILETYPE=`$FILE -b "$POSSIBLE_MSVC_DLL"` 56946 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 56947 # The MSYS 'file' command returns "PE32 executable for MS Windows (DLL) (GUI) Intel 80386 32-bit" 56948 # on x32 and "PE32+ executable for MS Windows (DLL) (GUI) Mono/.Net assembly" on x64 systems. 56949 if test "x$OPENJDK_TARGET_CPU_BITS" = x32; then 56950 CORRECT_MSVCR_ARCH="PE32 executable" 56951 else 56952 CORRECT_MSVCR_ARCH="PE32+ executable" 56953 fi 56954 else 56955 if test "x$OPENJDK_TARGET_CPU_BITS" = x32; then 56956 CORRECT_MSVCR_ARCH=386 56957 else 56958 CORRECT_MSVCR_ARCH=x86-64 56959 fi 56960 fi 56961 if $ECHO "$MSVC_DLL_FILETYPE" | $GREP "$CORRECT_MSVCR_ARCH" 2>&1 > /dev/null; then 56962 { $as_echo "$as_me:${as_lineno-$LINENO}: result: ok" >&5 56963 $as_echo "ok" >&6; } 56964 MSVC_DLL="$POSSIBLE_MSVC_DLL" 56965 56966 # Only process if variable expands to non-empty 56967 56968 if test "x$MSVC_DLL" != x; then 56969 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 56970 56971 # Input might be given as Windows format, start by converting to 56972 # unix format. 56973 path="$MSVC_DLL" 56974 new_path=`$CYGPATH -u "$path"` 56975 56976 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 56977 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 56978 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 56979 # "foo.exe" is OK but "foo" is an error. 56980 # 56981 # This test is therefore slightly more accurate than "test -f" to check for file precense. 56982 # It is also a way to make sure we got the proper file name for the real test later on. 56983 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 56984 if test "x$test_shortpath" = x; then 56985 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of MSVC_DLL, which resolves as \"$path\", is invalid." >&5 56986 $as_echo "$as_me: The path of MSVC_DLL, which resolves as \"$path\", is invalid." >&6;} 56987 as_fn_error $? "Cannot locate the the path of MSVC_DLL" "$LINENO" 5 56988 fi 56989 56990 # Call helper function which possibly converts this using DOS-style short mode. 56991 # If so, the updated path is stored in $new_path. 56992 56993 input_path="$new_path" 56994 # Check if we need to convert this using DOS-style short mode. If the path 56995 # contains just simple characters, use it. Otherwise (spaces, weird characters), 56996 # take no chances and rewrite it. 56997 # Note: m4 eats our [], so we need to use [ and ] instead. 56998 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 56999 if test "x$has_forbidden_chars" != x; then 57000 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 57001 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 57002 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 57003 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 57004 # Going to short mode and back again did indeed matter. Since short mode is 57005 # case insensitive, let's make it lowercase to improve readability. 57006 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 57007 # Now convert it back to Unix-style (cygpath) 57008 input_path=`$CYGPATH -u "$shortmode_path"` 57009 new_path="$input_path" 57010 fi 57011 fi 57012 57013 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 57014 if test "x$test_cygdrive_prefix" = x; then 57015 # As a simple fix, exclude /usr/bin since it's not a real path. 57016 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 57017 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 57018 # a path prefixed by /cygdrive for fixpath to work. 57019 new_path="$CYGWIN_ROOT_PATH$input_path" 57020 fi 57021 fi 57022 57023 57024 if test "x$path" != "x$new_path"; then 57025 MSVC_DLL="$new_path" 57026 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting MSVC_DLL to \"$new_path\"" >&5 57027 $as_echo "$as_me: Rewriting MSVC_DLL to \"$new_path\"" >&6;} 57028 fi 57029 57030 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 57031 57032 path="$MSVC_DLL" 57033 has_colon=`$ECHO $path | $GREP ^.:` 57034 new_path="$path" 57035 if test "x$has_colon" = x; then 57036 # Not in mixed or Windows style, start by that. 57037 new_path=`cmd //c echo $path` 57038 fi 57039 57040 57041 input_path="$new_path" 57042 # Check if we need to convert this using DOS-style short mode. If the path 57043 # contains just simple characters, use it. Otherwise (spaces, weird characters), 57044 # take no chances and rewrite it. 57045 # Note: m4 eats our [], so we need to use [ and ] instead. 57046 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 57047 if test "x$has_forbidden_chars" != x; then 57048 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 57049 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 57050 fi 57051 57052 57053 windows_path="$new_path" 57054 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 57055 unix_path=`$CYGPATH -u "$windows_path"` 57056 new_path="$unix_path" 57057 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 57058 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 57059 new_path="$unix_path" 57060 fi 57061 57062 if test "x$path" != "x$new_path"; then 57063 MSVC_DLL="$new_path" 57064 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting MSVC_DLL to \"$new_path\"" >&5 57065 $as_echo "$as_me: Rewriting MSVC_DLL to \"$new_path\"" >&6;} 57066 fi 57067 57068 # Save the first 10 bytes of this path to the storage, so fixpath can work. 57069 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 57070 57071 else 57072 # We're on a unix platform. Hooray! :) 57073 path="$MSVC_DLL" 57074 has_space=`$ECHO "$path" | $GREP " "` 57075 if test "x$has_space" != x; then 57076 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of MSVC_DLL, which resolves as \"$path\", is invalid." >&5 57077 $as_echo "$as_me: The path of MSVC_DLL, which resolves as \"$path\", is invalid." >&6;} 57078 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 57079 fi 57080 57081 # Use eval to expand a potential ~ 57082 eval path="$path" 57083 if test ! -f "$path" && test ! -d "$path"; then 57084 as_fn_error $? "The path of MSVC_DLL, which resolves as \"$path\", is not found." "$LINENO" 5 57085 fi 57086 57087 if test -d "$path"; then 57088 MSVC_DLL="`cd "$path"; $THEPWDCMD -L`" 57089 else 57090 dir="`$DIRNAME "$path"`" 57091 base="`$BASENAME "$path"`" 57092 MSVC_DLL="`cd "$dir"; $THEPWDCMD -L`/$base" 57093 fi 57094 fi 57095 fi 57096 57097 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $DLL_NAME" >&5 57098 $as_echo_n "checking for $DLL_NAME... " >&6; } 57099 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MSVC_DLL" >&5 57100 $as_echo "$MSVC_DLL" >&6; } 57101 else 57102 { $as_echo "$as_me:${as_lineno-$LINENO}: result: incorrect, ignoring" >&5 57103 $as_echo "incorrect, ignoring" >&6; } 57104 { $as_echo "$as_me:${as_lineno-$LINENO}: The file type of the located $DLL_NAME is $MSVC_DLL_FILETYPE" >&5 57105 $as_echo "$as_me: The file type of the located $DLL_NAME is $MSVC_DLL_FILETYPE" >&6;} 57106 fi 57107 fi 57108 57109 if test "x$MSVC_DLL" = x; then 57110 as_fn_error $? "Could not find a proper $MSVCP_NAME as specified by --with-msvcp-dll" "$LINENO" 5 57111 fi 57112 MSVCP_DLL="$MSVC_DLL" 57113 elif test "x$DEVKIT_MSVCP_DLL" != x; then 57114 57115 DLL_NAME="$MSVCP_NAME" 57116 POSSIBLE_MSVC_DLL="$DEVKIT_MSVCP_DLL" 57117 METHOD="devkit" 57118 if test -n "$POSSIBLE_MSVC_DLL" -a -e "$POSSIBLE_MSVC_DLL"; then 57119 { $as_echo "$as_me:${as_lineno-$LINENO}: Found $DLL_NAME at $POSSIBLE_MSVC_DLL using $METHOD" >&5 57120 $as_echo "$as_me: Found $DLL_NAME at $POSSIBLE_MSVC_DLL using $METHOD" >&6;} 57121 57122 # Need to check if the found msvcr is correct architecture 57123 { $as_echo "$as_me:${as_lineno-$LINENO}: checking found $DLL_NAME architecture" >&5 57124 $as_echo_n "checking found $DLL_NAME architecture... " >&6; } 57125 MSVC_DLL_FILETYPE=`$FILE -b "$POSSIBLE_MSVC_DLL"` 57126 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 57127 # The MSYS 'file' command returns "PE32 executable for MS Windows (DLL) (GUI) Intel 80386 32-bit" 57128 # on x32 and "PE32+ executable for MS Windows (DLL) (GUI) Mono/.Net assembly" on x64 systems. 57129 if test "x$OPENJDK_TARGET_CPU_BITS" = x32; then 57130 CORRECT_MSVCR_ARCH="PE32 executable" 57131 else 57132 CORRECT_MSVCR_ARCH="PE32+ executable" 57133 fi 57134 else 57135 if test "x$OPENJDK_TARGET_CPU_BITS" = x32; then 57136 CORRECT_MSVCR_ARCH=386 57137 else 57138 CORRECT_MSVCR_ARCH=x86-64 57139 fi 57140 fi 57141 if $ECHO "$MSVC_DLL_FILETYPE" | $GREP "$CORRECT_MSVCR_ARCH" 2>&1 > /dev/null; then 57142 { $as_echo "$as_me:${as_lineno-$LINENO}: result: ok" >&5 57143 $as_echo "ok" >&6; } 57144 MSVC_DLL="$POSSIBLE_MSVC_DLL" 57145 57146 # Only process if variable expands to non-empty 57147 57148 if test "x$MSVC_DLL" != x; then 57149 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 57150 57151 # Input might be given as Windows format, start by converting to 57152 # unix format. 57153 path="$MSVC_DLL" 57154 new_path=`$CYGPATH -u "$path"` 57155 57156 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 57157 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 57158 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 57159 # "foo.exe" is OK but "foo" is an error. 57160 # 57161 # This test is therefore slightly more accurate than "test -f" to check for file precense. 57162 # It is also a way to make sure we got the proper file name for the real test later on. 57163 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 57164 if test "x$test_shortpath" = x; then 57165 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of MSVC_DLL, which resolves as \"$path\", is invalid." >&5 57166 $as_echo "$as_me: The path of MSVC_DLL, which resolves as \"$path\", is invalid." >&6;} 57167 as_fn_error $? "Cannot locate the the path of MSVC_DLL" "$LINENO" 5 57168 fi 57169 57170 # Call helper function which possibly converts this using DOS-style short mode. 57171 # If so, the updated path is stored in $new_path. 57172 57173 input_path="$new_path" 57174 # Check if we need to convert this using DOS-style short mode. If the path 57175 # contains just simple characters, use it. Otherwise (spaces, weird characters), 57176 # take no chances and rewrite it. 57177 # Note: m4 eats our [], so we need to use [ and ] instead. 57178 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 57179 if test "x$has_forbidden_chars" != x; then 57180 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 57181 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 57182 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 57183 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 57184 # Going to short mode and back again did indeed matter. Since short mode is 57185 # case insensitive, let's make it lowercase to improve readability. 57186 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 57187 # Now convert it back to Unix-style (cygpath) 57188 input_path=`$CYGPATH -u "$shortmode_path"` 57189 new_path="$input_path" 57190 fi 57191 fi 57192 57193 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 57194 if test "x$test_cygdrive_prefix" = x; then 57195 # As a simple fix, exclude /usr/bin since it's not a real path. 57196 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 57197 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 57198 # a path prefixed by /cygdrive for fixpath to work. 57199 new_path="$CYGWIN_ROOT_PATH$input_path" 57200 fi 57201 fi 57202 57203 57204 if test "x$path" != "x$new_path"; then 57205 MSVC_DLL="$new_path" 57206 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting MSVC_DLL to \"$new_path\"" >&5 57207 $as_echo "$as_me: Rewriting MSVC_DLL to \"$new_path\"" >&6;} 57208 fi 57209 57210 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 57211 57212 path="$MSVC_DLL" 57213 has_colon=`$ECHO $path | $GREP ^.:` 57214 new_path="$path" 57215 if test "x$has_colon" = x; then 57216 # Not in mixed or Windows style, start by that. 57217 new_path=`cmd //c echo $path` 57218 fi 57219 57220 57221 input_path="$new_path" 57222 # Check if we need to convert this using DOS-style short mode. If the path 57223 # contains just simple characters, use it. Otherwise (spaces, weird characters), 57224 # take no chances and rewrite it. 57225 # Note: m4 eats our [], so we need to use [ and ] instead. 57226 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 57227 if test "x$has_forbidden_chars" != x; then 57228 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 57229 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 57230 fi 57231 57232 57233 windows_path="$new_path" 57234 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 57235 unix_path=`$CYGPATH -u "$windows_path"` 57236 new_path="$unix_path" 57237 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 57238 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 57239 new_path="$unix_path" 57240 fi 57241 57242 if test "x$path" != "x$new_path"; then 57243 MSVC_DLL="$new_path" 57244 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting MSVC_DLL to \"$new_path\"" >&5 57245 $as_echo "$as_me: Rewriting MSVC_DLL to \"$new_path\"" >&6;} 57246 fi 57247 57248 # Save the first 10 bytes of this path to the storage, so fixpath can work. 57249 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 57250 57251 else 57252 # We're on a unix platform. Hooray! :) 57253 path="$MSVC_DLL" 57254 has_space=`$ECHO "$path" | $GREP " "` 57255 if test "x$has_space" != x; then 57256 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of MSVC_DLL, which resolves as \"$path\", is invalid." >&5 57257 $as_echo "$as_me: The path of MSVC_DLL, which resolves as \"$path\", is invalid." >&6;} 57258 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 57259 fi 57260 57261 # Use eval to expand a potential ~ 57262 eval path="$path" 57263 if test ! -f "$path" && test ! -d "$path"; then 57264 as_fn_error $? "The path of MSVC_DLL, which resolves as \"$path\", is not found." "$LINENO" 5 57265 fi 57266 57267 if test -d "$path"; then 57268 MSVC_DLL="`cd "$path"; $THEPWDCMD -L`" 57269 else 57270 dir="`$DIRNAME "$path"`" 57271 base="`$BASENAME "$path"`" 57272 MSVC_DLL="`cd "$dir"; $THEPWDCMD -L`/$base" 57273 fi 57274 fi 57275 fi 57276 57277 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $DLL_NAME" >&5 57278 $as_echo_n "checking for $DLL_NAME... " >&6; } 57279 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MSVC_DLL" >&5 57280 $as_echo "$MSVC_DLL" >&6; } 57281 else 57282 { $as_echo "$as_me:${as_lineno-$LINENO}: result: incorrect, ignoring" >&5 57283 $as_echo "incorrect, ignoring" >&6; } 57284 { $as_echo "$as_me:${as_lineno-$LINENO}: The file type of the located $DLL_NAME is $MSVC_DLL_FILETYPE" >&5 57285 $as_echo "$as_me: The file type of the located $DLL_NAME is $MSVC_DLL_FILETYPE" >&6;} 57286 fi 57287 fi 57288 57289 if test "x$MSVC_DLL" = x; then 57290 as_fn_error $? "Could not find a proper $MSVCP_NAME as specified by devkit" "$LINENO" 5 57291 fi 57292 MSVCP_DLL="$MSVC_DLL" 57293 else 57294 57295 DLL_NAME="${MSVCP_NAME}" 57296 MSVC_DLL= 57297 57298 if test "x$MSVC_DLL" = x; then 57299 # Probe: Using well-known location from Visual Studio 10.0 57300 if test "x$VCINSTALLDIR" != x; then 57301 CYGWIN_VC_INSTALL_DIR="$VCINSTALLDIR" 57302 57303 windows_path="$CYGWIN_VC_INSTALL_DIR" 57304 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 57305 unix_path=`$CYGPATH -u "$windows_path"` 57306 CYGWIN_VC_INSTALL_DIR="$unix_path" 57307 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 57308 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 57309 CYGWIN_VC_INSTALL_DIR="$unix_path" 57310 fi 57311 57312 if test "x$OPENJDK_TARGET_CPU_BITS" = x64; then 57313 POSSIBLE_MSVC_DLL="$CYGWIN_VC_INSTALL_DIR/redist/x64/Microsoft.VC${VS_VERSION_INTERNAL}.CRT/$DLL_NAME" 57314 else 57315 POSSIBLE_MSVC_DLL="$CYGWIN_VC_INSTALL_DIR/redist/x86/Microsoft.VC${VS_VERSION_INTERNAL}.CRT/$DLL_NAME" 57316 fi 57317 $ECHO "POSSIBLE_MSVC_DLL $POSSIBLEMSVC_DLL" 57318 57319 DLL_NAME="$DLL_NAME" 57320 POSSIBLE_MSVC_DLL="$POSSIBLE_MSVC_DLL" 57321 METHOD="well-known location in VCINSTALLDIR" 57322 if test -n "$POSSIBLE_MSVC_DLL" -a -e "$POSSIBLE_MSVC_DLL"; then 57323 { $as_echo "$as_me:${as_lineno-$LINENO}: Found $DLL_NAME at $POSSIBLE_MSVC_DLL using $METHOD" >&5 57324 $as_echo "$as_me: Found $DLL_NAME at $POSSIBLE_MSVC_DLL using $METHOD" >&6;} 57325 57326 # Need to check if the found msvcr is correct architecture 57327 { $as_echo "$as_me:${as_lineno-$LINENO}: checking found $DLL_NAME architecture" >&5 57328 $as_echo_n "checking found $DLL_NAME architecture... " >&6; } 57329 MSVC_DLL_FILETYPE=`$FILE -b "$POSSIBLE_MSVC_DLL"` 57330 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 57331 # The MSYS 'file' command returns "PE32 executable for MS Windows (DLL) (GUI) Intel 80386 32-bit" 57332 # on x32 and "PE32+ executable for MS Windows (DLL) (GUI) Mono/.Net assembly" on x64 systems. 57333 if test "x$OPENJDK_TARGET_CPU_BITS" = x32; then 57334 CORRECT_MSVCR_ARCH="PE32 executable" 57335 else 57336 CORRECT_MSVCR_ARCH="PE32+ executable" 57337 fi 57338 else 57339 if test "x$OPENJDK_TARGET_CPU_BITS" = x32; then 57340 CORRECT_MSVCR_ARCH=386 57341 else 57342 CORRECT_MSVCR_ARCH=x86-64 57343 fi 57344 fi 57345 if $ECHO "$MSVC_DLL_FILETYPE" | $GREP "$CORRECT_MSVCR_ARCH" 2>&1 > /dev/null; then 57346 { $as_echo "$as_me:${as_lineno-$LINENO}: result: ok" >&5 57347 $as_echo "ok" >&6; } 57348 MSVC_DLL="$POSSIBLE_MSVC_DLL" 57349 57350 # Only process if variable expands to non-empty 57351 57352 if test "x$MSVC_DLL" != x; then 57353 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 57354 57355 # Input might be given as Windows format, start by converting to 57356 # unix format. 57357 path="$MSVC_DLL" 57358 new_path=`$CYGPATH -u "$path"` 57359 57360 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 57361 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 57362 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 57363 # "foo.exe" is OK but "foo" is an error. 57364 # 57365 # This test is therefore slightly more accurate than "test -f" to check for file precense. 57366 # It is also a way to make sure we got the proper file name for the real test later on. 57367 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 57368 if test "x$test_shortpath" = x; then 57369 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of MSVC_DLL, which resolves as \"$path\", is invalid." >&5 57370 $as_echo "$as_me: The path of MSVC_DLL, which resolves as \"$path\", is invalid." >&6;} 57371 as_fn_error $? "Cannot locate the the path of MSVC_DLL" "$LINENO" 5 57372 fi 57373 57374 # Call helper function which possibly converts this using DOS-style short mode. 57375 # If so, the updated path is stored in $new_path. 57376 57377 input_path="$new_path" 57378 # Check if we need to convert this using DOS-style short mode. If the path 57379 # contains just simple characters, use it. Otherwise (spaces, weird characters), 57380 # take no chances and rewrite it. 57381 # Note: m4 eats our [], so we need to use [ and ] instead. 57382 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 57383 if test "x$has_forbidden_chars" != x; then 57384 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 57385 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 57386 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 57387 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 57388 # Going to short mode and back again did indeed matter. Since short mode is 57389 # case insensitive, let's make it lowercase to improve readability. 57390 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 57391 # Now convert it back to Unix-style (cygpath) 57392 input_path=`$CYGPATH -u "$shortmode_path"` 57393 new_path="$input_path" 57394 fi 57395 fi 57396 57397 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 57398 if test "x$test_cygdrive_prefix" = x; then 57399 # As a simple fix, exclude /usr/bin since it's not a real path. 57400 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 57401 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 57402 # a path prefixed by /cygdrive for fixpath to work. 57403 new_path="$CYGWIN_ROOT_PATH$input_path" 57404 fi 57405 fi 57406 57407 57408 if test "x$path" != "x$new_path"; then 57409 MSVC_DLL="$new_path" 57410 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting MSVC_DLL to \"$new_path\"" >&5 57411 $as_echo "$as_me: Rewriting MSVC_DLL to \"$new_path\"" >&6;} 57412 fi 57413 57414 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 57415 57416 path="$MSVC_DLL" 57417 has_colon=`$ECHO $path | $GREP ^.:` 57418 new_path="$path" 57419 if test "x$has_colon" = x; then 57420 # Not in mixed or Windows style, start by that. 57421 new_path=`cmd //c echo $path` 57422 fi 57423 57424 57425 input_path="$new_path" 57426 # Check if we need to convert this using DOS-style short mode. If the path 57427 # contains just simple characters, use it. Otherwise (spaces, weird characters), 57428 # take no chances and rewrite it. 57429 # Note: m4 eats our [], so we need to use [ and ] instead. 57430 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 57431 if test "x$has_forbidden_chars" != x; then 57432 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 57433 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 57434 fi 57435 57436 57437 windows_path="$new_path" 57438 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 57439 unix_path=`$CYGPATH -u "$windows_path"` 57440 new_path="$unix_path" 57441 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 57442 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 57443 new_path="$unix_path" 57444 fi 57445 57446 if test "x$path" != "x$new_path"; then 57447 MSVC_DLL="$new_path" 57448 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting MSVC_DLL to \"$new_path\"" >&5 57449 $as_echo "$as_me: Rewriting MSVC_DLL to \"$new_path\"" >&6;} 57450 fi 57451 57452 # Save the first 10 bytes of this path to the storage, so fixpath can work. 57453 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 57454 57455 else 57456 # We're on a unix platform. Hooray! :) 57457 path="$MSVC_DLL" 57458 has_space=`$ECHO "$path" | $GREP " "` 57459 if test "x$has_space" != x; then 57460 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of MSVC_DLL, which resolves as \"$path\", is invalid." >&5 57461 $as_echo "$as_me: The path of MSVC_DLL, which resolves as \"$path\", is invalid." >&6;} 57462 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 57463 fi 57464 57465 # Use eval to expand a potential ~ 57466 eval path="$path" 57467 if test ! -f "$path" && test ! -d "$path"; then 57468 as_fn_error $? "The path of MSVC_DLL, which resolves as \"$path\", is not found." "$LINENO" 5 57469 fi 57470 57471 if test -d "$path"; then 57472 MSVC_DLL="`cd "$path"; $THEPWDCMD -L`" 57473 else 57474 dir="`$DIRNAME "$path"`" 57475 base="`$BASENAME "$path"`" 57476 MSVC_DLL="`cd "$dir"; $THEPWDCMD -L`/$base" 57477 fi 57478 fi 57479 fi 57480 57481 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $DLL_NAME" >&5 57482 $as_echo_n "checking for $DLL_NAME... " >&6; } 57483 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MSVC_DLL" >&5 57484 $as_echo "$MSVC_DLL" >&6; } 57485 else 57486 { $as_echo "$as_me:${as_lineno-$LINENO}: result: incorrect, ignoring" >&5 57487 $as_echo "incorrect, ignoring" >&6; } 57488 { $as_echo "$as_me:${as_lineno-$LINENO}: The file type of the located $DLL_NAME is $MSVC_DLL_FILETYPE" >&5 57489 $as_echo "$as_me: The file type of the located $DLL_NAME is $MSVC_DLL_FILETYPE" >&6;} 57490 fi 57491 fi 57492 57493 fi 57494 fi 57495 57496 if test "x$MSVC_DLL" = x; then 57497 # Probe: Check in the Boot JDK directory. 57498 POSSIBLE_MSVC_DLL="$BOOT_JDK/bin/$DLL_NAME" 57499 57500 DLL_NAME="$DLL_NAME" 57501 POSSIBLE_MSVC_DLL="$POSSIBLE_MSVC_DLL" 57502 METHOD="well-known location in Boot JDK" 57503 if test -n "$POSSIBLE_MSVC_DLL" -a -e "$POSSIBLE_MSVC_DLL"; then 57504 { $as_echo "$as_me:${as_lineno-$LINENO}: Found $DLL_NAME at $POSSIBLE_MSVC_DLL using $METHOD" >&5 57505 $as_echo "$as_me: Found $DLL_NAME at $POSSIBLE_MSVC_DLL using $METHOD" >&6;} 57506 57507 # Need to check if the found msvcr is correct architecture 57508 { $as_echo "$as_me:${as_lineno-$LINENO}: checking found $DLL_NAME architecture" >&5 57509 $as_echo_n "checking found $DLL_NAME architecture... " >&6; } 57510 MSVC_DLL_FILETYPE=`$FILE -b "$POSSIBLE_MSVC_DLL"` 57511 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 57512 # The MSYS 'file' command returns "PE32 executable for MS Windows (DLL) (GUI) Intel 80386 32-bit" 57513 # on x32 and "PE32+ executable for MS Windows (DLL) (GUI) Mono/.Net assembly" on x64 systems. 57514 if test "x$OPENJDK_TARGET_CPU_BITS" = x32; then 57515 CORRECT_MSVCR_ARCH="PE32 executable" 57516 else 57517 CORRECT_MSVCR_ARCH="PE32+ executable" 57518 fi 57519 else 57520 if test "x$OPENJDK_TARGET_CPU_BITS" = x32; then 57521 CORRECT_MSVCR_ARCH=386 57522 else 57523 CORRECT_MSVCR_ARCH=x86-64 57524 fi 57525 fi 57526 if $ECHO "$MSVC_DLL_FILETYPE" | $GREP "$CORRECT_MSVCR_ARCH" 2>&1 > /dev/null; then 57527 { $as_echo "$as_me:${as_lineno-$LINENO}: result: ok" >&5 57528 $as_echo "ok" >&6; } 57529 MSVC_DLL="$POSSIBLE_MSVC_DLL" 57530 57531 # Only process if variable expands to non-empty 57532 57533 if test "x$MSVC_DLL" != x; then 57534 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 57535 57536 # Input might be given as Windows format, start by converting to 57537 # unix format. 57538 path="$MSVC_DLL" 57539 new_path=`$CYGPATH -u "$path"` 57540 57541 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 57542 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 57543 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 57544 # "foo.exe" is OK but "foo" is an error. 57545 # 57546 # This test is therefore slightly more accurate than "test -f" to check for file precense. 57547 # It is also a way to make sure we got the proper file name for the real test later on. 57548 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 57549 if test "x$test_shortpath" = x; then 57550 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of MSVC_DLL, which resolves as \"$path\", is invalid." >&5 57551 $as_echo "$as_me: The path of MSVC_DLL, which resolves as \"$path\", is invalid." >&6;} 57552 as_fn_error $? "Cannot locate the the path of MSVC_DLL" "$LINENO" 5 57553 fi 57554 57555 # Call helper function which possibly converts this using DOS-style short mode. 57556 # If so, the updated path is stored in $new_path. 57557 57558 input_path="$new_path" 57559 # Check if we need to convert this using DOS-style short mode. If the path 57560 # contains just simple characters, use it. Otherwise (spaces, weird characters), 57561 # take no chances and rewrite it. 57562 # Note: m4 eats our [], so we need to use [ and ] instead. 57563 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 57564 if test "x$has_forbidden_chars" != x; then 57565 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 57566 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 57567 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 57568 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 57569 # Going to short mode and back again did indeed matter. Since short mode is 57570 # case insensitive, let's make it lowercase to improve readability. 57571 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 57572 # Now convert it back to Unix-style (cygpath) 57573 input_path=`$CYGPATH -u "$shortmode_path"` 57574 new_path="$input_path" 57575 fi 57576 fi 57577 57578 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 57579 if test "x$test_cygdrive_prefix" = x; then 57580 # As a simple fix, exclude /usr/bin since it's not a real path. 57581 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 57582 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 57583 # a path prefixed by /cygdrive for fixpath to work. 57584 new_path="$CYGWIN_ROOT_PATH$input_path" 57585 fi 57586 fi 57587 57588 57589 if test "x$path" != "x$new_path"; then 57590 MSVC_DLL="$new_path" 57591 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting MSVC_DLL to \"$new_path\"" >&5 57592 $as_echo "$as_me: Rewriting MSVC_DLL to \"$new_path\"" >&6;} 57593 fi 57594 57595 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 57596 57597 path="$MSVC_DLL" 57598 has_colon=`$ECHO $path | $GREP ^.:` 57599 new_path="$path" 57600 if test "x$has_colon" = x; then 57601 # Not in mixed or Windows style, start by that. 57602 new_path=`cmd //c echo $path` 57603 fi 57604 57605 57606 input_path="$new_path" 57607 # Check if we need to convert this using DOS-style short mode. If the path 57608 # contains just simple characters, use it. Otherwise (spaces, weird characters), 57609 # take no chances and rewrite it. 57610 # Note: m4 eats our [], so we need to use [ and ] instead. 57611 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 57612 if test "x$has_forbidden_chars" != x; then 57613 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 57614 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 57615 fi 57616 57617 57618 windows_path="$new_path" 57619 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 57620 unix_path=`$CYGPATH -u "$windows_path"` 57621 new_path="$unix_path" 57622 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 57623 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 57624 new_path="$unix_path" 57625 fi 57626 57627 if test "x$path" != "x$new_path"; then 57628 MSVC_DLL="$new_path" 57629 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting MSVC_DLL to \"$new_path\"" >&5 57630 $as_echo "$as_me: Rewriting MSVC_DLL to \"$new_path\"" >&6;} 57631 fi 57632 57633 # Save the first 10 bytes of this path to the storage, so fixpath can work. 57634 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 57635 57636 else 57637 # We're on a unix platform. Hooray! :) 57638 path="$MSVC_DLL" 57639 has_space=`$ECHO "$path" | $GREP " "` 57640 if test "x$has_space" != x; then 57641 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of MSVC_DLL, which resolves as \"$path\", is invalid." >&5 57642 $as_echo "$as_me: The path of MSVC_DLL, which resolves as \"$path\", is invalid." >&6;} 57643 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 57644 fi 57645 57646 # Use eval to expand a potential ~ 57647 eval path="$path" 57648 if test ! -f "$path" && test ! -d "$path"; then 57649 as_fn_error $? "The path of MSVC_DLL, which resolves as \"$path\", is not found." "$LINENO" 5 57650 fi 57651 57652 if test -d "$path"; then 57653 MSVC_DLL="`cd "$path"; $THEPWDCMD -L`" 57654 else 57655 dir="`$DIRNAME "$path"`" 57656 base="`$BASENAME "$path"`" 57657 MSVC_DLL="`cd "$dir"; $THEPWDCMD -L`/$base" 57658 fi 57659 fi 57660 fi 57661 57662 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $DLL_NAME" >&5 57663 $as_echo_n "checking for $DLL_NAME... " >&6; } 57664 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MSVC_DLL" >&5 57665 $as_echo "$MSVC_DLL" >&6; } 57666 else 57667 { $as_echo "$as_me:${as_lineno-$LINENO}: result: incorrect, ignoring" >&5 57668 $as_echo "incorrect, ignoring" >&6; } 57669 { $as_echo "$as_me:${as_lineno-$LINENO}: The file type of the located $DLL_NAME is $MSVC_DLL_FILETYPE" >&5 57670 $as_echo "$as_me: The file type of the located $DLL_NAME is $MSVC_DLL_FILETYPE" >&6;} 57671 fi 57672 fi 57673 57674 fi 57675 57676 if test "x$MSVC_DLL" = x; then 57677 # Probe: Look in the Windows system32 directory 57678 CYGWIN_SYSTEMROOT="$SYSTEMROOT" 57679 57680 windows_path="$CYGWIN_SYSTEMROOT" 57681 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 57682 unix_path=`$CYGPATH -u "$windows_path"` 57683 CYGWIN_SYSTEMROOT="$unix_path" 57684 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 57685 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 57686 CYGWIN_SYSTEMROOT="$unix_path" 57687 fi 57688 57689 POSSIBLE_MSVC_DLL="$CYGWIN_SYSTEMROOT/system32/$DLL_NAME" 57690 57691 DLL_NAME="$DLL_NAME" 57692 POSSIBLE_MSVC_DLL="$POSSIBLE_MSVC_DLL" 57693 METHOD="well-known location in SYSTEMROOT" 57694 if test -n "$POSSIBLE_MSVC_DLL" -a -e "$POSSIBLE_MSVC_DLL"; then 57695 { $as_echo "$as_me:${as_lineno-$LINENO}: Found $DLL_NAME at $POSSIBLE_MSVC_DLL using $METHOD" >&5 57696 $as_echo "$as_me: Found $DLL_NAME at $POSSIBLE_MSVC_DLL using $METHOD" >&6;} 57697 57698 # Need to check if the found msvcr is correct architecture 57699 { $as_echo "$as_me:${as_lineno-$LINENO}: checking found $DLL_NAME architecture" >&5 57700 $as_echo_n "checking found $DLL_NAME architecture... " >&6; } 57701 MSVC_DLL_FILETYPE=`$FILE -b "$POSSIBLE_MSVC_DLL"` 57702 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 57703 # The MSYS 'file' command returns "PE32 executable for MS Windows (DLL) (GUI) Intel 80386 32-bit" 57704 # on x32 and "PE32+ executable for MS Windows (DLL) (GUI) Mono/.Net assembly" on x64 systems. 57705 if test "x$OPENJDK_TARGET_CPU_BITS" = x32; then 57706 CORRECT_MSVCR_ARCH="PE32 executable" 57707 else 57708 CORRECT_MSVCR_ARCH="PE32+ executable" 57709 fi 57710 else 57711 if test "x$OPENJDK_TARGET_CPU_BITS" = x32; then 57712 CORRECT_MSVCR_ARCH=386 57713 else 57714 CORRECT_MSVCR_ARCH=x86-64 57715 fi 57716 fi 57717 if $ECHO "$MSVC_DLL_FILETYPE" | $GREP "$CORRECT_MSVCR_ARCH" 2>&1 > /dev/null; then 57718 { $as_echo "$as_me:${as_lineno-$LINENO}: result: ok" >&5 57719 $as_echo "ok" >&6; } 57720 MSVC_DLL="$POSSIBLE_MSVC_DLL" 57721 57722 # Only process if variable expands to non-empty 57723 57724 if test "x$MSVC_DLL" != x; then 57725 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 57726 57727 # Input might be given as Windows format, start by converting to 57728 # unix format. 57729 path="$MSVC_DLL" 57730 new_path=`$CYGPATH -u "$path"` 57731 57732 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 57733 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 57734 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 57735 # "foo.exe" is OK but "foo" is an error. 57736 # 57737 # This test is therefore slightly more accurate than "test -f" to check for file precense. 57738 # It is also a way to make sure we got the proper file name for the real test later on. 57739 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 57740 if test "x$test_shortpath" = x; then 57741 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of MSVC_DLL, which resolves as \"$path\", is invalid." >&5 57742 $as_echo "$as_me: The path of MSVC_DLL, which resolves as \"$path\", is invalid." >&6;} 57743 as_fn_error $? "Cannot locate the the path of MSVC_DLL" "$LINENO" 5 57744 fi 57745 57746 # Call helper function which possibly converts this using DOS-style short mode. 57747 # If so, the updated path is stored in $new_path. 57748 57749 input_path="$new_path" 57750 # Check if we need to convert this using DOS-style short mode. If the path 57751 # contains just simple characters, use it. Otherwise (spaces, weird characters), 57752 # take no chances and rewrite it. 57753 # Note: m4 eats our [], so we need to use [ and ] instead. 57754 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 57755 if test "x$has_forbidden_chars" != x; then 57756 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 57757 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 57758 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 57759 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 57760 # Going to short mode and back again did indeed matter. Since short mode is 57761 # case insensitive, let's make it lowercase to improve readability. 57762 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 57763 # Now convert it back to Unix-style (cygpath) 57764 input_path=`$CYGPATH -u "$shortmode_path"` 57765 new_path="$input_path" 57766 fi 57767 fi 57768 57769 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 57770 if test "x$test_cygdrive_prefix" = x; then 57771 # As a simple fix, exclude /usr/bin since it's not a real path. 57772 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 57773 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 57774 # a path prefixed by /cygdrive for fixpath to work. 57775 new_path="$CYGWIN_ROOT_PATH$input_path" 57776 fi 57777 fi 57778 57779 57780 if test "x$path" != "x$new_path"; then 57781 MSVC_DLL="$new_path" 57782 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting MSVC_DLL to \"$new_path\"" >&5 57783 $as_echo "$as_me: Rewriting MSVC_DLL to \"$new_path\"" >&6;} 57784 fi 57785 57786 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 57787 57788 path="$MSVC_DLL" 57789 has_colon=`$ECHO $path | $GREP ^.:` 57790 new_path="$path" 57791 if test "x$has_colon" = x; then 57792 # Not in mixed or Windows style, start by that. 57793 new_path=`cmd //c echo $path` 57794 fi 57795 57796 57797 input_path="$new_path" 57798 # Check if we need to convert this using DOS-style short mode. If the path 57799 # contains just simple characters, use it. Otherwise (spaces, weird characters), 57800 # take no chances and rewrite it. 57801 # Note: m4 eats our [], so we need to use [ and ] instead. 57802 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 57803 if test "x$has_forbidden_chars" != x; then 57804 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 57805 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 57806 fi 57807 57808 57809 windows_path="$new_path" 57810 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 57811 unix_path=`$CYGPATH -u "$windows_path"` 57812 new_path="$unix_path" 57813 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 57814 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 57815 new_path="$unix_path" 57816 fi 57817 57818 if test "x$path" != "x$new_path"; then 57819 MSVC_DLL="$new_path" 57820 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting MSVC_DLL to \"$new_path\"" >&5 57821 $as_echo "$as_me: Rewriting MSVC_DLL to \"$new_path\"" >&6;} 57822 fi 57823 57824 # Save the first 10 bytes of this path to the storage, so fixpath can work. 57825 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 57826 57827 else 57828 # We're on a unix platform. Hooray! :) 57829 path="$MSVC_DLL" 57830 has_space=`$ECHO "$path" | $GREP " "` 57831 if test "x$has_space" != x; then 57832 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of MSVC_DLL, which resolves as \"$path\", is invalid." >&5 57833 $as_echo "$as_me: The path of MSVC_DLL, which resolves as \"$path\", is invalid." >&6;} 57834 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 57835 fi 57836 57837 # Use eval to expand a potential ~ 57838 eval path="$path" 57839 if test ! -f "$path" && test ! -d "$path"; then 57840 as_fn_error $? "The path of MSVC_DLL, which resolves as \"$path\", is not found." "$LINENO" 5 57841 fi 57842 57843 if test -d "$path"; then 57844 MSVC_DLL="`cd "$path"; $THEPWDCMD -L`" 57845 else 57846 dir="`$DIRNAME "$path"`" 57847 base="`$BASENAME "$path"`" 57848 MSVC_DLL="`cd "$dir"; $THEPWDCMD -L`/$base" 57849 fi 57850 fi 57851 fi 57852 57853 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $DLL_NAME" >&5 57854 $as_echo_n "checking for $DLL_NAME... " >&6; } 57855 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MSVC_DLL" >&5 57856 $as_echo "$MSVC_DLL" >&6; } 57857 else 57858 { $as_echo "$as_me:${as_lineno-$LINENO}: result: incorrect, ignoring" >&5 57859 $as_echo "incorrect, ignoring" >&6; } 57860 { $as_echo "$as_me:${as_lineno-$LINENO}: The file type of the located $DLL_NAME is $MSVC_DLL_FILETYPE" >&5 57861 $as_echo "$as_me: The file type of the located $DLL_NAME is $MSVC_DLL_FILETYPE" >&6;} 57862 fi 57863 fi 57864 57865 fi 57866 57867 if test "x$MSVC_DLL" = x; then 57868 # Probe: If Visual Studio Express is installed, there is usually one with the debugger 57869 if test "x$VS100COMNTOOLS" != x; then 57870 CYGWIN_VS_TOOLS_DIR="$VS100COMNTOOLS/.." 57871 57872 windows_path="$CYGWIN_VS_TOOLS_DIR" 57873 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 57874 unix_path=`$CYGPATH -u "$windows_path"` 57875 CYGWIN_VS_TOOLS_DIR="$unix_path" 57876 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 57877 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 57878 CYGWIN_VS_TOOLS_DIR="$unix_path" 57879 fi 57880 57881 if test "x$OPENJDK_TARGET_CPU_BITS" = x64; then 57882 POSSIBLE_MSVC_DLL=`$FIND "$CYGWIN_VS_TOOLS_DIR" -name $DLL_NAME \ 57883 | $GREP -i /x64/ | $HEAD --lines 1` 57884 else 57885 POSSIBLE_MSVC_DLL=`$FIND "$CYGWIN_VS_TOOLS_DIR" -name $DLL_NAME \ 57886 | $GREP -i /x86/ | $HEAD --lines 1` 57887 fi 57888 57889 DLL_NAME="$DLL_NAME" 57890 POSSIBLE_MSVC_DLL="$POSSIBLE_MSVC_DLL" 57891 METHOD="search of VS100COMNTOOLS" 57892 if test -n "$POSSIBLE_MSVC_DLL" -a -e "$POSSIBLE_MSVC_DLL"; then 57893 { $as_echo "$as_me:${as_lineno-$LINENO}: Found $DLL_NAME at $POSSIBLE_MSVC_DLL using $METHOD" >&5 57894 $as_echo "$as_me: Found $DLL_NAME at $POSSIBLE_MSVC_DLL using $METHOD" >&6;} 57895 57896 # Need to check if the found msvcr is correct architecture 57897 { $as_echo "$as_me:${as_lineno-$LINENO}: checking found $DLL_NAME architecture" >&5 57898 $as_echo_n "checking found $DLL_NAME architecture... " >&6; } 57899 MSVC_DLL_FILETYPE=`$FILE -b "$POSSIBLE_MSVC_DLL"` 57900 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 57901 # The MSYS 'file' command returns "PE32 executable for MS Windows (DLL) (GUI) Intel 80386 32-bit" 57902 # on x32 and "PE32+ executable for MS Windows (DLL) (GUI) Mono/.Net assembly" on x64 systems. 57903 if test "x$OPENJDK_TARGET_CPU_BITS" = x32; then 57904 CORRECT_MSVCR_ARCH="PE32 executable" 57905 else 57906 CORRECT_MSVCR_ARCH="PE32+ executable" 57907 fi 57908 else 57909 if test "x$OPENJDK_TARGET_CPU_BITS" = x32; then 57910 CORRECT_MSVCR_ARCH=386 57911 else 57912 CORRECT_MSVCR_ARCH=x86-64 57913 fi 57914 fi 57915 if $ECHO "$MSVC_DLL_FILETYPE" | $GREP "$CORRECT_MSVCR_ARCH" 2>&1 > /dev/null; then 57916 { $as_echo "$as_me:${as_lineno-$LINENO}: result: ok" >&5 57917 $as_echo "ok" >&6; } 57918 MSVC_DLL="$POSSIBLE_MSVC_DLL" 57919 57920 # Only process if variable expands to non-empty 57921 57922 if test "x$MSVC_DLL" != x; then 57923 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 57924 57925 # Input might be given as Windows format, start by converting to 57926 # unix format. 57927 path="$MSVC_DLL" 57928 new_path=`$CYGPATH -u "$path"` 57929 57930 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 57931 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 57932 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 57933 # "foo.exe" is OK but "foo" is an error. 57934 # 57935 # This test is therefore slightly more accurate than "test -f" to check for file precense. 57936 # It is also a way to make sure we got the proper file name for the real test later on. 57937 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 57938 if test "x$test_shortpath" = x; then 57939 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of MSVC_DLL, which resolves as \"$path\", is invalid." >&5 57940 $as_echo "$as_me: The path of MSVC_DLL, which resolves as \"$path\", is invalid." >&6;} 57941 as_fn_error $? "Cannot locate the the path of MSVC_DLL" "$LINENO" 5 57942 fi 57943 57944 # Call helper function which possibly converts this using DOS-style short mode. 57945 # If so, the updated path is stored in $new_path. 57946 57947 input_path="$new_path" 57948 # Check if we need to convert this using DOS-style short mode. If the path 57949 # contains just simple characters, use it. Otherwise (spaces, weird characters), 57950 # take no chances and rewrite it. 57951 # Note: m4 eats our [], so we need to use [ and ] instead. 57952 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 57953 if test "x$has_forbidden_chars" != x; then 57954 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 57955 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 57956 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 57957 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 57958 # Going to short mode and back again did indeed matter. Since short mode is 57959 # case insensitive, let's make it lowercase to improve readability. 57960 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 57961 # Now convert it back to Unix-style (cygpath) 57962 input_path=`$CYGPATH -u "$shortmode_path"` 57963 new_path="$input_path" 57964 fi 57965 fi 57966 57967 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 57968 if test "x$test_cygdrive_prefix" = x; then 57969 # As a simple fix, exclude /usr/bin since it's not a real path. 57970 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 57971 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 57972 # a path prefixed by /cygdrive for fixpath to work. 57973 new_path="$CYGWIN_ROOT_PATH$input_path" 57974 fi 57975 fi 57976 57977 57978 if test "x$path" != "x$new_path"; then 57979 MSVC_DLL="$new_path" 57980 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting MSVC_DLL to \"$new_path\"" >&5 57981 $as_echo "$as_me: Rewriting MSVC_DLL to \"$new_path\"" >&6;} 57982 fi 57983 57984 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 57985 57986 path="$MSVC_DLL" 57987 has_colon=`$ECHO $path | $GREP ^.:` 57988 new_path="$path" 57989 if test "x$has_colon" = x; then 57990 # Not in mixed or Windows style, start by that. 57991 new_path=`cmd //c echo $path` 57992 fi 57993 57994 57995 input_path="$new_path" 57996 # Check if we need to convert this using DOS-style short mode. If the path 57997 # contains just simple characters, use it. Otherwise (spaces, weird characters), 57998 # take no chances and rewrite it. 57999 # Note: m4 eats our [], so we need to use [ and ] instead. 58000 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 58001 if test "x$has_forbidden_chars" != x; then 58002 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 58003 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 58004 fi 58005 58006 58007 windows_path="$new_path" 58008 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 58009 unix_path=`$CYGPATH -u "$windows_path"` 58010 new_path="$unix_path" 58011 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 58012 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 58013 new_path="$unix_path" 58014 fi 58015 58016 if test "x$path" != "x$new_path"; then 58017 MSVC_DLL="$new_path" 58018 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting MSVC_DLL to \"$new_path\"" >&5 58019 $as_echo "$as_me: Rewriting MSVC_DLL to \"$new_path\"" >&6;} 58020 fi 58021 58022 # Save the first 10 bytes of this path to the storage, so fixpath can work. 58023 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 58024 58025 else 58026 # We're on a unix platform. Hooray! :) 58027 path="$MSVC_DLL" 58028 has_space=`$ECHO "$path" | $GREP " "` 58029 if test "x$has_space" != x; then 58030 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of MSVC_DLL, which resolves as \"$path\", is invalid." >&5 58031 $as_echo "$as_me: The path of MSVC_DLL, which resolves as \"$path\", is invalid." >&6;} 58032 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 58033 fi 58034 58035 # Use eval to expand a potential ~ 58036 eval path="$path" 58037 if test ! -f "$path" && test ! -d "$path"; then 58038 as_fn_error $? "The path of MSVC_DLL, which resolves as \"$path\", is not found." "$LINENO" 5 58039 fi 58040 58041 if test -d "$path"; then 58042 MSVC_DLL="`cd "$path"; $THEPWDCMD -L`" 58043 else 58044 dir="`$DIRNAME "$path"`" 58045 base="`$BASENAME "$path"`" 58046 MSVC_DLL="`cd "$dir"; $THEPWDCMD -L`/$base" 58047 fi 58048 fi 58049 fi 58050 58051 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $DLL_NAME" >&5 58052 $as_echo_n "checking for $DLL_NAME... " >&6; } 58053 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MSVC_DLL" >&5 58054 $as_echo "$MSVC_DLL" >&6; } 58055 else 58056 { $as_echo "$as_me:${as_lineno-$LINENO}: result: incorrect, ignoring" >&5 58057 $as_echo "incorrect, ignoring" >&6; } 58058 { $as_echo "$as_me:${as_lineno-$LINENO}: The file type of the located $DLL_NAME is $MSVC_DLL_FILETYPE" >&5 58059 $as_echo "$as_me: The file type of the located $DLL_NAME is $MSVC_DLL_FILETYPE" >&6;} 58060 fi 58061 fi 58062 58063 fi 58064 fi 58065 58066 if test "x$MSVC_DLL" = x; then 58067 # Probe: Search wildly in the VCINSTALLDIR. We've probably lost by now. 58068 # (This was the original behaviour; kept since it might turn something up) 58069 if test "x$CYGWIN_VC_INSTALL_DIR" != x; then 58070 if test "x$OPENJDK_TARGET_CPU_BITS" = x64; then 58071 POSSIBLE_MSVC_DLL=`$FIND "$CYGWIN_VC_INSTALL_DIR" -name $DLL_NAME \ 58072 | $GREP x64 | $HEAD --lines 1` 58073 else 58074 POSSIBLE_MSVC_DLL=`$FIND "$CYGWIN_VC_INSTALL_DIR" -name $DLL_NAME \ 58075 | $GREP x86 | $GREP -v ia64 | $GREP -v x64 | $HEAD --lines 1` 58076 if test "x$POSSIBLE_MSVC_DLL" = x; then 58077 # We're grasping at straws now... 58078 POSSIBLE_MSVC_DLL=`$FIND "$CYGWIN_VC_INSTALL_DIR" -name $DLL_NAME \ 58079 | $HEAD --lines 1` 58080 fi 58081 fi 58082 58083 58084 DLL_NAME="$DLL_NAME" 58085 POSSIBLE_MSVC_DLL="$POSSIBLE_MSVC_DLL" 58086 METHOD="search of VCINSTALLDIR" 58087 if test -n "$POSSIBLE_MSVC_DLL" -a -e "$POSSIBLE_MSVC_DLL"; then 58088 { $as_echo "$as_me:${as_lineno-$LINENO}: Found $DLL_NAME at $POSSIBLE_MSVC_DLL using $METHOD" >&5 58089 $as_echo "$as_me: Found $DLL_NAME at $POSSIBLE_MSVC_DLL using $METHOD" >&6;} 58090 58091 # Need to check if the found msvcr is correct architecture 58092 { $as_echo "$as_me:${as_lineno-$LINENO}: checking found $DLL_NAME architecture" >&5 58093 $as_echo_n "checking found $DLL_NAME architecture... " >&6; } 58094 MSVC_DLL_FILETYPE=`$FILE -b "$POSSIBLE_MSVC_DLL"` 58095 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 58096 # The MSYS 'file' command returns "PE32 executable for MS Windows (DLL) (GUI) Intel 80386 32-bit" 58097 # on x32 and "PE32+ executable for MS Windows (DLL) (GUI) Mono/.Net assembly" on x64 systems. 58098 if test "x$OPENJDK_TARGET_CPU_BITS" = x32; then 58099 CORRECT_MSVCR_ARCH="PE32 executable" 58100 else 58101 CORRECT_MSVCR_ARCH="PE32+ executable" 58102 fi 58103 else 58104 if test "x$OPENJDK_TARGET_CPU_BITS" = x32; then 58105 CORRECT_MSVCR_ARCH=386 58106 else 58107 CORRECT_MSVCR_ARCH=x86-64 58108 fi 58109 fi 58110 if $ECHO "$MSVC_DLL_FILETYPE" | $GREP "$CORRECT_MSVCR_ARCH" 2>&1 > /dev/null; then 58111 { $as_echo "$as_me:${as_lineno-$LINENO}: result: ok" >&5 58112 $as_echo "ok" >&6; } 58113 MSVC_DLL="$POSSIBLE_MSVC_DLL" 58114 58115 # Only process if variable expands to non-empty 58116 58117 if test "x$MSVC_DLL" != x; then 58118 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 58119 58120 # Input might be given as Windows format, start by converting to 58121 # unix format. 58122 path="$MSVC_DLL" 58123 new_path=`$CYGPATH -u "$path"` 58124 58125 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 58126 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 58127 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 58128 # "foo.exe" is OK but "foo" is an error. 58129 # 58130 # This test is therefore slightly more accurate than "test -f" to check for file precense. 58131 # It is also a way to make sure we got the proper file name for the real test later on. 58132 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 58133 if test "x$test_shortpath" = x; then 58134 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of MSVC_DLL, which resolves as \"$path\", is invalid." >&5 58135 $as_echo "$as_me: The path of MSVC_DLL, which resolves as \"$path\", is invalid." >&6;} 58136 as_fn_error $? "Cannot locate the the path of MSVC_DLL" "$LINENO" 5 58137 fi 58138 58139 # Call helper function which possibly converts this using DOS-style short mode. 58140 # If so, the updated path is stored in $new_path. 58141 58142 input_path="$new_path" 58143 # Check if we need to convert this using DOS-style short mode. If the path 58144 # contains just simple characters, use it. Otherwise (spaces, weird characters), 58145 # take no chances and rewrite it. 58146 # Note: m4 eats our [], so we need to use [ and ] instead. 58147 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 58148 if test "x$has_forbidden_chars" != x; then 58149 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 58150 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 58151 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 58152 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 58153 # Going to short mode and back again did indeed matter. Since short mode is 58154 # case insensitive, let's make it lowercase to improve readability. 58155 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 58156 # Now convert it back to Unix-style (cygpath) 58157 input_path=`$CYGPATH -u "$shortmode_path"` 58158 new_path="$input_path" 58159 fi 58160 fi 58161 58162 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 58163 if test "x$test_cygdrive_prefix" = x; then 58164 # As a simple fix, exclude /usr/bin since it's not a real path. 58165 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 58166 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 58167 # a path prefixed by /cygdrive for fixpath to work. 58168 new_path="$CYGWIN_ROOT_PATH$input_path" 58169 fi 58170 fi 58171 58172 58173 if test "x$path" != "x$new_path"; then 58174 MSVC_DLL="$new_path" 58175 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting MSVC_DLL to \"$new_path\"" >&5 58176 $as_echo "$as_me: Rewriting MSVC_DLL to \"$new_path\"" >&6;} 58177 fi 58178 58179 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 58180 58181 path="$MSVC_DLL" 58182 has_colon=`$ECHO $path | $GREP ^.:` 58183 new_path="$path" 58184 if test "x$has_colon" = x; then 58185 # Not in mixed or Windows style, start by that. 58186 new_path=`cmd //c echo $path` 58187 fi 58188 58189 58190 input_path="$new_path" 58191 # Check if we need to convert this using DOS-style short mode. If the path 58192 # contains just simple characters, use it. Otherwise (spaces, weird characters), 58193 # take no chances and rewrite it. 58194 # Note: m4 eats our [], so we need to use [ and ] instead. 58195 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 58196 if test "x$has_forbidden_chars" != x; then 58197 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 58198 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 58199 fi 58200 58201 58202 windows_path="$new_path" 58203 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 58204 unix_path=`$CYGPATH -u "$windows_path"` 58205 new_path="$unix_path" 58206 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 58207 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 58208 new_path="$unix_path" 58209 fi 58210 58211 if test "x$path" != "x$new_path"; then 58212 MSVC_DLL="$new_path" 58213 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting MSVC_DLL to \"$new_path\"" >&5 58214 $as_echo "$as_me: Rewriting MSVC_DLL to \"$new_path\"" >&6;} 58215 fi 58216 58217 # Save the first 10 bytes of this path to the storage, so fixpath can work. 58218 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 58219 58220 else 58221 # We're on a unix platform. Hooray! :) 58222 path="$MSVC_DLL" 58223 has_space=`$ECHO "$path" | $GREP " "` 58224 if test "x$has_space" != x; then 58225 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of MSVC_DLL, which resolves as \"$path\", is invalid." >&5 58226 $as_echo "$as_me: The path of MSVC_DLL, which resolves as \"$path\", is invalid." >&6;} 58227 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 58228 fi 58229 58230 # Use eval to expand a potential ~ 58231 eval path="$path" 58232 if test ! -f "$path" && test ! -d "$path"; then 58233 as_fn_error $? "The path of MSVC_DLL, which resolves as \"$path\", is not found." "$LINENO" 5 58234 fi 58235 58236 if test -d "$path"; then 58237 MSVC_DLL="`cd "$path"; $THEPWDCMD -L`" 58238 else 58239 dir="`$DIRNAME "$path"`" 58240 base="`$BASENAME "$path"`" 58241 MSVC_DLL="`cd "$dir"; $THEPWDCMD -L`/$base" 58242 fi 58243 fi 58244 fi 58245 58246 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $DLL_NAME" >&5 58247 $as_echo_n "checking for $DLL_NAME... " >&6; } 58248 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MSVC_DLL" >&5 58249 $as_echo "$MSVC_DLL" >&6; } 58250 else 58251 { $as_echo "$as_me:${as_lineno-$LINENO}: result: incorrect, ignoring" >&5 58252 $as_echo "incorrect, ignoring" >&6; } 58253 { $as_echo "$as_me:${as_lineno-$LINENO}: The file type of the located $DLL_NAME is $MSVC_DLL_FILETYPE" >&5 58254 $as_echo "$as_me: The file type of the located $DLL_NAME is $MSVC_DLL_FILETYPE" >&6;} 58255 fi 58256 fi 58257 58258 fi 58259 fi 58260 58261 if test "x$MSVC_DLL" = x; then 58262 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $DLL_NAME" >&5 58263 $as_echo_n "checking for $DLL_NAME... " >&6; } 58264 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 58265 $as_echo "no" >&6; } 58266 as_fn_error $? "Could not find $DLL_NAME. Please specify using --with-msvcr-dll." "$LINENO" 5 58267 fi 58268 58269 MSVCP_DLL="$MSVC_DLL" 58270 fi 58271 58272 fi 58273 58274 fi 58275 58276 58277 if test "x$NEEDS_LIB_X11" = xfalse; then 58278 if (test "x${with_x}" != x && test "x${with_x}" != xno); then 58279 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: X11 is not used, so --with-x is ignored" >&5 58280 $as_echo "$as_me: WARNING: X11 is not used, so --with-x is ignored" >&2;} 58281 fi 58282 X_CFLAGS= 58283 X_LIBS= 58284 else 58285 58286 if test "x${with_x}" = xno; then 58287 as_fn_error $? "It is not possible to disable the use of X11. Remove the --without-x option." "$LINENO" 5 58288 fi 58289 58290 if test "x${with_x}" != x && test "x${with_x}" != xyes; then 58291 # The user has specified a X11 base directory. Use it for includes and 58292 # libraries, unless explicitly overridden. 58293 if test "x$x_includes" = xNONE; then 58294 x_includes="${with_x}/include" 58295 fi 58296 if test "x$x_libraries" = xNONE; then 58297 x_libraries="${with_x}/lib" 58298 fi 58299 else 58300 # Check if the user has specified sysroot, but not --with-x, --x-includes or --x-libraries. 58301 # Make a simple check for the libraries at the sysroot, and setup --x-includes and 58302 # --x-libraries for the sysroot, if that seems to be correct. 58303 if test "x$SYSROOT" != "x"; then 58304 if test "x$x_includes" = xNONE; then 58305 if test -f "$SYSROOT/usr/X11R6/include/X11/Xlib.h"; then 58306 x_includes="$SYSROOT/usr/X11R6/include" 58307 elif test -f "$SYSROOT/usr/include/X11/Xlib.h"; then 58308 x_includes="$SYSROOT/usr/include" 58309 fi 58310 fi 58311 if test "x$x_libraries" = xNONE; then 58312 if test -f "$SYSROOT/usr/X11R6/lib/libX11.so"; then 58313 x_libraries="$SYSROOT/usr/X11R6/lib" 58314 elif test -f "$SYSROOT/usr/lib64/libX11.so" && test "x$OPENJDK_TARGET_CPU_BITS" = x64; then 58315 x_libraries="$SYSROOT/usr/lib64" 58316 elif test -f "$SYSROOT/usr/lib/libX11.so"; then 58317 x_libraries="$SYSROOT/usr/lib" 58318 fi 58319 fi 58320 fi 58321 fi 58322 58323 # Now let autoconf do it's magic 58324 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for X" >&5 58325 $as_echo_n "checking for X... " >&6; } 58326 58327 58328 # Check whether --with-x was given. 58329 if test "${with_x+set}" = set; then : 58330 withval=$with_x; 58331 fi 58332 58333 # $have_x is `yes', `no', `disabled', or empty when we do not yet know. 58334 if test "x$with_x" = xno; then 58335 # The user explicitly disabled X. 58336 have_x=disabled 58337 else 58338 case $x_includes,$x_libraries in #( 58339 *\'*) as_fn_error $? "cannot use X directory names containing '" "$LINENO" 5;; #( 58340 *,NONE | NONE,*) if ${ac_cv_have_x+:} false; then : 58341 $as_echo_n "(cached) " >&6 58342 else 58343 # One or both of the vars are not set, and there is no cached value. 58344 ac_x_includes=no ac_x_libraries=no 58345 rm -f -r conftest.dir 58346 if mkdir conftest.dir; then 58347 cd conftest.dir 58348 cat >Imakefile <<'_ACEOF' 58349 incroot: 58350 @echo incroot='${INCROOT}' 58351 usrlibdir: 58352 @echo usrlibdir='${USRLIBDIR}' 58353 libdir: 58354 @echo libdir='${LIBDIR}' 58355 _ACEOF 58356 if (export CC; ${XMKMF-xmkmf}) >/dev/null 2>/dev/null && test -f Makefile; then 58357 # GNU make sometimes prints "make[1]: Entering ...", which would confuse us. 58358 for ac_var in incroot usrlibdir libdir; do 58359 eval "ac_im_$ac_var=\`\${MAKE-make} $ac_var 2>/dev/null | sed -n 's/^$ac_var=//p'\`" 58360 done 58361 # Open Windows xmkmf reportedly sets LIBDIR instead of USRLIBDIR. 58362 for ac_extension in a so sl dylib la dll; do 58363 if test ! -f "$ac_im_usrlibdir/libX11.$ac_extension" && 58364 test -f "$ac_im_libdir/libX11.$ac_extension"; then 58365 ac_im_usrlibdir=$ac_im_libdir; break 58366 fi 58367 done 58368 # Screen out bogus values from the imake configuration. They are 58369 # bogus both because they are the default anyway, and because 58370 # using them would break gcc on systems where it needs fixed includes. 58371 case $ac_im_incroot in 58372 /usr/include) ac_x_includes= ;; 58373 *) test -f "$ac_im_incroot/X11/Xos.h" && ac_x_includes=$ac_im_incroot;; 58374 esac 58375 case $ac_im_usrlibdir in 58376 /usr/lib | /usr/lib64 | /lib | /lib64) ;; 58377 *) test -d "$ac_im_usrlibdir" && ac_x_libraries=$ac_im_usrlibdir ;; 58378 esac 58379 fi 58380 cd .. 58381 rm -f -r conftest.dir 58382 fi 58383 58384 # Standard set of common directories for X headers. 58385 # Check X11 before X11Rn because it is often a symlink to the current release. 58386 ac_x_header_dirs=' 58387 /usr/X11/include 58388 /usr/X11R7/include 58389 /usr/X11R6/include 58390 /usr/X11R5/include 58391 /usr/X11R4/include 58392 58393 /usr/include/X11 58394 /usr/include/X11R7 58395 /usr/include/X11R6 58396 /usr/include/X11R5 58397 /usr/include/X11R4 58398 58399 /usr/local/X11/include 58400 /usr/local/X11R7/include 58401 /usr/local/X11R6/include 58402 /usr/local/X11R5/include 58403 /usr/local/X11R4/include 58404 58405 /usr/local/include/X11 58406 /usr/local/include/X11R7 58407 /usr/local/include/X11R6 58408 /usr/local/include/X11R5 58409 /usr/local/include/X11R4 58410 58411 /usr/X386/include 58412 /usr/x386/include 58413 /usr/XFree86/include/X11 58414 58415 /usr/include 58416 /usr/local/include 58417 /usr/unsupported/include 58418 /usr/athena/include 58419 /usr/local/x11r5/include 58420 /usr/lpp/Xamples/include 58421 58422 /usr/openwin/include 58423 /usr/openwin/share/include' 58424 58425 if test "$ac_x_includes" = no; then 58426 # Guess where to find include files, by looking for Xlib.h. 58427 # First, try using that file with no special directory specified. 58428 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 58429 /* end confdefs.h. */ 58430 #include <X11/Xlib.h> 58431 _ACEOF 58432 if ac_fn_cxx_try_cpp "$LINENO"; then : 58433 # We can compile using X headers with no special include directory. 58434 ac_x_includes= 58435 else 58436 for ac_dir in $ac_x_header_dirs; do 58437 if test -r "$ac_dir/X11/Xlib.h"; then 58438 ac_x_includes=$ac_dir 58439 break 58440 fi 58441 done 58442 fi 58443 rm -f conftest.err conftest.i conftest.$ac_ext 58444 fi # $ac_x_includes = no 58445 58446 if test "$ac_x_libraries" = no; then 58447 # Check for the libraries. 58448 # See if we find them without any special options. 58449 # Don't add to $LIBS permanently. 58450 ac_save_LIBS=$LIBS 58451 LIBS="-lX11 $LIBS" 58452 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 58453 /* end confdefs.h. */ 58454 #include <X11/Xlib.h> 58455 int 58456 main () 58457 { 58458 XrmInitialize () 58459 ; 58460 return 0; 58461 } 58462 _ACEOF 58463 if ac_fn_cxx_try_link "$LINENO"; then : 58464 LIBS=$ac_save_LIBS 58465 # We can link X programs with no special library path. 58466 ac_x_libraries= 58467 else 58468 LIBS=$ac_save_LIBS 58469 for ac_dir in `$as_echo "$ac_x_includes $ac_x_header_dirs" | sed s/include/lib/g` 58470 do 58471 # Don't even attempt the hair of trying to link an X program! 58472 for ac_extension in a so sl dylib la dll; do 58473 if test -r "$ac_dir/libX11.$ac_extension"; then 58474 ac_x_libraries=$ac_dir 58475 break 2 58476 fi 58477 done 58478 done 58479 fi 58480 rm -f core conftest.err conftest.$ac_objext \ 58481 conftest$ac_exeext conftest.$ac_ext 58482 fi # $ac_x_libraries = no 58483 58484 case $ac_x_includes,$ac_x_libraries in #( 58485 no,* | *,no | *\'*) 58486 # Didn't find X, or a directory has "'" in its name. 58487 ac_cv_have_x="have_x=no";; #( 58488 *) 58489 # Record where we found X for the cache. 58490 ac_cv_have_x="have_x=yes\ 58491 ac_x_includes='$ac_x_includes'\ 58492 ac_x_libraries='$ac_x_libraries'" 58493 esac 58494 fi 58495 ;; #( 58496 *) have_x=yes;; 58497 esac 58498 eval "$ac_cv_have_x" 58499 fi # $with_x != no 58500 58501 if test "$have_x" != yes; then 58502 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $have_x" >&5 58503 $as_echo "$have_x" >&6; } 58504 no_x=yes 58505 else 58506 # If each of the values was on the command line, it overrides each guess. 58507 test "x$x_includes" = xNONE && x_includes=$ac_x_includes 58508 test "x$x_libraries" = xNONE && x_libraries=$ac_x_libraries 58509 # Update the cache value to reflect the command line values. 58510 ac_cv_have_x="have_x=yes\ 58511 ac_x_includes='$x_includes'\ 58512 ac_x_libraries='$x_libraries'" 58513 { $as_echo "$as_me:${as_lineno-$LINENO}: result: libraries $x_libraries, headers $x_includes" >&5 58514 $as_echo "libraries $x_libraries, headers $x_includes" >&6; } 58515 fi 58516 58517 if test "$no_x" = yes; then 58518 # Not all programs may use this symbol, but it does not hurt to define it. 58519 58520 $as_echo "#define X_DISPLAY_MISSING 1" >>confdefs.h 58521 58522 X_CFLAGS= X_PRE_LIBS= X_LIBS= X_EXTRA_LIBS= 58523 else 58524 if test -n "$x_includes"; then 58525 X_CFLAGS="$X_CFLAGS -I$x_includes" 58526 fi 58527 58528 # It would also be nice to do this for all -L options, not just this one. 58529 if test -n "$x_libraries"; then 58530 X_LIBS="$X_LIBS -L$x_libraries" 58531 # For Solaris; some versions of Sun CC require a space after -R and 58532 # others require no space. Words are not sufficient . . . . 58533 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether -R must be followed by a space" >&5 58534 $as_echo_n "checking whether -R must be followed by a space... " >&6; } 58535 ac_xsave_LIBS=$LIBS; LIBS="$LIBS -R$x_libraries" 58536 ac_xsave_cxx_werror_flag=$ac_cxx_werror_flag 58537 ac_cxx_werror_flag=yes 58538 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 58539 /* end confdefs.h. */ 58540 58541 int 58542 main () 58543 { 58544 58545 ; 58546 return 0; 58547 } 58548 _ACEOF 58549 if ac_fn_cxx_try_link "$LINENO"; then : 58550 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 58551 $as_echo "no" >&6; } 58552 X_LIBS="$X_LIBS -R$x_libraries" 58553 else 58554 LIBS="$ac_xsave_LIBS -R $x_libraries" 58555 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 58556 /* end confdefs.h. */ 58557 58558 int 58559 main () 58560 { 58561 58562 ; 58563 return 0; 58564 } 58565 _ACEOF 58566 if ac_fn_cxx_try_link "$LINENO"; then : 58567 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 58568 $as_echo "yes" >&6; } 58569 X_LIBS="$X_LIBS -R $x_libraries" 58570 else 58571 { $as_echo "$as_me:${as_lineno-$LINENO}: result: neither works" >&5 58572 $as_echo "neither works" >&6; } 58573 fi 58574 rm -f core conftest.err conftest.$ac_objext \ 58575 conftest$ac_exeext conftest.$ac_ext 58576 fi 58577 rm -f core conftest.err conftest.$ac_objext \ 58578 conftest$ac_exeext conftest.$ac_ext 58579 ac_cxx_werror_flag=$ac_xsave_cxx_werror_flag 58580 LIBS=$ac_xsave_LIBS 58581 fi 58582 58583 # Check for system-dependent libraries X programs must link with. 58584 # Do this before checking for the system-independent R6 libraries 58585 # (-lICE), since we may need -lsocket or whatever for X linking. 58586 58587 if test "$ISC" = yes; then 58588 X_EXTRA_LIBS="$X_EXTRA_LIBS -lnsl_s -linet" 58589 else 58590 # Martyn Johnson says this is needed for Ultrix, if the X 58591 # libraries were built with DECnet support. And Karl Berry says 58592 # the Alpha needs dnet_stub (dnet does not exist). 58593 ac_xsave_LIBS="$LIBS"; LIBS="$LIBS $X_LIBS -lX11" 58594 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 58595 /* end confdefs.h. */ 58596 58597 /* Override any GCC internal prototype to avoid an error. 58598 Use char because int might match the return type of a GCC 58599 builtin and then its argument prototype would still apply. */ 58600 #ifdef __cplusplus 58601 extern "C" 58602 #endif 58603 char XOpenDisplay (); 58604 int 58605 main () 58606 { 58607 return XOpenDisplay (); 58608 ; 58609 return 0; 58610 } 58611 _ACEOF 58612 if ac_fn_cxx_try_link "$LINENO"; then : 58613 58614 else 58615 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for dnet_ntoa in -ldnet" >&5 58616 $as_echo_n "checking for dnet_ntoa in -ldnet... " >&6; } 58617 if ${ac_cv_lib_dnet_dnet_ntoa+:} false; then : 58618 $as_echo_n "(cached) " >&6 58619 else 58620 ac_check_lib_save_LIBS=$LIBS 58621 LIBS="-ldnet $LIBS" 58622 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 58623 /* end confdefs.h. */ 58624 58625 /* Override any GCC internal prototype to avoid an error. 58626 Use char because int might match the return type of a GCC 58627 builtin and then its argument prototype would still apply. */ 58628 #ifdef __cplusplus 58629 extern "C" 58630 #endif 58631 char dnet_ntoa (); 58632 int 58633 main () 58634 { 58635 return dnet_ntoa (); 58636 ; 58637 return 0; 58638 } 58639 _ACEOF 58640 if ac_fn_cxx_try_link "$LINENO"; then : 58641 ac_cv_lib_dnet_dnet_ntoa=yes 58642 else 58643 ac_cv_lib_dnet_dnet_ntoa=no 58644 fi 58645 rm -f core conftest.err conftest.$ac_objext \ 58646 conftest$ac_exeext conftest.$ac_ext 58647 LIBS=$ac_check_lib_save_LIBS 58648 fi 58649 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_dnet_dnet_ntoa" >&5 58650 $as_echo "$ac_cv_lib_dnet_dnet_ntoa" >&6; } 58651 if test "x$ac_cv_lib_dnet_dnet_ntoa" = xyes; then : 58652 X_EXTRA_LIBS="$X_EXTRA_LIBS -ldnet" 58653 fi 58654 58655 if test $ac_cv_lib_dnet_dnet_ntoa = no; then 58656 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for dnet_ntoa in -ldnet_stub" >&5 58657 $as_echo_n "checking for dnet_ntoa in -ldnet_stub... " >&6; } 58658 if ${ac_cv_lib_dnet_stub_dnet_ntoa+:} false; then : 58659 $as_echo_n "(cached) " >&6 58660 else 58661 ac_check_lib_save_LIBS=$LIBS 58662 LIBS="-ldnet_stub $LIBS" 58663 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 58664 /* end confdefs.h. */ 58665 58666 /* Override any GCC internal prototype to avoid an error. 58667 Use char because int might match the return type of a GCC 58668 builtin and then its argument prototype would still apply. */ 58669 #ifdef __cplusplus 58670 extern "C" 58671 #endif 58672 char dnet_ntoa (); 58673 int 58674 main () 58675 { 58676 return dnet_ntoa (); 58677 ; 58678 return 0; 58679 } 58680 _ACEOF 58681 if ac_fn_cxx_try_link "$LINENO"; then : 58682 ac_cv_lib_dnet_stub_dnet_ntoa=yes 58683 else 58684 ac_cv_lib_dnet_stub_dnet_ntoa=no 58685 fi 58686 rm -f core conftest.err conftest.$ac_objext \ 58687 conftest$ac_exeext conftest.$ac_ext 58688 LIBS=$ac_check_lib_save_LIBS 58689 fi 58690 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_dnet_stub_dnet_ntoa" >&5 58691 $as_echo "$ac_cv_lib_dnet_stub_dnet_ntoa" >&6; } 58692 if test "x$ac_cv_lib_dnet_stub_dnet_ntoa" = xyes; then : 58693 X_EXTRA_LIBS="$X_EXTRA_LIBS -ldnet_stub" 58694 fi 58695 58696 fi 58697 fi 58698 rm -f core conftest.err conftest.$ac_objext \ 58699 conftest$ac_exeext conftest.$ac_ext 58700 LIBS="$ac_xsave_LIBS" 58701 58702 # msh@cis.ufl.edu says -lnsl (and -lsocket) are needed for his 386/AT, 58703 # to get the SysV transport functions. 58704 # Chad R. Larson says the Pyramis MIS-ES running DC/OSx (SVR4) 58705 # needs -lnsl. 58706 # The nsl library prevents programs from opening the X display 58707 # on Irix 5.2, according to T.E. Dickey. 58708 # The functions gethostbyname, getservbyname, and inet_addr are 58709 # in -lbsd on LynxOS 3.0.1/i386, according to Lars Hecking. 58710 ac_fn_cxx_check_func "$LINENO" "gethostbyname" "ac_cv_func_gethostbyname" 58711 if test "x$ac_cv_func_gethostbyname" = xyes; then : 58712 58713 fi 58714 58715 if test $ac_cv_func_gethostbyname = no; then 58716 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for gethostbyname in -lnsl" >&5 58717 $as_echo_n "checking for gethostbyname in -lnsl... " >&6; } 58718 if ${ac_cv_lib_nsl_gethostbyname+:} false; then : 58719 $as_echo_n "(cached) " >&6 58720 else 58721 ac_check_lib_save_LIBS=$LIBS 58722 LIBS="-lnsl $LIBS" 58723 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 58724 /* end confdefs.h. */ 58725 58726 /* Override any GCC internal prototype to avoid an error. 58727 Use char because int might match the return type of a GCC 58728 builtin and then its argument prototype would still apply. */ 58729 #ifdef __cplusplus 58730 extern "C" 58731 #endif 58732 char gethostbyname (); 58733 int 58734 main () 58735 { 58736 return gethostbyname (); 58737 ; 58738 return 0; 58739 } 58740 _ACEOF 58741 if ac_fn_cxx_try_link "$LINENO"; then : 58742 ac_cv_lib_nsl_gethostbyname=yes 58743 else 58744 ac_cv_lib_nsl_gethostbyname=no 58745 fi 58746 rm -f core conftest.err conftest.$ac_objext \ 58747 conftest$ac_exeext conftest.$ac_ext 58748 LIBS=$ac_check_lib_save_LIBS 58749 fi 58750 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_nsl_gethostbyname" >&5 58751 $as_echo "$ac_cv_lib_nsl_gethostbyname" >&6; } 58752 if test "x$ac_cv_lib_nsl_gethostbyname" = xyes; then : 58753 X_EXTRA_LIBS="$X_EXTRA_LIBS -lnsl" 58754 fi 58755 58756 if test $ac_cv_lib_nsl_gethostbyname = no; then 58757 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for gethostbyname in -lbsd" >&5 58758 $as_echo_n "checking for gethostbyname in -lbsd... " >&6; } 58759 if ${ac_cv_lib_bsd_gethostbyname+:} false; then : 58760 $as_echo_n "(cached) " >&6 58761 else 58762 ac_check_lib_save_LIBS=$LIBS 58763 LIBS="-lbsd $LIBS" 58764 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 58765 /* end confdefs.h. */ 58766 58767 /* Override any GCC internal prototype to avoid an error. 58768 Use char because int might match the return type of a GCC 58769 builtin and then its argument prototype would still apply. */ 58770 #ifdef __cplusplus 58771 extern "C" 58772 #endif 58773 char gethostbyname (); 58774 int 58775 main () 58776 { 58777 return gethostbyname (); 58778 ; 58779 return 0; 58780 } 58781 _ACEOF 58782 if ac_fn_cxx_try_link "$LINENO"; then : 58783 ac_cv_lib_bsd_gethostbyname=yes 58784 else 58785 ac_cv_lib_bsd_gethostbyname=no 58786 fi 58787 rm -f core conftest.err conftest.$ac_objext \ 58788 conftest$ac_exeext conftest.$ac_ext 58789 LIBS=$ac_check_lib_save_LIBS 58790 fi 58791 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_bsd_gethostbyname" >&5 58792 $as_echo "$ac_cv_lib_bsd_gethostbyname" >&6; } 58793 if test "x$ac_cv_lib_bsd_gethostbyname" = xyes; then : 58794 X_EXTRA_LIBS="$X_EXTRA_LIBS -lbsd" 58795 fi 58796 58797 fi 58798 fi 58799 58800 # lieder@skyler.mavd.honeywell.com says without -lsocket, 58801 # socket/setsockopt and other routines are undefined under SCO ODT 58802 # 2.0. But -lsocket is broken on IRIX 5.2 (and is not necessary 58803 # on later versions), says Simon Leinen: it contains gethostby* 58804 # variants that don't use the name server (or something). -lsocket 58805 # must be given before -lnsl if both are needed. We assume that 58806 # if connect needs -lnsl, so does gethostbyname. 58807 ac_fn_cxx_check_func "$LINENO" "connect" "ac_cv_func_connect" 58808 if test "x$ac_cv_func_connect" = xyes; then : 58809 58810 fi 58811 58812 if test $ac_cv_func_connect = no; then 58813 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for connect in -lsocket" >&5 58814 $as_echo_n "checking for connect in -lsocket... " >&6; } 58815 if ${ac_cv_lib_socket_connect+:} false; then : 58816 $as_echo_n "(cached) " >&6 58817 else 58818 ac_check_lib_save_LIBS=$LIBS 58819 LIBS="-lsocket $X_EXTRA_LIBS $LIBS" 58820 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 58821 /* end confdefs.h. */ 58822 58823 /* Override any GCC internal prototype to avoid an error. 58824 Use char because int might match the return type of a GCC 58825 builtin and then its argument prototype would still apply. */ 58826 #ifdef __cplusplus 58827 extern "C" 58828 #endif 58829 char connect (); 58830 int 58831 main () 58832 { 58833 return connect (); 58834 ; 58835 return 0; 58836 } 58837 _ACEOF 58838 if ac_fn_cxx_try_link "$LINENO"; then : 58839 ac_cv_lib_socket_connect=yes 58840 else 58841 ac_cv_lib_socket_connect=no 58842 fi 58843 rm -f core conftest.err conftest.$ac_objext \ 58844 conftest$ac_exeext conftest.$ac_ext 58845 LIBS=$ac_check_lib_save_LIBS 58846 fi 58847 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_socket_connect" >&5 58848 $as_echo "$ac_cv_lib_socket_connect" >&6; } 58849 if test "x$ac_cv_lib_socket_connect" = xyes; then : 58850 X_EXTRA_LIBS="-lsocket $X_EXTRA_LIBS" 58851 fi 58852 58853 fi 58854 58855 # Guillermo Gomez says -lposix is necessary on A/UX. 58856 ac_fn_cxx_check_func "$LINENO" "remove" "ac_cv_func_remove" 58857 if test "x$ac_cv_func_remove" = xyes; then : 58858 58859 fi 58860 58861 if test $ac_cv_func_remove = no; then 58862 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for remove in -lposix" >&5 58863 $as_echo_n "checking for remove in -lposix... " >&6; } 58864 if ${ac_cv_lib_posix_remove+:} false; then : 58865 $as_echo_n "(cached) " >&6 58866 else 58867 ac_check_lib_save_LIBS=$LIBS 58868 LIBS="-lposix $LIBS" 58869 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 58870 /* end confdefs.h. */ 58871 58872 /* Override any GCC internal prototype to avoid an error. 58873 Use char because int might match the return type of a GCC 58874 builtin and then its argument prototype would still apply. */ 58875 #ifdef __cplusplus 58876 extern "C" 58877 #endif 58878 char remove (); 58879 int 58880 main () 58881 { 58882 return remove (); 58883 ; 58884 return 0; 58885 } 58886 _ACEOF 58887 if ac_fn_cxx_try_link "$LINENO"; then : 58888 ac_cv_lib_posix_remove=yes 58889 else 58890 ac_cv_lib_posix_remove=no 58891 fi 58892 rm -f core conftest.err conftest.$ac_objext \ 58893 conftest$ac_exeext conftest.$ac_ext 58894 LIBS=$ac_check_lib_save_LIBS 58895 fi 58896 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_posix_remove" >&5 58897 $as_echo "$ac_cv_lib_posix_remove" >&6; } 58898 if test "x$ac_cv_lib_posix_remove" = xyes; then : 58899 X_EXTRA_LIBS="$X_EXTRA_LIBS -lposix" 58900 fi 58901 58902 fi 58903 58904 # BSDI BSD/OS 2.1 needs -lipc for XOpenDisplay. 58905 ac_fn_cxx_check_func "$LINENO" "shmat" "ac_cv_func_shmat" 58906 if test "x$ac_cv_func_shmat" = xyes; then : 58907 58908 fi 58909 58910 if test $ac_cv_func_shmat = no; then 58911 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for shmat in -lipc" >&5 58912 $as_echo_n "checking for shmat in -lipc... " >&6; } 58913 if ${ac_cv_lib_ipc_shmat+:} false; then : 58914 $as_echo_n "(cached) " >&6 58915 else 58916 ac_check_lib_save_LIBS=$LIBS 58917 LIBS="-lipc $LIBS" 58918 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 58919 /* end confdefs.h. */ 58920 58921 /* Override any GCC internal prototype to avoid an error. 58922 Use char because int might match the return type of a GCC 58923 builtin and then its argument prototype would still apply. */ 58924 #ifdef __cplusplus 58925 extern "C" 58926 #endif 58927 char shmat (); 58928 int 58929 main () 58930 { 58931 return shmat (); 58932 ; 58933 return 0; 58934 } 58935 _ACEOF 58936 if ac_fn_cxx_try_link "$LINENO"; then : 58937 ac_cv_lib_ipc_shmat=yes 58938 else 58939 ac_cv_lib_ipc_shmat=no 58940 fi 58941 rm -f core conftest.err conftest.$ac_objext \ 58942 conftest$ac_exeext conftest.$ac_ext 58943 LIBS=$ac_check_lib_save_LIBS 58944 fi 58945 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_ipc_shmat" >&5 58946 $as_echo "$ac_cv_lib_ipc_shmat" >&6; } 58947 if test "x$ac_cv_lib_ipc_shmat" = xyes; then : 58948 X_EXTRA_LIBS="$X_EXTRA_LIBS -lipc" 58949 fi 58950 58951 fi 58952 fi 58953 58954 # Check for libraries that X11R6 Xt/Xaw programs need. 58955 ac_save_LDFLAGS=$LDFLAGS 58956 test -n "$x_libraries" && LDFLAGS="$LDFLAGS -L$x_libraries" 58957 # SM needs ICE to (dynamically) link under SunOS 4.x (so we have to 58958 # check for ICE first), but we must link in the order -lSM -lICE or 58959 # we get undefined symbols. So assume we have SM if we have ICE. 58960 # These have to be linked with before -lX11, unlike the other 58961 # libraries we check for below, so use a different variable. 58962 # John Interrante, Karl Berry 58963 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for IceConnectionNumber in -lICE" >&5 58964 $as_echo_n "checking for IceConnectionNumber in -lICE... " >&6; } 58965 if ${ac_cv_lib_ICE_IceConnectionNumber+:} false; then : 58966 $as_echo_n "(cached) " >&6 58967 else 58968 ac_check_lib_save_LIBS=$LIBS 58969 LIBS="-lICE $X_EXTRA_LIBS $LIBS" 58970 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 58971 /* end confdefs.h. */ 58972 58973 /* Override any GCC internal prototype to avoid an error. 58974 Use char because int might match the return type of a GCC 58975 builtin and then its argument prototype would still apply. */ 58976 #ifdef __cplusplus 58977 extern "C" 58978 #endif 58979 char IceConnectionNumber (); 58980 int 58981 main () 58982 { 58983 return IceConnectionNumber (); 58984 ; 58985 return 0; 58986 } 58987 _ACEOF 58988 if ac_fn_cxx_try_link "$LINENO"; then : 58989 ac_cv_lib_ICE_IceConnectionNumber=yes 58990 else 58991 ac_cv_lib_ICE_IceConnectionNumber=no 58992 fi 58993 rm -f core conftest.err conftest.$ac_objext \ 58994 conftest$ac_exeext conftest.$ac_ext 58995 LIBS=$ac_check_lib_save_LIBS 58996 fi 58997 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_ICE_IceConnectionNumber" >&5 58998 $as_echo "$ac_cv_lib_ICE_IceConnectionNumber" >&6; } 58999 if test "x$ac_cv_lib_ICE_IceConnectionNumber" = xyes; then : 59000 X_PRE_LIBS="$X_PRE_LIBS -lSM -lICE" 59001 fi 59002 59003 LDFLAGS=$ac_save_LDFLAGS 59004 59005 fi 59006 59007 59008 # AC_PATH_XTRA creates X_LIBS and sometimes adds -R flags. When cross compiling 59009 # this doesn't make sense so we remove it. 59010 if test "x$COMPILE_TYPE" = xcross; then 59011 X_LIBS=`$ECHO $X_LIBS | $SED 's/-R \{0,1\}[^ ]*//g'` 59012 fi 59013 59014 if test "x$no_x" = xyes; then 59015 59016 # Print a helpful message on how to acquire the necessary build dependency. 59017 # x11 is the help tag: freetype, cups, alsa etc 59018 MISSING_DEPENDENCY=x11 59019 59020 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 59021 cygwin_help $MISSING_DEPENDENCY 59022 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 59023 msys_help $MISSING_DEPENDENCY 59024 else 59025 PKGHANDLER_COMMAND= 59026 59027 case $PKGHANDLER in 59028 apt-get) 59029 apt_help $MISSING_DEPENDENCY ;; 59030 yum) 59031 yum_help $MISSING_DEPENDENCY ;; 59032 brew) 59033 brew_help $MISSING_DEPENDENCY ;; 59034 port) 59035 port_help $MISSING_DEPENDENCY ;; 59036 pkgutil) 59037 pkgutil_help $MISSING_DEPENDENCY ;; 59038 pkgadd) 59039 pkgadd_help $MISSING_DEPENDENCY ;; 59040 esac 59041 59042 if test "x$PKGHANDLER_COMMAND" != x; then 59043 HELP_MSG="You might be able to fix this by running '$PKGHANDLER_COMMAND'." 59044 fi 59045 fi 59046 59047 as_fn_error $? "Could not find X11 libraries. $HELP_MSG" "$LINENO" 5 59048 fi 59049 59050 if test "x$OPENJDK_TARGET_OS" = xsolaris; then 59051 OPENWIN_HOME="/usr/openwin" 59052 X_CFLAGS="-I$SYSROOT$OPENWIN_HOME/include -I$SYSROOT$OPENWIN_HOME/include/X11/extensions" 59053 X_LIBS="-L$SYSROOT$OPENWIN_HOME/lib$OPENJDK_TARGET_CPU_ISADIR \ 59054 -R$OPENWIN_HOME/lib$OPENJDK_TARGET_CPU_ISADIR" 59055 fi 59056 59057 ac_ext=c 59058 ac_cpp='$CPP $CPPFLAGS' 59059 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5' 59060 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' 59061 ac_compiler_gnu=$ac_cv_c_compiler_gnu 59062 59063 OLD_CFLAGS="$CFLAGS" 59064 CFLAGS="$CFLAGS $SYSROOT_CFLAGS $X_CFLAGS" 59065 59066 # Need to include Xlib.h and Xutil.h to avoid "present but cannot be compiled" warnings on Solaris 10 59067 for ac_header in X11/extensions/shape.h X11/extensions/Xrender.h X11/extensions/XTest.h X11/Intrinsic.h 59068 do : 59069 as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh` 59070 ac_fn_c_check_header_compile "$LINENO" "$ac_header" "$as_ac_Header" " 59071 # include <X11/Xlib.h> 59072 # include <X11/Xutil.h> 59073 59074 59075 " 59076 if eval test \"x\$"$as_ac_Header"\" = x"yes"; then : 59077 cat >>confdefs.h <<_ACEOF 59078 #define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1 59079 _ACEOF 59080 X11_HEADERS_OK=yes 59081 else 59082 X11_HEADERS_OK=no; break 59083 fi 59084 59085 done 59086 59087 59088 if test "x$X11_HEADERS_OK" = xno; then 59089 59090 # Print a helpful message on how to acquire the necessary build dependency. 59091 # x11 is the help tag: freetype, cups, alsa etc 59092 MISSING_DEPENDENCY=x11 59093 59094 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 59095 cygwin_help $MISSING_DEPENDENCY 59096 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 59097 msys_help $MISSING_DEPENDENCY 59098 else 59099 PKGHANDLER_COMMAND= 59100 59101 case $PKGHANDLER in 59102 apt-get) 59103 apt_help $MISSING_DEPENDENCY ;; 59104 yum) 59105 yum_help $MISSING_DEPENDENCY ;; 59106 brew) 59107 brew_help $MISSING_DEPENDENCY ;; 59108 port) 59109 port_help $MISSING_DEPENDENCY ;; 59110 pkgutil) 59111 pkgutil_help $MISSING_DEPENDENCY ;; 59112 pkgadd) 59113 pkgadd_help $MISSING_DEPENDENCY ;; 59114 esac 59115 59116 if test "x$PKGHANDLER_COMMAND" != x; then 59117 HELP_MSG="You might be able to fix this by running '$PKGHANDLER_COMMAND'." 59118 fi 59119 fi 59120 59121 as_fn_error $? "Could not find all X11 headers (shape.h Xrender.h XTest.h Intrinsic.h). $HELP_MSG" "$LINENO" 5 59122 fi 59123 59124 # If XLinearGradient isn't available in Xrender.h, signal that it needs to be 59125 # defined in libawt_xawt. 59126 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if XlinearGradient is defined in Xrender.h" >&5 59127 $as_echo_n "checking if XlinearGradient is defined in Xrender.h... " >&6; } 59128 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 59129 /* end confdefs.h. */ 59130 #include <X11/extensions/Xrender.h> 59131 int 59132 main () 59133 { 59134 XLinearGradient x; 59135 ; 59136 return 0; 59137 } 59138 _ACEOF 59139 if ac_fn_c_try_compile "$LINENO"; then : 59140 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 59141 $as_echo "yes" >&6; } 59142 else 59143 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 59144 $as_echo "no" >&6; } 59145 X_CFLAGS="$X_CFLAGS -DSOLARIS10_NO_XRENDER_STRUCTS" 59146 fi 59147 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext 59148 59149 CFLAGS="$OLD_CFLAGS" 59150 ac_ext=cpp 59151 ac_cpp='$CXXCPP $CPPFLAGS' 59152 ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5' 59153 ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' 59154 ac_compiler_gnu=$ac_cv_cxx_compiler_gnu 59155 59156 fi # NEEDS_LIB_X11 59157 59158 59159 59160 59161 59162 59163 # Check whether --with-cups was given. 59164 if test "${with_cups+set}" = set; then : 59165 withval=$with_cups; 59166 fi 59167 59168 59169 # Check whether --with-cups-include was given. 59170 if test "${with_cups_include+set}" = set; then : 59171 withval=$with_cups_include; 59172 fi 59173 59174 59175 if test "x$NEEDS_LIB_CUPS" = xfalse; then 59176 if (test "x${with_cups}" != x && test "x${with_cups}" != xno) || \ 59177 (test "x${with_cups_include}" != x && test "x${with_cups_include}" != xno); then 59178 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: cups not used, so --with-cups[-*] is ignored" >&5 59179 $as_echo "$as_me: WARNING: cups not used, so --with-cups[-*] is ignored" >&2;} 59180 fi 59181 CUPS_CFLAGS= 59182 else 59183 CUPS_FOUND=no 59184 59185 if test "x${with_cups}" = xno || test "x${with_cups_include}" = xno; then 59186 as_fn_error $? "It is not possible to disable the use of cups. Remove the --without-cups option." "$LINENO" 5 59187 fi 59188 59189 if test "x${with_cups}" != x; then 59190 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for cups headers" >&5 59191 $as_echo_n "checking for cups headers... " >&6; } 59192 if test -s "${with_cups}/include/cups/cups.h"; then 59193 CUPS_CFLAGS="-I${with_cups}/include" 59194 CUPS_FOUND=yes 59195 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CUPS_FOUND" >&5 59196 $as_echo "$CUPS_FOUND" >&6; } 59197 else 59198 as_fn_error $? "Can't find 'include/cups/cups.h' under ${with_cups} given with the --with-cups option." "$LINENO" 5 59199 fi 59200 fi 59201 if test "x${with_cups_include}" != x; then 59202 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for cups headers" >&5 59203 $as_echo_n "checking for cups headers... " >&6; } 59204 if test -s "${with_cups_include}/cups/cups.h"; then 59205 CUPS_CFLAGS="-I${with_cups_include}" 59206 CUPS_FOUND=yes 59207 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CUPS_FOUND" >&5 59208 $as_echo "$CUPS_FOUND" >&6; } 59209 else 59210 as_fn_error $? "Can't find 'cups/cups.h' under ${with_cups_include} given with the --with-cups-include option." "$LINENO" 5 59211 fi 59212 fi 59213 if test "x$CUPS_FOUND" = xno; then 59214 # Are the cups headers installed in the default /usr/include location? 59215 for ac_header in cups/cups.h cups/ppd.h 59216 do : 59217 as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh` 59218 ac_fn_cxx_check_header_mongrel "$LINENO" "$ac_header" "$as_ac_Header" "$ac_includes_default" 59219 if eval test \"x\$"$as_ac_Header"\" = x"yes"; then : 59220 cat >>confdefs.h <<_ACEOF 59221 #define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1 59222 _ACEOF 59223 59224 CUPS_FOUND=yes 59225 CUPS_CFLAGS= 59226 DEFAULT_CUPS=yes 59227 59228 fi 59229 59230 done 59231 59232 fi 59233 if test "x$CUPS_FOUND" = xno; then 59234 59235 # Print a helpful message on how to acquire the necessary build dependency. 59236 # cups is the help tag: freetype, cups, alsa etc 59237 MISSING_DEPENDENCY=cups 59238 59239 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 59240 cygwin_help $MISSING_DEPENDENCY 59241 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 59242 msys_help $MISSING_DEPENDENCY 59243 else 59244 PKGHANDLER_COMMAND= 59245 59246 case $PKGHANDLER in 59247 apt-get) 59248 apt_help $MISSING_DEPENDENCY ;; 59249 yum) 59250 yum_help $MISSING_DEPENDENCY ;; 59251 brew) 59252 brew_help $MISSING_DEPENDENCY ;; 59253 port) 59254 port_help $MISSING_DEPENDENCY ;; 59255 pkgutil) 59256 pkgutil_help $MISSING_DEPENDENCY ;; 59257 pkgadd) 59258 pkgadd_help $MISSING_DEPENDENCY ;; 59259 esac 59260 59261 if test "x$PKGHANDLER_COMMAND" != x; then 59262 HELP_MSG="You might be able to fix this by running '$PKGHANDLER_COMMAND'." 59263 fi 59264 fi 59265 59266 as_fn_error $? "Could not find cups! $HELP_MSG " "$LINENO" 5 59267 fi 59268 fi 59269 59270 59271 59272 59273 59274 # Check whether --with-fontconfig was given. 59275 if test "${with_fontconfig+set}" = set; then : 59276 withval=$with_fontconfig; 59277 fi 59278 59279 59280 # Check whether --with-fontconfig-include was given. 59281 if test "${with_fontconfig_include+set}" = set; then : 59282 withval=$with_fontconfig_include; 59283 fi 59284 59285 59286 if test "x$NEEDS_LIB_FONTCONFIG" = xfalse; then 59287 if (test "x${with_fontconfig}" != x && test "x${with_fontconfig}" != xno) || \ 59288 (test "x${with_fontconfig_include}" != x && test "x${with_fontconfig_include}" != xno); then 59289 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: fontconfig not used, so --with-fontconfig[-*] is ignored" >&5 59290 $as_echo "$as_me: WARNING: fontconfig not used, so --with-fontconfig[-*] is ignored" >&2;} 59291 fi 59292 FONTCONFIG_CFLAGS= 59293 else 59294 FONTCONFIG_FOUND=no 59295 59296 if test "x${with_fontconfig}" = xno || test "x${with_fontconfig_include}" = xno; then 59297 as_fn_error $? "It is not possible to disable the use of fontconfig. Remove the --without-fontconfig option." "$LINENO" 5 59298 fi 59299 59300 if test "x${with_fontconfig}" != x; then 59301 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for fontconfig headers" >&5 59302 $as_echo_n "checking for fontconfig headers... " >&6; } 59303 if test -s "${with_fontconfig}/include/fontconfig/fontconfig.h"; then 59304 FONTCONFIG_CFLAGS="-I${with_fontconfig}/include" 59305 FONTCONFIG_FOUND=yes 59306 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $FONTCONFIG_FOUND" >&5 59307 $as_echo "$FONTCONFIG_FOUND" >&6; } 59308 else 59309 as_fn_error $? "Can't find 'include/fontconfig/fontconfig.h' under ${with_fontconfig} given with the --with-fontconfig option." "$LINENO" 5 59310 fi 59311 fi 59312 if test "x${with_fontconfig_include}" != x; then 59313 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for fontconfig headers" >&5 59314 $as_echo_n "checking for fontconfig headers... " >&6; } 59315 if test -s "${with_fontconfig_include}/fontconfig/fontconfig.h"; then 59316 FONTCONFIG_CFLAGS="-I${with_fontconfig_include}" 59317 FONTCONFIG_FOUND=yes 59318 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $FONTCONFIG_FOUND" >&5 59319 $as_echo "$FONTCONFIG_FOUND" >&6; } 59320 else 59321 as_fn_error $? "Can't find 'fontconfig/fontconfig.h' under ${with_fontconfig_include} given with the --with-fontconfig-include option." "$LINENO" 5 59322 fi 59323 fi 59324 if test "x$FONTCONFIG_FOUND" = xno; then 59325 # Are the fontconfig headers installed in the default /usr/include location? 59326 for ac_header in fontconfig/fontconfig.h 59327 do : 59328 ac_fn_cxx_check_header_mongrel "$LINENO" "fontconfig/fontconfig.h" "ac_cv_header_fontconfig_fontconfig_h" "$ac_includes_default" 59329 if test "x$ac_cv_header_fontconfig_fontconfig_h" = xyes; then : 59330 cat >>confdefs.h <<_ACEOF 59331 #define HAVE_FONTCONFIG_FONTCONFIG_H 1 59332 _ACEOF 59333 59334 FONTCONFIG_FOUND=yes 59335 FONTCONFIG_CFLAGS= 59336 DEFAULT_FONTCONFIG=yes 59337 59338 fi 59339 59340 done 59341 59342 fi 59343 if test "x$FONTCONFIG_FOUND" = xno; then 59344 59345 # Print a helpful message on how to acquire the necessary build dependency. 59346 # fontconfig is the help tag: freetype, cups, alsa etc 59347 MISSING_DEPENDENCY=fontconfig 59348 59349 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 59350 cygwin_help $MISSING_DEPENDENCY 59351 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 59352 msys_help $MISSING_DEPENDENCY 59353 else 59354 PKGHANDLER_COMMAND= 59355 59356 case $PKGHANDLER in 59357 apt-get) 59358 apt_help $MISSING_DEPENDENCY ;; 59359 yum) 59360 yum_help $MISSING_DEPENDENCY ;; 59361 brew) 59362 brew_help $MISSING_DEPENDENCY ;; 59363 port) 59364 port_help $MISSING_DEPENDENCY ;; 59365 pkgutil) 59366 pkgutil_help $MISSING_DEPENDENCY ;; 59367 pkgadd) 59368 pkgadd_help $MISSING_DEPENDENCY ;; 59369 esac 59370 59371 if test "x$PKGHANDLER_COMMAND" != x; then 59372 HELP_MSG="You might be able to fix this by running '$PKGHANDLER_COMMAND'." 59373 fi 59374 fi 59375 59376 as_fn_error $? "Could not find fontconfig! $HELP_MSG " "$LINENO" 5 59377 fi 59378 fi 59379 59380 59381 59382 59383 59384 # Check whether --with-freetype was given. 59385 if test "${with_freetype+set}" = set; then : 59386 withval=$with_freetype; 59387 fi 59388 59389 59390 # Check whether --with-freetype-include was given. 59391 if test "${with_freetype_include+set}" = set; then : 59392 withval=$with_freetype_include; 59393 fi 59394 59395 59396 # Check whether --with-freetype-lib was given. 59397 if test "${with_freetype_lib+set}" = set; then : 59398 withval=$with_freetype_lib; 59399 fi 59400 59401 59402 # Check whether --with-freetype-src was given. 59403 if test "${with_freetype_src+set}" = set; then : 59404 withval=$with_freetype_src; 59405 fi 59406 59407 # Check whether --enable-freetype-bundling was given. 59408 if test "${enable_freetype_bundling+set}" = set; then : 59409 enableval=$enable_freetype_bundling; 59410 fi 59411 59412 59413 # Check whether --with-freetype-license was given. 59414 if test "${with_freetype_license+set}" = set; then : 59415 withval=$with_freetype_license; 59416 fi 59417 59418 59419 # Need to specify explicitly since it needs to be overridden on some versions of macosx 59420 FREETYPE_BASE_NAME=freetype 59421 FREETYPE_CFLAGS= 59422 FREETYPE_LIBS= 59423 FREETYPE_BUNDLE_LIB_PATH= 59424 59425 if test "x$NEEDS_LIB_FREETYPE" = xfalse; then 59426 if (test "x$with_freetype" != x && test "x$with_freetype" != xno) || \ 59427 (test "x$with_freetype_include" != x && test "x$with_freetype_include" != xno) || \ 59428 (test "x$with_freetype_lib" != x && test "x$with_freetype_lib" != xno) || \ 59429 (test "x$with_freetype_src" != x && test "x$with_freetype_src" != xno); then 59430 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: freetype not used, so --with-freetype[-*] is ignored" >&5 59431 $as_echo "$as_me: WARNING: freetype not used, so --with-freetype[-*] is ignored" >&2;} 59432 fi 59433 if (test "x$enable_freetype_bundling" != x && test "x$enable_freetype_bundling" != xno); then 59434 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: freetype not used, so --enable-freetype-bundling is ignored" >&5 59435 $as_echo "$as_me: WARNING: freetype not used, so --enable-freetype-bundling is ignored" >&2;} 59436 fi 59437 else 59438 # freetype is needed to build; go get it! 59439 59440 BUNDLE_FREETYPE="$enable_freetype_bundling" 59441 59442 if test "x$with_freetype_src" != x; then 59443 if test "x$OPENJDK_TARGET_OS" = xwindows; then 59444 # Try to build freetype if --with-freetype-src was given on Windows 59445 59446 FREETYPE_SRC_PATH="$with_freetype_src" 59447 BUILD_FREETYPE=yes 59448 59449 # Check if the freetype sources are acessible.. 59450 if ! test -d $FREETYPE_SRC_PATH; then 59451 { $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 59452 $as_echo "$as_me: WARNING: --with-freetype-src specified, but can not find path \"$FREETYPE_SRC_PATH\" - ignoring --with-freetype-src" >&2;} 59453 BUILD_FREETYPE=no 59454 fi 59455 # ..and contain a vc2010 project file 59456 vcxproj_path="$FREETYPE_SRC_PATH/builds/windows/vc2010/freetype.vcxproj" 59457 if test "x$BUILD_FREETYPE" = xyes && ! test -s $vcxproj_path; then 59458 { $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 59459 $as_echo "$as_me: WARNING: Can not find project file $vcxproj_path (you may try a newer freetype version) - ignoring --with-freetype-src" >&2;} 59460 BUILD_FREETYPE=no 59461 fi 59462 # Now check if configure found a version of 'msbuild.exe' 59463 if test "x$BUILD_FREETYPE" = xyes && test "x$MSBUILD" == x ; then 59464 { $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 59465 $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;} 59466 BUILD_FREETYPE=no 59467 fi 59468 59469 # Ready to go.. 59470 if test "x$BUILD_FREETYPE" = xyes; then 59471 # msbuild requires trailing slashes for output directories 59472 freetype_lib_path="$FREETYPE_SRC_PATH/lib$OPENJDK_TARGET_CPU_BITS/" 59473 freetype_lib_path_unix="$freetype_lib_path" 59474 freetype_obj_path="$FREETYPE_SRC_PATH/obj$OPENJDK_TARGET_CPU_BITS/" 59475 59476 unix_path="$vcxproj_path" 59477 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 59478 windows_path=`$CYGPATH -m "$unix_path"` 59479 vcxproj_path="$windows_path" 59480 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 59481 windows_path=`cmd //c echo $unix_path` 59482 vcxproj_path="$windows_path" 59483 fi 59484 59485 59486 unix_path="$freetype_lib_path" 59487 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 59488 windows_path=`$CYGPATH -m "$unix_path"` 59489 freetype_lib_path="$windows_path" 59490 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 59491 windows_path=`cmd //c echo $unix_path` 59492 freetype_lib_path="$windows_path" 59493 fi 59494 59495 59496 unix_path="$freetype_obj_path" 59497 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 59498 windows_path=`$CYGPATH -m "$unix_path"` 59499 freetype_obj_path="$windows_path" 59500 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 59501 windows_path=`cmd //c echo $unix_path` 59502 freetype_obj_path="$windows_path" 59503 fi 59504 59505 if test "x$OPENJDK_TARGET_CPU_BITS" = x64; then 59506 freetype_platform=x64 59507 else 59508 freetype_platform=win32 59509 fi 59510 59511 # The original freetype project file is for VS 2010 (i.e. 'v100'), 59512 # so we have to adapt the toolset if building with any other toolsed (i.e. SDK). 59513 # Currently 'PLATFORM_TOOLSET' is set in 'TOOLCHAIN_CHECK_POSSIBLE_VISUAL_STUDIO_ROOT'/ 59514 # 'TOOLCHAIN_CHECK_POSSIBLE_WIN_SDK_ROOT' in toolchain_windows.m4 59515 { $as_echo "$as_me:${as_lineno-$LINENO}: Trying to compile freetype sources with PlatformToolset=$PLATFORM_TOOLSET to $freetype_lib_path_unix ..." >&5 59516 $as_echo "$as_me: Trying to compile freetype sources with PlatformToolset=$PLATFORM_TOOLSET to $freetype_lib_path_unix ..." >&6;} 59517 59518 # First we try to build the freetype.dll 59519 $ECHO -e "@echo off\n"\ 59520 "$MSBUILD $vcxproj_path "\ 59521 "/p:PlatformToolset=$PLATFORM_TOOLSET "\ 59522 "/p:Configuration=\"Release Multithreaded\" "\ 59523 "/p:Platform=$freetype_platform "\ 59524 "/p:ConfigurationType=DynamicLibrary "\ 59525 "/p:TargetName=freetype "\ 59526 "/p:OutDir=\"$freetype_lib_path\" "\ 59527 "/p:IntDir=\"$freetype_obj_path\" > freetype.log" > freetype.bat 59528 cmd /c freetype.bat 59529 59530 if test -s "$freetype_lib_path_unix/freetype.dll"; then 59531 # If that succeeds we also build freetype.lib 59532 $ECHO -e "@echo off\n"\ 59533 "$MSBUILD $vcxproj_path "\ 59534 "/p:PlatformToolset=$PLATFORM_TOOLSET "\ 59535 "/p:Configuration=\"Release Multithreaded\" "\ 59536 "/p:Platform=$freetype_platform "\ 59537 "/p:ConfigurationType=StaticLibrary "\ 59538 "/p:TargetName=freetype "\ 59539 "/p:OutDir=\"$freetype_lib_path\" "\ 59540 "/p:IntDir=\"$freetype_obj_path\" >> freetype.log" > freetype.bat 59541 cmd /c freetype.bat 59542 59543 if test -s "$freetype_lib_path_unix/freetype.lib"; then 59544 # Once we build both, lib and dll, set freetype lib and include path appropriately 59545 POTENTIAL_FREETYPE_INCLUDE_PATH="$FREETYPE_SRC_PATH/include" 59546 POTENTIAL_FREETYPE_LIB_PATH="$freetype_lib_path_unix" 59547 { $as_echo "$as_me:${as_lineno-$LINENO}: Compiling freetype sources succeeded! (see freetype.log for build results)" >&5 59548 $as_echo "$as_me: Compiling freetype sources succeeded! (see freetype.log for build results)" >&6;} 59549 else 59550 BUILD_FREETYPE=no 59551 fi 59552 else 59553 BUILD_FREETYPE=no 59554 fi 59555 fi 59556 59557 if test "x$BUILD_FREETYPE" = xyes; then 59558 # Okay, we built it. Check that it works. 59559 59560 POTENTIAL_FREETYPE_INCLUDE_PATH="$POTENTIAL_FREETYPE_INCLUDE_PATH" 59561 POTENTIAL_FREETYPE_LIB_PATH="$POTENTIAL_FREETYPE_LIB_PATH" 59562 METHOD="--with-freetype-src" 59563 59564 # Let's start with an optimistic view of the world :-) 59565 FOUND_FREETYPE=yes 59566 59567 # First look for the canonical freetype main include file ft2build.h. 59568 if ! test -s "$POTENTIAL_FREETYPE_INCLUDE_PATH/ft2build.h"; then 59569 # Oh no! Let's try in the freetype2 directory. This is needed at least at Mac OS X Yosemite. 59570 POTENTIAL_FREETYPE_INCLUDE_PATH="$POTENTIAL_FREETYPE_INCLUDE_PATH/freetype2" 59571 if ! test -s "$POTENTIAL_FREETYPE_INCLUDE_PATH/ft2build.h"; then 59572 # Fail. 59573 FOUND_FREETYPE=no 59574 fi 59575 fi 59576 59577 if test "x$FOUND_FREETYPE" = xyes; then 59578 # Include file found, let's continue the sanity check. 59579 { $as_echo "$as_me:${as_lineno-$LINENO}: Found freetype include files at $POTENTIAL_FREETYPE_INCLUDE_PATH using $METHOD" >&5 59580 $as_echo "$as_me: Found freetype include files at $POTENTIAL_FREETYPE_INCLUDE_PATH using $METHOD" >&6;} 59581 59582 # Reset to default value 59583 FREETYPE_BASE_NAME=freetype 59584 FREETYPE_LIB_NAME="${LIBRARY_PREFIX}${FREETYPE_BASE_NAME}${SHARED_LIBRARY_SUFFIX}" 59585 if ! test -s "$POTENTIAL_FREETYPE_LIB_PATH/$FREETYPE_LIB_NAME"; then 59586 if test "x$OPENJDK_TARGET_OS" = xmacosx \ 59587 && test -s "$POTENTIAL_FREETYPE_LIB_PATH/${LIBRARY_PREFIX}freetype.6${SHARED_LIBRARY_SUFFIX}"; then 59588 # On Mac OS X Yosemite, the symlink from libfreetype.dylib to libfreetype.6.dylib disappeared. Check 59589 # for the .6 version explicitly. 59590 FREETYPE_BASE_NAME=freetype.6 59591 FREETYPE_LIB_NAME="${LIBRARY_PREFIX}${FREETYPE_BASE_NAME}${SHARED_LIBRARY_SUFFIX}" 59592 { $as_echo "$as_me:${as_lineno-$LINENO}: Compensating for missing symlink by using version 6 explicitly" >&5 59593 $as_echo "$as_me: Compensating for missing symlink by using version 6 explicitly" >&6;} 59594 else 59595 { $as_echo "$as_me:${as_lineno-$LINENO}: Could not find $POTENTIAL_FREETYPE_LIB_PATH/$FREETYPE_LIB_NAME. Ignoring location." >&5 59596 $as_echo "$as_me: Could not find $POTENTIAL_FREETYPE_LIB_PATH/$FREETYPE_LIB_NAME. Ignoring location." >&6;} 59597 FOUND_FREETYPE=no 59598 fi 59599 else 59600 if test "x$OPENJDK_TARGET_OS" = xwindows; then 59601 # On Windows, we will need both .lib and .dll file. 59602 if ! test -s "$POTENTIAL_FREETYPE_LIB_PATH/${FREETYPE_BASE_NAME}.lib"; then 59603 { $as_echo "$as_me:${as_lineno-$LINENO}: Could not find $POTENTIAL_FREETYPE_LIB_PATH/${FREETYPE_BASE_NAME}.lib. Ignoring location." >&5 59604 $as_echo "$as_me: Could not find $POTENTIAL_FREETYPE_LIB_PATH/${FREETYPE_BASE_NAME}.lib. Ignoring location." >&6;} 59605 FOUND_FREETYPE=no 59606 fi 59607 elif test "x$OPENJDK_TARGET_OS" = xsolaris \ 59608 && test -s "$POTENTIAL_FREETYPE_LIB_PATH$OPENJDK_TARGET_CPU_ISADIR/$FREETYPE_LIB_NAME"; then 59609 # Found lib in isa dir, use that instead. 59610 POTENTIAL_FREETYPE_LIB_PATH="$POTENTIAL_FREETYPE_LIB_PATH$OPENJDK_TARGET_CPU_ISADIR" 59611 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting to use $POTENTIAL_FREETYPE_LIB_PATH instead" >&5 59612 $as_echo "$as_me: Rewriting to use $POTENTIAL_FREETYPE_LIB_PATH instead" >&6;} 59613 fi 59614 fi 59615 fi 59616 59617 if test "x$FOUND_FREETYPE" = xyes; then 59618 59619 # Only process if variable expands to non-empty 59620 59621 if test "x$POTENTIAL_FREETYPE_INCLUDE_PATH" != x; then 59622 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 59623 59624 # Input might be given as Windows format, start by converting to 59625 # unix format. 59626 path="$POTENTIAL_FREETYPE_INCLUDE_PATH" 59627 new_path=`$CYGPATH -u "$path"` 59628 59629 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 59630 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 59631 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 59632 # "foo.exe" is OK but "foo" is an error. 59633 # 59634 # This test is therefore slightly more accurate than "test -f" to check for file precense. 59635 # It is also a way to make sure we got the proper file name for the real test later on. 59636 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 59637 if test "x$test_shortpath" = x; then 59638 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&5 59639 $as_echo "$as_me: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&6;} 59640 as_fn_error $? "Cannot locate the the path of POTENTIAL_FREETYPE_INCLUDE_PATH" "$LINENO" 5 59641 fi 59642 59643 # Call helper function which possibly converts this using DOS-style short mode. 59644 # If so, the updated path is stored in $new_path. 59645 59646 input_path="$new_path" 59647 # Check if we need to convert this using DOS-style short mode. If the path 59648 # contains just simple characters, use it. Otherwise (spaces, weird characters), 59649 # take no chances and rewrite it. 59650 # Note: m4 eats our [], so we need to use [ and ] instead. 59651 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 59652 if test "x$has_forbidden_chars" != x; then 59653 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 59654 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 59655 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 59656 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 59657 # Going to short mode and back again did indeed matter. Since short mode is 59658 # case insensitive, let's make it lowercase to improve readability. 59659 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 59660 # Now convert it back to Unix-style (cygpath) 59661 input_path=`$CYGPATH -u "$shortmode_path"` 59662 new_path="$input_path" 59663 fi 59664 fi 59665 59666 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 59667 if test "x$test_cygdrive_prefix" = x; then 59668 # As a simple fix, exclude /usr/bin since it's not a real path. 59669 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 59670 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 59671 # a path prefixed by /cygdrive for fixpath to work. 59672 new_path="$CYGWIN_ROOT_PATH$input_path" 59673 fi 59674 fi 59675 59676 59677 if test "x$path" != "x$new_path"; then 59678 POTENTIAL_FREETYPE_INCLUDE_PATH="$new_path" 59679 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&5 59680 $as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&6;} 59681 fi 59682 59683 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 59684 59685 path="$POTENTIAL_FREETYPE_INCLUDE_PATH" 59686 has_colon=`$ECHO $path | $GREP ^.:` 59687 new_path="$path" 59688 if test "x$has_colon" = x; then 59689 # Not in mixed or Windows style, start by that. 59690 new_path=`cmd //c echo $path` 59691 fi 59692 59693 59694 input_path="$new_path" 59695 # Check if we need to convert this using DOS-style short mode. If the path 59696 # contains just simple characters, use it. Otherwise (spaces, weird characters), 59697 # take no chances and rewrite it. 59698 # Note: m4 eats our [], so we need to use [ and ] instead. 59699 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 59700 if test "x$has_forbidden_chars" != x; then 59701 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 59702 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 59703 fi 59704 59705 59706 windows_path="$new_path" 59707 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 59708 unix_path=`$CYGPATH -u "$windows_path"` 59709 new_path="$unix_path" 59710 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 59711 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 59712 new_path="$unix_path" 59713 fi 59714 59715 if test "x$path" != "x$new_path"; then 59716 POTENTIAL_FREETYPE_INCLUDE_PATH="$new_path" 59717 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&5 59718 $as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&6;} 59719 fi 59720 59721 # Save the first 10 bytes of this path to the storage, so fixpath can work. 59722 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 59723 59724 else 59725 # We're on a unix platform. Hooray! :) 59726 path="$POTENTIAL_FREETYPE_INCLUDE_PATH" 59727 has_space=`$ECHO "$path" | $GREP " "` 59728 if test "x$has_space" != x; then 59729 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&5 59730 $as_echo "$as_me: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&6;} 59731 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 59732 fi 59733 59734 # Use eval to expand a potential ~ 59735 eval path="$path" 59736 if test ! -f "$path" && test ! -d "$path"; then 59737 as_fn_error $? "The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is not found." "$LINENO" 5 59738 fi 59739 59740 if test -d "$path"; then 59741 POTENTIAL_FREETYPE_INCLUDE_PATH="`cd "$path"; $THEPWDCMD -L`" 59742 else 59743 dir="`$DIRNAME "$path"`" 59744 base="`$BASENAME "$path"`" 59745 POTENTIAL_FREETYPE_INCLUDE_PATH="`cd "$dir"; $THEPWDCMD -L`/$base" 59746 fi 59747 fi 59748 fi 59749 59750 59751 # Only process if variable expands to non-empty 59752 59753 if test "x$POTENTIAL_FREETYPE_LIB_PATH" != x; then 59754 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 59755 59756 # Input might be given as Windows format, start by converting to 59757 # unix format. 59758 path="$POTENTIAL_FREETYPE_LIB_PATH" 59759 new_path=`$CYGPATH -u "$path"` 59760 59761 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 59762 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 59763 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 59764 # "foo.exe" is OK but "foo" is an error. 59765 # 59766 # This test is therefore slightly more accurate than "test -f" to check for file precense. 59767 # It is also a way to make sure we got the proper file name for the real test later on. 59768 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 59769 if test "x$test_shortpath" = x; then 59770 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&5 59771 $as_echo "$as_me: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&6;} 59772 as_fn_error $? "Cannot locate the the path of POTENTIAL_FREETYPE_LIB_PATH" "$LINENO" 5 59773 fi 59774 59775 # Call helper function which possibly converts this using DOS-style short mode. 59776 # If so, the updated path is stored in $new_path. 59777 59778 input_path="$new_path" 59779 # Check if we need to convert this using DOS-style short mode. If the path 59780 # contains just simple characters, use it. Otherwise (spaces, weird characters), 59781 # take no chances and rewrite it. 59782 # Note: m4 eats our [], so we need to use [ and ] instead. 59783 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 59784 if test "x$has_forbidden_chars" != x; then 59785 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 59786 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 59787 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 59788 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 59789 # Going to short mode and back again did indeed matter. Since short mode is 59790 # case insensitive, let's make it lowercase to improve readability. 59791 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 59792 # Now convert it back to Unix-style (cygpath) 59793 input_path=`$CYGPATH -u "$shortmode_path"` 59794 new_path="$input_path" 59795 fi 59796 fi 59797 59798 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 59799 if test "x$test_cygdrive_prefix" = x; then 59800 # As a simple fix, exclude /usr/bin since it's not a real path. 59801 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 59802 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 59803 # a path prefixed by /cygdrive for fixpath to work. 59804 new_path="$CYGWIN_ROOT_PATH$input_path" 59805 fi 59806 fi 59807 59808 59809 if test "x$path" != "x$new_path"; then 59810 POTENTIAL_FREETYPE_LIB_PATH="$new_path" 59811 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&5 59812 $as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&6;} 59813 fi 59814 59815 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 59816 59817 path="$POTENTIAL_FREETYPE_LIB_PATH" 59818 has_colon=`$ECHO $path | $GREP ^.:` 59819 new_path="$path" 59820 if test "x$has_colon" = x; then 59821 # Not in mixed or Windows style, start by that. 59822 new_path=`cmd //c echo $path` 59823 fi 59824 59825 59826 input_path="$new_path" 59827 # Check if we need to convert this using DOS-style short mode. If the path 59828 # contains just simple characters, use it. Otherwise (spaces, weird characters), 59829 # take no chances and rewrite it. 59830 # Note: m4 eats our [], so we need to use [ and ] instead. 59831 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 59832 if test "x$has_forbidden_chars" != x; then 59833 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 59834 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 59835 fi 59836 59837 59838 windows_path="$new_path" 59839 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 59840 unix_path=`$CYGPATH -u "$windows_path"` 59841 new_path="$unix_path" 59842 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 59843 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 59844 new_path="$unix_path" 59845 fi 59846 59847 if test "x$path" != "x$new_path"; then 59848 POTENTIAL_FREETYPE_LIB_PATH="$new_path" 59849 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&5 59850 $as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&6;} 59851 fi 59852 59853 # Save the first 10 bytes of this path to the storage, so fixpath can work. 59854 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 59855 59856 else 59857 # We're on a unix platform. Hooray! :) 59858 path="$POTENTIAL_FREETYPE_LIB_PATH" 59859 has_space=`$ECHO "$path" | $GREP " "` 59860 if test "x$has_space" != x; then 59861 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&5 59862 $as_echo "$as_me: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&6;} 59863 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 59864 fi 59865 59866 # Use eval to expand a potential ~ 59867 eval path="$path" 59868 if test ! -f "$path" && test ! -d "$path"; then 59869 as_fn_error $? "The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is not found." "$LINENO" 5 59870 fi 59871 59872 if test -d "$path"; then 59873 POTENTIAL_FREETYPE_LIB_PATH="`cd "$path"; $THEPWDCMD -L`" 59874 else 59875 dir="`$DIRNAME "$path"`" 59876 base="`$BASENAME "$path"`" 59877 POTENTIAL_FREETYPE_LIB_PATH="`cd "$dir"; $THEPWDCMD -L`/$base" 59878 fi 59879 fi 59880 fi 59881 59882 59883 FREETYPE_INCLUDE_PATH="$POTENTIAL_FREETYPE_INCLUDE_PATH" 59884 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for freetype includes" >&5 59885 $as_echo_n "checking for freetype includes... " >&6; } 59886 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $FREETYPE_INCLUDE_PATH" >&5 59887 $as_echo "$FREETYPE_INCLUDE_PATH" >&6; } 59888 FREETYPE_LIB_PATH="$POTENTIAL_FREETYPE_LIB_PATH" 59889 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for freetype libraries" >&5 59890 $as_echo_n "checking for freetype libraries... " >&6; } 59891 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $FREETYPE_LIB_PATH" >&5 59892 $as_echo "$FREETYPE_LIB_PATH" >&6; } 59893 fi 59894 59895 if test "x$FOUND_FREETYPE" != xyes; then 59896 as_fn_error $? "Can not use the built freetype at location given by --with-freetype-src" "$LINENO" 5 59897 fi 59898 else 59899 { $as_echo "$as_me:${as_lineno-$LINENO}: User specified --with-freetype-src but building freetype failed. (see freetype.log for build results)" >&5 59900 $as_echo "$as_me: User specified --with-freetype-src but building freetype failed. (see freetype.log for build results)" >&6;} 59901 as_fn_error $? "Consider building freetype manually and using --with-freetype instead." "$LINENO" 5 59902 fi 59903 else 59904 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: --with-freetype-src is currently only supported on Windows - ignoring" >&5 59905 $as_echo "$as_me: WARNING: --with-freetype-src is currently only supported on Windows - ignoring" >&2;} 59906 fi 59907 fi 59908 59909 if test "x$with_freetype" != x || test "x$with_freetype_include" != x || test "x$with_freetype_lib" != x; then 59910 # User has specified settings 59911 59912 if test "x$BUNDLE_FREETYPE" = x; then 59913 # If not specified, default is to bundle freetype 59914 BUNDLE_FREETYPE=yes 59915 fi 59916 59917 if test "x$with_freetype" != x; then 59918 POTENTIAL_FREETYPE_INCLUDE_PATH="$with_freetype/include" 59919 POTENTIAL_FREETYPE_LIB_PATH="$with_freetype/lib" 59920 fi 59921 59922 # Allow --with-freetype-lib and --with-freetype-include to override 59923 if test "x$with_freetype_include" != x; then 59924 POTENTIAL_FREETYPE_INCLUDE_PATH="$with_freetype_include" 59925 fi 59926 if test "x$with_freetype_lib" != x; then 59927 POTENTIAL_FREETYPE_LIB_PATH="$with_freetype_lib" 59928 fi 59929 59930 if test "x$POTENTIAL_FREETYPE_INCLUDE_PATH" != x && test "x$POTENTIAL_FREETYPE_LIB_PATH" != x; then 59931 # Okay, we got it. Check that it works. 59932 59933 POTENTIAL_FREETYPE_INCLUDE_PATH="$POTENTIAL_FREETYPE_INCLUDE_PATH" 59934 POTENTIAL_FREETYPE_LIB_PATH="$POTENTIAL_FREETYPE_LIB_PATH" 59935 METHOD="--with-freetype" 59936 59937 # Let's start with an optimistic view of the world :-) 59938 FOUND_FREETYPE=yes 59939 59940 # First look for the canonical freetype main include file ft2build.h. 59941 if ! test -s "$POTENTIAL_FREETYPE_INCLUDE_PATH/ft2build.h"; then 59942 # Oh no! Let's try in the freetype2 directory. This is needed at least at Mac OS X Yosemite. 59943 POTENTIAL_FREETYPE_INCLUDE_PATH="$POTENTIAL_FREETYPE_INCLUDE_PATH/freetype2" 59944 if ! test -s "$POTENTIAL_FREETYPE_INCLUDE_PATH/ft2build.h"; then 59945 # Fail. 59946 FOUND_FREETYPE=no 59947 fi 59948 fi 59949 59950 if test "x$FOUND_FREETYPE" = xyes; then 59951 # Include file found, let's continue the sanity check. 59952 { $as_echo "$as_me:${as_lineno-$LINENO}: Found freetype include files at $POTENTIAL_FREETYPE_INCLUDE_PATH using $METHOD" >&5 59953 $as_echo "$as_me: Found freetype include files at $POTENTIAL_FREETYPE_INCLUDE_PATH using $METHOD" >&6;} 59954 59955 # Reset to default value 59956 FREETYPE_BASE_NAME=freetype 59957 FREETYPE_LIB_NAME="${LIBRARY_PREFIX}${FREETYPE_BASE_NAME}${SHARED_LIBRARY_SUFFIX}" 59958 if ! test -s "$POTENTIAL_FREETYPE_LIB_PATH/$FREETYPE_LIB_NAME"; then 59959 if test "x$OPENJDK_TARGET_OS" = xmacosx \ 59960 && test -s "$POTENTIAL_FREETYPE_LIB_PATH/${LIBRARY_PREFIX}freetype.6${SHARED_LIBRARY_SUFFIX}"; then 59961 # On Mac OS X Yosemite, the symlink from libfreetype.dylib to libfreetype.6.dylib disappeared. Check 59962 # for the .6 version explicitly. 59963 FREETYPE_BASE_NAME=freetype.6 59964 FREETYPE_LIB_NAME="${LIBRARY_PREFIX}${FREETYPE_BASE_NAME}${SHARED_LIBRARY_SUFFIX}" 59965 { $as_echo "$as_me:${as_lineno-$LINENO}: Compensating for missing symlink by using version 6 explicitly" >&5 59966 $as_echo "$as_me: Compensating for missing symlink by using version 6 explicitly" >&6;} 59967 else 59968 { $as_echo "$as_me:${as_lineno-$LINENO}: Could not find $POTENTIAL_FREETYPE_LIB_PATH/$FREETYPE_LIB_NAME. Ignoring location." >&5 59969 $as_echo "$as_me: Could not find $POTENTIAL_FREETYPE_LIB_PATH/$FREETYPE_LIB_NAME. Ignoring location." >&6;} 59970 FOUND_FREETYPE=no 59971 fi 59972 else 59973 if test "x$OPENJDK_TARGET_OS" = xwindows; then 59974 # On Windows, we will need both .lib and .dll file. 59975 if ! test -s "$POTENTIAL_FREETYPE_LIB_PATH/${FREETYPE_BASE_NAME}.lib"; then 59976 { $as_echo "$as_me:${as_lineno-$LINENO}: Could not find $POTENTIAL_FREETYPE_LIB_PATH/${FREETYPE_BASE_NAME}.lib. Ignoring location." >&5 59977 $as_echo "$as_me: Could not find $POTENTIAL_FREETYPE_LIB_PATH/${FREETYPE_BASE_NAME}.lib. Ignoring location." >&6;} 59978 FOUND_FREETYPE=no 59979 fi 59980 elif test "x$OPENJDK_TARGET_OS" = xsolaris \ 59981 && test -s "$POTENTIAL_FREETYPE_LIB_PATH$OPENJDK_TARGET_CPU_ISADIR/$FREETYPE_LIB_NAME"; then 59982 # Found lib in isa dir, use that instead. 59983 POTENTIAL_FREETYPE_LIB_PATH="$POTENTIAL_FREETYPE_LIB_PATH$OPENJDK_TARGET_CPU_ISADIR" 59984 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting to use $POTENTIAL_FREETYPE_LIB_PATH instead" >&5 59985 $as_echo "$as_me: Rewriting to use $POTENTIAL_FREETYPE_LIB_PATH instead" >&6;} 59986 fi 59987 fi 59988 fi 59989 59990 if test "x$FOUND_FREETYPE" = xyes; then 59991 59992 # Only process if variable expands to non-empty 59993 59994 if test "x$POTENTIAL_FREETYPE_INCLUDE_PATH" != x; then 59995 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 59996 59997 # Input might be given as Windows format, start by converting to 59998 # unix format. 59999 path="$POTENTIAL_FREETYPE_INCLUDE_PATH" 60000 new_path=`$CYGPATH -u "$path"` 60001 60002 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 60003 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 60004 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 60005 # "foo.exe" is OK but "foo" is an error. 60006 # 60007 # This test is therefore slightly more accurate than "test -f" to check for file precense. 60008 # It is also a way to make sure we got the proper file name for the real test later on. 60009 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 60010 if test "x$test_shortpath" = x; then 60011 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&5 60012 $as_echo "$as_me: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&6;} 60013 as_fn_error $? "Cannot locate the the path of POTENTIAL_FREETYPE_INCLUDE_PATH" "$LINENO" 5 60014 fi 60015 60016 # Call helper function which possibly converts this using DOS-style short mode. 60017 # If so, the updated path is stored in $new_path. 60018 60019 input_path="$new_path" 60020 # Check if we need to convert this using DOS-style short mode. If the path 60021 # contains just simple characters, use it. Otherwise (spaces, weird characters), 60022 # take no chances and rewrite it. 60023 # Note: m4 eats our [], so we need to use [ and ] instead. 60024 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 60025 if test "x$has_forbidden_chars" != x; then 60026 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 60027 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 60028 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 60029 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 60030 # Going to short mode and back again did indeed matter. Since short mode is 60031 # case insensitive, let's make it lowercase to improve readability. 60032 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 60033 # Now convert it back to Unix-style (cygpath) 60034 input_path=`$CYGPATH -u "$shortmode_path"` 60035 new_path="$input_path" 60036 fi 60037 fi 60038 60039 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 60040 if test "x$test_cygdrive_prefix" = x; then 60041 # As a simple fix, exclude /usr/bin since it's not a real path. 60042 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 60043 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 60044 # a path prefixed by /cygdrive for fixpath to work. 60045 new_path="$CYGWIN_ROOT_PATH$input_path" 60046 fi 60047 fi 60048 60049 60050 if test "x$path" != "x$new_path"; then 60051 POTENTIAL_FREETYPE_INCLUDE_PATH="$new_path" 60052 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&5 60053 $as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&6;} 60054 fi 60055 60056 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 60057 60058 path="$POTENTIAL_FREETYPE_INCLUDE_PATH" 60059 has_colon=`$ECHO $path | $GREP ^.:` 60060 new_path="$path" 60061 if test "x$has_colon" = x; then 60062 # Not in mixed or Windows style, start by that. 60063 new_path=`cmd //c echo $path` 60064 fi 60065 60066 60067 input_path="$new_path" 60068 # Check if we need to convert this using DOS-style short mode. If the path 60069 # contains just simple characters, use it. Otherwise (spaces, weird characters), 60070 # take no chances and rewrite it. 60071 # Note: m4 eats our [], so we need to use [ and ] instead. 60072 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 60073 if test "x$has_forbidden_chars" != x; then 60074 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 60075 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 60076 fi 60077 60078 60079 windows_path="$new_path" 60080 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 60081 unix_path=`$CYGPATH -u "$windows_path"` 60082 new_path="$unix_path" 60083 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 60084 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 60085 new_path="$unix_path" 60086 fi 60087 60088 if test "x$path" != "x$new_path"; then 60089 POTENTIAL_FREETYPE_INCLUDE_PATH="$new_path" 60090 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&5 60091 $as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&6;} 60092 fi 60093 60094 # Save the first 10 bytes of this path to the storage, so fixpath can work. 60095 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 60096 60097 else 60098 # We're on a unix platform. Hooray! :) 60099 path="$POTENTIAL_FREETYPE_INCLUDE_PATH" 60100 has_space=`$ECHO "$path" | $GREP " "` 60101 if test "x$has_space" != x; then 60102 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&5 60103 $as_echo "$as_me: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&6;} 60104 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 60105 fi 60106 60107 # Use eval to expand a potential ~ 60108 eval path="$path" 60109 if test ! -f "$path" && test ! -d "$path"; then 60110 as_fn_error $? "The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is not found." "$LINENO" 5 60111 fi 60112 60113 if test -d "$path"; then 60114 POTENTIAL_FREETYPE_INCLUDE_PATH="`cd "$path"; $THEPWDCMD -L`" 60115 else 60116 dir="`$DIRNAME "$path"`" 60117 base="`$BASENAME "$path"`" 60118 POTENTIAL_FREETYPE_INCLUDE_PATH="`cd "$dir"; $THEPWDCMD -L`/$base" 60119 fi 60120 fi 60121 fi 60122 60123 60124 # Only process if variable expands to non-empty 60125 60126 if test "x$POTENTIAL_FREETYPE_LIB_PATH" != x; then 60127 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 60128 60129 # Input might be given as Windows format, start by converting to 60130 # unix format. 60131 path="$POTENTIAL_FREETYPE_LIB_PATH" 60132 new_path=`$CYGPATH -u "$path"` 60133 60134 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 60135 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 60136 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 60137 # "foo.exe" is OK but "foo" is an error. 60138 # 60139 # This test is therefore slightly more accurate than "test -f" to check for file precense. 60140 # It is also a way to make sure we got the proper file name for the real test later on. 60141 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 60142 if test "x$test_shortpath" = x; then 60143 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&5 60144 $as_echo "$as_me: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&6;} 60145 as_fn_error $? "Cannot locate the the path of POTENTIAL_FREETYPE_LIB_PATH" "$LINENO" 5 60146 fi 60147 60148 # Call helper function which possibly converts this using DOS-style short mode. 60149 # If so, the updated path is stored in $new_path. 60150 60151 input_path="$new_path" 60152 # Check if we need to convert this using DOS-style short mode. If the path 60153 # contains just simple characters, use it. Otherwise (spaces, weird characters), 60154 # take no chances and rewrite it. 60155 # Note: m4 eats our [], so we need to use [ and ] instead. 60156 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 60157 if test "x$has_forbidden_chars" != x; then 60158 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 60159 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 60160 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 60161 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 60162 # Going to short mode and back again did indeed matter. Since short mode is 60163 # case insensitive, let's make it lowercase to improve readability. 60164 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 60165 # Now convert it back to Unix-style (cygpath) 60166 input_path=`$CYGPATH -u "$shortmode_path"` 60167 new_path="$input_path" 60168 fi 60169 fi 60170 60171 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 60172 if test "x$test_cygdrive_prefix" = x; then 60173 # As a simple fix, exclude /usr/bin since it's not a real path. 60174 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 60175 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 60176 # a path prefixed by /cygdrive for fixpath to work. 60177 new_path="$CYGWIN_ROOT_PATH$input_path" 60178 fi 60179 fi 60180 60181 60182 if test "x$path" != "x$new_path"; then 60183 POTENTIAL_FREETYPE_LIB_PATH="$new_path" 60184 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&5 60185 $as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&6;} 60186 fi 60187 60188 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 60189 60190 path="$POTENTIAL_FREETYPE_LIB_PATH" 60191 has_colon=`$ECHO $path | $GREP ^.:` 60192 new_path="$path" 60193 if test "x$has_colon" = x; then 60194 # Not in mixed or Windows style, start by that. 60195 new_path=`cmd //c echo $path` 60196 fi 60197 60198 60199 input_path="$new_path" 60200 # Check if we need to convert this using DOS-style short mode. If the path 60201 # contains just simple characters, use it. Otherwise (spaces, weird characters), 60202 # take no chances and rewrite it. 60203 # Note: m4 eats our [], so we need to use [ and ] instead. 60204 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 60205 if test "x$has_forbidden_chars" != x; then 60206 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 60207 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 60208 fi 60209 60210 60211 windows_path="$new_path" 60212 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 60213 unix_path=`$CYGPATH -u "$windows_path"` 60214 new_path="$unix_path" 60215 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 60216 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 60217 new_path="$unix_path" 60218 fi 60219 60220 if test "x$path" != "x$new_path"; then 60221 POTENTIAL_FREETYPE_LIB_PATH="$new_path" 60222 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&5 60223 $as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&6;} 60224 fi 60225 60226 # Save the first 10 bytes of this path to the storage, so fixpath can work. 60227 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 60228 60229 else 60230 # We're on a unix platform. Hooray! :) 60231 path="$POTENTIAL_FREETYPE_LIB_PATH" 60232 has_space=`$ECHO "$path" | $GREP " "` 60233 if test "x$has_space" != x; then 60234 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&5 60235 $as_echo "$as_me: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&6;} 60236 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 60237 fi 60238 60239 # Use eval to expand a potential ~ 60240 eval path="$path" 60241 if test ! -f "$path" && test ! -d "$path"; then 60242 as_fn_error $? "The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is not found." "$LINENO" 5 60243 fi 60244 60245 if test -d "$path"; then 60246 POTENTIAL_FREETYPE_LIB_PATH="`cd "$path"; $THEPWDCMD -L`" 60247 else 60248 dir="`$DIRNAME "$path"`" 60249 base="`$BASENAME "$path"`" 60250 POTENTIAL_FREETYPE_LIB_PATH="`cd "$dir"; $THEPWDCMD -L`/$base" 60251 fi 60252 fi 60253 fi 60254 60255 60256 FREETYPE_INCLUDE_PATH="$POTENTIAL_FREETYPE_INCLUDE_PATH" 60257 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for freetype includes" >&5 60258 $as_echo_n "checking for freetype includes... " >&6; } 60259 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $FREETYPE_INCLUDE_PATH" >&5 60260 $as_echo "$FREETYPE_INCLUDE_PATH" >&6; } 60261 FREETYPE_LIB_PATH="$POTENTIAL_FREETYPE_LIB_PATH" 60262 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for freetype libraries" >&5 60263 $as_echo_n "checking for freetype libraries... " >&6; } 60264 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $FREETYPE_LIB_PATH" >&5 60265 $as_echo "$FREETYPE_LIB_PATH" >&6; } 60266 fi 60267 60268 if test "x$FOUND_FREETYPE" != xyes; then 60269 as_fn_error $? "Can not find or use freetype at location given by --with-freetype" "$LINENO" 5 60270 fi 60271 else 60272 # User specified only one of lib or include. This is an error. 60273 if test "x$POTENTIAL_FREETYPE_INCLUDE_PATH" = x ; then 60274 { $as_echo "$as_me:${as_lineno-$LINENO}: User specified --with-freetype-lib but not --with-freetype-include" >&5 60275 $as_echo "$as_me: User specified --with-freetype-lib but not --with-freetype-include" >&6;} 60276 as_fn_error $? "Need both freetype lib and include paths. Consider using --with-freetype instead." "$LINENO" 5 60277 else 60278 { $as_echo "$as_me:${as_lineno-$LINENO}: User specified --with-freetype-include but not --with-freetype-lib" >&5 60279 $as_echo "$as_me: User specified --with-freetype-include but not --with-freetype-lib" >&6;} 60280 as_fn_error $? "Need both freetype lib and include paths. Consider using --with-freetype instead." "$LINENO" 5 60281 fi 60282 fi 60283 else 60284 # User did not specify settings, but we need freetype. Try to locate it. 60285 60286 if test "x$BUNDLE_FREETYPE" = x; then 60287 # If not specified, default is to bundle freetype only on windows 60288 if test "x$OPENJDK_TARGET_OS" = xwindows; then 60289 BUNDLE_FREETYPE=yes 60290 else 60291 BUNDLE_FREETYPE=no 60292 fi 60293 fi 60294 60295 # If we have a sysroot, assume that's where we are supposed to look and skip pkg-config. 60296 if test "x$SYSROOT" = x; then 60297 if test "x$FOUND_FREETYPE" != xyes; then 60298 # Check modules using pkg-config, but only if we have it (ugly output results otherwise) 60299 if test "x$PKG_CONFIG" != x; then 60300 60301 pkg_failed=no 60302 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for FREETYPE" >&5 60303 $as_echo_n "checking for FREETYPE... " >&6; } 60304 60305 if test -n "$FREETYPE_CFLAGS"; then 60306 pkg_cv_FREETYPE_CFLAGS="$FREETYPE_CFLAGS" 60307 elif test -n "$PKG_CONFIG"; then 60308 if test -n "$PKG_CONFIG" && \ 60309 { { $as_echo "$as_me:${as_lineno-$LINENO}: \$PKG_CONFIG --exists --print-errors \"freetype2\""; } >&5 60310 ($PKG_CONFIG --exists --print-errors "freetype2") 2>&5 60311 ac_status=$? 60312 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 60313 test $ac_status = 0; }; then 60314 pkg_cv_FREETYPE_CFLAGS=`$PKG_CONFIG --cflags "freetype2" 2>/dev/null` 60315 else 60316 pkg_failed=yes 60317 fi 60318 else 60319 pkg_failed=untried 60320 fi 60321 if test -n "$FREETYPE_LIBS"; then 60322 pkg_cv_FREETYPE_LIBS="$FREETYPE_LIBS" 60323 elif test -n "$PKG_CONFIG"; then 60324 if test -n "$PKG_CONFIG" && \ 60325 { { $as_echo "$as_me:${as_lineno-$LINENO}: \$PKG_CONFIG --exists --print-errors \"freetype2\""; } >&5 60326 ($PKG_CONFIG --exists --print-errors "freetype2") 2>&5 60327 ac_status=$? 60328 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 60329 test $ac_status = 0; }; then 60330 pkg_cv_FREETYPE_LIBS=`$PKG_CONFIG --libs "freetype2" 2>/dev/null` 60331 else 60332 pkg_failed=yes 60333 fi 60334 else 60335 pkg_failed=untried 60336 fi 60337 60338 60339 60340 if test $pkg_failed = yes; then 60341 60342 if $PKG_CONFIG --atleast-pkgconfig-version 0.20; then 60343 _pkg_short_errors_supported=yes 60344 else 60345 _pkg_short_errors_supported=no 60346 fi 60347 if test $_pkg_short_errors_supported = yes; then 60348 FREETYPE_PKG_ERRORS=`$PKG_CONFIG --short-errors --print-errors "freetype2" 2>&1` 60349 else 60350 FREETYPE_PKG_ERRORS=`$PKG_CONFIG --print-errors "freetype2" 2>&1` 60351 fi 60352 # Put the nasty error message in config.log where it belongs 60353 echo "$FREETYPE_PKG_ERRORS" >&5 60354 60355 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 60356 $as_echo "no" >&6; } 60357 FOUND_FREETYPE=no 60358 elif test $pkg_failed = untried; then 60359 FOUND_FREETYPE=no 60360 else 60361 FREETYPE_CFLAGS=$pkg_cv_FREETYPE_CFLAGS 60362 FREETYPE_LIBS=$pkg_cv_FREETYPE_LIBS 60363 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 60364 $as_echo "yes" >&6; } 60365 FOUND_FREETYPE=yes 60366 fi 60367 if test "x$FOUND_FREETYPE" = xyes; then 60368 # On solaris, pkg_check adds -lz to freetype libs, which isn't necessary for us. 60369 FREETYPE_LIBS=`$ECHO $FREETYPE_LIBS | $SED 's/-lz//g'` 60370 # 64-bit libs for Solaris x86 are installed in the amd64 subdirectory, change lib to lib/amd64 60371 if test "x$OPENJDK_TARGET_OS" = xsolaris && test "x$OPENJDK_TARGET_CPU" = xx86_64; then 60372 FREETYPE_LIBS=`$ECHO $FREETYPE_LIBS | $SED 's?/lib?/lib/amd64?g'` 60373 fi 60374 # PKG_CHECK_MODULES will set FREETYPE_CFLAGS and _LIBS, but we don't get a lib path for bundling. 60375 if test "x$BUNDLE_FREETYPE" = xyes; then 60376 { $as_echo "$as_me:${as_lineno-$LINENO}: Found freetype using pkg-config, but ignoring since we can not bundle that" >&5 60377 $as_echo "$as_me: Found freetype using pkg-config, but ignoring since we can not bundle that" >&6;} 60378 FOUND_FREETYPE=no 60379 else 60380 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for freetype" >&5 60381 $as_echo_n "checking for freetype... " >&6; } 60382 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes (using pkg-config)" >&5 60383 $as_echo "yes (using pkg-config)" >&6; } 60384 fi 60385 fi 60386 fi 60387 fi 60388 fi 60389 60390 if test "x$FOUND_FREETYPE" != xyes; then 60391 # Check in well-known locations 60392 if test "x$OPENJDK_TARGET_OS" = xwindows; then 60393 FREETYPE_BASE_DIR="$PROGRAMFILES/GnuWin32" 60394 60395 windows_path="$FREETYPE_BASE_DIR" 60396 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 60397 unix_path=`$CYGPATH -u "$windows_path"` 60398 FREETYPE_BASE_DIR="$unix_path" 60399 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 60400 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 60401 FREETYPE_BASE_DIR="$unix_path" 60402 fi 60403 60404 60405 POTENTIAL_FREETYPE_INCLUDE_PATH="$FREETYPE_BASE_DIR/include" 60406 POTENTIAL_FREETYPE_LIB_PATH="$FREETYPE_BASE_DIR/lib" 60407 METHOD="well-known location" 60408 60409 # Let's start with an optimistic view of the world :-) 60410 FOUND_FREETYPE=yes 60411 60412 # First look for the canonical freetype main include file ft2build.h. 60413 if ! test -s "$POTENTIAL_FREETYPE_INCLUDE_PATH/ft2build.h"; then 60414 # Oh no! Let's try in the freetype2 directory. This is needed at least at Mac OS X Yosemite. 60415 POTENTIAL_FREETYPE_INCLUDE_PATH="$POTENTIAL_FREETYPE_INCLUDE_PATH/freetype2" 60416 if ! test -s "$POTENTIAL_FREETYPE_INCLUDE_PATH/ft2build.h"; then 60417 # Fail. 60418 FOUND_FREETYPE=no 60419 fi 60420 fi 60421 60422 if test "x$FOUND_FREETYPE" = xyes; then 60423 # Include file found, let's continue the sanity check. 60424 { $as_echo "$as_me:${as_lineno-$LINENO}: Found freetype include files at $POTENTIAL_FREETYPE_INCLUDE_PATH using $METHOD" >&5 60425 $as_echo "$as_me: Found freetype include files at $POTENTIAL_FREETYPE_INCLUDE_PATH using $METHOD" >&6;} 60426 60427 # Reset to default value 60428 FREETYPE_BASE_NAME=freetype 60429 FREETYPE_LIB_NAME="${LIBRARY_PREFIX}${FREETYPE_BASE_NAME}${SHARED_LIBRARY_SUFFIX}" 60430 if ! test -s "$POTENTIAL_FREETYPE_LIB_PATH/$FREETYPE_LIB_NAME"; then 60431 if test "x$OPENJDK_TARGET_OS" = xmacosx \ 60432 && test -s "$POTENTIAL_FREETYPE_LIB_PATH/${LIBRARY_PREFIX}freetype.6${SHARED_LIBRARY_SUFFIX}"; then 60433 # On Mac OS X Yosemite, the symlink from libfreetype.dylib to libfreetype.6.dylib disappeared. Check 60434 # for the .6 version explicitly. 60435 FREETYPE_BASE_NAME=freetype.6 60436 FREETYPE_LIB_NAME="${LIBRARY_PREFIX}${FREETYPE_BASE_NAME}${SHARED_LIBRARY_SUFFIX}" 60437 { $as_echo "$as_me:${as_lineno-$LINENO}: Compensating for missing symlink by using version 6 explicitly" >&5 60438 $as_echo "$as_me: Compensating for missing symlink by using version 6 explicitly" >&6;} 60439 else 60440 { $as_echo "$as_me:${as_lineno-$LINENO}: Could not find $POTENTIAL_FREETYPE_LIB_PATH/$FREETYPE_LIB_NAME. Ignoring location." >&5 60441 $as_echo "$as_me: Could not find $POTENTIAL_FREETYPE_LIB_PATH/$FREETYPE_LIB_NAME. Ignoring location." >&6;} 60442 FOUND_FREETYPE=no 60443 fi 60444 else 60445 if test "x$OPENJDK_TARGET_OS" = xwindows; then 60446 # On Windows, we will need both .lib and .dll file. 60447 if ! test -s "$POTENTIAL_FREETYPE_LIB_PATH/${FREETYPE_BASE_NAME}.lib"; then 60448 { $as_echo "$as_me:${as_lineno-$LINENO}: Could not find $POTENTIAL_FREETYPE_LIB_PATH/${FREETYPE_BASE_NAME}.lib. Ignoring location." >&5 60449 $as_echo "$as_me: Could not find $POTENTIAL_FREETYPE_LIB_PATH/${FREETYPE_BASE_NAME}.lib. Ignoring location." >&6;} 60450 FOUND_FREETYPE=no 60451 fi 60452 elif test "x$OPENJDK_TARGET_OS" = xsolaris \ 60453 && test -s "$POTENTIAL_FREETYPE_LIB_PATH$OPENJDK_TARGET_CPU_ISADIR/$FREETYPE_LIB_NAME"; then 60454 # Found lib in isa dir, use that instead. 60455 POTENTIAL_FREETYPE_LIB_PATH="$POTENTIAL_FREETYPE_LIB_PATH$OPENJDK_TARGET_CPU_ISADIR" 60456 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting to use $POTENTIAL_FREETYPE_LIB_PATH instead" >&5 60457 $as_echo "$as_me: Rewriting to use $POTENTIAL_FREETYPE_LIB_PATH instead" >&6;} 60458 fi 60459 fi 60460 fi 60461 60462 if test "x$FOUND_FREETYPE" = xyes; then 60463 60464 # Only process if variable expands to non-empty 60465 60466 if test "x$POTENTIAL_FREETYPE_INCLUDE_PATH" != x; then 60467 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 60468 60469 # Input might be given as Windows format, start by converting to 60470 # unix format. 60471 path="$POTENTIAL_FREETYPE_INCLUDE_PATH" 60472 new_path=`$CYGPATH -u "$path"` 60473 60474 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 60475 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 60476 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 60477 # "foo.exe" is OK but "foo" is an error. 60478 # 60479 # This test is therefore slightly more accurate than "test -f" to check for file precense. 60480 # It is also a way to make sure we got the proper file name for the real test later on. 60481 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 60482 if test "x$test_shortpath" = x; then 60483 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&5 60484 $as_echo "$as_me: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&6;} 60485 as_fn_error $? "Cannot locate the the path of POTENTIAL_FREETYPE_INCLUDE_PATH" "$LINENO" 5 60486 fi 60487 60488 # Call helper function which possibly converts this using DOS-style short mode. 60489 # If so, the updated path is stored in $new_path. 60490 60491 input_path="$new_path" 60492 # Check if we need to convert this using DOS-style short mode. If the path 60493 # contains just simple characters, use it. Otherwise (spaces, weird characters), 60494 # take no chances and rewrite it. 60495 # Note: m4 eats our [], so we need to use [ and ] instead. 60496 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 60497 if test "x$has_forbidden_chars" != x; then 60498 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 60499 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 60500 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 60501 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 60502 # Going to short mode and back again did indeed matter. Since short mode is 60503 # case insensitive, let's make it lowercase to improve readability. 60504 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 60505 # Now convert it back to Unix-style (cygpath) 60506 input_path=`$CYGPATH -u "$shortmode_path"` 60507 new_path="$input_path" 60508 fi 60509 fi 60510 60511 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 60512 if test "x$test_cygdrive_prefix" = x; then 60513 # As a simple fix, exclude /usr/bin since it's not a real path. 60514 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 60515 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 60516 # a path prefixed by /cygdrive for fixpath to work. 60517 new_path="$CYGWIN_ROOT_PATH$input_path" 60518 fi 60519 fi 60520 60521 60522 if test "x$path" != "x$new_path"; then 60523 POTENTIAL_FREETYPE_INCLUDE_PATH="$new_path" 60524 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&5 60525 $as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&6;} 60526 fi 60527 60528 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 60529 60530 path="$POTENTIAL_FREETYPE_INCLUDE_PATH" 60531 has_colon=`$ECHO $path | $GREP ^.:` 60532 new_path="$path" 60533 if test "x$has_colon" = x; then 60534 # Not in mixed or Windows style, start by that. 60535 new_path=`cmd //c echo $path` 60536 fi 60537 60538 60539 input_path="$new_path" 60540 # Check if we need to convert this using DOS-style short mode. If the path 60541 # contains just simple characters, use it. Otherwise (spaces, weird characters), 60542 # take no chances and rewrite it. 60543 # Note: m4 eats our [], so we need to use [ and ] instead. 60544 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 60545 if test "x$has_forbidden_chars" != x; then 60546 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 60547 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 60548 fi 60549 60550 60551 windows_path="$new_path" 60552 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 60553 unix_path=`$CYGPATH -u "$windows_path"` 60554 new_path="$unix_path" 60555 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 60556 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 60557 new_path="$unix_path" 60558 fi 60559 60560 if test "x$path" != "x$new_path"; then 60561 POTENTIAL_FREETYPE_INCLUDE_PATH="$new_path" 60562 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&5 60563 $as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&6;} 60564 fi 60565 60566 # Save the first 10 bytes of this path to the storage, so fixpath can work. 60567 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 60568 60569 else 60570 # We're on a unix platform. Hooray! :) 60571 path="$POTENTIAL_FREETYPE_INCLUDE_PATH" 60572 has_space=`$ECHO "$path" | $GREP " "` 60573 if test "x$has_space" != x; then 60574 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&5 60575 $as_echo "$as_me: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&6;} 60576 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 60577 fi 60578 60579 # Use eval to expand a potential ~ 60580 eval path="$path" 60581 if test ! -f "$path" && test ! -d "$path"; then 60582 as_fn_error $? "The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is not found." "$LINENO" 5 60583 fi 60584 60585 if test -d "$path"; then 60586 POTENTIAL_FREETYPE_INCLUDE_PATH="`cd "$path"; $THEPWDCMD -L`" 60587 else 60588 dir="`$DIRNAME "$path"`" 60589 base="`$BASENAME "$path"`" 60590 POTENTIAL_FREETYPE_INCLUDE_PATH="`cd "$dir"; $THEPWDCMD -L`/$base" 60591 fi 60592 fi 60593 fi 60594 60595 60596 # Only process if variable expands to non-empty 60597 60598 if test "x$POTENTIAL_FREETYPE_LIB_PATH" != x; then 60599 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 60600 60601 # Input might be given as Windows format, start by converting to 60602 # unix format. 60603 path="$POTENTIAL_FREETYPE_LIB_PATH" 60604 new_path=`$CYGPATH -u "$path"` 60605 60606 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 60607 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 60608 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 60609 # "foo.exe" is OK but "foo" is an error. 60610 # 60611 # This test is therefore slightly more accurate than "test -f" to check for file precense. 60612 # It is also a way to make sure we got the proper file name for the real test later on. 60613 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 60614 if test "x$test_shortpath" = x; then 60615 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&5 60616 $as_echo "$as_me: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&6;} 60617 as_fn_error $? "Cannot locate the the path of POTENTIAL_FREETYPE_LIB_PATH" "$LINENO" 5 60618 fi 60619 60620 # Call helper function which possibly converts this using DOS-style short mode. 60621 # If so, the updated path is stored in $new_path. 60622 60623 input_path="$new_path" 60624 # Check if we need to convert this using DOS-style short mode. If the path 60625 # contains just simple characters, use it. Otherwise (spaces, weird characters), 60626 # take no chances and rewrite it. 60627 # Note: m4 eats our [], so we need to use [ and ] instead. 60628 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 60629 if test "x$has_forbidden_chars" != x; then 60630 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 60631 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 60632 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 60633 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 60634 # Going to short mode and back again did indeed matter. Since short mode is 60635 # case insensitive, let's make it lowercase to improve readability. 60636 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 60637 # Now convert it back to Unix-style (cygpath) 60638 input_path=`$CYGPATH -u "$shortmode_path"` 60639 new_path="$input_path" 60640 fi 60641 fi 60642 60643 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 60644 if test "x$test_cygdrive_prefix" = x; then 60645 # As a simple fix, exclude /usr/bin since it's not a real path. 60646 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 60647 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 60648 # a path prefixed by /cygdrive for fixpath to work. 60649 new_path="$CYGWIN_ROOT_PATH$input_path" 60650 fi 60651 fi 60652 60653 60654 if test "x$path" != "x$new_path"; then 60655 POTENTIAL_FREETYPE_LIB_PATH="$new_path" 60656 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&5 60657 $as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&6;} 60658 fi 60659 60660 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 60661 60662 path="$POTENTIAL_FREETYPE_LIB_PATH" 60663 has_colon=`$ECHO $path | $GREP ^.:` 60664 new_path="$path" 60665 if test "x$has_colon" = x; then 60666 # Not in mixed or Windows style, start by that. 60667 new_path=`cmd //c echo $path` 60668 fi 60669 60670 60671 input_path="$new_path" 60672 # Check if we need to convert this using DOS-style short mode. If the path 60673 # contains just simple characters, use it. Otherwise (spaces, weird characters), 60674 # take no chances and rewrite it. 60675 # Note: m4 eats our [], so we need to use [ and ] instead. 60676 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 60677 if test "x$has_forbidden_chars" != x; then 60678 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 60679 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 60680 fi 60681 60682 60683 windows_path="$new_path" 60684 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 60685 unix_path=`$CYGPATH -u "$windows_path"` 60686 new_path="$unix_path" 60687 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 60688 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 60689 new_path="$unix_path" 60690 fi 60691 60692 if test "x$path" != "x$new_path"; then 60693 POTENTIAL_FREETYPE_LIB_PATH="$new_path" 60694 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&5 60695 $as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&6;} 60696 fi 60697 60698 # Save the first 10 bytes of this path to the storage, so fixpath can work. 60699 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 60700 60701 else 60702 # We're on a unix platform. Hooray! :) 60703 path="$POTENTIAL_FREETYPE_LIB_PATH" 60704 has_space=`$ECHO "$path" | $GREP " "` 60705 if test "x$has_space" != x; then 60706 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&5 60707 $as_echo "$as_me: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&6;} 60708 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 60709 fi 60710 60711 # Use eval to expand a potential ~ 60712 eval path="$path" 60713 if test ! -f "$path" && test ! -d "$path"; then 60714 as_fn_error $? "The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is not found." "$LINENO" 5 60715 fi 60716 60717 if test -d "$path"; then 60718 POTENTIAL_FREETYPE_LIB_PATH="`cd "$path"; $THEPWDCMD -L`" 60719 else 60720 dir="`$DIRNAME "$path"`" 60721 base="`$BASENAME "$path"`" 60722 POTENTIAL_FREETYPE_LIB_PATH="`cd "$dir"; $THEPWDCMD -L`/$base" 60723 fi 60724 fi 60725 fi 60726 60727 60728 FREETYPE_INCLUDE_PATH="$POTENTIAL_FREETYPE_INCLUDE_PATH" 60729 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for freetype includes" >&5 60730 $as_echo_n "checking for freetype includes... " >&6; } 60731 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $FREETYPE_INCLUDE_PATH" >&5 60732 $as_echo "$FREETYPE_INCLUDE_PATH" >&6; } 60733 FREETYPE_LIB_PATH="$POTENTIAL_FREETYPE_LIB_PATH" 60734 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for freetype libraries" >&5 60735 $as_echo_n "checking for freetype libraries... " >&6; } 60736 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $FREETYPE_LIB_PATH" >&5 60737 $as_echo "$FREETYPE_LIB_PATH" >&6; } 60738 fi 60739 60740 if test "x$FOUND_FREETYPE" != xyes; then 60741 FREETYPE_BASE_DIR="$ProgramW6432/GnuWin32" 60742 60743 windows_path="$FREETYPE_BASE_DIR" 60744 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 60745 unix_path=`$CYGPATH -u "$windows_path"` 60746 FREETYPE_BASE_DIR="$unix_path" 60747 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 60748 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 60749 FREETYPE_BASE_DIR="$unix_path" 60750 fi 60751 60752 60753 POTENTIAL_FREETYPE_INCLUDE_PATH="$FREETYPE_BASE_DIR/include" 60754 POTENTIAL_FREETYPE_LIB_PATH="$FREETYPE_BASE_DIR/lib" 60755 METHOD="well-known location" 60756 60757 # Let's start with an optimistic view of the world :-) 60758 FOUND_FREETYPE=yes 60759 60760 # First look for the canonical freetype main include file ft2build.h. 60761 if ! test -s "$POTENTIAL_FREETYPE_INCLUDE_PATH/ft2build.h"; then 60762 # Oh no! Let's try in the freetype2 directory. This is needed at least at Mac OS X Yosemite. 60763 POTENTIAL_FREETYPE_INCLUDE_PATH="$POTENTIAL_FREETYPE_INCLUDE_PATH/freetype2" 60764 if ! test -s "$POTENTIAL_FREETYPE_INCLUDE_PATH/ft2build.h"; then 60765 # Fail. 60766 FOUND_FREETYPE=no 60767 fi 60768 fi 60769 60770 if test "x$FOUND_FREETYPE" = xyes; then 60771 # Include file found, let's continue the sanity check. 60772 { $as_echo "$as_me:${as_lineno-$LINENO}: Found freetype include files at $POTENTIAL_FREETYPE_INCLUDE_PATH using $METHOD" >&5 60773 $as_echo "$as_me: Found freetype include files at $POTENTIAL_FREETYPE_INCLUDE_PATH using $METHOD" >&6;} 60774 60775 # Reset to default value 60776 FREETYPE_BASE_NAME=freetype 60777 FREETYPE_LIB_NAME="${LIBRARY_PREFIX}${FREETYPE_BASE_NAME}${SHARED_LIBRARY_SUFFIX}" 60778 if ! test -s "$POTENTIAL_FREETYPE_LIB_PATH/$FREETYPE_LIB_NAME"; then 60779 if test "x$OPENJDK_TARGET_OS" = xmacosx \ 60780 && test -s "$POTENTIAL_FREETYPE_LIB_PATH/${LIBRARY_PREFIX}freetype.6${SHARED_LIBRARY_SUFFIX}"; then 60781 # On Mac OS X Yosemite, the symlink from libfreetype.dylib to libfreetype.6.dylib disappeared. Check 60782 # for the .6 version explicitly. 60783 FREETYPE_BASE_NAME=freetype.6 60784 FREETYPE_LIB_NAME="${LIBRARY_PREFIX}${FREETYPE_BASE_NAME}${SHARED_LIBRARY_SUFFIX}" 60785 { $as_echo "$as_me:${as_lineno-$LINENO}: Compensating for missing symlink by using version 6 explicitly" >&5 60786 $as_echo "$as_me: Compensating for missing symlink by using version 6 explicitly" >&6;} 60787 else 60788 { $as_echo "$as_me:${as_lineno-$LINENO}: Could not find $POTENTIAL_FREETYPE_LIB_PATH/$FREETYPE_LIB_NAME. Ignoring location." >&5 60789 $as_echo "$as_me: Could not find $POTENTIAL_FREETYPE_LIB_PATH/$FREETYPE_LIB_NAME. Ignoring location." >&6;} 60790 FOUND_FREETYPE=no 60791 fi 60792 else 60793 if test "x$OPENJDK_TARGET_OS" = xwindows; then 60794 # On Windows, we will need both .lib and .dll file. 60795 if ! test -s "$POTENTIAL_FREETYPE_LIB_PATH/${FREETYPE_BASE_NAME}.lib"; then 60796 { $as_echo "$as_me:${as_lineno-$LINENO}: Could not find $POTENTIAL_FREETYPE_LIB_PATH/${FREETYPE_BASE_NAME}.lib. Ignoring location." >&5 60797 $as_echo "$as_me: Could not find $POTENTIAL_FREETYPE_LIB_PATH/${FREETYPE_BASE_NAME}.lib. Ignoring location." >&6;} 60798 FOUND_FREETYPE=no 60799 fi 60800 elif test "x$OPENJDK_TARGET_OS" = xsolaris \ 60801 && test -s "$POTENTIAL_FREETYPE_LIB_PATH$OPENJDK_TARGET_CPU_ISADIR/$FREETYPE_LIB_NAME"; then 60802 # Found lib in isa dir, use that instead. 60803 POTENTIAL_FREETYPE_LIB_PATH="$POTENTIAL_FREETYPE_LIB_PATH$OPENJDK_TARGET_CPU_ISADIR" 60804 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting to use $POTENTIAL_FREETYPE_LIB_PATH instead" >&5 60805 $as_echo "$as_me: Rewriting to use $POTENTIAL_FREETYPE_LIB_PATH instead" >&6;} 60806 fi 60807 fi 60808 fi 60809 60810 if test "x$FOUND_FREETYPE" = xyes; then 60811 60812 # Only process if variable expands to non-empty 60813 60814 if test "x$POTENTIAL_FREETYPE_INCLUDE_PATH" != x; then 60815 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 60816 60817 # Input might be given as Windows format, start by converting to 60818 # unix format. 60819 path="$POTENTIAL_FREETYPE_INCLUDE_PATH" 60820 new_path=`$CYGPATH -u "$path"` 60821 60822 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 60823 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 60824 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 60825 # "foo.exe" is OK but "foo" is an error. 60826 # 60827 # This test is therefore slightly more accurate than "test -f" to check for file precense. 60828 # It is also a way to make sure we got the proper file name for the real test later on. 60829 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 60830 if test "x$test_shortpath" = x; then 60831 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&5 60832 $as_echo "$as_me: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&6;} 60833 as_fn_error $? "Cannot locate the the path of POTENTIAL_FREETYPE_INCLUDE_PATH" "$LINENO" 5 60834 fi 60835 60836 # Call helper function which possibly converts this using DOS-style short mode. 60837 # If so, the updated path is stored in $new_path. 60838 60839 input_path="$new_path" 60840 # Check if we need to convert this using DOS-style short mode. If the path 60841 # contains just simple characters, use it. Otherwise (spaces, weird characters), 60842 # take no chances and rewrite it. 60843 # Note: m4 eats our [], so we need to use [ and ] instead. 60844 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 60845 if test "x$has_forbidden_chars" != x; then 60846 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 60847 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 60848 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 60849 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 60850 # Going to short mode and back again did indeed matter. Since short mode is 60851 # case insensitive, let's make it lowercase to improve readability. 60852 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 60853 # Now convert it back to Unix-style (cygpath) 60854 input_path=`$CYGPATH -u "$shortmode_path"` 60855 new_path="$input_path" 60856 fi 60857 fi 60858 60859 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 60860 if test "x$test_cygdrive_prefix" = x; then 60861 # As a simple fix, exclude /usr/bin since it's not a real path. 60862 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 60863 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 60864 # a path prefixed by /cygdrive for fixpath to work. 60865 new_path="$CYGWIN_ROOT_PATH$input_path" 60866 fi 60867 fi 60868 60869 60870 if test "x$path" != "x$new_path"; then 60871 POTENTIAL_FREETYPE_INCLUDE_PATH="$new_path" 60872 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&5 60873 $as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&6;} 60874 fi 60875 60876 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 60877 60878 path="$POTENTIAL_FREETYPE_INCLUDE_PATH" 60879 has_colon=`$ECHO $path | $GREP ^.:` 60880 new_path="$path" 60881 if test "x$has_colon" = x; then 60882 # Not in mixed or Windows style, start by that. 60883 new_path=`cmd //c echo $path` 60884 fi 60885 60886 60887 input_path="$new_path" 60888 # Check if we need to convert this using DOS-style short mode. If the path 60889 # contains just simple characters, use it. Otherwise (spaces, weird characters), 60890 # take no chances and rewrite it. 60891 # Note: m4 eats our [], so we need to use [ and ] instead. 60892 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 60893 if test "x$has_forbidden_chars" != x; then 60894 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 60895 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 60896 fi 60897 60898 60899 windows_path="$new_path" 60900 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 60901 unix_path=`$CYGPATH -u "$windows_path"` 60902 new_path="$unix_path" 60903 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 60904 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 60905 new_path="$unix_path" 60906 fi 60907 60908 if test "x$path" != "x$new_path"; then 60909 POTENTIAL_FREETYPE_INCLUDE_PATH="$new_path" 60910 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&5 60911 $as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&6;} 60912 fi 60913 60914 # Save the first 10 bytes of this path to the storage, so fixpath can work. 60915 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 60916 60917 else 60918 # We're on a unix platform. Hooray! :) 60919 path="$POTENTIAL_FREETYPE_INCLUDE_PATH" 60920 has_space=`$ECHO "$path" | $GREP " "` 60921 if test "x$has_space" != x; then 60922 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&5 60923 $as_echo "$as_me: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&6;} 60924 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 60925 fi 60926 60927 # Use eval to expand a potential ~ 60928 eval path="$path" 60929 if test ! -f "$path" && test ! -d "$path"; then 60930 as_fn_error $? "The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is not found." "$LINENO" 5 60931 fi 60932 60933 if test -d "$path"; then 60934 POTENTIAL_FREETYPE_INCLUDE_PATH="`cd "$path"; $THEPWDCMD -L`" 60935 else 60936 dir="`$DIRNAME "$path"`" 60937 base="`$BASENAME "$path"`" 60938 POTENTIAL_FREETYPE_INCLUDE_PATH="`cd "$dir"; $THEPWDCMD -L`/$base" 60939 fi 60940 fi 60941 fi 60942 60943 60944 # Only process if variable expands to non-empty 60945 60946 if test "x$POTENTIAL_FREETYPE_LIB_PATH" != x; then 60947 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 60948 60949 # Input might be given as Windows format, start by converting to 60950 # unix format. 60951 path="$POTENTIAL_FREETYPE_LIB_PATH" 60952 new_path=`$CYGPATH -u "$path"` 60953 60954 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 60955 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 60956 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 60957 # "foo.exe" is OK but "foo" is an error. 60958 # 60959 # This test is therefore slightly more accurate than "test -f" to check for file precense. 60960 # It is also a way to make sure we got the proper file name for the real test later on. 60961 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 60962 if test "x$test_shortpath" = x; then 60963 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&5 60964 $as_echo "$as_me: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&6;} 60965 as_fn_error $? "Cannot locate the the path of POTENTIAL_FREETYPE_LIB_PATH" "$LINENO" 5 60966 fi 60967 60968 # Call helper function which possibly converts this using DOS-style short mode. 60969 # If so, the updated path is stored in $new_path. 60970 60971 input_path="$new_path" 60972 # Check if we need to convert this using DOS-style short mode. If the path 60973 # contains just simple characters, use it. Otherwise (spaces, weird characters), 60974 # take no chances and rewrite it. 60975 # Note: m4 eats our [], so we need to use [ and ] instead. 60976 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 60977 if test "x$has_forbidden_chars" != x; then 60978 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 60979 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 60980 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 60981 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 60982 # Going to short mode and back again did indeed matter. Since short mode is 60983 # case insensitive, let's make it lowercase to improve readability. 60984 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 60985 # Now convert it back to Unix-style (cygpath) 60986 input_path=`$CYGPATH -u "$shortmode_path"` 60987 new_path="$input_path" 60988 fi 60989 fi 60990 60991 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 60992 if test "x$test_cygdrive_prefix" = x; then 60993 # As a simple fix, exclude /usr/bin since it's not a real path. 60994 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 60995 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 60996 # a path prefixed by /cygdrive for fixpath to work. 60997 new_path="$CYGWIN_ROOT_PATH$input_path" 60998 fi 60999 fi 61000 61001 61002 if test "x$path" != "x$new_path"; then 61003 POTENTIAL_FREETYPE_LIB_PATH="$new_path" 61004 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&5 61005 $as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&6;} 61006 fi 61007 61008 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 61009 61010 path="$POTENTIAL_FREETYPE_LIB_PATH" 61011 has_colon=`$ECHO $path | $GREP ^.:` 61012 new_path="$path" 61013 if test "x$has_colon" = x; then 61014 # Not in mixed or Windows style, start by that. 61015 new_path=`cmd //c echo $path` 61016 fi 61017 61018 61019 input_path="$new_path" 61020 # Check if we need to convert this using DOS-style short mode. If the path 61021 # contains just simple characters, use it. Otherwise (spaces, weird characters), 61022 # take no chances and rewrite it. 61023 # Note: m4 eats our [], so we need to use [ and ] instead. 61024 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 61025 if test "x$has_forbidden_chars" != x; then 61026 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 61027 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 61028 fi 61029 61030 61031 windows_path="$new_path" 61032 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 61033 unix_path=`$CYGPATH -u "$windows_path"` 61034 new_path="$unix_path" 61035 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 61036 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 61037 new_path="$unix_path" 61038 fi 61039 61040 if test "x$path" != "x$new_path"; then 61041 POTENTIAL_FREETYPE_LIB_PATH="$new_path" 61042 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&5 61043 $as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&6;} 61044 fi 61045 61046 # Save the first 10 bytes of this path to the storage, so fixpath can work. 61047 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 61048 61049 else 61050 # We're on a unix platform. Hooray! :) 61051 path="$POTENTIAL_FREETYPE_LIB_PATH" 61052 has_space=`$ECHO "$path" | $GREP " "` 61053 if test "x$has_space" != x; then 61054 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&5 61055 $as_echo "$as_me: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&6;} 61056 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 61057 fi 61058 61059 # Use eval to expand a potential ~ 61060 eval path="$path" 61061 if test ! -f "$path" && test ! -d "$path"; then 61062 as_fn_error $? "The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is not found." "$LINENO" 5 61063 fi 61064 61065 if test -d "$path"; then 61066 POTENTIAL_FREETYPE_LIB_PATH="`cd "$path"; $THEPWDCMD -L`" 61067 else 61068 dir="`$DIRNAME "$path"`" 61069 base="`$BASENAME "$path"`" 61070 POTENTIAL_FREETYPE_LIB_PATH="`cd "$dir"; $THEPWDCMD -L`/$base" 61071 fi 61072 fi 61073 fi 61074 61075 61076 FREETYPE_INCLUDE_PATH="$POTENTIAL_FREETYPE_INCLUDE_PATH" 61077 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for freetype includes" >&5 61078 $as_echo_n "checking for freetype includes... " >&6; } 61079 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $FREETYPE_INCLUDE_PATH" >&5 61080 $as_echo "$FREETYPE_INCLUDE_PATH" >&6; } 61081 FREETYPE_LIB_PATH="$POTENTIAL_FREETYPE_LIB_PATH" 61082 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for freetype libraries" >&5 61083 $as_echo_n "checking for freetype libraries... " >&6; } 61084 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $FREETYPE_LIB_PATH" >&5 61085 $as_echo "$FREETYPE_LIB_PATH" >&6; } 61086 fi 61087 61088 fi 61089 if test "x$FOUND_FREETYPE" != xyes; then 61090 FREETYPE_BASE_DIR="$HOME/freetype" 61091 61092 windows_path="$FREETYPE_BASE_DIR" 61093 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 61094 unix_path=`$CYGPATH -u "$windows_path"` 61095 FREETYPE_BASE_DIR="$unix_path" 61096 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 61097 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 61098 FREETYPE_BASE_DIR="$unix_path" 61099 fi 61100 61101 if test "x$OPENJDK_TARGET_CPU_BITS" = x64; then 61102 61103 POTENTIAL_FREETYPE_INCLUDE_PATH="$FREETYPE_BASE_DIR/include" 61104 POTENTIAL_FREETYPE_LIB_PATH="$FREETYPE_BASE_DIR/lib64" 61105 METHOD="well-known location" 61106 61107 # Let's start with an optimistic view of the world :-) 61108 FOUND_FREETYPE=yes 61109 61110 # First look for the canonical freetype main include file ft2build.h. 61111 if ! test -s "$POTENTIAL_FREETYPE_INCLUDE_PATH/ft2build.h"; then 61112 # Oh no! Let's try in the freetype2 directory. This is needed at least at Mac OS X Yosemite. 61113 POTENTIAL_FREETYPE_INCLUDE_PATH="$POTENTIAL_FREETYPE_INCLUDE_PATH/freetype2" 61114 if ! test -s "$POTENTIAL_FREETYPE_INCLUDE_PATH/ft2build.h"; then 61115 # Fail. 61116 FOUND_FREETYPE=no 61117 fi 61118 fi 61119 61120 if test "x$FOUND_FREETYPE" = xyes; then 61121 # Include file found, let's continue the sanity check. 61122 { $as_echo "$as_me:${as_lineno-$LINENO}: Found freetype include files at $POTENTIAL_FREETYPE_INCLUDE_PATH using $METHOD" >&5 61123 $as_echo "$as_me: Found freetype include files at $POTENTIAL_FREETYPE_INCLUDE_PATH using $METHOD" >&6;} 61124 61125 # Reset to default value 61126 FREETYPE_BASE_NAME=freetype 61127 FREETYPE_LIB_NAME="${LIBRARY_PREFIX}${FREETYPE_BASE_NAME}${SHARED_LIBRARY_SUFFIX}" 61128 if ! test -s "$POTENTIAL_FREETYPE_LIB_PATH/$FREETYPE_LIB_NAME"; then 61129 if test "x$OPENJDK_TARGET_OS" = xmacosx \ 61130 && test -s "$POTENTIAL_FREETYPE_LIB_PATH/${LIBRARY_PREFIX}freetype.6${SHARED_LIBRARY_SUFFIX}"; then 61131 # On Mac OS X Yosemite, the symlink from libfreetype.dylib to libfreetype.6.dylib disappeared. Check 61132 # for the .6 version explicitly. 61133 FREETYPE_BASE_NAME=freetype.6 61134 FREETYPE_LIB_NAME="${LIBRARY_PREFIX}${FREETYPE_BASE_NAME}${SHARED_LIBRARY_SUFFIX}" 61135 { $as_echo "$as_me:${as_lineno-$LINENO}: Compensating for missing symlink by using version 6 explicitly" >&5 61136 $as_echo "$as_me: Compensating for missing symlink by using version 6 explicitly" >&6;} 61137 else 61138 { $as_echo "$as_me:${as_lineno-$LINENO}: Could not find $POTENTIAL_FREETYPE_LIB_PATH/$FREETYPE_LIB_NAME. Ignoring location." >&5 61139 $as_echo "$as_me: Could not find $POTENTIAL_FREETYPE_LIB_PATH/$FREETYPE_LIB_NAME. Ignoring location." >&6;} 61140 FOUND_FREETYPE=no 61141 fi 61142 else 61143 if test "x$OPENJDK_TARGET_OS" = xwindows; then 61144 # On Windows, we will need both .lib and .dll file. 61145 if ! test -s "$POTENTIAL_FREETYPE_LIB_PATH/${FREETYPE_BASE_NAME}.lib"; then 61146 { $as_echo "$as_me:${as_lineno-$LINENO}: Could not find $POTENTIAL_FREETYPE_LIB_PATH/${FREETYPE_BASE_NAME}.lib. Ignoring location." >&5 61147 $as_echo "$as_me: Could not find $POTENTIAL_FREETYPE_LIB_PATH/${FREETYPE_BASE_NAME}.lib. Ignoring location." >&6;} 61148 FOUND_FREETYPE=no 61149 fi 61150 elif test "x$OPENJDK_TARGET_OS" = xsolaris \ 61151 && test -s "$POTENTIAL_FREETYPE_LIB_PATH$OPENJDK_TARGET_CPU_ISADIR/$FREETYPE_LIB_NAME"; then 61152 # Found lib in isa dir, use that instead. 61153 POTENTIAL_FREETYPE_LIB_PATH="$POTENTIAL_FREETYPE_LIB_PATH$OPENJDK_TARGET_CPU_ISADIR" 61154 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting to use $POTENTIAL_FREETYPE_LIB_PATH instead" >&5 61155 $as_echo "$as_me: Rewriting to use $POTENTIAL_FREETYPE_LIB_PATH instead" >&6;} 61156 fi 61157 fi 61158 fi 61159 61160 if test "x$FOUND_FREETYPE" = xyes; then 61161 61162 # Only process if variable expands to non-empty 61163 61164 if test "x$POTENTIAL_FREETYPE_INCLUDE_PATH" != x; then 61165 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 61166 61167 # Input might be given as Windows format, start by converting to 61168 # unix format. 61169 path="$POTENTIAL_FREETYPE_INCLUDE_PATH" 61170 new_path=`$CYGPATH -u "$path"` 61171 61172 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 61173 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 61174 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 61175 # "foo.exe" is OK but "foo" is an error. 61176 # 61177 # This test is therefore slightly more accurate than "test -f" to check for file precense. 61178 # It is also a way to make sure we got the proper file name for the real test later on. 61179 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 61180 if test "x$test_shortpath" = x; then 61181 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&5 61182 $as_echo "$as_me: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&6;} 61183 as_fn_error $? "Cannot locate the the path of POTENTIAL_FREETYPE_INCLUDE_PATH" "$LINENO" 5 61184 fi 61185 61186 # Call helper function which possibly converts this using DOS-style short mode. 61187 # If so, the updated path is stored in $new_path. 61188 61189 input_path="$new_path" 61190 # Check if we need to convert this using DOS-style short mode. If the path 61191 # contains just simple characters, use it. Otherwise (spaces, weird characters), 61192 # take no chances and rewrite it. 61193 # Note: m4 eats our [], so we need to use [ and ] instead. 61194 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 61195 if test "x$has_forbidden_chars" != x; then 61196 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 61197 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 61198 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 61199 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 61200 # Going to short mode and back again did indeed matter. Since short mode is 61201 # case insensitive, let's make it lowercase to improve readability. 61202 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 61203 # Now convert it back to Unix-style (cygpath) 61204 input_path=`$CYGPATH -u "$shortmode_path"` 61205 new_path="$input_path" 61206 fi 61207 fi 61208 61209 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 61210 if test "x$test_cygdrive_prefix" = x; then 61211 # As a simple fix, exclude /usr/bin since it's not a real path. 61212 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 61213 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 61214 # a path prefixed by /cygdrive for fixpath to work. 61215 new_path="$CYGWIN_ROOT_PATH$input_path" 61216 fi 61217 fi 61218 61219 61220 if test "x$path" != "x$new_path"; then 61221 POTENTIAL_FREETYPE_INCLUDE_PATH="$new_path" 61222 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&5 61223 $as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&6;} 61224 fi 61225 61226 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 61227 61228 path="$POTENTIAL_FREETYPE_INCLUDE_PATH" 61229 has_colon=`$ECHO $path | $GREP ^.:` 61230 new_path="$path" 61231 if test "x$has_colon" = x; then 61232 # Not in mixed or Windows style, start by that. 61233 new_path=`cmd //c echo $path` 61234 fi 61235 61236 61237 input_path="$new_path" 61238 # Check if we need to convert this using DOS-style short mode. If the path 61239 # contains just simple characters, use it. Otherwise (spaces, weird characters), 61240 # take no chances and rewrite it. 61241 # Note: m4 eats our [], so we need to use [ and ] instead. 61242 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 61243 if test "x$has_forbidden_chars" != x; then 61244 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 61245 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 61246 fi 61247 61248 61249 windows_path="$new_path" 61250 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 61251 unix_path=`$CYGPATH -u "$windows_path"` 61252 new_path="$unix_path" 61253 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 61254 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 61255 new_path="$unix_path" 61256 fi 61257 61258 if test "x$path" != "x$new_path"; then 61259 POTENTIAL_FREETYPE_INCLUDE_PATH="$new_path" 61260 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&5 61261 $as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&6;} 61262 fi 61263 61264 # Save the first 10 bytes of this path to the storage, so fixpath can work. 61265 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 61266 61267 else 61268 # We're on a unix platform. Hooray! :) 61269 path="$POTENTIAL_FREETYPE_INCLUDE_PATH" 61270 has_space=`$ECHO "$path" | $GREP " "` 61271 if test "x$has_space" != x; then 61272 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&5 61273 $as_echo "$as_me: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&6;} 61274 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 61275 fi 61276 61277 # Use eval to expand a potential ~ 61278 eval path="$path" 61279 if test ! -f "$path" && test ! -d "$path"; then 61280 as_fn_error $? "The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is not found." "$LINENO" 5 61281 fi 61282 61283 if test -d "$path"; then 61284 POTENTIAL_FREETYPE_INCLUDE_PATH="`cd "$path"; $THEPWDCMD -L`" 61285 else 61286 dir="`$DIRNAME "$path"`" 61287 base="`$BASENAME "$path"`" 61288 POTENTIAL_FREETYPE_INCLUDE_PATH="`cd "$dir"; $THEPWDCMD -L`/$base" 61289 fi 61290 fi 61291 fi 61292 61293 61294 # Only process if variable expands to non-empty 61295 61296 if test "x$POTENTIAL_FREETYPE_LIB_PATH" != x; then 61297 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 61298 61299 # Input might be given as Windows format, start by converting to 61300 # unix format. 61301 path="$POTENTIAL_FREETYPE_LIB_PATH" 61302 new_path=`$CYGPATH -u "$path"` 61303 61304 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 61305 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 61306 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 61307 # "foo.exe" is OK but "foo" is an error. 61308 # 61309 # This test is therefore slightly more accurate than "test -f" to check for file precense. 61310 # It is also a way to make sure we got the proper file name for the real test later on. 61311 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 61312 if test "x$test_shortpath" = x; then 61313 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&5 61314 $as_echo "$as_me: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&6;} 61315 as_fn_error $? "Cannot locate the the path of POTENTIAL_FREETYPE_LIB_PATH" "$LINENO" 5 61316 fi 61317 61318 # Call helper function which possibly converts this using DOS-style short mode. 61319 # If so, the updated path is stored in $new_path. 61320 61321 input_path="$new_path" 61322 # Check if we need to convert this using DOS-style short mode. If the path 61323 # contains just simple characters, use it. Otherwise (spaces, weird characters), 61324 # take no chances and rewrite it. 61325 # Note: m4 eats our [], so we need to use [ and ] instead. 61326 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 61327 if test "x$has_forbidden_chars" != x; then 61328 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 61329 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 61330 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 61331 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 61332 # Going to short mode and back again did indeed matter. Since short mode is 61333 # case insensitive, let's make it lowercase to improve readability. 61334 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 61335 # Now convert it back to Unix-style (cygpath) 61336 input_path=`$CYGPATH -u "$shortmode_path"` 61337 new_path="$input_path" 61338 fi 61339 fi 61340 61341 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 61342 if test "x$test_cygdrive_prefix" = x; then 61343 # As a simple fix, exclude /usr/bin since it's not a real path. 61344 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 61345 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 61346 # a path prefixed by /cygdrive for fixpath to work. 61347 new_path="$CYGWIN_ROOT_PATH$input_path" 61348 fi 61349 fi 61350 61351 61352 if test "x$path" != "x$new_path"; then 61353 POTENTIAL_FREETYPE_LIB_PATH="$new_path" 61354 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&5 61355 $as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&6;} 61356 fi 61357 61358 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 61359 61360 path="$POTENTIAL_FREETYPE_LIB_PATH" 61361 has_colon=`$ECHO $path | $GREP ^.:` 61362 new_path="$path" 61363 if test "x$has_colon" = x; then 61364 # Not in mixed or Windows style, start by that. 61365 new_path=`cmd //c echo $path` 61366 fi 61367 61368 61369 input_path="$new_path" 61370 # Check if we need to convert this using DOS-style short mode. If the path 61371 # contains just simple characters, use it. Otherwise (spaces, weird characters), 61372 # take no chances and rewrite it. 61373 # Note: m4 eats our [], so we need to use [ and ] instead. 61374 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 61375 if test "x$has_forbidden_chars" != x; then 61376 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 61377 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 61378 fi 61379 61380 61381 windows_path="$new_path" 61382 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 61383 unix_path=`$CYGPATH -u "$windows_path"` 61384 new_path="$unix_path" 61385 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 61386 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 61387 new_path="$unix_path" 61388 fi 61389 61390 if test "x$path" != "x$new_path"; then 61391 POTENTIAL_FREETYPE_LIB_PATH="$new_path" 61392 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&5 61393 $as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&6;} 61394 fi 61395 61396 # Save the first 10 bytes of this path to the storage, so fixpath can work. 61397 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 61398 61399 else 61400 # We're on a unix platform. Hooray! :) 61401 path="$POTENTIAL_FREETYPE_LIB_PATH" 61402 has_space=`$ECHO "$path" | $GREP " "` 61403 if test "x$has_space" != x; then 61404 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&5 61405 $as_echo "$as_me: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&6;} 61406 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 61407 fi 61408 61409 # Use eval to expand a potential ~ 61410 eval path="$path" 61411 if test ! -f "$path" && test ! -d "$path"; then 61412 as_fn_error $? "The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is not found." "$LINENO" 5 61413 fi 61414 61415 if test -d "$path"; then 61416 POTENTIAL_FREETYPE_LIB_PATH="`cd "$path"; $THEPWDCMD -L`" 61417 else 61418 dir="`$DIRNAME "$path"`" 61419 base="`$BASENAME "$path"`" 61420 POTENTIAL_FREETYPE_LIB_PATH="`cd "$dir"; $THEPWDCMD -L`/$base" 61421 fi 61422 fi 61423 fi 61424 61425 61426 FREETYPE_INCLUDE_PATH="$POTENTIAL_FREETYPE_INCLUDE_PATH" 61427 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for freetype includes" >&5 61428 $as_echo_n "checking for freetype includes... " >&6; } 61429 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $FREETYPE_INCLUDE_PATH" >&5 61430 $as_echo "$FREETYPE_INCLUDE_PATH" >&6; } 61431 FREETYPE_LIB_PATH="$POTENTIAL_FREETYPE_LIB_PATH" 61432 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for freetype libraries" >&5 61433 $as_echo_n "checking for freetype libraries... " >&6; } 61434 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $FREETYPE_LIB_PATH" >&5 61435 $as_echo "$FREETYPE_LIB_PATH" >&6; } 61436 fi 61437 61438 else 61439 61440 POTENTIAL_FREETYPE_INCLUDE_PATH="$FREETYPE_BASE_DIR/include" 61441 POTENTIAL_FREETYPE_LIB_PATH="$FREETYPE_BASE_DIR/lib32" 61442 METHOD="well-known location" 61443 61444 # Let's start with an optimistic view of the world :-) 61445 FOUND_FREETYPE=yes 61446 61447 # First look for the canonical freetype main include file ft2build.h. 61448 if ! test -s "$POTENTIAL_FREETYPE_INCLUDE_PATH/ft2build.h"; then 61449 # Oh no! Let's try in the freetype2 directory. This is needed at least at Mac OS X Yosemite. 61450 POTENTIAL_FREETYPE_INCLUDE_PATH="$POTENTIAL_FREETYPE_INCLUDE_PATH/freetype2" 61451 if ! test -s "$POTENTIAL_FREETYPE_INCLUDE_PATH/ft2build.h"; then 61452 # Fail. 61453 FOUND_FREETYPE=no 61454 fi 61455 fi 61456 61457 if test "x$FOUND_FREETYPE" = xyes; then 61458 # Include file found, let's continue the sanity check. 61459 { $as_echo "$as_me:${as_lineno-$LINENO}: Found freetype include files at $POTENTIAL_FREETYPE_INCLUDE_PATH using $METHOD" >&5 61460 $as_echo "$as_me: Found freetype include files at $POTENTIAL_FREETYPE_INCLUDE_PATH using $METHOD" >&6;} 61461 61462 # Reset to default value 61463 FREETYPE_BASE_NAME=freetype 61464 FREETYPE_LIB_NAME="${LIBRARY_PREFIX}${FREETYPE_BASE_NAME}${SHARED_LIBRARY_SUFFIX}" 61465 if ! test -s "$POTENTIAL_FREETYPE_LIB_PATH/$FREETYPE_LIB_NAME"; then 61466 if test "x$OPENJDK_TARGET_OS" = xmacosx \ 61467 && test -s "$POTENTIAL_FREETYPE_LIB_PATH/${LIBRARY_PREFIX}freetype.6${SHARED_LIBRARY_SUFFIX}"; then 61468 # On Mac OS X Yosemite, the symlink from libfreetype.dylib to libfreetype.6.dylib disappeared. Check 61469 # for the .6 version explicitly. 61470 FREETYPE_BASE_NAME=freetype.6 61471 FREETYPE_LIB_NAME="${LIBRARY_PREFIX}${FREETYPE_BASE_NAME}${SHARED_LIBRARY_SUFFIX}" 61472 { $as_echo "$as_me:${as_lineno-$LINENO}: Compensating for missing symlink by using version 6 explicitly" >&5 61473 $as_echo "$as_me: Compensating for missing symlink by using version 6 explicitly" >&6;} 61474 else 61475 { $as_echo "$as_me:${as_lineno-$LINENO}: Could not find $POTENTIAL_FREETYPE_LIB_PATH/$FREETYPE_LIB_NAME. Ignoring location." >&5 61476 $as_echo "$as_me: Could not find $POTENTIAL_FREETYPE_LIB_PATH/$FREETYPE_LIB_NAME. Ignoring location." >&6;} 61477 FOUND_FREETYPE=no 61478 fi 61479 else 61480 if test "x$OPENJDK_TARGET_OS" = xwindows; then 61481 # On Windows, we will need both .lib and .dll file. 61482 if ! test -s "$POTENTIAL_FREETYPE_LIB_PATH/${FREETYPE_BASE_NAME}.lib"; then 61483 { $as_echo "$as_me:${as_lineno-$LINENO}: Could not find $POTENTIAL_FREETYPE_LIB_PATH/${FREETYPE_BASE_NAME}.lib. Ignoring location." >&5 61484 $as_echo "$as_me: Could not find $POTENTIAL_FREETYPE_LIB_PATH/${FREETYPE_BASE_NAME}.lib. Ignoring location." >&6;} 61485 FOUND_FREETYPE=no 61486 fi 61487 elif test "x$OPENJDK_TARGET_OS" = xsolaris \ 61488 && test -s "$POTENTIAL_FREETYPE_LIB_PATH$OPENJDK_TARGET_CPU_ISADIR/$FREETYPE_LIB_NAME"; then 61489 # Found lib in isa dir, use that instead. 61490 POTENTIAL_FREETYPE_LIB_PATH="$POTENTIAL_FREETYPE_LIB_PATH$OPENJDK_TARGET_CPU_ISADIR" 61491 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting to use $POTENTIAL_FREETYPE_LIB_PATH instead" >&5 61492 $as_echo "$as_me: Rewriting to use $POTENTIAL_FREETYPE_LIB_PATH instead" >&6;} 61493 fi 61494 fi 61495 fi 61496 61497 if test "x$FOUND_FREETYPE" = xyes; then 61498 61499 # Only process if variable expands to non-empty 61500 61501 if test "x$POTENTIAL_FREETYPE_INCLUDE_PATH" != x; then 61502 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 61503 61504 # Input might be given as Windows format, start by converting to 61505 # unix format. 61506 path="$POTENTIAL_FREETYPE_INCLUDE_PATH" 61507 new_path=`$CYGPATH -u "$path"` 61508 61509 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 61510 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 61511 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 61512 # "foo.exe" is OK but "foo" is an error. 61513 # 61514 # This test is therefore slightly more accurate than "test -f" to check for file precense. 61515 # It is also a way to make sure we got the proper file name for the real test later on. 61516 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 61517 if test "x$test_shortpath" = x; then 61518 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&5 61519 $as_echo "$as_me: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&6;} 61520 as_fn_error $? "Cannot locate the the path of POTENTIAL_FREETYPE_INCLUDE_PATH" "$LINENO" 5 61521 fi 61522 61523 # Call helper function which possibly converts this using DOS-style short mode. 61524 # If so, the updated path is stored in $new_path. 61525 61526 input_path="$new_path" 61527 # Check if we need to convert this using DOS-style short mode. If the path 61528 # contains just simple characters, use it. Otherwise (spaces, weird characters), 61529 # take no chances and rewrite it. 61530 # Note: m4 eats our [], so we need to use [ and ] instead. 61531 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 61532 if test "x$has_forbidden_chars" != x; then 61533 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 61534 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 61535 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 61536 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 61537 # Going to short mode and back again did indeed matter. Since short mode is 61538 # case insensitive, let's make it lowercase to improve readability. 61539 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 61540 # Now convert it back to Unix-style (cygpath) 61541 input_path=`$CYGPATH -u "$shortmode_path"` 61542 new_path="$input_path" 61543 fi 61544 fi 61545 61546 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 61547 if test "x$test_cygdrive_prefix" = x; then 61548 # As a simple fix, exclude /usr/bin since it's not a real path. 61549 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 61550 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 61551 # a path prefixed by /cygdrive for fixpath to work. 61552 new_path="$CYGWIN_ROOT_PATH$input_path" 61553 fi 61554 fi 61555 61556 61557 if test "x$path" != "x$new_path"; then 61558 POTENTIAL_FREETYPE_INCLUDE_PATH="$new_path" 61559 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&5 61560 $as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&6;} 61561 fi 61562 61563 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 61564 61565 path="$POTENTIAL_FREETYPE_INCLUDE_PATH" 61566 has_colon=`$ECHO $path | $GREP ^.:` 61567 new_path="$path" 61568 if test "x$has_colon" = x; then 61569 # Not in mixed or Windows style, start by that. 61570 new_path=`cmd //c echo $path` 61571 fi 61572 61573 61574 input_path="$new_path" 61575 # Check if we need to convert this using DOS-style short mode. If the path 61576 # contains just simple characters, use it. Otherwise (spaces, weird characters), 61577 # take no chances and rewrite it. 61578 # Note: m4 eats our [], so we need to use [ and ] instead. 61579 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 61580 if test "x$has_forbidden_chars" != x; then 61581 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 61582 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 61583 fi 61584 61585 61586 windows_path="$new_path" 61587 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 61588 unix_path=`$CYGPATH -u "$windows_path"` 61589 new_path="$unix_path" 61590 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 61591 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 61592 new_path="$unix_path" 61593 fi 61594 61595 if test "x$path" != "x$new_path"; then 61596 POTENTIAL_FREETYPE_INCLUDE_PATH="$new_path" 61597 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&5 61598 $as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&6;} 61599 fi 61600 61601 # Save the first 10 bytes of this path to the storage, so fixpath can work. 61602 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 61603 61604 else 61605 # We're on a unix platform. Hooray! :) 61606 path="$POTENTIAL_FREETYPE_INCLUDE_PATH" 61607 has_space=`$ECHO "$path" | $GREP " "` 61608 if test "x$has_space" != x; then 61609 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&5 61610 $as_echo "$as_me: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&6;} 61611 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 61612 fi 61613 61614 # Use eval to expand a potential ~ 61615 eval path="$path" 61616 if test ! -f "$path" && test ! -d "$path"; then 61617 as_fn_error $? "The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is not found." "$LINENO" 5 61618 fi 61619 61620 if test -d "$path"; then 61621 POTENTIAL_FREETYPE_INCLUDE_PATH="`cd "$path"; $THEPWDCMD -L`" 61622 else 61623 dir="`$DIRNAME "$path"`" 61624 base="`$BASENAME "$path"`" 61625 POTENTIAL_FREETYPE_INCLUDE_PATH="`cd "$dir"; $THEPWDCMD -L`/$base" 61626 fi 61627 fi 61628 fi 61629 61630 61631 # Only process if variable expands to non-empty 61632 61633 if test "x$POTENTIAL_FREETYPE_LIB_PATH" != x; then 61634 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 61635 61636 # Input might be given as Windows format, start by converting to 61637 # unix format. 61638 path="$POTENTIAL_FREETYPE_LIB_PATH" 61639 new_path=`$CYGPATH -u "$path"` 61640 61641 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 61642 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 61643 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 61644 # "foo.exe" is OK but "foo" is an error. 61645 # 61646 # This test is therefore slightly more accurate than "test -f" to check for file precense. 61647 # It is also a way to make sure we got the proper file name for the real test later on. 61648 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 61649 if test "x$test_shortpath" = x; then 61650 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&5 61651 $as_echo "$as_me: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&6;} 61652 as_fn_error $? "Cannot locate the the path of POTENTIAL_FREETYPE_LIB_PATH" "$LINENO" 5 61653 fi 61654 61655 # Call helper function which possibly converts this using DOS-style short mode. 61656 # If so, the updated path is stored in $new_path. 61657 61658 input_path="$new_path" 61659 # Check if we need to convert this using DOS-style short mode. If the path 61660 # contains just simple characters, use it. Otherwise (spaces, weird characters), 61661 # take no chances and rewrite it. 61662 # Note: m4 eats our [], so we need to use [ and ] instead. 61663 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 61664 if test "x$has_forbidden_chars" != x; then 61665 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 61666 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 61667 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 61668 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 61669 # Going to short mode and back again did indeed matter. Since short mode is 61670 # case insensitive, let's make it lowercase to improve readability. 61671 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 61672 # Now convert it back to Unix-style (cygpath) 61673 input_path=`$CYGPATH -u "$shortmode_path"` 61674 new_path="$input_path" 61675 fi 61676 fi 61677 61678 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 61679 if test "x$test_cygdrive_prefix" = x; then 61680 # As a simple fix, exclude /usr/bin since it's not a real path. 61681 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 61682 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 61683 # a path prefixed by /cygdrive for fixpath to work. 61684 new_path="$CYGWIN_ROOT_PATH$input_path" 61685 fi 61686 fi 61687 61688 61689 if test "x$path" != "x$new_path"; then 61690 POTENTIAL_FREETYPE_LIB_PATH="$new_path" 61691 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&5 61692 $as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&6;} 61693 fi 61694 61695 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 61696 61697 path="$POTENTIAL_FREETYPE_LIB_PATH" 61698 has_colon=`$ECHO $path | $GREP ^.:` 61699 new_path="$path" 61700 if test "x$has_colon" = x; then 61701 # Not in mixed or Windows style, start by that. 61702 new_path=`cmd //c echo $path` 61703 fi 61704 61705 61706 input_path="$new_path" 61707 # Check if we need to convert this using DOS-style short mode. If the path 61708 # contains just simple characters, use it. Otherwise (spaces, weird characters), 61709 # take no chances and rewrite it. 61710 # Note: m4 eats our [], so we need to use [ and ] instead. 61711 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 61712 if test "x$has_forbidden_chars" != x; then 61713 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 61714 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 61715 fi 61716 61717 61718 windows_path="$new_path" 61719 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 61720 unix_path=`$CYGPATH -u "$windows_path"` 61721 new_path="$unix_path" 61722 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 61723 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 61724 new_path="$unix_path" 61725 fi 61726 61727 if test "x$path" != "x$new_path"; then 61728 POTENTIAL_FREETYPE_LIB_PATH="$new_path" 61729 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&5 61730 $as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&6;} 61731 fi 61732 61733 # Save the first 10 bytes of this path to the storage, so fixpath can work. 61734 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 61735 61736 else 61737 # We're on a unix platform. Hooray! :) 61738 path="$POTENTIAL_FREETYPE_LIB_PATH" 61739 has_space=`$ECHO "$path" | $GREP " "` 61740 if test "x$has_space" != x; then 61741 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&5 61742 $as_echo "$as_me: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&6;} 61743 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 61744 fi 61745 61746 # Use eval to expand a potential ~ 61747 eval path="$path" 61748 if test ! -f "$path" && test ! -d "$path"; then 61749 as_fn_error $? "The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is not found." "$LINENO" 5 61750 fi 61751 61752 if test -d "$path"; then 61753 POTENTIAL_FREETYPE_LIB_PATH="`cd "$path"; $THEPWDCMD -L`" 61754 else 61755 dir="`$DIRNAME "$path"`" 61756 base="`$BASENAME "$path"`" 61757 POTENTIAL_FREETYPE_LIB_PATH="`cd "$dir"; $THEPWDCMD -L`/$base" 61758 fi 61759 fi 61760 fi 61761 61762 61763 FREETYPE_INCLUDE_PATH="$POTENTIAL_FREETYPE_INCLUDE_PATH" 61764 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for freetype includes" >&5 61765 $as_echo_n "checking for freetype includes... " >&6; } 61766 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $FREETYPE_INCLUDE_PATH" >&5 61767 $as_echo "$FREETYPE_INCLUDE_PATH" >&6; } 61768 FREETYPE_LIB_PATH="$POTENTIAL_FREETYPE_LIB_PATH" 61769 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for freetype libraries" >&5 61770 $as_echo_n "checking for freetype libraries... " >&6; } 61771 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $FREETYPE_LIB_PATH" >&5 61772 $as_echo "$FREETYPE_LIB_PATH" >&6; } 61773 fi 61774 61775 fi 61776 if test "x$FOUND_FREETYPE" != xyes && test -d $FREETYPE_BASE_DIR \ 61777 && test -s "$FREETYPE_BASE_DIR/builds/windows/vc2010/freetype.vcxproj" && test "x$MSBUILD" != x; then 61778 # Source is available, as a last resort try to build freetype in default location 61779 61780 FREETYPE_SRC_PATH="$FREETYPE_BASE_DIR" 61781 BUILD_FREETYPE=yes 61782 61783 # Check if the freetype sources are acessible.. 61784 if ! test -d $FREETYPE_SRC_PATH; then 61785 { $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 61786 $as_echo "$as_me: WARNING: --with-freetype-src specified, but can not find path \"$FREETYPE_SRC_PATH\" - ignoring --with-freetype-src" >&2;} 61787 BUILD_FREETYPE=no 61788 fi 61789 # ..and contain a vc2010 project file 61790 vcxproj_path="$FREETYPE_SRC_PATH/builds/windows/vc2010/freetype.vcxproj" 61791 if test "x$BUILD_FREETYPE" = xyes && ! test -s $vcxproj_path; then 61792 { $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 61793 $as_echo "$as_me: WARNING: Can not find project file $vcxproj_path (you may try a newer freetype version) - ignoring --with-freetype-src" >&2;} 61794 BUILD_FREETYPE=no 61795 fi 61796 # Now check if configure found a version of 'msbuild.exe' 61797 if test "x$BUILD_FREETYPE" = xyes && test "x$MSBUILD" == x ; then 61798 { $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 61799 $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;} 61800 BUILD_FREETYPE=no 61801 fi 61802 61803 # Ready to go.. 61804 if test "x$BUILD_FREETYPE" = xyes; then 61805 # msbuild requires trailing slashes for output directories 61806 freetype_lib_path="$FREETYPE_SRC_PATH/lib$OPENJDK_TARGET_CPU_BITS/" 61807 freetype_lib_path_unix="$freetype_lib_path" 61808 freetype_obj_path="$FREETYPE_SRC_PATH/obj$OPENJDK_TARGET_CPU_BITS/" 61809 61810 unix_path="$vcxproj_path" 61811 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 61812 windows_path=`$CYGPATH -m "$unix_path"` 61813 vcxproj_path="$windows_path" 61814 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 61815 windows_path=`cmd //c echo $unix_path` 61816 vcxproj_path="$windows_path" 61817 fi 61818 61819 61820 unix_path="$freetype_lib_path" 61821 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 61822 windows_path=`$CYGPATH -m "$unix_path"` 61823 freetype_lib_path="$windows_path" 61824 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 61825 windows_path=`cmd //c echo $unix_path` 61826 freetype_lib_path="$windows_path" 61827 fi 61828 61829 61830 unix_path="$freetype_obj_path" 61831 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 61832 windows_path=`$CYGPATH -m "$unix_path"` 61833 freetype_obj_path="$windows_path" 61834 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 61835 windows_path=`cmd //c echo $unix_path` 61836 freetype_obj_path="$windows_path" 61837 fi 61838 61839 if test "x$OPENJDK_TARGET_CPU_BITS" = x64; then 61840 freetype_platform=x64 61841 else 61842 freetype_platform=win32 61843 fi 61844 61845 # The original freetype project file is for VS 2010 (i.e. 'v100'), 61846 # so we have to adapt the toolset if building with any other toolsed (i.e. SDK). 61847 # Currently 'PLATFORM_TOOLSET' is set in 'TOOLCHAIN_CHECK_POSSIBLE_VISUAL_STUDIO_ROOT'/ 61848 # 'TOOLCHAIN_CHECK_POSSIBLE_WIN_SDK_ROOT' in toolchain_windows.m4 61849 { $as_echo "$as_me:${as_lineno-$LINENO}: Trying to compile freetype sources with PlatformToolset=$PLATFORM_TOOLSET to $freetype_lib_path_unix ..." >&5 61850 $as_echo "$as_me: Trying to compile freetype sources with PlatformToolset=$PLATFORM_TOOLSET to $freetype_lib_path_unix ..." >&6;} 61851 61852 # First we try to build the freetype.dll 61853 $ECHO -e "@echo off\n"\ 61854 "$MSBUILD $vcxproj_path "\ 61855 "/p:PlatformToolset=$PLATFORM_TOOLSET "\ 61856 "/p:Configuration=\"Release Multithreaded\" "\ 61857 "/p:Platform=$freetype_platform "\ 61858 "/p:ConfigurationType=DynamicLibrary "\ 61859 "/p:TargetName=freetype "\ 61860 "/p:OutDir=\"$freetype_lib_path\" "\ 61861 "/p:IntDir=\"$freetype_obj_path\" > freetype.log" > freetype.bat 61862 cmd /c freetype.bat 61863 61864 if test -s "$freetype_lib_path_unix/freetype.dll"; then 61865 # If that succeeds we also build freetype.lib 61866 $ECHO -e "@echo off\n"\ 61867 "$MSBUILD $vcxproj_path "\ 61868 "/p:PlatformToolset=$PLATFORM_TOOLSET "\ 61869 "/p:Configuration=\"Release Multithreaded\" "\ 61870 "/p:Platform=$freetype_platform "\ 61871 "/p:ConfigurationType=StaticLibrary "\ 61872 "/p:TargetName=freetype "\ 61873 "/p:OutDir=\"$freetype_lib_path\" "\ 61874 "/p:IntDir=\"$freetype_obj_path\" >> freetype.log" > freetype.bat 61875 cmd /c freetype.bat 61876 61877 if test -s "$freetype_lib_path_unix/freetype.lib"; then 61878 # Once we build both, lib and dll, set freetype lib and include path appropriately 61879 POTENTIAL_FREETYPE_INCLUDE_PATH="$FREETYPE_SRC_PATH/include" 61880 POTENTIAL_FREETYPE_LIB_PATH="$freetype_lib_path_unix" 61881 { $as_echo "$as_me:${as_lineno-$LINENO}: Compiling freetype sources succeeded! (see freetype.log for build results)" >&5 61882 $as_echo "$as_me: Compiling freetype sources succeeded! (see freetype.log for build results)" >&6;} 61883 else 61884 BUILD_FREETYPE=no 61885 fi 61886 else 61887 BUILD_FREETYPE=no 61888 fi 61889 fi 61890 61891 if test "x$OPENJDK_TARGET_CPU_BITS" = x64; then 61892 61893 POTENTIAL_FREETYPE_INCLUDE_PATH="$FREETYPE_BASE_DIR/include" 61894 POTENTIAL_FREETYPE_LIB_PATH="$FREETYPE_BASE_DIR/lib64" 61895 METHOD="well-known location" 61896 61897 # Let's start with an optimistic view of the world :-) 61898 FOUND_FREETYPE=yes 61899 61900 # First look for the canonical freetype main include file ft2build.h. 61901 if ! test -s "$POTENTIAL_FREETYPE_INCLUDE_PATH/ft2build.h"; then 61902 # Oh no! Let's try in the freetype2 directory. This is needed at least at Mac OS X Yosemite. 61903 POTENTIAL_FREETYPE_INCLUDE_PATH="$POTENTIAL_FREETYPE_INCLUDE_PATH/freetype2" 61904 if ! test -s "$POTENTIAL_FREETYPE_INCLUDE_PATH/ft2build.h"; then 61905 # Fail. 61906 FOUND_FREETYPE=no 61907 fi 61908 fi 61909 61910 if test "x$FOUND_FREETYPE" = xyes; then 61911 # Include file found, let's continue the sanity check. 61912 { $as_echo "$as_me:${as_lineno-$LINENO}: Found freetype include files at $POTENTIAL_FREETYPE_INCLUDE_PATH using $METHOD" >&5 61913 $as_echo "$as_me: Found freetype include files at $POTENTIAL_FREETYPE_INCLUDE_PATH using $METHOD" >&6;} 61914 61915 # Reset to default value 61916 FREETYPE_BASE_NAME=freetype 61917 FREETYPE_LIB_NAME="${LIBRARY_PREFIX}${FREETYPE_BASE_NAME}${SHARED_LIBRARY_SUFFIX}" 61918 if ! test -s "$POTENTIAL_FREETYPE_LIB_PATH/$FREETYPE_LIB_NAME"; then 61919 if test "x$OPENJDK_TARGET_OS" = xmacosx \ 61920 && test -s "$POTENTIAL_FREETYPE_LIB_PATH/${LIBRARY_PREFIX}freetype.6${SHARED_LIBRARY_SUFFIX}"; then 61921 # On Mac OS X Yosemite, the symlink from libfreetype.dylib to libfreetype.6.dylib disappeared. Check 61922 # for the .6 version explicitly. 61923 FREETYPE_BASE_NAME=freetype.6 61924 FREETYPE_LIB_NAME="${LIBRARY_PREFIX}${FREETYPE_BASE_NAME}${SHARED_LIBRARY_SUFFIX}" 61925 { $as_echo "$as_me:${as_lineno-$LINENO}: Compensating for missing symlink by using version 6 explicitly" >&5 61926 $as_echo "$as_me: Compensating for missing symlink by using version 6 explicitly" >&6;} 61927 else 61928 { $as_echo "$as_me:${as_lineno-$LINENO}: Could not find $POTENTIAL_FREETYPE_LIB_PATH/$FREETYPE_LIB_NAME. Ignoring location." >&5 61929 $as_echo "$as_me: Could not find $POTENTIAL_FREETYPE_LIB_PATH/$FREETYPE_LIB_NAME. Ignoring location." >&6;} 61930 FOUND_FREETYPE=no 61931 fi 61932 else 61933 if test "x$OPENJDK_TARGET_OS" = xwindows; then 61934 # On Windows, we will need both .lib and .dll file. 61935 if ! test -s "$POTENTIAL_FREETYPE_LIB_PATH/${FREETYPE_BASE_NAME}.lib"; then 61936 { $as_echo "$as_me:${as_lineno-$LINENO}: Could not find $POTENTIAL_FREETYPE_LIB_PATH/${FREETYPE_BASE_NAME}.lib. Ignoring location." >&5 61937 $as_echo "$as_me: Could not find $POTENTIAL_FREETYPE_LIB_PATH/${FREETYPE_BASE_NAME}.lib. Ignoring location." >&6;} 61938 FOUND_FREETYPE=no 61939 fi 61940 elif test "x$OPENJDK_TARGET_OS" = xsolaris \ 61941 && test -s "$POTENTIAL_FREETYPE_LIB_PATH$OPENJDK_TARGET_CPU_ISADIR/$FREETYPE_LIB_NAME"; then 61942 # Found lib in isa dir, use that instead. 61943 POTENTIAL_FREETYPE_LIB_PATH="$POTENTIAL_FREETYPE_LIB_PATH$OPENJDK_TARGET_CPU_ISADIR" 61944 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting to use $POTENTIAL_FREETYPE_LIB_PATH instead" >&5 61945 $as_echo "$as_me: Rewriting to use $POTENTIAL_FREETYPE_LIB_PATH instead" >&6;} 61946 fi 61947 fi 61948 fi 61949 61950 if test "x$FOUND_FREETYPE" = xyes; then 61951 61952 # Only process if variable expands to non-empty 61953 61954 if test "x$POTENTIAL_FREETYPE_INCLUDE_PATH" != x; then 61955 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 61956 61957 # Input might be given as Windows format, start by converting to 61958 # unix format. 61959 path="$POTENTIAL_FREETYPE_INCLUDE_PATH" 61960 new_path=`$CYGPATH -u "$path"` 61961 61962 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 61963 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 61964 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 61965 # "foo.exe" is OK but "foo" is an error. 61966 # 61967 # This test is therefore slightly more accurate than "test -f" to check for file precense. 61968 # It is also a way to make sure we got the proper file name for the real test later on. 61969 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 61970 if test "x$test_shortpath" = x; then 61971 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&5 61972 $as_echo "$as_me: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&6;} 61973 as_fn_error $? "Cannot locate the the path of POTENTIAL_FREETYPE_INCLUDE_PATH" "$LINENO" 5 61974 fi 61975 61976 # Call helper function which possibly converts this using DOS-style short mode. 61977 # If so, the updated path is stored in $new_path. 61978 61979 input_path="$new_path" 61980 # Check if we need to convert this using DOS-style short mode. If the path 61981 # contains just simple characters, use it. Otherwise (spaces, weird characters), 61982 # take no chances and rewrite it. 61983 # Note: m4 eats our [], so we need to use [ and ] instead. 61984 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 61985 if test "x$has_forbidden_chars" != x; then 61986 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 61987 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 61988 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 61989 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 61990 # Going to short mode and back again did indeed matter. Since short mode is 61991 # case insensitive, let's make it lowercase to improve readability. 61992 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 61993 # Now convert it back to Unix-style (cygpath) 61994 input_path=`$CYGPATH -u "$shortmode_path"` 61995 new_path="$input_path" 61996 fi 61997 fi 61998 61999 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 62000 if test "x$test_cygdrive_prefix" = x; then 62001 # As a simple fix, exclude /usr/bin since it's not a real path. 62002 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 62003 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 62004 # a path prefixed by /cygdrive for fixpath to work. 62005 new_path="$CYGWIN_ROOT_PATH$input_path" 62006 fi 62007 fi 62008 62009 62010 if test "x$path" != "x$new_path"; then 62011 POTENTIAL_FREETYPE_INCLUDE_PATH="$new_path" 62012 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&5 62013 $as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&6;} 62014 fi 62015 62016 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 62017 62018 path="$POTENTIAL_FREETYPE_INCLUDE_PATH" 62019 has_colon=`$ECHO $path | $GREP ^.:` 62020 new_path="$path" 62021 if test "x$has_colon" = x; then 62022 # Not in mixed or Windows style, start by that. 62023 new_path=`cmd //c echo $path` 62024 fi 62025 62026 62027 input_path="$new_path" 62028 # Check if we need to convert this using DOS-style short mode. If the path 62029 # contains just simple characters, use it. Otherwise (spaces, weird characters), 62030 # take no chances and rewrite it. 62031 # Note: m4 eats our [], so we need to use [ and ] instead. 62032 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 62033 if test "x$has_forbidden_chars" != x; then 62034 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 62035 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 62036 fi 62037 62038 62039 windows_path="$new_path" 62040 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 62041 unix_path=`$CYGPATH -u "$windows_path"` 62042 new_path="$unix_path" 62043 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 62044 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 62045 new_path="$unix_path" 62046 fi 62047 62048 if test "x$path" != "x$new_path"; then 62049 POTENTIAL_FREETYPE_INCLUDE_PATH="$new_path" 62050 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&5 62051 $as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&6;} 62052 fi 62053 62054 # Save the first 10 bytes of this path to the storage, so fixpath can work. 62055 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 62056 62057 else 62058 # We're on a unix platform. Hooray! :) 62059 path="$POTENTIAL_FREETYPE_INCLUDE_PATH" 62060 has_space=`$ECHO "$path" | $GREP " "` 62061 if test "x$has_space" != x; then 62062 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&5 62063 $as_echo "$as_me: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&6;} 62064 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 62065 fi 62066 62067 # Use eval to expand a potential ~ 62068 eval path="$path" 62069 if test ! -f "$path" && test ! -d "$path"; then 62070 as_fn_error $? "The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is not found." "$LINENO" 5 62071 fi 62072 62073 if test -d "$path"; then 62074 POTENTIAL_FREETYPE_INCLUDE_PATH="`cd "$path"; $THEPWDCMD -L`" 62075 else 62076 dir="`$DIRNAME "$path"`" 62077 base="`$BASENAME "$path"`" 62078 POTENTIAL_FREETYPE_INCLUDE_PATH="`cd "$dir"; $THEPWDCMD -L`/$base" 62079 fi 62080 fi 62081 fi 62082 62083 62084 # Only process if variable expands to non-empty 62085 62086 if test "x$POTENTIAL_FREETYPE_LIB_PATH" != x; then 62087 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 62088 62089 # Input might be given as Windows format, start by converting to 62090 # unix format. 62091 path="$POTENTIAL_FREETYPE_LIB_PATH" 62092 new_path=`$CYGPATH -u "$path"` 62093 62094 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 62095 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 62096 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 62097 # "foo.exe" is OK but "foo" is an error. 62098 # 62099 # This test is therefore slightly more accurate than "test -f" to check for file precense. 62100 # It is also a way to make sure we got the proper file name for the real test later on. 62101 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 62102 if test "x$test_shortpath" = x; then 62103 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&5 62104 $as_echo "$as_me: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&6;} 62105 as_fn_error $? "Cannot locate the the path of POTENTIAL_FREETYPE_LIB_PATH" "$LINENO" 5 62106 fi 62107 62108 # Call helper function which possibly converts this using DOS-style short mode. 62109 # If so, the updated path is stored in $new_path. 62110 62111 input_path="$new_path" 62112 # Check if we need to convert this using DOS-style short mode. If the path 62113 # contains just simple characters, use it. Otherwise (spaces, weird characters), 62114 # take no chances and rewrite it. 62115 # Note: m4 eats our [], so we need to use [ and ] instead. 62116 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 62117 if test "x$has_forbidden_chars" != x; then 62118 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 62119 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 62120 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 62121 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 62122 # Going to short mode and back again did indeed matter. Since short mode is 62123 # case insensitive, let's make it lowercase to improve readability. 62124 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 62125 # Now convert it back to Unix-style (cygpath) 62126 input_path=`$CYGPATH -u "$shortmode_path"` 62127 new_path="$input_path" 62128 fi 62129 fi 62130 62131 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 62132 if test "x$test_cygdrive_prefix" = x; then 62133 # As a simple fix, exclude /usr/bin since it's not a real path. 62134 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 62135 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 62136 # a path prefixed by /cygdrive for fixpath to work. 62137 new_path="$CYGWIN_ROOT_PATH$input_path" 62138 fi 62139 fi 62140 62141 62142 if test "x$path" != "x$new_path"; then 62143 POTENTIAL_FREETYPE_LIB_PATH="$new_path" 62144 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&5 62145 $as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&6;} 62146 fi 62147 62148 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 62149 62150 path="$POTENTIAL_FREETYPE_LIB_PATH" 62151 has_colon=`$ECHO $path | $GREP ^.:` 62152 new_path="$path" 62153 if test "x$has_colon" = x; then 62154 # Not in mixed or Windows style, start by that. 62155 new_path=`cmd //c echo $path` 62156 fi 62157 62158 62159 input_path="$new_path" 62160 # Check if we need to convert this using DOS-style short mode. If the path 62161 # contains just simple characters, use it. Otherwise (spaces, weird characters), 62162 # take no chances and rewrite it. 62163 # Note: m4 eats our [], so we need to use [ and ] instead. 62164 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 62165 if test "x$has_forbidden_chars" != x; then 62166 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 62167 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 62168 fi 62169 62170 62171 windows_path="$new_path" 62172 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 62173 unix_path=`$CYGPATH -u "$windows_path"` 62174 new_path="$unix_path" 62175 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 62176 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 62177 new_path="$unix_path" 62178 fi 62179 62180 if test "x$path" != "x$new_path"; then 62181 POTENTIAL_FREETYPE_LIB_PATH="$new_path" 62182 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&5 62183 $as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&6;} 62184 fi 62185 62186 # Save the first 10 bytes of this path to the storage, so fixpath can work. 62187 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 62188 62189 else 62190 # We're on a unix platform. Hooray! :) 62191 path="$POTENTIAL_FREETYPE_LIB_PATH" 62192 has_space=`$ECHO "$path" | $GREP " "` 62193 if test "x$has_space" != x; then 62194 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&5 62195 $as_echo "$as_me: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&6;} 62196 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 62197 fi 62198 62199 # Use eval to expand a potential ~ 62200 eval path="$path" 62201 if test ! -f "$path" && test ! -d "$path"; then 62202 as_fn_error $? "The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is not found." "$LINENO" 5 62203 fi 62204 62205 if test -d "$path"; then 62206 POTENTIAL_FREETYPE_LIB_PATH="`cd "$path"; $THEPWDCMD -L`" 62207 else 62208 dir="`$DIRNAME "$path"`" 62209 base="`$BASENAME "$path"`" 62210 POTENTIAL_FREETYPE_LIB_PATH="`cd "$dir"; $THEPWDCMD -L`/$base" 62211 fi 62212 fi 62213 fi 62214 62215 62216 FREETYPE_INCLUDE_PATH="$POTENTIAL_FREETYPE_INCLUDE_PATH" 62217 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for freetype includes" >&5 62218 $as_echo_n "checking for freetype includes... " >&6; } 62219 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $FREETYPE_INCLUDE_PATH" >&5 62220 $as_echo "$FREETYPE_INCLUDE_PATH" >&6; } 62221 FREETYPE_LIB_PATH="$POTENTIAL_FREETYPE_LIB_PATH" 62222 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for freetype libraries" >&5 62223 $as_echo_n "checking for freetype libraries... " >&6; } 62224 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $FREETYPE_LIB_PATH" >&5 62225 $as_echo "$FREETYPE_LIB_PATH" >&6; } 62226 fi 62227 62228 else 62229 62230 POTENTIAL_FREETYPE_INCLUDE_PATH="$FREETYPE_BASE_DIR/include" 62231 POTENTIAL_FREETYPE_LIB_PATH="$FREETYPE_BASE_DIR/lib32" 62232 METHOD="well-known location" 62233 62234 # Let's start with an optimistic view of the world :-) 62235 FOUND_FREETYPE=yes 62236 62237 # First look for the canonical freetype main include file ft2build.h. 62238 if ! test -s "$POTENTIAL_FREETYPE_INCLUDE_PATH/ft2build.h"; then 62239 # Oh no! Let's try in the freetype2 directory. This is needed at least at Mac OS X Yosemite. 62240 POTENTIAL_FREETYPE_INCLUDE_PATH="$POTENTIAL_FREETYPE_INCLUDE_PATH/freetype2" 62241 if ! test -s "$POTENTIAL_FREETYPE_INCLUDE_PATH/ft2build.h"; then 62242 # Fail. 62243 FOUND_FREETYPE=no 62244 fi 62245 fi 62246 62247 if test "x$FOUND_FREETYPE" = xyes; then 62248 # Include file found, let's continue the sanity check. 62249 { $as_echo "$as_me:${as_lineno-$LINENO}: Found freetype include files at $POTENTIAL_FREETYPE_INCLUDE_PATH using $METHOD" >&5 62250 $as_echo "$as_me: Found freetype include files at $POTENTIAL_FREETYPE_INCLUDE_PATH using $METHOD" >&6;} 62251 62252 # Reset to default value 62253 FREETYPE_BASE_NAME=freetype 62254 FREETYPE_LIB_NAME="${LIBRARY_PREFIX}${FREETYPE_BASE_NAME}${SHARED_LIBRARY_SUFFIX}" 62255 if ! test -s "$POTENTIAL_FREETYPE_LIB_PATH/$FREETYPE_LIB_NAME"; then 62256 if test "x$OPENJDK_TARGET_OS" = xmacosx \ 62257 && test -s "$POTENTIAL_FREETYPE_LIB_PATH/${LIBRARY_PREFIX}freetype.6${SHARED_LIBRARY_SUFFIX}"; then 62258 # On Mac OS X Yosemite, the symlink from libfreetype.dylib to libfreetype.6.dylib disappeared. Check 62259 # for the .6 version explicitly. 62260 FREETYPE_BASE_NAME=freetype.6 62261 FREETYPE_LIB_NAME="${LIBRARY_PREFIX}${FREETYPE_BASE_NAME}${SHARED_LIBRARY_SUFFIX}" 62262 { $as_echo "$as_me:${as_lineno-$LINENO}: Compensating for missing symlink by using version 6 explicitly" >&5 62263 $as_echo "$as_me: Compensating for missing symlink by using version 6 explicitly" >&6;} 62264 else 62265 { $as_echo "$as_me:${as_lineno-$LINENO}: Could not find $POTENTIAL_FREETYPE_LIB_PATH/$FREETYPE_LIB_NAME. Ignoring location." >&5 62266 $as_echo "$as_me: Could not find $POTENTIAL_FREETYPE_LIB_PATH/$FREETYPE_LIB_NAME. Ignoring location." >&6;} 62267 FOUND_FREETYPE=no 62268 fi 62269 else 62270 if test "x$OPENJDK_TARGET_OS" = xwindows; then 62271 # On Windows, we will need both .lib and .dll file. 62272 if ! test -s "$POTENTIAL_FREETYPE_LIB_PATH/${FREETYPE_BASE_NAME}.lib"; then 62273 { $as_echo "$as_me:${as_lineno-$LINENO}: Could not find $POTENTIAL_FREETYPE_LIB_PATH/${FREETYPE_BASE_NAME}.lib. Ignoring location." >&5 62274 $as_echo "$as_me: Could not find $POTENTIAL_FREETYPE_LIB_PATH/${FREETYPE_BASE_NAME}.lib. Ignoring location." >&6;} 62275 FOUND_FREETYPE=no 62276 fi 62277 elif test "x$OPENJDK_TARGET_OS" = xsolaris \ 62278 && test -s "$POTENTIAL_FREETYPE_LIB_PATH$OPENJDK_TARGET_CPU_ISADIR/$FREETYPE_LIB_NAME"; then 62279 # Found lib in isa dir, use that instead. 62280 POTENTIAL_FREETYPE_LIB_PATH="$POTENTIAL_FREETYPE_LIB_PATH$OPENJDK_TARGET_CPU_ISADIR" 62281 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting to use $POTENTIAL_FREETYPE_LIB_PATH instead" >&5 62282 $as_echo "$as_me: Rewriting to use $POTENTIAL_FREETYPE_LIB_PATH instead" >&6;} 62283 fi 62284 fi 62285 fi 62286 62287 if test "x$FOUND_FREETYPE" = xyes; then 62288 62289 # Only process if variable expands to non-empty 62290 62291 if test "x$POTENTIAL_FREETYPE_INCLUDE_PATH" != x; then 62292 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 62293 62294 # Input might be given as Windows format, start by converting to 62295 # unix format. 62296 path="$POTENTIAL_FREETYPE_INCLUDE_PATH" 62297 new_path=`$CYGPATH -u "$path"` 62298 62299 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 62300 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 62301 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 62302 # "foo.exe" is OK but "foo" is an error. 62303 # 62304 # This test is therefore slightly more accurate than "test -f" to check for file precense. 62305 # It is also a way to make sure we got the proper file name for the real test later on. 62306 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 62307 if test "x$test_shortpath" = x; then 62308 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&5 62309 $as_echo "$as_me: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&6;} 62310 as_fn_error $? "Cannot locate the the path of POTENTIAL_FREETYPE_INCLUDE_PATH" "$LINENO" 5 62311 fi 62312 62313 # Call helper function which possibly converts this using DOS-style short mode. 62314 # If so, the updated path is stored in $new_path. 62315 62316 input_path="$new_path" 62317 # Check if we need to convert this using DOS-style short mode. If the path 62318 # contains just simple characters, use it. Otherwise (spaces, weird characters), 62319 # take no chances and rewrite it. 62320 # Note: m4 eats our [], so we need to use [ and ] instead. 62321 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 62322 if test "x$has_forbidden_chars" != x; then 62323 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 62324 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 62325 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 62326 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 62327 # Going to short mode and back again did indeed matter. Since short mode is 62328 # case insensitive, let's make it lowercase to improve readability. 62329 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 62330 # Now convert it back to Unix-style (cygpath) 62331 input_path=`$CYGPATH -u "$shortmode_path"` 62332 new_path="$input_path" 62333 fi 62334 fi 62335 62336 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 62337 if test "x$test_cygdrive_prefix" = x; then 62338 # As a simple fix, exclude /usr/bin since it's not a real path. 62339 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 62340 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 62341 # a path prefixed by /cygdrive for fixpath to work. 62342 new_path="$CYGWIN_ROOT_PATH$input_path" 62343 fi 62344 fi 62345 62346 62347 if test "x$path" != "x$new_path"; then 62348 POTENTIAL_FREETYPE_INCLUDE_PATH="$new_path" 62349 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&5 62350 $as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&6;} 62351 fi 62352 62353 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 62354 62355 path="$POTENTIAL_FREETYPE_INCLUDE_PATH" 62356 has_colon=`$ECHO $path | $GREP ^.:` 62357 new_path="$path" 62358 if test "x$has_colon" = x; then 62359 # Not in mixed or Windows style, start by that. 62360 new_path=`cmd //c echo $path` 62361 fi 62362 62363 62364 input_path="$new_path" 62365 # Check if we need to convert this using DOS-style short mode. If the path 62366 # contains just simple characters, use it. Otherwise (spaces, weird characters), 62367 # take no chances and rewrite it. 62368 # Note: m4 eats our [], so we need to use [ and ] instead. 62369 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 62370 if test "x$has_forbidden_chars" != x; then 62371 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 62372 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 62373 fi 62374 62375 62376 windows_path="$new_path" 62377 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 62378 unix_path=`$CYGPATH -u "$windows_path"` 62379 new_path="$unix_path" 62380 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 62381 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 62382 new_path="$unix_path" 62383 fi 62384 62385 if test "x$path" != "x$new_path"; then 62386 POTENTIAL_FREETYPE_INCLUDE_PATH="$new_path" 62387 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&5 62388 $as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&6;} 62389 fi 62390 62391 # Save the first 10 bytes of this path to the storage, so fixpath can work. 62392 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 62393 62394 else 62395 # We're on a unix platform. Hooray! :) 62396 path="$POTENTIAL_FREETYPE_INCLUDE_PATH" 62397 has_space=`$ECHO "$path" | $GREP " "` 62398 if test "x$has_space" != x; then 62399 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&5 62400 $as_echo "$as_me: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&6;} 62401 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 62402 fi 62403 62404 # Use eval to expand a potential ~ 62405 eval path="$path" 62406 if test ! -f "$path" && test ! -d "$path"; then 62407 as_fn_error $? "The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is not found." "$LINENO" 5 62408 fi 62409 62410 if test -d "$path"; then 62411 POTENTIAL_FREETYPE_INCLUDE_PATH="`cd "$path"; $THEPWDCMD -L`" 62412 else 62413 dir="`$DIRNAME "$path"`" 62414 base="`$BASENAME "$path"`" 62415 POTENTIAL_FREETYPE_INCLUDE_PATH="`cd "$dir"; $THEPWDCMD -L`/$base" 62416 fi 62417 fi 62418 fi 62419 62420 62421 # Only process if variable expands to non-empty 62422 62423 if test "x$POTENTIAL_FREETYPE_LIB_PATH" != x; then 62424 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 62425 62426 # Input might be given as Windows format, start by converting to 62427 # unix format. 62428 path="$POTENTIAL_FREETYPE_LIB_PATH" 62429 new_path=`$CYGPATH -u "$path"` 62430 62431 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 62432 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 62433 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 62434 # "foo.exe" is OK but "foo" is an error. 62435 # 62436 # This test is therefore slightly more accurate than "test -f" to check for file precense. 62437 # It is also a way to make sure we got the proper file name for the real test later on. 62438 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 62439 if test "x$test_shortpath" = x; then 62440 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&5 62441 $as_echo "$as_me: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&6;} 62442 as_fn_error $? "Cannot locate the the path of POTENTIAL_FREETYPE_LIB_PATH" "$LINENO" 5 62443 fi 62444 62445 # Call helper function which possibly converts this using DOS-style short mode. 62446 # If so, the updated path is stored in $new_path. 62447 62448 input_path="$new_path" 62449 # Check if we need to convert this using DOS-style short mode. If the path 62450 # contains just simple characters, use it. Otherwise (spaces, weird characters), 62451 # take no chances and rewrite it. 62452 # Note: m4 eats our [], so we need to use [ and ] instead. 62453 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 62454 if test "x$has_forbidden_chars" != x; then 62455 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 62456 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 62457 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 62458 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 62459 # Going to short mode and back again did indeed matter. Since short mode is 62460 # case insensitive, let's make it lowercase to improve readability. 62461 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 62462 # Now convert it back to Unix-style (cygpath) 62463 input_path=`$CYGPATH -u "$shortmode_path"` 62464 new_path="$input_path" 62465 fi 62466 fi 62467 62468 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 62469 if test "x$test_cygdrive_prefix" = x; then 62470 # As a simple fix, exclude /usr/bin since it's not a real path. 62471 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 62472 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 62473 # a path prefixed by /cygdrive for fixpath to work. 62474 new_path="$CYGWIN_ROOT_PATH$input_path" 62475 fi 62476 fi 62477 62478 62479 if test "x$path" != "x$new_path"; then 62480 POTENTIAL_FREETYPE_LIB_PATH="$new_path" 62481 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&5 62482 $as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&6;} 62483 fi 62484 62485 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 62486 62487 path="$POTENTIAL_FREETYPE_LIB_PATH" 62488 has_colon=`$ECHO $path | $GREP ^.:` 62489 new_path="$path" 62490 if test "x$has_colon" = x; then 62491 # Not in mixed or Windows style, start by that. 62492 new_path=`cmd //c echo $path` 62493 fi 62494 62495 62496 input_path="$new_path" 62497 # Check if we need to convert this using DOS-style short mode. If the path 62498 # contains just simple characters, use it. Otherwise (spaces, weird characters), 62499 # take no chances and rewrite it. 62500 # Note: m4 eats our [], so we need to use [ and ] instead. 62501 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 62502 if test "x$has_forbidden_chars" != x; then 62503 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 62504 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 62505 fi 62506 62507 62508 windows_path="$new_path" 62509 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 62510 unix_path=`$CYGPATH -u "$windows_path"` 62511 new_path="$unix_path" 62512 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 62513 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 62514 new_path="$unix_path" 62515 fi 62516 62517 if test "x$path" != "x$new_path"; then 62518 POTENTIAL_FREETYPE_LIB_PATH="$new_path" 62519 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&5 62520 $as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&6;} 62521 fi 62522 62523 # Save the first 10 bytes of this path to the storage, so fixpath can work. 62524 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 62525 62526 else 62527 # We're on a unix platform. Hooray! :) 62528 path="$POTENTIAL_FREETYPE_LIB_PATH" 62529 has_space=`$ECHO "$path" | $GREP " "` 62530 if test "x$has_space" != x; then 62531 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&5 62532 $as_echo "$as_me: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&6;} 62533 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 62534 fi 62535 62536 # Use eval to expand a potential ~ 62537 eval path="$path" 62538 if test ! -f "$path" && test ! -d "$path"; then 62539 as_fn_error $? "The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is not found." "$LINENO" 5 62540 fi 62541 62542 if test -d "$path"; then 62543 POTENTIAL_FREETYPE_LIB_PATH="`cd "$path"; $THEPWDCMD -L`" 62544 else 62545 dir="`$DIRNAME "$path"`" 62546 base="`$BASENAME "$path"`" 62547 POTENTIAL_FREETYPE_LIB_PATH="`cd "$dir"; $THEPWDCMD -L`/$base" 62548 fi 62549 fi 62550 fi 62551 62552 62553 FREETYPE_INCLUDE_PATH="$POTENTIAL_FREETYPE_INCLUDE_PATH" 62554 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for freetype includes" >&5 62555 $as_echo_n "checking for freetype includes... " >&6; } 62556 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $FREETYPE_INCLUDE_PATH" >&5 62557 $as_echo "$FREETYPE_INCLUDE_PATH" >&6; } 62558 FREETYPE_LIB_PATH="$POTENTIAL_FREETYPE_LIB_PATH" 62559 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for freetype libraries" >&5 62560 $as_echo_n "checking for freetype libraries... " >&6; } 62561 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $FREETYPE_LIB_PATH" >&5 62562 $as_echo "$FREETYPE_LIB_PATH" >&6; } 62563 fi 62564 62565 fi 62566 fi 62567 fi 62568 else 62569 FREETYPE_BASE_DIR="$SYSROOT/usr" 62570 62571 POTENTIAL_FREETYPE_INCLUDE_PATH="$FREETYPE_BASE_DIR/include" 62572 POTENTIAL_FREETYPE_LIB_PATH="$FREETYPE_BASE_DIR/lib" 62573 METHOD="well-known location" 62574 62575 # Let's start with an optimistic view of the world :-) 62576 FOUND_FREETYPE=yes 62577 62578 # First look for the canonical freetype main include file ft2build.h. 62579 if ! test -s "$POTENTIAL_FREETYPE_INCLUDE_PATH/ft2build.h"; then 62580 # Oh no! Let's try in the freetype2 directory. This is needed at least at Mac OS X Yosemite. 62581 POTENTIAL_FREETYPE_INCLUDE_PATH="$POTENTIAL_FREETYPE_INCLUDE_PATH/freetype2" 62582 if ! test -s "$POTENTIAL_FREETYPE_INCLUDE_PATH/ft2build.h"; then 62583 # Fail. 62584 FOUND_FREETYPE=no 62585 fi 62586 fi 62587 62588 if test "x$FOUND_FREETYPE" = xyes; then 62589 # Include file found, let's continue the sanity check. 62590 { $as_echo "$as_me:${as_lineno-$LINENO}: Found freetype include files at $POTENTIAL_FREETYPE_INCLUDE_PATH using $METHOD" >&5 62591 $as_echo "$as_me: Found freetype include files at $POTENTIAL_FREETYPE_INCLUDE_PATH using $METHOD" >&6;} 62592 62593 # Reset to default value 62594 FREETYPE_BASE_NAME=freetype 62595 FREETYPE_LIB_NAME="${LIBRARY_PREFIX}${FREETYPE_BASE_NAME}${SHARED_LIBRARY_SUFFIX}" 62596 if ! test -s "$POTENTIAL_FREETYPE_LIB_PATH/$FREETYPE_LIB_NAME"; then 62597 if test "x$OPENJDK_TARGET_OS" = xmacosx \ 62598 && test -s "$POTENTIAL_FREETYPE_LIB_PATH/${LIBRARY_PREFIX}freetype.6${SHARED_LIBRARY_SUFFIX}"; then 62599 # On Mac OS X Yosemite, the symlink from libfreetype.dylib to libfreetype.6.dylib disappeared. Check 62600 # for the .6 version explicitly. 62601 FREETYPE_BASE_NAME=freetype.6 62602 FREETYPE_LIB_NAME="${LIBRARY_PREFIX}${FREETYPE_BASE_NAME}${SHARED_LIBRARY_SUFFIX}" 62603 { $as_echo "$as_me:${as_lineno-$LINENO}: Compensating for missing symlink by using version 6 explicitly" >&5 62604 $as_echo "$as_me: Compensating for missing symlink by using version 6 explicitly" >&6;} 62605 else 62606 { $as_echo "$as_me:${as_lineno-$LINENO}: Could not find $POTENTIAL_FREETYPE_LIB_PATH/$FREETYPE_LIB_NAME. Ignoring location." >&5 62607 $as_echo "$as_me: Could not find $POTENTIAL_FREETYPE_LIB_PATH/$FREETYPE_LIB_NAME. Ignoring location." >&6;} 62608 FOUND_FREETYPE=no 62609 fi 62610 else 62611 if test "x$OPENJDK_TARGET_OS" = xwindows; then 62612 # On Windows, we will need both .lib and .dll file. 62613 if ! test -s "$POTENTIAL_FREETYPE_LIB_PATH/${FREETYPE_BASE_NAME}.lib"; then 62614 { $as_echo "$as_me:${as_lineno-$LINENO}: Could not find $POTENTIAL_FREETYPE_LIB_PATH/${FREETYPE_BASE_NAME}.lib. Ignoring location." >&5 62615 $as_echo "$as_me: Could not find $POTENTIAL_FREETYPE_LIB_PATH/${FREETYPE_BASE_NAME}.lib. Ignoring location." >&6;} 62616 FOUND_FREETYPE=no 62617 fi 62618 elif test "x$OPENJDK_TARGET_OS" = xsolaris \ 62619 && test -s "$POTENTIAL_FREETYPE_LIB_PATH$OPENJDK_TARGET_CPU_ISADIR/$FREETYPE_LIB_NAME"; then 62620 # Found lib in isa dir, use that instead. 62621 POTENTIAL_FREETYPE_LIB_PATH="$POTENTIAL_FREETYPE_LIB_PATH$OPENJDK_TARGET_CPU_ISADIR" 62622 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting to use $POTENTIAL_FREETYPE_LIB_PATH instead" >&5 62623 $as_echo "$as_me: Rewriting to use $POTENTIAL_FREETYPE_LIB_PATH instead" >&6;} 62624 fi 62625 fi 62626 fi 62627 62628 if test "x$FOUND_FREETYPE" = xyes; then 62629 62630 # Only process if variable expands to non-empty 62631 62632 if test "x$POTENTIAL_FREETYPE_INCLUDE_PATH" != x; then 62633 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 62634 62635 # Input might be given as Windows format, start by converting to 62636 # unix format. 62637 path="$POTENTIAL_FREETYPE_INCLUDE_PATH" 62638 new_path=`$CYGPATH -u "$path"` 62639 62640 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 62641 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 62642 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 62643 # "foo.exe" is OK but "foo" is an error. 62644 # 62645 # This test is therefore slightly more accurate than "test -f" to check for file precense. 62646 # It is also a way to make sure we got the proper file name for the real test later on. 62647 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 62648 if test "x$test_shortpath" = x; then 62649 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&5 62650 $as_echo "$as_me: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&6;} 62651 as_fn_error $? "Cannot locate the the path of POTENTIAL_FREETYPE_INCLUDE_PATH" "$LINENO" 5 62652 fi 62653 62654 # Call helper function which possibly converts this using DOS-style short mode. 62655 # If so, the updated path is stored in $new_path. 62656 62657 input_path="$new_path" 62658 # Check if we need to convert this using DOS-style short mode. If the path 62659 # contains just simple characters, use it. Otherwise (spaces, weird characters), 62660 # take no chances and rewrite it. 62661 # Note: m4 eats our [], so we need to use [ and ] instead. 62662 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 62663 if test "x$has_forbidden_chars" != x; then 62664 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 62665 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 62666 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 62667 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 62668 # Going to short mode and back again did indeed matter. Since short mode is 62669 # case insensitive, let's make it lowercase to improve readability. 62670 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 62671 # Now convert it back to Unix-style (cygpath) 62672 input_path=`$CYGPATH -u "$shortmode_path"` 62673 new_path="$input_path" 62674 fi 62675 fi 62676 62677 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 62678 if test "x$test_cygdrive_prefix" = x; then 62679 # As a simple fix, exclude /usr/bin since it's not a real path. 62680 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 62681 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 62682 # a path prefixed by /cygdrive for fixpath to work. 62683 new_path="$CYGWIN_ROOT_PATH$input_path" 62684 fi 62685 fi 62686 62687 62688 if test "x$path" != "x$new_path"; then 62689 POTENTIAL_FREETYPE_INCLUDE_PATH="$new_path" 62690 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&5 62691 $as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&6;} 62692 fi 62693 62694 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 62695 62696 path="$POTENTIAL_FREETYPE_INCLUDE_PATH" 62697 has_colon=`$ECHO $path | $GREP ^.:` 62698 new_path="$path" 62699 if test "x$has_colon" = x; then 62700 # Not in mixed or Windows style, start by that. 62701 new_path=`cmd //c echo $path` 62702 fi 62703 62704 62705 input_path="$new_path" 62706 # Check if we need to convert this using DOS-style short mode. If the path 62707 # contains just simple characters, use it. Otherwise (spaces, weird characters), 62708 # take no chances and rewrite it. 62709 # Note: m4 eats our [], so we need to use [ and ] instead. 62710 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 62711 if test "x$has_forbidden_chars" != x; then 62712 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 62713 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 62714 fi 62715 62716 62717 windows_path="$new_path" 62718 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 62719 unix_path=`$CYGPATH -u "$windows_path"` 62720 new_path="$unix_path" 62721 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 62722 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 62723 new_path="$unix_path" 62724 fi 62725 62726 if test "x$path" != "x$new_path"; then 62727 POTENTIAL_FREETYPE_INCLUDE_PATH="$new_path" 62728 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&5 62729 $as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&6;} 62730 fi 62731 62732 # Save the first 10 bytes of this path to the storage, so fixpath can work. 62733 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 62734 62735 else 62736 # We're on a unix platform. Hooray! :) 62737 path="$POTENTIAL_FREETYPE_INCLUDE_PATH" 62738 has_space=`$ECHO "$path" | $GREP " "` 62739 if test "x$has_space" != x; then 62740 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&5 62741 $as_echo "$as_me: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&6;} 62742 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 62743 fi 62744 62745 # Use eval to expand a potential ~ 62746 eval path="$path" 62747 if test ! -f "$path" && test ! -d "$path"; then 62748 as_fn_error $? "The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is not found." "$LINENO" 5 62749 fi 62750 62751 if test -d "$path"; then 62752 POTENTIAL_FREETYPE_INCLUDE_PATH="`cd "$path"; $THEPWDCMD -L`" 62753 else 62754 dir="`$DIRNAME "$path"`" 62755 base="`$BASENAME "$path"`" 62756 POTENTIAL_FREETYPE_INCLUDE_PATH="`cd "$dir"; $THEPWDCMD -L`/$base" 62757 fi 62758 fi 62759 fi 62760 62761 62762 # Only process if variable expands to non-empty 62763 62764 if test "x$POTENTIAL_FREETYPE_LIB_PATH" != x; then 62765 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 62766 62767 # Input might be given as Windows format, start by converting to 62768 # unix format. 62769 path="$POTENTIAL_FREETYPE_LIB_PATH" 62770 new_path=`$CYGPATH -u "$path"` 62771 62772 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 62773 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 62774 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 62775 # "foo.exe" is OK but "foo" is an error. 62776 # 62777 # This test is therefore slightly more accurate than "test -f" to check for file precense. 62778 # It is also a way to make sure we got the proper file name for the real test later on. 62779 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 62780 if test "x$test_shortpath" = x; then 62781 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&5 62782 $as_echo "$as_me: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&6;} 62783 as_fn_error $? "Cannot locate the the path of POTENTIAL_FREETYPE_LIB_PATH" "$LINENO" 5 62784 fi 62785 62786 # Call helper function which possibly converts this using DOS-style short mode. 62787 # If so, the updated path is stored in $new_path. 62788 62789 input_path="$new_path" 62790 # Check if we need to convert this using DOS-style short mode. If the path 62791 # contains just simple characters, use it. Otherwise (spaces, weird characters), 62792 # take no chances and rewrite it. 62793 # Note: m4 eats our [], so we need to use [ and ] instead. 62794 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 62795 if test "x$has_forbidden_chars" != x; then 62796 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 62797 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 62798 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 62799 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 62800 # Going to short mode and back again did indeed matter. Since short mode is 62801 # case insensitive, let's make it lowercase to improve readability. 62802 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 62803 # Now convert it back to Unix-style (cygpath) 62804 input_path=`$CYGPATH -u "$shortmode_path"` 62805 new_path="$input_path" 62806 fi 62807 fi 62808 62809 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 62810 if test "x$test_cygdrive_prefix" = x; then 62811 # As a simple fix, exclude /usr/bin since it's not a real path. 62812 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 62813 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 62814 # a path prefixed by /cygdrive for fixpath to work. 62815 new_path="$CYGWIN_ROOT_PATH$input_path" 62816 fi 62817 fi 62818 62819 62820 if test "x$path" != "x$new_path"; then 62821 POTENTIAL_FREETYPE_LIB_PATH="$new_path" 62822 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&5 62823 $as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&6;} 62824 fi 62825 62826 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 62827 62828 path="$POTENTIAL_FREETYPE_LIB_PATH" 62829 has_colon=`$ECHO $path | $GREP ^.:` 62830 new_path="$path" 62831 if test "x$has_colon" = x; then 62832 # Not in mixed or Windows style, start by that. 62833 new_path=`cmd //c echo $path` 62834 fi 62835 62836 62837 input_path="$new_path" 62838 # Check if we need to convert this using DOS-style short mode. If the path 62839 # contains just simple characters, use it. Otherwise (spaces, weird characters), 62840 # take no chances and rewrite it. 62841 # Note: m4 eats our [], so we need to use [ and ] instead. 62842 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 62843 if test "x$has_forbidden_chars" != x; then 62844 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 62845 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 62846 fi 62847 62848 62849 windows_path="$new_path" 62850 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 62851 unix_path=`$CYGPATH -u "$windows_path"` 62852 new_path="$unix_path" 62853 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 62854 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 62855 new_path="$unix_path" 62856 fi 62857 62858 if test "x$path" != "x$new_path"; then 62859 POTENTIAL_FREETYPE_LIB_PATH="$new_path" 62860 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&5 62861 $as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&6;} 62862 fi 62863 62864 # Save the first 10 bytes of this path to the storage, so fixpath can work. 62865 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 62866 62867 else 62868 # We're on a unix platform. Hooray! :) 62869 path="$POTENTIAL_FREETYPE_LIB_PATH" 62870 has_space=`$ECHO "$path" | $GREP " "` 62871 if test "x$has_space" != x; then 62872 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&5 62873 $as_echo "$as_me: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&6;} 62874 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 62875 fi 62876 62877 # Use eval to expand a potential ~ 62878 eval path="$path" 62879 if test ! -f "$path" && test ! -d "$path"; then 62880 as_fn_error $? "The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is not found." "$LINENO" 5 62881 fi 62882 62883 if test -d "$path"; then 62884 POTENTIAL_FREETYPE_LIB_PATH="`cd "$path"; $THEPWDCMD -L`" 62885 else 62886 dir="`$DIRNAME "$path"`" 62887 base="`$BASENAME "$path"`" 62888 POTENTIAL_FREETYPE_LIB_PATH="`cd "$dir"; $THEPWDCMD -L`/$base" 62889 fi 62890 fi 62891 fi 62892 62893 62894 FREETYPE_INCLUDE_PATH="$POTENTIAL_FREETYPE_INCLUDE_PATH" 62895 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for freetype includes" >&5 62896 $as_echo_n "checking for freetype includes... " >&6; } 62897 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $FREETYPE_INCLUDE_PATH" >&5 62898 $as_echo "$FREETYPE_INCLUDE_PATH" >&6; } 62899 FREETYPE_LIB_PATH="$POTENTIAL_FREETYPE_LIB_PATH" 62900 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for freetype libraries" >&5 62901 $as_echo_n "checking for freetype libraries... " >&6; } 62902 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $FREETYPE_LIB_PATH" >&5 62903 $as_echo "$FREETYPE_LIB_PATH" >&6; } 62904 fi 62905 62906 62907 if test "x$FOUND_FREETYPE" != xyes; then 62908 FREETYPE_BASE_DIR="$SYSROOT/usr/X11" 62909 62910 POTENTIAL_FREETYPE_INCLUDE_PATH="$FREETYPE_BASE_DIR/include" 62911 POTENTIAL_FREETYPE_LIB_PATH="$FREETYPE_BASE_DIR/lib" 62912 METHOD="well-known location" 62913 62914 # Let's start with an optimistic view of the world :-) 62915 FOUND_FREETYPE=yes 62916 62917 # First look for the canonical freetype main include file ft2build.h. 62918 if ! test -s "$POTENTIAL_FREETYPE_INCLUDE_PATH/ft2build.h"; then 62919 # Oh no! Let's try in the freetype2 directory. This is needed at least at Mac OS X Yosemite. 62920 POTENTIAL_FREETYPE_INCLUDE_PATH="$POTENTIAL_FREETYPE_INCLUDE_PATH/freetype2" 62921 if ! test -s "$POTENTIAL_FREETYPE_INCLUDE_PATH/ft2build.h"; then 62922 # Fail. 62923 FOUND_FREETYPE=no 62924 fi 62925 fi 62926 62927 if test "x$FOUND_FREETYPE" = xyes; then 62928 # Include file found, let's continue the sanity check. 62929 { $as_echo "$as_me:${as_lineno-$LINENO}: Found freetype include files at $POTENTIAL_FREETYPE_INCLUDE_PATH using $METHOD" >&5 62930 $as_echo "$as_me: Found freetype include files at $POTENTIAL_FREETYPE_INCLUDE_PATH using $METHOD" >&6;} 62931 62932 # Reset to default value 62933 FREETYPE_BASE_NAME=freetype 62934 FREETYPE_LIB_NAME="${LIBRARY_PREFIX}${FREETYPE_BASE_NAME}${SHARED_LIBRARY_SUFFIX}" 62935 if ! test -s "$POTENTIAL_FREETYPE_LIB_PATH/$FREETYPE_LIB_NAME"; then 62936 if test "x$OPENJDK_TARGET_OS" = xmacosx \ 62937 && test -s "$POTENTIAL_FREETYPE_LIB_PATH/${LIBRARY_PREFIX}freetype.6${SHARED_LIBRARY_SUFFIX}"; then 62938 # On Mac OS X Yosemite, the symlink from libfreetype.dylib to libfreetype.6.dylib disappeared. Check 62939 # for the .6 version explicitly. 62940 FREETYPE_BASE_NAME=freetype.6 62941 FREETYPE_LIB_NAME="${LIBRARY_PREFIX}${FREETYPE_BASE_NAME}${SHARED_LIBRARY_SUFFIX}" 62942 { $as_echo "$as_me:${as_lineno-$LINENO}: Compensating for missing symlink by using version 6 explicitly" >&5 62943 $as_echo "$as_me: Compensating for missing symlink by using version 6 explicitly" >&6;} 62944 else 62945 { $as_echo "$as_me:${as_lineno-$LINENO}: Could not find $POTENTIAL_FREETYPE_LIB_PATH/$FREETYPE_LIB_NAME. Ignoring location." >&5 62946 $as_echo "$as_me: Could not find $POTENTIAL_FREETYPE_LIB_PATH/$FREETYPE_LIB_NAME. Ignoring location." >&6;} 62947 FOUND_FREETYPE=no 62948 fi 62949 else 62950 if test "x$OPENJDK_TARGET_OS" = xwindows; then 62951 # On Windows, we will need both .lib and .dll file. 62952 if ! test -s "$POTENTIAL_FREETYPE_LIB_PATH/${FREETYPE_BASE_NAME}.lib"; then 62953 { $as_echo "$as_me:${as_lineno-$LINENO}: Could not find $POTENTIAL_FREETYPE_LIB_PATH/${FREETYPE_BASE_NAME}.lib. Ignoring location." >&5 62954 $as_echo "$as_me: Could not find $POTENTIAL_FREETYPE_LIB_PATH/${FREETYPE_BASE_NAME}.lib. Ignoring location." >&6;} 62955 FOUND_FREETYPE=no 62956 fi 62957 elif test "x$OPENJDK_TARGET_OS" = xsolaris \ 62958 && test -s "$POTENTIAL_FREETYPE_LIB_PATH$OPENJDK_TARGET_CPU_ISADIR/$FREETYPE_LIB_NAME"; then 62959 # Found lib in isa dir, use that instead. 62960 POTENTIAL_FREETYPE_LIB_PATH="$POTENTIAL_FREETYPE_LIB_PATH$OPENJDK_TARGET_CPU_ISADIR" 62961 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting to use $POTENTIAL_FREETYPE_LIB_PATH instead" >&5 62962 $as_echo "$as_me: Rewriting to use $POTENTIAL_FREETYPE_LIB_PATH instead" >&6;} 62963 fi 62964 fi 62965 fi 62966 62967 if test "x$FOUND_FREETYPE" = xyes; then 62968 62969 # Only process if variable expands to non-empty 62970 62971 if test "x$POTENTIAL_FREETYPE_INCLUDE_PATH" != x; then 62972 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 62973 62974 # Input might be given as Windows format, start by converting to 62975 # unix format. 62976 path="$POTENTIAL_FREETYPE_INCLUDE_PATH" 62977 new_path=`$CYGPATH -u "$path"` 62978 62979 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 62980 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 62981 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 62982 # "foo.exe" is OK but "foo" is an error. 62983 # 62984 # This test is therefore slightly more accurate than "test -f" to check for file precense. 62985 # It is also a way to make sure we got the proper file name for the real test later on. 62986 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 62987 if test "x$test_shortpath" = x; then 62988 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&5 62989 $as_echo "$as_me: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&6;} 62990 as_fn_error $? "Cannot locate the the path of POTENTIAL_FREETYPE_INCLUDE_PATH" "$LINENO" 5 62991 fi 62992 62993 # Call helper function which possibly converts this using DOS-style short mode. 62994 # If so, the updated path is stored in $new_path. 62995 62996 input_path="$new_path" 62997 # Check if we need to convert this using DOS-style short mode. If the path 62998 # contains just simple characters, use it. Otherwise (spaces, weird characters), 62999 # take no chances and rewrite it. 63000 # Note: m4 eats our [], so we need to use [ and ] instead. 63001 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 63002 if test "x$has_forbidden_chars" != x; then 63003 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 63004 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 63005 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 63006 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 63007 # Going to short mode and back again did indeed matter. Since short mode is 63008 # case insensitive, let's make it lowercase to improve readability. 63009 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 63010 # Now convert it back to Unix-style (cygpath) 63011 input_path=`$CYGPATH -u "$shortmode_path"` 63012 new_path="$input_path" 63013 fi 63014 fi 63015 63016 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 63017 if test "x$test_cygdrive_prefix" = x; then 63018 # As a simple fix, exclude /usr/bin since it's not a real path. 63019 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 63020 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 63021 # a path prefixed by /cygdrive for fixpath to work. 63022 new_path="$CYGWIN_ROOT_PATH$input_path" 63023 fi 63024 fi 63025 63026 63027 if test "x$path" != "x$new_path"; then 63028 POTENTIAL_FREETYPE_INCLUDE_PATH="$new_path" 63029 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&5 63030 $as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&6;} 63031 fi 63032 63033 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 63034 63035 path="$POTENTIAL_FREETYPE_INCLUDE_PATH" 63036 has_colon=`$ECHO $path | $GREP ^.:` 63037 new_path="$path" 63038 if test "x$has_colon" = x; then 63039 # Not in mixed or Windows style, start by that. 63040 new_path=`cmd //c echo $path` 63041 fi 63042 63043 63044 input_path="$new_path" 63045 # Check if we need to convert this using DOS-style short mode. If the path 63046 # contains just simple characters, use it. Otherwise (spaces, weird characters), 63047 # take no chances and rewrite it. 63048 # Note: m4 eats our [], so we need to use [ and ] instead. 63049 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 63050 if test "x$has_forbidden_chars" != x; then 63051 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 63052 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 63053 fi 63054 63055 63056 windows_path="$new_path" 63057 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 63058 unix_path=`$CYGPATH -u "$windows_path"` 63059 new_path="$unix_path" 63060 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 63061 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 63062 new_path="$unix_path" 63063 fi 63064 63065 if test "x$path" != "x$new_path"; then 63066 POTENTIAL_FREETYPE_INCLUDE_PATH="$new_path" 63067 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&5 63068 $as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&6;} 63069 fi 63070 63071 # Save the first 10 bytes of this path to the storage, so fixpath can work. 63072 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 63073 63074 else 63075 # We're on a unix platform. Hooray! :) 63076 path="$POTENTIAL_FREETYPE_INCLUDE_PATH" 63077 has_space=`$ECHO "$path" | $GREP " "` 63078 if test "x$has_space" != x; then 63079 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&5 63080 $as_echo "$as_me: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&6;} 63081 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 63082 fi 63083 63084 # Use eval to expand a potential ~ 63085 eval path="$path" 63086 if test ! -f "$path" && test ! -d "$path"; then 63087 as_fn_error $? "The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is not found." "$LINENO" 5 63088 fi 63089 63090 if test -d "$path"; then 63091 POTENTIAL_FREETYPE_INCLUDE_PATH="`cd "$path"; $THEPWDCMD -L`" 63092 else 63093 dir="`$DIRNAME "$path"`" 63094 base="`$BASENAME "$path"`" 63095 POTENTIAL_FREETYPE_INCLUDE_PATH="`cd "$dir"; $THEPWDCMD -L`/$base" 63096 fi 63097 fi 63098 fi 63099 63100 63101 # Only process if variable expands to non-empty 63102 63103 if test "x$POTENTIAL_FREETYPE_LIB_PATH" != x; then 63104 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 63105 63106 # Input might be given as Windows format, start by converting to 63107 # unix format. 63108 path="$POTENTIAL_FREETYPE_LIB_PATH" 63109 new_path=`$CYGPATH -u "$path"` 63110 63111 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 63112 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 63113 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 63114 # "foo.exe" is OK but "foo" is an error. 63115 # 63116 # This test is therefore slightly more accurate than "test -f" to check for file precense. 63117 # It is also a way to make sure we got the proper file name for the real test later on. 63118 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 63119 if test "x$test_shortpath" = x; then 63120 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&5 63121 $as_echo "$as_me: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&6;} 63122 as_fn_error $? "Cannot locate the the path of POTENTIAL_FREETYPE_LIB_PATH" "$LINENO" 5 63123 fi 63124 63125 # Call helper function which possibly converts this using DOS-style short mode. 63126 # If so, the updated path is stored in $new_path. 63127 63128 input_path="$new_path" 63129 # Check if we need to convert this using DOS-style short mode. If the path 63130 # contains just simple characters, use it. Otherwise (spaces, weird characters), 63131 # take no chances and rewrite it. 63132 # Note: m4 eats our [], so we need to use [ and ] instead. 63133 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 63134 if test "x$has_forbidden_chars" != x; then 63135 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 63136 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 63137 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 63138 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 63139 # Going to short mode and back again did indeed matter. Since short mode is 63140 # case insensitive, let's make it lowercase to improve readability. 63141 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 63142 # Now convert it back to Unix-style (cygpath) 63143 input_path=`$CYGPATH -u "$shortmode_path"` 63144 new_path="$input_path" 63145 fi 63146 fi 63147 63148 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 63149 if test "x$test_cygdrive_prefix" = x; then 63150 # As a simple fix, exclude /usr/bin since it's not a real path. 63151 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 63152 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 63153 # a path prefixed by /cygdrive for fixpath to work. 63154 new_path="$CYGWIN_ROOT_PATH$input_path" 63155 fi 63156 fi 63157 63158 63159 if test "x$path" != "x$new_path"; then 63160 POTENTIAL_FREETYPE_LIB_PATH="$new_path" 63161 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&5 63162 $as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&6;} 63163 fi 63164 63165 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 63166 63167 path="$POTENTIAL_FREETYPE_LIB_PATH" 63168 has_colon=`$ECHO $path | $GREP ^.:` 63169 new_path="$path" 63170 if test "x$has_colon" = x; then 63171 # Not in mixed or Windows style, start by that. 63172 new_path=`cmd //c echo $path` 63173 fi 63174 63175 63176 input_path="$new_path" 63177 # Check if we need to convert this using DOS-style short mode. If the path 63178 # contains just simple characters, use it. Otherwise (spaces, weird characters), 63179 # take no chances and rewrite it. 63180 # Note: m4 eats our [], so we need to use [ and ] instead. 63181 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 63182 if test "x$has_forbidden_chars" != x; then 63183 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 63184 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 63185 fi 63186 63187 63188 windows_path="$new_path" 63189 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 63190 unix_path=`$CYGPATH -u "$windows_path"` 63191 new_path="$unix_path" 63192 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 63193 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 63194 new_path="$unix_path" 63195 fi 63196 63197 if test "x$path" != "x$new_path"; then 63198 POTENTIAL_FREETYPE_LIB_PATH="$new_path" 63199 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&5 63200 $as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&6;} 63201 fi 63202 63203 # Save the first 10 bytes of this path to the storage, so fixpath can work. 63204 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 63205 63206 else 63207 # We're on a unix platform. Hooray! :) 63208 path="$POTENTIAL_FREETYPE_LIB_PATH" 63209 has_space=`$ECHO "$path" | $GREP " "` 63210 if test "x$has_space" != x; then 63211 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&5 63212 $as_echo "$as_me: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&6;} 63213 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 63214 fi 63215 63216 # Use eval to expand a potential ~ 63217 eval path="$path" 63218 if test ! -f "$path" && test ! -d "$path"; then 63219 as_fn_error $? "The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is not found." "$LINENO" 5 63220 fi 63221 63222 if test -d "$path"; then 63223 POTENTIAL_FREETYPE_LIB_PATH="`cd "$path"; $THEPWDCMD -L`" 63224 else 63225 dir="`$DIRNAME "$path"`" 63226 base="`$BASENAME "$path"`" 63227 POTENTIAL_FREETYPE_LIB_PATH="`cd "$dir"; $THEPWDCMD -L`/$base" 63228 fi 63229 fi 63230 fi 63231 63232 63233 FREETYPE_INCLUDE_PATH="$POTENTIAL_FREETYPE_INCLUDE_PATH" 63234 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for freetype includes" >&5 63235 $as_echo_n "checking for freetype includes... " >&6; } 63236 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $FREETYPE_INCLUDE_PATH" >&5 63237 $as_echo "$FREETYPE_INCLUDE_PATH" >&6; } 63238 FREETYPE_LIB_PATH="$POTENTIAL_FREETYPE_LIB_PATH" 63239 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for freetype libraries" >&5 63240 $as_echo_n "checking for freetype libraries... " >&6; } 63241 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $FREETYPE_LIB_PATH" >&5 63242 $as_echo "$FREETYPE_LIB_PATH" >&6; } 63243 fi 63244 63245 fi 63246 if test "x$FOUND_FREETYPE" != xyes; then 63247 FREETYPE_BASE_DIR="$SYSROOT/usr/local" 63248 63249 POTENTIAL_FREETYPE_INCLUDE_PATH="$FREETYPE_BASE_DIR/include" 63250 POTENTIAL_FREETYPE_LIB_PATH="$FREETYPE_BASE_DIR/lib" 63251 METHOD="well-known location" 63252 63253 # Let's start with an optimistic view of the world :-) 63254 FOUND_FREETYPE=yes 63255 63256 # First look for the canonical freetype main include file ft2build.h. 63257 if ! test -s "$POTENTIAL_FREETYPE_INCLUDE_PATH/ft2build.h"; then 63258 # Oh no! Let's try in the freetype2 directory. This is needed at least at Mac OS X Yosemite. 63259 POTENTIAL_FREETYPE_INCLUDE_PATH="$POTENTIAL_FREETYPE_INCLUDE_PATH/freetype2" 63260 if ! test -s "$POTENTIAL_FREETYPE_INCLUDE_PATH/ft2build.h"; then 63261 # Fail. 63262 FOUND_FREETYPE=no 63263 fi 63264 fi 63265 63266 if test "x$FOUND_FREETYPE" = xyes; then 63267 # Include file found, let's continue the sanity check. 63268 { $as_echo "$as_me:${as_lineno-$LINENO}: Found freetype include files at $POTENTIAL_FREETYPE_INCLUDE_PATH using $METHOD" >&5 63269 $as_echo "$as_me: Found freetype include files at $POTENTIAL_FREETYPE_INCLUDE_PATH using $METHOD" >&6;} 63270 63271 # Reset to default value 63272 FREETYPE_BASE_NAME=freetype 63273 FREETYPE_LIB_NAME="${LIBRARY_PREFIX}${FREETYPE_BASE_NAME}${SHARED_LIBRARY_SUFFIX}" 63274 if ! test -s "$POTENTIAL_FREETYPE_LIB_PATH/$FREETYPE_LIB_NAME"; then 63275 if test "x$OPENJDK_TARGET_OS" = xmacosx \ 63276 && test -s "$POTENTIAL_FREETYPE_LIB_PATH/${LIBRARY_PREFIX}freetype.6${SHARED_LIBRARY_SUFFIX}"; then 63277 # On Mac OS X Yosemite, the symlink from libfreetype.dylib to libfreetype.6.dylib disappeared. Check 63278 # for the .6 version explicitly. 63279 FREETYPE_BASE_NAME=freetype.6 63280 FREETYPE_LIB_NAME="${LIBRARY_PREFIX}${FREETYPE_BASE_NAME}${SHARED_LIBRARY_SUFFIX}" 63281 { $as_echo "$as_me:${as_lineno-$LINENO}: Compensating for missing symlink by using version 6 explicitly" >&5 63282 $as_echo "$as_me: Compensating for missing symlink by using version 6 explicitly" >&6;} 63283 else 63284 { $as_echo "$as_me:${as_lineno-$LINENO}: Could not find $POTENTIAL_FREETYPE_LIB_PATH/$FREETYPE_LIB_NAME. Ignoring location." >&5 63285 $as_echo "$as_me: Could not find $POTENTIAL_FREETYPE_LIB_PATH/$FREETYPE_LIB_NAME. Ignoring location." >&6;} 63286 FOUND_FREETYPE=no 63287 fi 63288 else 63289 if test "x$OPENJDK_TARGET_OS" = xwindows; then 63290 # On Windows, we will need both .lib and .dll file. 63291 if ! test -s "$POTENTIAL_FREETYPE_LIB_PATH/${FREETYPE_BASE_NAME}.lib"; then 63292 { $as_echo "$as_me:${as_lineno-$LINENO}: Could not find $POTENTIAL_FREETYPE_LIB_PATH/${FREETYPE_BASE_NAME}.lib. Ignoring location." >&5 63293 $as_echo "$as_me: Could not find $POTENTIAL_FREETYPE_LIB_PATH/${FREETYPE_BASE_NAME}.lib. Ignoring location." >&6;} 63294 FOUND_FREETYPE=no 63295 fi 63296 elif test "x$OPENJDK_TARGET_OS" = xsolaris \ 63297 && test -s "$POTENTIAL_FREETYPE_LIB_PATH$OPENJDK_TARGET_CPU_ISADIR/$FREETYPE_LIB_NAME"; then 63298 # Found lib in isa dir, use that instead. 63299 POTENTIAL_FREETYPE_LIB_PATH="$POTENTIAL_FREETYPE_LIB_PATH$OPENJDK_TARGET_CPU_ISADIR" 63300 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting to use $POTENTIAL_FREETYPE_LIB_PATH instead" >&5 63301 $as_echo "$as_me: Rewriting to use $POTENTIAL_FREETYPE_LIB_PATH instead" >&6;} 63302 fi 63303 fi 63304 fi 63305 63306 if test "x$FOUND_FREETYPE" = xyes; then 63307 63308 # Only process if variable expands to non-empty 63309 63310 if test "x$POTENTIAL_FREETYPE_INCLUDE_PATH" != x; then 63311 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 63312 63313 # Input might be given as Windows format, start by converting to 63314 # unix format. 63315 path="$POTENTIAL_FREETYPE_INCLUDE_PATH" 63316 new_path=`$CYGPATH -u "$path"` 63317 63318 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 63319 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 63320 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 63321 # "foo.exe" is OK but "foo" is an error. 63322 # 63323 # This test is therefore slightly more accurate than "test -f" to check for file precense. 63324 # It is also a way to make sure we got the proper file name for the real test later on. 63325 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 63326 if test "x$test_shortpath" = x; then 63327 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&5 63328 $as_echo "$as_me: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&6;} 63329 as_fn_error $? "Cannot locate the the path of POTENTIAL_FREETYPE_INCLUDE_PATH" "$LINENO" 5 63330 fi 63331 63332 # Call helper function which possibly converts this using DOS-style short mode. 63333 # If so, the updated path is stored in $new_path. 63334 63335 input_path="$new_path" 63336 # Check if we need to convert this using DOS-style short mode. If the path 63337 # contains just simple characters, use it. Otherwise (spaces, weird characters), 63338 # take no chances and rewrite it. 63339 # Note: m4 eats our [], so we need to use [ and ] instead. 63340 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 63341 if test "x$has_forbidden_chars" != x; then 63342 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 63343 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 63344 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 63345 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 63346 # Going to short mode and back again did indeed matter. Since short mode is 63347 # case insensitive, let's make it lowercase to improve readability. 63348 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 63349 # Now convert it back to Unix-style (cygpath) 63350 input_path=`$CYGPATH -u "$shortmode_path"` 63351 new_path="$input_path" 63352 fi 63353 fi 63354 63355 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 63356 if test "x$test_cygdrive_prefix" = x; then 63357 # As a simple fix, exclude /usr/bin since it's not a real path. 63358 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 63359 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 63360 # a path prefixed by /cygdrive for fixpath to work. 63361 new_path="$CYGWIN_ROOT_PATH$input_path" 63362 fi 63363 fi 63364 63365 63366 if test "x$path" != "x$new_path"; then 63367 POTENTIAL_FREETYPE_INCLUDE_PATH="$new_path" 63368 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&5 63369 $as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&6;} 63370 fi 63371 63372 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 63373 63374 path="$POTENTIAL_FREETYPE_INCLUDE_PATH" 63375 has_colon=`$ECHO $path | $GREP ^.:` 63376 new_path="$path" 63377 if test "x$has_colon" = x; then 63378 # Not in mixed or Windows style, start by that. 63379 new_path=`cmd //c echo $path` 63380 fi 63381 63382 63383 input_path="$new_path" 63384 # Check if we need to convert this using DOS-style short mode. If the path 63385 # contains just simple characters, use it. Otherwise (spaces, weird characters), 63386 # take no chances and rewrite it. 63387 # Note: m4 eats our [], so we need to use [ and ] instead. 63388 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 63389 if test "x$has_forbidden_chars" != x; then 63390 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 63391 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 63392 fi 63393 63394 63395 windows_path="$new_path" 63396 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 63397 unix_path=`$CYGPATH -u "$windows_path"` 63398 new_path="$unix_path" 63399 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 63400 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 63401 new_path="$unix_path" 63402 fi 63403 63404 if test "x$path" != "x$new_path"; then 63405 POTENTIAL_FREETYPE_INCLUDE_PATH="$new_path" 63406 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&5 63407 $as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&6;} 63408 fi 63409 63410 # Save the first 10 bytes of this path to the storage, so fixpath can work. 63411 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 63412 63413 else 63414 # We're on a unix platform. Hooray! :) 63415 path="$POTENTIAL_FREETYPE_INCLUDE_PATH" 63416 has_space=`$ECHO "$path" | $GREP " "` 63417 if test "x$has_space" != x; then 63418 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&5 63419 $as_echo "$as_me: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&6;} 63420 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 63421 fi 63422 63423 # Use eval to expand a potential ~ 63424 eval path="$path" 63425 if test ! -f "$path" && test ! -d "$path"; then 63426 as_fn_error $? "The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is not found." "$LINENO" 5 63427 fi 63428 63429 if test -d "$path"; then 63430 POTENTIAL_FREETYPE_INCLUDE_PATH="`cd "$path"; $THEPWDCMD -L`" 63431 else 63432 dir="`$DIRNAME "$path"`" 63433 base="`$BASENAME "$path"`" 63434 POTENTIAL_FREETYPE_INCLUDE_PATH="`cd "$dir"; $THEPWDCMD -L`/$base" 63435 fi 63436 fi 63437 fi 63438 63439 63440 # Only process if variable expands to non-empty 63441 63442 if test "x$POTENTIAL_FREETYPE_LIB_PATH" != x; then 63443 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 63444 63445 # Input might be given as Windows format, start by converting to 63446 # unix format. 63447 path="$POTENTIAL_FREETYPE_LIB_PATH" 63448 new_path=`$CYGPATH -u "$path"` 63449 63450 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 63451 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 63452 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 63453 # "foo.exe" is OK but "foo" is an error. 63454 # 63455 # This test is therefore slightly more accurate than "test -f" to check for file precense. 63456 # It is also a way to make sure we got the proper file name for the real test later on. 63457 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 63458 if test "x$test_shortpath" = x; then 63459 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&5 63460 $as_echo "$as_me: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&6;} 63461 as_fn_error $? "Cannot locate the the path of POTENTIAL_FREETYPE_LIB_PATH" "$LINENO" 5 63462 fi 63463 63464 # Call helper function which possibly converts this using DOS-style short mode. 63465 # If so, the updated path is stored in $new_path. 63466 63467 input_path="$new_path" 63468 # Check if we need to convert this using DOS-style short mode. If the path 63469 # contains just simple characters, use it. Otherwise (spaces, weird characters), 63470 # take no chances and rewrite it. 63471 # Note: m4 eats our [], so we need to use [ and ] instead. 63472 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 63473 if test "x$has_forbidden_chars" != x; then 63474 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 63475 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 63476 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 63477 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 63478 # Going to short mode and back again did indeed matter. Since short mode is 63479 # case insensitive, let's make it lowercase to improve readability. 63480 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 63481 # Now convert it back to Unix-style (cygpath) 63482 input_path=`$CYGPATH -u "$shortmode_path"` 63483 new_path="$input_path" 63484 fi 63485 fi 63486 63487 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 63488 if test "x$test_cygdrive_prefix" = x; then 63489 # As a simple fix, exclude /usr/bin since it's not a real path. 63490 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 63491 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 63492 # a path prefixed by /cygdrive for fixpath to work. 63493 new_path="$CYGWIN_ROOT_PATH$input_path" 63494 fi 63495 fi 63496 63497 63498 if test "x$path" != "x$new_path"; then 63499 POTENTIAL_FREETYPE_LIB_PATH="$new_path" 63500 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&5 63501 $as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&6;} 63502 fi 63503 63504 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 63505 63506 path="$POTENTIAL_FREETYPE_LIB_PATH" 63507 has_colon=`$ECHO $path | $GREP ^.:` 63508 new_path="$path" 63509 if test "x$has_colon" = x; then 63510 # Not in mixed or Windows style, start by that. 63511 new_path=`cmd //c echo $path` 63512 fi 63513 63514 63515 input_path="$new_path" 63516 # Check if we need to convert this using DOS-style short mode. If the path 63517 # contains just simple characters, use it. Otherwise (spaces, weird characters), 63518 # take no chances and rewrite it. 63519 # Note: m4 eats our [], so we need to use [ and ] instead. 63520 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 63521 if test "x$has_forbidden_chars" != x; then 63522 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 63523 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 63524 fi 63525 63526 63527 windows_path="$new_path" 63528 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 63529 unix_path=`$CYGPATH -u "$windows_path"` 63530 new_path="$unix_path" 63531 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 63532 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 63533 new_path="$unix_path" 63534 fi 63535 63536 if test "x$path" != "x$new_path"; then 63537 POTENTIAL_FREETYPE_LIB_PATH="$new_path" 63538 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&5 63539 $as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&6;} 63540 fi 63541 63542 # Save the first 10 bytes of this path to the storage, so fixpath can work. 63543 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 63544 63545 else 63546 # We're on a unix platform. Hooray! :) 63547 path="$POTENTIAL_FREETYPE_LIB_PATH" 63548 has_space=`$ECHO "$path" | $GREP " "` 63549 if test "x$has_space" != x; then 63550 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&5 63551 $as_echo "$as_me: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&6;} 63552 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 63553 fi 63554 63555 # Use eval to expand a potential ~ 63556 eval path="$path" 63557 if test ! -f "$path" && test ! -d "$path"; then 63558 as_fn_error $? "The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is not found." "$LINENO" 5 63559 fi 63560 63561 if test -d "$path"; then 63562 POTENTIAL_FREETYPE_LIB_PATH="`cd "$path"; $THEPWDCMD -L`" 63563 else 63564 dir="`$DIRNAME "$path"`" 63565 base="`$BASENAME "$path"`" 63566 POTENTIAL_FREETYPE_LIB_PATH="`cd "$dir"; $THEPWDCMD -L`/$base" 63567 fi 63568 fi 63569 fi 63570 63571 63572 FREETYPE_INCLUDE_PATH="$POTENTIAL_FREETYPE_INCLUDE_PATH" 63573 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for freetype includes" >&5 63574 $as_echo_n "checking for freetype includes... " >&6; } 63575 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $FREETYPE_INCLUDE_PATH" >&5 63576 $as_echo "$FREETYPE_INCLUDE_PATH" >&6; } 63577 FREETYPE_LIB_PATH="$POTENTIAL_FREETYPE_LIB_PATH" 63578 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for freetype libraries" >&5 63579 $as_echo_n "checking for freetype libraries... " >&6; } 63580 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $FREETYPE_LIB_PATH" >&5 63581 $as_echo "$FREETYPE_LIB_PATH" >&6; } 63582 fi 63583 63584 fi 63585 63586 if test "x$OPENJDK_TARGET_OS" = xmacosx; then 63587 if test "x$FOUND_FREETYPE" != xyes; then 63588 # Due to changes in OSX 10.11 XQuartz now installs to /opt/X11 63589 FREETYPE_BASE_DIR="$SYSROOT/opt/X11" 63590 63591 POTENTIAL_FREETYPE_INCLUDE_PATH="$FREETYPE_BASE_DIR/include" 63592 POTENTIAL_FREETYPE_LIB_PATH="$FREETYPE_BASE_DIR/lib" 63593 METHOD="well-known location" 63594 63595 # Let's start with an optimistic view of the world :-) 63596 FOUND_FREETYPE=yes 63597 63598 # First look for the canonical freetype main include file ft2build.h. 63599 if ! test -s "$POTENTIAL_FREETYPE_INCLUDE_PATH/ft2build.h"; then 63600 # Oh no! Let's try in the freetype2 directory. This is needed at least at Mac OS X Yosemite. 63601 POTENTIAL_FREETYPE_INCLUDE_PATH="$POTENTIAL_FREETYPE_INCLUDE_PATH/freetype2" 63602 if ! test -s "$POTENTIAL_FREETYPE_INCLUDE_PATH/ft2build.h"; then 63603 # Fail. 63604 FOUND_FREETYPE=no 63605 fi 63606 fi 63607 63608 if test "x$FOUND_FREETYPE" = xyes; then 63609 # Include file found, let's continue the sanity check. 63610 { $as_echo "$as_me:${as_lineno-$LINENO}: Found freetype include files at $POTENTIAL_FREETYPE_INCLUDE_PATH using $METHOD" >&5 63611 $as_echo "$as_me: Found freetype include files at $POTENTIAL_FREETYPE_INCLUDE_PATH using $METHOD" >&6;} 63612 63613 # Reset to default value 63614 FREETYPE_BASE_NAME=freetype 63615 FREETYPE_LIB_NAME="${LIBRARY_PREFIX}${FREETYPE_BASE_NAME}${SHARED_LIBRARY_SUFFIX}" 63616 if ! test -s "$POTENTIAL_FREETYPE_LIB_PATH/$FREETYPE_LIB_NAME"; then 63617 if test "x$OPENJDK_TARGET_OS" = xmacosx \ 63618 && test -s "$POTENTIAL_FREETYPE_LIB_PATH/${LIBRARY_PREFIX}freetype.6${SHARED_LIBRARY_SUFFIX}"; then 63619 # On Mac OS X Yosemite, the symlink from libfreetype.dylib to libfreetype.6.dylib disappeared. Check 63620 # for the .6 version explicitly. 63621 FREETYPE_BASE_NAME=freetype.6 63622 FREETYPE_LIB_NAME="${LIBRARY_PREFIX}${FREETYPE_BASE_NAME}${SHARED_LIBRARY_SUFFIX}" 63623 { $as_echo "$as_me:${as_lineno-$LINENO}: Compensating for missing symlink by using version 6 explicitly" >&5 63624 $as_echo "$as_me: Compensating for missing symlink by using version 6 explicitly" >&6;} 63625 else 63626 { $as_echo "$as_me:${as_lineno-$LINENO}: Could not find $POTENTIAL_FREETYPE_LIB_PATH/$FREETYPE_LIB_NAME. Ignoring location." >&5 63627 $as_echo "$as_me: Could not find $POTENTIAL_FREETYPE_LIB_PATH/$FREETYPE_LIB_NAME. Ignoring location." >&6;} 63628 FOUND_FREETYPE=no 63629 fi 63630 else 63631 if test "x$OPENJDK_TARGET_OS" = xwindows; then 63632 # On Windows, we will need both .lib and .dll file. 63633 if ! test -s "$POTENTIAL_FREETYPE_LIB_PATH/${FREETYPE_BASE_NAME}.lib"; then 63634 { $as_echo "$as_me:${as_lineno-$LINENO}: Could not find $POTENTIAL_FREETYPE_LIB_PATH/${FREETYPE_BASE_NAME}.lib. Ignoring location." >&5 63635 $as_echo "$as_me: Could not find $POTENTIAL_FREETYPE_LIB_PATH/${FREETYPE_BASE_NAME}.lib. Ignoring location." >&6;} 63636 FOUND_FREETYPE=no 63637 fi 63638 elif test "x$OPENJDK_TARGET_OS" = xsolaris \ 63639 && test -s "$POTENTIAL_FREETYPE_LIB_PATH$OPENJDK_TARGET_CPU_ISADIR/$FREETYPE_LIB_NAME"; then 63640 # Found lib in isa dir, use that instead. 63641 POTENTIAL_FREETYPE_LIB_PATH="$POTENTIAL_FREETYPE_LIB_PATH$OPENJDK_TARGET_CPU_ISADIR" 63642 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting to use $POTENTIAL_FREETYPE_LIB_PATH instead" >&5 63643 $as_echo "$as_me: Rewriting to use $POTENTIAL_FREETYPE_LIB_PATH instead" >&6;} 63644 fi 63645 fi 63646 fi 63647 63648 if test "x$FOUND_FREETYPE" = xyes; then 63649 63650 # Only process if variable expands to non-empty 63651 63652 if test "x$POTENTIAL_FREETYPE_INCLUDE_PATH" != x; then 63653 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 63654 63655 # Input might be given as Windows format, start by converting to 63656 # unix format. 63657 path="$POTENTIAL_FREETYPE_INCLUDE_PATH" 63658 new_path=`$CYGPATH -u "$path"` 63659 63660 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 63661 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 63662 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 63663 # "foo.exe" is OK but "foo" is an error. 63664 # 63665 # This test is therefore slightly more accurate than "test -f" to check for file precense. 63666 # It is also a way to make sure we got the proper file name for the real test later on. 63667 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 63668 if test "x$test_shortpath" = x; then 63669 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&5 63670 $as_echo "$as_me: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&6;} 63671 as_fn_error $? "Cannot locate the the path of POTENTIAL_FREETYPE_INCLUDE_PATH" "$LINENO" 5 63672 fi 63673 63674 # Call helper function which possibly converts this using DOS-style short mode. 63675 # If so, the updated path is stored in $new_path. 63676 63677 input_path="$new_path" 63678 # Check if we need to convert this using DOS-style short mode. If the path 63679 # contains just simple characters, use it. Otherwise (spaces, weird characters), 63680 # take no chances and rewrite it. 63681 # Note: m4 eats our [], so we need to use [ and ] instead. 63682 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 63683 if test "x$has_forbidden_chars" != x; then 63684 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 63685 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 63686 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 63687 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 63688 # Going to short mode and back again did indeed matter. Since short mode is 63689 # case insensitive, let's make it lowercase to improve readability. 63690 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 63691 # Now convert it back to Unix-style (cygpath) 63692 input_path=`$CYGPATH -u "$shortmode_path"` 63693 new_path="$input_path" 63694 fi 63695 fi 63696 63697 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 63698 if test "x$test_cygdrive_prefix" = x; then 63699 # As a simple fix, exclude /usr/bin since it's not a real path. 63700 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 63701 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 63702 # a path prefixed by /cygdrive for fixpath to work. 63703 new_path="$CYGWIN_ROOT_PATH$input_path" 63704 fi 63705 fi 63706 63707 63708 if test "x$path" != "x$new_path"; then 63709 POTENTIAL_FREETYPE_INCLUDE_PATH="$new_path" 63710 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&5 63711 $as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&6;} 63712 fi 63713 63714 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 63715 63716 path="$POTENTIAL_FREETYPE_INCLUDE_PATH" 63717 has_colon=`$ECHO $path | $GREP ^.:` 63718 new_path="$path" 63719 if test "x$has_colon" = x; then 63720 # Not in mixed or Windows style, start by that. 63721 new_path=`cmd //c echo $path` 63722 fi 63723 63724 63725 input_path="$new_path" 63726 # Check if we need to convert this using DOS-style short mode. If the path 63727 # contains just simple characters, use it. Otherwise (spaces, weird characters), 63728 # take no chances and rewrite it. 63729 # Note: m4 eats our [], so we need to use [ and ] instead. 63730 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 63731 if test "x$has_forbidden_chars" != x; then 63732 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 63733 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 63734 fi 63735 63736 63737 windows_path="$new_path" 63738 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 63739 unix_path=`$CYGPATH -u "$windows_path"` 63740 new_path="$unix_path" 63741 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 63742 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 63743 new_path="$unix_path" 63744 fi 63745 63746 if test "x$path" != "x$new_path"; then 63747 POTENTIAL_FREETYPE_INCLUDE_PATH="$new_path" 63748 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&5 63749 $as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&6;} 63750 fi 63751 63752 # Save the first 10 bytes of this path to the storage, so fixpath can work. 63753 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 63754 63755 else 63756 # We're on a unix platform. Hooray! :) 63757 path="$POTENTIAL_FREETYPE_INCLUDE_PATH" 63758 has_space=`$ECHO "$path" | $GREP " "` 63759 if test "x$has_space" != x; then 63760 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&5 63761 $as_echo "$as_me: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&6;} 63762 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 63763 fi 63764 63765 # Use eval to expand a potential ~ 63766 eval path="$path" 63767 if test ! -f "$path" && test ! -d "$path"; then 63768 as_fn_error $? "The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is not found." "$LINENO" 5 63769 fi 63770 63771 if test -d "$path"; then 63772 POTENTIAL_FREETYPE_INCLUDE_PATH="`cd "$path"; $THEPWDCMD -L`" 63773 else 63774 dir="`$DIRNAME "$path"`" 63775 base="`$BASENAME "$path"`" 63776 POTENTIAL_FREETYPE_INCLUDE_PATH="`cd "$dir"; $THEPWDCMD -L`/$base" 63777 fi 63778 fi 63779 fi 63780 63781 63782 # Only process if variable expands to non-empty 63783 63784 if test "x$POTENTIAL_FREETYPE_LIB_PATH" != x; then 63785 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 63786 63787 # Input might be given as Windows format, start by converting to 63788 # unix format. 63789 path="$POTENTIAL_FREETYPE_LIB_PATH" 63790 new_path=`$CYGPATH -u "$path"` 63791 63792 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 63793 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 63794 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 63795 # "foo.exe" is OK but "foo" is an error. 63796 # 63797 # This test is therefore slightly more accurate than "test -f" to check for file precense. 63798 # It is also a way to make sure we got the proper file name for the real test later on. 63799 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 63800 if test "x$test_shortpath" = x; then 63801 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&5 63802 $as_echo "$as_me: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&6;} 63803 as_fn_error $? "Cannot locate the the path of POTENTIAL_FREETYPE_LIB_PATH" "$LINENO" 5 63804 fi 63805 63806 # Call helper function which possibly converts this using DOS-style short mode. 63807 # If so, the updated path is stored in $new_path. 63808 63809 input_path="$new_path" 63810 # Check if we need to convert this using DOS-style short mode. If the path 63811 # contains just simple characters, use it. Otherwise (spaces, weird characters), 63812 # take no chances and rewrite it. 63813 # Note: m4 eats our [], so we need to use [ and ] instead. 63814 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 63815 if test "x$has_forbidden_chars" != x; then 63816 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 63817 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 63818 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 63819 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 63820 # Going to short mode and back again did indeed matter. Since short mode is 63821 # case insensitive, let's make it lowercase to improve readability. 63822 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 63823 # Now convert it back to Unix-style (cygpath) 63824 input_path=`$CYGPATH -u "$shortmode_path"` 63825 new_path="$input_path" 63826 fi 63827 fi 63828 63829 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 63830 if test "x$test_cygdrive_prefix" = x; then 63831 # As a simple fix, exclude /usr/bin since it's not a real path. 63832 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 63833 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 63834 # a path prefixed by /cygdrive for fixpath to work. 63835 new_path="$CYGWIN_ROOT_PATH$input_path" 63836 fi 63837 fi 63838 63839 63840 if test "x$path" != "x$new_path"; then 63841 POTENTIAL_FREETYPE_LIB_PATH="$new_path" 63842 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&5 63843 $as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&6;} 63844 fi 63845 63846 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 63847 63848 path="$POTENTIAL_FREETYPE_LIB_PATH" 63849 has_colon=`$ECHO $path | $GREP ^.:` 63850 new_path="$path" 63851 if test "x$has_colon" = x; then 63852 # Not in mixed or Windows style, start by that. 63853 new_path=`cmd //c echo $path` 63854 fi 63855 63856 63857 input_path="$new_path" 63858 # Check if we need to convert this using DOS-style short mode. If the path 63859 # contains just simple characters, use it. Otherwise (spaces, weird characters), 63860 # take no chances and rewrite it. 63861 # Note: m4 eats our [], so we need to use [ and ] instead. 63862 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 63863 if test "x$has_forbidden_chars" != x; then 63864 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 63865 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 63866 fi 63867 63868 63869 windows_path="$new_path" 63870 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 63871 unix_path=`$CYGPATH -u "$windows_path"` 63872 new_path="$unix_path" 63873 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 63874 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 63875 new_path="$unix_path" 63876 fi 63877 63878 if test "x$path" != "x$new_path"; then 63879 POTENTIAL_FREETYPE_LIB_PATH="$new_path" 63880 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&5 63881 $as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&6;} 63882 fi 63883 63884 # Save the first 10 bytes of this path to the storage, so fixpath can work. 63885 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 63886 63887 else 63888 # We're on a unix platform. Hooray! :) 63889 path="$POTENTIAL_FREETYPE_LIB_PATH" 63890 has_space=`$ECHO "$path" | $GREP " "` 63891 if test "x$has_space" != x; then 63892 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&5 63893 $as_echo "$as_me: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&6;} 63894 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 63895 fi 63896 63897 # Use eval to expand a potential ~ 63898 eval path="$path" 63899 if test ! -f "$path" && test ! -d "$path"; then 63900 as_fn_error $? "The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is not found." "$LINENO" 5 63901 fi 63902 63903 if test -d "$path"; then 63904 POTENTIAL_FREETYPE_LIB_PATH="`cd "$path"; $THEPWDCMD -L`" 63905 else 63906 dir="`$DIRNAME "$path"`" 63907 base="`$BASENAME "$path"`" 63908 POTENTIAL_FREETYPE_LIB_PATH="`cd "$dir"; $THEPWDCMD -L`/$base" 63909 fi 63910 fi 63911 fi 63912 63913 63914 FREETYPE_INCLUDE_PATH="$POTENTIAL_FREETYPE_INCLUDE_PATH" 63915 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for freetype includes" >&5 63916 $as_echo_n "checking for freetype includes... " >&6; } 63917 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $FREETYPE_INCLUDE_PATH" >&5 63918 $as_echo "$FREETYPE_INCLUDE_PATH" >&6; } 63919 FREETYPE_LIB_PATH="$POTENTIAL_FREETYPE_LIB_PATH" 63920 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for freetype libraries" >&5 63921 $as_echo_n "checking for freetype libraries... " >&6; } 63922 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $FREETYPE_LIB_PATH" >&5 63923 $as_echo "$FREETYPE_LIB_PATH" >&6; } 63924 fi 63925 63926 fi 63927 fi 63928 63929 if test "x$FOUND_FREETYPE" != xyes; then 63930 FREETYPE_BASE_DIR="$SYSROOT/usr" 63931 if test "x$OPENJDK_TARGET_CPU_BITS" = x64; then 63932 63933 POTENTIAL_FREETYPE_INCLUDE_PATH="$FREETYPE_BASE_DIR/include" 63934 POTENTIAL_FREETYPE_LIB_PATH="$FREETYPE_BASE_DIR/lib/$OPENJDK_TARGET_CPU-linux-gnu" 63935 METHOD="well-known location" 63936 63937 # Let's start with an optimistic view of the world :-) 63938 FOUND_FREETYPE=yes 63939 63940 # First look for the canonical freetype main include file ft2build.h. 63941 if ! test -s "$POTENTIAL_FREETYPE_INCLUDE_PATH/ft2build.h"; then 63942 # Oh no! Let's try in the freetype2 directory. This is needed at least at Mac OS X Yosemite. 63943 POTENTIAL_FREETYPE_INCLUDE_PATH="$POTENTIAL_FREETYPE_INCLUDE_PATH/freetype2" 63944 if ! test -s "$POTENTIAL_FREETYPE_INCLUDE_PATH/ft2build.h"; then 63945 # Fail. 63946 FOUND_FREETYPE=no 63947 fi 63948 fi 63949 63950 if test "x$FOUND_FREETYPE" = xyes; then 63951 # Include file found, let's continue the sanity check. 63952 { $as_echo "$as_me:${as_lineno-$LINENO}: Found freetype include files at $POTENTIAL_FREETYPE_INCLUDE_PATH using $METHOD" >&5 63953 $as_echo "$as_me: Found freetype include files at $POTENTIAL_FREETYPE_INCLUDE_PATH using $METHOD" >&6;} 63954 63955 # Reset to default value 63956 FREETYPE_BASE_NAME=freetype 63957 FREETYPE_LIB_NAME="${LIBRARY_PREFIX}${FREETYPE_BASE_NAME}${SHARED_LIBRARY_SUFFIX}" 63958 if ! test -s "$POTENTIAL_FREETYPE_LIB_PATH/$FREETYPE_LIB_NAME"; then 63959 if test "x$OPENJDK_TARGET_OS" = xmacosx \ 63960 && test -s "$POTENTIAL_FREETYPE_LIB_PATH/${LIBRARY_PREFIX}freetype.6${SHARED_LIBRARY_SUFFIX}"; then 63961 # On Mac OS X Yosemite, the symlink from libfreetype.dylib to libfreetype.6.dylib disappeared. Check 63962 # for the .6 version explicitly. 63963 FREETYPE_BASE_NAME=freetype.6 63964 FREETYPE_LIB_NAME="${LIBRARY_PREFIX}${FREETYPE_BASE_NAME}${SHARED_LIBRARY_SUFFIX}" 63965 { $as_echo "$as_me:${as_lineno-$LINENO}: Compensating for missing symlink by using version 6 explicitly" >&5 63966 $as_echo "$as_me: Compensating for missing symlink by using version 6 explicitly" >&6;} 63967 else 63968 { $as_echo "$as_me:${as_lineno-$LINENO}: Could not find $POTENTIAL_FREETYPE_LIB_PATH/$FREETYPE_LIB_NAME. Ignoring location." >&5 63969 $as_echo "$as_me: Could not find $POTENTIAL_FREETYPE_LIB_PATH/$FREETYPE_LIB_NAME. Ignoring location." >&6;} 63970 FOUND_FREETYPE=no 63971 fi 63972 else 63973 if test "x$OPENJDK_TARGET_OS" = xwindows; then 63974 # On Windows, we will need both .lib and .dll file. 63975 if ! test -s "$POTENTIAL_FREETYPE_LIB_PATH/${FREETYPE_BASE_NAME}.lib"; then 63976 { $as_echo "$as_me:${as_lineno-$LINENO}: Could not find $POTENTIAL_FREETYPE_LIB_PATH/${FREETYPE_BASE_NAME}.lib. Ignoring location." >&5 63977 $as_echo "$as_me: Could not find $POTENTIAL_FREETYPE_LIB_PATH/${FREETYPE_BASE_NAME}.lib. Ignoring location." >&6;} 63978 FOUND_FREETYPE=no 63979 fi 63980 elif test "x$OPENJDK_TARGET_OS" = xsolaris \ 63981 && test -s "$POTENTIAL_FREETYPE_LIB_PATH$OPENJDK_TARGET_CPU_ISADIR/$FREETYPE_LIB_NAME"; then 63982 # Found lib in isa dir, use that instead. 63983 POTENTIAL_FREETYPE_LIB_PATH="$POTENTIAL_FREETYPE_LIB_PATH$OPENJDK_TARGET_CPU_ISADIR" 63984 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting to use $POTENTIAL_FREETYPE_LIB_PATH instead" >&5 63985 $as_echo "$as_me: Rewriting to use $POTENTIAL_FREETYPE_LIB_PATH instead" >&6;} 63986 fi 63987 fi 63988 fi 63989 63990 if test "x$FOUND_FREETYPE" = xyes; then 63991 63992 # Only process if variable expands to non-empty 63993 63994 if test "x$POTENTIAL_FREETYPE_INCLUDE_PATH" != x; then 63995 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 63996 63997 # Input might be given as Windows format, start by converting to 63998 # unix format. 63999 path="$POTENTIAL_FREETYPE_INCLUDE_PATH" 64000 new_path=`$CYGPATH -u "$path"` 64001 64002 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 64003 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 64004 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 64005 # "foo.exe" is OK but "foo" is an error. 64006 # 64007 # This test is therefore slightly more accurate than "test -f" to check for file precense. 64008 # It is also a way to make sure we got the proper file name for the real test later on. 64009 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 64010 if test "x$test_shortpath" = x; then 64011 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&5 64012 $as_echo "$as_me: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&6;} 64013 as_fn_error $? "Cannot locate the the path of POTENTIAL_FREETYPE_INCLUDE_PATH" "$LINENO" 5 64014 fi 64015 64016 # Call helper function which possibly converts this using DOS-style short mode. 64017 # If so, the updated path is stored in $new_path. 64018 64019 input_path="$new_path" 64020 # Check if we need to convert this using DOS-style short mode. If the path 64021 # contains just simple characters, use it. Otherwise (spaces, weird characters), 64022 # take no chances and rewrite it. 64023 # Note: m4 eats our [], so we need to use [ and ] instead. 64024 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 64025 if test "x$has_forbidden_chars" != x; then 64026 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 64027 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 64028 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 64029 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 64030 # Going to short mode and back again did indeed matter. Since short mode is 64031 # case insensitive, let's make it lowercase to improve readability. 64032 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 64033 # Now convert it back to Unix-style (cygpath) 64034 input_path=`$CYGPATH -u "$shortmode_path"` 64035 new_path="$input_path" 64036 fi 64037 fi 64038 64039 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 64040 if test "x$test_cygdrive_prefix" = x; then 64041 # As a simple fix, exclude /usr/bin since it's not a real path. 64042 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 64043 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 64044 # a path prefixed by /cygdrive for fixpath to work. 64045 new_path="$CYGWIN_ROOT_PATH$input_path" 64046 fi 64047 fi 64048 64049 64050 if test "x$path" != "x$new_path"; then 64051 POTENTIAL_FREETYPE_INCLUDE_PATH="$new_path" 64052 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&5 64053 $as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&6;} 64054 fi 64055 64056 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 64057 64058 path="$POTENTIAL_FREETYPE_INCLUDE_PATH" 64059 has_colon=`$ECHO $path | $GREP ^.:` 64060 new_path="$path" 64061 if test "x$has_colon" = x; then 64062 # Not in mixed or Windows style, start by that. 64063 new_path=`cmd //c echo $path` 64064 fi 64065 64066 64067 input_path="$new_path" 64068 # Check if we need to convert this using DOS-style short mode. If the path 64069 # contains just simple characters, use it. Otherwise (spaces, weird characters), 64070 # take no chances and rewrite it. 64071 # Note: m4 eats our [], so we need to use [ and ] instead. 64072 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 64073 if test "x$has_forbidden_chars" != x; then 64074 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 64075 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 64076 fi 64077 64078 64079 windows_path="$new_path" 64080 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 64081 unix_path=`$CYGPATH -u "$windows_path"` 64082 new_path="$unix_path" 64083 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 64084 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 64085 new_path="$unix_path" 64086 fi 64087 64088 if test "x$path" != "x$new_path"; then 64089 POTENTIAL_FREETYPE_INCLUDE_PATH="$new_path" 64090 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&5 64091 $as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&6;} 64092 fi 64093 64094 # Save the first 10 bytes of this path to the storage, so fixpath can work. 64095 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 64096 64097 else 64098 # We're on a unix platform. Hooray! :) 64099 path="$POTENTIAL_FREETYPE_INCLUDE_PATH" 64100 has_space=`$ECHO "$path" | $GREP " "` 64101 if test "x$has_space" != x; then 64102 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&5 64103 $as_echo "$as_me: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&6;} 64104 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 64105 fi 64106 64107 # Use eval to expand a potential ~ 64108 eval path="$path" 64109 if test ! -f "$path" && test ! -d "$path"; then 64110 as_fn_error $? "The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is not found." "$LINENO" 5 64111 fi 64112 64113 if test -d "$path"; then 64114 POTENTIAL_FREETYPE_INCLUDE_PATH="`cd "$path"; $THEPWDCMD -L`" 64115 else 64116 dir="`$DIRNAME "$path"`" 64117 base="`$BASENAME "$path"`" 64118 POTENTIAL_FREETYPE_INCLUDE_PATH="`cd "$dir"; $THEPWDCMD -L`/$base" 64119 fi 64120 fi 64121 fi 64122 64123 64124 # Only process if variable expands to non-empty 64125 64126 if test "x$POTENTIAL_FREETYPE_LIB_PATH" != x; then 64127 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 64128 64129 # Input might be given as Windows format, start by converting to 64130 # unix format. 64131 path="$POTENTIAL_FREETYPE_LIB_PATH" 64132 new_path=`$CYGPATH -u "$path"` 64133 64134 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 64135 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 64136 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 64137 # "foo.exe" is OK but "foo" is an error. 64138 # 64139 # This test is therefore slightly more accurate than "test -f" to check for file precense. 64140 # It is also a way to make sure we got the proper file name for the real test later on. 64141 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 64142 if test "x$test_shortpath" = x; then 64143 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&5 64144 $as_echo "$as_me: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&6;} 64145 as_fn_error $? "Cannot locate the the path of POTENTIAL_FREETYPE_LIB_PATH" "$LINENO" 5 64146 fi 64147 64148 # Call helper function which possibly converts this using DOS-style short mode. 64149 # If so, the updated path is stored in $new_path. 64150 64151 input_path="$new_path" 64152 # Check if we need to convert this using DOS-style short mode. If the path 64153 # contains just simple characters, use it. Otherwise (spaces, weird characters), 64154 # take no chances and rewrite it. 64155 # Note: m4 eats our [], so we need to use [ and ] instead. 64156 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 64157 if test "x$has_forbidden_chars" != x; then 64158 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 64159 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 64160 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 64161 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 64162 # Going to short mode and back again did indeed matter. Since short mode is 64163 # case insensitive, let's make it lowercase to improve readability. 64164 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 64165 # Now convert it back to Unix-style (cygpath) 64166 input_path=`$CYGPATH -u "$shortmode_path"` 64167 new_path="$input_path" 64168 fi 64169 fi 64170 64171 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 64172 if test "x$test_cygdrive_prefix" = x; then 64173 # As a simple fix, exclude /usr/bin since it's not a real path. 64174 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 64175 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 64176 # a path prefixed by /cygdrive for fixpath to work. 64177 new_path="$CYGWIN_ROOT_PATH$input_path" 64178 fi 64179 fi 64180 64181 64182 if test "x$path" != "x$new_path"; then 64183 POTENTIAL_FREETYPE_LIB_PATH="$new_path" 64184 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&5 64185 $as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&6;} 64186 fi 64187 64188 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 64189 64190 path="$POTENTIAL_FREETYPE_LIB_PATH" 64191 has_colon=`$ECHO $path | $GREP ^.:` 64192 new_path="$path" 64193 if test "x$has_colon" = x; then 64194 # Not in mixed or Windows style, start by that. 64195 new_path=`cmd //c echo $path` 64196 fi 64197 64198 64199 input_path="$new_path" 64200 # Check if we need to convert this using DOS-style short mode. If the path 64201 # contains just simple characters, use it. Otherwise (spaces, weird characters), 64202 # take no chances and rewrite it. 64203 # Note: m4 eats our [], so we need to use [ and ] instead. 64204 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 64205 if test "x$has_forbidden_chars" != x; then 64206 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 64207 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 64208 fi 64209 64210 64211 windows_path="$new_path" 64212 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 64213 unix_path=`$CYGPATH -u "$windows_path"` 64214 new_path="$unix_path" 64215 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 64216 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 64217 new_path="$unix_path" 64218 fi 64219 64220 if test "x$path" != "x$new_path"; then 64221 POTENTIAL_FREETYPE_LIB_PATH="$new_path" 64222 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&5 64223 $as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&6;} 64224 fi 64225 64226 # Save the first 10 bytes of this path to the storage, so fixpath can work. 64227 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 64228 64229 else 64230 # We're on a unix platform. Hooray! :) 64231 path="$POTENTIAL_FREETYPE_LIB_PATH" 64232 has_space=`$ECHO "$path" | $GREP " "` 64233 if test "x$has_space" != x; then 64234 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&5 64235 $as_echo "$as_me: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&6;} 64236 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 64237 fi 64238 64239 # Use eval to expand a potential ~ 64240 eval path="$path" 64241 if test ! -f "$path" && test ! -d "$path"; then 64242 as_fn_error $? "The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is not found." "$LINENO" 5 64243 fi 64244 64245 if test -d "$path"; then 64246 POTENTIAL_FREETYPE_LIB_PATH="`cd "$path"; $THEPWDCMD -L`" 64247 else 64248 dir="`$DIRNAME "$path"`" 64249 base="`$BASENAME "$path"`" 64250 POTENTIAL_FREETYPE_LIB_PATH="`cd "$dir"; $THEPWDCMD -L`/$base" 64251 fi 64252 fi 64253 fi 64254 64255 64256 FREETYPE_INCLUDE_PATH="$POTENTIAL_FREETYPE_INCLUDE_PATH" 64257 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for freetype includes" >&5 64258 $as_echo_n "checking for freetype includes... " >&6; } 64259 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $FREETYPE_INCLUDE_PATH" >&5 64260 $as_echo "$FREETYPE_INCLUDE_PATH" >&6; } 64261 FREETYPE_LIB_PATH="$POTENTIAL_FREETYPE_LIB_PATH" 64262 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for freetype libraries" >&5 64263 $as_echo_n "checking for freetype libraries... " >&6; } 64264 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $FREETYPE_LIB_PATH" >&5 64265 $as_echo "$FREETYPE_LIB_PATH" >&6; } 64266 fi 64267 64268 else 64269 64270 POTENTIAL_FREETYPE_INCLUDE_PATH="$FREETYPE_BASE_DIR/include" 64271 POTENTIAL_FREETYPE_LIB_PATH="$FREETYPE_BASE_DIR/lib/i386-linux-gnu" 64272 METHOD="well-known location" 64273 64274 # Let's start with an optimistic view of the world :-) 64275 FOUND_FREETYPE=yes 64276 64277 # First look for the canonical freetype main include file ft2build.h. 64278 if ! test -s "$POTENTIAL_FREETYPE_INCLUDE_PATH/ft2build.h"; then 64279 # Oh no! Let's try in the freetype2 directory. This is needed at least at Mac OS X Yosemite. 64280 POTENTIAL_FREETYPE_INCLUDE_PATH="$POTENTIAL_FREETYPE_INCLUDE_PATH/freetype2" 64281 if ! test -s "$POTENTIAL_FREETYPE_INCLUDE_PATH/ft2build.h"; then 64282 # Fail. 64283 FOUND_FREETYPE=no 64284 fi 64285 fi 64286 64287 if test "x$FOUND_FREETYPE" = xyes; then 64288 # Include file found, let's continue the sanity check. 64289 { $as_echo "$as_me:${as_lineno-$LINENO}: Found freetype include files at $POTENTIAL_FREETYPE_INCLUDE_PATH using $METHOD" >&5 64290 $as_echo "$as_me: Found freetype include files at $POTENTIAL_FREETYPE_INCLUDE_PATH using $METHOD" >&6;} 64291 64292 # Reset to default value 64293 FREETYPE_BASE_NAME=freetype 64294 FREETYPE_LIB_NAME="${LIBRARY_PREFIX}${FREETYPE_BASE_NAME}${SHARED_LIBRARY_SUFFIX}" 64295 if ! test -s "$POTENTIAL_FREETYPE_LIB_PATH/$FREETYPE_LIB_NAME"; then 64296 if test "x$OPENJDK_TARGET_OS" = xmacosx \ 64297 && test -s "$POTENTIAL_FREETYPE_LIB_PATH/${LIBRARY_PREFIX}freetype.6${SHARED_LIBRARY_SUFFIX}"; then 64298 # On Mac OS X Yosemite, the symlink from libfreetype.dylib to libfreetype.6.dylib disappeared. Check 64299 # for the .6 version explicitly. 64300 FREETYPE_BASE_NAME=freetype.6 64301 FREETYPE_LIB_NAME="${LIBRARY_PREFIX}${FREETYPE_BASE_NAME}${SHARED_LIBRARY_SUFFIX}" 64302 { $as_echo "$as_me:${as_lineno-$LINENO}: Compensating for missing symlink by using version 6 explicitly" >&5 64303 $as_echo "$as_me: Compensating for missing symlink by using version 6 explicitly" >&6;} 64304 else 64305 { $as_echo "$as_me:${as_lineno-$LINENO}: Could not find $POTENTIAL_FREETYPE_LIB_PATH/$FREETYPE_LIB_NAME. Ignoring location." >&5 64306 $as_echo "$as_me: Could not find $POTENTIAL_FREETYPE_LIB_PATH/$FREETYPE_LIB_NAME. Ignoring location." >&6;} 64307 FOUND_FREETYPE=no 64308 fi 64309 else 64310 if test "x$OPENJDK_TARGET_OS" = xwindows; then 64311 # On Windows, we will need both .lib and .dll file. 64312 if ! test -s "$POTENTIAL_FREETYPE_LIB_PATH/${FREETYPE_BASE_NAME}.lib"; then 64313 { $as_echo "$as_me:${as_lineno-$LINENO}: Could not find $POTENTIAL_FREETYPE_LIB_PATH/${FREETYPE_BASE_NAME}.lib. Ignoring location." >&5 64314 $as_echo "$as_me: Could not find $POTENTIAL_FREETYPE_LIB_PATH/${FREETYPE_BASE_NAME}.lib. Ignoring location." >&6;} 64315 FOUND_FREETYPE=no 64316 fi 64317 elif test "x$OPENJDK_TARGET_OS" = xsolaris \ 64318 && test -s "$POTENTIAL_FREETYPE_LIB_PATH$OPENJDK_TARGET_CPU_ISADIR/$FREETYPE_LIB_NAME"; then 64319 # Found lib in isa dir, use that instead. 64320 POTENTIAL_FREETYPE_LIB_PATH="$POTENTIAL_FREETYPE_LIB_PATH$OPENJDK_TARGET_CPU_ISADIR" 64321 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting to use $POTENTIAL_FREETYPE_LIB_PATH instead" >&5 64322 $as_echo "$as_me: Rewriting to use $POTENTIAL_FREETYPE_LIB_PATH instead" >&6;} 64323 fi 64324 fi 64325 fi 64326 64327 if test "x$FOUND_FREETYPE" = xyes; then 64328 64329 # Only process if variable expands to non-empty 64330 64331 if test "x$POTENTIAL_FREETYPE_INCLUDE_PATH" != x; then 64332 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 64333 64334 # Input might be given as Windows format, start by converting to 64335 # unix format. 64336 path="$POTENTIAL_FREETYPE_INCLUDE_PATH" 64337 new_path=`$CYGPATH -u "$path"` 64338 64339 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 64340 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 64341 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 64342 # "foo.exe" is OK but "foo" is an error. 64343 # 64344 # This test is therefore slightly more accurate than "test -f" to check for file precense. 64345 # It is also a way to make sure we got the proper file name for the real test later on. 64346 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 64347 if test "x$test_shortpath" = x; then 64348 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&5 64349 $as_echo "$as_me: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&6;} 64350 as_fn_error $? "Cannot locate the the path of POTENTIAL_FREETYPE_INCLUDE_PATH" "$LINENO" 5 64351 fi 64352 64353 # Call helper function which possibly converts this using DOS-style short mode. 64354 # If so, the updated path is stored in $new_path. 64355 64356 input_path="$new_path" 64357 # Check if we need to convert this using DOS-style short mode. If the path 64358 # contains just simple characters, use it. Otherwise (spaces, weird characters), 64359 # take no chances and rewrite it. 64360 # Note: m4 eats our [], so we need to use [ and ] instead. 64361 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 64362 if test "x$has_forbidden_chars" != x; then 64363 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 64364 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 64365 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 64366 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 64367 # Going to short mode and back again did indeed matter. Since short mode is 64368 # case insensitive, let's make it lowercase to improve readability. 64369 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 64370 # Now convert it back to Unix-style (cygpath) 64371 input_path=`$CYGPATH -u "$shortmode_path"` 64372 new_path="$input_path" 64373 fi 64374 fi 64375 64376 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 64377 if test "x$test_cygdrive_prefix" = x; then 64378 # As a simple fix, exclude /usr/bin since it's not a real path. 64379 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 64380 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 64381 # a path prefixed by /cygdrive for fixpath to work. 64382 new_path="$CYGWIN_ROOT_PATH$input_path" 64383 fi 64384 fi 64385 64386 64387 if test "x$path" != "x$new_path"; then 64388 POTENTIAL_FREETYPE_INCLUDE_PATH="$new_path" 64389 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&5 64390 $as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&6;} 64391 fi 64392 64393 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 64394 64395 path="$POTENTIAL_FREETYPE_INCLUDE_PATH" 64396 has_colon=`$ECHO $path | $GREP ^.:` 64397 new_path="$path" 64398 if test "x$has_colon" = x; then 64399 # Not in mixed or Windows style, start by that. 64400 new_path=`cmd //c echo $path` 64401 fi 64402 64403 64404 input_path="$new_path" 64405 # Check if we need to convert this using DOS-style short mode. If the path 64406 # contains just simple characters, use it. Otherwise (spaces, weird characters), 64407 # take no chances and rewrite it. 64408 # Note: m4 eats our [], so we need to use [ and ] instead. 64409 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 64410 if test "x$has_forbidden_chars" != x; then 64411 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 64412 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 64413 fi 64414 64415 64416 windows_path="$new_path" 64417 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 64418 unix_path=`$CYGPATH -u "$windows_path"` 64419 new_path="$unix_path" 64420 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 64421 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 64422 new_path="$unix_path" 64423 fi 64424 64425 if test "x$path" != "x$new_path"; then 64426 POTENTIAL_FREETYPE_INCLUDE_PATH="$new_path" 64427 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&5 64428 $as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&6;} 64429 fi 64430 64431 # Save the first 10 bytes of this path to the storage, so fixpath can work. 64432 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 64433 64434 else 64435 # We're on a unix platform. Hooray! :) 64436 path="$POTENTIAL_FREETYPE_INCLUDE_PATH" 64437 has_space=`$ECHO "$path" | $GREP " "` 64438 if test "x$has_space" != x; then 64439 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&5 64440 $as_echo "$as_me: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&6;} 64441 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 64442 fi 64443 64444 # Use eval to expand a potential ~ 64445 eval path="$path" 64446 if test ! -f "$path" && test ! -d "$path"; then 64447 as_fn_error $? "The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is not found." "$LINENO" 5 64448 fi 64449 64450 if test -d "$path"; then 64451 POTENTIAL_FREETYPE_INCLUDE_PATH="`cd "$path"; $THEPWDCMD -L`" 64452 else 64453 dir="`$DIRNAME "$path"`" 64454 base="`$BASENAME "$path"`" 64455 POTENTIAL_FREETYPE_INCLUDE_PATH="`cd "$dir"; $THEPWDCMD -L`/$base" 64456 fi 64457 fi 64458 fi 64459 64460 64461 # Only process if variable expands to non-empty 64462 64463 if test "x$POTENTIAL_FREETYPE_LIB_PATH" != x; then 64464 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 64465 64466 # Input might be given as Windows format, start by converting to 64467 # unix format. 64468 path="$POTENTIAL_FREETYPE_LIB_PATH" 64469 new_path=`$CYGPATH -u "$path"` 64470 64471 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 64472 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 64473 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 64474 # "foo.exe" is OK but "foo" is an error. 64475 # 64476 # This test is therefore slightly more accurate than "test -f" to check for file precense. 64477 # It is also a way to make sure we got the proper file name for the real test later on. 64478 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 64479 if test "x$test_shortpath" = x; then 64480 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&5 64481 $as_echo "$as_me: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&6;} 64482 as_fn_error $? "Cannot locate the the path of POTENTIAL_FREETYPE_LIB_PATH" "$LINENO" 5 64483 fi 64484 64485 # Call helper function which possibly converts this using DOS-style short mode. 64486 # If so, the updated path is stored in $new_path. 64487 64488 input_path="$new_path" 64489 # Check if we need to convert this using DOS-style short mode. If the path 64490 # contains just simple characters, use it. Otherwise (spaces, weird characters), 64491 # take no chances and rewrite it. 64492 # Note: m4 eats our [], so we need to use [ and ] instead. 64493 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 64494 if test "x$has_forbidden_chars" != x; then 64495 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 64496 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 64497 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 64498 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 64499 # Going to short mode and back again did indeed matter. Since short mode is 64500 # case insensitive, let's make it lowercase to improve readability. 64501 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 64502 # Now convert it back to Unix-style (cygpath) 64503 input_path=`$CYGPATH -u "$shortmode_path"` 64504 new_path="$input_path" 64505 fi 64506 fi 64507 64508 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 64509 if test "x$test_cygdrive_prefix" = x; then 64510 # As a simple fix, exclude /usr/bin since it's not a real path. 64511 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 64512 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 64513 # a path prefixed by /cygdrive for fixpath to work. 64514 new_path="$CYGWIN_ROOT_PATH$input_path" 64515 fi 64516 fi 64517 64518 64519 if test "x$path" != "x$new_path"; then 64520 POTENTIAL_FREETYPE_LIB_PATH="$new_path" 64521 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&5 64522 $as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&6;} 64523 fi 64524 64525 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 64526 64527 path="$POTENTIAL_FREETYPE_LIB_PATH" 64528 has_colon=`$ECHO $path | $GREP ^.:` 64529 new_path="$path" 64530 if test "x$has_colon" = x; then 64531 # Not in mixed or Windows style, start by that. 64532 new_path=`cmd //c echo $path` 64533 fi 64534 64535 64536 input_path="$new_path" 64537 # Check if we need to convert this using DOS-style short mode. If the path 64538 # contains just simple characters, use it. Otherwise (spaces, weird characters), 64539 # take no chances and rewrite it. 64540 # Note: m4 eats our [], so we need to use [ and ] instead. 64541 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 64542 if test "x$has_forbidden_chars" != x; then 64543 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 64544 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 64545 fi 64546 64547 64548 windows_path="$new_path" 64549 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 64550 unix_path=`$CYGPATH -u "$windows_path"` 64551 new_path="$unix_path" 64552 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 64553 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 64554 new_path="$unix_path" 64555 fi 64556 64557 if test "x$path" != "x$new_path"; then 64558 POTENTIAL_FREETYPE_LIB_PATH="$new_path" 64559 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&5 64560 $as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&6;} 64561 fi 64562 64563 # Save the first 10 bytes of this path to the storage, so fixpath can work. 64564 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 64565 64566 else 64567 # We're on a unix platform. Hooray! :) 64568 path="$POTENTIAL_FREETYPE_LIB_PATH" 64569 has_space=`$ECHO "$path" | $GREP " "` 64570 if test "x$has_space" != x; then 64571 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&5 64572 $as_echo "$as_me: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&6;} 64573 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 64574 fi 64575 64576 # Use eval to expand a potential ~ 64577 eval path="$path" 64578 if test ! -f "$path" && test ! -d "$path"; then 64579 as_fn_error $? "The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is not found." "$LINENO" 5 64580 fi 64581 64582 if test -d "$path"; then 64583 POTENTIAL_FREETYPE_LIB_PATH="`cd "$path"; $THEPWDCMD -L`" 64584 else 64585 dir="`$DIRNAME "$path"`" 64586 base="`$BASENAME "$path"`" 64587 POTENTIAL_FREETYPE_LIB_PATH="`cd "$dir"; $THEPWDCMD -L`/$base" 64588 fi 64589 fi 64590 fi 64591 64592 64593 FREETYPE_INCLUDE_PATH="$POTENTIAL_FREETYPE_INCLUDE_PATH" 64594 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for freetype includes" >&5 64595 $as_echo_n "checking for freetype includes... " >&6; } 64596 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $FREETYPE_INCLUDE_PATH" >&5 64597 $as_echo "$FREETYPE_INCLUDE_PATH" >&6; } 64598 FREETYPE_LIB_PATH="$POTENTIAL_FREETYPE_LIB_PATH" 64599 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for freetype libraries" >&5 64600 $as_echo_n "checking for freetype libraries... " >&6; } 64601 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $FREETYPE_LIB_PATH" >&5 64602 $as_echo "$FREETYPE_LIB_PATH" >&6; } 64603 fi 64604 64605 if test "x$FOUND_FREETYPE" != xyes; then 64606 64607 POTENTIAL_FREETYPE_INCLUDE_PATH="$FREETYPE_BASE_DIR/include" 64608 POTENTIAL_FREETYPE_LIB_PATH="$FREETYPE_BASE_DIR/lib32" 64609 METHOD="well-known location" 64610 64611 # Let's start with an optimistic view of the world :-) 64612 FOUND_FREETYPE=yes 64613 64614 # First look for the canonical freetype main include file ft2build.h. 64615 if ! test -s "$POTENTIAL_FREETYPE_INCLUDE_PATH/ft2build.h"; then 64616 # Oh no! Let's try in the freetype2 directory. This is needed at least at Mac OS X Yosemite. 64617 POTENTIAL_FREETYPE_INCLUDE_PATH="$POTENTIAL_FREETYPE_INCLUDE_PATH/freetype2" 64618 if ! test -s "$POTENTIAL_FREETYPE_INCLUDE_PATH/ft2build.h"; then 64619 # Fail. 64620 FOUND_FREETYPE=no 64621 fi 64622 fi 64623 64624 if test "x$FOUND_FREETYPE" = xyes; then 64625 # Include file found, let's continue the sanity check. 64626 { $as_echo "$as_me:${as_lineno-$LINENO}: Found freetype include files at $POTENTIAL_FREETYPE_INCLUDE_PATH using $METHOD" >&5 64627 $as_echo "$as_me: Found freetype include files at $POTENTIAL_FREETYPE_INCLUDE_PATH using $METHOD" >&6;} 64628 64629 # Reset to default value 64630 FREETYPE_BASE_NAME=freetype 64631 FREETYPE_LIB_NAME="${LIBRARY_PREFIX}${FREETYPE_BASE_NAME}${SHARED_LIBRARY_SUFFIX}" 64632 if ! test -s "$POTENTIAL_FREETYPE_LIB_PATH/$FREETYPE_LIB_NAME"; then 64633 if test "x$OPENJDK_TARGET_OS" = xmacosx \ 64634 && test -s "$POTENTIAL_FREETYPE_LIB_PATH/${LIBRARY_PREFIX}freetype.6${SHARED_LIBRARY_SUFFIX}"; then 64635 # On Mac OS X Yosemite, the symlink from libfreetype.dylib to libfreetype.6.dylib disappeared. Check 64636 # for the .6 version explicitly. 64637 FREETYPE_BASE_NAME=freetype.6 64638 FREETYPE_LIB_NAME="${LIBRARY_PREFIX}${FREETYPE_BASE_NAME}${SHARED_LIBRARY_SUFFIX}" 64639 { $as_echo "$as_me:${as_lineno-$LINENO}: Compensating for missing symlink by using version 6 explicitly" >&5 64640 $as_echo "$as_me: Compensating for missing symlink by using version 6 explicitly" >&6;} 64641 else 64642 { $as_echo "$as_me:${as_lineno-$LINENO}: Could not find $POTENTIAL_FREETYPE_LIB_PATH/$FREETYPE_LIB_NAME. Ignoring location." >&5 64643 $as_echo "$as_me: Could not find $POTENTIAL_FREETYPE_LIB_PATH/$FREETYPE_LIB_NAME. Ignoring location." >&6;} 64644 FOUND_FREETYPE=no 64645 fi 64646 else 64647 if test "x$OPENJDK_TARGET_OS" = xwindows; then 64648 # On Windows, we will need both .lib and .dll file. 64649 if ! test -s "$POTENTIAL_FREETYPE_LIB_PATH/${FREETYPE_BASE_NAME}.lib"; then 64650 { $as_echo "$as_me:${as_lineno-$LINENO}: Could not find $POTENTIAL_FREETYPE_LIB_PATH/${FREETYPE_BASE_NAME}.lib. Ignoring location." >&5 64651 $as_echo "$as_me: Could not find $POTENTIAL_FREETYPE_LIB_PATH/${FREETYPE_BASE_NAME}.lib. Ignoring location." >&6;} 64652 FOUND_FREETYPE=no 64653 fi 64654 elif test "x$OPENJDK_TARGET_OS" = xsolaris \ 64655 && test -s "$POTENTIAL_FREETYPE_LIB_PATH$OPENJDK_TARGET_CPU_ISADIR/$FREETYPE_LIB_NAME"; then 64656 # Found lib in isa dir, use that instead. 64657 POTENTIAL_FREETYPE_LIB_PATH="$POTENTIAL_FREETYPE_LIB_PATH$OPENJDK_TARGET_CPU_ISADIR" 64658 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting to use $POTENTIAL_FREETYPE_LIB_PATH instead" >&5 64659 $as_echo "$as_me: Rewriting to use $POTENTIAL_FREETYPE_LIB_PATH instead" >&6;} 64660 fi 64661 fi 64662 fi 64663 64664 if test "x$FOUND_FREETYPE" = xyes; then 64665 64666 # Only process if variable expands to non-empty 64667 64668 if test "x$POTENTIAL_FREETYPE_INCLUDE_PATH" != x; then 64669 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 64670 64671 # Input might be given as Windows format, start by converting to 64672 # unix format. 64673 path="$POTENTIAL_FREETYPE_INCLUDE_PATH" 64674 new_path=`$CYGPATH -u "$path"` 64675 64676 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 64677 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 64678 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 64679 # "foo.exe" is OK but "foo" is an error. 64680 # 64681 # This test is therefore slightly more accurate than "test -f" to check for file precense. 64682 # It is also a way to make sure we got the proper file name for the real test later on. 64683 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 64684 if test "x$test_shortpath" = x; then 64685 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&5 64686 $as_echo "$as_me: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&6;} 64687 as_fn_error $? "Cannot locate the the path of POTENTIAL_FREETYPE_INCLUDE_PATH" "$LINENO" 5 64688 fi 64689 64690 # Call helper function which possibly converts this using DOS-style short mode. 64691 # If so, the updated path is stored in $new_path. 64692 64693 input_path="$new_path" 64694 # Check if we need to convert this using DOS-style short mode. If the path 64695 # contains just simple characters, use it. Otherwise (spaces, weird characters), 64696 # take no chances and rewrite it. 64697 # Note: m4 eats our [], so we need to use [ and ] instead. 64698 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 64699 if test "x$has_forbidden_chars" != x; then 64700 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 64701 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 64702 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 64703 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 64704 # Going to short mode and back again did indeed matter. Since short mode is 64705 # case insensitive, let's make it lowercase to improve readability. 64706 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 64707 # Now convert it back to Unix-style (cygpath) 64708 input_path=`$CYGPATH -u "$shortmode_path"` 64709 new_path="$input_path" 64710 fi 64711 fi 64712 64713 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 64714 if test "x$test_cygdrive_prefix" = x; then 64715 # As a simple fix, exclude /usr/bin since it's not a real path. 64716 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 64717 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 64718 # a path prefixed by /cygdrive for fixpath to work. 64719 new_path="$CYGWIN_ROOT_PATH$input_path" 64720 fi 64721 fi 64722 64723 64724 if test "x$path" != "x$new_path"; then 64725 POTENTIAL_FREETYPE_INCLUDE_PATH="$new_path" 64726 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&5 64727 $as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&6;} 64728 fi 64729 64730 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 64731 64732 path="$POTENTIAL_FREETYPE_INCLUDE_PATH" 64733 has_colon=`$ECHO $path | $GREP ^.:` 64734 new_path="$path" 64735 if test "x$has_colon" = x; then 64736 # Not in mixed or Windows style, start by that. 64737 new_path=`cmd //c echo $path` 64738 fi 64739 64740 64741 input_path="$new_path" 64742 # Check if we need to convert this using DOS-style short mode. If the path 64743 # contains just simple characters, use it. Otherwise (spaces, weird characters), 64744 # take no chances and rewrite it. 64745 # Note: m4 eats our [], so we need to use [ and ] instead. 64746 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 64747 if test "x$has_forbidden_chars" != x; then 64748 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 64749 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 64750 fi 64751 64752 64753 windows_path="$new_path" 64754 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 64755 unix_path=`$CYGPATH -u "$windows_path"` 64756 new_path="$unix_path" 64757 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 64758 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 64759 new_path="$unix_path" 64760 fi 64761 64762 if test "x$path" != "x$new_path"; then 64763 POTENTIAL_FREETYPE_INCLUDE_PATH="$new_path" 64764 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&5 64765 $as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&6;} 64766 fi 64767 64768 # Save the first 10 bytes of this path to the storage, so fixpath can work. 64769 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 64770 64771 else 64772 # We're on a unix platform. Hooray! :) 64773 path="$POTENTIAL_FREETYPE_INCLUDE_PATH" 64774 has_space=`$ECHO "$path" | $GREP " "` 64775 if test "x$has_space" != x; then 64776 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&5 64777 $as_echo "$as_me: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&6;} 64778 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 64779 fi 64780 64781 # Use eval to expand a potential ~ 64782 eval path="$path" 64783 if test ! -f "$path" && test ! -d "$path"; then 64784 as_fn_error $? "The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is not found." "$LINENO" 5 64785 fi 64786 64787 if test -d "$path"; then 64788 POTENTIAL_FREETYPE_INCLUDE_PATH="`cd "$path"; $THEPWDCMD -L`" 64789 else 64790 dir="`$DIRNAME "$path"`" 64791 base="`$BASENAME "$path"`" 64792 POTENTIAL_FREETYPE_INCLUDE_PATH="`cd "$dir"; $THEPWDCMD -L`/$base" 64793 fi 64794 fi 64795 fi 64796 64797 64798 # Only process if variable expands to non-empty 64799 64800 if test "x$POTENTIAL_FREETYPE_LIB_PATH" != x; then 64801 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 64802 64803 # Input might be given as Windows format, start by converting to 64804 # unix format. 64805 path="$POTENTIAL_FREETYPE_LIB_PATH" 64806 new_path=`$CYGPATH -u "$path"` 64807 64808 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 64809 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 64810 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 64811 # "foo.exe" is OK but "foo" is an error. 64812 # 64813 # This test is therefore slightly more accurate than "test -f" to check for file precense. 64814 # It is also a way to make sure we got the proper file name for the real test later on. 64815 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 64816 if test "x$test_shortpath" = x; then 64817 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&5 64818 $as_echo "$as_me: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&6;} 64819 as_fn_error $? "Cannot locate the the path of POTENTIAL_FREETYPE_LIB_PATH" "$LINENO" 5 64820 fi 64821 64822 # Call helper function which possibly converts this using DOS-style short mode. 64823 # If so, the updated path is stored in $new_path. 64824 64825 input_path="$new_path" 64826 # Check if we need to convert this using DOS-style short mode. If the path 64827 # contains just simple characters, use it. Otherwise (spaces, weird characters), 64828 # take no chances and rewrite it. 64829 # Note: m4 eats our [], so we need to use [ and ] instead. 64830 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 64831 if test "x$has_forbidden_chars" != x; then 64832 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 64833 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 64834 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 64835 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 64836 # Going to short mode and back again did indeed matter. Since short mode is 64837 # case insensitive, let's make it lowercase to improve readability. 64838 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 64839 # Now convert it back to Unix-style (cygpath) 64840 input_path=`$CYGPATH -u "$shortmode_path"` 64841 new_path="$input_path" 64842 fi 64843 fi 64844 64845 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 64846 if test "x$test_cygdrive_prefix" = x; then 64847 # As a simple fix, exclude /usr/bin since it's not a real path. 64848 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 64849 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 64850 # a path prefixed by /cygdrive for fixpath to work. 64851 new_path="$CYGWIN_ROOT_PATH$input_path" 64852 fi 64853 fi 64854 64855 64856 if test "x$path" != "x$new_path"; then 64857 POTENTIAL_FREETYPE_LIB_PATH="$new_path" 64858 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&5 64859 $as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&6;} 64860 fi 64861 64862 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 64863 64864 path="$POTENTIAL_FREETYPE_LIB_PATH" 64865 has_colon=`$ECHO $path | $GREP ^.:` 64866 new_path="$path" 64867 if test "x$has_colon" = x; then 64868 # Not in mixed or Windows style, start by that. 64869 new_path=`cmd //c echo $path` 64870 fi 64871 64872 64873 input_path="$new_path" 64874 # Check if we need to convert this using DOS-style short mode. If the path 64875 # contains just simple characters, use it. Otherwise (spaces, weird characters), 64876 # take no chances and rewrite it. 64877 # Note: m4 eats our [], so we need to use [ and ] instead. 64878 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 64879 if test "x$has_forbidden_chars" != x; then 64880 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 64881 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 64882 fi 64883 64884 64885 windows_path="$new_path" 64886 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 64887 unix_path=`$CYGPATH -u "$windows_path"` 64888 new_path="$unix_path" 64889 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 64890 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 64891 new_path="$unix_path" 64892 fi 64893 64894 if test "x$path" != "x$new_path"; then 64895 POTENTIAL_FREETYPE_LIB_PATH="$new_path" 64896 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&5 64897 $as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&6;} 64898 fi 64899 64900 # Save the first 10 bytes of this path to the storage, so fixpath can work. 64901 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 64902 64903 else 64904 # We're on a unix platform. Hooray! :) 64905 path="$POTENTIAL_FREETYPE_LIB_PATH" 64906 has_space=`$ECHO "$path" | $GREP " "` 64907 if test "x$has_space" != x; then 64908 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&5 64909 $as_echo "$as_me: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&6;} 64910 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 64911 fi 64912 64913 # Use eval to expand a potential ~ 64914 eval path="$path" 64915 if test ! -f "$path" && test ! -d "$path"; then 64916 as_fn_error $? "The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is not found." "$LINENO" 5 64917 fi 64918 64919 if test -d "$path"; then 64920 POTENTIAL_FREETYPE_LIB_PATH="`cd "$path"; $THEPWDCMD -L`" 64921 else 64922 dir="`$DIRNAME "$path"`" 64923 base="`$BASENAME "$path"`" 64924 POTENTIAL_FREETYPE_LIB_PATH="`cd "$dir"; $THEPWDCMD -L`/$base" 64925 fi 64926 fi 64927 fi 64928 64929 64930 FREETYPE_INCLUDE_PATH="$POTENTIAL_FREETYPE_INCLUDE_PATH" 64931 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for freetype includes" >&5 64932 $as_echo_n "checking for freetype includes... " >&6; } 64933 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $FREETYPE_INCLUDE_PATH" >&5 64934 $as_echo "$FREETYPE_INCLUDE_PATH" >&6; } 64935 FREETYPE_LIB_PATH="$POTENTIAL_FREETYPE_LIB_PATH" 64936 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for freetype libraries" >&5 64937 $as_echo_n "checking for freetype libraries... " >&6; } 64938 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $FREETYPE_LIB_PATH" >&5 64939 $as_echo "$FREETYPE_LIB_PATH" >&6; } 64940 fi 64941 64942 fi 64943 fi 64944 fi 64945 fi 64946 fi # end check in well-known locations 64947 64948 if test "x$FOUND_FREETYPE" != xyes; then 64949 64950 # Print a helpful message on how to acquire the necessary build dependency. 64951 # freetype is the help tag: freetype, cups, alsa etc 64952 MISSING_DEPENDENCY=freetype 64953 64954 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 64955 cygwin_help $MISSING_DEPENDENCY 64956 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 64957 msys_help $MISSING_DEPENDENCY 64958 else 64959 PKGHANDLER_COMMAND= 64960 64961 case $PKGHANDLER in 64962 apt-get) 64963 apt_help $MISSING_DEPENDENCY ;; 64964 yum) 64965 yum_help $MISSING_DEPENDENCY ;; 64966 brew) 64967 brew_help $MISSING_DEPENDENCY ;; 64968 port) 64969 port_help $MISSING_DEPENDENCY ;; 64970 pkgutil) 64971 pkgutil_help $MISSING_DEPENDENCY ;; 64972 pkgadd) 64973 pkgadd_help $MISSING_DEPENDENCY ;; 64974 esac 64975 64976 if test "x$PKGHANDLER_COMMAND" != x; then 64977 HELP_MSG="You might be able to fix this by running '$PKGHANDLER_COMMAND'." 64978 fi 64979 fi 64980 64981 as_fn_error $? "Could not find freetype! $HELP_MSG " "$LINENO" 5 64982 fi 64983 fi # end user specified settings 64984 64985 # Set FREETYPE_CFLAGS, _LIBS and _LIB_PATH from include and lib dir. 64986 if test "x$FREETYPE_CFLAGS" = x; then 64987 64988 # Only process if variable expands to non-empty 64989 64990 if test "x$FREETYPE_INCLUDE_PATH" != x; then 64991 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 64992 64993 # Input might be given as Windows format, start by converting to 64994 # unix format. 64995 path="$FREETYPE_INCLUDE_PATH" 64996 new_path=`$CYGPATH -u "$path"` 64997 64998 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 64999 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 65000 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 65001 # "foo.exe" is OK but "foo" is an error. 65002 # 65003 # This test is therefore slightly more accurate than "test -f" to check for file precense. 65004 # It is also a way to make sure we got the proper file name for the real test later on. 65005 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 65006 if test "x$test_shortpath" = x; then 65007 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&5 65008 $as_echo "$as_me: The path of FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&6;} 65009 as_fn_error $? "Cannot locate the the path of FREETYPE_INCLUDE_PATH" "$LINENO" 5 65010 fi 65011 65012 # Call helper function which possibly converts this using DOS-style short mode. 65013 # If so, the updated path is stored in $new_path. 65014 65015 input_path="$new_path" 65016 # Check if we need to convert this using DOS-style short mode. If the path 65017 # contains just simple characters, use it. Otherwise (spaces, weird characters), 65018 # take no chances and rewrite it. 65019 # Note: m4 eats our [], so we need to use [ and ] instead. 65020 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 65021 if test "x$has_forbidden_chars" != x; then 65022 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 65023 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 65024 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 65025 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 65026 # Going to short mode and back again did indeed matter. Since short mode is 65027 # case insensitive, let's make it lowercase to improve readability. 65028 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 65029 # Now convert it back to Unix-style (cygpath) 65030 input_path=`$CYGPATH -u "$shortmode_path"` 65031 new_path="$input_path" 65032 fi 65033 fi 65034 65035 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 65036 if test "x$test_cygdrive_prefix" = x; then 65037 # As a simple fix, exclude /usr/bin since it's not a real path. 65038 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 65039 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 65040 # a path prefixed by /cygdrive for fixpath to work. 65041 new_path="$CYGWIN_ROOT_PATH$input_path" 65042 fi 65043 fi 65044 65045 65046 if test "x$path" != "x$new_path"; then 65047 FREETYPE_INCLUDE_PATH="$new_path" 65048 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting FREETYPE_INCLUDE_PATH to \"$new_path\"" >&5 65049 $as_echo "$as_me: Rewriting FREETYPE_INCLUDE_PATH to \"$new_path\"" >&6;} 65050 fi 65051 65052 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 65053 65054 path="$FREETYPE_INCLUDE_PATH" 65055 has_colon=`$ECHO $path | $GREP ^.:` 65056 new_path="$path" 65057 if test "x$has_colon" = x; then 65058 # Not in mixed or Windows style, start by that. 65059 new_path=`cmd //c echo $path` 65060 fi 65061 65062 65063 input_path="$new_path" 65064 # Check if we need to convert this using DOS-style short mode. If the path 65065 # contains just simple characters, use it. Otherwise (spaces, weird characters), 65066 # take no chances and rewrite it. 65067 # Note: m4 eats our [], so we need to use [ and ] instead. 65068 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 65069 if test "x$has_forbidden_chars" != x; then 65070 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 65071 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 65072 fi 65073 65074 65075 windows_path="$new_path" 65076 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 65077 unix_path=`$CYGPATH -u "$windows_path"` 65078 new_path="$unix_path" 65079 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 65080 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 65081 new_path="$unix_path" 65082 fi 65083 65084 if test "x$path" != "x$new_path"; then 65085 FREETYPE_INCLUDE_PATH="$new_path" 65086 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting FREETYPE_INCLUDE_PATH to \"$new_path\"" >&5 65087 $as_echo "$as_me: Rewriting FREETYPE_INCLUDE_PATH to \"$new_path\"" >&6;} 65088 fi 65089 65090 # Save the first 10 bytes of this path to the storage, so fixpath can work. 65091 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 65092 65093 else 65094 # We're on a unix platform. Hooray! :) 65095 path="$FREETYPE_INCLUDE_PATH" 65096 has_space=`$ECHO "$path" | $GREP " "` 65097 if test "x$has_space" != x; then 65098 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&5 65099 $as_echo "$as_me: The path of FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&6;} 65100 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 65101 fi 65102 65103 # Use eval to expand a potential ~ 65104 eval path="$path" 65105 if test ! -f "$path" && test ! -d "$path"; then 65106 as_fn_error $? "The path of FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is not found." "$LINENO" 5 65107 fi 65108 65109 if test -d "$path"; then 65110 FREETYPE_INCLUDE_PATH="`cd "$path"; $THEPWDCMD -L`" 65111 else 65112 dir="`$DIRNAME "$path"`" 65113 base="`$BASENAME "$path"`" 65114 FREETYPE_INCLUDE_PATH="`cd "$dir"; $THEPWDCMD -L`/$base" 65115 fi 65116 fi 65117 fi 65118 65119 if test -d $FREETYPE_INCLUDE_PATH/freetype2/freetype; then 65120 FREETYPE_CFLAGS="-I$FREETYPE_INCLUDE_PATH/freetype2 -I$FREETYPE_INCLUDE_PATH" 65121 else 65122 FREETYPE_CFLAGS="-I$FREETYPE_INCLUDE_PATH" 65123 fi 65124 fi 65125 65126 if test "x$FREETYPE_LIBS" = x; then 65127 65128 # Only process if variable expands to non-empty 65129 65130 if test "x$FREETYPE_LIB_PATH" != x; then 65131 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 65132 65133 # Input might be given as Windows format, start by converting to 65134 # unix format. 65135 path="$FREETYPE_LIB_PATH" 65136 new_path=`$CYGPATH -u "$path"` 65137 65138 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 65139 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 65140 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 65141 # "foo.exe" is OK but "foo" is an error. 65142 # 65143 # This test is therefore slightly more accurate than "test -f" to check for file precense. 65144 # It is also a way to make sure we got the proper file name for the real test later on. 65145 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 65146 if test "x$test_shortpath" = x; then 65147 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&5 65148 $as_echo "$as_me: The path of FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&6;} 65149 as_fn_error $? "Cannot locate the the path of FREETYPE_LIB_PATH" "$LINENO" 5 65150 fi 65151 65152 # Call helper function which possibly converts this using DOS-style short mode. 65153 # If so, the updated path is stored in $new_path. 65154 65155 input_path="$new_path" 65156 # Check if we need to convert this using DOS-style short mode. If the path 65157 # contains just simple characters, use it. Otherwise (spaces, weird characters), 65158 # take no chances and rewrite it. 65159 # Note: m4 eats our [], so we need to use [ and ] instead. 65160 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 65161 if test "x$has_forbidden_chars" != x; then 65162 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 65163 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 65164 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 65165 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 65166 # Going to short mode and back again did indeed matter. Since short mode is 65167 # case insensitive, let's make it lowercase to improve readability. 65168 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 65169 # Now convert it back to Unix-style (cygpath) 65170 input_path=`$CYGPATH -u "$shortmode_path"` 65171 new_path="$input_path" 65172 fi 65173 fi 65174 65175 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 65176 if test "x$test_cygdrive_prefix" = x; then 65177 # As a simple fix, exclude /usr/bin since it's not a real path. 65178 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 65179 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 65180 # a path prefixed by /cygdrive for fixpath to work. 65181 new_path="$CYGWIN_ROOT_PATH$input_path" 65182 fi 65183 fi 65184 65185 65186 if test "x$path" != "x$new_path"; then 65187 FREETYPE_LIB_PATH="$new_path" 65188 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting FREETYPE_LIB_PATH to \"$new_path\"" >&5 65189 $as_echo "$as_me: Rewriting FREETYPE_LIB_PATH to \"$new_path\"" >&6;} 65190 fi 65191 65192 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 65193 65194 path="$FREETYPE_LIB_PATH" 65195 has_colon=`$ECHO $path | $GREP ^.:` 65196 new_path="$path" 65197 if test "x$has_colon" = x; then 65198 # Not in mixed or Windows style, start by that. 65199 new_path=`cmd //c echo $path` 65200 fi 65201 65202 65203 input_path="$new_path" 65204 # Check if we need to convert this using DOS-style short mode. If the path 65205 # contains just simple characters, use it. Otherwise (spaces, weird characters), 65206 # take no chances and rewrite it. 65207 # Note: m4 eats our [], so we need to use [ and ] instead. 65208 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 65209 if test "x$has_forbidden_chars" != x; then 65210 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 65211 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 65212 fi 65213 65214 65215 windows_path="$new_path" 65216 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 65217 unix_path=`$CYGPATH -u "$windows_path"` 65218 new_path="$unix_path" 65219 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 65220 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 65221 new_path="$unix_path" 65222 fi 65223 65224 if test "x$path" != "x$new_path"; then 65225 FREETYPE_LIB_PATH="$new_path" 65226 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting FREETYPE_LIB_PATH to \"$new_path\"" >&5 65227 $as_echo "$as_me: Rewriting FREETYPE_LIB_PATH to \"$new_path\"" >&6;} 65228 fi 65229 65230 # Save the first 10 bytes of this path to the storage, so fixpath can work. 65231 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 65232 65233 else 65234 # We're on a unix platform. Hooray! :) 65235 path="$FREETYPE_LIB_PATH" 65236 has_space=`$ECHO "$path" | $GREP " "` 65237 if test "x$has_space" != x; then 65238 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&5 65239 $as_echo "$as_me: The path of FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&6;} 65240 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 65241 fi 65242 65243 # Use eval to expand a potential ~ 65244 eval path="$path" 65245 if test ! -f "$path" && test ! -d "$path"; then 65246 as_fn_error $? "The path of FREETYPE_LIB_PATH, which resolves as \"$path\", is not found." "$LINENO" 5 65247 fi 65248 65249 if test -d "$path"; then 65250 FREETYPE_LIB_PATH="`cd "$path"; $THEPWDCMD -L`" 65251 else 65252 dir="`$DIRNAME "$path"`" 65253 base="`$BASENAME "$path"`" 65254 FREETYPE_LIB_PATH="`cd "$dir"; $THEPWDCMD -L`/$base" 65255 fi 65256 fi 65257 fi 65258 65259 if test "x$OPENJDK_TARGET_OS" = xwindows; then 65260 FREETYPE_LIBS="$FREETYPE_LIB_PATH/$FREETYPE_BASE_NAME.lib" 65261 else 65262 FREETYPE_LIBS="-L$FREETYPE_LIB_PATH -l$FREETYPE_BASE_NAME" 65263 fi 65264 fi 65265 65266 # Try to compile it 65267 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if we can compile and link with freetype" >&5 65268 $as_echo_n "checking if we can compile and link with freetype... " >&6; } 65269 ac_ext=cpp 65270 ac_cpp='$CXXCPP $CPPFLAGS' 65271 ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5' 65272 ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' 65273 ac_compiler_gnu=$ac_cv_cxx_compiler_gnu 65274 65275 PREV_CXXCFLAGS="$CXXFLAGS" 65276 PREV_LIBS="$LIBS" 65277 PREV_CXX="$CXX" 65278 CXXFLAGS="$CXXFLAGS $FREETYPE_CFLAGS" 65279 LIBS="$LIBS $FREETYPE_LIBS" 65280 CXX="$FIXPATH $CXX" 65281 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 65282 /* end confdefs.h. */ 65283 65284 #include<ft2build.h> 65285 #include FT_FREETYPE_H 65286 int main () { 65287 FT_Init_FreeType(NULL); 65288 return 0; 65289 } 65290 65291 _ACEOF 65292 if ac_fn_cxx_try_link "$LINENO"; then : 65293 65294 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 65295 $as_echo "yes" >&6; } 65296 65297 else 65298 65299 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 65300 $as_echo "no" >&6; } 65301 { $as_echo "$as_me:${as_lineno-$LINENO}: Could not compile and link with freetype. This might be a 32/64-bit mismatch." >&5 65302 $as_echo "$as_me: Could not compile and link with freetype. This might be a 32/64-bit mismatch." >&6;} 65303 { $as_echo "$as_me:${as_lineno-$LINENO}: Using FREETYPE_CFLAGS=$FREETYPE_CFLAGS and FREETYPE_LIBS=$FREETYPE_LIBS" >&5 65304 $as_echo "$as_me: Using FREETYPE_CFLAGS=$FREETYPE_CFLAGS and FREETYPE_LIBS=$FREETYPE_LIBS" >&6;} 65305 65306 65307 # Print a helpful message on how to acquire the necessary build dependency. 65308 # freetype is the help tag: freetype, cups, alsa etc 65309 MISSING_DEPENDENCY=freetype 65310 65311 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 65312 cygwin_help $MISSING_DEPENDENCY 65313 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 65314 msys_help $MISSING_DEPENDENCY 65315 else 65316 PKGHANDLER_COMMAND= 65317 65318 case $PKGHANDLER in 65319 apt-get) 65320 apt_help $MISSING_DEPENDENCY ;; 65321 yum) 65322 yum_help $MISSING_DEPENDENCY ;; 65323 brew) 65324 brew_help $MISSING_DEPENDENCY ;; 65325 port) 65326 port_help $MISSING_DEPENDENCY ;; 65327 pkgutil) 65328 pkgutil_help $MISSING_DEPENDENCY ;; 65329 pkgadd) 65330 pkgadd_help $MISSING_DEPENDENCY ;; 65331 esac 65332 65333 if test "x$PKGHANDLER_COMMAND" != x; then 65334 HELP_MSG="You might be able to fix this by running '$PKGHANDLER_COMMAND'." 65335 fi 65336 fi 65337 65338 65339 as_fn_error $? "Can not continue without freetype. $HELP_MSG" "$LINENO" 5 65340 65341 65342 fi 65343 rm -f core conftest.err conftest.$ac_objext \ 65344 conftest$ac_exeext conftest.$ac_ext 65345 CXXCFLAGS="$PREV_CXXFLAGS" 65346 LIBS="$PREV_LIBS" 65347 CXX="$PREV_CXX" 65348 ac_ext=cpp 65349 ac_cpp='$CXXCPP $CPPFLAGS' 65350 ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5' 65351 ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' 65352 ac_compiler_gnu=$ac_cv_cxx_compiler_gnu 65353 65354 65355 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if we should bundle freetype" >&5 65356 $as_echo_n "checking if we should bundle freetype... " >&6; } 65357 if test "x$BUNDLE_FREETYPE" = xyes; then 65358 FREETYPE_BUNDLE_LIB_PATH="$FREETYPE_LIB_PATH" 65359 fi 65360 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BUNDLE_FREETYPE" >&5 65361 $as_echo "$BUNDLE_FREETYPE" >&6; } 65362 65363 if test "x$BUNDLE_FREETYPE" = xyes; then 65364 FREETYPE_LICENSE="" 65365 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for freetype license" >&5 65366 $as_echo_n "checking for freetype license... " >&6; } 65367 if test "x$with_freetype_license" = "xyes"; then 65368 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 65369 $as_echo "no" >&6; } 65370 as_fn_error $? "--with-freetype-license must have a value" "$LINENO" 5 65371 elif test "x$with_freetype_license" != "x"; then 65372 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $with_freetype_license" >&5 65373 $as_echo "$with_freetype_license" >&6; } 65374 FREETYPE_LICENSE="$with_freetype_license" 65375 65376 # Only process if variable expands to non-empty 65377 65378 if test "x$FREETYPE_LICENSE" != x; then 65379 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 65380 65381 # Input might be given as Windows format, start by converting to 65382 # unix format. 65383 path="$FREETYPE_LICENSE" 65384 new_path=`$CYGPATH -u "$path"` 65385 65386 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 65387 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 65388 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 65389 # "foo.exe" is OK but "foo" is an error. 65390 # 65391 # This test is therefore slightly more accurate than "test -f" to check for file precense. 65392 # It is also a way to make sure we got the proper file name for the real test later on. 65393 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 65394 if test "x$test_shortpath" = x; then 65395 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of FREETYPE_LICENSE, which resolves as \"$path\", is invalid." >&5 65396 $as_echo "$as_me: The path of FREETYPE_LICENSE, which resolves as \"$path\", is invalid." >&6;} 65397 as_fn_error $? "Cannot locate the the path of FREETYPE_LICENSE" "$LINENO" 5 65398 fi 65399 65400 # Call helper function which possibly converts this using DOS-style short mode. 65401 # If so, the updated path is stored in $new_path. 65402 65403 input_path="$new_path" 65404 # Check if we need to convert this using DOS-style short mode. If the path 65405 # contains just simple characters, use it. Otherwise (spaces, weird characters), 65406 # take no chances and rewrite it. 65407 # Note: m4 eats our [], so we need to use [ and ] instead. 65408 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 65409 if test "x$has_forbidden_chars" != x; then 65410 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 65411 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 65412 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 65413 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 65414 # Going to short mode and back again did indeed matter. Since short mode is 65415 # case insensitive, let's make it lowercase to improve readability. 65416 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 65417 # Now convert it back to Unix-style (cygpath) 65418 input_path=`$CYGPATH -u "$shortmode_path"` 65419 new_path="$input_path" 65420 fi 65421 fi 65422 65423 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 65424 if test "x$test_cygdrive_prefix" = x; then 65425 # As a simple fix, exclude /usr/bin since it's not a real path. 65426 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 65427 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 65428 # a path prefixed by /cygdrive for fixpath to work. 65429 new_path="$CYGWIN_ROOT_PATH$input_path" 65430 fi 65431 fi 65432 65433 65434 if test "x$path" != "x$new_path"; then 65435 FREETYPE_LICENSE="$new_path" 65436 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting FREETYPE_LICENSE to \"$new_path\"" >&5 65437 $as_echo "$as_me: Rewriting FREETYPE_LICENSE to \"$new_path\"" >&6;} 65438 fi 65439 65440 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 65441 65442 path="$FREETYPE_LICENSE" 65443 has_colon=`$ECHO $path | $GREP ^.:` 65444 new_path="$path" 65445 if test "x$has_colon" = x; then 65446 # Not in mixed or Windows style, start by that. 65447 new_path=`cmd //c echo $path` 65448 fi 65449 65450 65451 input_path="$new_path" 65452 # Check if we need to convert this using DOS-style short mode. If the path 65453 # contains just simple characters, use it. Otherwise (spaces, weird characters), 65454 # take no chances and rewrite it. 65455 # Note: m4 eats our [], so we need to use [ and ] instead. 65456 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 65457 if test "x$has_forbidden_chars" != x; then 65458 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 65459 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 65460 fi 65461 65462 65463 windows_path="$new_path" 65464 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 65465 unix_path=`$CYGPATH -u "$windows_path"` 65466 new_path="$unix_path" 65467 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 65468 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 65469 new_path="$unix_path" 65470 fi 65471 65472 if test "x$path" != "x$new_path"; then 65473 FREETYPE_LICENSE="$new_path" 65474 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting FREETYPE_LICENSE to \"$new_path\"" >&5 65475 $as_echo "$as_me: Rewriting FREETYPE_LICENSE to \"$new_path\"" >&6;} 65476 fi 65477 65478 # Save the first 10 bytes of this path to the storage, so fixpath can work. 65479 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 65480 65481 else 65482 # We're on a unix platform. Hooray! :) 65483 path="$FREETYPE_LICENSE" 65484 has_space=`$ECHO "$path" | $GREP " "` 65485 if test "x$has_space" != x; then 65486 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of FREETYPE_LICENSE, which resolves as \"$path\", is invalid." >&5 65487 $as_echo "$as_me: The path of FREETYPE_LICENSE, which resolves as \"$path\", is invalid." >&6;} 65488 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 65489 fi 65490 65491 # Use eval to expand a potential ~ 65492 eval path="$path" 65493 if test ! -f "$path" && test ! -d "$path"; then 65494 as_fn_error $? "The path of FREETYPE_LICENSE, which resolves as \"$path\", is not found." "$LINENO" 5 65495 fi 65496 65497 if test -d "$path"; then 65498 FREETYPE_LICENSE="`cd "$path"; $THEPWDCMD -L`" 65499 else 65500 dir="`$DIRNAME "$path"`" 65501 base="`$BASENAME "$path"`" 65502 FREETYPE_LICENSE="`cd "$dir"; $THEPWDCMD -L`/$base" 65503 fi 65504 fi 65505 fi 65506 65507 if test ! -f "$FREETYPE_LICENSE"; then 65508 as_fn_error $? "$FREETYPE_LICENSE cannot be found" "$LINENO" 5 65509 fi 65510 else 65511 if test "x$with_freetype" != "x" && test -f $with_freetype/freetype.md; then 65512 FREETYPE_LICENSE="$with_freetype/freetype.md" 65513 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $FREETYPE_LICENSE" >&5 65514 $as_echo "$FREETYPE_LICENSE" >&6; } 65515 65516 # Only process if variable expands to non-empty 65517 65518 if test "x$FREETYPE_LICENSE" != x; then 65519 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 65520 65521 # Input might be given as Windows format, start by converting to 65522 # unix format. 65523 path="$FREETYPE_LICENSE" 65524 new_path=`$CYGPATH -u "$path"` 65525 65526 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 65527 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 65528 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 65529 # "foo.exe" is OK but "foo" is an error. 65530 # 65531 # This test is therefore slightly more accurate than "test -f" to check for file precense. 65532 # It is also a way to make sure we got the proper file name for the real test later on. 65533 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 65534 if test "x$test_shortpath" = x; then 65535 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of FREETYPE_LICENSE, which resolves as \"$path\", is invalid." >&5 65536 $as_echo "$as_me: The path of FREETYPE_LICENSE, which resolves as \"$path\", is invalid." >&6;} 65537 as_fn_error $? "Cannot locate the the path of FREETYPE_LICENSE" "$LINENO" 5 65538 fi 65539 65540 # Call helper function which possibly converts this using DOS-style short mode. 65541 # If so, the updated path is stored in $new_path. 65542 65543 input_path="$new_path" 65544 # Check if we need to convert this using DOS-style short mode. If the path 65545 # contains just simple characters, use it. Otherwise (spaces, weird characters), 65546 # take no chances and rewrite it. 65547 # Note: m4 eats our [], so we need to use [ and ] instead. 65548 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 65549 if test "x$has_forbidden_chars" != x; then 65550 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 65551 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 65552 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 65553 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 65554 # Going to short mode and back again did indeed matter. Since short mode is 65555 # case insensitive, let's make it lowercase to improve readability. 65556 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 65557 # Now convert it back to Unix-style (cygpath) 65558 input_path=`$CYGPATH -u "$shortmode_path"` 65559 new_path="$input_path" 65560 fi 65561 fi 65562 65563 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 65564 if test "x$test_cygdrive_prefix" = x; then 65565 # As a simple fix, exclude /usr/bin since it's not a real path. 65566 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 65567 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 65568 # a path prefixed by /cygdrive for fixpath to work. 65569 new_path="$CYGWIN_ROOT_PATH$input_path" 65570 fi 65571 fi 65572 65573 65574 if test "x$path" != "x$new_path"; then 65575 FREETYPE_LICENSE="$new_path" 65576 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting FREETYPE_LICENSE to \"$new_path\"" >&5 65577 $as_echo "$as_me: Rewriting FREETYPE_LICENSE to \"$new_path\"" >&6;} 65578 fi 65579 65580 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 65581 65582 path="$FREETYPE_LICENSE" 65583 has_colon=`$ECHO $path | $GREP ^.:` 65584 new_path="$path" 65585 if test "x$has_colon" = x; then 65586 # Not in mixed or Windows style, start by that. 65587 new_path=`cmd //c echo $path` 65588 fi 65589 65590 65591 input_path="$new_path" 65592 # Check if we need to convert this using DOS-style short mode. If the path 65593 # contains just simple characters, use it. Otherwise (spaces, weird characters), 65594 # take no chances and rewrite it. 65595 # Note: m4 eats our [], so we need to use [ and ] instead. 65596 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 65597 if test "x$has_forbidden_chars" != x; then 65598 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 65599 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 65600 fi 65601 65602 65603 windows_path="$new_path" 65604 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 65605 unix_path=`$CYGPATH -u "$windows_path"` 65606 new_path="$unix_path" 65607 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 65608 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 65609 new_path="$unix_path" 65610 fi 65611 65612 if test "x$path" != "x$new_path"; then 65613 FREETYPE_LICENSE="$new_path" 65614 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting FREETYPE_LICENSE to \"$new_path\"" >&5 65615 $as_echo "$as_me: Rewriting FREETYPE_LICENSE to \"$new_path\"" >&6;} 65616 fi 65617 65618 # Save the first 10 bytes of this path to the storage, so fixpath can work. 65619 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 65620 65621 else 65622 # We're on a unix platform. Hooray! :) 65623 path="$FREETYPE_LICENSE" 65624 has_space=`$ECHO "$path" | $GREP " "` 65625 if test "x$has_space" != x; then 65626 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of FREETYPE_LICENSE, which resolves as \"$path\", is invalid." >&5 65627 $as_echo "$as_me: The path of FREETYPE_LICENSE, which resolves as \"$path\", is invalid." >&6;} 65628 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 65629 fi 65630 65631 # Use eval to expand a potential ~ 65632 eval path="$path" 65633 if test ! -f "$path" && test ! -d "$path"; then 65634 as_fn_error $? "The path of FREETYPE_LICENSE, which resolves as \"$path\", is not found." "$LINENO" 5 65635 fi 65636 65637 if test -d "$path"; then 65638 FREETYPE_LICENSE="`cd "$path"; $THEPWDCMD -L`" 65639 else 65640 dir="`$DIRNAME "$path"`" 65641 base="`$BASENAME "$path"`" 65642 FREETYPE_LICENSE="`cd "$dir"; $THEPWDCMD -L`/$base" 65643 fi 65644 fi 65645 fi 65646 65647 else 65648 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 65649 $as_echo "no" >&6; } 65650 fi 65651 fi 65652 fi 65653 65654 fi # end freetype needed 65655 65656 65657 65658 65659 65660 65661 65662 65663 # Check whether --with-alsa was given. 65664 if test "${with_alsa+set}" = set; then : 65665 withval=$with_alsa; 65666 fi 65667 65668 65669 # Check whether --with-alsa-include was given. 65670 if test "${with_alsa_include+set}" = set; then : 65671 withval=$with_alsa_include; 65672 fi 65673 65674 65675 # Check whether --with-alsa-lib was given. 65676 if test "${with_alsa_lib+set}" = set; then : 65677 withval=$with_alsa_lib; 65678 fi 65679 65680 65681 if test "x$NEEDS_LIB_ALSA" = xfalse; then 65682 if (test "x${with_alsa}" != x && test "x${with_alsa}" != xno) || \ 65683 (test "x${with_alsa_include}" != x && test "x${with_alsa_include}" != xno) || \ 65684 (test "x${with_alsa_lib}" != x && test "x${with_alsa_lib}" != xno); then 65685 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: alsa not used, so --with-alsa[-*] is ignored" >&5 65686 $as_echo "$as_me: WARNING: alsa not used, so --with-alsa[-*] is ignored" >&2;} 65687 fi 65688 ALSA_CFLAGS= 65689 ALSA_LIBS= 65690 else 65691 ALSA_FOUND=no 65692 65693 if test "x${with_alsa}" = xno || test "x${with_alsa_include}" = xno || test "x${with_alsa_lib}" = xno; then 65694 as_fn_error $? "It is not possible to disable the use of alsa. Remove the --without-alsa option." "$LINENO" 5 65695 fi 65696 65697 if test "x${with_alsa}" != x; then 65698 ALSA_LIBS="-L${with_alsa}/lib -lasound" 65699 ALSA_CFLAGS="-I${with_alsa}/include" 65700 ALSA_FOUND=yes 65701 fi 65702 if test "x${with_alsa_include}" != x; then 65703 ALSA_CFLAGS="-I${with_alsa_include}" 65704 ALSA_FOUND=yes 65705 fi 65706 if test "x${with_alsa_lib}" != x; then 65707 ALSA_LIBS="-L${with_alsa_lib} -lasound" 65708 ALSA_FOUND=yes 65709 fi 65710 # Do not try pkg-config if we have a sysroot set. 65711 if test "x$SYSROOT" = x; then 65712 if test "x$ALSA_FOUND" = xno; then 65713 65714 pkg_failed=no 65715 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ALSA" >&5 65716 $as_echo_n "checking for ALSA... " >&6; } 65717 65718 if test -n "$ALSA_CFLAGS"; then 65719 pkg_cv_ALSA_CFLAGS="$ALSA_CFLAGS" 65720 elif test -n "$PKG_CONFIG"; then 65721 if test -n "$PKG_CONFIG" && \ 65722 { { $as_echo "$as_me:${as_lineno-$LINENO}: \$PKG_CONFIG --exists --print-errors \"alsa\""; } >&5 65723 ($PKG_CONFIG --exists --print-errors "alsa") 2>&5 65724 ac_status=$? 65725 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 65726 test $ac_status = 0; }; then 65727 pkg_cv_ALSA_CFLAGS=`$PKG_CONFIG --cflags "alsa" 2>/dev/null` 65728 else 65729 pkg_failed=yes 65730 fi 65731 else 65732 pkg_failed=untried 65733 fi 65734 if test -n "$ALSA_LIBS"; then 65735 pkg_cv_ALSA_LIBS="$ALSA_LIBS" 65736 elif test -n "$PKG_CONFIG"; then 65737 if test -n "$PKG_CONFIG" && \ 65738 { { $as_echo "$as_me:${as_lineno-$LINENO}: \$PKG_CONFIG --exists --print-errors \"alsa\""; } >&5 65739 ($PKG_CONFIG --exists --print-errors "alsa") 2>&5 65740 ac_status=$? 65741 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 65742 test $ac_status = 0; }; then 65743 pkg_cv_ALSA_LIBS=`$PKG_CONFIG --libs "alsa" 2>/dev/null` 65744 else 65745 pkg_failed=yes 65746 fi 65747 else 65748 pkg_failed=untried 65749 fi 65750 65751 65752 65753 if test $pkg_failed = yes; then 65754 65755 if $PKG_CONFIG --atleast-pkgconfig-version 0.20; then 65756 _pkg_short_errors_supported=yes 65757 else 65758 _pkg_short_errors_supported=no 65759 fi 65760 if test $_pkg_short_errors_supported = yes; then 65761 ALSA_PKG_ERRORS=`$PKG_CONFIG --short-errors --print-errors "alsa" 2>&1` 65762 else 65763 ALSA_PKG_ERRORS=`$PKG_CONFIG --print-errors "alsa" 2>&1` 65764 fi 65765 # Put the nasty error message in config.log where it belongs 65766 echo "$ALSA_PKG_ERRORS" >&5 65767 65768 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 65769 $as_echo "no" >&6; } 65770 ALSA_FOUND=no 65771 elif test $pkg_failed = untried; then 65772 ALSA_FOUND=no 65773 else 65774 ALSA_CFLAGS=$pkg_cv_ALSA_CFLAGS 65775 ALSA_LIBS=$pkg_cv_ALSA_LIBS 65776 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 65777 $as_echo "yes" >&6; } 65778 ALSA_FOUND=yes 65779 fi 65780 fi 65781 fi 65782 if test "x$ALSA_FOUND" = xno; then 65783 for ac_header in alsa/asoundlib.h 65784 do : 65785 ac_fn_cxx_check_header_mongrel "$LINENO" "alsa/asoundlib.h" "ac_cv_header_alsa_asoundlib_h" "$ac_includes_default" 65786 if test "x$ac_cv_header_alsa_asoundlib_h" = xyes; then : 65787 cat >>confdefs.h <<_ACEOF 65788 #define HAVE_ALSA_ASOUNDLIB_H 1 65789 _ACEOF 65790 65791 ALSA_FOUND=yes 65792 ALSA_CFLAGS=-Iignoreme 65793 ALSA_LIBS=-lasound 65794 DEFAULT_ALSA=yes 65795 65796 else 65797 ALSA_FOUND=no 65798 65799 fi 65800 65801 done 65802 65803 fi 65804 if test "x$ALSA_FOUND" = xno; then 65805 65806 # Print a helpful message on how to acquire the necessary build dependency. 65807 # alsa is the help tag: freetype, cups, alsa etc 65808 MISSING_DEPENDENCY=alsa 65809 65810 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 65811 cygwin_help $MISSING_DEPENDENCY 65812 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 65813 msys_help $MISSING_DEPENDENCY 65814 else 65815 PKGHANDLER_COMMAND= 65816 65817 case $PKGHANDLER in 65818 apt-get) 65819 apt_help $MISSING_DEPENDENCY ;; 65820 yum) 65821 yum_help $MISSING_DEPENDENCY ;; 65822 brew) 65823 brew_help $MISSING_DEPENDENCY ;; 65824 port) 65825 port_help $MISSING_DEPENDENCY ;; 65826 pkgutil) 65827 pkgutil_help $MISSING_DEPENDENCY ;; 65828 pkgadd) 65829 pkgadd_help $MISSING_DEPENDENCY ;; 65830 esac 65831 65832 if test "x$PKGHANDLER_COMMAND" != x; then 65833 HELP_MSG="You might be able to fix this by running '$PKGHANDLER_COMMAND'." 65834 fi 65835 fi 65836 65837 as_fn_error $? "Could not find alsa! $HELP_MSG" "$LINENO" 5 65838 fi 65839 fi 65840 65841 65842 65843 65844 65845 65846 # Check whether --with-libffi was given. 65847 if test "${with_libffi+set}" = set; then : 65848 withval=$with_libffi; 65849 fi 65850 65851 65852 # Check whether --with-libffi-include was given. 65853 if test "${with_libffi_include+set}" = set; then : 65854 withval=$with_libffi_include; 65855 fi 65856 65857 65858 # Check whether --with-libffi-lib was given. 65859 if test "${with_libffi_lib+set}" = set; then : 65860 withval=$with_libffi_lib; 65861 fi 65862 65863 # Check whether --enable-libffi-bundling was given. 65864 if test "${enable_libffi_bundling+set}" = set; then : 65865 enableval=$enable_libffi_bundling; 65866 fi 65867 65868 65869 if test "x$NEEDS_LIB_FFI" = xfalse; then 65870 if (test "x${with_libffi}" != x && test "x${with_libffi}" != xno) || \ 65871 (test "x${with_libffi_include}" != x && test "x${with_libffi_include}" != xno) || \ 65872 (test "x${with_libffi_lib}" != x && test "x${with_libffi_lib}" != xno); then 65873 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: libffi not used, so --with-libffi[-*] is ignored" >&5 65874 $as_echo "$as_me: WARNING: libffi not used, so --with-libffi[-*] is ignored" >&2;} 65875 fi 65876 LIBFFI_CFLAGS= 65877 LIBFFI_LIBS= 65878 else 65879 LIBFFI_FOUND=no 65880 65881 if test "x${with_libffi}" = xno || test "x${with_libffi_include}" = xno || test "x${with_libffi_lib}" = xno; then 65882 as_fn_error $? "It is not possible to disable the use of libffi. Remove the --without-libffi option." "$LINENO" 5 65883 fi 65884 65885 if test "x${with_libffi}" != x; then 65886 LIBFFI_LIB_PATH="${with_libffi}/lib" 65887 LIBFFI_LIBS="-L${with_libffi}/lib -lffi" 65888 LIBFFI_CFLAGS="-I${with_libffi}/include" 65889 LIBFFI_FOUND=yes 65890 fi 65891 if test "x${with_libffi_include}" != x; then 65892 LIBFFI_CFLAGS="-I${with_libffi_include}" 65893 LIBFFI_FOUND=yes 65894 fi 65895 if test "x${with_libffi_lib}" != x; then 65896 LIBFFI_LIB_PATH="${with_libffi_lib}" 65897 LIBFFI_LIBS="-L${with_libffi_lib} -lffi" 65898 LIBFFI_FOUND=yes 65899 fi 65900 # Do not try pkg-config if we have a sysroot set. 65901 if test "x$SYSROOT" = x; then 65902 if test "x$LIBFFI_FOUND" = xno; then 65903 # Figure out LIBFFI_CFLAGS and LIBFFI_LIBS 65904 65905 pkg_failed=no 65906 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for LIBFFI" >&5 65907 $as_echo_n "checking for LIBFFI... " >&6; } 65908 65909 if test -n "$LIBFFI_CFLAGS"; then 65910 pkg_cv_LIBFFI_CFLAGS="$LIBFFI_CFLAGS" 65911 elif test -n "$PKG_CONFIG"; then 65912 if test -n "$PKG_CONFIG" && \ 65913 { { $as_echo "$as_me:${as_lineno-$LINENO}: \$PKG_CONFIG --exists --print-errors \"libffi\""; } >&5 65914 ($PKG_CONFIG --exists --print-errors "libffi") 2>&5 65915 ac_status=$? 65916 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 65917 test $ac_status = 0; }; then 65918 pkg_cv_LIBFFI_CFLAGS=`$PKG_CONFIG --cflags "libffi" 2>/dev/null` 65919 else 65920 pkg_failed=yes 65921 fi 65922 else 65923 pkg_failed=untried 65924 fi 65925 if test -n "$LIBFFI_LIBS"; then 65926 pkg_cv_LIBFFI_LIBS="$LIBFFI_LIBS" 65927 elif test -n "$PKG_CONFIG"; then 65928 if test -n "$PKG_CONFIG" && \ 65929 { { $as_echo "$as_me:${as_lineno-$LINENO}: \$PKG_CONFIG --exists --print-errors \"libffi\""; } >&5 65930 ($PKG_CONFIG --exists --print-errors "libffi") 2>&5 65931 ac_status=$? 65932 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 65933 test $ac_status = 0; }; then 65934 pkg_cv_LIBFFI_LIBS=`$PKG_CONFIG --libs "libffi" 2>/dev/null` 65935 else 65936 pkg_failed=yes 65937 fi 65938 else 65939 pkg_failed=untried 65940 fi 65941 65942 65943 65944 if test $pkg_failed = yes; then 65945 65946 if $PKG_CONFIG --atleast-pkgconfig-version 0.20; then 65947 _pkg_short_errors_supported=yes 65948 else 65949 _pkg_short_errors_supported=no 65950 fi 65951 if test $_pkg_short_errors_supported = yes; then 65952 LIBFFI_PKG_ERRORS=`$PKG_CONFIG --short-errors --print-errors "libffi" 2>&1` 65953 else 65954 LIBFFI_PKG_ERRORS=`$PKG_CONFIG --print-errors "libffi" 2>&1` 65955 fi 65956 # Put the nasty error message in config.log where it belongs 65957 echo "$LIBFFI_PKG_ERRORS" >&5 65958 65959 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 65960 $as_echo "no" >&6; } 65961 LIBFFI_FOUND=no 65962 elif test $pkg_failed = untried; then 65963 LIBFFI_FOUND=no 65964 else 65965 LIBFFI_CFLAGS=$pkg_cv_LIBFFI_CFLAGS 65966 LIBFFI_LIBS=$pkg_cv_LIBFFI_LIBS 65967 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 65968 $as_echo "yes" >&6; } 65969 LIBFFI_FOUND=yes 65970 fi 65971 fi 65972 fi 65973 if test "x$LIBFFI_FOUND" = xno; then 65974 for ac_header in ffi.h 65975 do : 65976 ac_fn_cxx_check_header_mongrel "$LINENO" "ffi.h" "ac_cv_header_ffi_h" "$ac_includes_default" 65977 if test "x$ac_cv_header_ffi_h" = xyes; then : 65978 cat >>confdefs.h <<_ACEOF 65979 #define HAVE_FFI_H 1 65980 _ACEOF 65981 65982 LIBFFI_FOUND=yes 65983 LIBFFI_CFLAGS= 65984 LIBFFI_LIBS=-lffi 65985 65986 else 65987 LIBFFI_FOUND=no 65988 65989 fi 65990 65991 done 65992 65993 fi 65994 if test "x$LIBFFI_FOUND" = xno; then 65995 65996 # Print a helpful message on how to acquire the necessary build dependency. 65997 # ffi is the help tag: freetype, cups, alsa etc 65998 MISSING_DEPENDENCY=ffi 65999 66000 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 66001 cygwin_help $MISSING_DEPENDENCY 66002 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 66003 msys_help $MISSING_DEPENDENCY 66004 else 66005 PKGHANDLER_COMMAND= 66006 66007 case $PKGHANDLER in 66008 apt-get) 66009 apt_help $MISSING_DEPENDENCY ;; 66010 yum) 66011 yum_help $MISSING_DEPENDENCY ;; 66012 brew) 66013 brew_help $MISSING_DEPENDENCY ;; 66014 port) 66015 port_help $MISSING_DEPENDENCY ;; 66016 pkgutil) 66017 pkgutil_help $MISSING_DEPENDENCY ;; 66018 pkgadd) 66019 pkgadd_help $MISSING_DEPENDENCY ;; 66020 esac 66021 66022 if test "x$PKGHANDLER_COMMAND" != x; then 66023 HELP_MSG="You might be able to fix this by running '$PKGHANDLER_COMMAND'." 66024 fi 66025 fi 66026 66027 as_fn_error $? "Could not find libffi! $HELP_MSG" "$LINENO" 5 66028 fi 66029 66030 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if libffi works" >&5 66031 $as_echo_n "checking if libffi works... " >&6; } 66032 ac_ext=c 66033 ac_cpp='$CPP $CPPFLAGS' 66034 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5' 66035 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' 66036 ac_compiler_gnu=$ac_cv_c_compiler_gnu 66037 66038 OLD_CFLAGS="$CFLAGS" 66039 CFLAGS="$CFLAGS $LIBFFI_CFLAGS" 66040 OLD_LIBS="$LIBS" 66041 LIBS="$LIBS $LIBFFI_LIBS" 66042 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 66043 /* end confdefs.h. */ 66044 #include <ffi.h> 66045 int 66046 main () 66047 { 66048 66049 ffi_call(NULL, NULL, NULL, NULL); 66050 return 0; 66051 66052 ; 66053 return 0; 66054 } 66055 _ACEOF 66056 if ac_fn_c_try_link "$LINENO"; then : 66057 LIBFFI_WORKS=yes 66058 else 66059 LIBFFI_WORKS=no 66060 66061 fi 66062 rm -f core conftest.err conftest.$ac_objext \ 66063 conftest$ac_exeext conftest.$ac_ext 66064 CFLAGS="$OLD_CFLAGS" 66065 LIBS="$OLD_LIBS" 66066 ac_ext=cpp 66067 ac_cpp='$CXXCPP $CPPFLAGS' 66068 ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5' 66069 ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' 66070 ac_compiler_gnu=$ac_cv_cxx_compiler_gnu 66071 66072 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $LIBFFI_WORKS" >&5 66073 $as_echo "$LIBFFI_WORKS" >&6; } 66074 66075 if test "x$LIBFFI_WORKS" = xno; then 66076 66077 # Print a helpful message on how to acquire the necessary build dependency. 66078 # ffi is the help tag: freetype, cups, alsa etc 66079 MISSING_DEPENDENCY=ffi 66080 66081 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 66082 cygwin_help $MISSING_DEPENDENCY 66083 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 66084 msys_help $MISSING_DEPENDENCY 66085 else 66086 PKGHANDLER_COMMAND= 66087 66088 case $PKGHANDLER in 66089 apt-get) 66090 apt_help $MISSING_DEPENDENCY ;; 66091 yum) 66092 yum_help $MISSING_DEPENDENCY ;; 66093 brew) 66094 brew_help $MISSING_DEPENDENCY ;; 66095 port) 66096 port_help $MISSING_DEPENDENCY ;; 66097 pkgutil) 66098 pkgutil_help $MISSING_DEPENDENCY ;; 66099 pkgadd) 66100 pkgadd_help $MISSING_DEPENDENCY ;; 66101 esac 66102 66103 if test "x$PKGHANDLER_COMMAND" != x; then 66104 HELP_MSG="You might be able to fix this by running '$PKGHANDLER_COMMAND'." 66105 fi 66106 fi 66107 66108 as_fn_error $? "Found libffi but could not link and compile with it. $HELP_MSG" "$LINENO" 5 66109 fi 66110 66111 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if libffi should be bundled" >&5 66112 $as_echo_n "checking if libffi should be bundled... " >&6; } 66113 if test "x$enable_libffi_bundling" = "x"; then 66114 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 66115 $as_echo "no" >&6; } 66116 ENABLE_LIBFFI_BUNDLING=false 66117 elif test "x$enable_libffi_bundling" = "xno"; then 66118 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no, forced" >&5 66119 $as_echo "no, forced" >&6; } 66120 ENABLE_LIBFFI_BUNDLING=false 66121 elif test "x$enable_libffi_bundling" = "xyes"; then 66122 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes, forced" >&5 66123 $as_echo "yes, forced" >&6; } 66124 ENABLE_LIBFFI_BUNDLING=true 66125 else 66126 as_fn_error $? "Invalid value for --enable-libffi-bundling" "$LINENO" 5 66127 fi 66128 66129 # Find the libffi.so.X to bundle 66130 if test "x${ENABLE_LIBFFI_BUNDLING}" = "xtrue"; then 66131 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for libffi lib file location" >&5 66132 $as_echo_n "checking for libffi lib file location... " >&6; } 66133 if test "x${LIBFFI_LIB_PATH}" != x; then 66134 if test -e ${LIBFFI_LIB_PATH}/libffi.so.?; then 66135 LIBFFI_LIB_FILE="${LIBFFI_LIB_PATH}/libffi.so.?" 66136 else 66137 as_fn_error $? "Could not locate libffi.so.? for bundling in ${LIBFFI_LIB_PATH}" "$LINENO" 5 66138 fi 66139 else 66140 # If we don't have an explicit path, look in a few obvious places 66141 if test "x${OPENJDK_TARGET_CPU}" = "xx86"; then 66142 if test -e ${SYSROOT}/usr/lib/libffi.so.? ; then 66143 LIBFFI_LIB_FILE="${SYSROOT}/usr/lib/libffi.so.?" 66144 elif test -e ${SYSROOT}/usr/lib/i386-linux-gnu/libffi.so.? ; then 66145 LIBFFI_LIB_FILE="${SYSROOT}/usr/lib/i386-linux-gnu/libffi.so.?" 66146 else 66147 as_fn_error $? "Could not locate libffi.so.? for bundling" "$LINENO" 5 66148 fi 66149 elif test "x${OPENJDK_TARGET_CPU}" = "xx86_64"; then 66150 if test -e ${SYSROOT}/usr/lib64/libffi.so.? ; then 66151 LIBFFI_LIB_FILE="${SYSROOT}/usr/lib64/libffi.so.?" 66152 elif test -e ${SYSROOT}/usr/lib/x86_64-linux-gnu/libffi.so.? ; then 66153 LIBFFI_LIB_FILE="${SYSROOT}/usr/lib/x86_64-linux-gnu/libffi.so.?" 66154 else 66155 as_fn_error $? "Could not locate libffi.so.? for bundling" "$LINENO" 5 66156 fi 66157 else 66158 # Fallback on the default /usr/lib dir 66159 if test -e ${SYSROOT}/usr/lib/libffi.so.? ; then 66160 LIBFFI_LIB_FILE="${SYSROOT}/usr/lib/libffi.so.?" 66161 else 66162 as_fn_error $? "Could not locate libffi.so.? for bundling" "$LINENO" 5 66163 fi 66164 fi 66165 fi 66166 # Make sure the wildcard is evaluated 66167 LIBFFI_LIB_FILE="$(ls ${LIBFFI_LIB_FILE})" 66168 { $as_echo "$as_me:${as_lineno-$LINENO}: result: ${LIBFFI_LIB_FILE}" >&5 66169 $as_echo "${LIBFFI_LIB_FILE}" >&6; } 66170 fi 66171 fi 66172 66173 66174 66175 66176 66177 66178 66179 66180 # Check whether --with-libjpeg was given. 66181 if test "${with_libjpeg+set}" = set; then : 66182 withval=$with_libjpeg; 66183 fi 66184 66185 66186 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for which libjpeg to use" >&5 66187 $as_echo_n "checking for which libjpeg to use... " >&6; } 66188 # default is bundled 66189 DEFAULT_LIBJPEG=bundled 66190 # if user didn't specify, use DEFAULT_LIBJPEG 66191 if test "x${with_libjpeg}" = "x"; then 66192 with_libjpeg=${DEFAULT_LIBJPEG} 66193 fi 66194 { $as_echo "$as_me:${as_lineno-$LINENO}: result: ${with_libjpeg}" >&5 66195 $as_echo "${with_libjpeg}" >&6; } 66196 66197 if test "x${with_libjpeg}" = "xbundled"; then 66198 USE_EXTERNAL_LIBJPEG=false 66199 elif test "x${with_libjpeg}" = "xsystem"; then 66200 ac_fn_cxx_check_header_mongrel "$LINENO" "jpeglib.h" "ac_cv_header_jpeglib_h" "$ac_includes_default" 66201 if test "x$ac_cv_header_jpeglib_h" = xyes; then : 66202 66203 else 66204 as_fn_error $? "--with-libjpeg=system specified, but jpeglib.h not found!" "$LINENO" 5 66205 fi 66206 66207 66208 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for jpeg_CreateDecompress in -ljpeg" >&5 66209 $as_echo_n "checking for jpeg_CreateDecompress in -ljpeg... " >&6; } 66210 if ${ac_cv_lib_jpeg_jpeg_CreateDecompress+:} false; then : 66211 $as_echo_n "(cached) " >&6 66212 else 66213 ac_check_lib_save_LIBS=$LIBS 66214 LIBS="-ljpeg $LIBS" 66215 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 66216 /* end confdefs.h. */ 66217 66218 /* Override any GCC internal prototype to avoid an error. 66219 Use char because int might match the return type of a GCC 66220 builtin and then its argument prototype would still apply. */ 66221 #ifdef __cplusplus 66222 extern "C" 66223 #endif 66224 char jpeg_CreateDecompress (); 66225 int 66226 main () 66227 { 66228 return jpeg_CreateDecompress (); 66229 ; 66230 return 0; 66231 } 66232 _ACEOF 66233 if ac_fn_cxx_try_link "$LINENO"; then : 66234 ac_cv_lib_jpeg_jpeg_CreateDecompress=yes 66235 else 66236 ac_cv_lib_jpeg_jpeg_CreateDecompress=no 66237 fi 66238 rm -f core conftest.err conftest.$ac_objext \ 66239 conftest$ac_exeext conftest.$ac_ext 66240 LIBS=$ac_check_lib_save_LIBS 66241 fi 66242 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_jpeg_jpeg_CreateDecompress" >&5 66243 $as_echo "$ac_cv_lib_jpeg_jpeg_CreateDecompress" >&6; } 66244 if test "x$ac_cv_lib_jpeg_jpeg_CreateDecompress" = xyes; then : 66245 cat >>confdefs.h <<_ACEOF 66246 #define HAVE_LIBJPEG 1 66247 _ACEOF 66248 66249 LIBS="-ljpeg $LIBS" 66250 66251 else 66252 as_fn_error $? "--with-libjpeg=system specified, but no libjpeg found" "$LINENO" 5 66253 fi 66254 66255 66256 USE_EXTERNAL_LIBJPEG=true 66257 else 66258 as_fn_error $? "Invalid use of --with-libjpeg: ${with_libjpeg}, use 'system' or 'bundled'" "$LINENO" 5 66259 fi 66260 66261 66262 66263 66264 66265 # Check whether --with-giflib was given. 66266 if test "${with_giflib+set}" = set; then : 66267 withval=$with_giflib; 66268 fi 66269 66270 66271 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for which giflib to use" >&5 66272 $as_echo_n "checking for which giflib to use... " >&6; } 66273 # default is bundled 66274 DEFAULT_GIFLIB=bundled 66275 # if user didn't specify, use DEFAULT_GIFLIB 66276 if test "x${with_giflib}" = "x"; then 66277 with_giflib=${DEFAULT_GIFLIB} 66278 fi 66279 { $as_echo "$as_me:${as_lineno-$LINENO}: result: ${with_giflib}" >&5 66280 $as_echo "${with_giflib}" >&6; } 66281 66282 if test "x${with_giflib}" = "xbundled"; then 66283 USE_EXTERNAL_LIBGIF=false 66284 elif test "x${with_giflib}" = "xsystem"; then 66285 ac_fn_cxx_check_header_mongrel "$LINENO" "gif_lib.h" "ac_cv_header_gif_lib_h" "$ac_includes_default" 66286 if test "x$ac_cv_header_gif_lib_h" = xyes; then : 66287 66288 else 66289 as_fn_error $? "--with-giflib=system specified, but gif_lib.h not found!" "$LINENO" 5 66290 fi 66291 66292 66293 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for DGifGetCode in -lgif" >&5 66294 $as_echo_n "checking for DGifGetCode in -lgif... " >&6; } 66295 if ${ac_cv_lib_gif_DGifGetCode+:} false; then : 66296 $as_echo_n "(cached) " >&6 66297 else 66298 ac_check_lib_save_LIBS=$LIBS 66299 LIBS="-lgif $LIBS" 66300 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 66301 /* end confdefs.h. */ 66302 66303 /* Override any GCC internal prototype to avoid an error. 66304 Use char because int might match the return type of a GCC 66305 builtin and then its argument prototype would still apply. */ 66306 #ifdef __cplusplus 66307 extern "C" 66308 #endif 66309 char DGifGetCode (); 66310 int 66311 main () 66312 { 66313 return DGifGetCode (); 66314 ; 66315 return 0; 66316 } 66317 _ACEOF 66318 if ac_fn_cxx_try_link "$LINENO"; then : 66319 ac_cv_lib_gif_DGifGetCode=yes 66320 else 66321 ac_cv_lib_gif_DGifGetCode=no 66322 fi 66323 rm -f core conftest.err conftest.$ac_objext \ 66324 conftest$ac_exeext conftest.$ac_ext 66325 LIBS=$ac_check_lib_save_LIBS 66326 fi 66327 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_gif_DGifGetCode" >&5 66328 $as_echo "$ac_cv_lib_gif_DGifGetCode" >&6; } 66329 if test "x$ac_cv_lib_gif_DGifGetCode" = xyes; then : 66330 cat >>confdefs.h <<_ACEOF 66331 #define HAVE_LIBGIF 1 66332 _ACEOF 66333 66334 LIBS="-lgif $LIBS" 66335 66336 else 66337 as_fn_error $? "--with-giflib=system specified, but no giflib found!" "$LINENO" 5 66338 fi 66339 66340 66341 USE_EXTERNAL_LIBGIF=true 66342 else 66343 as_fn_error $? "Invalid value of --with-giflib: ${with_giflib}, use 'system' or 'bundled'" "$LINENO" 5 66344 fi 66345 66346 66347 66348 66349 66350 # Check whether --with-libpng was given. 66351 if test "${with_libpng+set}" = set; then : 66352 withval=$with_libpng; 66353 fi 66354 66355 66356 66357 pkg_failed=no 66358 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for PNG" >&5 66359 $as_echo_n "checking for PNG... " >&6; } 66360 66361 if test -n "$PNG_CFLAGS"; then 66362 pkg_cv_PNG_CFLAGS="$PNG_CFLAGS" 66363 elif test -n "$PKG_CONFIG"; then 66364 if test -n "$PKG_CONFIG" && \ 66365 { { $as_echo "$as_me:${as_lineno-$LINENO}: \$PKG_CONFIG --exists --print-errors \"libpng\""; } >&5 66366 ($PKG_CONFIG --exists --print-errors "libpng") 2>&5 66367 ac_status=$? 66368 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 66369 test $ac_status = 0; }; then 66370 pkg_cv_PNG_CFLAGS=`$PKG_CONFIG --cflags "libpng" 2>/dev/null` 66371 else 66372 pkg_failed=yes 66373 fi 66374 else 66375 pkg_failed=untried 66376 fi 66377 if test -n "$PNG_LIBS"; then 66378 pkg_cv_PNG_LIBS="$PNG_LIBS" 66379 elif test -n "$PKG_CONFIG"; then 66380 if test -n "$PKG_CONFIG" && \ 66381 { { $as_echo "$as_me:${as_lineno-$LINENO}: \$PKG_CONFIG --exists --print-errors \"libpng\""; } >&5 66382 ($PKG_CONFIG --exists --print-errors "libpng") 2>&5 66383 ac_status=$? 66384 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 66385 test $ac_status = 0; }; then 66386 pkg_cv_PNG_LIBS=`$PKG_CONFIG --libs "libpng" 2>/dev/null` 66387 else 66388 pkg_failed=yes 66389 fi 66390 else 66391 pkg_failed=untried 66392 fi 66393 66394 66395 66396 if test $pkg_failed = yes; then 66397 66398 if $PKG_CONFIG --atleast-pkgconfig-version 0.20; then 66399 _pkg_short_errors_supported=yes 66400 else 66401 _pkg_short_errors_supported=no 66402 fi 66403 if test $_pkg_short_errors_supported = yes; then 66404 PNG_PKG_ERRORS=`$PKG_CONFIG --short-errors --print-errors "libpng" 2>&1` 66405 else 66406 PNG_PKG_ERRORS=`$PKG_CONFIG --print-errors "libpng" 2>&1` 66407 fi 66408 # Put the nasty error message in config.log where it belongs 66409 echo "$PNG_PKG_ERRORS" >&5 66410 66411 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 66412 $as_echo "no" >&6; } 66413 LIBPNG_FOUND=no 66414 elif test $pkg_failed = untried; then 66415 LIBPNG_FOUND=no 66416 else 66417 PNG_CFLAGS=$pkg_cv_PNG_CFLAGS 66418 PNG_LIBS=$pkg_cv_PNG_LIBS 66419 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 66420 $as_echo "yes" >&6; } 66421 LIBPNG_FOUND=yes 66422 fi 66423 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for which libpng to use" >&5 66424 $as_echo_n "checking for which libpng to use... " >&6; } 66425 66426 # default is bundled 66427 DEFAULT_LIBPNG=bundled 66428 # if user didn't specify, use DEFAULT_LIBPNG 66429 if test "x${with_libpng}" = "x"; then 66430 with_libpng=${DEFAULT_LIBPNG} 66431 fi 66432 66433 if test "x${with_libpng}" = "xbundled"; then 66434 USE_EXTERNAL_LIBPNG=false 66435 PNG_CFLAGS="" 66436 PNG_LIBS="" 66437 { $as_echo "$as_me:${as_lineno-$LINENO}: result: bundled" >&5 66438 $as_echo "bundled" >&6; } 66439 elif test "x${with_libpng}" = "xsystem"; then 66440 if test "x${LIBPNG_FOUND}" = "xyes"; then 66441 # PKG_CHECK_MODULES will set PNG_CFLAGS and PNG_LIBS 66442 USE_EXTERNAL_LIBPNG=true 66443 { $as_echo "$as_me:${as_lineno-$LINENO}: result: system" >&5 66444 $as_echo "system" >&6; } 66445 else 66446 { $as_echo "$as_me:${as_lineno-$LINENO}: result: system not found" >&5 66447 $as_echo "system not found" >&6; } 66448 as_fn_error $? "--with-libpng=system specified, but no libpng found!" "$LINENO" 5 66449 fi 66450 else 66451 as_fn_error $? "Invalid value of --with-libpng: ${with_libpng}, use 'system' or 'bundled'" "$LINENO" 5 66452 fi 66453 66454 66455 66456 66457 66458 66459 66460 # Check whether --with-zlib was given. 66461 if test "${with_zlib+set}" = set; then : 66462 withval=$with_zlib; 66463 fi 66464 66465 66466 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for compress in -lz" >&5 66467 $as_echo_n "checking for compress in -lz... " >&6; } 66468 if ${ac_cv_lib_z_compress+:} false; then : 66469 $as_echo_n "(cached) " >&6 66470 else 66471 ac_check_lib_save_LIBS=$LIBS 66472 LIBS="-lz $LIBS" 66473 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 66474 /* end confdefs.h. */ 66475 66476 /* Override any GCC internal prototype to avoid an error. 66477 Use char because int might match the return type of a GCC 66478 builtin and then its argument prototype would still apply. */ 66479 #ifdef __cplusplus 66480 extern "C" 66481 #endif 66482 char compress (); 66483 int 66484 main () 66485 { 66486 return compress (); 66487 ; 66488 return 0; 66489 } 66490 _ACEOF 66491 if ac_fn_cxx_try_link "$LINENO"; then : 66492 ac_cv_lib_z_compress=yes 66493 else 66494 ac_cv_lib_z_compress=no 66495 fi 66496 rm -f core conftest.err conftest.$ac_objext \ 66497 conftest$ac_exeext conftest.$ac_ext 66498 LIBS=$ac_check_lib_save_LIBS 66499 fi 66500 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_z_compress" >&5 66501 $as_echo "$ac_cv_lib_z_compress" >&6; } 66502 if test "x$ac_cv_lib_z_compress" = xyes; then : 66503 ZLIB_FOUND=yes 66504 else 66505 ZLIB_FOUND=no 66506 fi 66507 66508 66509 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for which zlib to use" >&5 66510 $as_echo_n "checking for which zlib to use... " >&6; } 66511 66512 DEFAULT_ZLIB=system 66513 if test "x$OPENJDK_TARGET_OS" = xwindows; then 66514 # On windows default is bundled...on others default is system 66515 DEFAULT_ZLIB=bundled 66516 fi 66517 66518 if test "x${ZLIB_FOUND}" != "xyes"; then 66519 # If we don't find any system...set default to bundled 66520 DEFAULT_ZLIB=bundled 66521 fi 66522 66523 # If user didn't specify, use DEFAULT_ZLIB 66524 if test "x${with_zlib}" = "x"; then 66525 with_zlib=${DEFAULT_ZLIB} 66526 fi 66527 66528 if test "x${with_zlib}" = "xbundled"; then 66529 USE_EXTERNAL_LIBZ=false 66530 { $as_echo "$as_me:${as_lineno-$LINENO}: result: bundled" >&5 66531 $as_echo "bundled" >&6; } 66532 elif test "x${with_zlib}" = "xsystem"; then 66533 if test "x${ZLIB_FOUND}" = "xyes"; then 66534 USE_EXTERNAL_LIBZ=true 66535 { $as_echo "$as_me:${as_lineno-$LINENO}: result: system" >&5 66536 $as_echo "system" >&6; } 66537 66538 if test "x$USE_EXTERNAL_LIBPNG" != "xtrue"; then 66539 # If we use bundled libpng, we must verify that we have a proper zlib. 66540 # For instance zlib-ng has had issues with inflateValidate(). 66541 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for system zlib functionality" >&5 66542 $as_echo_n "checking for system zlib functionality... " >&6; } 66543 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 66544 /* end confdefs.h. */ 66545 #include "zlib.h" 66546 int 66547 main () 66548 { 66549 66550 #if ZLIB_VERNUM >= 0x1281 66551 inflateValidate(NULL, 0); 66552 #endif 66553 66554 ; 66555 return 0; 66556 } 66557 _ACEOF 66558 if ac_fn_cxx_try_compile "$LINENO"; then : 66559 { $as_echo "$as_me:${as_lineno-$LINENO}: result: ok" >&5 66560 $as_echo "ok" >&6; } 66561 else 66562 66563 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not ok" >&5 66564 $as_echo "not ok" >&6; } 66565 as_fn_error $? "System zlib not working correctly" "$LINENO" 5 66566 66567 66568 fi 66569 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext 66570 fi 66571 else 66572 { $as_echo "$as_me:${as_lineno-$LINENO}: result: system not found" >&5 66573 $as_echo "system not found" >&6; } 66574 as_fn_error $? "--with-zlib=system specified, but no zlib found!" "$LINENO" 5 66575 fi 66576 else 66577 as_fn_error $? "Invalid value for --with-zlib: ${with_zlib}, use 'system' or 'bundled'" "$LINENO" 5 66578 fi 66579 66580 66581 66582 66583 66584 # Check whether --with-lcms was given. 66585 if test "${with_lcms+set}" = set; then : 66586 withval=$with_lcms; 66587 fi 66588 66589 66590 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for which lcms to use" >&5 66591 $as_echo_n "checking for which lcms to use... " >&6; } 66592 66593 DEFAULT_LCMS=bundled 66594 # If user didn't specify, use DEFAULT_LCMS 66595 if test "x${with_lcms}" = "x"; then 66596 with_lcms=${DEFAULT_LCMS} 66597 fi 66598 66599 if test "x${with_lcms}" = "xbundled"; then 66600 USE_EXTERNAL_LCMS=false 66601 LCMS_CFLAGS="" 66602 LCMS_LIBS="" 66603 { $as_echo "$as_me:${as_lineno-$LINENO}: result: bundled" >&5 66604 $as_echo "bundled" >&6; } 66605 elif test "x${with_lcms}" = "xsystem"; then 66606 { $as_echo "$as_me:${as_lineno-$LINENO}: result: system" >&5 66607 $as_echo "system" >&6; } 66608 66609 pkg_failed=no 66610 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for LCMS" >&5 66611 $as_echo_n "checking for LCMS... " >&6; } 66612 66613 if test -n "$LCMS_CFLAGS"; then 66614 pkg_cv_LCMS_CFLAGS="$LCMS_CFLAGS" 66615 elif test -n "$PKG_CONFIG"; then 66616 if test -n "$PKG_CONFIG" && \ 66617 { { $as_echo "$as_me:${as_lineno-$LINENO}: \$PKG_CONFIG --exists --print-errors \"lcms2\""; } >&5 66618 ($PKG_CONFIG --exists --print-errors "lcms2") 2>&5 66619 ac_status=$? 66620 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 66621 test $ac_status = 0; }; then 66622 pkg_cv_LCMS_CFLAGS=`$PKG_CONFIG --cflags "lcms2" 2>/dev/null` 66623 else 66624 pkg_failed=yes 66625 fi 66626 else 66627 pkg_failed=untried 66628 fi 66629 if test -n "$LCMS_LIBS"; then 66630 pkg_cv_LCMS_LIBS="$LCMS_LIBS" 66631 elif test -n "$PKG_CONFIG"; then 66632 if test -n "$PKG_CONFIG" && \ 66633 { { $as_echo "$as_me:${as_lineno-$LINENO}: \$PKG_CONFIG --exists --print-errors \"lcms2\""; } >&5 66634 ($PKG_CONFIG --exists --print-errors "lcms2") 2>&5 66635 ac_status=$? 66636 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 66637 test $ac_status = 0; }; then 66638 pkg_cv_LCMS_LIBS=`$PKG_CONFIG --libs "lcms2" 2>/dev/null` 66639 else 66640 pkg_failed=yes 66641 fi 66642 else 66643 pkg_failed=untried 66644 fi 66645 66646 66647 66648 if test $pkg_failed = yes; then 66649 66650 if $PKG_CONFIG --atleast-pkgconfig-version 0.20; then 66651 _pkg_short_errors_supported=yes 66652 else 66653 _pkg_short_errors_supported=no 66654 fi 66655 if test $_pkg_short_errors_supported = yes; then 66656 LCMS_PKG_ERRORS=`$PKG_CONFIG --short-errors --print-errors "lcms2" 2>&1` 66657 else 66658 LCMS_PKG_ERRORS=`$PKG_CONFIG --print-errors "lcms2" 2>&1` 66659 fi 66660 # Put the nasty error message in config.log where it belongs 66661 echo "$LCMS_PKG_ERRORS" >&5 66662 66663 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 66664 $as_echo "no" >&6; } 66665 LCMS_FOUND=no 66666 elif test $pkg_failed = untried; then 66667 LCMS_FOUND=no 66668 else 66669 LCMS_CFLAGS=$pkg_cv_LCMS_CFLAGS 66670 LCMS_LIBS=$pkg_cv_LCMS_LIBS 66671 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 66672 $as_echo "yes" >&6; } 66673 LCMS_FOUND=yes 66674 fi 66675 if test "x${LCMS_FOUND}" = "xyes"; then 66676 # PKG_CHECK_MODULES will set LCMS_CFLAGS and LCMS_LIBS 66677 USE_EXTERNAL_LCMS=true 66678 else 66679 as_fn_error $? "--with-lcms=system specified, but no lcms found!" "$LINENO" 5 66680 fi 66681 else 66682 as_fn_error $? "Invalid value for --with-lcms: ${with_lcms}, use 'system' or 'bundled'" "$LINENO" 5 66683 fi 66684 66685 66686 66687 66688 66689 66690 66691 66692 66693 66694 66695 66696 66697 # Setup libm (the maths library) 66698 if test "x$OPENJDK_TARGET_OS" != "xwindows"; then 66699 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for cos in -lm" >&5 66700 $as_echo_n "checking for cos in -lm... " >&6; } 66701 if ${ac_cv_lib_m_cos+:} false; then : 66702 $as_echo_n "(cached) " >&6 66703 else 66704 ac_check_lib_save_LIBS=$LIBS 66705 LIBS="-lm $LIBS" 66706 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 66707 /* end confdefs.h. */ 66708 66709 /* Override any GCC internal prototype to avoid an error. 66710 Use char because int might match the return type of a GCC 66711 builtin and then its argument prototype would still apply. */ 66712 #ifdef __cplusplus 66713 extern "C" 66714 #endif 66715 char cos (); 66716 int 66717 main () 66718 { 66719 return cos (); 66720 ; 66721 return 0; 66722 } 66723 _ACEOF 66724 if ac_fn_cxx_try_link "$LINENO"; then : 66725 ac_cv_lib_m_cos=yes 66726 else 66727 ac_cv_lib_m_cos=no 66728 fi 66729 rm -f core conftest.err conftest.$ac_objext \ 66730 conftest$ac_exeext conftest.$ac_ext 66731 LIBS=$ac_check_lib_save_LIBS 66732 fi 66733 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_m_cos" >&5 66734 $as_echo "$ac_cv_lib_m_cos" >&6; } 66735 if test "x$ac_cv_lib_m_cos" = xyes; then : 66736 cat >>confdefs.h <<_ACEOF 66737 #define HAVE_LIBM 1 66738 _ACEOF 66739 66740 LIBS="-lm $LIBS" 66741 66742 else 66743 66744 { $as_echo "$as_me:${as_lineno-$LINENO}: Maths library was not found" >&5 66745 $as_echo "$as_me: Maths library was not found" >&6;} 66746 66747 fi 66748 66749 LIBM="-lm" 66750 else 66751 LIBM="" 66752 fi 66753 66754 66755 # Setup libdl (for dynamic library loading) 66756 save_LIBS="$LIBS" 66757 LIBS="" 66758 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for dlopen in -ldl" >&5 66759 $as_echo_n "checking for dlopen in -ldl... " >&6; } 66760 if ${ac_cv_lib_dl_dlopen+:} false; then : 66761 $as_echo_n "(cached) " >&6 66762 else 66763 ac_check_lib_save_LIBS=$LIBS 66764 LIBS="-ldl $LIBS" 66765 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 66766 /* end confdefs.h. */ 66767 66768 /* Override any GCC internal prototype to avoid an error. 66769 Use char because int might match the return type of a GCC 66770 builtin and then its argument prototype would still apply. */ 66771 #ifdef __cplusplus 66772 extern "C" 66773 #endif 66774 char dlopen (); 66775 int 66776 main () 66777 { 66778 return dlopen (); 66779 ; 66780 return 0; 66781 } 66782 _ACEOF 66783 if ac_fn_cxx_try_link "$LINENO"; then : 66784 ac_cv_lib_dl_dlopen=yes 66785 else 66786 ac_cv_lib_dl_dlopen=no 66787 fi 66788 rm -f core conftest.err conftest.$ac_objext \ 66789 conftest$ac_exeext conftest.$ac_ext 66790 LIBS=$ac_check_lib_save_LIBS 66791 fi 66792 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_dl_dlopen" >&5 66793 $as_echo "$ac_cv_lib_dl_dlopen" >&6; } 66794 if test "x$ac_cv_lib_dl_dlopen" = xyes; then : 66795 cat >>confdefs.h <<_ACEOF 66796 #define HAVE_LIBDL 1 66797 _ACEOF 66798 66799 LIBS="-ldl $LIBS" 66800 66801 fi 66802 66803 LIBDL="$LIBS" 66804 66805 LIBS="$save_LIBS" 66806 66807 # Deprecated libraries, keep the flags for backwards compatibility 66808 if test "x$OPENJDK_TARGET_OS" = "xwindows"; then 66809 66810 66811 # Check whether --with-dxsdk was given. 66812 if test "${with_dxsdk+set}" = set; then : 66813 withval=$with_dxsdk; { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Option --with-dxsdk is deprecated and will be ignored." >&5 66814 $as_echo "$as_me: WARNING: Option --with-dxsdk is deprecated and will be ignored." >&2;} 66815 fi 66816 66817 66818 66819 66820 # Check whether --with-dxsdk-lib was given. 66821 if test "${with_dxsdk_lib+set}" = set; then : 66822 withval=$with_dxsdk_lib; { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Option --with-dxsdk-lib is deprecated and will be ignored." >&5 66823 $as_echo "$as_me: WARNING: Option --with-dxsdk-lib is deprecated and will be ignored." >&2;} 66824 fi 66825 66826 66827 66828 66829 # Check whether --with-dxsdk-include was given. 66830 if test "${with_dxsdk_include+set}" = set; then : 66831 withval=$with_dxsdk_include; { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Option --with-dxsdk-include is deprecated and will be ignored." >&5 66832 $as_echo "$as_me: WARNING: Option --with-dxsdk-include is deprecated and will be ignored." >&2;} 66833 fi 66834 66835 66836 fi 66837 66838 # Control if libzip can use mmap. Available for purposes of overriding. 66839 LIBZIP_CAN_USE_MMAP=true 66840 66841 66842 66843 if test "$OPENJDK_TARGET_OS" = "solaris" && test "x$BUILD_GTEST" = "xtrue"; then 66844 # Find the root of the Solaris Studio installation from the compiler path 66845 SOLARIS_STUDIO_DIR="$(dirname $CC)/.." 66846 STLPORT_LIB="$SOLARIS_STUDIO_DIR/lib/stlport4$OPENJDK_TARGET_CPU_ISADIR/libstlport.so.1" 66847 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for libstlport.so.1" >&5 66848 $as_echo_n "checking for libstlport.so.1... " >&6; } 66849 if ! test -f "$STLPORT_LIB" && test "x$OPENJDK_TARGET_CPU_ISADIR" = "x/sparcv9"; then 66850 # SS12u3 has libstlport under 'stlport4/v9' instead of 'stlport4/sparcv9' 66851 STLPORT_LIB="$SOLARIS_STUDIO_DIR/lib/stlport4/v9/libstlport.so.1" 66852 fi 66853 if test -f "$STLPORT_LIB"; then 66854 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes, $STLPORT_LIB" >&5 66855 $as_echo "yes, $STLPORT_LIB" >&6; } 66856 66857 # Only process if variable expands to non-empty 66858 66859 if test "x$STLPORT_LIB" != x; then 66860 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 66861 66862 # Input might be given as Windows format, start by converting to 66863 # unix format. 66864 path="$STLPORT_LIB" 66865 new_path=`$CYGPATH -u "$path"` 66866 66867 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 66868 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 66869 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 66870 # "foo.exe" is OK but "foo" is an error. 66871 # 66872 # This test is therefore slightly more accurate than "test -f" to check for file precense. 66873 # It is also a way to make sure we got the proper file name for the real test later on. 66874 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 66875 if test "x$test_shortpath" = x; then 66876 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of STLPORT_LIB, which resolves as \"$path\", is invalid." >&5 66877 $as_echo "$as_me: The path of STLPORT_LIB, which resolves as \"$path\", is invalid." >&6;} 66878 as_fn_error $? "Cannot locate the the path of STLPORT_LIB" "$LINENO" 5 66879 fi 66880 66881 # Call helper function which possibly converts this using DOS-style short mode. 66882 # If so, the updated path is stored in $new_path. 66883 66884 input_path="$new_path" 66885 # Check if we need to convert this using DOS-style short mode. If the path 66886 # contains just simple characters, use it. Otherwise (spaces, weird characters), 66887 # take no chances and rewrite it. 66888 # Note: m4 eats our [], so we need to use [ and ] instead. 66889 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 66890 if test "x$has_forbidden_chars" != x; then 66891 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 66892 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 66893 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 66894 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 66895 # Going to short mode and back again did indeed matter. Since short mode is 66896 # case insensitive, let's make it lowercase to improve readability. 66897 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 66898 # Now convert it back to Unix-style (cygpath) 66899 input_path=`$CYGPATH -u "$shortmode_path"` 66900 new_path="$input_path" 66901 fi 66902 fi 66903 66904 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 66905 if test "x$test_cygdrive_prefix" = x; then 66906 # As a simple fix, exclude /usr/bin since it's not a real path. 66907 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 66908 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 66909 # a path prefixed by /cygdrive for fixpath to work. 66910 new_path="$CYGWIN_ROOT_PATH$input_path" 66911 fi 66912 fi 66913 66914 66915 if test "x$path" != "x$new_path"; then 66916 STLPORT_LIB="$new_path" 66917 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting STLPORT_LIB to \"$new_path\"" >&5 66918 $as_echo "$as_me: Rewriting STLPORT_LIB to \"$new_path\"" >&6;} 66919 fi 66920 66921 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 66922 66923 path="$STLPORT_LIB" 66924 has_colon=`$ECHO $path | $GREP ^.:` 66925 new_path="$path" 66926 if test "x$has_colon" = x; then 66927 # Not in mixed or Windows style, start by that. 66928 new_path=`cmd //c echo $path` 66929 fi 66930 66931 66932 input_path="$new_path" 66933 # Check if we need to convert this using DOS-style short mode. If the path 66934 # contains just simple characters, use it. Otherwise (spaces, weird characters), 66935 # take no chances and rewrite it. 66936 # Note: m4 eats our [], so we need to use [ and ] instead. 66937 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 66938 if test "x$has_forbidden_chars" != x; then 66939 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 66940 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 66941 fi 66942 66943 66944 windows_path="$new_path" 66945 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 66946 unix_path=`$CYGPATH -u "$windows_path"` 66947 new_path="$unix_path" 66948 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 66949 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 66950 new_path="$unix_path" 66951 fi 66952 66953 if test "x$path" != "x$new_path"; then 66954 STLPORT_LIB="$new_path" 66955 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting STLPORT_LIB to \"$new_path\"" >&5 66956 $as_echo "$as_me: Rewriting STLPORT_LIB to \"$new_path\"" >&6;} 66957 fi 66958 66959 # Save the first 10 bytes of this path to the storage, so fixpath can work. 66960 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 66961 66962 else 66963 # We're on a unix platform. Hooray! :) 66964 path="$STLPORT_LIB" 66965 has_space=`$ECHO "$path" | $GREP " "` 66966 if test "x$has_space" != x; then 66967 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of STLPORT_LIB, which resolves as \"$path\", is invalid." >&5 66968 $as_echo "$as_me: The path of STLPORT_LIB, which resolves as \"$path\", is invalid." >&6;} 66969 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 66970 fi 66971 66972 # Use eval to expand a potential ~ 66973 eval path="$path" 66974 if test ! -f "$path" && test ! -d "$path"; then 66975 as_fn_error $? "The path of STLPORT_LIB, which resolves as \"$path\", is not found." "$LINENO" 5 66976 fi 66977 66978 if test -d "$path"; then 66979 STLPORT_LIB="`cd "$path"; $THEPWDCMD -L`" 66980 else 66981 dir="`$DIRNAME "$path"`" 66982 base="`$BASENAME "$path"`" 66983 STLPORT_LIB="`cd "$dir"; $THEPWDCMD -L`/$base" 66984 fi 66985 fi 66986 fi 66987 66988 else 66989 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no, not found at $STLPORT_LIB" >&5 66990 $as_echo "no, not found at $STLPORT_LIB" >&6; } 66991 as_fn_error $? "Failed to find libstlport.so.1, cannot build Hotspot gtests" "$LINENO" 5 66992 fi 66993 66994 fi 66995 66996 66997 66998 66999 67000 67001 67002 67003 67004 67005 67006 67007 67008 67009 # Hotspot setup depends on lib checks. 67010 67011 67012 # The user can in some cases supply additional jvm features. For the custom 67013 # variant, this defines the entire variant. 67014 67015 # Check whether --with-jvm-features was given. 67016 if test "${with_jvm_features+set}" = set; then : 67017 withval=$with_jvm_features; 67018 fi 67019 67020 if test "x$with_jvm_features" != x; then 67021 { $as_echo "$as_me:${as_lineno-$LINENO}: checking additional JVM features" >&5 67022 $as_echo_n "checking additional JVM features... " >&6; } 67023 JVM_FEATURES=`$ECHO $with_jvm_features | $SED -e 's/,/ /g'` 67024 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $JVM_FEATURES" >&5 67025 $as_echo "$JVM_FEATURES" >&6; } 67026 fi 67027 67028 # Override hotspot cpu definitions for ARM platforms 67029 if test "x$OPENJDK_TARGET_CPU" = xarm; then 67030 HOTSPOT_TARGET_CPU=arm_32 67031 HOTSPOT_TARGET_CPU_DEFINE="ARM32" 67032 JVM_LDFLAGS="$JVM_LDFLAGS -fsigned-char" 67033 JVM_CFLAGS="$JVM_CFLAGS -DARM -fsigned-char" 67034 elif test "x$OPENJDK_TARGET_CPU" = xaarch64 && test "x$HOTSPOT_TARGET_CPU_PORT" = xarm64; then 67035 HOTSPOT_TARGET_CPU=arm_64 67036 HOTSPOT_TARGET_CPU_ARCH=arm 67037 JVM_LDFLAGS="$JVM_LDFLAGS -fsigned-char" 67038 JVM_CFLAGS="$JVM_CFLAGS -DARM -fsigned-char" 67039 fi 67040 67041 # Verify that dependencies are met for explicitly set features. 67042 if [[ " $JVM_FEATURES " =~ " jvmti " ]] && ! [[ " $JVM_FEATURES " =~ " services " ]] ; then 67043 as_fn_error $? "Specified JVM feature 'jvmti' requires feature 'services'" "$LINENO" 5 67044 fi 67045 67046 if [[ " $JVM_FEATURES " =~ " management " ]] && ! [[ " $JVM_FEATURES " =~ " nmt " ]] ; then 67047 as_fn_error $? "Specified JVM feature 'management' requires feature 'nmt'" "$LINENO" 5 67048 fi 67049 67050 if [[ " $JVM_FEATURES " =~ " jvmci " ]] && ! ( [[ " $JVM_FEATURES " =~ " compiler1 " ]] || [[ " $JVM_FEATURES " =~ " compiler2 " ]] ); then 67051 as_fn_error $? "Specified JVM feature 'jvmci' requires feature 'compiler2' or 'compiler1'" "$LINENO" 5 67052 fi 67053 67054 if [[ " $JVM_FEATURES " =~ " compiler2 " ]] && ! [[ " $JVM_FEATURES " =~ " all-gcs " ]] ; then 67055 as_fn_error $? "Specified JVM feature 'compiler2' requires feature 'all-gcs'" "$LINENO" 5 67056 fi 67057 67058 if [[ " $JVM_FEATURES " =~ " vm-structs " ]] && ! [[ " $JVM_FEATURES " =~ " all-gcs " ]] ; then 67059 as_fn_error $? "Specified JVM feature 'vm-structs' requires feature 'all-gcs'" "$LINENO" 5 67060 fi 67061 67062 # Turn on additional features based on other parts of configure 67063 if test "x$INCLUDE_DTRACE" = "xtrue"; then 67064 JVM_FEATURES="$JVM_FEATURES dtrace" 67065 else 67066 if [[ " $JVM_FEATURES " =~ " dtrace " ]] ; then 67067 as_fn_error $? "To enable dtrace, you must use --enable-dtrace" "$LINENO" 5 67068 fi 67069 fi 67070 67071 if test "x$STATIC_BUILD" = "xtrue"; then 67072 JVM_FEATURES="$JVM_FEATURES static-build" 67073 else 67074 if [[ " $JVM_FEATURES " =~ " static-build " ]] ; then 67075 as_fn_error $? "To enable static-build, you must use --enable-static-build" "$LINENO" 5 67076 fi 67077 fi 67078 67079 if ! [[ " $JVM_VARIANTS " =~ " zero " ]] ; then 67080 if [[ " $JVM_FEATURES " =~ " zero " ]] ; then 67081 as_fn_error $? "To enable zero, you must use --with-jvm-variants=zero" "$LINENO" 5 67082 fi 67083 fi 67084 67085 # Only enable jvmci on x86_64, sparcv9 and aarch64. 67086 if test "x$OPENJDK_TARGET_CPU" = "xx86_64" || \ 67087 test "x$OPENJDK_TARGET_CPU" = "xsparcv9" || \ 67088 test "x$OPENJDK_TARGET_CPU" = "xaarch64" ; then 67089 JVM_FEATURES_jvmci="jvmci" 67090 else 67091 JVM_FEATURES_jvmci="" 67092 fi 67093 67094 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if jdk.internal.vm.compiler should be built" >&5 67095 $as_echo_n "checking if jdk.internal.vm.compiler should be built... " >&6; } 67096 if [[ " $JVM_FEATURES " =~ " graal " ]] ; then 67097 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes, forced" >&5 67098 $as_echo "yes, forced" >&6; } 67099 if test "x$JVM_FEATURES_jvmci" != "xjvmci" ; then 67100 as_fn_error $? "Specified JVM feature 'graal' requires feature 'jvmci'" "$LINENO" 5 67101 fi 67102 INCLUDE_GRAAL="true" 67103 else 67104 # By default enable graal build on linux-x64 or where AOT is available. 67105 # graal build requires jvmci. 67106 if test "x$JVM_FEATURES_jvmci" = "xjvmci" && \ 67107 (test "x$OPENJDK_TARGET_CPU" = "xx86_64" && \ 67108 test "x$OPENJDK_TARGET_OS" = "xlinux" || \ 67109 test "x$ENABLE_AOT" = "xtrue") ; then 67110 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 67111 $as_echo "yes" >&6; } 67112 JVM_FEATURES_graal="graal" 67113 INCLUDE_GRAAL="true" 67114 else 67115 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 67116 $as_echo "no" >&6; } 67117 JVM_FEATURES_graal="" 67118 INCLUDE_GRAAL="false" 67119 fi 67120 fi 67121 67122 67123 67124 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if aot should be enabled" >&5 67125 $as_echo_n "checking if aot should be enabled... " >&6; } 67126 if test "x$ENABLE_AOT" = "xtrue"; then 67127 if test "x$enable_aot" = "xyes"; then 67128 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes, forced" >&5 67129 $as_echo "yes, forced" >&6; } 67130 else 67131 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 67132 $as_echo "yes" >&6; } 67133 fi 67134 JVM_FEATURES_aot="aot" 67135 else 67136 if test "x$enable_aot" = "xno"; then 67137 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no, forced" >&5 67138 $as_echo "no, forced" >&6; } 67139 else 67140 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 67141 $as_echo "no" >&6; } 67142 fi 67143 JVM_FEATURES_aot="" 67144 fi 67145 67146 if test "x$OPENJDK_TARGET_CPU" = xarm ; then 67147 # Default to use link time optimizations on minimal on arm 67148 JVM_FEATURES_link_time_opt="link-time-opt" 67149 else 67150 JVM_FEATURES_link_time_opt="" 67151 fi 67152 67153 # All variants but minimal (and custom) get these features 67154 NON_MINIMAL_FEATURES="$NON_MINIMAL_FEATURES jvmti vm-structs jni-check services management all-gcs nmt" 67155 if test "x$ENABLE_CDS" = "xtrue"; then 67156 NON_MINIMAL_FEATURES="$NON_MINIMAL_FEATURES cds" 67157 fi 67158 67159 # Enable features depending on variant. 67160 JVM_FEATURES_server="compiler1 compiler2 $NON_MINIMAL_FEATURES $JVM_FEATURES $JVM_FEATURES_jvmci $JVM_FEATURES_aot $JVM_FEATURES_graal" 67161 JVM_FEATURES_client="compiler1 $NON_MINIMAL_FEATURES $JVM_FEATURES $JVM_FEATURES_jvmci" 67162 JVM_FEATURES_core="$NON_MINIMAL_FEATURES $JVM_FEATURES" 67163 JVM_FEATURES_minimal="compiler1 minimal $JVM_FEATURES $JVM_FEATURES_link_time_opt" 67164 JVM_FEATURES_zero="zero $NON_MINIMAL_FEATURES $JVM_FEATURES" 67165 JVM_FEATURES_custom="$JVM_FEATURES" 67166 67167 67168 67169 67170 67171 67172 67173 67174 # Used for verification of Makefiles by check-jvm-feature 67175 67176 67177 # We don't support --with-jvm-interpreter anymore, use zero instead. 67178 67179 67180 # Check whether --with-jvm-interpreter was given. 67181 if test "${with_jvm_interpreter+set}" = set; then : 67182 withval=$with_jvm_interpreter; { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Option --with-jvm-interpreter is deprecated and will be ignored." >&5 67183 $as_echo "$as_me: WARNING: Option --with-jvm-interpreter is deprecated and will be ignored." >&2;} 67184 fi 67185 67186 67187 67188 67189 ############################################################################### 67190 # 67191 # We need to do some final tweaking, when everything else is done. 67192 # 67193 ############################################################################### 67194 67195 67196 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if elliptic curve crypto implementation is present" >&5 67197 $as_echo_n "checking if elliptic curve crypto implementation is present... " >&6; } 67198 67199 if test -d "${TOPDIR}/src/jdk.crypto.ec/share/native/libsunec/impl"; then 67200 ENABLE_INTREE_EC=true 67201 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 67202 $as_echo "yes" >&6; } 67203 else 67204 ENABLE_INTREE_EC=false 67205 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 67206 $as_echo "no" >&6; } 67207 fi 67208 67209 67210 67211 67212 # Check whether --enable-jtreg-failure-handler was given. 67213 if test "${enable_jtreg_failure_handler+set}" = set; then : 67214 enableval=$enable_jtreg_failure_handler; 67215 fi 67216 67217 67218 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if jtreg failure handler should be built" >&5 67219 $as_echo_n "checking if jtreg failure handler should be built... " >&6; } 67220 67221 if test "x$enable_jtreg_failure_handler" = "xyes"; then 67222 if test "x$JT_HOME" = "x"; then 67223 as_fn_error $? "Cannot enable jtreg failure handler without jtreg." "$LINENO" 5 67224 else 67225 BUILD_FAILURE_HANDLER=true 67226 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes, forced" >&5 67227 $as_echo "yes, forced" >&6; } 67228 fi 67229 elif test "x$enable_jtreg_failure_handler" = "xno"; then 67230 BUILD_FAILURE_HANDLER=false 67231 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no, forced" >&5 67232 $as_echo "no, forced" >&6; } 67233 elif test "x$enable_jtreg_failure_handler" = "xauto" \ 67234 || test "x$enable_jtreg_failure_handler" = "x"; then 67235 if test "x$JT_HOME" = "x"; then 67236 BUILD_FAILURE_HANDLER=false 67237 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no, missing jtreg" >&5 67238 $as_echo "no, missing jtreg" >&6; } 67239 else 67240 BUILD_FAILURE_HANDLER=true 67241 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes, jtreg present" >&5 67242 $as_echo "yes, jtreg present" >&6; } 67243 fi 67244 else 67245 as_fn_error $? "Invalid value for --enable-jtreg-failure-handler: $enable_jtreg_failure_handler" "$LINENO" 5 67246 fi 67247 67248 67249 67250 67251 # Check whether --enable-generate-classlist was given. 67252 if test "${enable_generate_classlist+set}" = set; then : 67253 enableval=$enable_generate_classlist; 67254 fi 67255 67256 67257 # Check if it's likely that it's possible to generate the classlist. Depending 67258 # on exact jvm configuration it could be possible anyway. 67259 if test "x$ENABLE_CDS" = "xtrue" && ( [[ " $JVM_VARIANTS " =~ " server " ]] || [[ " $JVM_VARIANTS " =~ " client " ]] ); then 67260 ENABLE_GENERATE_CLASSLIST_POSSIBLE="true" 67261 else 67262 ENABLE_GENERATE_CLASSLIST_POSSIBLE="false" 67263 fi 67264 67265 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if the CDS classlist generation should be enabled" >&5 67266 $as_echo_n "checking if the CDS classlist generation should be enabled... " >&6; } 67267 if test "x$enable_generate_classlist" = "xyes"; then 67268 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes, forced" >&5 67269 $as_echo "yes, forced" >&6; } 67270 ENABLE_GENERATE_CLASSLIST="true" 67271 if test "x$ENABLE_GENERATE_CLASSLIST_POSSIBLE" = "xfalse"; then 67272 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Generation of classlist might not be possible with JVM Variants $JVM_VARIANTS and enable-cds=$ENABLE_CDS" >&5 67273 $as_echo "$as_me: WARNING: Generation of classlist might not be possible with JVM Variants $JVM_VARIANTS and enable-cds=$ENABLE_CDS" >&2;} 67274 fi 67275 elif test "x$enable_generate_classlist" = "xno"; then 67276 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no, forced" >&5 67277 $as_echo "no, forced" >&6; } 67278 ENABLE_GENERATE_CLASSLIST="false" 67279 elif test "x$enable_generate_classlist" = "x"; then 67280 if test "x$ENABLE_GENERATE_CLASSLIST_POSSIBLE" = "xtrue"; then 67281 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 67282 $as_echo "yes" >&6; } 67283 ENABLE_GENERATE_CLASSLIST="true" 67284 else 67285 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 67286 $as_echo "no" >&6; } 67287 ENABLE_GENERATE_CLASSLIST="false" 67288 fi 67289 else 67290 as_fn_error $? "Invalid value for --enable-generate-classlist: $enable_generate_classlist" "$LINENO" 5 67291 fi 67292 67293 67294 67295 67296 ############################################################################### 67297 # 67298 # Configure parts of the build that only affect the build performance, 67299 # not the result. 67300 # 67301 ############################################################################### 67302 67303 67304 # How many cores do we have on this build system? 67305 67306 # Check whether --with-num-cores was given. 67307 if test "${with_num_cores+set}" = set; then : 67308 withval=$with_num_cores; 67309 fi 67310 67311 if test "x$with_num_cores" = x; then 67312 # The number of cores were not specified, try to probe them. 67313 67314 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for number of cores" >&5 67315 $as_echo_n "checking for number of cores... " >&6; } 67316 NUM_CORES=1 67317 FOUND_CORES=no 67318 67319 if test -f /proc/cpuinfo; then 67320 # Looks like a Linux (or cygwin) system 67321 NUM_CORES=`cat /proc/cpuinfo | grep -c processor` 67322 FOUND_CORES=yes 67323 elif test -x /usr/sbin/psrinfo; then 67324 # Looks like a Solaris system 67325 NUM_CORES=`LC_MESSAGES=C /usr/sbin/psrinfo -v | grep -c on-line` 67326 FOUND_CORES=yes 67327 elif test -x /usr/sbin/sysctl; then 67328 # Looks like a MacOSX system 67329 NUM_CORES=`/usr/sbin/sysctl -n hw.ncpu` 67330 FOUND_CORES=yes 67331 elif test "x$OPENJDK_BUILD_OS" = xaix ; then 67332 NUM_CORES=`/usr/sbin/prtconf | grep "^Number Of Processors" | awk '{ print $4 }'` 67333 FOUND_CORES=yes 67334 elif test -n "$NUMBER_OF_PROCESSORS"; then 67335 # On windows, look in the env 67336 NUM_CORES=$NUMBER_OF_PROCESSORS 67337 FOUND_CORES=yes 67338 fi 67339 67340 if test "x$FOUND_CORES" = xyes; then 67341 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $NUM_CORES" >&5 67342 $as_echo "$NUM_CORES" >&6; } 67343 else 67344 { $as_echo "$as_me:${as_lineno-$LINENO}: result: could not detect number of cores, defaulting to 1" >&5 67345 $as_echo "could not detect number of cores, defaulting to 1" >&6; } 67346 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: This will disable all parallelism from build!" >&5 67347 $as_echo "$as_me: WARNING: This will disable all parallelism from build!" >&2;} 67348 fi 67349 67350 else 67351 NUM_CORES=$with_num_cores 67352 fi 67353 67354 67355 67356 # How much memory do we have on this build system? 67357 67358 # Check whether --with-memory-size was given. 67359 if test "${with_memory_size+set}" = set; then : 67360 withval=$with_memory_size; 67361 fi 67362 67363 if test "x$with_memory_size" = x; then 67364 # The memory size was not specified, try to probe it. 67365 67366 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for memory size" >&5 67367 $as_echo_n "checking for memory size... " >&6; } 67368 # Default to 1024 MB 67369 MEMORY_SIZE=1024 67370 FOUND_MEM=no 67371 67372 if test -f /proc/meminfo; then 67373 # Looks like a Linux (or cygwin) system 67374 MEMORY_SIZE=`cat /proc/meminfo | grep MemTotal | awk '{print $2}'` 67375 MEMORY_SIZE=`expr $MEMORY_SIZE / 1024` 67376 FOUND_MEM=yes 67377 elif test -x /usr/sbin/prtconf; then 67378 # Looks like a Solaris or AIX system 67379 MEMORY_SIZE=`/usr/sbin/prtconf 2> /dev/null | grep "^Memory [Ss]ize" | awk '{ print $3 }'` 67380 FOUND_MEM=yes 67381 elif test -x /usr/sbin/sysctl; then 67382 # Looks like a MacOSX system 67383 MEMORY_SIZE=`/usr/sbin/sysctl -n hw.memsize` 67384 MEMORY_SIZE=`expr $MEMORY_SIZE / 1024 / 1024` 67385 FOUND_MEM=yes 67386 elif test "x$OPENJDK_BUILD_OS" = xwindows; then 67387 # Windows, but without cygwin 67388 MEMORY_SIZE=`wmic computersystem get totalphysicalmemory -value | grep = | cut -d "=" -f 2-` 67389 MEMORY_SIZE=`expr $MEMORY_SIZE / 1024 / 1024` 67390 FOUND_MEM=yes 67391 fi 67392 67393 if test "x$FOUND_MEM" = xyes; then 67394 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MEMORY_SIZE MB" >&5 67395 $as_echo "$MEMORY_SIZE MB" >&6; } 67396 else 67397 { $as_echo "$as_me:${as_lineno-$LINENO}: result: could not detect memory size, defaulting to $MEMORY_SIZE MB" >&5 67398 $as_echo "could not detect memory size, defaulting to $MEMORY_SIZE MB" >&6; } 67399 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: This might seriously impact build performance!" >&5 67400 $as_echo "$as_me: WARNING: This might seriously impact build performance!" >&2;} 67401 fi 67402 67403 else 67404 MEMORY_SIZE=$with_memory_size 67405 fi 67406 67407 67408 67409 # Provide a decent default number of parallel jobs for make depending on 67410 # number of cores, amount of memory and machine architecture. 67411 67412 # Check whether --with-jobs was given. 67413 if test "${with_jobs+set}" = set; then : 67414 withval=$with_jobs; 67415 fi 67416 67417 if test "x$with_jobs" = x; then 67418 # Number of jobs was not specified, calculate. 67419 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for appropriate number of jobs to run in parallel" >&5 67420 $as_echo_n "checking for appropriate number of jobs to run in parallel... " >&6; } 67421 # Approximate memory in GB. 67422 memory_gb=`expr $MEMORY_SIZE / 1024` 67423 # Pick the lowest of memory in gb and number of cores. 67424 if test "$memory_gb" -lt "$NUM_CORES"; then 67425 JOBS="$memory_gb" 67426 else 67427 JOBS="$NUM_CORES" 67428 fi 67429 if test "$JOBS" -eq "0"; then 67430 JOBS=1 67431 fi 67432 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $JOBS" >&5 67433 $as_echo "$JOBS" >&6; } 67434 else 67435 JOBS=$with_jobs 67436 fi 67437 67438 67439 67440 # The number of test jobs will be chosen automatically if TEST_JOBS is 0 67441 67442 # Check whether --with-test-jobs was given. 67443 if test "${with_test_jobs+set}" = set; then : 67444 withval=$with_test_jobs; 67445 fi 67446 67447 if test "x$with_test_jobs" = x; then 67448 TEST_JOBS=0 67449 else 67450 TEST_JOBS=$with_test_jobs 67451 fi 67452 67453 67454 67455 # Setup arguments for the boot jdk (after cores and memory have been setup) 67456 67457 ############################################################################## 67458 # 67459 # Specify jvm options for anything that is run with the Boot JDK. 67460 # Not all JVM:s accept the same arguments on the command line. 67461 # 67462 67463 # Check whether --with-boot-jdk-jvmargs was given. 67464 if test "${with_boot_jdk_jvmargs+set}" = set; then : 67465 withval=$with_boot_jdk_jvmargs; 67466 fi 67467 67468 67469 { $as_echo "$as_me:${as_lineno-$LINENO}: checking flags for boot jdk java command " >&5 67470 $as_echo_n "checking flags for boot jdk java command ... " >&6; } 67471 67472 # Force en-US environment 67473 67474 $ECHO "Check if jvm arg is ok: -Duser.language=en -Duser.country=US" >&5 67475 $ECHO "Command: $JAVA -Duser.language=en -Duser.country=US -version" >&5 67476 OUTPUT=`$JAVA -Duser.language=en -Duser.country=US -version 2>&1` 67477 FOUND_WARN=`$ECHO "$OUTPUT" | $GREP -i warn` 67478 FOUND_VERSION=`$ECHO $OUTPUT | $GREP " version \""` 67479 if test "x$FOUND_VERSION" != x && test "x$FOUND_WARN" = x; then 67480 boot_jdk_jvmargs="$boot_jdk_jvmargs -Duser.language=en -Duser.country=US" 67481 JVM_ARG_OK=true 67482 else 67483 $ECHO "Arg failed:" >&5 67484 $ECHO "$OUTPUT" >&5 67485 JVM_ARG_OK=false 67486 fi 67487 67488 67489 if test "x$BOOTJDK_USE_LOCAL_CDS" = xtrue; then 67490 # Use our own CDS archive 67491 67492 $ECHO "Check if jvm arg is ok: $boot_jdk_cds_args -Xshare:auto" >&5 67493 $ECHO "Command: $JAVA $boot_jdk_cds_args -Xshare:auto -version" >&5 67494 OUTPUT=`$JAVA $boot_jdk_cds_args -Xshare:auto -version 2>&1` 67495 FOUND_WARN=`$ECHO "$OUTPUT" | $GREP -i warn` 67496 FOUND_VERSION=`$ECHO $OUTPUT | $GREP " version \""` 67497 if test "x$FOUND_VERSION" != x && test "x$FOUND_WARN" = x; then 67498 boot_jdk_jvmargs="$boot_jdk_jvmargs $boot_jdk_cds_args -Xshare:auto" 67499 JVM_ARG_OK=true 67500 else 67501 $ECHO "Arg failed:" >&5 67502 $ECHO "$OUTPUT" >&5 67503 JVM_ARG_OK=false 67504 fi 67505 67506 else 67507 # Otherwise optimistically use the system-wide one, if one is present 67508 67509 $ECHO "Check if jvm arg is ok: -Xshare:auto" >&5 67510 $ECHO "Command: $JAVA -Xshare:auto -version" >&5 67511 OUTPUT=`$JAVA -Xshare:auto -version 2>&1` 67512 FOUND_WARN=`$ECHO "$OUTPUT" | $GREP -i warn` 67513 FOUND_VERSION=`$ECHO $OUTPUT | $GREP " version \""` 67514 if test "x$FOUND_VERSION" != x && test "x$FOUND_WARN" = x; then 67515 boot_jdk_jvmargs="$boot_jdk_jvmargs -Xshare:auto" 67516 JVM_ARG_OK=true 67517 else 67518 $ECHO "Arg failed:" >&5 67519 $ECHO "$OUTPUT" >&5 67520 JVM_ARG_OK=false 67521 fi 67522 67523 fi 67524 67525 # Apply user provided options. 67526 67527 $ECHO "Check if jvm arg is ok: $with_boot_jdk_jvmargs" >&5 67528 $ECHO "Command: $JAVA $with_boot_jdk_jvmargs -version" >&5 67529 OUTPUT=`$JAVA $with_boot_jdk_jvmargs -version 2>&1` 67530 FOUND_WARN=`$ECHO "$OUTPUT" | $GREP -i warn` 67531 FOUND_VERSION=`$ECHO $OUTPUT | $GREP " version \""` 67532 if test "x$FOUND_VERSION" != x && test "x$FOUND_WARN" = x; then 67533 boot_jdk_jvmargs="$boot_jdk_jvmargs $with_boot_jdk_jvmargs" 67534 JVM_ARG_OK=true 67535 else 67536 $ECHO "Arg failed:" >&5 67537 $ECHO "$OUTPUT" >&5 67538 JVM_ARG_OK=false 67539 fi 67540 67541 67542 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $boot_jdk_jvmargs" >&5 67543 $as_echo "$boot_jdk_jvmargs" >&6; } 67544 67545 # For now, general JAVA_FLAGS are the same as the boot jdk jvmargs 67546 JAVA_FLAGS=$boot_jdk_jvmargs 67547 67548 67549 { $as_echo "$as_me:${as_lineno-$LINENO}: checking flags for boot jdk java command for big workloads" >&5 67550 $as_echo_n "checking flags for boot jdk java command for big workloads... " >&6; } 67551 67552 # Starting amount of heap memory. 67553 67554 $ECHO "Check if jvm arg is ok: -Xms64M" >&5 67555 $ECHO "Command: $JAVA -Xms64M -version" >&5 67556 OUTPUT=`$JAVA -Xms64M -version 2>&1` 67557 FOUND_WARN=`$ECHO "$OUTPUT" | $GREP -i warn` 67558 FOUND_VERSION=`$ECHO $OUTPUT | $GREP " version \""` 67559 if test "x$FOUND_VERSION" != x && test "x$FOUND_WARN" = x; then 67560 boot_jdk_jvmargs_big="$boot_jdk_jvmargs_big -Xms64M" 67561 JVM_ARG_OK=true 67562 else 67563 $ECHO "Arg failed:" >&5 67564 $ECHO "$OUTPUT" >&5 67565 JVM_ARG_OK=false 67566 fi 67567 67568 BOOTCYCLE_JVM_ARGS_BIG=-Xms64M 67569 67570 # Maximum amount of heap memory and stack size. 67571 JVM_HEAP_LIMIT_32="1024" 67572 # Running a 64 bit JVM allows for and requires a bigger heap 67573 JVM_HEAP_LIMIT_64="1600" 67574 STACK_SIZE_32=768 67575 STACK_SIZE_64=1536 67576 JVM_HEAP_LIMIT_GLOBAL=`expr $MEMORY_SIZE / 2` 67577 if test "$JVM_HEAP_LIMIT_GLOBAL" -lt "$JVM_HEAP_LIMIT_32"; then 67578 JVM_HEAP_LIMIT_32=$JVM_HEAP_LIMIT_GLOBAL 67579 fi 67580 if test "$JVM_HEAP_LIMIT_GLOBAL" -lt "$JVM_HEAP_LIMIT_64"; then 67581 JVM_HEAP_LIMIT_64=$JVM_HEAP_LIMIT_GLOBAL 67582 fi 67583 if test "$JVM_HEAP_LIMIT_GLOBAL" -lt "512"; then 67584 JVM_HEAP_LIMIT_32=512 67585 JVM_HEAP_LIMIT_64=512 67586 fi 67587 67588 if test "x$BOOT_JDK_BITS" = "x32"; then 67589 STACK_SIZE=$STACK_SIZE_32 67590 JVM_MAX_HEAP=$JVM_HEAP_LIMIT_32 67591 else 67592 STACK_SIZE=$STACK_SIZE_64 67593 JVM_MAX_HEAP=$JVM_HEAP_LIMIT_64 67594 fi 67595 67596 $ECHO "Check if jvm arg is ok: -Xmx${JVM_MAX_HEAP}M" >&5 67597 $ECHO "Command: $JAVA -Xmx${JVM_MAX_HEAP}M -version" >&5 67598 OUTPUT=`$JAVA -Xmx${JVM_MAX_HEAP}M -version 2>&1` 67599 FOUND_WARN=`$ECHO "$OUTPUT" | $GREP -i warn` 67600 FOUND_VERSION=`$ECHO $OUTPUT | $GREP " version \""` 67601 if test "x$FOUND_VERSION" != x && test "x$FOUND_WARN" = x; then 67602 boot_jdk_jvmargs_big="$boot_jdk_jvmargs_big -Xmx${JVM_MAX_HEAP}M" 67603 JVM_ARG_OK=true 67604 else 67605 $ECHO "Arg failed:" >&5 67606 $ECHO "$OUTPUT" >&5 67607 JVM_ARG_OK=false 67608 fi 67609 67610 67611 $ECHO "Check if jvm arg is ok: -XX:ThreadStackSize=$STACK_SIZE" >&5 67612 $ECHO "Command: $JAVA -XX:ThreadStackSize=$STACK_SIZE -version" >&5 67613 OUTPUT=`$JAVA -XX:ThreadStackSize=$STACK_SIZE -version 2>&1` 67614 FOUND_WARN=`$ECHO "$OUTPUT" | $GREP -i warn` 67615 FOUND_VERSION=`$ECHO $OUTPUT | $GREP " version \""` 67616 if test "x$FOUND_VERSION" != x && test "x$FOUND_WARN" = x; then 67617 boot_jdk_jvmargs_big="$boot_jdk_jvmargs_big -XX:ThreadStackSize=$STACK_SIZE" 67618 JVM_ARG_OK=true 67619 else 67620 $ECHO "Arg failed:" >&5 67621 $ECHO "$OUTPUT" >&5 67622 JVM_ARG_OK=false 67623 fi 67624 67625 67626 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $boot_jdk_jvmargs_big" >&5 67627 $as_echo "$boot_jdk_jvmargs_big" >&6; } 67628 67629 JAVA_FLAGS_BIG=$boot_jdk_jvmargs_big 67630 67631 67632 if test "x$OPENJDK_TARGET_CPU_BITS" = "x32"; then 67633 BOOTCYCLE_MAX_HEAP=$JVM_HEAP_LIMIT_32 67634 BOOTCYCLE_STACK_SIZE=$STACK_SIZE_32 67635 else 67636 BOOTCYCLE_MAX_HEAP=$JVM_HEAP_LIMIT_64 67637 BOOTCYCLE_STACK_SIZE=$STACK_SIZE_64 67638 fi 67639 BOOTCYCLE_JVM_ARGS_BIG="$BOOTCYCLE_JVM_ARGS_BIG -Xmx${BOOTCYCLE_MAX_HEAP}M" 67640 BOOTCYCLE_JVM_ARGS_BIG="$BOOTCYCLE_JVM_ARGS_BIG -XX:ThreadStackSize=$BOOTCYCLE_STACK_SIZE" 67641 { $as_echo "$as_me:${as_lineno-$LINENO}: checking flags for bootcycle boot jdk java command for big workloads" >&5 67642 $as_echo_n "checking flags for bootcycle boot jdk java command for big workloads... " >&6; } 67643 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOTCYCLE_JVM_ARGS_BIG" >&5 67644 $as_echo "$BOOTCYCLE_JVM_ARGS_BIG" >&6; } 67645 67646 67647 # By default, the main javac compilations use big 67648 JAVA_FLAGS_JAVAC="$JAVA_FLAGS_BIG" 67649 67650 67651 { $as_echo "$as_me:${as_lineno-$LINENO}: checking flags for boot jdk java command for small workloads" >&5 67652 $as_echo_n "checking flags for boot jdk java command for small workloads... " >&6; } 67653 67654 # Use serial gc for small short lived tools if possible 67655 67656 $ECHO "Check if jvm arg is ok: -XX:+UseSerialGC" >&5 67657 $ECHO "Command: $JAVA -XX:+UseSerialGC -version" >&5 67658 OUTPUT=`$JAVA -XX:+UseSerialGC -version 2>&1` 67659 FOUND_WARN=`$ECHO "$OUTPUT" | $GREP -i warn` 67660 FOUND_VERSION=`$ECHO $OUTPUT | $GREP " version \""` 67661 if test "x$FOUND_VERSION" != x && test "x$FOUND_WARN" = x; then 67662 boot_jdk_jvmargs_small="$boot_jdk_jvmargs_small -XX:+UseSerialGC" 67663 JVM_ARG_OK=true 67664 else 67665 $ECHO "Arg failed:" >&5 67666 $ECHO "$OUTPUT" >&5 67667 JVM_ARG_OK=false 67668 fi 67669 67670 67671 $ECHO "Check if jvm arg is ok: -Xms32M" >&5 67672 $ECHO "Command: $JAVA -Xms32M -version" >&5 67673 OUTPUT=`$JAVA -Xms32M -version 2>&1` 67674 FOUND_WARN=`$ECHO "$OUTPUT" | $GREP -i warn` 67675 FOUND_VERSION=`$ECHO $OUTPUT | $GREP " version \""` 67676 if test "x$FOUND_VERSION" != x && test "x$FOUND_WARN" = x; then 67677 boot_jdk_jvmargs_small="$boot_jdk_jvmargs_small -Xms32M" 67678 JVM_ARG_OK=true 67679 else 67680 $ECHO "Arg failed:" >&5 67681 $ECHO "$OUTPUT" >&5 67682 JVM_ARG_OK=false 67683 fi 67684 67685 67686 $ECHO "Check if jvm arg is ok: -Xmx512M" >&5 67687 $ECHO "Command: $JAVA -Xmx512M -version" >&5 67688 OUTPUT=`$JAVA -Xmx512M -version 2>&1` 67689 FOUND_WARN=`$ECHO "$OUTPUT" | $GREP -i warn` 67690 FOUND_VERSION=`$ECHO $OUTPUT | $GREP " version \""` 67691 if test "x$FOUND_VERSION" != x && test "x$FOUND_WARN" = x; then 67692 boot_jdk_jvmargs_small="$boot_jdk_jvmargs_small -Xmx512M" 67693 JVM_ARG_OK=true 67694 else 67695 $ECHO "Arg failed:" >&5 67696 $ECHO "$OUTPUT" >&5 67697 JVM_ARG_OK=false 67698 fi 67699 67700 67701 $ECHO "Check if jvm arg is ok: -XX:TieredStopAtLevel=1" >&5 67702 $ECHO "Command: $JAVA -XX:TieredStopAtLevel=1 -version" >&5 67703 OUTPUT=`$JAVA -XX:TieredStopAtLevel=1 -version 2>&1` 67704 FOUND_WARN=`$ECHO "$OUTPUT" | $GREP -i warn` 67705 FOUND_VERSION=`$ECHO $OUTPUT | $GREP " version \""` 67706 if test "x$FOUND_VERSION" != x && test "x$FOUND_WARN" = x; then 67707 boot_jdk_jvmargs_small="$boot_jdk_jvmargs_small -XX:TieredStopAtLevel=1" 67708 JVM_ARG_OK=true 67709 else 67710 $ECHO "Arg failed:" >&5 67711 $ECHO "$OUTPUT" >&5 67712 JVM_ARG_OK=false 67713 fi 67714 67715 67716 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $boot_jdk_jvmargs_small" >&5 67717 $as_echo "$boot_jdk_jvmargs_small" >&6; } 67718 67719 JAVA_FLAGS_SMALL=$boot_jdk_jvmargs_small 67720 67721 67722 JAVA_TOOL_FLAGS_SMALL="" 67723 for f in $JAVA_FLAGS_SMALL; do 67724 JAVA_TOOL_FLAGS_SMALL="$JAVA_TOOL_FLAGS_SMALL -J$f" 67725 done 67726 67727 67728 67729 # Setup smart javac (after cores and memory have been setup) 67730 67731 67732 # Check whether --with-sjavac-server-java was given. 67733 if test "${with_sjavac_server_java+set}" = set; then : 67734 withval=$with_sjavac_server_java; 67735 fi 67736 67737 67738 if test "x$with_sjavac_server_java" != x; then 67739 SJAVAC_SERVER_JAVA="$with_sjavac_server_java" 67740 FOUND_VERSION=`$SJAVAC_SERVER_JAVA -version 2>&1 | grep " version \""` 67741 if test "x$FOUND_VERSION" = x; then 67742 as_fn_error $? "Could not execute server java: $SJAVAC_SERVER_JAVA" "$LINENO" 5 67743 fi 67744 else 67745 SJAVAC_SERVER_JAVA="$JAVA" 67746 fi 67747 67748 67749 if test "$MEMORY_SIZE" -gt "3000"; then 67750 if "$JAVA" -version 2>&1 | $GREP -q "64-Bit"; then 67751 JVM_64BIT=true 67752 fi 67753 fi 67754 67755 MX_VALUE=`expr $MEMORY_SIZE / 2` 67756 if test "$JVM_64BIT" = true; then 67757 # Set ms lower than mx since more than one instance of the server might 67758 # get launched at the same time before they figure out which instance won. 67759 MS_VALUE=512 67760 if test "$MX_VALUE" -gt "2048"; then 67761 MX_VALUE=2048 67762 fi 67763 else 67764 MS_VALUE=256 67765 if test "$MX_VALUE" -gt "1500"; then 67766 MX_VALUE=1500 67767 fi 67768 fi 67769 if test "$MX_VALUE" -lt "512"; then 67770 MX_VALUE=512 67771 fi 67772 67773 $ECHO "Check if jvm arg is ok: -Xms${MS_VALUE}M -Xmx${MX_VALUE}M" >&5 67774 $ECHO "Command: $SJAVAC_SERVER_JAVA -Xms${MS_VALUE}M -Xmx${MX_VALUE}M -version" >&5 67775 OUTPUT=`$SJAVAC_SERVER_JAVA -Xms${MS_VALUE}M -Xmx${MX_VALUE}M -version 2>&1` 67776 FOUND_WARN=`$ECHO "$OUTPUT" | $GREP -i warn` 67777 FOUND_VERSION=`$ECHO $OUTPUT | $GREP " version \""` 67778 if test "x$FOUND_VERSION" != x && test "x$FOUND_WARN" = x; then 67779 SJAVAC_SERVER_JAVA_FLAGS="$SJAVAC_SERVER_JAVA_FLAGS -Xms${MS_VALUE}M -Xmx${MX_VALUE}M" 67780 JVM_ARG_OK=true 67781 else 67782 $ECHO "Arg failed:" >&5 67783 $ECHO "$OUTPUT" >&5 67784 JVM_ARG_OK=false 67785 fi 67786 67787 67788 67789 # Check whether --enable-sjavac was given. 67790 if test "${enable_sjavac+set}" = set; then : 67791 enableval=$enable_sjavac; ENABLE_SJAVAC="${enableval}" 67792 else 67793 ENABLE_SJAVAC="no" 67794 fi 67795 67796 if test "x$JVM_ARG_OK" = "xfalse"; then 67797 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Could not set -Xms${MS_VALUE}M -Xmx${MX_VALUE}M, disabling sjavac" >&5 67798 $as_echo "$as_me: WARNING: Could not set -Xms${MS_VALUE}M -Xmx${MX_VALUE}M, disabling sjavac" >&2;} 67799 ENABLE_SJAVAC="no" 67800 fi 67801 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether to use sjavac" >&5 67802 $as_echo_n "checking whether to use sjavac... " >&6; } 67803 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ENABLE_SJAVAC" >&5 67804 $as_echo "$ENABLE_SJAVAC" >&6; } 67805 67806 67807 # Check whether --enable-javac-server was given. 67808 if test "${enable_javac_server+set}" = set; then : 67809 enableval=$enable_javac_server; ENABLE_JAVAC_SERVER="${enableval}" 67810 else 67811 ENABLE_JAVAC_SERVER="yes" 67812 fi 67813 67814 if test "x$JVM_ARG_OK" = "xfalse"; then 67815 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Could not set -Xms${MS_VALUE}M -Xmx${MX_VALUE}M, disabling javac server" >&5 67816 $as_echo "$as_me: WARNING: Could not set -Xms${MS_VALUE}M -Xmx${MX_VALUE}M, disabling javac server" >&2;} 67817 ENABLE_JAVAC_SERVER="no" 67818 fi 67819 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether to use javac server" >&5 67820 $as_echo_n "checking whether to use javac server... " >&6; } 67821 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ENABLE_JAVAC_SERVER" >&5 67822 $as_echo "$ENABLE_JAVAC_SERVER" >&6; } 67823 67824 67825 if test "x$ENABLE_JAVAC_SERVER" = "xyes" || test "x$ENABLE_SJAVAC" = "xyes"; then 67826 # When using a server javac, the small client instances do not need much 67827 # resources. 67828 JAVA_FLAGS_JAVAC="$JAVA_FLAGS_SMALL" 67829 fi 67830 67831 67832 # Setup use of icecc if requested 67833 67834 # Check whether --enable-icecc was given. 67835 if test "${enable_icecc+set}" = set; then : 67836 enableval=$enable_icecc; 67837 fi 67838 67839 67840 if test "x${enable_icecc}" = "xyes"; then 67841 67842 67843 67844 # Publish this variable in the help. 67845 67846 67847 if [ -z "${ICECC_CMD+x}" ]; then 67848 # The variable is not set by user, try to locate tool using the code snippet 67849 for ac_prog in icecc 67850 do 67851 # Extract the first word of "$ac_prog", so it can be a program name with args. 67852 set dummy $ac_prog; ac_word=$2 67853 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 67854 $as_echo_n "checking for $ac_word... " >&6; } 67855 if ${ac_cv_path_ICECC_CMD+:} false; then : 67856 $as_echo_n "(cached) " >&6 67857 else 67858 case $ICECC_CMD in 67859 [\\/]* | ?:[\\/]*) 67860 ac_cv_path_ICECC_CMD="$ICECC_CMD" # Let the user override the test with a path. 67861 ;; 67862 *) 67863 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 67864 for as_dir in $PATH 67865 do 67866 IFS=$as_save_IFS 67867 test -z "$as_dir" && as_dir=. 67868 for ac_exec_ext in '' $ac_executable_extensions; do 67869 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 67870 ac_cv_path_ICECC_CMD="$as_dir/$ac_word$ac_exec_ext" 67871 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 67872 break 2 67873 fi 67874 done 67875 done 67876 IFS=$as_save_IFS 67877 67878 ;; 67879 esac 67880 fi 67881 ICECC_CMD=$ac_cv_path_ICECC_CMD 67882 if test -n "$ICECC_CMD"; then 67883 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ICECC_CMD" >&5 67884 $as_echo "$ICECC_CMD" >&6; } 67885 else 67886 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 67887 $as_echo "no" >&6; } 67888 fi 67889 67890 67891 test -n "$ICECC_CMD" && break 67892 done 67893 67894 else 67895 # The variable is set, but is it from the command line or the environment? 67896 67897 # Try to remove the string !ICECC_CMD! from our list. 67898 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!ICECC_CMD!/} 67899 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 67900 # If it failed, the variable was not from the command line. Ignore it, 67901 # but warn the user (except for BASH, which is always set by the calling BASH). 67902 if test "xICECC_CMD" != xBASH; then 67903 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of ICECC_CMD from the environment. Use command line variables instead." >&5 67904 $as_echo "$as_me: WARNING: Ignoring value of ICECC_CMD from the environment. Use command line variables instead." >&2;} 67905 fi 67906 # Try to locate tool using the code snippet 67907 for ac_prog in icecc 67908 do 67909 # Extract the first word of "$ac_prog", so it can be a program name with args. 67910 set dummy $ac_prog; ac_word=$2 67911 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 67912 $as_echo_n "checking for $ac_word... " >&6; } 67913 if ${ac_cv_path_ICECC_CMD+:} false; then : 67914 $as_echo_n "(cached) " >&6 67915 else 67916 case $ICECC_CMD in 67917 [\\/]* | ?:[\\/]*) 67918 ac_cv_path_ICECC_CMD="$ICECC_CMD" # Let the user override the test with a path. 67919 ;; 67920 *) 67921 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 67922 for as_dir in $PATH 67923 do 67924 IFS=$as_save_IFS 67925 test -z "$as_dir" && as_dir=. 67926 for ac_exec_ext in '' $ac_executable_extensions; do 67927 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 67928 ac_cv_path_ICECC_CMD="$as_dir/$ac_word$ac_exec_ext" 67929 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 67930 break 2 67931 fi 67932 done 67933 done 67934 IFS=$as_save_IFS 67935 67936 ;; 67937 esac 67938 fi 67939 ICECC_CMD=$ac_cv_path_ICECC_CMD 67940 if test -n "$ICECC_CMD"; then 67941 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ICECC_CMD" >&5 67942 $as_echo "$ICECC_CMD" >&6; } 67943 else 67944 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 67945 $as_echo "no" >&6; } 67946 fi 67947 67948 67949 test -n "$ICECC_CMD" && break 67950 done 67951 67952 else 67953 # If it succeeded, then it was overridden by the user. We will use it 67954 # for the tool. 67955 67956 # First remove it from the list of overridden variables, so we can test 67957 # for unknown variables in the end. 67958 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 67959 67960 # Check if we try to supply an empty value 67961 if test "x$ICECC_CMD" = x; then 67962 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool ICECC_CMD= (no value)" >&5 67963 $as_echo "$as_me: Setting user supplied tool ICECC_CMD= (no value)" >&6;} 67964 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ICECC_CMD" >&5 67965 $as_echo_n "checking for ICECC_CMD... " >&6; } 67966 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 67967 $as_echo "disabled" >&6; } 67968 else 67969 # Check if the provided tool contains a complete path. 67970 tool_specified="$ICECC_CMD" 67971 tool_basename="${tool_specified##*/}" 67972 if test "x$tool_basename" = "x$tool_specified"; then 67973 # A command without a complete path is provided, search $PATH. 67974 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool ICECC_CMD=$tool_basename" >&5 67975 $as_echo "$as_me: Will search for user supplied tool ICECC_CMD=$tool_basename" >&6;} 67976 # Extract the first word of "$tool_basename", so it can be a program name with args. 67977 set dummy $tool_basename; ac_word=$2 67978 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 67979 $as_echo_n "checking for $ac_word... " >&6; } 67980 if ${ac_cv_path_ICECC_CMD+:} false; then : 67981 $as_echo_n "(cached) " >&6 67982 else 67983 case $ICECC_CMD in 67984 [\\/]* | ?:[\\/]*) 67985 ac_cv_path_ICECC_CMD="$ICECC_CMD" # Let the user override the test with a path. 67986 ;; 67987 *) 67988 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 67989 for as_dir in $PATH 67990 do 67991 IFS=$as_save_IFS 67992 test -z "$as_dir" && as_dir=. 67993 for ac_exec_ext in '' $ac_executable_extensions; do 67994 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 67995 ac_cv_path_ICECC_CMD="$as_dir/$ac_word$ac_exec_ext" 67996 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 67997 break 2 67998 fi 67999 done 68000 done 68001 IFS=$as_save_IFS 68002 68003 ;; 68004 esac 68005 fi 68006 ICECC_CMD=$ac_cv_path_ICECC_CMD 68007 if test -n "$ICECC_CMD"; then 68008 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ICECC_CMD" >&5 68009 $as_echo "$ICECC_CMD" >&6; } 68010 else 68011 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 68012 $as_echo "no" >&6; } 68013 fi 68014 68015 68016 if test "x$ICECC_CMD" = x; then 68017 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 68018 fi 68019 else 68020 # Otherwise we believe it is a complete path. Use it as it is. 68021 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool ICECC_CMD=$tool_specified" >&5 68022 $as_echo "$as_me: Will use user supplied tool ICECC_CMD=$tool_specified" >&6;} 68023 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ICECC_CMD" >&5 68024 $as_echo_n "checking for ICECC_CMD... " >&6; } 68025 if test ! -x "$tool_specified"; then 68026 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 68027 $as_echo "not found" >&6; } 68028 as_fn_error $? "User supplied tool ICECC_CMD=$tool_specified does not exist or is not executable" "$LINENO" 5 68029 fi 68030 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 68031 $as_echo "$tool_specified" >&6; } 68032 fi 68033 fi 68034 fi 68035 68036 fi 68037 68038 68039 68040 if test "x$ICECC_CMD" = x; then 68041 as_fn_error $? "Could not find required tool for ICECC_CMD" "$LINENO" 5 68042 fi 68043 68044 68045 old_path="$PATH" 68046 68047 # Look for icecc-create-env in some known places 68048 PATH="$PATH:/usr/lib/icecc:/usr/lib64/icecc" 68049 68050 68051 68052 # Publish this variable in the help. 68053 68054 68055 if [ -z "${ICECC_CREATE_ENV+x}" ]; then 68056 # The variable is not set by user, try to locate tool using the code snippet 68057 for ac_prog in icecc-create-env 68058 do 68059 # Extract the first word of "$ac_prog", so it can be a program name with args. 68060 set dummy $ac_prog; ac_word=$2 68061 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 68062 $as_echo_n "checking for $ac_word... " >&6; } 68063 if ${ac_cv_path_ICECC_CREATE_ENV+:} false; then : 68064 $as_echo_n "(cached) " >&6 68065 else 68066 case $ICECC_CREATE_ENV in 68067 [\\/]* | ?:[\\/]*) 68068 ac_cv_path_ICECC_CREATE_ENV="$ICECC_CREATE_ENV" # Let the user override the test with a path. 68069 ;; 68070 *) 68071 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 68072 for as_dir in $PATH 68073 do 68074 IFS=$as_save_IFS 68075 test -z "$as_dir" && as_dir=. 68076 for ac_exec_ext in '' $ac_executable_extensions; do 68077 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 68078 ac_cv_path_ICECC_CREATE_ENV="$as_dir/$ac_word$ac_exec_ext" 68079 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 68080 break 2 68081 fi 68082 done 68083 done 68084 IFS=$as_save_IFS 68085 68086 ;; 68087 esac 68088 fi 68089 ICECC_CREATE_ENV=$ac_cv_path_ICECC_CREATE_ENV 68090 if test -n "$ICECC_CREATE_ENV"; then 68091 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ICECC_CREATE_ENV" >&5 68092 $as_echo "$ICECC_CREATE_ENV" >&6; } 68093 else 68094 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 68095 $as_echo "no" >&6; } 68096 fi 68097 68098 68099 test -n "$ICECC_CREATE_ENV" && break 68100 done 68101 68102 else 68103 # The variable is set, but is it from the command line or the environment? 68104 68105 # Try to remove the string !ICECC_CREATE_ENV! from our list. 68106 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!ICECC_CREATE_ENV!/} 68107 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 68108 # If it failed, the variable was not from the command line. Ignore it, 68109 # but warn the user (except for BASH, which is always set by the calling BASH). 68110 if test "xICECC_CREATE_ENV" != xBASH; then 68111 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of ICECC_CREATE_ENV from the environment. Use command line variables instead." >&5 68112 $as_echo "$as_me: WARNING: Ignoring value of ICECC_CREATE_ENV from the environment. Use command line variables instead." >&2;} 68113 fi 68114 # Try to locate tool using the code snippet 68115 for ac_prog in icecc-create-env 68116 do 68117 # Extract the first word of "$ac_prog", so it can be a program name with args. 68118 set dummy $ac_prog; ac_word=$2 68119 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 68120 $as_echo_n "checking for $ac_word... " >&6; } 68121 if ${ac_cv_path_ICECC_CREATE_ENV+:} false; then : 68122 $as_echo_n "(cached) " >&6 68123 else 68124 case $ICECC_CREATE_ENV in 68125 [\\/]* | ?:[\\/]*) 68126 ac_cv_path_ICECC_CREATE_ENV="$ICECC_CREATE_ENV" # Let the user override the test with a path. 68127 ;; 68128 *) 68129 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 68130 for as_dir in $PATH 68131 do 68132 IFS=$as_save_IFS 68133 test -z "$as_dir" && as_dir=. 68134 for ac_exec_ext in '' $ac_executable_extensions; do 68135 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 68136 ac_cv_path_ICECC_CREATE_ENV="$as_dir/$ac_word$ac_exec_ext" 68137 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 68138 break 2 68139 fi 68140 done 68141 done 68142 IFS=$as_save_IFS 68143 68144 ;; 68145 esac 68146 fi 68147 ICECC_CREATE_ENV=$ac_cv_path_ICECC_CREATE_ENV 68148 if test -n "$ICECC_CREATE_ENV"; then 68149 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ICECC_CREATE_ENV" >&5 68150 $as_echo "$ICECC_CREATE_ENV" >&6; } 68151 else 68152 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 68153 $as_echo "no" >&6; } 68154 fi 68155 68156 68157 test -n "$ICECC_CREATE_ENV" && break 68158 done 68159 68160 else 68161 # If it succeeded, then it was overridden by the user. We will use it 68162 # for the tool. 68163 68164 # First remove it from the list of overridden variables, so we can test 68165 # for unknown variables in the end. 68166 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 68167 68168 # Check if we try to supply an empty value 68169 if test "x$ICECC_CREATE_ENV" = x; then 68170 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool ICECC_CREATE_ENV= (no value)" >&5 68171 $as_echo "$as_me: Setting user supplied tool ICECC_CREATE_ENV= (no value)" >&6;} 68172 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ICECC_CREATE_ENV" >&5 68173 $as_echo_n "checking for ICECC_CREATE_ENV... " >&6; } 68174 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 68175 $as_echo "disabled" >&6; } 68176 else 68177 # Check if the provided tool contains a complete path. 68178 tool_specified="$ICECC_CREATE_ENV" 68179 tool_basename="${tool_specified##*/}" 68180 if test "x$tool_basename" = "x$tool_specified"; then 68181 # A command without a complete path is provided, search $PATH. 68182 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool ICECC_CREATE_ENV=$tool_basename" >&5 68183 $as_echo "$as_me: Will search for user supplied tool ICECC_CREATE_ENV=$tool_basename" >&6;} 68184 # Extract the first word of "$tool_basename", so it can be a program name with args. 68185 set dummy $tool_basename; ac_word=$2 68186 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 68187 $as_echo_n "checking for $ac_word... " >&6; } 68188 if ${ac_cv_path_ICECC_CREATE_ENV+:} false; then : 68189 $as_echo_n "(cached) " >&6 68190 else 68191 case $ICECC_CREATE_ENV in 68192 [\\/]* | ?:[\\/]*) 68193 ac_cv_path_ICECC_CREATE_ENV="$ICECC_CREATE_ENV" # Let the user override the test with a path. 68194 ;; 68195 *) 68196 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 68197 for as_dir in $PATH 68198 do 68199 IFS=$as_save_IFS 68200 test -z "$as_dir" && as_dir=. 68201 for ac_exec_ext in '' $ac_executable_extensions; do 68202 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 68203 ac_cv_path_ICECC_CREATE_ENV="$as_dir/$ac_word$ac_exec_ext" 68204 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 68205 break 2 68206 fi 68207 done 68208 done 68209 IFS=$as_save_IFS 68210 68211 ;; 68212 esac 68213 fi 68214 ICECC_CREATE_ENV=$ac_cv_path_ICECC_CREATE_ENV 68215 if test -n "$ICECC_CREATE_ENV"; then 68216 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ICECC_CREATE_ENV" >&5 68217 $as_echo "$ICECC_CREATE_ENV" >&6; } 68218 else 68219 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 68220 $as_echo "no" >&6; } 68221 fi 68222 68223 68224 if test "x$ICECC_CREATE_ENV" = x; then 68225 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 68226 fi 68227 else 68228 # Otherwise we believe it is a complete path. Use it as it is. 68229 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool ICECC_CREATE_ENV=$tool_specified" >&5 68230 $as_echo "$as_me: Will use user supplied tool ICECC_CREATE_ENV=$tool_specified" >&6;} 68231 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ICECC_CREATE_ENV" >&5 68232 $as_echo_n "checking for ICECC_CREATE_ENV... " >&6; } 68233 if test ! -x "$tool_specified"; then 68234 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 68235 $as_echo "not found" >&6; } 68236 as_fn_error $? "User supplied tool ICECC_CREATE_ENV=$tool_specified does not exist or is not executable" "$LINENO" 5 68237 fi 68238 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 68239 $as_echo "$tool_specified" >&6; } 68240 fi 68241 fi 68242 fi 68243 68244 fi 68245 68246 68247 68248 if test "x$ICECC_CREATE_ENV" = x; then 68249 as_fn_error $? "Could not find required tool for ICECC_CREATE_ENV" "$LINENO" 5 68250 fi 68251 68252 68253 # Use icecc-create-env to create a minimal compilation environment that can 68254 # be sent to the other hosts in the icecream cluster. 68255 icecc_create_env_log="${CONFIGURESUPPORT_OUTPUTDIR}/icecc/icecc_create_env.log" 68256 ${MKDIR} -p ${CONFIGURESUPPORT_OUTPUTDIR}/icecc 68257 # Older versions of icecc does not have the --gcc parameter 68258 if ${ICECC_CREATE_ENV} | $GREP -q -e --gcc; then 68259 icecc_gcc_arg="--gcc" 68260 fi 68261 if test "x${TOOLCHAIN_TYPE}" = "xgcc"; then 68262 68263 ( cd ${CONFIGURESUPPORT_OUTPUTDIR}/icecc \ 68264 && ${ICECC_CREATE_ENV} ${icecc_gcc_arg} ${CC} ${CXX} > \ 68265 ${icecc_create_env_log} 2>&1 ) 68266 if test "$?" != "0"; then 68267 { $as_echo "$as_me:${as_lineno-$LINENO}: icecc-create-env output:" >&5 68268 $as_echo "$as_me: icecc-create-env output:" >&6;} 68269 cat \ 68270 ${icecc_create_env_log} 68271 as_fn_error $? "Failed to create icecc compiler environment" "$LINENO" 5 68272 fi 68273 68274 elif test "x$TOOLCHAIN_TYPE" = "xclang"; then 68275 # For clang, the icecc compilerwrapper is needed. It usually resides next 68276 # to icecc-create-env. 68277 68278 68279 68280 # Publish this variable in the help. 68281 68282 68283 if [ -z "${ICECC_WRAPPER+x}" ]; then 68284 # The variable is not set by user, try to locate tool using the code snippet 68285 for ac_prog in compilerwrapper 68286 do 68287 # Extract the first word of "$ac_prog", so it can be a program name with args. 68288 set dummy $ac_prog; ac_word=$2 68289 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 68290 $as_echo_n "checking for $ac_word... " >&6; } 68291 if ${ac_cv_path_ICECC_WRAPPER+:} false; then : 68292 $as_echo_n "(cached) " >&6 68293 else 68294 case $ICECC_WRAPPER in 68295 [\\/]* | ?:[\\/]*) 68296 ac_cv_path_ICECC_WRAPPER="$ICECC_WRAPPER" # Let the user override the test with a path. 68297 ;; 68298 *) 68299 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 68300 for as_dir in $PATH 68301 do 68302 IFS=$as_save_IFS 68303 test -z "$as_dir" && as_dir=. 68304 for ac_exec_ext in '' $ac_executable_extensions; do 68305 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 68306 ac_cv_path_ICECC_WRAPPER="$as_dir/$ac_word$ac_exec_ext" 68307 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 68308 break 2 68309 fi 68310 done 68311 done 68312 IFS=$as_save_IFS 68313 68314 ;; 68315 esac 68316 fi 68317 ICECC_WRAPPER=$ac_cv_path_ICECC_WRAPPER 68318 if test -n "$ICECC_WRAPPER"; then 68319 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ICECC_WRAPPER" >&5 68320 $as_echo "$ICECC_WRAPPER" >&6; } 68321 else 68322 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 68323 $as_echo "no" >&6; } 68324 fi 68325 68326 68327 test -n "$ICECC_WRAPPER" && break 68328 done 68329 68330 else 68331 # The variable is set, but is it from the command line or the environment? 68332 68333 # Try to remove the string !ICECC_WRAPPER! from our list. 68334 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!ICECC_WRAPPER!/} 68335 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 68336 # If it failed, the variable was not from the command line. Ignore it, 68337 # but warn the user (except for BASH, which is always set by the calling BASH). 68338 if test "xICECC_WRAPPER" != xBASH; then 68339 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of ICECC_WRAPPER from the environment. Use command line variables instead." >&5 68340 $as_echo "$as_me: WARNING: Ignoring value of ICECC_WRAPPER from the environment. Use command line variables instead." >&2;} 68341 fi 68342 # Try to locate tool using the code snippet 68343 for ac_prog in compilerwrapper 68344 do 68345 # Extract the first word of "$ac_prog", so it can be a program name with args. 68346 set dummy $ac_prog; ac_word=$2 68347 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 68348 $as_echo_n "checking for $ac_word... " >&6; } 68349 if ${ac_cv_path_ICECC_WRAPPER+:} false; then : 68350 $as_echo_n "(cached) " >&6 68351 else 68352 case $ICECC_WRAPPER in 68353 [\\/]* | ?:[\\/]*) 68354 ac_cv_path_ICECC_WRAPPER="$ICECC_WRAPPER" # Let the user override the test with a path. 68355 ;; 68356 *) 68357 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 68358 for as_dir in $PATH 68359 do 68360 IFS=$as_save_IFS 68361 test -z "$as_dir" && as_dir=. 68362 for ac_exec_ext in '' $ac_executable_extensions; do 68363 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 68364 ac_cv_path_ICECC_WRAPPER="$as_dir/$ac_word$ac_exec_ext" 68365 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 68366 break 2 68367 fi 68368 done 68369 done 68370 IFS=$as_save_IFS 68371 68372 ;; 68373 esac 68374 fi 68375 ICECC_WRAPPER=$ac_cv_path_ICECC_WRAPPER 68376 if test -n "$ICECC_WRAPPER"; then 68377 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ICECC_WRAPPER" >&5 68378 $as_echo "$ICECC_WRAPPER" >&6; } 68379 else 68380 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 68381 $as_echo "no" >&6; } 68382 fi 68383 68384 68385 test -n "$ICECC_WRAPPER" && break 68386 done 68387 68388 else 68389 # If it succeeded, then it was overridden by the user. We will use it 68390 # for the tool. 68391 68392 # First remove it from the list of overridden variables, so we can test 68393 # for unknown variables in the end. 68394 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 68395 68396 # Check if we try to supply an empty value 68397 if test "x$ICECC_WRAPPER" = x; then 68398 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool ICECC_WRAPPER= (no value)" >&5 68399 $as_echo "$as_me: Setting user supplied tool ICECC_WRAPPER= (no value)" >&6;} 68400 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ICECC_WRAPPER" >&5 68401 $as_echo_n "checking for ICECC_WRAPPER... " >&6; } 68402 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 68403 $as_echo "disabled" >&6; } 68404 else 68405 # Check if the provided tool contains a complete path. 68406 tool_specified="$ICECC_WRAPPER" 68407 tool_basename="${tool_specified##*/}" 68408 if test "x$tool_basename" = "x$tool_specified"; then 68409 # A command without a complete path is provided, search $PATH. 68410 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool ICECC_WRAPPER=$tool_basename" >&5 68411 $as_echo "$as_me: Will search for user supplied tool ICECC_WRAPPER=$tool_basename" >&6;} 68412 # Extract the first word of "$tool_basename", so it can be a program name with args. 68413 set dummy $tool_basename; ac_word=$2 68414 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 68415 $as_echo_n "checking for $ac_word... " >&6; } 68416 if ${ac_cv_path_ICECC_WRAPPER+:} false; then : 68417 $as_echo_n "(cached) " >&6 68418 else 68419 case $ICECC_WRAPPER in 68420 [\\/]* | ?:[\\/]*) 68421 ac_cv_path_ICECC_WRAPPER="$ICECC_WRAPPER" # Let the user override the test with a path. 68422 ;; 68423 *) 68424 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 68425 for as_dir in $PATH 68426 do 68427 IFS=$as_save_IFS 68428 test -z "$as_dir" && as_dir=. 68429 for ac_exec_ext in '' $ac_executable_extensions; do 68430 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 68431 ac_cv_path_ICECC_WRAPPER="$as_dir/$ac_word$ac_exec_ext" 68432 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 68433 break 2 68434 fi 68435 done 68436 done 68437 IFS=$as_save_IFS 68438 68439 ;; 68440 esac 68441 fi 68442 ICECC_WRAPPER=$ac_cv_path_ICECC_WRAPPER 68443 if test -n "$ICECC_WRAPPER"; then 68444 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ICECC_WRAPPER" >&5 68445 $as_echo "$ICECC_WRAPPER" >&6; } 68446 else 68447 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 68448 $as_echo "no" >&6; } 68449 fi 68450 68451 68452 if test "x$ICECC_WRAPPER" = x; then 68453 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 68454 fi 68455 else 68456 # Otherwise we believe it is a complete path. Use it as it is. 68457 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool ICECC_WRAPPER=$tool_specified" >&5 68458 $as_echo "$as_me: Will use user supplied tool ICECC_WRAPPER=$tool_specified" >&6;} 68459 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ICECC_WRAPPER" >&5 68460 $as_echo_n "checking for ICECC_WRAPPER... " >&6; } 68461 if test ! -x "$tool_specified"; then 68462 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 68463 $as_echo "not found" >&6; } 68464 as_fn_error $? "User supplied tool ICECC_WRAPPER=$tool_specified does not exist or is not executable" "$LINENO" 5 68465 fi 68466 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 68467 $as_echo "$tool_specified" >&6; } 68468 fi 68469 fi 68470 fi 68471 68472 fi 68473 68474 68475 68476 if test "x$ICECC_WRAPPER" = x; then 68477 as_fn_error $? "Could not find required tool for ICECC_WRAPPER" "$LINENO" 5 68478 fi 68479 68480 68481 68482 ( cd ${CONFIGURESUPPORT_OUTPUTDIR}/icecc \ 68483 && ${ICECC_CREATE_ENV} --clang ${CC} ${ICECC_WRAPPER} > ${icecc_create_env_log} 2>&1 ) 68484 if test "$?" != "0"; then 68485 { $as_echo "$as_me:${as_lineno-$LINENO}: icecc-create-env output:" >&5 68486 $as_echo "$as_me: icecc-create-env output:" >&6;} 68487 cat ${icecc_create_env_log} 68488 as_fn_error $? "Failed to create icecc compiler environment" "$LINENO" 5 68489 fi 68490 68491 else 68492 as_fn_error $? "Can only create icecc compiler packages for toolchain types gcc and clang" "$LINENO" 5 68493 fi 68494 PATH="$old_path" 68495 # The bundle with the compiler gets a name based on checksums. Parse log file 68496 # to find it. 68497 ICECC_ENV_BUNDLE_BASENAME="`${SED} -n '/^creating/s/creating //p' ${icecc_create_env_log}`" 68498 ICECC_ENV_BUNDLE="${CONFIGURESUPPORT_OUTPUTDIR}/icecc/${ICECC_ENV_BUNDLE_BASENAME}" 68499 if test ! -f ${ICECC_ENV_BUNDLE}; then 68500 as_fn_error $? "icecc-create-env did not produce an environment ${ICECC_ENV_BUNDLE}" "$LINENO" 5 68501 fi 68502 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for icecc build environment for target compiler" >&5 68503 $as_echo_n "checking for icecc build environment for target compiler... " >&6; } 68504 { $as_echo "$as_me:${as_lineno-$LINENO}: result: ${ICECC_ENV_BUNDLE}" >&5 68505 $as_echo "${ICECC_ENV_BUNDLE}" >&6; } 68506 ICECC="ICECC_VERSION=${ICECC_ENV_BUNDLE} ICECC_CC=${CC} ICECC_CXX=${CXX} ${ICECC_CMD}" 68507 68508 if test "x${COMPILE_TYPE}" = "xcross"; then 68509 # If cross compiling, create a separate env package for the build compiler 68510 # Assume "gcc" or "cc" is gcc and "clang" is clang. Otherwise bail. 68511 icecc_create_env_log_build="${CONFIGURESUPPORT_OUTPUTDIR}/icecc/icecc_create_env_build.log" 68512 if test "x${BUILD_CC##*/}" = "xgcc" || test "x${BUILD_CC##*/}" = "xcc"; then 68513 68514 ( cd ${CONFIGURESUPPORT_OUTPUTDIR}/icecc \ 68515 && ${ICECC_CREATE_ENV} ${icecc_gcc_arg} ${BUILD_CC} ${BUILD_CXX} > \ 68516 ${icecc_create_env_log_build} 2>&1 ) 68517 if test "$?" != "0"; then 68518 { $as_echo "$as_me:${as_lineno-$LINENO}: icecc-create-env output:" >&5 68519 $as_echo "$as_me: icecc-create-env output:" >&6;} 68520 cat \ 68521 ${icecc_create_env_log_build} 68522 as_fn_error $? "Failed to create icecc compiler environment" "$LINENO" 5 68523 fi 68524 68525 elif test "x${BUILD_CC##*/}" = "xclang"; then 68526 68527 ( cd ${CONFIGURESUPPORT_OUTPUTDIR}/icecc \ 68528 && ${ICECC_CREATE_ENV} --clang ${BUILD_CC} ${ICECC_WRAPPER} > ${icecc_create_env_log_build} 2>&1 ) 68529 if test "$?" != "0"; then 68530 { $as_echo "$as_me:${as_lineno-$LINENO}: icecc-create-env output:" >&5 68531 $as_echo "$as_me: icecc-create-env output:" >&6;} 68532 cat ${icecc_create_env_log_build} 68533 as_fn_error $? "Failed to create icecc compiler environment" "$LINENO" 5 68534 fi 68535 68536 else 68537 as_fn_error $? "Cannot create icecc compiler package for ${BUILD_CC}" "$LINENO" 5 68538 fi 68539 ICECC_ENV_BUNDLE_BASENAME="`${SED} -n '/^creating/s/creating //p' ${icecc_create_env_log_build}`" 68540 ICECC_ENV_BUNDLE="${CONFIGURESUPPORT_OUTPUTDIR}/icecc/${ICECC_ENV_BUNDLE_BASENAME}" 68541 if test ! -f ${ICECC_ENV_BUNDLE}; then 68542 as_fn_error $? "icecc-create-env did not produce an environment ${ICECC_ENV_BUNDLE}" "$LINENO" 5 68543 fi 68544 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for icecc build environment for build compiler" >&5 68545 $as_echo_n "checking for icecc build environment for build compiler... " >&6; } 68546 { $as_echo "$as_me:${as_lineno-$LINENO}: result: ${ICECC_ENV_BUNDLE}" >&5 68547 $as_echo "${ICECC_ENV_BUNDLE}" >&6; } 68548 BUILD_ICECC="ICECC_VERSION=${ICECC_ENV_BUNDLE} ICECC_CC=${BUILD_CC} \ 68549 ICECC_CXX=${BUILD_CXX} ${ICECC_CMD}" 68550 else 68551 BUILD_ICECC="${ICECC}" 68552 fi 68553 68554 68555 fi 68556 68557 68558 # Can the C/C++ compiler use precompiled headers? 68559 68560 68561 ############################################################################### 68562 # 68563 # Can the C/C++ compiler use precompiled headers? 68564 # 68565 # Check whether --enable-precompiled-headers was given. 68566 if test "${enable_precompiled_headers+set}" = set; then : 68567 enableval=$enable_precompiled_headers; ENABLE_PRECOMPH=${enable_precompiled_headers} 68568 else 68569 ENABLE_PRECOMPH=yes 68570 fi 68571 68572 68573 USE_PRECOMPILED_HEADER=true 68574 { $as_echo "$as_me:${as_lineno-$LINENO}: checking If precompiled header is enabled" >&5 68575 $as_echo_n "checking If precompiled header is enabled... " >&6; } 68576 if test "x$ENABLE_PRECOMPH" = xno; then 68577 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no, forced" >&5 68578 $as_echo "no, forced" >&6; } 68579 USE_PRECOMPILED_HEADER=false 68580 elif test "x$ICECC" != "x"; then 68581 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no, does not work effectively with icecc" >&5 68582 $as_echo "no, does not work effectively with icecc" >&6; } 68583 USE_PRECOMPILED_HEADER=false 68584 elif test "x$TOOLCHAIN_TYPE" = xsolstudio; then 68585 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no, does not work with Solaris Studio" >&5 68586 $as_echo "no, does not work with Solaris Studio" >&6; } 68587 USE_PRECOMPILED_HEADER=false 68588 elif test "x$TOOLCHAIN_TYPE" = xxlc; then 68589 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no, does not work with xlc" >&5 68590 $as_echo "no, does not work with xlc" >&6; } 68591 USE_PRECOMPILED_HEADER=false 68592 else 68593 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 68594 $as_echo "yes" >&6; } 68595 fi 68596 68597 if test "x$ENABLE_PRECOMPH" = xyes; then 68598 # Check that the compiler actually supports precomp headers. 68599 if test "x$TOOLCHAIN_TYPE" = xgcc; then 68600 { $as_echo "$as_me:${as_lineno-$LINENO}: checking that precompiled headers work" >&5 68601 $as_echo_n "checking that precompiled headers work... " >&6; } 68602 echo "int alfa();" > conftest.h 68603 $CXX -x c++-header conftest.h -o conftest.hpp.gch 2>&5 >&5 68604 if test ! -f conftest.hpp.gch; then 68605 USE_PRECOMPILED_HEADER=false 68606 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 68607 $as_echo "no" >&6; } 68608 else 68609 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 68610 $as_echo "yes" >&6; } 68611 fi 68612 $RM conftest.h conftest.hpp.gch 68613 fi 68614 fi 68615 68616 68617 68618 68619 # Setup use of ccache, if available 68620 68621 # Check whether --enable-ccache was given. 68622 if test "${enable_ccache+set}" = set; then : 68623 enableval=$enable_ccache; 68624 fi 68625 68626 68627 CCACHE_STATUS= 68628 { $as_echo "$as_me:${as_lineno-$LINENO}: checking is ccache enabled" >&5 68629 $as_echo_n "checking is ccache enabled... " >&6; } 68630 if test "x$enable_ccache" = xyes; then 68631 if test "x$TOOLCHAIN_TYPE" = "xgcc" -o "x$TOOLCHAIN_TYPE" = "xclang"; then 68632 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 68633 $as_echo "yes" >&6; } 68634 OLD_PATH="$PATH" 68635 if test "x$TOOLCHAIN_PATH" != x; then 68636 PATH=$TOOLCHAIN_PATH:$PATH 68637 fi 68638 68639 68640 68641 # Publish this variable in the help. 68642 68643 68644 if [ -z "${CCACHE+x}" ]; then 68645 # The variable is not set by user, try to locate tool using the code snippet 68646 for ac_prog in ccache 68647 do 68648 # Extract the first word of "$ac_prog", so it can be a program name with args. 68649 set dummy $ac_prog; ac_word=$2 68650 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 68651 $as_echo_n "checking for $ac_word... " >&6; } 68652 if ${ac_cv_path_CCACHE+:} false; then : 68653 $as_echo_n "(cached) " >&6 68654 else 68655 case $CCACHE in 68656 [\\/]* | ?:[\\/]*) 68657 ac_cv_path_CCACHE="$CCACHE" # Let the user override the test with a path. 68658 ;; 68659 *) 68660 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 68661 for as_dir in $PATH 68662 do 68663 IFS=$as_save_IFS 68664 test -z "$as_dir" && as_dir=. 68665 for ac_exec_ext in '' $ac_executable_extensions; do 68666 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 68667 ac_cv_path_CCACHE="$as_dir/$ac_word$ac_exec_ext" 68668 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 68669 break 2 68670 fi 68671 done 68672 done 68673 IFS=$as_save_IFS 68674 68675 ;; 68676 esac 68677 fi 68678 CCACHE=$ac_cv_path_CCACHE 68679 if test -n "$CCACHE"; then 68680 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CCACHE" >&5 68681 $as_echo "$CCACHE" >&6; } 68682 else 68683 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 68684 $as_echo "no" >&6; } 68685 fi 68686 68687 68688 test -n "$CCACHE" && break 68689 done 68690 68691 else 68692 # The variable is set, but is it from the command line or the environment? 68693 68694 # Try to remove the string !CCACHE! from our list. 68695 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!CCACHE!/} 68696 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 68697 # If it failed, the variable was not from the command line. Ignore it, 68698 # but warn the user (except for BASH, which is always set by the calling BASH). 68699 if test "xCCACHE" != xBASH; then 68700 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of CCACHE from the environment. Use command line variables instead." >&5 68701 $as_echo "$as_me: WARNING: Ignoring value of CCACHE from the environment. Use command line variables instead." >&2;} 68702 fi 68703 # Try to locate tool using the code snippet 68704 for ac_prog in ccache 68705 do 68706 # Extract the first word of "$ac_prog", so it can be a program name with args. 68707 set dummy $ac_prog; ac_word=$2 68708 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 68709 $as_echo_n "checking for $ac_word... " >&6; } 68710 if ${ac_cv_path_CCACHE+:} false; then : 68711 $as_echo_n "(cached) " >&6 68712 else 68713 case $CCACHE in 68714 [\\/]* | ?:[\\/]*) 68715 ac_cv_path_CCACHE="$CCACHE" # Let the user override the test with a path. 68716 ;; 68717 *) 68718 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 68719 for as_dir in $PATH 68720 do 68721 IFS=$as_save_IFS 68722 test -z "$as_dir" && as_dir=. 68723 for ac_exec_ext in '' $ac_executable_extensions; do 68724 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 68725 ac_cv_path_CCACHE="$as_dir/$ac_word$ac_exec_ext" 68726 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 68727 break 2 68728 fi 68729 done 68730 done 68731 IFS=$as_save_IFS 68732 68733 ;; 68734 esac 68735 fi 68736 CCACHE=$ac_cv_path_CCACHE 68737 if test -n "$CCACHE"; then 68738 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CCACHE" >&5 68739 $as_echo "$CCACHE" >&6; } 68740 else 68741 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 68742 $as_echo "no" >&6; } 68743 fi 68744 68745 68746 test -n "$CCACHE" && break 68747 done 68748 68749 else 68750 # If it succeeded, then it was overridden by the user. We will use it 68751 # for the tool. 68752 68753 # First remove it from the list of overridden variables, so we can test 68754 # for unknown variables in the end. 68755 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 68756 68757 # Check if we try to supply an empty value 68758 if test "x$CCACHE" = x; then 68759 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool CCACHE= (no value)" >&5 68760 $as_echo "$as_me: Setting user supplied tool CCACHE= (no value)" >&6;} 68761 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for CCACHE" >&5 68762 $as_echo_n "checking for CCACHE... " >&6; } 68763 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 68764 $as_echo "disabled" >&6; } 68765 else 68766 # Check if the provided tool contains a complete path. 68767 tool_specified="$CCACHE" 68768 tool_basename="${tool_specified##*/}" 68769 if test "x$tool_basename" = "x$tool_specified"; then 68770 # A command without a complete path is provided, search $PATH. 68771 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool CCACHE=$tool_basename" >&5 68772 $as_echo "$as_me: Will search for user supplied tool CCACHE=$tool_basename" >&6;} 68773 # Extract the first word of "$tool_basename", so it can be a program name with args. 68774 set dummy $tool_basename; ac_word=$2 68775 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 68776 $as_echo_n "checking for $ac_word... " >&6; } 68777 if ${ac_cv_path_CCACHE+:} false; then : 68778 $as_echo_n "(cached) " >&6 68779 else 68780 case $CCACHE in 68781 [\\/]* | ?:[\\/]*) 68782 ac_cv_path_CCACHE="$CCACHE" # Let the user override the test with a path. 68783 ;; 68784 *) 68785 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 68786 for as_dir in $PATH 68787 do 68788 IFS=$as_save_IFS 68789 test -z "$as_dir" && as_dir=. 68790 for ac_exec_ext in '' $ac_executable_extensions; do 68791 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 68792 ac_cv_path_CCACHE="$as_dir/$ac_word$ac_exec_ext" 68793 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 68794 break 2 68795 fi 68796 done 68797 done 68798 IFS=$as_save_IFS 68799 68800 ;; 68801 esac 68802 fi 68803 CCACHE=$ac_cv_path_CCACHE 68804 if test -n "$CCACHE"; then 68805 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CCACHE" >&5 68806 $as_echo "$CCACHE" >&6; } 68807 else 68808 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 68809 $as_echo "no" >&6; } 68810 fi 68811 68812 68813 if test "x$CCACHE" = x; then 68814 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 68815 fi 68816 else 68817 # Otherwise we believe it is a complete path. Use it as it is. 68818 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool CCACHE=$tool_specified" >&5 68819 $as_echo "$as_me: Will use user supplied tool CCACHE=$tool_specified" >&6;} 68820 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for CCACHE" >&5 68821 $as_echo_n "checking for CCACHE... " >&6; } 68822 if test ! -x "$tool_specified"; then 68823 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 68824 $as_echo "not found" >&6; } 68825 as_fn_error $? "User supplied tool CCACHE=$tool_specified does not exist or is not executable" "$LINENO" 5 68826 fi 68827 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 68828 $as_echo "$tool_specified" >&6; } 68829 fi 68830 fi 68831 fi 68832 68833 fi 68834 68835 68836 68837 if test "x$CCACHE" = x; then 68838 as_fn_error $? "Could not find required tool for CCACHE" "$LINENO" 5 68839 fi 68840 68841 68842 PATH="$OLD_PATH" 68843 CCACHE_VERSION=`$CCACHE --version | head -n1 | $SED 's/[A-Za-z ]*//'` 68844 CCACHE_STATUS="Active ($CCACHE_VERSION)" 68845 else 68846 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 68847 $as_echo "no" >&6; } 68848 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: ccache is not supported with toolchain type $TOOLCHAIN_TYPE" >&5 68849 $as_echo "$as_me: WARNING: ccache is not supported with toolchain type $TOOLCHAIN_TYPE" >&2;} 68850 fi 68851 elif test "x$enable_ccache" = xno; then 68852 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no, explicitly disabled" >&5 68853 $as_echo "no, explicitly disabled" >&6; } 68854 CCACHE_STATUS="Disabled" 68855 elif test "x$enable_ccache" = x; then 68856 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 68857 $as_echo "no" >&6; } 68858 else 68859 { $as_echo "$as_me:${as_lineno-$LINENO}: result: unknown" >&5 68860 $as_echo "unknown" >&6; } 68861 as_fn_error $? "--enable-ccache does not accept any parameters" "$LINENO" 5 68862 fi 68863 68864 68865 68866 # Check whether --with-ccache-dir was given. 68867 if test "${with_ccache_dir+set}" = set; then : 68868 withval=$with_ccache_dir; 68869 fi 68870 68871 68872 if test "x$with_ccache_dir" != x; then 68873 # When using a non home ccache directory, assume the use is to share ccache files 68874 # with other users. Thus change the umask. 68875 SET_CCACHE_DIR="CCACHE_DIR=$with_ccache_dir CCACHE_UMASK=002" 68876 if test "x$CCACHE" = x; then 68877 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: --with-ccache-dir has no meaning when ccache is not enabled" >&5 68878 $as_echo "$as_me: WARNING: --with-ccache-dir has no meaning when ccache is not enabled" >&2;} 68879 fi 68880 fi 68881 68882 if test "x$CCACHE" != x; then 68883 68884 if test "x$CCACHE" != x; then 68885 if test "x$OPENJDK_BUILD_OS" = "xmacosx"; then 68886 HAS_BAD_CCACHE=`$ECHO $CCACHE_VERSION | \ 68887 $GREP -e '^1\.' -e '^2\.' -e '^3\.0\.' -e '^3\.1\.'` 68888 if test "x$HAS_BAD_CCACHE" != "x"; then 68889 as_fn_error $? "On macosx, ccache 3.2 or later is required, found $CCACHE_VERSION" "$LINENO" 5 68890 fi 68891 fi 68892 if test "x$USE_PRECOMPILED_HEADER" = "xtrue"; then 68893 HAS_BAD_CCACHE=`$ECHO $CCACHE_VERSION | \ 68894 $GREP -e '^1.*' -e '^2.*' -e '^3\.0.*' -e '^3\.1\.[0123]$'` 68895 if test "x$HAS_BAD_CCACHE" != "x"; then 68896 as_fn_error $? "Precompiled headers requires ccache 3.1.4 or later, found $CCACHE_VERSION" "$LINENO" 5 68897 fi 68898 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if C-compiler supports ccache precompiled headers" >&5 68899 $as_echo_n "checking if C-compiler supports ccache precompiled headers... " >&6; } 68900 CCACHE_PRECOMP_FLAG="-fpch-preprocess" 68901 PUSHED_FLAGS="$CXXFLAGS" 68902 CXXFLAGS="$CCACHE_PRECOMP_FLAG $CXXFLAGS" 68903 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 68904 /* end confdefs.h. */ 68905 68906 int 68907 main () 68908 { 68909 68910 ; 68911 return 0; 68912 } 68913 _ACEOF 68914 if ac_fn_cxx_try_compile "$LINENO"; then : 68915 CC_KNOWS_CCACHE_TRICK=yes 68916 else 68917 CC_KNOWS_CCACHE_TRICK=no 68918 fi 68919 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext 68920 CXXFLAGS="$PUSHED_FLAGS" 68921 if test "x$CC_KNOWS_CCACHE_TRICK" = xyes; then 68922 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 68923 $as_echo "yes" >&6; } 68924 CFLAGS_CCACHE="$CCACHE_PRECOMP_FLAG" 68925 68926 CCACHE_SLOPPINESS=pch_defines,time_macros 68927 else 68928 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 68929 $as_echo "no" >&6; } 68930 as_fn_error $? "Cannot use ccache with precompiled headers without compiler support for $CCACHE_PRECOMP_FLAG" "$LINENO" 5 68931 fi 68932 fi 68933 68934 CCACHE="CCACHE_COMPRESS=1 $SET_CCACHE_DIR \ 68935 CCACHE_SLOPPINESS=$CCACHE_SLOPPINESS CCACHE_BASEDIR=$TOPDIR $CCACHE" 68936 68937 if test "x$SET_CCACHE_DIR" != x; then 68938 mkdir -p $CCACHE_DIR > /dev/null 2>&1 68939 chmod a+rwxs $CCACHE_DIR > /dev/null 2>&1 68940 fi 68941 fi 68942 68943 fi 68944 68945 68946 ############################################################################### 68947 # 68948 # And now the finish... 68949 # 68950 ############################################################################### 68951 68952 # Check for some common pitfalls 68953 68954 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 68955 file_to_test="$TOPDIR/LICENSE" 68956 if test `$STAT -c '%a' "$file_to_test"` -lt 400; then 68957 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 68958 fi 68959 fi 68960 68961 68962 # Did user specify any unknown variables? 68963 68964 if test "x$CONFIGURE_OVERRIDDEN_VARIABLES" != x; then 68965 # Replace the separating ! with spaces before presenting for end user. 68966 unknown_variables=${CONFIGURE_OVERRIDDEN_VARIABLES//!/ } 68967 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: The following variables might be unknown to configure: $unknown_variables" >&5 68968 $as_echo "$as_me: WARNING: The following variables might be unknown to configure: $unknown_variables" >&2;} 68969 fi 68970 68971 68972 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if build directory is on local disk" >&5 68973 $as_echo_n "checking if build directory is on local disk... " >&6; } 68974 68975 # df -l lists only local disks; if the given directory is not found then 68976 # a non-zero exit code is given 68977 if test "x$DF" = x; then 68978 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 68979 # msys does not have df; use Windows "net use" instead. 68980 IS_NETWORK_DISK=`net use | grep \`pwd -W | cut -d ":" -f 1 | tr a-z A-Z\`:` 68981 if test "x$IS_NETWORK_DISK" = x; then 68982 OUTPUT_DIR_IS_LOCAL="yes" 68983 else 68984 OUTPUT_DIR_IS_LOCAL="no" 68985 fi 68986 else 68987 # No df here, say it's local 68988 OUTPUT_DIR_IS_LOCAL="yes" 68989 fi 68990 else 68991 # JDK-8189619 68992 # df on AIX does not understand -l. On modern AIXes it understands "-T local" which 68993 # is the same. On older AIXes we just continue to live with a "not local build" warning. 68994 if test "x$OPENJDK_TARGET_OS" = xaix; then 68995 DF_LOCAL_ONLY_OPTION='-T local' 68996 else 68997 DF_LOCAL_ONLY_OPTION='-l' 68998 fi 68999 if $DF $DF_LOCAL_ONLY_OPTION $OUTPUTDIR > /dev/null 2>&1; then 69000 OUTPUT_DIR_IS_LOCAL="yes" 69001 else 69002 OUTPUT_DIR_IS_LOCAL="no" 69003 fi 69004 fi 69005 69006 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $OUTPUT_DIR_IS_LOCAL" >&5 69007 $as_echo "$OUTPUT_DIR_IS_LOCAL" >&6; } 69008 69009 69010 69011 # Check if the user has any old-style ALT_ variables set. 69012 FOUND_ALT_VARIABLES=`env | grep ^ALT_` 69013 69014 # Before generating output files, test if they exist. If they do, this is a reconfigure. 69015 # Since we can't properly handle the dependencies for this, warn the user about the situation 69016 if test -e $OUTPUTDIR/spec.gmk; then 69017 IS_RECONFIGURE=yes 69018 else 69019 IS_RECONFIGURE=no 69020 fi 69021 69022 69023 # At the end, call the custom hook. (Dummy macro if no custom sources available) 69024 69025 69026 # This needs to be done after CUSTOM_LATE_HOOK since we can setup custom features. 69027 69028 # Keep feature lists sorted and free of duplicates 69029 JVM_FEATURES_server="$($ECHO $($PRINTF '%s\n' $JVM_FEATURES_server | $SORT -u))" 69030 JVM_FEATURES_client="$($ECHO $($PRINTF '%s\n' $JVM_FEATURES_client | $SORT -u))" 69031 JVM_FEATURES_core="$($ECHO $($PRINTF '%s\n' $JVM_FEATURES_core | $SORT -u))" 69032 JVM_FEATURES_minimal="$($ECHO $($PRINTF '%s\n' $JVM_FEATURES_minimal | $SORT -u))" 69033 JVM_FEATURES_zero="$($ECHO $($PRINTF '%s\n' $JVM_FEATURES_zero | $SORT -u))" 69034 JVM_FEATURES_custom="$($ECHO $($PRINTF '%s\n' $JVM_FEATURES_custom | $SORT -u))" 69035 69036 # Validate features 69037 for variant in $JVM_VARIANTS; do 69038 { $as_echo "$as_me:${as_lineno-$LINENO}: checking JVM features for JVM variant '$variant'" >&5 69039 $as_echo_n "checking JVM features for JVM variant '$variant'... " >&6; } 69040 features_var_name=JVM_FEATURES_$variant 69041 JVM_FEATURES_TO_TEST=${!features_var_name} 69042 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $JVM_FEATURES_TO_TEST" >&5 69043 $as_echo "$JVM_FEATURES_TO_TEST" >&6; } 69044 NEEDLE=${VALID_JVM_FEATURES// /$'\n'} 69045 STACK=${JVM_FEATURES_TO_TEST// /$'\n'} 69046 INVALID_FEATURES=`$GREP -Fvx "${NEEDLE}" <<< "${STACK}"` 69047 if test "x$INVALID_FEATURES" != x; then 69048 as_fn_error $? "Invalid JVM feature(s): $INVALID_FEATURES" "$LINENO" 5 69049 fi 69050 done 69051 69052 69053 # We're messing a bit with internal autoconf variables to put the config.status 69054 # in the output directory instead of the current directory. 69055 CONFIG_STATUS="$CONFIGURESUPPORT_OUTPUTDIR/config.status" 69056 69057 # Create the actual output files. Now the main work of configure is done. 69058 cat >confcache <<\_ACEOF 69059 # This file is a shell script that caches the results of configure 69060 # tests run on this system so they can be shared between configure 69061 # scripts and configure runs, see configure's option --config-cache. 69062 # It is not useful on other systems. If it contains results you don't 69063 # want to keep, you may remove or edit it. 69064 # 69065 # config.status only pays attention to the cache file if you give it 69066 # the --recheck option to rerun configure. 69067 # 69068 # `ac_cv_env_foo' variables (set or unset) will be overridden when 69069 # loading this file, other *unset* `ac_cv_foo' will be assigned the 69070 # following values. 69071 69072 _ACEOF 69073 69074 # The following way of writing the cache mishandles newlines in values, 69075 # but we know of no workaround that is simple, portable, and efficient. 69076 # So, we kill variables containing newlines. 69077 # Ultrix sh set writes to stderr and can't be redirected directly, 69078 # and sets the high bit in the cache file unless we assign to the vars. 69079 ( 69080 for ac_var in `(set) 2>&1 | sed -n 's/^\([a-zA-Z_][a-zA-Z0-9_]*\)=.*/\1/p'`; do 69081 eval ac_val=\$$ac_var 69082 case $ac_val in #( 69083 *${as_nl}*) 69084 case $ac_var in #( 69085 *_cv_*) { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: cache variable $ac_var contains a newline" >&5 69086 $as_echo "$as_me: WARNING: cache variable $ac_var contains a newline" >&2;} ;; 69087 esac 69088 case $ac_var in #( 69089 _ | IFS | as_nl) ;; #( 69090 BASH_ARGV | BASH_SOURCE) eval $ac_var= ;; #( 69091 *) { eval $ac_var=; unset $ac_var;} ;; 69092 esac ;; 69093 esac 69094 done 69095 69096 (set) 2>&1 | 69097 case $as_nl`(ac_space=' '; set) 2>&1` in #( 69098 *${as_nl}ac_space=\ *) 69099 # `set' does not quote correctly, so add quotes: double-quote 69100 # substitution turns \\\\ into \\, and sed turns \\ into \. 69101 sed -n \ 69102 "s/'/'\\\\''/g; 69103 s/^\\([_$as_cr_alnum]*_cv_[_$as_cr_alnum]*\\)=\\(.*\\)/\\1='\\2'/p" 69104 ;; #( 69105 *) 69106 # `set' quotes correctly as required by POSIX, so do not add quotes. 69107 sed -n "/^[_$as_cr_alnum]*_cv_[_$as_cr_alnum]*=/p" 69108 ;; 69109 esac | 69110 sort 69111 ) | 69112 sed ' 69113 /^ac_cv_env_/b end 69114 t clear 69115 :clear 69116 s/^\([^=]*\)=\(.*[{}].*\)$/test "${\1+set}" = set || &/ 69117 t end 69118 s/^\([^=]*\)=\(.*\)$/\1=${\1=\2}/ 69119 :end' >>confcache 69120 if diff "$cache_file" confcache >/dev/null 2>&1; then :; else 69121 if test -w "$cache_file"; then 69122 if test "x$cache_file" != "x/dev/null"; then 69123 { $as_echo "$as_me:${as_lineno-$LINENO}: updating cache $cache_file" >&5 69124 $as_echo "$as_me: updating cache $cache_file" >&6;} 69125 if test ! -f "$cache_file" || test -h "$cache_file"; then 69126 cat confcache >"$cache_file" 69127 else 69128 case $cache_file in #( 69129 */* | ?:*) 69130 mv -f confcache "$cache_file"$$ && 69131 mv -f "$cache_file"$$ "$cache_file" ;; #( 69132 *) 69133 mv -f confcache "$cache_file" ;; 69134 esac 69135 fi 69136 fi 69137 else 69138 { $as_echo "$as_me:${as_lineno-$LINENO}: not updating unwritable cache $cache_file" >&5 69139 $as_echo "$as_me: not updating unwritable cache $cache_file" >&6;} 69140 fi 69141 fi 69142 rm -f confcache 69143 69144 test "x$prefix" = xNONE && prefix=$ac_default_prefix 69145 # Let make expand exec_prefix. 69146 test "x$exec_prefix" = xNONE && exec_prefix='${prefix}' 69147 69148 # Transform confdefs.h into DEFS. 69149 # Protect against shell expansion while executing Makefile rules. 69150 # Protect against Makefile macro expansion. 69151 # 69152 # If the first sed substitution is executed (which looks for macros that 69153 # take arguments), then branch to the quote section. Otherwise, 69154 # look for a macro that doesn't take arguments. 69155 ac_script=' 69156 :mline 69157 /\\$/{ 69158 N 69159 s,\\\n,, 69160 b mline 69161 } 69162 t clear 69163 :clear 69164 s/^[ ]*#[ ]*define[ ][ ]*\([^ (][^ (]*([^)]*)\)[ ]*\(.*\)/-D\1=\2/g 69165 t quote 69166 s/^[ ]*#[ ]*define[ ][ ]*\([^ ][^ ]*\)[ ]*\(.*\)/-D\1=\2/g 69167 t quote 69168 b any 69169 :quote 69170 s/[ `~#$^&*(){}\\|;'\''"<>?]/\\&/g 69171 s/\[/\\&/g 69172 s/\]/\\&/g 69173 s/\$/$$/g 69174 H 69175 :any 69176 ${ 69177 g 69178 s/^\n// 69179 s/\n/ /g 69180 p 69181 } 69182 ' 69183 DEFS=`sed -n "$ac_script" confdefs.h` 69184 69185 69186 ac_libobjs= 69187 ac_ltlibobjs= 69188 U= 69189 for ac_i in : $LIBOBJS; do test "x$ac_i" = x: && continue 69190 # 1. Remove the extension, and $U if already installed. 69191 ac_script='s/\$U\././;s/\.o$//;s/\.obj$//' 69192 ac_i=`$as_echo "$ac_i" | sed "$ac_script"` 69193 # 2. Prepend LIBOBJDIR. When used with automake>=1.10 LIBOBJDIR 69194 # will be set to the directory where LIBOBJS objects are built. 69195 as_fn_append ac_libobjs " \${LIBOBJDIR}$ac_i\$U.$ac_objext" 69196 as_fn_append ac_ltlibobjs " \${LIBOBJDIR}$ac_i"'$U.lo' 69197 done 69198 LIBOBJS=$ac_libobjs 69199 69200 LTLIBOBJS=$ac_ltlibobjs 69201 69202 69203 69204 : "${CONFIG_STATUS=./config.status}" 69205 ac_write_fail=0 69206 ac_clean_files_save=$ac_clean_files 69207 ac_clean_files="$ac_clean_files $CONFIG_STATUS" 69208 { $as_echo "$as_me:${as_lineno-$LINENO}: creating $CONFIG_STATUS" >&5 69209 $as_echo "$as_me: creating $CONFIG_STATUS" >&6;} 69210 as_write_fail=0 69211 cat >$CONFIG_STATUS <<_ASEOF || as_write_fail=1 69212 #! $SHELL 69213 # Generated by $as_me. 69214 # Run this file to recreate the current configuration. 69215 # Compiler output produced by configure, useful for debugging 69216 # configure, is in config.log if it exists. 69217 69218 debug=false 69219 ac_cs_recheck=false 69220 ac_cs_silent=false 69221 69222 SHELL=\${CONFIG_SHELL-$SHELL} 69223 export SHELL 69224 _ASEOF 69225 cat >>$CONFIG_STATUS <<\_ASEOF || as_write_fail=1 69226 ## -------------------- ## 69227 ## M4sh Initialization. ## 69228 ## -------------------- ## 69229 69230 # Be more Bourne compatible 69231 DUALCASE=1; export DUALCASE # for MKS sh 69232 if test -n "${ZSH_VERSION+set}" && (emulate sh) >/dev/null 2>&1; then : 69233 emulate sh 69234 NULLCMD=: 69235 # Pre-4.2 versions of Zsh do word splitting on ${1+"$@"}, which 69236 # is contrary to our usage. Disable this feature. 69237 alias -g '${1+"$@"}'='"$@"' 69238 setopt NO_GLOB_SUBST 69239 else 69240 case `(set -o) 2>/dev/null` in #( 69241 *posix*) : 69242 set -o posix ;; #( 69243 *) : 69244 ;; 69245 esac 69246 fi 69247 69248 69249 as_nl=' 69250 ' 69251 export as_nl 69252 # Printing a long string crashes Solaris 7 /usr/bin/printf. 69253 as_echo='\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\' 69254 as_echo=$as_echo$as_echo$as_echo$as_echo$as_echo 69255 as_echo=$as_echo$as_echo$as_echo$as_echo$as_echo$as_echo 69256 # Prefer a ksh shell builtin over an external printf program on Solaris, 69257 # but without wasting forks for bash or zsh. 69258 if test -z "$BASH_VERSION$ZSH_VERSION" \ 69259 && (test "X`print -r -- $as_echo`" = "X$as_echo") 2>/dev/null; then 69260 as_echo='print -r --' 69261 as_echo_n='print -rn --' 69262 elif (test "X`printf %s $as_echo`" = "X$as_echo") 2>/dev/null; then 69263 as_echo='printf %s\n' 69264 as_echo_n='printf %s' 69265 else 69266 if test "X`(/usr/ucb/echo -n -n $as_echo) 2>/dev/null`" = "X-n $as_echo"; then 69267 as_echo_body='eval /usr/ucb/echo -n "$1$as_nl"' 69268 as_echo_n='/usr/ucb/echo -n' 69269 else 69270 as_echo_body='eval expr "X$1" : "X\\(.*\\)"' 69271 as_echo_n_body='eval 69272 arg=$1; 69273 case $arg in #( 69274 *"$as_nl"*) 69275 expr "X$arg" : "X\\(.*\\)$as_nl"; 69276 arg=`expr "X$arg" : ".*$as_nl\\(.*\\)"`;; 69277 esac; 69278 expr "X$arg" : "X\\(.*\\)" | tr -d "$as_nl" 69279 ' 69280 export as_echo_n_body 69281 as_echo_n='sh -c $as_echo_n_body as_echo' 69282 fi 69283 export as_echo_body 69284 as_echo='sh -c $as_echo_body as_echo' 69285 fi 69286 69287 # The user is always right. 69288 if test "${PATH_SEPARATOR+set}" != set; then 69289 PATH_SEPARATOR=: 69290 (PATH='/bin;/bin'; FPATH=$PATH; sh -c :) >/dev/null 2>&1 && { 69291 (PATH='/bin:/bin'; FPATH=$PATH; sh -c :) >/dev/null 2>&1 || 69292 PATH_SEPARATOR=';' 69293 } 69294 fi 69295 69296 69297 # IFS 69298 # We need space, tab and new line, in precisely that order. Quoting is 69299 # there to prevent editors from complaining about space-tab. 69300 # (If _AS_PATH_WALK were called with IFS unset, it would disable word 69301 # splitting by setting IFS to empty value.) 69302 IFS=" "" $as_nl" 69303 69304 # Find who we are. Look in the path if we contain no directory separator. 69305 as_myself= 69306 case $0 in #(( 69307 *[\\/]* ) as_myself=$0 ;; 69308 *) as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 69309 for as_dir in $PATH 69310 do 69311 IFS=$as_save_IFS 69312 test -z "$as_dir" && as_dir=. 69313 test -r "$as_dir/$0" && as_myself=$as_dir/$0 && break 69314 done 69315 IFS=$as_save_IFS 69316 69317 ;; 69318 esac 69319 # We did not find ourselves, most probably we were run as `sh COMMAND' 69320 # in which case we are not to be found in the path. 69321 if test "x$as_myself" = x; then 69322 as_myself=$0 69323 fi 69324 if test ! -f "$as_myself"; then 69325 $as_echo "$as_myself: error: cannot find myself; rerun with an absolute file name" >&2 69326 exit 1 69327 fi 69328 69329 # Unset variables that we do not need and which cause bugs (e.g. in 69330 # pre-3.0 UWIN ksh). But do not cause bugs in bash 2.01; the "|| exit 1" 69331 # suppresses any "Segmentation fault" message there. '((' could 69332 # trigger a bug in pdksh 5.2.14. 69333 for as_var in BASH_ENV ENV MAIL MAILPATH 69334 do eval test x\${$as_var+set} = xset \ 69335 && ( (unset $as_var) || exit 1) >/dev/null 2>&1 && unset $as_var || : 69336 done 69337 PS1='$ ' 69338 PS2='> ' 69339 PS4='+ ' 69340 69341 # NLS nuisances. 69342 LC_ALL=C 69343 export LC_ALL 69344 LANGUAGE=C 69345 export LANGUAGE 69346 69347 # CDPATH. 69348 (unset CDPATH) >/dev/null 2>&1 && unset CDPATH 69349 69350 69351 # as_fn_error STATUS ERROR [LINENO LOG_FD] 69352 # ---------------------------------------- 69353 # Output "`basename $0`: error: ERROR" to stderr. If LINENO and LOG_FD are 69354 # provided, also output the error to LOG_FD, referencing LINENO. Then exit the 69355 # script with STATUS, using 1 if that was 0. 69356 as_fn_error () 69357 { 69358 as_status=$1; test $as_status -eq 0 && as_status=1 69359 if test "$4"; then 69360 as_lineno=${as_lineno-"$3"} as_lineno_stack=as_lineno_stack=$as_lineno_stack 69361 $as_echo "$as_me:${as_lineno-$LINENO}: error: $2" >&$4 69362 fi 69363 $as_echo "$as_me: error: $2" >&2 69364 as_fn_exit $as_status 69365 } # as_fn_error 69366 69367 69368 # as_fn_set_status STATUS 69369 # ----------------------- 69370 # Set $? to STATUS, without forking. 69371 as_fn_set_status () 69372 { 69373 return $1 69374 } # as_fn_set_status 69375 69376 # as_fn_exit STATUS 69377 # ----------------- 69378 # Exit the shell with STATUS, even in a "trap 0" or "set -e" context. 69379 as_fn_exit () 69380 { 69381 set +e 69382 as_fn_set_status $1 69383 exit $1 69384 } # as_fn_exit 69385 69386 # as_fn_unset VAR 69387 # --------------- 69388 # Portably unset VAR. 69389 as_fn_unset () 69390 { 69391 { eval $1=; unset $1;} 69392 } 69393 as_unset=as_fn_unset 69394 # as_fn_append VAR VALUE 69395 # ---------------------- 69396 # Append the text in VALUE to the end of the definition contained in VAR. Take 69397 # advantage of any shell optimizations that allow amortized linear growth over 69398 # repeated appends, instead of the typical quadratic growth present in naive 69399 # implementations. 69400 if (eval "as_var=1; as_var+=2; test x\$as_var = x12") 2>/dev/null; then : 69401 eval 'as_fn_append () 69402 { 69403 eval $1+=\$2 69404 }' 69405 else 69406 as_fn_append () 69407 { 69408 eval $1=\$$1\$2 69409 } 69410 fi # as_fn_append 69411 69412 # as_fn_arith ARG... 69413 # ------------------ 69414 # Perform arithmetic evaluation on the ARGs, and store the result in the 69415 # global $as_val. Take advantage of shells that can avoid forks. The arguments 69416 # must be portable across $(()) and expr. 69417 if (eval "test \$(( 1 + 1 )) = 2") 2>/dev/null; then : 69418 eval 'as_fn_arith () 69419 { 69420 as_val=$(( $* )) 69421 }' 69422 else 69423 as_fn_arith () 69424 { 69425 as_val=`expr "$@" || test $? -eq 1` 69426 } 69427 fi # as_fn_arith 69428 69429 69430 if expr a : '\(a\)' >/dev/null 2>&1 && 69431 test "X`expr 00001 : '.*\(...\)'`" = X001; then 69432 as_expr=expr 69433 else 69434 as_expr=false 69435 fi 69436 69437 if (basename -- /) >/dev/null 2>&1 && test "X`basename -- / 2>&1`" = "X/"; then 69438 as_basename=basename 69439 else 69440 as_basename=false 69441 fi 69442 69443 if (as_dir=`dirname -- /` && test "X$as_dir" = X/) >/dev/null 2>&1; then 69444 as_dirname=dirname 69445 else 69446 as_dirname=false 69447 fi 69448 69449 as_me=`$as_basename -- "$0" || 69450 $as_expr X/"$0" : '.*/\([^/][^/]*\)/*$' \| \ 69451 X"$0" : 'X\(//\)$' \| \ 69452 X"$0" : 'X\(/\)' \| . 2>/dev/null || 69453 $as_echo X/"$0" | 69454 sed '/^.*\/\([^/][^/]*\)\/*$/{ 69455 s//\1/ 69456 q 69457 } 69458 /^X\/\(\/\/\)$/{ 69459 s//\1/ 69460 q 69461 } 69462 /^X\/\(\/\).*/{ 69463 s//\1/ 69464 q 69465 } 69466 s/.*/./; q'` 69467 69468 # Avoid depending upon Character Ranges. 69469 as_cr_letters='abcdefghijklmnopqrstuvwxyz' 69470 as_cr_LETTERS='ABCDEFGHIJKLMNOPQRSTUVWXYZ' 69471 as_cr_Letters=$as_cr_letters$as_cr_LETTERS 69472 as_cr_digits='0123456789' 69473 as_cr_alnum=$as_cr_Letters$as_cr_digits 69474 69475 ECHO_C= ECHO_N= ECHO_T= 69476 case `echo -n x` in #((((( 69477 -n*) 69478 case `echo 'xy\c'` in 69479 *c*) ECHO_T=' ';; # ECHO_T is single tab character. 69480 xy) ECHO_C='\c';; 69481 *) echo `echo ksh88 bug on AIX 6.1` > /dev/null 69482 ECHO_T=' ';; 69483 esac;; 69484 *) 69485 ECHO_N='-n';; 69486 esac 69487 69488 rm -f conf$$ conf$$.exe conf$$.file 69489 if test -d conf$$.dir; then 69490 rm -f conf$$.dir/conf$$.file 69491 else 69492 rm -f conf$$.dir 69493 mkdir conf$$.dir 2>/dev/null 69494 fi 69495 if (echo >conf$$.file) 2>/dev/null; then 69496 if ln -s conf$$.file conf$$ 2>/dev/null; then 69497 as_ln_s='ln -s' 69498 # ... but there are two gotchas: 69499 # 1) On MSYS, both `ln -s file dir' and `ln file dir' fail. 69500 # 2) DJGPP < 2.04 has no symlinks; `ln -s' creates a wrapper executable. 69501 # In both cases, we have to default to `cp -pR'. 69502 ln -s conf$$.file conf$$.dir 2>/dev/null && test ! -f conf$$.exe || 69503 as_ln_s='cp -pR' 69504 elif ln conf$$.file conf$$ 2>/dev/null; then 69505 as_ln_s=ln 69506 else 69507 as_ln_s='cp -pR' 69508 fi 69509 else 69510 as_ln_s='cp -pR' 69511 fi 69512 rm -f conf$$ conf$$.exe conf$$.dir/conf$$.file conf$$.file 69513 rmdir conf$$.dir 2>/dev/null 69514 69515 69516 # as_fn_mkdir_p 69517 # ------------- 69518 # Create "$as_dir" as a directory, including parents if necessary. 69519 as_fn_mkdir_p () 69520 { 69521 69522 case $as_dir in #( 69523 -*) as_dir=./$as_dir;; 69524 esac 69525 test -d "$as_dir" || eval $as_mkdir_p || { 69526 as_dirs= 69527 while :; do 69528 case $as_dir in #( 69529 *\'*) as_qdir=`$as_echo "$as_dir" | sed "s/'/'\\\\\\\\''/g"`;; #'( 69530 *) as_qdir=$as_dir;; 69531 esac 69532 as_dirs="'$as_qdir' $as_dirs" 69533 as_dir=`$as_dirname -- "$as_dir" || 69534 $as_expr X"$as_dir" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \ 69535 X"$as_dir" : 'X\(//\)[^/]' \| \ 69536 X"$as_dir" : 'X\(//\)$' \| \ 69537 X"$as_dir" : 'X\(/\)' \| . 2>/dev/null || 69538 $as_echo X"$as_dir" | 69539 sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{ 69540 s//\1/ 69541 q 69542 } 69543 /^X\(\/\/\)[^/].*/{ 69544 s//\1/ 69545 q 69546 } 69547 /^X\(\/\/\)$/{ 69548 s//\1/ 69549 q 69550 } 69551 /^X\(\/\).*/{ 69552 s//\1/ 69553 q 69554 } 69555 s/.*/./; q'` 69556 test -d "$as_dir" && break 69557 done 69558 test -z "$as_dirs" || eval "mkdir $as_dirs" 69559 } || test -d "$as_dir" || as_fn_error $? "cannot create directory $as_dir" 69560 69561 69562 } # as_fn_mkdir_p 69563 if mkdir -p . 2>/dev/null; then 69564 as_mkdir_p='mkdir -p "$as_dir"' 69565 else 69566 test -d ./-p && rmdir ./-p 69567 as_mkdir_p=false 69568 fi 69569 69570 69571 # as_fn_executable_p FILE 69572 # ----------------------- 69573 # Test if FILE is an executable regular file. 69574 as_fn_executable_p () 69575 { 69576 test -f "$1" && test -x "$1" 69577 } # as_fn_executable_p 69578 as_test_x='test -x' 69579 as_executable_p=as_fn_executable_p 69580 69581 # Sed expression to map a string onto a valid CPP name. 69582 as_tr_cpp="eval sed 'y%*$as_cr_letters%P$as_cr_LETTERS%;s%[^_$as_cr_alnum]%_%g'" 69583 69584 # Sed expression to map a string onto a valid variable name. 69585 as_tr_sh="eval sed 'y%*+%pp%;s%[^_$as_cr_alnum]%_%g'" 69586 69587 69588 exec 6>&1 69589 ## ----------------------------------- ## 69590 ## Main body of $CONFIG_STATUS script. ## 69591 ## ----------------------------------- ## 69592 _ASEOF 69593 test $as_write_fail = 0 && chmod +x $CONFIG_STATUS || ac_write_fail=1 69594 69595 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1 69596 # Save the log message, to keep $0 and so on meaningful, and to 69597 # report actual input values of CONFIG_FILES etc. instead of their 69598 # values after options handling. 69599 ac_log=" 69600 This file was extended by OpenJDK $as_me jdk9, which was 69601 generated by GNU Autoconf 2.69. Invocation command line was 69602 69603 CONFIG_FILES = $CONFIG_FILES 69604 CONFIG_HEADERS = $CONFIG_HEADERS 69605 CONFIG_LINKS = $CONFIG_LINKS 69606 CONFIG_COMMANDS = $CONFIG_COMMANDS 69607 $ $0 $@ 69608 69609 on `(hostname || uname -n) 2>/dev/null | sed 1q` 69610 " 69611 69612 _ACEOF 69613 69614 case $ac_config_files in *" 69615 "*) set x $ac_config_files; shift; ac_config_files=$*;; 69616 esac 69617 69618 69619 69620 cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1 69621 # Files that config.status was made for. 69622 config_files="$ac_config_files" 69623 69624 _ACEOF 69625 69626 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1 69627 ac_cs_usage="\ 69628 \`$as_me' instantiates files and other configuration actions 69629 from templates according to the current configuration. Unless the files 69630 and actions are specified as TAGs, all are instantiated by default. 69631 69632 Usage: $0 [OPTION]... [TAG]... 69633 69634 -h, --help print this help, then exit 69635 -V, --version print version number and configuration settings, then exit 69636 --config print configuration, then exit 69637 -q, --quiet, --silent 69638 do not print progress messages 69639 -d, --debug don't remove temporary files 69640 --recheck update $as_me by reconfiguring in the same conditions 69641 --file=FILE[:TEMPLATE] 69642 instantiate the configuration file FILE 69643 69644 Configuration files: 69645 $config_files 69646 69647 Report bugs to <build-dev@openjdk.java.net>. 69648 OpenJDK home page: <http://openjdk.java.net>." 69649 69650 _ACEOF 69651 cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1 69652 ac_cs_config="`$as_echo "$ac_configure_args" | sed 's/^ //; s/[\\""\`\$]/\\\\&/g'`" 69653 ac_cs_version="\\ 69654 OpenJDK config.status jdk9 69655 configured by $0, generated by GNU Autoconf 2.69, 69656 with options \\"\$ac_cs_config\\" 69657 69658 Copyright (C) 2012 Free Software Foundation, Inc. 69659 This config.status script is free software; the Free Software Foundation 69660 gives unlimited permission to copy, distribute and modify it." 69661 69662 ac_pwd='$ac_pwd' 69663 srcdir='$srcdir' 69664 AWK='$AWK' 69665 test -n "\$AWK" || AWK=awk 69666 _ACEOF 69667 69668 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1 69669 # The default lists apply if the user does not specify any file. 69670 ac_need_defaults=: 69671 while test $# != 0 69672 do 69673 case $1 in 69674 --*=?*) 69675 ac_option=`expr "X$1" : 'X\([^=]*\)='` 69676 ac_optarg=`expr "X$1" : 'X[^=]*=\(.*\)'` 69677 ac_shift=: 69678 ;; 69679 --*=) 69680 ac_option=`expr "X$1" : 'X\([^=]*\)='` 69681 ac_optarg= 69682 ac_shift=: 69683 ;; 69684 *) 69685 ac_option=$1 69686 ac_optarg=$2 69687 ac_shift=shift 69688 ;; 69689 esac 69690 69691 case $ac_option in 69692 # Handling of the options. 69693 -recheck | --recheck | --rechec | --reche | --rech | --rec | --re | --r) 69694 ac_cs_recheck=: ;; 69695 --version | --versio | --versi | --vers | --ver | --ve | --v | -V ) 69696 $as_echo "$ac_cs_version"; exit ;; 69697 --config | --confi | --conf | --con | --co | --c ) 69698 $as_echo "$ac_cs_config"; exit ;; 69699 --debug | --debu | --deb | --de | --d | -d ) 69700 debug=: ;; 69701 --file | --fil | --fi | --f ) 69702 $ac_shift 69703 case $ac_optarg in 69704 *\'*) ac_optarg=`$as_echo "$ac_optarg" | sed "s/'/'\\\\\\\\''/g"` ;; 69705 '') as_fn_error $? "missing file argument" ;; 69706 esac 69707 as_fn_append CONFIG_FILES " '$ac_optarg'" 69708 ac_need_defaults=false;; 69709 --he | --h | --help | --hel | -h ) 69710 $as_echo "$ac_cs_usage"; exit ;; 69711 -q | -quiet | --quiet | --quie | --qui | --qu | --q \ 69712 | -silent | --silent | --silen | --sile | --sil | --si | --s) 69713 ac_cs_silent=: ;; 69714 69715 # This is an error. 69716 -*) as_fn_error $? "unrecognized option: \`$1' 69717 Try \`$0 --help' for more information." ;; 69718 69719 *) as_fn_append ac_config_targets " $1" 69720 ac_need_defaults=false ;; 69721 69722 esac 69723 shift 69724 done 69725 69726 ac_configure_extra_args= 69727 69728 if $ac_cs_silent; then 69729 exec 6>/dev/null 69730 ac_configure_extra_args="$ac_configure_extra_args --silent" 69731 fi 69732 69733 _ACEOF 69734 cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1 69735 if \$ac_cs_recheck; then 69736 set X $SHELL '$0' $ac_configure_args \$ac_configure_extra_args --no-create --no-recursion 69737 shift 69738 \$as_echo "running CONFIG_SHELL=$SHELL \$*" >&6 69739 CONFIG_SHELL='$SHELL' 69740 export CONFIG_SHELL 69741 exec "\$@" 69742 fi 69743 69744 _ACEOF 69745 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1 69746 exec 5>>config.log 69747 { 69748 echo 69749 sed 'h;s/./-/g;s/^.../## /;s/...$/ ##/;p;x;p;x' <<_ASBOX 69750 ## Running $as_me. ## 69751 _ASBOX 69752 $as_echo "$ac_log" 69753 } >&5 69754 69755 _ACEOF 69756 cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1 69757 _ACEOF 69758 69759 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1 69760 69761 # Handling of arguments. 69762 for ac_config_target in $ac_config_targets 69763 do 69764 case $ac_config_target in 69765 "$OUTPUTDIR/spec.gmk") CONFIG_FILES="$CONFIG_FILES $OUTPUTDIR/spec.gmk:$AUTOCONF_DIR/spec.gmk.in" ;; 69766 "$OUTPUTDIR/bootcycle-spec.gmk") CONFIG_FILES="$CONFIG_FILES $OUTPUTDIR/bootcycle-spec.gmk:$AUTOCONF_DIR/bootcycle-spec.gmk.in" ;; 69767 "$OUTPUTDIR/buildjdk-spec.gmk") CONFIG_FILES="$CONFIG_FILES $OUTPUTDIR/buildjdk-spec.gmk:$AUTOCONF_DIR/buildjdk-spec.gmk.in" ;; 69768 "$OUTPUTDIR/compare.sh") CONFIG_FILES="$CONFIG_FILES $OUTPUTDIR/compare.sh:$AUTOCONF_DIR/compare.sh.in" ;; 69769 "$OUTPUTDIR/Makefile") CONFIG_FILES="$CONFIG_FILES $OUTPUTDIR/Makefile:$AUTOCONF_DIR/Makefile.in" ;; 69770 69771 *) as_fn_error $? "invalid argument: \`$ac_config_target'" "$LINENO" 5;; 69772 esac 69773 done 69774 69775 69776 # If the user did not use the arguments to specify the items to instantiate, 69777 # then the envvar interface is used. Set only those that are not. 69778 # We use the long form for the default assignment because of an extremely 69779 # bizarre bug on SunOS 4.1.3. 69780 if $ac_need_defaults; then 69781 test "${CONFIG_FILES+set}" = set || CONFIG_FILES=$config_files 69782 fi 69783 69784 # Have a temporary directory for convenience. Make it in the build tree 69785 # simply because there is no reason against having it here, and in addition, 69786 # creating and moving files from /tmp can sometimes cause problems. 69787 # Hook for its removal unless debugging. 69788 # Note that there is a small window in which the directory will not be cleaned: 69789 # after its creation but before its name has been assigned to `$tmp'. 69790 $debug || 69791 { 69792 tmp= ac_tmp= 69793 trap 'exit_status=$? 69794 : "${ac_tmp:=$tmp}" 69795 { test ! -d "$ac_tmp" || rm -fr "$ac_tmp"; } && exit $exit_status 69796 ' 0 69797 trap 'as_fn_exit 1' 1 2 13 15 69798 } 69799 # Create a (secure) tmp directory for tmp files. 69800 69801 { 69802 tmp=`(umask 077 && mktemp -d "./confXXXXXX") 2>/dev/null` && 69803 test -d "$tmp" 69804 } || 69805 { 69806 tmp=./conf$$-$RANDOM 69807 (umask 077 && mkdir "$tmp") 69808 } || as_fn_error $? "cannot create a temporary directory in ." "$LINENO" 5 69809 ac_tmp=$tmp 69810 69811 # Set up the scripts for CONFIG_FILES section. 69812 # No need to generate them if there are no CONFIG_FILES. 69813 # This happens for instance with `./config.status config.h'. 69814 if test -n "$CONFIG_FILES"; then 69815 69816 69817 ac_cr=`echo X | tr X '\015'` 69818 # On cygwin, bash can eat \r inside `` if the user requested igncr. 69819 # But we know of no other shell where ac_cr would be empty at this 69820 # point, so we can use a bashism as a fallback. 69821 if test "x$ac_cr" = x; then 69822 eval ac_cr=\$\'\\r\' 69823 fi 69824 ac_cs_awk_cr=`$AWK 'BEGIN { print "a\rb" }' </dev/null 2>/dev/null` 69825 if test "$ac_cs_awk_cr" = "a${ac_cr}b"; then 69826 ac_cs_awk_cr='\\r' 69827 else 69828 ac_cs_awk_cr=$ac_cr 69829 fi 69830 69831 echo 'BEGIN {' >"$ac_tmp/subs1.awk" && 69832 _ACEOF 69833 69834 69835 { 69836 echo "cat >conf$$subs.awk <<_ACEOF" && 69837 echo "$ac_subst_vars" | sed 's/.*/&!$&$ac_delim/' && 69838 echo "_ACEOF" 69839 } >conf$$subs.sh || 69840 as_fn_error $? "could not make $CONFIG_STATUS" "$LINENO" 5 69841 ac_delim_num=`echo "$ac_subst_vars" | grep -c '^'` 69842 ac_delim='%!_!# ' 69843 for ac_last_try in false false false false false :; do 69844 . ./conf$$subs.sh || 69845 as_fn_error $? "could not make $CONFIG_STATUS" "$LINENO" 5 69846 69847 ac_delim_n=`sed -n "s/.*$ac_delim\$/X/p" conf$$subs.awk | grep -c X` 69848 if test $ac_delim_n = $ac_delim_num; then 69849 break 69850 elif $ac_last_try; then 69851 as_fn_error $? "could not make $CONFIG_STATUS" "$LINENO" 5 69852 else 69853 ac_delim="$ac_delim!$ac_delim _$ac_delim!! " 69854 fi 69855 done 69856 rm -f conf$$subs.sh 69857 69858 cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1 69859 cat >>"\$ac_tmp/subs1.awk" <<\\_ACAWK && 69860 _ACEOF 69861 sed -n ' 69862 h 69863 s/^/S["/; s/!.*/"]=/ 69864 p 69865 g 69866 s/^[^!]*!// 69867 :repl 69868 t repl 69869 s/'"$ac_delim"'$// 69870 t delim 69871 :nl 69872 h 69873 s/\(.\{148\}\)..*/\1/ 69874 t more1 69875 s/["\\]/\\&/g; s/^/"/; s/$/\\n"\\/ 69876 p 69877 n 69878 b repl 69879 :more1 69880 s/["\\]/\\&/g; s/^/"/; s/$/"\\/ 69881 p 69882 g 69883 s/.\{148\}// 69884 t nl 69885 :delim 69886 h 69887 s/\(.\{148\}\)..*/\1/ 69888 t more2 69889 s/["\\]/\\&/g; s/^/"/; s/$/"/ 69890 p 69891 b 69892 :more2 69893 s/["\\]/\\&/g; s/^/"/; s/$/"\\/ 69894 p 69895 g 69896 s/.\{148\}// 69897 t delim 69898 ' <conf$$subs.awk | sed ' 69899 /^[^""]/{ 69900 N 69901 s/\n// 69902 } 69903 ' >>$CONFIG_STATUS || ac_write_fail=1 69904 rm -f conf$$subs.awk 69905 cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1 69906 _ACAWK 69907 cat >>"\$ac_tmp/subs1.awk" <<_ACAWK && 69908 for (key in S) S_is_set[key] = 1 69909 FS = "" 69910 69911 } 69912 { 69913 line = $ 0 69914 nfields = split(line, field, "@") 69915 substed = 0 69916 len = length(field[1]) 69917 for (i = 2; i < nfields; i++) { 69918 key = field[i] 69919 keylen = length(key) 69920 if (S_is_set[key]) { 69921 value = S[key] 69922 line = substr(line, 1, len) "" value "" substr(line, len + keylen + 3) 69923 len += length(value) + length(field[++i]) 69924 substed = 1 69925 } else 69926 len += 1 + keylen 69927 } 69928 69929 print line 69930 } 69931 69932 _ACAWK 69933 _ACEOF 69934 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1 69935 if sed "s/$ac_cr//" < /dev/null > /dev/null 2>&1; then 69936 sed "s/$ac_cr\$//; s/$ac_cr/$ac_cs_awk_cr/g" 69937 else 69938 cat 69939 fi < "$ac_tmp/subs1.awk" > "$ac_tmp/subs.awk" \ 69940 || as_fn_error $? "could not setup config files machinery" "$LINENO" 5 69941 _ACEOF 69942 69943 # VPATH may cause trouble with some makes, so we remove sole $(srcdir), 69944 # ${srcdir} and @srcdir@ entries from VPATH if srcdir is ".", strip leading and 69945 # trailing colons and then remove the whole line if VPATH becomes empty 69946 # (actually we leave an empty line to preserve line numbers). 69947 if test "x$srcdir" = x.; then 69948 ac_vpsub='/^[ ]*VPATH[ ]*=[ ]*/{ 69949 h 69950 s/// 69951 s/^/:/ 69952 s/[ ]*$/:/ 69953 s/:\$(srcdir):/:/g 69954 s/:\${srcdir}:/:/g 69955 s/:@srcdir@:/:/g 69956 s/^:*// 69957 s/:*$// 69958 x 69959 s/\(=[ ]*\).*/\1/ 69960 G 69961 s/\n// 69962 s/^[^=]*=[ ]*$// 69963 }' 69964 fi 69965 69966 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1 69967 fi # test -n "$CONFIG_FILES" 69968 69969 69970 eval set X " :F $CONFIG_FILES " 69971 shift 69972 for ac_tag 69973 do 69974 case $ac_tag in 69975 :[FHLC]) ac_mode=$ac_tag; continue;; 69976 esac 69977 case $ac_mode$ac_tag in 69978 :[FHL]*:*);; 69979 :L* | :C*:*) as_fn_error $? "invalid tag \`$ac_tag'" "$LINENO" 5;; 69980 :[FH]-) ac_tag=-:-;; 69981 :[FH]*) ac_tag=$ac_tag:$ac_tag.in;; 69982 esac 69983 ac_save_IFS=$IFS 69984 IFS=: 69985 set x $ac_tag 69986 IFS=$ac_save_IFS 69987 shift 69988 ac_file=$1 69989 shift 69990 69991 case $ac_mode in 69992 :L) ac_source=$1;; 69993 :[FH]) 69994 ac_file_inputs= 69995 for ac_f 69996 do 69997 case $ac_f in 69998 -) ac_f="$ac_tmp/stdin";; 69999 *) # Look for the file first in the build tree, then in the source tree 70000 # (if the path is not absolute). The absolute path cannot be DOS-style, 70001 # because $ac_f cannot contain `:'. 70002 test -f "$ac_f" || 70003 case $ac_f in 70004 [\\/$]*) false;; 70005 *) test -f "$srcdir/$ac_f" && ac_f="$srcdir/$ac_f";; 70006 esac || 70007 as_fn_error 1 "cannot find input file: \`$ac_f'" "$LINENO" 5;; 70008 esac 70009 case $ac_f in *\'*) ac_f=`$as_echo "$ac_f" | sed "s/'/'\\\\\\\\''/g"`;; esac 70010 as_fn_append ac_file_inputs " '$ac_f'" 70011 done 70012 70013 # Let's still pretend it is `configure' which instantiates (i.e., don't 70014 # use $as_me), people would be surprised to read: 70015 # /* config.h. Generated by config.status. */ 70016 configure_input='Generated from '` 70017 $as_echo "$*" | sed 's|^[^:]*/||;s|:[^:]*/|, |g' 70018 `' by configure.' 70019 if test x"$ac_file" != x-; then 70020 configure_input="$ac_file. $configure_input" 70021 { $as_echo "$as_me:${as_lineno-$LINENO}: creating $ac_file" >&5 70022 $as_echo "$as_me: creating $ac_file" >&6;} 70023 fi 70024 # Neutralize special characters interpreted by sed in replacement strings. 70025 case $configure_input in #( 70026 *\&* | *\|* | *\\* ) 70027 ac_sed_conf_input=`$as_echo "$configure_input" | 70028 sed 's/[\\\\&|]/\\\\&/g'`;; #( 70029 *) ac_sed_conf_input=$configure_input;; 70030 esac 70031 70032 case $ac_tag in 70033 *:-:* | *:-) cat >"$ac_tmp/stdin" \ 70034 || as_fn_error $? "could not create $ac_file" "$LINENO" 5 ;; 70035 esac 70036 ;; 70037 esac 70038 70039 ac_dir=`$as_dirname -- "$ac_file" || 70040 $as_expr X"$ac_file" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \ 70041 X"$ac_file" : 'X\(//\)[^/]' \| \ 70042 X"$ac_file" : 'X\(//\)$' \| \ 70043 X"$ac_file" : 'X\(/\)' \| . 2>/dev/null || 70044 $as_echo X"$ac_file" | 70045 sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{ 70046 s//\1/ 70047 q 70048 } 70049 /^X\(\/\/\)[^/].*/{ 70050 s//\1/ 70051 q 70052 } 70053 /^X\(\/\/\)$/{ 70054 s//\1/ 70055 q 70056 } 70057 /^X\(\/\).*/{ 70058 s//\1/ 70059 q 70060 } 70061 s/.*/./; q'` 70062 as_dir="$ac_dir"; as_fn_mkdir_p 70063 ac_builddir=. 70064 70065 case "$ac_dir" in 70066 .) ac_dir_suffix= ac_top_builddir_sub=. ac_top_build_prefix= ;; 70067 *) 70068 ac_dir_suffix=/`$as_echo "$ac_dir" | sed 's|^\.[\\/]||'` 70069 # A ".." for each directory in $ac_dir_suffix. 70070 ac_top_builddir_sub=`$as_echo "$ac_dir_suffix" | sed 's|/[^\\/]*|/..|g;s|/||'` 70071 case $ac_top_builddir_sub in 70072 "") ac_top_builddir_sub=. ac_top_build_prefix= ;; 70073 *) ac_top_build_prefix=$ac_top_builddir_sub/ ;; 70074 esac ;; 70075 esac 70076 ac_abs_top_builddir=$ac_pwd 70077 ac_abs_builddir=$ac_pwd$ac_dir_suffix 70078 # for backward compatibility: 70079 ac_top_builddir=$ac_top_build_prefix 70080 70081 case $srcdir in 70082 .) # We are building in place. 70083 ac_srcdir=. 70084 ac_top_srcdir=$ac_top_builddir_sub 70085 ac_abs_top_srcdir=$ac_pwd ;; 70086 [\\/]* | ?:[\\/]* ) # Absolute name. 70087 ac_srcdir=$srcdir$ac_dir_suffix; 70088 ac_top_srcdir=$srcdir 70089 ac_abs_top_srcdir=$srcdir ;; 70090 *) # Relative name. 70091 ac_srcdir=$ac_top_build_prefix$srcdir$ac_dir_suffix 70092 ac_top_srcdir=$ac_top_build_prefix$srcdir 70093 ac_abs_top_srcdir=$ac_pwd/$srcdir ;; 70094 esac 70095 ac_abs_srcdir=$ac_abs_top_srcdir$ac_dir_suffix 70096 70097 70098 case $ac_mode in 70099 :F) 70100 # 70101 # CONFIG_FILE 70102 # 70103 70104 _ACEOF 70105 70106 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1 70107 # If the template does not know about datarootdir, expand it. 70108 # FIXME: This hack should be removed a few years after 2.60. 70109 ac_datarootdir_hack=; ac_datarootdir_seen= 70110 ac_sed_dataroot=' 70111 /datarootdir/ { 70112 p 70113 q 70114 } 70115 /@datadir@/p 70116 /@docdir@/p 70117 /@infodir@/p 70118 /@localedir@/p 70119 /@mandir@/p' 70120 case `eval "sed -n \"\$ac_sed_dataroot\" $ac_file_inputs"` in 70121 *datarootdir*) ac_datarootdir_seen=yes;; 70122 *@datadir@*|*@docdir@*|*@infodir@*|*@localedir@*|*@mandir@*) 70123 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $ac_file_inputs seems to ignore the --datarootdir setting" >&5 70124 $as_echo "$as_me: WARNING: $ac_file_inputs seems to ignore the --datarootdir setting" >&2;} 70125 _ACEOF 70126 cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1 70127 ac_datarootdir_hack=' 70128 s&@datadir@&$datadir&g 70129 s&@docdir@&$docdir&g 70130 s&@infodir@&$infodir&g 70131 s&@localedir@&$localedir&g 70132 s&@mandir@&$mandir&g 70133 s&\\\${datarootdir}&$datarootdir&g' ;; 70134 esac 70135 _ACEOF 70136 70137 # Neutralize VPATH when `$srcdir' = `.'. 70138 # Shell code in configure.ac might set extrasub. 70139 # FIXME: do we really want to maintain this feature? 70140 cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1 70141 ac_sed_extra="$ac_vpsub 70142 $extrasub 70143 _ACEOF 70144 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1 70145 :t 70146 /@[a-zA-Z_][a-zA-Z_0-9]*@/!b 70147 s|@configure_input@|$ac_sed_conf_input|;t t 70148 s&@top_builddir@&$ac_top_builddir_sub&;t t 70149 s&@top_build_prefix@&$ac_top_build_prefix&;t t 70150 s&@srcdir@&$ac_srcdir&;t t 70151 s&@abs_srcdir@&$ac_abs_srcdir&;t t 70152 s&@top_srcdir@&$ac_top_srcdir&;t t 70153 s&@abs_top_srcdir@&$ac_abs_top_srcdir&;t t 70154 s&@builddir@&$ac_builddir&;t t 70155 s&@abs_builddir@&$ac_abs_builddir&;t t 70156 s&@abs_top_builddir@&$ac_abs_top_builddir&;t t 70157 $ac_datarootdir_hack 70158 " 70159 eval sed \"\$ac_sed_extra\" "$ac_file_inputs" | $AWK -f "$ac_tmp/subs.awk" \ 70160 >$ac_tmp/out || as_fn_error $? "could not create $ac_file" "$LINENO" 5 70161 70162 test -z "$ac_datarootdir_hack$ac_datarootdir_seen" && 70163 { ac_out=`sed -n '/\${datarootdir}/p' "$ac_tmp/out"`; test -n "$ac_out"; } && 70164 { ac_out=`sed -n '/^[ ]*datarootdir[ ]*:*=/p' \ 70165 "$ac_tmp/out"`; test -z "$ac_out"; } && 70166 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $ac_file contains a reference to the variable \`datarootdir' 70167 which seems to be undefined. Please make sure it is defined" >&5 70168 $as_echo "$as_me: WARNING: $ac_file contains a reference to the variable \`datarootdir' 70169 which seems to be undefined. Please make sure it is defined" >&2;} 70170 70171 rm -f "$ac_tmp/stdin" 70172 case $ac_file in 70173 -) cat "$ac_tmp/out" && rm -f "$ac_tmp/out";; 70174 *) rm -f "$ac_file" && mv "$ac_tmp/out" "$ac_file";; 70175 esac \ 70176 || as_fn_error $? "could not create $ac_file" "$LINENO" 5 70177 ;; 70178 70179 70180 70181 esac 70182 70183 done # for ac_tag 70184 70185 70186 as_fn_exit 0 70187 _ACEOF 70188 ac_clean_files=$ac_clean_files_save 70189 70190 test $ac_write_fail = 0 || 70191 as_fn_error $? "write failure creating $CONFIG_STATUS" "$LINENO" 5 70192 70193 70194 # configure is writing to config.log, and then calls config.status. 70195 # config.status does its own redirection, appending to config.log. 70196 # Unfortunately, on DOS this fails, as config.log is still kept open 70197 # by configure, so config.status won't be able to write to it; its 70198 # output is simply discarded. So we exec the FD to /dev/null, 70199 # effectively closing config.log, so it can be properly (re)opened and 70200 # appended to by config.status. When coming back to configure, we 70201 # need to make the FD available again. 70202 if test "$no_create" != yes; then 70203 ac_cs_success=: 70204 ac_config_status_args= 70205 test "$silent" = yes && 70206 ac_config_status_args="$ac_config_status_args --quiet" 70207 exec 5>/dev/null 70208 $SHELL $CONFIG_STATUS $ac_config_status_args || ac_cs_success=false 70209 exec 5>>config.log 70210 # Use ||, not &&, to avoid exiting from the if with $? = 1, which 70211 # would make configure fail if this is the last instruction. 70212 $ac_cs_success || as_fn_exit 1 70213 fi 70214 if test -n "$ac_unrecognized_opts" && test "$enable_option_checking" != no; then 70215 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: unrecognized options: $ac_unrecognized_opts" >&5 70216 $as_echo "$as_me: WARNING: unrecognized options: $ac_unrecognized_opts" >&2;} 70217 fi 70218 70219 70220 # After AC_OUTPUT, we need to do final work 70221 70222 70223 # Try to move config.log (generated by autoconf) to the configure-support directory. 70224 if test -e ./config.log; then 70225 $MV -f ./config.log "$CONFIGURESUPPORT_OUTPUTDIR/config.log" 2> /dev/null 70226 fi 70227 70228 # Rotate our log file (configure.log) 70229 if test -e "$OUTPUTDIR/configure.log.old"; then 70230 $RM -f "$OUTPUTDIR/configure.log.old" 70231 fi 70232 if test -e "$OUTPUTDIR/configure.log"; then 70233 $MV -f "$OUTPUTDIR/configure.log" "$OUTPUTDIR/configure.log.old" 2> /dev/null 70234 fi 70235 70236 # Move configure.log from current directory to the build output root 70237 if test -e ./configure.log; then 70238 $MV -f ./configure.log "$OUTPUTDIR/configure.log" 2> /dev/null 70239 fi 70240 70241 # Make the compare script executable 70242 $CHMOD +x $OUTPUTDIR/compare.sh 70243 70244 70245 # Finally output some useful information to the user 70246 70247 # Finally output some useful information to the user 70248 70249 printf "\n" 70250 printf "====================================================\n" 70251 if test "x$no_create" != "xyes"; then 70252 if test "x$IS_RECONFIGURE" != "xyes"; then 70253 printf "A new configuration has been successfully created in\n%s\n" "$OUTPUTDIR" 70254 else 70255 printf "The existing configuration has been successfully updated in\n%s\n" "$OUTPUTDIR" 70256 fi 70257 else 70258 if test "x$IS_RECONFIGURE" != "xyes"; then 70259 printf "A configuration has been successfully checked but not created\n" 70260 else 70261 printf "The existing configuration has been successfully checked in\n%s\n" "$OUTPUTDIR" 70262 fi 70263 fi 70264 if test "x$CONFIGURE_COMMAND_LINE" != x; then 70265 printf "using configure arguments '$CONFIGURE_COMMAND_LINE'.\n" 70266 else 70267 printf "using default settings.\n" 70268 fi 70269 70270 printf "\n" 70271 printf "Configuration summary:\n" 70272 printf "* Debug level: $DEBUG_LEVEL\n" 70273 printf "* HS debug level: $HOTSPOT_DEBUG_LEVEL\n" 70274 printf "* JDK variant: $JDK_VARIANT\n" 70275 printf "* JVM variants: $JVM_VARIANTS\n" 70276 printf "* OpenJDK target: OS: $OPENJDK_TARGET_OS, CPU architecture: $OPENJDK_TARGET_CPU_ARCH, address length: $OPENJDK_TARGET_CPU_BITS\n" 70277 printf "* Version string: $VERSION_STRING ($VERSION_SHORT)\n" 70278 70279 printf "\n" 70280 printf "Tools summary:\n" 70281 if test "x$OPENJDK_BUILD_OS" = "xwindows"; then 70282 printf "* Environment: $WINDOWS_ENV_VENDOR version $WINDOWS_ENV_VERSION (root at $WINDOWS_ENV_ROOT_PATH)\n" 70283 fi 70284 printf "* Boot JDK: $BOOT_JDK_VERSION (at $BOOT_JDK)\n" 70285 if test "x$TOOLCHAIN_VERSION" != "x"; then 70286 print_version=" $TOOLCHAIN_VERSION" 70287 fi 70288 printf "* Toolchain: $TOOLCHAIN_TYPE ($TOOLCHAIN_DESCRIPTION$print_version)\n" 70289 printf "* C Compiler: Version $CC_VERSION_NUMBER (at $CC)\n" 70290 printf "* C++ Compiler: Version $CXX_VERSION_NUMBER (at $CXX)\n" 70291 70292 printf "\n" 70293 printf "Build performance summary:\n" 70294 printf "* Cores to use: $JOBS\n" 70295 printf "* Memory limit: $MEMORY_SIZE MB\n" 70296 if test "x$CCACHE_STATUS" != "x"; then 70297 printf "* ccache status: $CCACHE_STATUS\n" 70298 fi 70299 printf "\n" 70300 70301 if test "x$BUILDING_MULTIPLE_JVM_VARIANTS" = "xtrue"; then 70302 printf "NOTE: You have requested to build more than one version of the JVM, which\n" 70303 printf "will result in longer build times.\n" 70304 printf "\n" 70305 fi 70306 70307 if test "x$FOUND_ALT_VARIABLES" != "x"; then 70308 printf "WARNING: You have old-style ALT_ environment variables set.\n" 70309 printf "These are not respected, and will be ignored. It is recommended\n" 70310 printf "that you clean your environment. The following variables are set:\n" 70311 printf "$FOUND_ALT_VARIABLES\n" 70312 printf "\n" 70313 fi 70314 70315 if test "x$OUTPUT_DIR_IS_LOCAL" != "xyes"; then 70316 printf "WARNING: Your build output directory is not on a local disk.\n" 70317 printf "This will severely degrade build performance!\n" 70318 printf "It is recommended that you create an output directory on a local disk,\n" 70319 printf "and run the configure script again from that directory.\n" 70320 printf "\n" 70321 fi 70322 70323 if test "x$IS_RECONFIGURE" = "xyes" && test "x$no_create" != "xyes"; then 70324 printf "WARNING: The result of this configuration has overridden an older\n" 70325 printf "configuration. You *should* run 'make clean' to make sure you get a\n" 70326 printf "proper build. Failure to do so might result in strange build problems.\n" 70327 printf "\n" 70328 fi 70329 70330 if test "x$IS_RECONFIGURE" != "xyes" && test "x$no_create" = "xyes"; then 70331 printf "WARNING: The result of this configuration was not saved.\n" 70332 printf "You should run without '--no-create | -n' to create the configuration.\n" 70333 printf "\n" 70334 fi 70335 70336 70337 70338 # Locate config.log. 70339 if test -e "$CONFIGURESUPPORT_OUTPUTDIR/config.log"; then 70340 CONFIG_LOG_PATH="$CONFIGURESUPPORT_OUTPUTDIR" 70341 elif test -e "./config.log"; then 70342 CONFIG_LOG_PATH="." 70343 fi 70344 70345 if test -e "$CONFIG_LOG_PATH/config.log"; then 70346 $GREP '^configure:.*: WARNING:' "$CONFIG_LOG_PATH/config.log" > /dev/null 2>&1 70347 if test $? -eq 0; then 70348 printf "The following warnings were produced. Repeated here for convenience:\n" 70349 # We must quote sed expression (using []) to stop m4 from eating the []. 70350 $GREP '^configure:.*: WARNING:' "$CONFIG_LOG_PATH/config.log" | $SED -e 's/^configure:[0-9]*: //' 70351 printf "\n" 70352 fi 70353 fi 70354